:root {
  --bg: #0b0b10;
  --bg-soft: #14141c;
  --bg-card: #1a1a24;
  --line: rgba(255, 255, 255, 0.08);
  --text: #f3f3f7;
  --muted: #a7a7b5;
  --orange: #ff8a2b;
  --pink: #ff4b8b;
  --magenta: #c2188c;
  --grad: linear-gradient(135deg, #ff8a2b 0%, #ff4b8b 55%, #c2188c 100%);
  --radius: 14px;
  --shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  --max: 1120px;
  --font: "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  background:
    radial-gradient(1200px 500px at 10% -10%, rgba(255, 75, 139, 0.18), transparent 60%),
    radial-gradient(900px 400px at 90% 0%, rgba(255, 138, 43, 0.14), transparent 55%),
    var(--bg);
  color: var(--text);
  line-height: 1.75;
  font-size: 16px;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: #ff8fb5;
  text-decoration: none;
  transition: color 0.2s ease, opacity 0.2s ease;
}

a:hover {
  color: #ffc2d6;
}

.container {
  width: min(100% - 32px, var(--max));
  margin-inline: auto;
}

.skip {
  position: absolute;
  left: -9999px;
}

.skip:focus {
  left: 16px;
  top: 16px;
  z-index: 1000;
  background: #fff;
  color: #111;
  padding: 8px 12px;
  border-radius: 8px;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(14px);
  background: rgba(11, 11, 16, 0.82);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  letter-spacing: 0.02em;
}

.brand img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
}

.brand span {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-size: 1.2rem;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  align-items: center;
}

.nav-links a {
  color: var(--muted);
  font-size: 0.95rem;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
}

.menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--line);
  background: var(--bg-soft);
  border-radius: 10px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--text);
}

/* Hero */
.hero {
  padding: 48px 0 28px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 36px;
  align-items: center;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 12px;
  color: #ffb0cb;
  font-size: 0.92rem;
  letter-spacing: 0.04em;
}

.hero h1 {
  margin: 0 0 14px;
  font-size: clamp(1.8rem, 3.4vw, 2.7rem);
  line-height: 1.25;
  font-weight: 800;
}

.hero-lead {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 36em;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 18px;
  border-radius: 999px;
  font-weight: 600;
  border: 1px solid transparent;
}

.btn-primary {
  background: var(--grad);
  color: #fff;
}

.btn-ghost {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
}

.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 0;
  margin: 0;
  list-style: none;
}

.hero-points li {
  font-size: 0.9rem;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 12px;
}

.hero-visual {
  position: relative;
}

.hero-visual img {
  width: 100%;
  border-radius: 22px;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
}

.hero-float {
  position: absolute;
  right: -8px;
  bottom: -12px;
  width: 42%;
  border-radius: 16px;
  border: 2px solid rgba(255, 255, 255, 0.12);
  box-shadow: var(--shadow);
}

/* Sections */
section {
  padding: 42px 0;
}

.section-head {
  margin-bottom: 22px;
}

.section-head h2 {
  margin: 0 0 8px;
  font-size: clamp(1.4rem, 2.4vw, 1.9rem);
}

.section-head p {
  margin: 0;
  color: var(--muted);
  max-width: 46em;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent 40%), var(--bg-card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.card img {
  width: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  object-position: top center;
  background: #111;
}

.card-body {
  padding: 14px 16px 18px;
}

.card-body h3 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.card-body p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
}

.shot-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.shot {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg-card);
}

.shot img {
  width: 100%;
  aspect-ratio: 9 / 16;
  object-fit: cover;
  object-position: top center;
}

.shot figcaption {
  padding: 10px 12px 12px;
  font-size: 0.88rem;
  color: var(--muted);
}

.feature-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  align-items: center;
  margin: 28px 0;
}

.feature-row.reverse {
  direction: rtl;
}

.feature-row.reverse > * {
  direction: ltr;
}

.feature-copy h3 {
  margin: 0 0 10px;
  font-size: 1.25rem;
}

.feature-copy p {
  margin: 0 0 10px;
  color: var(--muted);
}

.feature-media img {
  width: 100%;
  border-radius: 16px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.prose {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 24px 22px;
}

.prose h2,
.prose h3 {
  scroll-margin-top: 88px;
}

.prose h2 {
  margin: 1.4em 0 0.6em;
  font-size: 1.35rem;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.prose h2:first-child {
  margin-top: 0;
}

.prose h3 {
  margin: 1.15em 0 0.45em;
  font-size: 1.1rem;
}

.prose p,
.prose li {
  color: #cfcfd8;
}

.prose ul,
.prose ol {
  padding-left: 1.2em;
}

.prose li + li {
  margin-top: 0.35em;
}

.toc {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px 16px;
  margin: 0 0 22px;
  padding: 16px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 14px;
}

.toc a {
  color: #ffb0cb;
}

.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px 0 0;
}

.badge {
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 75, 139, 0.12);
  border: 1px solid rgba(255, 75, 139, 0.28);
  color: #ffd0e0;
  font-size: 0.88rem;
}

.cta-banner {
  margin: 18px 0 0;
  padding: 28px 24px;
  border-radius: 18px;
  background:
    linear-gradient(120deg, rgba(255, 138, 43, 0.18), rgba(255, 75, 139, 0.22), rgba(194, 24, 140, 0.18)),
    var(--bg-card);
  border: 1px solid var(--line);
  text-align: center;
}

.cta-banner h2 {
  margin: 0 0 8px;
}

.cta-banner p {
  margin: 0 0 16px;
  color: var(--muted);
}

/* Page header for inner pages */
.page-hero {
  padding: 36px 0 10px;
}

.page-hero h1 {
  margin: 0 0 10px;
  font-size: clamp(1.6rem, 3vw, 2.2rem);
}

.page-hero p {
  margin: 0;
  color: var(--muted);
  max-width: 48em;
}

.breadcrumbs {
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 0.9rem;
}

.breadcrumbs a {
  color: #ffb0cb;
}

/* Error pages */
.error-wrap {
  min-height: 70vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 48px 0;
}

.error-wrap h1 {
  margin: 0 0 8px;
  font-size: clamp(2.4rem, 6vw, 4rem);
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.error-wrap p {
  color: var(--muted);
  margin: 0 0 18px;
}

/* Footer */
.site-footer {
  margin-top: 40px;
  border-top: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.28);
  padding: 34px 0 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 24px;
}

.site-footer h3 {
  margin: 0 0 12px;
  font-size: 1rem;
}

.site-footer p,
.site-footer li {
  color: var(--muted);
  font-size: 0.92rem;
}

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer li + li {
  margin-top: 8px;
}

.footer-bottom {
  margin-top: 22px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  color: #8e8e9c;
  font-size: 0.86rem;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  justify-content: space-between;
}

/* Mobile bottom bar */
.mobile-bar {
  display: none;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 99;
  background: rgba(12, 12, 18, 0.94);
  border-top: 1px solid var(--line);
  backdrop-filter: blur(12px);
  padding: 8px 10px calc(8px + env(safe-area-inset-bottom));
}

.mobile-bar nav {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  text-align: center;
}

.mobile-bar a {
  color: var(--muted);
  font-size: 0.72rem;
  padding: 6px 2px;
}

.mobile-bar a.active,
.mobile-bar a:hover {
  color: #ff8fb5;
}

.mobile-bar strong {
  display: block;
  font-size: 0.95rem;
  margin-bottom: 2px;
}

@media (max-width: 980px) {
  .hero-grid,
  .feature-row,
  .feature-row.reverse,
  .footer-grid {
    grid-template-columns: 1fr;
    direction: ltr;
  }

  .card-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .shot-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .hero-float {
    width: 38%;
    right: 8px;
    bottom: 8px;
  }
}

@media (max-width: 720px) {
  .menu-toggle {
    display: inline-flex;
    flex-direction: column;
  }

  .nav-links {
    display: none;
    position: absolute;
    left: 16px;
    right: 16px;
    top: 68px;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: #16161f;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 8px;
    box-shadow: var(--shadow);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 12px 14px;
    border-radius: 10px;
  }

  .nav-links a:hover {
    background: rgba(255, 255, 255, 0.04);
  }

  .hero {
    padding-top: 28px;
  }

  .card-grid,
  .shot-grid,
  .toc {
    grid-template-columns: 1fr 1fr;
  }

  .prose {
    padding: 18px 14px;
  }

  body {
    padding-bottom: 72px;
  }

  .mobile-bar {
    display: block;
  }

  .hero-float {
    display: none;
  }
}

@media (max-width: 480px) {
  .card-grid,
  .shot-grid {
    grid-template-columns: 1fr;
  }

  .toc {
    grid-template-columns: 1fr;
  }
}
