:root {
  --bg-primary: #0d0b14;
  --bg-secondary: #161222;
  --bg-card: #1e1830;
  --text-primary: #f5f3ff;
  --text-secondary: #b8b0cc;
  --accent: #e84393;
  --accent-2: #9b59b6;
  --accent-gradient: linear-gradient(135deg, #e84393, #9b59b6, #6c5ce7);
  --border: rgba(255, 255, 255, 0.08);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.35);
  --radius: 12px;
  --max-width: 1200px;
  --header-height: 64px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.75;
  font-size: 16px;
  min-height: 100vh;
}

a {
  color: #d896ff;
  text-decoration: none;
  transition: color 0.2s;
}

a:hover {
  color: #f0b4ff;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(13, 11, 20, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.site-header .container {
  position: relative;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
}

.logo img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
}

.nav-desktop {
  display: flex;
  gap: 28px;
}

.nav-desktop a {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.nav-desktop a:hover,
.nav-desktop a.active {
  color: var(--text-primary);
}

.menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  position: relative;
  flex-shrink: 0;
}

.menu-toggle span {
  display: block;
  position: absolute;
  left: 8px;
  right: 8px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease, top 0.25s ease;
}

.menu-toggle span:nth-child(1) { top: 12px; }
.menu-toggle span:nth-child(2) { top: 19px; }
.menu-toggle span:nth-child(3) { top: 26px; }

.menu-toggle.open span:nth-child(1) {
  top: 19px;
  transform: rotate(45deg);
}

.menu-toggle.open span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.open span:nth-child(3) {
  top: 19px;
  transform: rotate(-45deg);
}

.nav-mobile {
  display: none;
  flex-direction: column;
}

.nav-mobile.open {
  display: flex;
}

.nav-mobile a {
  display: block;
  padding: 14px 4px;
  color: var(--text-primary);
  font-size: 1rem;
  border-bottom: 1px solid var(--border);
}

.nav-mobile a:last-child {
  border-bottom: none;
}

.nav-mobile a:hover,
.nav-mobile a.active {
  color: #f0b4ff;
}

.hero {
  padding: 60px 0 40px;
  background: radial-gradient(ellipse at 50% 0%, rgba(155, 89, 182, 0.15), transparent 60%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.hero h1 {
  font-size: 2.2rem;
  line-height: 1.3;
  margin-bottom: 16px;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-desc {
  color: var(--text-secondary);
  font-size: 1.05rem;
  margin-bottom: 24px;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.badge {
  display: inline-block;
  padding: 6px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary {
  background: var(--accent-gradient);
  color: #fff;
}

.btn-primary:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(232, 67, 147, 0.35);
}

.btn-outline {
  border: 1px solid var(--accent-2);
  color: #d896ff;
  margin-left: 12px;
}

.hero-img {
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

.section {
  padding: 56px 0;
}

.section-alt {
  background: var(--bg-secondary);
}

.section-title {
  font-size: 1.75rem;
  margin-bottom: 12px;
  text-align: center;
}

.section-subtitle {
  text-align: center;
  color: var(--text-secondary);
  margin-bottom: 40px;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: transform 0.2s;
}

.feature-card:hover {
  transform: translateY(-4px);
}

.feature-card h3 {
  font-size: 1.15rem;
  margin-bottom: 10px;
  color: #e8d5ff;
}

.feature-card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
}

.feature-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 16px;
}

.content-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
  margin-bottom: 48px;
}

.content-block.reverse {
  direction: rtl;
}

.content-block.reverse > * {
  direction: ltr;
}

.content-block img {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.content-block h3 {
  font-size: 1.35rem;
  margin-bottom: 14px;
  color: #e8d5ff;
}

.content-block p {
  color: var(--text-secondary);
  margin-bottom: 12px;
  font-size: 0.95rem;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.gallery-item {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  position: relative;
}

.gallery-item img {
  width: 100%;
  aspect-ratio: 9/16;
  object-fit: cover;
}

.gallery-item span {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 8px;
  background: linear-gradient(transparent, rgba(0,0,0,0.8));
  font-size: 0.8rem;
  text-align: center;
}

.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
}

.faq-question {
  width: 100%;
  padding: 18px 24px;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1rem;
  text-align: left;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.faq-answer {
  padding: 0 24px 18px;
  color: var(--text-secondary);
  font-size: 0.92rem;
  display: none;
}

.faq-item.open .faq-answer {
  display: block;
}

.page-hero {
  padding: 48px 0 32px;
  text-align: center;
  background: var(--bg-secondary);
}

.page-hero h1 {
  font-size: 2rem;
  margin-bottom: 8px;
}

.page-hero p {
  color: var(--text-secondary);
}

.article-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 40px 20px 60px;
}

.article-content h2 {
  font-size: 1.35rem;
  margin: 32px 0 14px;
  color: #e8d5ff;
}

.article-content h3 {
  font-size: 1.1rem;
  margin: 24px 0 10px;
  color: #d4c4f0;
}

.article-content p,
.article-content li {
  color: var(--text-secondary);
  margin-bottom: 12px;
  font-size: 0.95rem;
}

.article-content ul,
.article-content ol {
  padding-left: 24px;
  margin-bottom: 16px;
}

.article-content ul li,
.article-content ol li {
  margin-bottom: 8px;
}

.error-page {
  min-height: 70vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 20px;
}

.error-code {
  font-size: 6rem;
  font-weight: 800;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}

.error-page h1 {
  font-size: 1.5rem;
  margin: 16px 0 8px;
}

.error-page p {
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
  padding: 48px 0 24px;
  margin-top: 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 32px;
}

.footer-brand p {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-top: 12px;
}

.footer-col h4 {
  font-size: 0.95rem;
  margin-bottom: 14px;
  color: #e8d5ff;
}

.footer-col a {
  display: block;
  color: var(--text-secondary);
  font-size: 0.88rem;
  margin-bottom: 8px;
}

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 20px;
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.breadcrumb {
  padding: 16px 0;
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.breadcrumb a {
  color: var(--text-secondary);
}

.breadcrumb span {
  margin: 0 8px;
}

.toc {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 32px;
}

.toc h3 {
  font-size: 1rem;
  margin-bottom: 12px;
}

.toc ol {
  padding-left: 20px;
}

.toc li {
  margin-bottom: 6px;
  font-size: 0.9rem;
}

@media (max-width: 992px) {
  .hero-grid,
  .content-block {
    grid-template-columns: 1fr;
  }

  .content-block.reverse {
    direction: ltr;
  }

  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  html,
  body {
    overflow-x: hidden;
  }

  .nav-desktop {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .nav-mobile {
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    z-index: 1001;
    padding: 8px 20px 16px;
    border-top: 1px solid var(--border);
    background: rgba(13, 11, 20, 0.98);
    backdrop-filter: blur(12px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.35);
  }

  .nav-mobile.open {
    display: flex;
  }

  .hero h1 {
    font-size: 1.6rem;
  }

  .btn-outline {
    margin-left: 0;
    margin-top: 12px;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .footer-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 40px 0 24px;
  }

  .section {
    padding: 40px 0;
  }

  .page-inner .breadcrumb {
    padding-left: 16px;
    padding-right: 16px;
  }

  .page-inner .article-content {
    padding: 24px 16px 48px;
  }

  .page-inner .page-hero .container {
    padding-left: 16px;
    padding-right: 16px;
  }
}
