/*
 * Jotsy 官网样式（index / privacy / 404 共用）
 *
 * 设计：极简留白。近白的页面、大号粗体标题、几乎只用中性色；主题色只出现在按钮、
 * 选项卡指示条、链接与少量点缀上。与 app 同源（Material 3 Expressive：胶囊按钮、
 * 大圆角容器、ExpressiveMotion 同档的时长与曲线），不使用任何渐变。
 *
 * 颜色：--c-* 为 Material 3 色槽的 RGB 三元组（写成 rgb(var(--c-primary) / .5) 即可
 * 带透明度）。下面是默认种子色 #1E6586 由 ColorScheme.fromSeed(tonalSpot) 生成的值，
 * 与 app 完全一致；访客在“定制”里换主题色时，theme.js 会注入同样结构的
 * <style id="seed-theme">（数据见 assets/data/themes.json）覆盖这 25 个色槽，下面的
 * 派生令牌（--c-page、--c-deep……）引用色槽，所以会一起变。
 * 明暗：跟随系统，或由 <html data-theme="light|dark"> 强制；三段结构必须与
 * theme.js 的 buildCss 一致。
 */

/* ---------- 1. 设计令牌 ---------- */
:root {
  color-scheme: light;
  --c-primary: 29 101 134;
  --c-on-primary: 255 255 255;
  --c-primary-container: 196 231 255;
  --c-on-primary-container: 0 76 105;
  --c-secondary: 78 97 109;
  --c-on-secondary: 255 255 255;
  --c-secondary-container: 209 229 244;
  --c-on-secondary-container: 55 73 85;
  --c-tertiary: 97 90 125;
  --c-on-tertiary: 255 255 255;
  --c-tertiary-container: 231 222 255;
  --c-on-tertiary-container: 73 66 100;
  --c-surface: 246 250 254;
  --c-on-surface: 24 28 31;
  --c-on-surface-variant: 65 72 77;
  --c-surface-lowest: 255 255 255;
  --c-surface-low: 240 244 248;
  --c-surface-container: 235 238 243;
  --c-surface-high: 229 232 237;
  --c-surface-highest: 223 227 231;
  --c-outline: 113 120 126;
  --c-outline-variant: 192 199 205;
  --c-inverse-surface: 44 49 52;
  --c-inverse-on-surface: 237 241 245;
  --c-inverse-primary: 144 206 244;
  --c-error: 186 26 26;

  /* 派生：页面底色、相间区块、强对比色带（亮色取反色表面，暗色取抬高一级的表面） */
  --c-page: var(--c-surface-lowest);
  --c-alt: var(--c-surface-low);
  --c-raised: var(--c-surface-lowest);
  --c-deep: var(--c-inverse-surface);
  --c-on-deep: var(--c-inverse-on-surface);
  --c-deep-accent: var(--c-inverse-primary);
  --a-hairline: .7;
  --shadow-rest: 0 1px 2px rgb(0 0 0 / .06), 0 2px 8px rgb(0 0 0 / .04);
  --shadow-float: 0 12px 32px -12px rgb(0 0 0 / .18);
  --shadow-phone: 0 50px 90px -40px rgb(0 0 0 / .42), 0 22px 40px -24px rgb(0 0 0 / .24);
  --frame: 24 27 30;
  --frame-edge: 70 76 82;

  /* 字体：中文优先系统黑体（鸿蒙设备上即 HarmonyOS Sans，与 app 同款），不引入字体文件 */
  --font-sans: "HarmonyOS Sans SC", "HarmonyOS Sans", "MiSans", "PingFang SC", "Hiragino Sans GB",
    "Source Han Sans SC", "Noto Sans CJK SC", "Microsoft YaHei UI", "Microsoft YaHei", system-ui,
    -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, "SFMono-Regular", "JetBrains Mono", "Cascadia Code", Menlo, Consolas,
    monospace;

  /* 字阶 */
  --fs-hero: clamp(2.4rem, 1.15rem + 5.4vw, 5.5rem);
  --fs-display: clamp(1.9rem, 1.25rem + 2.8vw, 3.25rem);
  --fs-h3: clamp(1.45rem, 1.15rem + 1.1vw, 2.1rem);
  --fs-lead: clamp(1.05rem, 1rem + .3vw, 1.2rem);
  --ls-tight: -.015em;

  /* 间距与圆角 */
  --gutter: clamp(16px, 4vw, 40px);
  --header-h: 64px;
  --section-pad: clamp(88px, 12vw, 168px);
  --r-sm: 12px;
  --r-md: 20px;
  --r-lg: 28px;
  --r-block: clamp(28px, 4vw, 44px);

  /* 动效（与 ExpressiveMotion 同档） */
  --m-fast: 180ms;
  --m-medium: 250ms;
  --m-standard: 350ms;
  --m-long: 500ms;
  --e-effects: cubic-bezier(.215, .61, .355, 1);
  --e-emph: cubic-bezier(.2, 0, 0, 1);
  --e-spatial: cubic-bezier(.34, 1.36, .64, 1);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --c-primary: 144 206 244;
    --c-on-primary: 0 52 74;
    --c-primary-container: 0 76 105;
    --c-on-primary-container: 196 231 255;
    --c-secondary: 182 201 215;
    --c-on-secondary: 32 51 62;
    --c-secondary-container: 55 73 85;
    --c-on-secondary-container: 209 229 244;
    --c-tertiary: 202 193 233;
    --c-on-tertiary: 50 44 76;
    --c-tertiary-container: 73 66 100;
    --c-on-tertiary-container: 231 222 255;
    --c-surface: 15 20 23;
    --c-on-surface: 223 227 231;
    --c-on-surface-variant: 192 199 205;
    --c-surface-lowest: 10 15 18;
    --c-surface-low: 24 28 31;
    --c-surface-container: 28 32 35;
    --c-surface-high: 38 43 46;
    --c-surface-highest: 49 53 57;
    --c-outline: 139 146 151;
    --c-outline-variant: 65 72 77;
    --c-inverse-surface: 223 227 231;
    --c-inverse-on-surface: 44 49 52;
    --c-inverse-primary: 29 101 134;
    --c-error: 255 180 171;
    --c-alt: var(--c-surface);
    --c-raised: var(--c-surface-container);
    --c-deep: var(--c-surface-container);
    --c-on-deep: var(--c-on-surface);
    --c-deep-accent: var(--c-primary);
    --a-hairline: .9;
    --shadow-rest: 0 0 0 1px rgb(var(--c-outline-variant) / .6);
    --shadow-float: 0 12px 32px -12px rgb(0 0 0 / .6);
    --shadow-phone: 0 50px 90px -40px rgb(0 0 0 / .8), 0 22px 40px -24px rgb(0 0 0 / .6);
    --frame: 36 40 44;
    --frame-edge: 84 90 96;
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --c-primary: 144 206 244;
  --c-on-primary: 0 52 74;
  --c-primary-container: 0 76 105;
  --c-on-primary-container: 196 231 255;
  --c-secondary: 182 201 215;
  --c-on-secondary: 32 51 62;
  --c-secondary-container: 55 73 85;
  --c-on-secondary-container: 209 229 244;
  --c-tertiary: 202 193 233;
  --c-on-tertiary: 50 44 76;
  --c-tertiary-container: 73 66 100;
  --c-on-tertiary-container: 231 222 255;
  --c-surface: 15 20 23;
  --c-on-surface: 223 227 231;
  --c-on-surface-variant: 192 199 205;
  --c-surface-lowest: 10 15 18;
  --c-surface-low: 24 28 31;
  --c-surface-container: 28 32 35;
  --c-surface-high: 38 43 46;
  --c-surface-highest: 49 53 57;
  --c-outline: 139 146 151;
  --c-outline-variant: 65 72 77;
  --c-inverse-surface: 223 227 231;
  --c-inverse-on-surface: 44 49 52;
  --c-inverse-primary: 29 101 134;
  --c-error: 255 180 171;
  --c-alt: var(--c-surface);
  --c-raised: var(--c-surface-container);
  --c-deep: var(--c-surface-container);
  --c-on-deep: var(--c-on-surface);
  --c-deep-accent: var(--c-primary);
  --a-hairline: .9;
  --shadow-rest: 0 0 0 1px rgb(var(--c-outline-variant) / .6);
  --shadow-float: 0 12px 32px -12px rgb(0 0 0 / .6);
  --shadow-phone: 0 50px 90px -40px rgb(0 0 0 / .8), 0 22px 40px -24px rgb(0 0 0 / .6);
  --frame: 36 40 44;
  --frame-edge: 84 90 96;
}

html[lang="en"] {
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC",
    "HarmonyOS Sans SC", "Microsoft YaHei UI", "Microsoft YaHei", sans-serif;
  --ls-tight: -.03em;
}

/* ---------- 2. 基础 ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  background: rgb(var(--c-page));
}

body {
  margin: 0;
  min-height: 100vh;
  background: rgb(var(--c-page));
  color: rgb(var(--c-on-surface));
  font: 400 1rem/1.7 var(--font-sans);
  line-break: strict;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
  overflow-x: clip;
}

img,
svg,
video {
  display: block;
  max-width: 100%;
}

img {
  height: auto;
}

figure {
  margin: 0;
}

h1,
h2,
h3,
p,
ul,
ol {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

a {
  color: rgb(var(--c-primary));
  text-underline-offset: .2em;
}

button,
input,
select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid rgb(var(--c-primary));
  outline-offset: 3px;
  border-radius: 6px;
}

::selection {
  background: rgb(var(--c-primary) / .2);
}

.i {
  width: 1em;
  height: 1em;
  flex: none;
  fill: currentColor;
}

.container {
  width: min(100% - 2 * var(--gutter), 1160px);
  margin-inline: auto;
}

.skip-link {
  position: fixed;
  left: 16px;
  top: 12px;
  z-index: 100;
  padding: 10px 18px;
  border-radius: 999px;
  background: rgb(var(--c-primary));
  color: rgb(var(--c-on-primary));
  font-weight: 600;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform var(--m-medium) var(--e-effects);
}

.skip-link:focus {
  transform: none;
}

/* 主题切换时短暂补间颜色；不支持 View Transitions 时的退路 */
html.theme-anim,
html.theme-anim *,
html.theme-anim *::before,
html.theme-anim *::after {
  transition: background-color var(--m-standard) var(--e-effects),
    color var(--m-standard) var(--e-effects), border-color var(--m-standard) var(--e-effects),
    fill var(--m-standard) var(--e-effects), box-shadow var(--m-standard) var(--e-effects) !important;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation: none;
  mix-blend-mode: normal;
}

/* 英文偏好：脚本替换文案前先隐藏，避免中文闪一下（1.2 秒后无论如何显示） */
html.lang-pending body {
  animation: lang-reveal 0s linear 1.2s forwards;
  visibility: hidden;
}

@keyframes lang-reveal {
  to {
    visibility: visible;
  }
}

/* ---------- 3. 通用组件 ---------- */
.btn {
  --h: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: var(--h);
  padding: 0 calc(var(--h) * .48);
  border: 0;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: .01em;
  text-decoration: none;
  white-space: nowrap;
  transition: box-shadow var(--m-fast) var(--e-effects), transform var(--m-medium) var(--e-spatial),
    background-color var(--m-fast) var(--e-effects);
}

.btn .i {
  font-size: 1.1em;
}

.btn:active {
  transform: scale(.97);
}

.btn--sm {
  --h: 38px;
  padding: 0 18px;
  font-size: 14px;
}

.btn--lg {
  --h: 52px;
  font-size: 16px;
}

.btn--xl {
  --h: 60px;
  font-size: 16px;
}

.btn--filled {
  background: rgb(var(--c-primary));
  color: rgb(var(--c-on-primary));
}

.btn--filled:hover {
  box-shadow: inset 0 0 0 999px rgb(var(--c-on-primary) / .1), var(--shadow-float);
}

.btn--tonal {
  background: rgb(var(--c-on-surface) / .07);
  color: rgb(var(--c-on-surface));
}

.btn--tonal:hover {
  background: rgb(var(--c-on-surface) / .11);
}

.btn-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  text-align: left;
}

.btn-stack small {
  font-size: 12px;
  font-weight: 500;
  opacity: .78;
}

.star-count {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-left: 2px;
  padding: 3px 9px;
  border-radius: 999px;
  background: rgb(var(--c-on-surface) / .08);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.star-count .i {
  font-size: 11px;
}

.star-count[hidden] {
  display: none;
}

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgb(var(--c-on-surface-variant));
  font-size: 18px;
  text-decoration: none;
  transition: background-color var(--m-fast) var(--e-effects), color var(--m-fast) var(--e-effects);
}

.icon-btn:hover {
  background: rgb(var(--c-on-surface) / .07);
  color: rgb(var(--c-on-surface));
}

.lang-btn {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .02em;
}

.text-btn {
  padding: 8px 4px;
  border: 0;
  background: none;
  color: rgb(var(--c-primary));
  font-size: 14px;
  font-weight: 600;
}

.text-btn:hover {
  text-decoration: underline;
  text-underline-offset: .25em;
}

/* 带箭头的文字链接（箭头用伪元素画，悬停时右移） */
.more-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  text-decoration: none;
}

.more-link::after {
  content: "→";
  transition: transform var(--m-medium) var(--e-spatial);
}

.more-link:hover::after {
  transform: translateX(4px);
}

/* 分段单选（明暗、语言） */
.seg {
  display: inline-flex;
  gap: 2px;
  padding: 4px;
  border-radius: 999px;
  background: rgb(var(--c-on-surface) / .06);
}

.seg button {
  min-height: 36px;
  padding: 0 16px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgb(var(--c-on-surface-variant));
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  transition: background-color var(--m-fast) var(--e-effects), color var(--m-fast) var(--e-effects),
    box-shadow var(--m-fast) var(--e-effects);
}

.seg button[aria-checked="true"] {
  background: rgb(var(--c-raised));
  color: rgb(var(--c-on-surface));
  box-shadow: var(--shadow-rest);
}

.seg--sm button {
  min-height: 30px;
  padding: 0 12px;
  font-size: 13px;
}

/* ---------- 4. 顶栏 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  transition: background-color var(--m-medium) var(--e-effects),
    box-shadow var(--m-medium) var(--e-effects);
}

/* 滚动后（或展开菜单时）换成半透明底 + 单层模糊；页面顶部保持透明 */
.site-header[data-elevated="true"],
.site-header.is-menu-open {
  background: rgb(var(--c-page) / .82);
  box-shadow: 0 1px 0 rgb(var(--c-outline-variant) / var(--a-hairline));
  -webkit-backdrop-filter: saturate(1.6) blur(18px);
  backdrop-filter: saturate(1.6) blur(18px);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: rgb(var(--c-on-surface));
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -.01em;
  text-decoration: none;
}

.brand-mark {
  display: block;
  width: 22px;
  height: 26px;
  color: rgb(var(--c-primary));
}

.brand-mark svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.nav {
  display: flex;
  gap: 4px;
  margin-inline: auto;
}

.nav a {
  padding: 8px 14px;
  border-radius: 999px;
  color: rgb(var(--c-on-surface-variant));
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  transition: color var(--m-fast) var(--e-effects), background-color var(--m-fast) var(--e-effects);
}

.nav a:hover {
  color: rgb(var(--c-on-surface));
}

.nav a[aria-current="true"] {
  color: rgb(var(--c-on-surface));
  background: rgb(var(--c-on-surface) / .06);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 2px;
  margin-left: auto;
}

.nav + .header-actions {
  margin-left: 0;
}

.header-actions .btn {
  margin-left: 8px;
}

.theme-btn .i {
  display: none;
}

html:not([data-theme]) .theme-btn .ic-system,
html[data-theme="light"] .theme-btn .ic-light,
html[data-theme="dark"] .theme-btn .ic-dark {
  display: block;
}

.menu-btn {
  display: none;
}

.menu-btn .ic-close,
.menu-btn[aria-expanded="true"] .ic-open {
  display: none;
}

.menu-btn[aria-expanded="true"] .ic-close {
  display: block;
}

.mobile-menu {
  position: fixed;
  inset: var(--header-h) 0 auto;
  z-index: 39;
  display: grid;
  gap: 24px;
  max-height: calc(100dvh - var(--header-h));
  overflow-y: auto;
  padding: 8px var(--gutter) calc(28px + env(safe-area-inset-bottom));
  background: rgb(var(--c-page));
  box-shadow: 0 24px 48px -24px rgb(0 0 0 / .25);
  animation: menu-in var(--m-standard) var(--e-emph);
}

.mobile-menu[hidden] {
  display: none;
}

.mobile-menu nav {
  display: grid;
}

.mobile-menu nav a {
  padding: 14px 0;
  border-bottom: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
  color: rgb(var(--c-on-surface));
  font-size: 20px;
  font-weight: 600;
  text-decoration: none;
}

.mobile-menu .btn {
  width: 100%;
}

@keyframes menu-in {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
}

@media (max-width: 899px) {
  .nav {
    display: none;
  }

  .menu-btn {
    display: inline-grid;
  }
}

@media (max-width: 559px) {
  .hide-sm {
    display: none;
  }
}

/* ---------- 5. 区块骨架 ---------- */
.section {
  padding-block: var(--section-pad);
}

.section--alt {
  background: rgb(var(--c-alt));
}

.section-head {
  max-width: 640px;
  margin-bottom: clamp(40px, 6vw, 72px);
}

.section-head.center {
  margin-inline: auto;
  text-align: center;
}

.eyebrow {
  margin-bottom: 14px;
  color: rgb(var(--c-primary));
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}

/*
 * 中文标题只在标点处换行（“你的日记，/只在你的手机里”），不在词中间断开；
 * 一整段没有标点、放不下时由 overflow-wrap 兜底，不会撑破版面。英文不受影响。
 */
.display,
.hero-title,
.ft-panel h3 {
  word-break: keep-all;
  overflow-wrap: anywhere;
}

.display {
  font-size: var(--fs-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: var(--ls-tight);
  text-wrap: balance;
}

.lead {
  margin-top: 20px;
  color: rgb(var(--c-on-surface-variant));
  font-size: var(--fs-lead);
  line-height: 1.7;
  text-wrap: pretty;
}

.section-head .more-link {
  margin-top: 24px;
}

/* 左文右图（或左标题右列表）的两栏 */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(48px, 7vw, 96px);
}

.split > .section-head {
  margin-bottom: 0;
}

.split--top {
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  align-items: start;
}

/* 宽屏时左侧标题随右侧长列表吸顶 */
@media (min-width: 900px) {
  .split--top > .section-head {
    position: sticky;
    top: calc(var(--header-h) + 40px);
  }
}

@media (max-width: 899px) {
  .split,
  .split--top {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- 6. 手机框（纯 CSS；截图本身已带状态栏） ---------- */
.phone {
  --pw: 280px;
  display: grid;
  width: var(--pw);
  padding: calc(var(--pw) * .028);
  border-radius: calc(var(--pw) * .15);
  background: rgb(var(--frame));
  box-shadow: inset 0 0 0 1px rgb(var(--frame-edge)), var(--shadow-phone);
}

.phone > img,
.phone > picture {
  grid-area: 1 / 1;
  width: 100%;
  border-radius: calc(var(--pw) * .125);
}

.phone > picture img {
  width: 100%;
  border-radius: inherit;
}

.phone img {
  aspect-ratio: 720 / 1600;
  object-fit: cover;
  background: rgb(var(--c-surface-container));
}

/* ---------- 7. 首屏 ---------- */
.hero {
  padding-top: clamp(40px, 7vw, 88px);
  text-align: center;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.release-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  max-width: 100%;
  padding: 5px 14px 5px 5px;
  border-radius: 999px;
  background: rgb(var(--c-on-surface) / .05);
  color: rgb(var(--c-on-surface-variant));
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: background-color var(--m-fast) var(--e-effects);
}

.release-pill:hover {
  background: rgb(var(--c-on-surface) / .09);
}

.release-pill > span:nth-child(2) {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.release-pill__badge {
  flex: none;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgb(var(--c-primary));
  color: rgb(var(--c-on-primary));
  font-size: 12px;
  font-weight: 700;
}

.release-pill .i {
  flex: none;
  font-size: 11px;
}

.hero-title {
  margin-top: 28px;
  font-size: var(--fs-hero);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: var(--ls-tight);
  text-wrap: balance;
}

.hero-lead {
  max-width: 32em;
  margin-top: 24px;
  color: rgb(var(--c-on-surface-variant));
  font-size: var(--fs-lead);
  line-height: 1.7;
  text-wrap: balance;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 36px;
}

.hero-meta {
  margin-top: 20px;
  color: rgb(var(--c-on-surface-variant) / .85);
  font-size: 13px;
  letter-spacing: .02em;
}

/*
 * 三台手机叠在同一个网格格子里：中间一台正放，左右两台缩小、下沉并向两侧错开。
 * 窄屏时两侧只露出一截（被本容器裁掉），像扇面展开；底部留白给阴影。
 */
.hero-stage {
  --pw: clamp(220px, 15vw + 120px, 320px);
  display: grid;
  justify-items: center;
  align-items: end;
  margin-top: clamp(56px, 8vw, 88px);
  padding-bottom: clamp(56px, 8vw, 104px);
  overflow: hidden;
}

.hero-stage .phone {
  --pw: inherit;
  grid-area: 1 / 1;
}

.phone--hero {
  z-index: 2;
}

.phone--side {
  --dir: -1;
  transform: translate(calc(var(--dir) * var(--pw) * .88), 7%) scale(.84);
}

.phone--right {
  --dir: 1;
}

@media (max-width: 559px) {
  .hero-cta {
    flex-direction: column;
    align-self: stretch;
  }

  .hero-cta .btn {
    width: 100%;
  }

  .phone--side {
    transform: translate(calc(var(--dir) * var(--pw) * .74), 8%) scale(.8);
  }
}

/* ---------- 8. 功能：选项卡 + 截图 ---------- */
.features {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  grid-template-areas:
    "tabs tabs"
    "stage copy";
  column-gap: clamp(40px, 6vw, 88px);
  row-gap: clamp(32px, 5vw, 56px);
  align-items: center;
}

.ft-tabs {
  grid-area: tabs;
  display: flex;
  justify-content: center;
  gap: 4px;
  border-bottom: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
}

.ft-tab {
  position: relative;
  padding: 14px 20px 16px;
  border: 0;
  background: none;
  color: rgb(var(--c-on-surface-variant));
  font-size: 16px;
  font-weight: 600;
  white-space: nowrap;
  transition: color var(--m-fast) var(--e-effects);
}

.ft-tab::after {
  content: "";
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: -1px;
  height: 3px;
  border-radius: 3px 3px 0 0;
  background: rgb(var(--c-primary));
  transform: scaleX(0);
  transition: transform var(--m-standard) var(--e-emph);
}

.ft-tab:hover {
  color: rgb(var(--c-on-surface));
}

.ft-tab[aria-selected="true"] {
  color: rgb(var(--c-on-surface));
}

.ft-tab[aria-selected="true"]::after {
  transform: scaleX(1);
}

.ft-tab:focus-visible {
  outline-offset: -4px;
}

.ft-stage {
  grid-area: stage;
  display: grid;
  place-items: center;
  padding: clamp(36px, 6vw, 64px) 16px;
  border-radius: var(--r-block);
  background: rgb(var(--c-alt));
}

.phone--feature {
  --pw: clamp(220px, 12vw + 140px, 300px);
}

/* 截图叠放，当前一张淡入；没有脚本时只显示第一张 */
.phone--feature img {
  opacity: 0;
  transition: opacity var(--m-long) var(--e-effects);
}

.phone--feature img.is-active {
  opacity: 1;
}

.ft-copy {
  grid-area: copy;
  max-width: 460px;
}

.ft-panel h3 {
  font-size: var(--fs-h3);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: var(--ls-tight);
  text-wrap: balance;
}

.ft-panel p {
  margin-top: 16px;
  color: rgb(var(--c-on-surface-variant));
  font-size: 17px;
  line-height: 1.75;
  text-wrap: pretty;
}

.ft-panel + .ft-panel {
  margin-top: 48px;
}

html.js .ft-panel + .ft-panel {
  margin-top: 0;
}

.ft-panel[hidden] {
  display: none;
}

html.js .ft-panel:not([hidden]) {
  animation: panel-in var(--m-long) var(--e-emph);
}

@keyframes panel-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
}

.keys {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 28px;
}

.keys li {
  padding: 6px 14px;
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgb(var(--c-outline-variant) / var(--a-hairline));
  color: rgb(var(--c-on-surface-variant));
  font-size: 14px;
  font-weight: 500;
}

@media (max-width: 899px) {
  .features {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "tabs"
      "stage"
      "copy";
  }

  .ft-copy {
    justify-self: center;
    text-align: center;
  }

  .keys {
    justify-content: center;
  }
}

@media (max-width: 559px) {
  .ft-tabs {
    gap: 0;
  }

  .ft-tab {
    flex: 1 1 0;
    min-width: 0;
    padding: 12px 4px 14px;
    font-size: 15px;
  }

  .ft-tab::after {
    left: 12px;
    right: 12px;
  }

  .ft-stage {
    margin-inline: calc(var(--gutter) * -1);
    border-radius: 0;
  }
}

/* ---------- 9. 定制：主题色 ---------- */
.palette {
  margin-top: 40px;
}

/* 色块由脚本生成、换色也靠脚本；没有脚本时整块不显示，免得留下按不动的按钮 */
html:not(.js) .palette {
  display: none;
}

.palette-hint {
  margin-bottom: 16px;
  color: rgb(var(--c-on-surface));
  font-size: 15px;
  font-weight: 600;
}

.swatches {
  --n: 10;
  display: grid;
  grid-template-columns: repeat(var(--n), minmax(0, 40px));
  gap: clamp(6px, 1.4vw, 10px);
}

.swatches--shades {
  --n: 8;
  margin-top: 14px;
}

.swatches:empty {
  display: none;
}

.swatch {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  width: 100%;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--sw);
  box-shadow: inset 0 0 0 1px rgb(var(--c-on-surface) / .12);
  color: var(--ink);
  font-size: 14px;
  transition: transform var(--m-medium) var(--e-spatial), box-shadow var(--m-fast) var(--e-effects);
}

.swatch:hover {
  transform: scale(1.08);
}

.swatch .i {
  opacity: 0;
  transform: scale(.5);
  transition: opacity var(--m-fast) var(--e-effects), transform var(--m-medium) var(--e-spatial);
}

.swatch[aria-checked="true"] {
  box-shadow: 0 0 0 2px rgb(var(--c-page)), 0 0 0 4px rgb(var(--c-on-surface));
}

.section--alt .swatch[aria-checked="true"] {
  box-shadow: 0 0 0 2px rgb(var(--c-alt)), 0 0 0 4px rgb(var(--c-on-surface));
}

.swatch[aria-checked="true"] .i {
  opacity: 1;
  transform: none;
}

.swatches--families .swatch[aria-checked="true"] .i {
  opacity: 0;
}

.palette-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-top: 28px;
}

/* 两台不同主题色的手机前后错开 */
.duo {
  --pw: clamp(190px, 10vw + 140px, 280px);
  display: grid;
  justify-items: center;
  padding-block: 24px 48px;
}

.duo .phone {
  --pw: inherit;
  grid-area: 1 / 1;
}

.phone--back {
  transform: translate(30%, -5%) scale(.92);
}

.phone--front {
  z-index: 1;
  transform: translate(-24%, 4%);
}

/* ---------- 10. 隐私：强对比色带 ---------- */
.band {
  background: rgb(var(--c-deep));
  color: rgb(var(--c-on-deep));
}

.band .eyebrow,
.band .more-link {
  color: rgb(var(--c-deep-accent));
}

.band .lead {
  color: rgb(var(--c-on-deep) / .72);
}

.band .section-head {
  max-width: 720px;
}

.pillars {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(28px, 4vw, 56px);
}

.pillars li {
  padding-top: 28px;
  border-top: 1px solid rgb(var(--c-on-deep) / .16);
}

.pillars .i {
  margin-bottom: 20px;
  color: rgb(var(--c-deep-accent));
  font-size: 24px;
}

.pillars h3,
.trio h3 {
  font-size: 19px;
  font-weight: 700;
  line-height: 1.4;
}

.pillars p {
  margin-top: 10px;
  color: rgb(var(--c-on-deep) / .72);
}

.band > .container > .more-link {
  margin-top: clamp(40px, 6vw, 64px);
}

/* ---------- 11. 数据：三栏 ---------- */
.trio {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(28px, 4vw, 56px);
}

.trio li {
  display: flex;
  flex-direction: column;
  padding-top: 28px;
  border-top: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
}

.trio p {
  margin-top: 10px;
  color: rgb(var(--c-on-surface-variant));
}

.trio .names {
  margin-top: 16px;
  color: rgb(var(--c-on-surface-variant) / .8);
  font-size: 14px;
  line-height: 1.8;
}

.trio .more-link {
  margin-top: 16px;
  font-size: 15px;
}

@media (max-width: 899px) {
  .pillars,
  .trio {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- 12. 更新日志 ---------- */
.releases {
  display: grid;
}

.release {
  padding-block: 28px;
  border-top: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
}

.release:last-child {
  border-bottom: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
}

.release[hidden] {
  display: none;
}

.release header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}

.release h3 {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -.01em;
  font-variant-numeric: tabular-nums;
}

.release time {
  margin-left: auto;
  color: rgb(var(--c-on-surface-variant));
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

.badge {
  padding: 2px 10px;
  border-radius: 999px;
  background: rgb(var(--c-primary) / .12);
  color: rgb(var(--c-primary));
  font-size: 12px;
  font-weight: 700;
}

.badge[hidden] {
  display: none;
}

.release ul {
  display: grid;
  gap: 8px;
  margin-top: 16px;
}

.release li {
  position: relative;
  padding-left: 18px;
  color: rgb(var(--c-on-surface-variant));
}

.release li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .72em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgb(var(--c-outline));
}

.release > a {
  display: inline-block;
  margin-top: 14px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.release > a:hover {
  text-decoration: underline;
}

.newer-release {
  margin-bottom: 20px;
  color: rgb(var(--c-on-surface-variant));
}

.newer-release[hidden] {
  display: none;
}

/* ---------- 13. 常见问题 ---------- */
.faq-list {
  border-top: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
}

.faq {
  border-bottom: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
}

.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 0;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.5;
  list-style: none;
  cursor: pointer;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary .i {
  color: rgb(var(--c-on-surface-variant));
  font-size: 15px;
  transition: transform var(--m-standard) var(--e-emph);
}

.faq[open] summary .i {
  transform: rotate(45deg);
}

.faq summary:focus-visible {
  outline-offset: -2px;
}

.faq-body {
  overflow: hidden;
}

.faq-body p {
  max-width: 62ch;
  padding-bottom: 22px;
  color: rgb(var(--c-on-surface-variant));
}

.faq-body p + p {
  margin-top: -10px;
}

/* ---------- 14. 下载（结尾号召） ---------- */
.dl {
  display: grid;
  justify-items: center;
  gap: 40px;
  text-align: center;
}

.dl-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 720px;
}

.dl-icon {
  width: 96px;
  height: 96px;
  margin-bottom: 32px;
  border-radius: 24px;
  box-shadow: var(--shadow-float);
}

.dl-main .lead {
  max-width: 34em;
  text-wrap: balance;
}

.dl-release {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 20px;
  color: rgb(var(--c-on-surface-variant));
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

.dl-release > span[hidden] {
  display: none;
}

.dl-release > span + span::before {
  content: "·";
  margin-inline: .6em;
}

.dl-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
}

/* 三个平台按钮在桌面宽度下排成一行：可以比 .dl-main 的 720px 略宽（在列内居中），
   放不下视口时照常换行；手机宽度下改为竖排（见文末断点）。 */
@media (min-width: 560px) {
  .dl-buttons {
    width: max-content;
    max-width: calc(100vw - 32px);
  }
}

.os-note {
  display: none;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  color: rgb(var(--c-on-surface-variant));
  font-size: 14px;
}

html[data-os="ios"] .os-note--ios {
  display: inline-flex;
}

.dl-more {
  width: 100%;
  margin-top: 28px;
}

.dl-more summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  color: rgb(var(--c-on-surface-variant));
  font-size: 14px;
  font-weight: 600;
  list-style: none;
  cursor: pointer;
}

.dl-more summary::-webkit-details-marker {
  display: none;
}

.dl-more summary:hover {
  color: rgb(var(--c-on-surface));
}

.dl-more summary .i {
  font-size: 12px;
  transition: transform var(--m-standard) var(--e-emph);
}

.dl-more[open] summary .i {
  transform: rotate(180deg);
}

.dl-more__body {
  display: grid;
  gap: 20px;
  margin-top: 16px;
  padding: clamp(20px, 3vw, 28px);
  border-radius: var(--r-lg);
  background: rgb(var(--c-raised));
  box-shadow: var(--shadow-rest);
  text-align: left;
}

.dl-alt {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.dl-alt a {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 10px;
  padding: 14px 16px;
  border-radius: var(--r-md);
  background: rgb(var(--c-on-surface) / .05);
  color: rgb(var(--c-on-surface));
  text-decoration: none;
  transition: background-color var(--m-fast) var(--e-effects);
}

.dl-alt a:hover {
  background: rgb(var(--c-on-surface) / .09);
}

.dl-alt .i {
  color: rgb(var(--c-primary));
}

.dl-alt b {
  font-weight: 600;
}

.dl-alt small {
  color: rgb(var(--c-on-surface-variant));
  font-size: 13px;
}

.dl-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
}

.dl-line label {
  font-weight: 600;
}

.select {
  position: relative;
  display: inline-flex;
}

.select select {
  appearance: none;
  min-height: 40px;
  padding: 0 40px 0 16px;
  border: 0;
  border-radius: 999px;
  background: rgb(var(--c-on-surface) / .06);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.select select option {
  background: rgb(var(--c-raised));
  color: rgb(var(--c-on-surface));
}

.select .i {
  position: absolute;
  right: 14px;
  top: 50%;
  font-size: 12px;
  transform: translateY(-50%);
  pointer-events: none;
}

.line-status,
.route-note {
  color: rgb(var(--c-on-surface-variant));
  font-size: 13px;
  line-height: 1.6;
}

.dl-sha[hidden] {
  display: none;
}

.dl-sha > p {
  margin-bottom: 8px;
  font-size: 14px;
  font-weight: 600;
}

.sha-list {
  display: grid;
  gap: 6px;
}

.sha-list li {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  font-size: 13px;
}

.sha-list b {
  font-weight: 600;
}

.sha-list code {
  overflow-wrap: anywhere;
  color: rgb(var(--c-on-surface-variant));
  font-family: var(--font-mono);
  font-size: 12px;
}

.sha-list .icon-btn {
  width: 32px;
  height: 32px;
  font-size: 14px;
}

.qr-card {
  display: none;
  align-items: center;
  gap: 18px;
  padding: 14px 22px 14px 14px;
  border-radius: var(--r-lg);
  background: rgb(var(--c-raised));
  box-shadow: var(--shadow-rest);
  text-align: left;
}

/* 只在电脑上显示扫码卡片（手机上直接点按钮下载） */
html[data-os="desktop"] .qr-card {
  display: flex;
}

/* 二维码固定为白底黑码：暗色模式下反色的码不少扫码器认不出，这里是功能需要，不跟主题 */
.qr {
  width: 84px;
  padding: 6px;
  border-radius: 12px;
  background: rgb(255 255 255);
}

.qr svg {
  width: 100%;
  fill: rgb(0 0 0);
}

.qr-card p {
  display: grid;
  gap: 2px;
  font-size: 13px;
  color: rgb(var(--c-on-surface-variant));
}

.qr-card b {
  color: rgb(var(--c-on-surface));
  font-size: 15px;
}

@media (max-width: 559px) {
  .dl-buttons {
    flex-direction: column;
    align-self: stretch;
  }

  .dl-buttons .btn {
    width: 100%;
  }

  .dl-alt {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* ---------- 15. 页脚 ---------- */
.site-footer {
  padding-block: 56px calc(40px + env(safe-area-inset-bottom));
  border-top: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
  color: rgb(var(--c-on-surface-variant));
  font-size: 14px;
}

.footer-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 24px 40px;
}

.footer-brand {
  display: grid;
  gap: 6px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 24px;
  margin-left: auto;
}

.footer-links a,
.footer-links button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 0;
  border: 0;
  background: none;
  color: rgb(var(--c-on-surface-variant));
  font-size: 14px;
  text-decoration: none;
}

.footer-links a:hover,
.footer-links button:hover {
  color: rgb(var(--c-on-surface));
}

.footer-links .i {
  font-size: 12px;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
  color: rgb(var(--c-on-surface-variant) / .8);
  font-size: 13px;
}

.footer-bottom a {
  color: inherit;
}

@media (max-width: 899px) {
  .footer-top {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-links {
    margin-left: 0;
  }
}

/* ---------- 16. 提示条 ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: calc(100% - 32px);
  padding: 12px 20px;
  border-radius: 999px;
  background: rgb(var(--c-inverse-surface));
  color: rgb(var(--c-inverse-on-surface));
  font-size: 14px;
  font-weight: 500;
  box-shadow: var(--shadow-float);
  opacity: 0;
  transform: translate(-50%, 16px);
  pointer-events: none;
  transition: opacity var(--m-medium) var(--e-effects), transform var(--m-standard) var(--e-emph);
}

.toast.is-shown {
  opacity: 1;
  transform: translate(-50%, 0);
}

.toast .i {
  color: rgb(var(--c-inverse-primary));
}

/* ---------- 17. 动效：首屏上浮、进入视口淡入 ---------- */
@media (prefers-reduced-motion: no-preference) {
  .rise {
    animation: rise var(--m-long) var(--e-emph) both;
    animation-delay: calc(var(--slot, 0) * 70ms);
  }

  .hero-stage .rise {
    animation-duration: 900ms;
    animation-delay: calc(160ms + var(--slot, 0) * 60ms);
  }

  html.js .reveal {
    opacity: 0;
    translate: 0 16px;
    transition: opacity 700ms var(--e-effects), translate 700ms var(--e-emph);
    transition-delay: calc(var(--d, 0) * 80ms);
  }

  html.js .reveal.is-in {
    opacity: 1;
    translate: none;
  }
}

/* 用独立的 translate 属性上浮，不覆盖两侧手机原有的 transform */
@keyframes rise {
  from {
    opacity: 0;
    translate: 0 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-delay: 0ms !important;
    transition-duration: 1ms !important;
  }
}

/* ---------- 18. 文档页（隐私政策） ---------- */
.doc-hero {
  padding-block: clamp(48px, 8vw, 104px) clamp(32px, 5vw, 56px);
}

.doc-hero .display {
  font-size: clamp(2.2rem, 1.4rem + 3.4vw, 4rem);
}

.doc-hero .lead {
  max-width: 40em;
}

.doc-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-top: 32px;
  color: rgb(var(--c-on-surface-variant));
  font-size: 14px;
}

.doc-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: clamp(32px, 6vw, 88px);
  padding-top: clamp(24px, 4vw, 48px);
  padding-bottom: var(--section-pad);
  border-top: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
}

.toc {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  align-self: start;
  display: grid;
  gap: 2px;
  font-size: 14px;
}

.toc > p {
  margin-bottom: 10px;
  color: rgb(var(--c-on-surface));
  font-weight: 700;
}

.toc-group {
  display: contents;
}

.toc a {
  padding: 6px 0 6px 14px;
  border-left: 2px solid rgb(var(--c-outline-variant) / var(--a-hairline));
  color: rgb(var(--c-on-surface-variant));
  text-decoration: none;
  transition: color var(--m-fast) var(--e-effects), border-color var(--m-fast) var(--e-effects);
}

.toc a:hover {
  color: rgb(var(--c-on-surface));
}

.toc a[aria-current="true"] {
  border-left-color: rgb(var(--c-primary));
  color: rgb(var(--c-on-surface));
}

.prose {
  max-width: 720px;
  font-size: 16.5px;
  line-height: 1.8;
}

.prose h2 {
  margin: 56px 0 16px;
  font-size: clamp(1.4rem, 1.2rem + .7vw, 1.75rem);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: var(--ls-tight);
}

.prose h2:first-child {
  margin-top: 0;
}

.prose h3 {
  margin: 36px 0 12px;
  font-size: 1.15rem;
  font-weight: 700;
}

.prose p,
.prose ul,
.prose .table-wrap {
  margin-top: 14px;
}

.prose p,
.prose li {
  color: rgb(var(--c-on-surface-variant));
}

.prose strong {
  color: rgb(var(--c-on-surface));
}

.prose ul {
  display: grid;
  gap: 10px;
}

.prose ul li {
  position: relative;
  padding-left: 20px;
}

.prose ul li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: .8em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgb(var(--c-outline));
}

.prose code {
  padding: 1px 6px;
  border-radius: 6px;
  background: rgb(var(--c-on-surface) / .06);
  font-family: var(--font-mono);
  font-size: .88em;
}

.table-wrap {
  overflow-x: auto;
  border-radius: var(--r-md);
  box-shadow: inset 0 0 0 1px rgb(var(--c-outline-variant) / var(--a-hairline));
}

.prose table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 14.5px;
  line-height: 1.6;
}

.prose th,
.prose td {
  padding: 12px 16px;
  text-align: left;
  vertical-align: top;
}

.prose th {
  color: rgb(var(--c-on-surface));
  font-weight: 700;
  white-space: nowrap;
}

.prose td {
  border-top: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
  color: rgb(var(--c-on-surface-variant));
}

.lang-block + .lang-block {
  margin-top: 80px;
  padding-top: 64px;
  border-top: 1px solid rgb(var(--c-outline-variant) / var(--a-hairline));
}

/* 有脚本时只显示当前语言的那一份；没有脚本时正文两份都显示，目录只列中文 */
html.js:not([lang="en"]) .lang-block[lang="en"],
html.js[lang="en"] .lang-block[lang="zh-CN"],
html:not([lang="en"]) [data-lang-only="en"],
html[lang="en"] [data-lang-only="zh"] {
  display: none;
}

html.js .lang-block + .lang-block {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

@media (max-width: 899px) {
  .doc-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .toc {
    display: none;
  }
}

/* ---------- 19. 404 ---------- */
.notfound {
  display: grid;
  place-items: center;
  min-height: calc(100vh - var(--header-h));
  min-height: calc(100dvh - var(--header-h));
  padding: 48px var(--gutter) 96px;
  text-align: center;
}

.notfound-code {
  color: rgb(var(--c-on-surface) / .08);
  font-size: clamp(7rem, 4rem + 18vw, 16rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -.04em;
  font-variant-numeric: tabular-nums;
}

.notfound .display {
  margin-top: -.6em;
}

.notfound .lead {
  max-width: 28em;
  margin-inline: auto;
}

.notfound .btn-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 36px;
}

/* ---------- 20. 打印（隐私政策可直接打印） ---------- */
@media print {
  .site-header,
  .mobile-menu,
  .site-footer,
  .toc,
  .skip-link,
  .toast {
    display: none !important;
  }

  .doc-layout {
    display: block;
    border: 0;
  }

  .doc-hero {
    padding-top: 0;
  }
}
