/* ============================================================
   抖音知识库 · 站点样式
   设计系统：纸感浅色 / 墨色深色双主题，抖音红作强调色
   ============================================================ */

/* ---------- tokens ---------- */
:root {
  --bg: #fbf9f6;
  --bg-alt: #f3efe8;
  --surface: #ffffff;
  --surface-2: #fdfcfa;
  --ink: #17181c;
  --ink-2: #4a4f5e;
  --muted: #7b8291;
  --line: rgba(23, 24, 28, 0.10);
  --line-strong: rgba(23, 24, 28, 0.18);
  --accent: #fe2c55;
  --accent-soft: rgba(254, 44, 85, 0.10);
  --accent-line: rgba(254, 44, 85, 0.28);
  --cyan: #0aa8a0;
  --cyan-soft: rgba(10, 168, 160, 0.10);
  --code-bg: #15171e;
  --code-ink: #d7dbe6;
  --shadow-sm: 0 1px 2px rgba(23, 24, 28, .05), 0 2px 8px rgba(23, 24, 28, .04);
  --shadow-md: 0 8px 24px rgba(23, 24, 28, .07), 0 2px 6px rgba(23, 24, 28, .05);
  --shadow-lg: 0 30px 70px -20px rgba(23, 24, 28, .22), 0 10px 24px rgba(23, 24, 28, .06);
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 22px;
  --font: "Inter", "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  --mono: "JetBrains Mono", "Cascadia Code", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --max: 1160px;
}

html[data-theme="dark"] {
  --bg: #0b0d12;
  --bg-alt: #0f1219;
  --surface: #141822;
  --surface-2: #171c27;
  --ink: #eceef4;
  --ink-2: #b6bccb;
  --muted: #878fa1;
  --line: rgba(255, 255, 255, 0.10);
  --line-strong: rgba(255, 255, 255, 0.18);
  --accent: #ff4569;
  --accent-soft: rgba(255, 69, 105, 0.14);
  --accent-line: rgba(255, 69, 105, 0.34);
  --cyan: #35d0c6;
  --cyan-soft: rgba(53, 208, 198, 0.12);
  --code-bg: #080a0f;
  --code-ink: #cfd5e2;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4);
  --shadow-md: 0 10px 30px rgba(0, 0, 0, .45);
  --shadow-lg: 0 40px 90px -30px rgba(0, 0, 0, .8), 0 12px 30px rgba(0, 0, 0, .35);
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  transition: background-color .35s ease, color .35s ease;
}

::selection { background: var(--accent); color: #fff; }

a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; line-height: 1.18; letter-spacing: -0.02em; font-weight: 680; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
img, svg { display: block; max-width: 100%; }
code { font-family: var(--mono); font-size: .9em; }
button { font: inherit; color: inherit; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.skip {
  position: absolute; left: 16px; top: -60px; z-index: 200;
  background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 8px;
  transition: top .2s ease;
}
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 28px; }

/* ---------- nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease, background-color .3s ease;
}
.nav.is-stuck { border-bottom-color: var(--line); }

.nav__inner {
  max-width: var(--max); margin: 0 auto; padding: 0 28px;
  height: 64px; display: flex; align-items: center; gap: 24px;
}

.brand { display: inline-flex; align-items: center; gap: 9px; font-weight: 700; letter-spacing: -0.01em; }
.brand__mark {
  width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
  background: var(--ink); color: var(--bg); transition: transform .3s ease;
}
.brand:hover .brand__mark { transform: rotate(-8deg) scale(1.05); }
.brand__text { font-size: 15px; }
.brand__ver {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .04em;
  padding: 2px 6px; border-radius: 5px; color: var(--accent);
  background: var(--accent-soft); border: 1px solid var(--accent-line);
}

.nav__links { display: flex; gap: 26px; margin-left: 12px; }
.nav__links a {
  font-size: 14px; color: var(--ink-2); position: relative; padding: 6px 0;
  transition: color .2s ease;
}
.nav__links a::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: 0; height: 1.5px;
  background: var(--accent); transition: right .25s ease;
}
.nav__links a:hover { color: var(--ink); }
.nav__links a:hover::after { right: 0; }

.nav__actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }

.icon-btn {
  width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center;
  background: transparent; border: 1px solid var(--line); cursor: pointer;
  color: var(--ink-2); transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.icon-btn:hover { background: var(--surface); color: var(--ink); border-color: var(--line-strong); }
.icon-btn .i-moon { display: none; }
html[data-theme="dark"] .icon-btn .i-sun { display: none; }
html[data-theme="dark"] .icon-btn .i-moon { display: block; }

.nav__progress {
  position: absolute; left: 0; bottom: -1px; height: 2px; width: 0;
  background: linear-gradient(90deg, var(--accent), var(--cyan));
  transition: width .12s linear;
}

/* ---------- buttons ---------- */
.btn {
  --pad: 13px 22px;
  display: inline-flex; align-items: center; gap: 10px;
  padding: var(--pad); border-radius: 999px;
  font-size: 15px; font-weight: 600; letter-spacing: -0.01em;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .2s ease, box-shadow .25s ease, background .2s ease, color .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px) scale(.99); }

.btn--primary {
  background: var(--accent); color: #fff;
  box-shadow: 0 8px 22px -8px rgba(254, 44, 85, .6);
}
.btn--primary:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -10px rgba(254, 44, 85, .65); }

.btn--ghost {
  background: transparent; color: var(--ink); border-color: var(--line-strong);
}
.btn--ghost:hover { background: var(--surface); border-color: var(--ink); transform: translateY(-2px); }

.btn--sm { --pad: 9px 18px; font-size: 14px; }
.btn--block { width: 100%; justify-content: center; }
.btn__meta {
  font-family: var(--mono); font-size: 11px; font-weight: 500; opacity: .8;
  padding-left: 10px; border-left: 1px solid rgba(255, 255, 255, .35);
}

/* ---------- hero ---------- */
.hero { position: relative; padding: clamp(120px, 15vw, 176px) 0 clamp(48px, 6vw, 72px); overflow: hidden; }
.hero__glow {
  position: absolute; z-index: 0; inset: -30% -10% auto -10%; height: 900px;
  background:
    radial-gradient(46% 42% at 22% 18%, var(--accent-soft), transparent 70%),
    radial-gradient(40% 38% at 78% 12%, var(--cyan-soft), transparent 70%);
  filter: blur(10px); pointer-events: none;
}
.hero__grid {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1.02fr .98fr; gap: clamp(32px, 5vw, 64px); align-items: center;
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--mono); font-size: 11.5px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--ink-2); margin-bottom: 18px;
}
.eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-soft);
}

.hero h1 {
  font-size: clamp(2.05rem, 3.9vw, 3.3rem);
  font-weight: 720; letter-spacing: -0.035em; line-height: 1.12;
  margin-bottom: 22px; text-wrap: balance;
}
.hl {
  position: relative; color: var(--accent); white-space: nowrap;
}
.hl::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 6px;
  background: var(--accent-soft); border-radius: 3px; z-index: -1;
}

.lede { font-size: clamp(1rem, 1.25vw, 1.125rem); color: var(--ink-2); max-width: 34em; margin-bottom: 30px; }

.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 26px; }

.hero__meta { display: flex; flex-wrap: wrap; gap: 8px 20px; list-style: none; }
.hero__meta li {
  font-size: 13px; color: var(--muted); display: inline-flex; align-items: center; gap: 7px;
}
.hero__meta li::before {
  content: ""; width: 5px; height: 5px; border-radius: 50%;
  background: var(--cyan); flex: none;
}

/* ---------- app mock ---------- */
.hero__visual { position: relative; }

.mock {
  position: relative; border-radius: 18px; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
  transform: perspective(1400px) rotateY(-5deg) rotateX(2deg);
  transition: transform .6s cubic-bezier(.2, .8, .2, 1);
}
.mock:hover { transform: perspective(1400px) rotateY(-2deg) rotateX(0deg) translateY(-4px); }

.mock__bar {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 14px; border-bottom: 1px solid var(--line);
  background: var(--surface-2);
}
.mock__dots { display: inline-flex; gap: 6px; }
.mock__dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--line-strong); }
.mock__dots i:nth-child(1) { background: #ff5f57; }
.mock__dots i:nth-child(2) { background: #febc2e; }
.mock__dots i:nth-child(3) { background: #28c840; }
.mock__title { font-size: 11.5px; color: var(--muted); font-family: var(--mono); }

.mock__body { display: grid; grid-template-columns: 158px 1fr; min-height: 342px; }

.mock__side {
  border-right: 1px solid var(--line); padding: 14px 12px;
  background: var(--surface-2);
  display: flex; flex-direction: column; gap: 10px;
}
.mock__side-label {
  font-family: var(--mono); font-size: 9.5px; letter-spacing: .16em; color: var(--muted);
}
.mock__tree { display: flex; flex-direction: column; gap: 2px; font-size: 12px; }
.t { padding: 4px 8px; border-radius: 6px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t--l1 { padding-left: 18px; font-size: 11.5px; color: var(--muted); }
.t--active { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.mock__side-note {
  margin-top: auto; font-family: var(--mono); font-size: 10px; color: var(--muted);
  border-top: 1px dashed var(--line); padding-top: 8px;
}

.mock__doc { padding: 20px 22px 22px; min-width: 0; }
.mock__tag {
  display: inline-block; font-family: var(--mono); font-size: 10px; letter-spacing: .04em;
  color: var(--accent); background: var(--accent-soft);
  padding: 2px 8px; border-radius: 5px; margin-bottom: 10px;
}
.mock__doc-head h3 { font-size: 16px; font-weight: 680; margin-bottom: 4px; }
.mock__src { font-size: 11px; color: var(--muted); }
.mock__rule { height: 1px; background: var(--line); margin: 12px 0 10px; }
.mock__h { font-size: 10px; font-family: var(--mono); letter-spacing: .1em; color: var(--muted); margin-bottom: 3px; }
.mock__p { font-size: 12.5px; color: var(--ink-2); margin-bottom: 10px; }
.mock__list { list-style: none; margin-bottom: 10px; }
.mock__list li {
  position: relative; padding-left: 12px; font-size: 12.5px; color: var(--ink-2); line-height: 1.6;
}
.mock__list li::before {
  content: ""; position: absolute; left: 0; top: .62em; width: 4px; height: 4px;
  border-radius: 50%; background: var(--accent);
}
.mock__fold {
  margin-top: 6px; font-size: 11px; color: var(--muted);
  padding: 7px 10px; border: 1px dashed var(--line-strong); border-radius: 7px;
}

.mock__status {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 14px; border-top: 1px solid var(--line);
  background: var(--surface-2); font-size: 11px; color: var(--muted); font-family: var(--mono);
}
.pulse {
  width: 7px; height: 7px; border-radius: 50%; background: var(--cyan); flex: none;
  box-shadow: 0 0 0 0 var(--cyan);
  animation: pulse 2.2s ease-out infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(10, 168, 160, .5); }
  70% { box-shadow: 0 0 0 8px rgba(10, 168, 160, 0); }
  100% { box-shadow: 0 0 0 0 rgba(10, 168, 160, 0); }
}
.mock__status-bar {
  flex: 1; height: 4px; border-radius: 2px; background: var(--line); overflow: hidden;
}
.mock__status-bar i { display: block; height: 100%; border-radius: 2px; background: linear-gradient(90deg, var(--accent), var(--cyan)); }
.mock__cpu { color: var(--ink-2); }

.chip {
  position: absolute; z-index: 2;
  font-size: 11.5px; font-weight: 550; padding: 7px 12px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line);
  box-shadow: var(--shadow-md); color: var(--ink-2);
  animation: float 7s ease-in-out infinite;
}
.chip--a { top: -24px; left: 7%; animation-delay: -1s; }
.chip--b { bottom: -36px; right: 5%; animation-delay: -3s; }

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

/* ---------- stats ---------- */
.stats {
  margin-top: clamp(44px, 6vw, 68px);
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.stat { padding: 22px 8px 20px; text-align: center; position: relative; }
.stat + .stat::before {
  content: ""; position: absolute; left: 0; top: 26%; bottom: 26%; width: 1px; background: var(--line);
}
.stat b {
  display: block; font-size: clamp(1.7rem, 3vw, 2.3rem); font-weight: 700; letter-spacing: -0.03em;
  line-height: 1.1; margin-bottom: 4px;
}
.stat span { font-size: 12.5px; color: var(--muted); }

/* ---------- sections ---------- */
.section { padding: clamp(72px, 9vw, 120px) 0; position: relative; }
.section--alt { background: var(--bg-alt); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.sec-head { max-width: 46em; margin-bottom: clamp(36px, 5vw, 56px); }
.sec-head h2 { font-size: clamp(1.6rem, 3.2vw, 2.4rem); letter-spacing: -0.03em; margin-bottom: 12px; }
.sec-sub { color: var(--ink-2); font-size: clamp(.95rem, 1.2vw, 1.05rem); }

/* ---------- cards ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }

.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 28px 26px 24px; box-shadow: var(--shadow-sm);
  transition: transform .3s cubic-bezier(.2,.8,.2,1), box-shadow .3s ease, border-color .3s ease;
}
.card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); border-color: var(--line-strong); }
.card__icon {
  width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent); margin-bottom: 18px;
  border: 1px solid var(--accent-line);
}
.card h3 { font-size: 1.06rem; margin-bottom: 10px; }
.card p { font-size: 14px; color: var(--ink-2); }
.card__note {
  margin-top: 14px; padding-top: 12px; border-top: 1px dashed var(--line);
  font-size: 12.5px !important; color: var(--muted) !important;
}

/* ---------- pipeline ---------- */
.pipe {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px;
  position: relative; margin-bottom: 22px;
}
.pipe::before {
  content: ""; position: absolute; left: 3%; right: 3%; top: 26px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--line-strong), transparent);
}
.pipe__step {
  position: relative; z-index: 1;
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  padding: 12px 6px 14px; border: 1px solid transparent; border-radius: var(--r-md);
  background: transparent; cursor: pointer; color: var(--muted);
  transition: color .2s ease, background .2s ease, border-color .2s ease, transform .2s ease;
}
.pipe__step:hover { color: var(--ink); transform: translateY(-2px); }
.pipe__num {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  font-family: var(--mono); font-size: 12.5px; font-weight: 600;
  background: var(--surface); border: 1px solid var(--line-strong); color: var(--ink-2);
  transition: all .25s ease;
}
.pipe__name { font-size: 13px; font-weight: 550; }
.pipe__step.is-active { color: var(--ink); }
.pipe__step.is-active .pipe__num {
  background: var(--accent); border-color: var(--accent); color: #fff;
  box-shadow: 0 8px 20px -8px rgba(254, 44, 85, .7);
  transform: scale(1.05);
}
.pipe__step.is-active .pipe__name { color: var(--accent); font-weight: 650; }

.pipe__panel {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: 28px 30px; box-shadow: var(--shadow-sm);
  min-height: 236px;
}
.pipe__panel-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 10px; }
.pipe__panel-head h3 { font-size: 1.18rem; }
.pipe__badge {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .04em;
  padding: 3px 9px; border-radius: 6px; color: var(--cyan);
  background: var(--cyan-soft); border: 1px solid rgba(10, 168, 160, .3);
  white-space: nowrap;
}
.pipe__desc { color: var(--ink-2); font-size: 14.5px; margin-bottom: 16px; max-width: 52em; }
.pipe__points { list-style: none; display: grid; gap: 8px; margin-bottom: 14px; }
.pipe__points li {
  position: relative; padding-left: 20px; font-size: 14px; color: var(--ink-2);
}
.pipe__points li::before {
  content: "→"; position: absolute; left: 0; top: 0; color: var(--accent); font-size: 13px;
}
.pipe__warn {
  font-size: 12.5px; color: var(--muted); padding-left: 12px;
  border-left: 2px solid var(--accent-line);
}

/* ---------- mechanics ---------- */
.mech {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-md);
  padding: 24px 24px 20px; transition: border-color .25s ease, transform .25s ease, box-shadow .25s ease;
}
.mech:hover { border-color: var(--line-strong); transform: translateY(-3px); box-shadow: var(--shadow-sm); }
.mech h3 { font-size: 1rem; display: flex; align-items: baseline; gap: 10px; margin-bottom: 10px; }
.mech__i {
  font-family: var(--mono); font-size: 11px; color: var(--accent); font-weight: 600;
  letter-spacing: .04em;
}
.mech p { font-size: 13.8px; color: var(--ink-2); }
.mech__foot {
  margin-top: 12px; font-size: 12.3px !important; color: var(--muted) !important;
}

.quote {
  margin-top: 34px; padding: 24px 28px;
  border-left: 3px solid var(--accent); background: var(--surface);
  border-radius: 0 var(--r-md) var(--r-md) 0;
}
.quote p { font-size: clamp(1rem, 1.6vw, 1.18rem); letter-spacing: -0.01em; margin-bottom: 6px; }
.quote span { font-size: 12.5px; color: var(--muted); }

/* ---------- vault split ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }

.code-card {
  background: var(--code-bg); border-radius: var(--r-lg); overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .08); box-shadow: var(--shadow-md);
}
.code-card__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 14px; border-bottom: 1px solid rgba(255, 255, 255, .07);
  font-family: var(--mono); font-size: 11px; color: #8b93a7; letter-spacing: .04em;
}
.code-card pre {
  margin: 0; padding: 18px 18px 22px; overflow-x: auto;
  font-family: var(--mono); font-size: 12.6px; line-height: 1.75; color: var(--code-ink);
  tab-size: 2;
}

.copy {
  background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .1);
  color: #aab2c4; font-size: 11px; padding: 3px 9px; border-radius: 6px; cursor: pointer;
  transition: background .2s ease, color .2s ease;
}
.copy:hover { background: rgba(255, 255, 255, .14); color: #fff; }
.copy.is-done { color: #35d0c6; border-color: rgba(53, 208, 198, .4); }
.copy--light {
  background: var(--surface); border-color: var(--line); color: var(--ink-2);
}
.copy--light:hover { background: var(--bg-alt); color: var(--ink); }

/* ---------- steps ---------- */
.steps { list-style: none; display: grid; gap: 2px; counter-reset: step; }
.step {
  display: flex; gap: 20px; padding: 20px 4px; border-bottom: 1px dashed var(--line);
}
.step:last-child { border-bottom: 0; }
.step__n {
  flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  font-family: var(--mono); font-size: 13px; font-weight: 600;
  background: var(--accent-soft); color: var(--accent); border: 1px solid var(--accent-line);
}
.step h3 { font-size: 1rem; margin-bottom: 4px; }
.step p { font-size: 14px; color: var(--ink-2); max-width: 48em; }

.notice {
  margin-top: 28px; padding: 18px 22px; border-radius: var(--r-md);
  background: var(--accent-soft); border: 1px solid var(--accent-line);
  font-size: 13.8px; color: var(--ink-2);
}
.notice strong { color: var(--ink); }

/* ---------- faq ---------- */
.faq { display: grid; gap: 0; max-width: 54em; }
.faq details {
  border-bottom: 1px solid var(--line); padding: 4px 0;
}
.faq summary {
  cursor: pointer; list-style: none; padding: 18px 40px 18px 0; position: relative;
  font-size: 15.5px; font-weight: 550; letter-spacing: -0.01em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  font-family: var(--mono); font-size: 18px; color: var(--muted);
  transition: transform .25s ease, color .2s ease;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); color: var(--accent); }
.faq summary:hover::after { color: var(--accent); }
.faq details p { padding: 0 40px 20px 0; font-size: 14px; color: var(--ink-2); }

/* ---------- download ---------- */
.download { padding-bottom: clamp(80px, 10vw, 130px); }
.dl-card {
  display: grid; grid-template-columns: 1.25fr .75fr; gap: 40px;
  padding: clamp(30px, 4vw, 52px);
  background: var(--surface); border: 1px solid var(--line); border-radius: 26px;
  box-shadow: var(--shadow-lg); position: relative; overflow: hidden;
}
.dl-card::before {
  content: ""; position: absolute; inset: 0 auto auto 0; width: 60%; height: 100%;
  background: radial-gradient(60% 70% at 10% 0%, var(--accent-soft), transparent 70%);
  pointer-events: none;
}
.dl-card__left { position: relative; z-index: 1; }
.dl-card h2 { font-size: clamp(1.5rem, 2.8vw, 2.1rem); margin-bottom: 10px; letter-spacing: -0.03em; }
.dl-card__sub { font-family: var(--mono); font-size: 12px; color: var(--muted); margin-bottom: 22px; }
.dl-card__list { list-style: none; display: grid; gap: 10px; }
.dl-card__list li {
  position: relative; padding-left: 24px; font-size: 14px; color: var(--ink-2);
}
.dl-card__list li::before {
  content: "✓"; position: absolute; left: 0; top: -1px; color: var(--cyan);
  font-size: 13px; font-weight: 700;
}

.dl-card__right { position: relative; z-index: 1; display: flex; align-items: center; }
.dl-box {
  width: 100%; padding: 22px; border-radius: var(--r-md);
  background: var(--surface-2); border: 1px solid var(--line);
}
.dl-box__label {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 12px;
}
.dl-code {
  display: flex; align-items: center; gap: 10px; margin-top: 12px;
  font-size: 12.5px; color: var(--muted);
}
.dl-code code {
  font-size: 14px; font-weight: 600; letter-spacing: .18em; color: var(--ink);
  background: var(--bg-alt); padding: 4px 10px; border-radius: 6px; border: 1px solid var(--line);
}
.dl-code .copy { margin-left: auto; background: var(--surface); border-color: var(--line); color: var(--ink-2); }
.dl-code .copy:hover { background: var(--bg-alt); color: var(--ink); }
.dl-note { margin-top: 14px; font-size: 11.8px; color: var(--muted); line-height: 1.6; }

/* ---------- footer ---------- */
.footer { border-top: 1px solid var(--line); padding: 34px 0 40px; background: var(--bg-alt); }
.footer__inner { display: grid; gap: 14px; }
.footer__brand { display: flex; align-items: center; gap: 9px; font-size: 13.5px; font-weight: 600; }
.footer__brand .brand__mark { width: 26px; height: 26px; border-radius: 8px; }
.footer__links { display: flex; flex-wrap: wrap; gap: 20px; font-size: 13px; color: var(--ink-2); }
.footer__links a:hover { color: var(--accent); }
.footer__meta { font-size: 12px; color: var(--muted); }

/* ---------- reveal ---------- */
/* 无 JS 时保持可见；有 JS 才启用入场位移 */
.reveal { transition: opacity .7s ease, transform .7s cubic-bezier(.2,.8,.2,1); }
html.js .reveal { opacity: 0; transform: translateY(18px); }
html.js .reveal.is-in { opacity: 1; transform: none; }
html.static-mode .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
@media (prefers-reduced-motion: reduce) {
  html.js .reveal { opacity: 1; transform: none; }
}

/* ---------- responsive ---------- */
@media (max-width: 1040px) {
  .hero__grid { grid-template-columns: 1fr; }
  .hero__visual { max-width: 620px; }
  .chip--a { left: -4%; }
  .chip--b { right: -2%; }
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .grid-3 .card:last-child { grid-column: span 2; }
  .split { grid-template-columns: 1fr; }
  .dl-card { grid-template-columns: 1fr; gap: 28px; }
}

@media (max-width: 820px) {
  .nav__links { display: none; }
  .pipe { grid-template-columns: repeat(4, 1fr); overflow: visible; padding-bottom: 0; }
  .pipe::before { display: none; }
  .grid-3 { grid-template-columns: 1fr; }
  .grid-3 .card:last-child { grid-column: auto; }
  .grid-2 { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3)::before, .stat:nth-child(1)::before { display: none; }
  .stat:nth-child(3), .stat:nth-child(4) { border-top: 1px solid var(--line); }
}

@media (max-width: 560px) {
  .wrap, .nav__inner { padding-left: 18px; padding-right: 18px; }
  .mock { transform: none; }
  .mock__body { grid-template-columns: 1fr; }
  .mock__side { display: none; }
  .pipe__panel { padding: 22px 20px; }
  .btn { width: 100%; justify-content: center; }
  .hero__cta { gap: 10px; }
  .nav__actions .btn--sm { width: auto; }
  .step { gap: 14px; }
}
