:root {
  --bg: #0a0a0c;
  --bg-soft: #141418;
  --bg-card: #1a1a20;
  --text: #f2f2f5;
  --text-muted: #a8a8b3;
  --accent: #e63b4d;
  --accent-soft: #ff6b7a;
  --line: rgba(255, 255, 255, 0.08);
  --gold: #f0c36a;
  --max: 1180px;
  --radius: 14px;
  --shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  --font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(230, 59, 77, 0.18), transparent 55%),
    radial-gradient(900px 420px at 90% 0%, rgba(240, 195, 106, 0.08), transparent 50%),
    linear-gradient(180deg, #0d0d12 0%, var(--bg) 40%, #09090b 100%);
  color: var(--text);
  line-height: 1.75;
  min-height: 100vh;
}

img {
  max-width: 100%;
  display: block;
  height: auto;
}

a {
  color: var(--accent-soft);
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover {
  color: #fff;
}

ul {
  list-style: none;
}

.container {
  width: min(100% - 32px, var(--max));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(16px);
  background: rgba(10, 10, 12, 0.86);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #fff;
  flex-shrink: 0;
}

.brand img {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  object-fit: cover;
}

.brand-text strong {
  display: block;
  font-size: 1.15rem;
  letter-spacing: 0.02em;
}

.brand-text span {
  display: block;
  font-size: 0.78rem;
  color: var(--text-muted);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  align-items: center;
  justify-content: flex-end;
}

.nav a {
  color: var(--text-muted);
  font-size: 0.95rem;
  padding: 6px 0;
  position: relative;
}

.nav a:hover,
.nav a.active {
  color: #fff;
}

.nav a.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: var(--accent);
  border-radius: 2px;
}

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  background: var(--bg-soft);
  color: #fff;
  border-radius: 10px;
  padding: 0;
  cursor: pointer;
}

.menu-toggle-icon {
  position: relative;
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  box-shadow: 0 -6px 0 currentColor, 0 6px 0 currentColor;
}

.hero {
  padding: 48px 0 28px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 28px;
  align-items: center;
}

.hero-copy h1 {
  font-size: clamp(1.8rem, 3.2vw, 2.7rem);
  line-height: 1.25;
  margin-bottom: 16px;
  letter-spacing: 0.01em;
}

.hero-copy .lead {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-bottom: 22px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 22px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 0.95rem;
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), #b91c2c);
  color: #fff;
}

.btn-primary:hover {
  color: #fff;
  opacity: 0.92;
}

.btn-ghost {
  background: transparent;
  border-color: var(--line);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: rgba(255, 255, 255, 0.25);
  color: #fff;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.hero-tags span,
.chip {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  color: var(--text-muted);
  font-size: 0.82rem;
}

.hero-visual {
  position: relative;
}

.hero-visual img {
  width: 100%;
  border-radius: 22px;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
  object-fit: cover;
  max-height: 520px;
}

.hero-badge {
  position: absolute;
  left: 16px;
  bottom: 16px;
  background: rgba(0, 0, 0, 0.72);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 0.86rem;
}

.section {
  padding: 42px 0;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.section-head h2 {
  font-size: clamp(1.35rem, 2.2vw, 1.85rem);
  margin-bottom: 6px;
}

.section-head p {
  color: var(--text-muted);
  max-width: 720px;
}

.section-link {
  color: var(--gold);
  white-space: nowrap;
  font-size: 0.92rem;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent), var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.card:hover {
  transform: translateY(-3px);
  border-color: rgba(230, 59, 77, 0.35);
}

.card img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: #111;
}

.card-body {
  padding: 14px;
}

.card-body h3 {
  font-size: 1rem;
  margin-bottom: 8px;
  line-height: 1.4;
}

.card-body p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.feature {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
}

.feature img {
  width: 100%;
  border-radius: 12px;
  margin-bottom: 14px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.feature h3 {
  margin-bottom: 8px;
  font-size: 1.08rem;
}

.feature p {
  color: var(--text-muted);
  font-size: 0.94rem;
}

.prose {
  background: rgba(20, 20, 24, 0.72);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 28px;
}

.prose h2,
.prose h3 {
  margin: 28px 0 12px;
  line-height: 1.35;
}

.prose h2:first-child,
.prose > h2:first-of-type {
  margin-top: 0;
}

.prose p {
  margin-bottom: 14px;
  color: #d8d8e0;
}

.prose ul,
.prose ol {
  margin: 0 0 16px 1.2em;
  color: #d8d8e0;
}

.prose li {
  margin-bottom: 8px;
  list-style: disc;
}

.prose ol li {
  list-style: decimal;
}

.toc {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px 16px;
  margin: 18px 0 8px;
  padding: 16px;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 12px;
  border: 1px solid var(--line);
}

.toc a {
  color: var(--text);
  font-size: 0.95rem;
}

.category-list {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.category-item {
  display: block;
  padding: 16px;
  border-radius: 12px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  color: var(--text);
}

.category-item strong {
  display: block;
  margin-bottom: 6px;
}

.category-item span {
  color: var(--text-muted);
  font-size: 0.88rem;
}

.duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.duo img {
  width: 100%;
  border-radius: 16px;
  border: 1px solid var(--line);
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.cta-band {
  margin: 20px 0 0;
  padding: 28px;
  border-radius: 18px;
  background:
    linear-gradient(120deg, rgba(230, 59, 77, 0.22), rgba(240, 195, 106, 0.08)),
    var(--bg-soft);
  border: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.cta-band h2 {
  margin-bottom: 8px;
}

.cta-band p {
  color: var(--text-muted);
}

.breadcrumb {
  padding: 18px 0 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

.breadcrumb a {
  color: var(--text-muted);
}

.page-hero {
  padding: 28px 0 10px;
}

.page-hero h1 {
  font-size: clamp(1.6rem, 2.8vw, 2.3rem);
  margin-bottom: 10px;
}

.page-hero p {
  color: var(--text-muted);
  max-width: 760px;
}

.site-footer {
  margin-top: 48px;
  border-top: 1px solid var(--line);
  background: #08080a;
  padding: 36px 0 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 24px;
  margin-bottom: 24px;
}

.site-footer h3 {
  margin-bottom: 12px;
  font-size: 1rem;
}

.site-footer p,
.site-footer a {
  color: var(--text-muted);
  font-size: 0.92rem;
}

.site-footer a {
  display: block;
  margin-bottom: 8px;
}

.site-footer a:hover {
  color: #fff;
}

.copyright {
  border-top: 1px solid var(--line);
  padding-top: 16px;
  color: #7d7d88;
  font-size: 0.85rem;
  text-align: center;
}

.error-wrap {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 60px 16px;
}

.error-wrap h1 {
  font-size: clamp(2.4rem, 6vw, 4rem);
  margin-bottom: 12px;
}

.error-wrap p {
  color: var(--text-muted);
  margin-bottom: 22px;
}

@media (max-width: 980px) {
  .hero-grid,
  .duo,
  .footer-grid,
  .feature-grid {
    grid-template-columns: 1fr;
  }

  .card-grid,
  .category-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .toc {
    grid-template-columns: 1fr;
  }

  .cta-band {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 720px) {
  .menu-toggle {
    display: inline-flex;
  }

  .nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    padding: 8px 0 4px;
  }

  .nav.open {
    display: flex;
  }

  .header-inner {
    flex-wrap: wrap;
  }

  .hero {
    padding-top: 28px;
  }

  .card-grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .card-body {
    padding: 10px;
  }

  .card-body h3 {
    font-size: 0.9rem;
  }

  .prose {
    padding: 18px;
  }

  .section {
    padding: 28px 0;
  }
}

@media (max-width: 420px) {
  .category-list {
    grid-template-columns: 1fr;
  }
}
