@import url('https://fonts.googleapis.com/css2?family=Ma+Shan+Zheng&family=Noto+Sans+SC:wght@400;500;700&display=swap');

:root {
  --primary: #6B46C1;
  --secondary: #C0A062;
  --accent: #FF6B6B;
  --bg-dark: #1A1033;
  --bg-light: rgba(255, 255, 255, 0.06);
  --text-main: #FFFFFF;
  --text-muted: rgba(255, 255, 255, 0.7);
}

* {
  box-sizing: border-box;
}

html, body {
  max-width: 100%;
  overflow-x: hidden;
}

body {
  background-color: var(--bg-dark);
  color: var(--text-main);
  font-family: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  line-height: 1.7;
  word-break: break-word;
}

h1, h2, h3, h4, h5, h6, .font-display {
  font-family: 'Ma Shan Zheng', 'STKaiti', 'KaiTi', serif;
  line-height: 1.25;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
}

::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 4px;
}

.stars {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  background-image:
    radial-gradient(circle, rgba(255, 255, 255, 0.12) 1px, transparent 1px),
    radial-gradient(circle, rgba(107, 70, 193, 0.18) 2px, transparent 2px);
  background-size: 48px 48px, 96px 96px;
  animation: drift 80s linear infinite;
}

.orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.22;
  pointer-events: none;
  z-index: 0;
}

.orb-1 {
  width: 360px;
  height: 360px;
  background: var(--primary);
  top: -120px;
  right: -80px;
  animation: float-orb 10s ease-in-out infinite;
}

.orb-2 {
  width: 280px;
  height: 280px;
  background: var(--accent);
  bottom: 10%;
  left: -80px;
  animation: float-orb 12s ease-in-out infinite reverse;
}

.z-10 {
  position: relative;
  z-index: 10;
}

.btn-neon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.75rem;
  border-radius: 9999px;
  background: linear-gradient(135deg, var(--primary), #8B5CF6);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 0 18px rgba(107, 70, 193, 0.55);
  transition: all 0.3s ease;
}

.btn-neon:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 0 28px rgba(255, 107, 107, 0.7);
}

.btn-gold {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.875rem 2rem;
  border-radius: 0.75rem;
  background: linear-gradient(180deg, #E8D5A3 0%, var(--secondary) 50%, #8F7640 100%);
  color: #1A1033;
  font-weight: 800;
  border: 2px solid rgba(255, 255, 255, 0.3);
  box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.35), 0 6px 0 #5E4D28, 0 8px 16px rgba(0, 0, 0, 0.35);
  transition: all 0.15s ease;
}

.btn-gold:active {
  transform: translateY(4px);
  box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.35), 0 2px 0 #5E4D28, 0 3px 6px rgba(0, 0, 0, 0.35);
}

.btn-gold:hover {
  filter: brightness(1.08);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
  backdrop-filter: blur(8px);
  transition: all 0.3s ease;
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: var(--secondary);
  transform: translateY(-2px);
}

.card-glass {
  background: var(--bg-light);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 1.25rem;
  padding: 1.5rem;
  transition: all 0.35s ease;
}

.card-glass:hover {
  transform: translateY(-8px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35), 0 0 20px rgba(107, 70, 193, 0.25);
  border-color: rgba(107, 70, 193, 0.45);
}

.card-solid {
  background: linear-gradient(145deg, rgba(107, 70, 193, 0.22), rgba(26, 16, 51, 0.92));
  border: 1px solid rgba(192, 160, 98, 0.35);
  border-radius: 1rem;
  padding: 1.5rem;
  transition: all 0.35s ease;
}

.card-solid:hover {
  transform: scale(1.02);
  border-color: var(--accent);
  box-shadow: 0 0 24px rgba(255, 107, 107, 0.25);
}

.card-img {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
  background: var(--bg-dark);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.35s ease;
}

.card-img:hover {
  transform: rotate(1deg) scale(1.02);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.card-img:hover img {
  transform: scale(1.08);
}

.title-line {
  position: relative;
  display: inline-block;
  padding-bottom: 0.5rem;
  margin-bottom: 1rem;
}

.title-line::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 3rem;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 2px;
}

.title-center::after {
  left: 50%;
  transform: translateX(-50%);
  width: 4rem;
}

.title-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(192, 160, 98, 0.12);
  border: 1px solid rgba(192, 160, 98, 0.35);
  border-radius: 9999px;
  padding: 0.35rem 1rem;
  color: var(--secondary);
  font-weight: 600;
  margin-bottom: 0.75rem;
}

.title-stroke {
  position: relative;
  color: var(--text-main);
}

.title-stroke::before {
  content: attr(data-text);
  position: absolute;
  left: 2px;
  top: 2px;
  color: transparent;
  -webkit-text-stroke: 1px rgba(107, 70, 193, 0.35);
  z-index: -1;
}

.nav-top {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 50;
  background: linear-gradient(180deg, rgba(26, 16, 51, 0.92) 0%, rgba(26, 16, 51, 0) 100%);
  backdrop-filter: blur(10px);
  transition: background 0.3s ease;
}

.nav-top.scrolled {
  background: rgba(26, 16, 51, 0.95);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.nav-links {
  display: none;
}

.nav-links.open {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background: rgba(26, 16, 51, 0.98);
  padding: 1rem;
  gap: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-links a {
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  color: var(--text-muted);
  transition: all 0.2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--secondary);
  background: rgba(192, 160, 98, 0.1);
}

@media (min-width: 768px) {
  .nav-links {
    display: flex;
    flex-direction: row;
    position: static;
    width: auto;
    background: transparent;
    padding: 0;
    gap: 0.25rem;
    border-top: none;
  }
}

.hero-split {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  padding-top: 5rem;
  padding-bottom: 3rem;
}

@media (min-width: 1024px) {
  .hero-split {
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
  }
}

.hero-full {
  min-height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  padding-top: 5rem;
}

.hero-full-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0.35;
}

.hero-full::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(26, 16, 51, 0.3) 0%, var(--bg-dark) 100%);
}

.hero-tri {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  padding-top: 6rem;
  padding-bottom: 4rem;
  gap: 2rem;
}

@media (min-width: 1024px) {
  .hero-tri {
    grid-template-columns: 1fr 1.1fr 1fr;
  }
}

.hero-top {
  padding-top: 7rem;
  padding-bottom: 2rem;
  text-align: center;
}

.scroll-strip {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 1rem;
  scroll-snap-type: x mandatory;
}

.scroll-strip > * {
  flex: 0 0 80%;
  scroll-snap-align: start;
}

@media (min-width: 768px) {
  .scroll-strip > * {
    flex: 0 0 45%;
  }
}

@media (min-width: 1024px) {
  .scroll-strip > * {
    flex: 0 0 30%;
  }
}

.guide-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

@media (min-width: 1024px) {
  .guide-layout {
    grid-template-columns: 280px 1fr;
  }
}

.toc {
  position: sticky;
  top: 6rem;
  height: fit-content;
  background: var(--bg-light);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1rem;
  padding: 1.25rem;
}

.toc a {
  display: block;
  padding: 0.5rem 0;
  color: var(--text-muted);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: color 0.2s ease;
}

.toc a:hover {
  color: var(--secondary);
}

.article-body {
  background: var(--bg-light);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.25rem;
  padding: 1.5rem;
}

@media (min-width: 768px) {
  .article-body {
    padding: 2.5rem;
  }
}

.article-body h2 {
  font-size: clamp(1.5rem, 4vw, 2rem);
  margin-top: 1.75rem;
  margin-bottom: 0.75rem;
  color: var(--secondary);
}

.article-body p {
  margin-bottom: 1rem;
  color: var(--text-muted);
}

.article-body ul {
  list-style: disc;
  padding-left: 1.5rem;
  margin-bottom: 1rem;
  color: var(--text-muted);
}

.article-body li {
  margin-bottom: 0.5rem;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  color: var(--text-muted);
  font-size: 0.875rem;
  margin-bottom: 1.5rem;
}

.breadcrumb a:hover {
  color: var(--secondary);
}

.footer-contact {
  background: linear-gradient(180deg, rgba(107, 70, 193, 0.12) 0%, rgba(26, 16, 51, 1) 100%);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.qr-card {
  background: var(--bg-light);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1rem;
  padding: 1rem;
  text-align: center;
  transition: all 0.3s ease;
}

.qr-card:hover {
  transform: translateY(-4px);
  border-color: rgba(192, 160, 98, 0.4);
}

.qr-card img {
  width: 100px;
  height: 100px;
  object-fit: contain;
  margin: 0 auto 0.75rem;
  border-radius: 0.5rem;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  background: rgba(107, 70, 193, 0.25);
  color: #E9D5FF;
  border: 1px solid rgba(107, 70, 193, 0.4);
}

.tag-gold {
  background: rgba(192, 160, 98, 0.15);
  color: var(--secondary);
  border-color: rgba(192, 160, 98, 0.35);
}

.tag-red {
  background: rgba(255, 107, 107, 0.15);
  color: #FECACA;
  border-color: rgba(255, 107, 107, 0.35);
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

.animate-float {
  animation: float 4s ease-in-out infinite;
}

.animate-glow {
  animation: glow 2.2s ease-in-out infinite;
}

.animate-pulse-slow {
  animation: pulse-slow 3s ease-in-out infinite;
}

.toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(120%);
  background: rgba(26, 16, 51, 0.96);
  color: var(--text-main);
  padding: 0.75rem 1.5rem;
  border-radius: 9999px;
  border: 1px solid var(--secondary);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  z-index: 100;
  transition: transform 0.3s ease;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
}

@keyframes drift {
  0% { background-position: 0 0, 0 0; }
  100% { background-position: 48px 96px, 96px 192px; }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

@keyframes float-orb {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(20px, -30px); }
}

@keyframes glow {
  0%, 100% { box-shadow: 0 0 12px rgba(107, 70, 193, 0.55); }
  50% { box-shadow: 0 0 28px rgba(255, 107, 107, 0.7); }
}

@keyframes pulse-slow {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.85; transform: scale(1.05); }
}
