:root {
  color-scheme: dark;
  --bg: #050812;
  --panel: rgba(255, 255, 255, 0.065);
  --panel-strong: rgba(255, 255, 255, 0.11);
  --text: #f6f8ff;
  --muted: #aab4ca;
  --muted-2: #79859d;
  --line: rgba(255, 255, 255, 0.14);
  --blue: #60a5fa;
  --cyan: #5eead4;
  --violet: #a78bfa;
  --green: #86efac;
  --orange: #fbbf24;
  --shadow: 0 24px 90px rgba(0, 0, 0, 0.42);
  --radius: 28px;
  --nav-bg: rgba(5, 8, 18, 0.72);
  --table-sticky-bg: #111827;
  --table-group-bg: #182235;
  --highlight-bg: rgba(94, 234, 212, 0.07);
  --highlight-first-bg: #123031;
  --body-text: #d8e0f0;
  --dek-text: #dce5f6;
  --surface-soft: rgba(255, 255, 255, 0.055);
  --surface-strong: linear-gradient(180deg, rgba(255,255,255,0.13), rgba(255,255,255,0.06));
  --hero-card-bg: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0.055));
  --media-bg: rgba(255,255,255,0.06);
  --media-border: rgba(255,255,255,0.08);
  --table-row-line: rgba(255,255,255,0.09);
  --table-heading: #e8efff;
  --table-text: #dbe4f5;
  --quote-text: #f6fbff;
  --panel-shadow: rgba(0,0,0,0.22);
  --body-bg:
    radial-gradient(circle at 15% -10%, rgba(94, 234, 212, 0.24), transparent 30%),
    radial-gradient(circle at 90% 5%, rgba(96, 165, 250, 0.25), transparent 32%),
    radial-gradient(circle at 55% 38%, rgba(167, 139, 250, 0.12), transparent 38%),
    linear-gradient(180deg, #050812 0%, #08101f 44%, #03050c 100%);
  --primary-button-text: #03101d;
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: #f7f9fc;
  --panel: rgba(255, 255, 255, 0.84);
  --panel-strong: rgba(255, 255, 255, 0.96);
  --text: #102033;
  --muted: #536277;
  --muted-2: #7a8797;
  --line: rgba(15, 23, 42, 0.12);
  --blue: #315eea;
  --cyan: #0f9f91;
  --violet: #7652d6;
  --green: #138a52;
  --orange: #b77905;
  --shadow: 0 24px 70px rgba(15, 23, 42, 0.13);
  --nav-bg: rgba(247, 249, 252, 0.8);
  --table-sticky-bg: #eef4fb;
  --table-group-bg: #e1eaf5;
  --highlight-bg: rgba(15, 159, 145, 0.1);
  --highlight-first-bg: #dff8f3;
  --body-text: #35445a;
  --dek-text: #45566e;
  --surface-soft: rgba(255, 255, 255, 0.68);
  --surface-strong: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(255,255,255,0.72));
  --hero-card-bg: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(255,255,255,0.72));
  --media-bg: rgba(15, 23, 42, 0.04);
  --media-border: rgba(15, 23, 42, 0.10);
  --table-row-line: rgba(15, 23, 42, 0.09);
  --table-heading: #24334a;
  --table-text: #41516a;
  --quote-text: #102033;
  --panel-shadow: rgba(15,23,42,0.10);
  --body-bg:
    radial-gradient(circle at 15% -10%, rgba(15, 159, 145, 0.18), transparent 30%),
    radial-gradient(circle at 90% 5%, rgba(49, 94, 234, 0.15), transparent 32%),
    radial-gradient(circle at 55% 38%, rgba(118, 82, 214, 0.10), transparent 38%),
    linear-gradient(180deg, #f7f9fc 0%, #eef4fb 44%, #ffffff 100%);
  --primary-button-text: #ffffff;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--body-bg);
  line-height: 1.62;
}

html[lang="zh-CN"] body {
  font-family: "PingFang SC", "Noto Sans CJK SC", "Source Han Sans SC", "Microsoft YaHei", "Droid Sans Fallback", Inter, ui-sans-serif, system-ui, sans-serif;
  line-height: 1.75;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
button { font-family: inherit; }
code { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; font-size: 0.92em; color: var(--cyan); }
.page { overflow: hidden; }
.container { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
section[id] { scroll-margin-top: 86px; }

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 100;
  transform: translateY(-160%);
  padding: 10px 14px;
  border-radius: 12px;
  color: var(--primary-button-text);
  background: var(--cyan);
  font-weight: 800;
}
.skip-link:focus { transform: translateY(0); }
a:focus-visible, button:focus-visible, [tabindex="0"]:focus-visible {
  outline: 3px solid var(--cyan);
  outline-offset: 4px;
}

header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(18px);
  background: var(--nav-bg);
  border-bottom: 1px solid var(--line);
}

.nav {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand { display: flex; align-items: center; gap: 12px; font-weight: 750; letter-spacing: -0.02em; white-space: nowrap; }
.brand img { width: 34px; height: 34px; object-fit: contain; }
.brand .logo-light { display: none; }
html[data-theme="light"] .brand .logo-dark { display: none; }
html[data-theme="light"] .brand .logo-light { display: block; }
.nav-links { display: flex; align-items: center; justify-content: flex-end; gap: clamp(12px, 1.7vw, 22px); color: var(--muted); font-size: 14px; }
.nav-links a:hover { color: var(--text); }
.language-switch {
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text);
  background: var(--panel);
  font-weight: 750;
}
.language-switch:hover { border-color: rgba(94, 234, 212, 0.42); color: var(--cyan); }
.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 9px 12px;
  color: var(--text);
  background: var(--panel);
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}
.theme-toggle:hover { border-color: rgba(94, 234, 212, 0.42); color: var(--cyan); }
.theme-toggle .theme-icon { width: 16px; height: 16px; }
html[data-theme="light"] .theme-toggle .sun { display: none; }
html:not([data-theme="light"]) .theme-toggle .moon { display: none; }

.hero { padding: 94px 0 48px; position: relative; }
.hero-grid { display: grid; grid-template-columns: 1.08fr 0.92fr; gap: 42px; align-items: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--cyan); background: rgba(94, 234, 212, 0.08); font-size: 13px; font-weight: 700; }
.hero h1 { margin: 24px 0 18px; font-size: clamp(48px, 8vw, 92px); line-height: 0.92; letter-spacing: -0.075em; text-wrap: balance; }
.hero h1 span { color: transparent; background: linear-gradient(120deg, var(--cyan), var(--blue), var(--violet)); -webkit-background-clip: text; background-clip: text; }
.dek { font-size: clamp(19px, 2.2vw, 25px); color: var(--dek-text); max-width: 780px; margin: 0 0 30px; letter-spacing: -0.02em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin: 28px 0; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 18px; border-radius: 999px; font-weight: 750; border: 1px solid var(--line); background: var(--panel); }
.button:hover { border-color: rgba(94, 234, 212, 0.42); transform: translateY(-1px); }
.button.primary { background: linear-gradient(135deg, #5eead4, #60a5fa); color: var(--primary-button-text); border: 0; }
.button.download { border-color: rgba(94, 234, 212, 0.36); color: var(--cyan); }
.meta { display: flex; flex-wrap: wrap; gap: 8px 16px; color: var(--muted); font-size: 14px; }
.meta span { display: inline-flex; align-items: center; }
.meta span + span::before { content: "·"; margin-right: 16px; color: var(--muted-2); }

.hero-card { border: 1px solid var(--line); background: var(--hero-card-bg); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.hero-card img { border-radius: 20px; background: var(--media-bg); }
.caption { margin: 12px 4px 0; color: var(--muted); font-size: 13px; line-height: 1.55; }

section { padding: 68px 0; }
.section-head { max-width: 820px; margin-bottom: 32px; }
.section-head.spaced { margin-top: 48px; }
.kicker { color: var(--cyan); font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; font-size: 12px; }
h2 { margin: 10px 0 14px; font-size: clamp(34px, 4vw, 56px); line-height: 1.02; letter-spacing: -0.055em; text-wrap: balance; }
h3 { margin: 0 0 10px; font-size: 22px; line-height: 1.18; letter-spacing: -0.025em; text-wrap: balance; }
p { color: var(--body-text); margin: 0 0 16px; }
.muted { color: var(--muted); }

html[lang="zh-CN"] .hero h1 { font-size: clamp(44px, 6.7vw, 82px); line-height: 1.04; letter-spacing: -0.045em; }
html[lang="zh-CN"] .dek { line-height: 1.65; letter-spacing: -0.01em; }
html[lang="zh-CN"] h2 { line-height: 1.14; letter-spacing: -0.035em; }
html[lang="zh-CN"] h3 { line-height: 1.35; letter-spacing: -0.015em; }
html[lang="zh-CN"] p { line-height: 1.82; }
html[lang="zh-CN"] .kicker { letter-spacing: 0.08em; }

.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 28px; }
.metric { border: 1px solid var(--line); background: var(--panel); border-radius: 22px; padding: 22px; min-height: 148px; }
.metric .value { font-size: 40px; line-height: 1; font-weight: 850; letter-spacing: -0.05em; color: var(--text); }
.metric .label { margin-top: 12px; color: var(--muted); font-size: 14px; }
.metric .tag { display: inline-block; margin-top: 14px; color: var(--cyan); font-size: 12px; font-weight: 800; }

.two-col { display: grid; grid-template-columns: 0.92fr 1.08fr; gap: 28px; align-items: start; }
.panel { border: 1px solid var(--line); background: var(--panel); border-radius: var(--radius); padding: 28px; box-shadow: 0 16px 70px var(--panel-shadow); }
.panel.strong { background: var(--surface-strong); }
.panel img { border-radius: 18px; border: 1px solid var(--media-border); background: var(--media-bg); }

.loop { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; margin-top: 28px; }
.step { position: relative; padding: 20px; border-radius: 20px; border: 1px solid var(--line); background: var(--surface-soft); min-height: 172px; }
.step b { display: block; margin-bottom: 10px; color: var(--text); }
.step span { color: var(--muted); font-size: 14px; }
.step .num { color: var(--cyan); font-weight: 850; margin-bottom: 16px; }

.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.case-card { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface-soft); }
.case-card img { width: 100%; height: auto; background: #fff; }
.case-card div { padding: 22px; }
.case-card small { display: inline-flex; margin-bottom: 10px; color: var(--green); font-weight: 850; letter-spacing: 0.08em; text-transform: uppercase; }

.table-wrap { overflow-x: auto; padding: 0; border: 1px solid var(--line); border-radius: 24px; background: var(--surface-soft); }
table { width: 100%; border-collapse: collapse; min-width: 900px; font-size: 14px; }
th, td { padding: 14px 16px; border-bottom: 1px solid var(--table-row-line); text-align: right; white-space: nowrap; }
th:first-child, td:first-child { text-align: left; position: sticky; left: 0; z-index: 1; background: var(--table-sticky-bg); }
th { color: var(--table-heading); font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; }
td { color: var(--table-text); }
tr:last-child td { border-bottom: 0; }
.group-row th { position: static; text-align: left; padding: 11px 16px; color: var(--cyan); background: var(--table-group-bg); border-bottom-color: var(--line); font-size: 11px; letter-spacing: 0.08em; }
.highlight td { color: var(--text); font-weight: 780; background: var(--highlight-bg); }
.highlight td:first-child { background: var(--highlight-first-bg); }

.quote { margin: 34px 0; padding: 28px; border-left: 4px solid var(--cyan); border-radius: 0 24px 24px 0; background: rgba(94,234,212,0.08); font-size: 23px; line-height: 1.35; letter-spacing: -0.025em; color: var(--quote-text); }
html[lang="zh-CN"] .quote { line-height: 1.6; letter-spacing: -0.015em; }
.principles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.principles.spaced { margin-top: 18px; }
.principle { border: 1px solid var(--line); border-radius: 24px; padding: 24px; background: var(--surface-soft); }
.principle b { color: var(--cyan); }
.limits-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 20px; }
.limit { border: 1px solid var(--line); border-radius: 20px; padding: 22px; background: var(--surface-soft); }
.limit h3 { color: var(--text); font-size: 19px; }
.limit p { margin-bottom: 0; }
.limits-section { margin-top: 34px; }

.footer { padding: 54px 0 80px; color: var(--muted); border-top: 1px solid var(--line); }
.footer-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.reader-note { border: 1px dashed rgba(94,234,212,0.5); background: rgba(94,234,212,0.075); border-radius: 24px; padding: 22px; }
.footer-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.footer-intro { margin-top: 16px; }

@media (max-width: 920px) {
  .hero-grid, .two-col, .footer-grid { grid-template-columns: 1fr; }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .loop { grid-template-columns: 1fr; }
  .cards, .principles { grid-template-columns: 1fr; }
  .section-link { display: none; }
  .hero { padding-top: 60px; }
}

@media (max-width: 680px) {
  .back-link { display: none; }
  .nav { gap: 14px; }
  .nav-links { gap: 8px; }
}

@media (max-width: 560px) {
  .container { width: min(100% - 24px, 1180px); }
  .nav { min-height: 66px; }
  .brand { gap: 8px; font-size: 14px; }
  .brand img { width: 30px; height: 30px; }
  .language-switch { padding: 6px 9px; font-size: 13px; }
  .theme-toggle { gap: 6px; padding: 8px 10px; }
  .metrics, .limits-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 44px; }
  html[lang="zh-CN"] .hero h1 { font-size: 42px; }
  .hero { padding: 52px 0 34px; }
  section { padding: 52px 0; }
  .panel, .metric, .step, .principle, .limit { padding: 20px; }
  .quote { padding: 22px; font-size: 20px; }
  .meta span + span::before { display: none; }
  .meta { flex-direction: column; gap: 4px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .button:hover { transform: none; }
}
