/* 由 build.py 从 tokens.json 生成，不要手改。改颜色 / 字体去改 tokens.json。 */
:root {
  --c-brand: #24704A;
  --c-onBrand: #FFFFFF;
  --c-accent: #9A5A12;
  --c-canvas: #F4F6F3;
  --c-surface: #FFFFFF;
  --c-textPrimary: #1A221C;
  --c-textSecondary: #5B655A;
  --c-outline: #7D877C;
  --c-divider: #E4E8E2;
  --c-stateReady: #8A5300;
  --c-stateBest: #2E7040;
  --c-stateOverdue: #B3362B;
  --c-shelfPlank: #B08254;
  --c-shelfPlankEdge: #6E4627;
  --c-jarLid: #AEB6AC;
  --c-brand-light: #24704A;
  --c-brand-dark: #7FD19E;
  --c-onBrand-light: #FFFFFF;
  --c-onBrand-dark: #0B2415;
  --c-accent-light: #9A5A12;
  --c-accent-dark: #F0B566;
  --c-canvas-light: #F4F6F3;
  --c-canvas-dark: #0F1311;
  --c-surface-light: #FFFFFF;
  --c-surface-dark: #1A1F1C;
  --c-textPrimary-light: #1A221C;
  --c-textPrimary-dark: #EEF2EE;
  --c-textSecondary-light: #5B655A;
  --c-textSecondary-dark: #A9B3AA;
  --c-outline-light: #7D877C;
  --c-outline-dark: #7F8A80;
  --c-divider-light: #E4E8E2;
  --c-divider-dark: #2A312D;
  --c-stateReady-light: #8A5300;
  --c-stateReady-dark: #F2B84B;
  --c-stateBest-light: #2E7040;
  --c-stateBest-dark: #6FD08A;
  --c-stateOverdue-light: #B3362B;
  --c-stateOverdue-dark: #FF8E82;
  --c-shelfPlank-light: #B08254;
  --c-shelfPlank-dark: #8A6240;
  --c-shelfPlankEdge-light: #6E4627;
  --c-shelfPlankEdge-dark: #4E331F;
  --c-jarLid-light: #AEB6AC;
  --c-jarLid-dark: #4A524B;
  --space-xxs: 2px;
  --space-xs: 4px;
  --space-s: 8px;
  --space-m: 12px;
  --space-l: 16px;
  --space-xl: 24px;
  --space-xxl: 32px;
  --space-xxxl: 48px;
  --radius-s: 8px;
  --radius-m: 14px;
  --radius-l: 22px;
  --radius-xl: 30px;
  --font-display: system-ui, sans-serif;
  --font-text: system-ui, sans-serif;
  --font-cjk: system-ui, sans-serif;
  --display-weight: 700;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
  --c-brand: #7FD19E;
    --c-onBrand: #0B2415;
    --c-accent: #F0B566;
    --c-canvas: #0F1311;
    --c-surface: #1A1F1C;
    --c-textPrimary: #EEF2EE;
    --c-textSecondary: #A9B3AA;
    --c-outline: #7F8A80;
    --c-divider: #2A312D;
    --c-stateReady: #F2B84B;
    --c-stateBest: #6FD08A;
    --c-stateOverdue: #FF8E82;
    --c-shelfPlank: #8A6240;
    --c-shelfPlankEdge: #4E331F;
    --c-jarLid: #4A524B;
  }
}
@media (prefers-contrast: more) {
  :root {
  --c-brand: #17502F;
    --c-onBrand: #FFFFFF;
    --c-accent: #6E3F08;
    --c-canvas: #F4F6F3;
    --c-surface: #FFFFFF;
    --c-textPrimary: #000000;
    --c-textSecondary: #33392F;
    --c-outline: #7D877C;
    --c-divider: #E4E8E2;
    --c-stateReady: #8A5300;
    --c-stateBest: #2E7040;
    --c-stateOverdue: #B3362B;
    --c-shelfPlank: #B08254;
    --c-shelfPlankEdge: #6E4627;
    --c-jarLid: #AEB6AC;
  }
}
@media (prefers-contrast: more) and (prefers-color-scheme: dark) {
  :root {
  --c-brand: #B5EBC8;
    --c-onBrand: #000000;
    --c-accent: #FFD49A;
    --c-canvas: #0F1311;
    --c-surface: #1A1F1C;
    --c-textPrimary: #FFFFFF;
    --c-textSecondary: #D8DDD1;
    --c-outline: #7F8A80;
    --c-divider: #2A312D;
    --c-stateReady: #F2B84B;
    --c-stateBest: #6FD08A;
    --c-stateOverdue: #FF8E82;
    --c-shelfPlank: #8A6240;
    --c-shelfPlankEdge: #4E331F;
    --c-jarLid: #4A524B;
  }
}
/* site.css —— 版式与组件。
   颜色、字体、间距、圆角全部用 build.py 从 tokens.json 生成的变量（--c-*、--font-*、--space-*、--radius-*），
   这里不写品牌色值。阴影用中性黑，按深浅色分两档。改视觉方向先改 lifecycle/website/design-direction.md。 */

:root {
  --wrap: 1160px;
  --gutter: clamp(20px, 5vw, 40px);
  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: clamp(1.125rem, 1.06rem + 0.3vw, 1.3125rem);
  --step-2: clamp(1.375rem, 1.22rem + 0.75vw, 1.75rem);
  --step-3: clamp(2rem, 1.45rem + 2.4vw, 3.25rem);
  --step-4: clamp(2.6rem, 1.55rem + 4.6vw, 5rem);
  --section: clamp(72px, 10vw, 136px);
  --hairline: 1px solid var(--c-divider);
  --wash: color-mix(in srgb, var(--c-brand) 7%, transparent);
  --shadow-device: 0 1px 2px rgb(16 20 28 / 0.06), 0 22px 48px -18px rgb(16 20 28 / 0.28);
  --screen-radius: 13.8% / 6.4%;
}
@media (prefers-color-scheme: dark) {
  :root { --shadow-device: 0 0 0 1px rgb(255 255 255 / 0.06), 0 24px 56px -16px rgb(0 0 0 / 0.7); --wash: color-mix(in srgb, var(--c-brand) 11%, transparent); }
}

/* ── 基础 ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--c-canvas);
  color: var(--c-textPrimary);
  font-family: var(--font-text);
  font-size: var(--step-0);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-kerning: normal;
}
html[lang^="zh"] body, html[lang^="ja"] body { line-height: 1.75; }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, p, ul, ol, dl, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: var(--c-brand); text-decoration-thickness: 1px; text-underline-offset: 0.2em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--c-brand); outline-offset: 3px; border-radius: 4px; }
::selection { background: color-mix(in srgb, var(--c-brand) 22%, transparent); }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; left: -9999px; top: 8px; }
.skip:focus { left: 8px; z-index: 10; background: var(--c-surface); padding: 8px 14px; border-radius: var(--radius-s); }
.muted { color: var(--c-textSecondary); }

/* ── 字体层级 ───────────────────────────────────────── */
.display {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  font-optical-sizing: auto;
  letter-spacing: -0.012em;
  line-height: 1.06;
  text-wrap: balance;
}
html[lang^="zh"] .display, html[lang^="ja"] .display { font-weight: 600; letter-spacing: 0.01em; line-height: 1.28; word-break: keep-all; overflow-wrap: break-word; }
h1.display { font-size: var(--step-4); }
.h2 { font-size: var(--step-3); }
.h3 { font-size: var(--step-1); font-weight: 600; }
.lead { font-size: var(--step-1); color: var(--c-textSecondary); max-width: 32em; text-wrap: pretty; }
html[lang^="zh"] .lead { max-width: 26em; }
.body-lg { font-size: var(--step-1); color: var(--c-textSecondary); max-width: 26em; text-wrap: pretty; }
.kicker { font-size: var(--step--1); font-weight: 600; color: var(--c-textSecondary); margin-bottom: var(--space-m); }
.label { display: inline-flex; align-items: center; gap: 10px; font-size: var(--step--1); font-weight: 600; color: var(--c-textSecondary); margin-bottom: var(--space-l); }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--c-brand); }

/* ── 页头 / 页脚 ────────────────────────────────────── */
.header-row { display: flex; align-items: center; justify-content: space-between; gap: var(--space-l); min-height: 76px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--c-textPrimary); text-decoration: none; font-weight: 650; letter-spacing: -0.01em; }
.brand-icon { border-radius: 22.37%; box-shadow: 0 0 0 1px var(--c-divider); }
.nav { display: flex; align-items: center; gap: clamp(14px, 3vw, 30px); font-size: 0.9375rem; }
.nav-link { color: var(--c-textSecondary); text-decoration: none; transition: color 0.15s ease; white-space: nowrap; }
.nav-link:hover, .nav-link[aria-current="page"] { color: var(--c-textPrimary); }
.nav-link[aria-current="page"] { text-decoration: underline; text-decoration-color: var(--c-brand); text-underline-offset: 0.45em; }
.nav-lang { padding: 4px 10px; border: var(--hairline); border-radius: 999px; }
@media (max-width: 600px) { .nav-features { display: none; } }

.site-footer { border-top: var(--hairline); margin-top: var(--section); padding-block: 56px 32px; font-size: 0.9375rem; }
.footer-grid { display: grid; gap: 40px; grid-template-columns: 1fr; }
.footer-line { color: var(--c-textSecondary); margin-top: var(--space-m); max-width: 24em; }
.footer-mail { margin-top: var(--space-s); }
.footer-cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.footer-h { font-size: var(--step--1); font-weight: 600; color: var(--c-textSecondary); margin-bottom: var(--space-m); }
.footer-cols li + li { margin-top: 8px; }
.footer-cols a { color: var(--c-textPrimary); text-decoration: none; }
.footer-cols a:hover { text-decoration: underline; }
.footer-base { margin-top: 48px; padding-top: 20px; border-top: var(--hairline); color: var(--c-textSecondary); font-size: var(--step--1); display: grid; gap: 6px; }
.footer-base a { color: inherit; }
@media (min-width: 860px) { .footer-grid { grid-template-columns: 5fr 7fr; } }

/* ── 商店徽章（官方素材原样使用：不改色、不加阴影、不做悬停动画） ───── */
.badges { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-top: var(--space-xl); }
.badge img { height: 48px; width: auto; }
.store-link { display: inline-block; padding: 12px 18px; border: 1px solid var(--c-outline); border-radius: var(--radius-s); color: var(--c-textPrimary); text-decoration: none; font-weight: 600; }
.soon { display: inline-block; padding: 10px 16px; border: var(--hairline); border-radius: 999px; color: var(--c-textSecondary); font-size: var(--step--1); }
.facts { margin-top: var(--space-l); font-size: var(--step--1); color: var(--c-textSecondary); }

/* ── 设备画面（不画苹果真机外观：只用圆角屏幕 + 细描边，见 references/design-and-taste.md §6） ── */
.device { width: var(--device-w, 300px); }
.device .screen, .press-item .screen { border-radius: var(--screen-radius); box-shadow: var(--shadow-device); background: var(--c-surface); }

/* ── 首屏 ─────────────────────────────────────────── */
.hero { padding-top: clamp(28px, 6vw, 72px); overflow: hidden; }
.hero-grid { display: grid; gap: clamp(36px, 6vw, 56px); align-items: center; }
.hero-title { max-width: 11em; }
html[lang^="zh"] .hero-title { max-width: 9em; }
.hero .lead { margin-top: var(--space-xl); }
.hero-stage {
  position: relative;
  height: clamp(420px, 64vw, 640px);
  -webkit-mask-image: linear-gradient(to bottom, #000 78%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 78%, transparent 100%);
}
/* 母题：胡桃木层板（来自 App 首页货架），两条横板托住手机 */
.shelf { position: absolute; inset: 0; pointer-events: none; }
.shelf span { position: absolute; left: 4%; right: 4%; height: 12px; border-radius: 6px; background: linear-gradient(to bottom, var(--c-shelfPlank), var(--c-shelfPlankEdge)); opacity: 0.9; }
.shelf span:first-child { top: 38%; }
.shelf span:last-child { top: 74%; }
.device--hero { --device-w: clamp(232px, 62vw, 304px); position: absolute; left: 50%; top: 56px; transform: translateX(-50%); }
@media (min-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); gap: 40px; }
  .hero { padding-bottom: 0; }
  .hero-copy { padding-bottom: 72px; }
}
@media (prefers-reduced-motion: no-preference) {
  .device--hero { animation: rise 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) both 0.1s; }
  @keyframes rise { from { opacity: 0; transform: translate(-50%, 14px); } to { opacity: 1; transform: translate(-50%, 0); } }
}

/* ── 功能（左右交替；每段一个画面，不做三栏卡片） ──────────────── */
.feature { padding-block: clamp(56px, 8vw, 104px); }
.feature:first-child { padding-top: clamp(40px, 6vw, 88px); }
.feature + .feature { border-top: var(--hairline); }
.feature-grid { display: grid; gap: 40px; align-items: center; }
.feature-copy .h2 { max-width: 12em; }
html[lang^="zh"] .feature-copy .h2 { max-width: 10em; }
.feature-copy .body-lg { margin-top: var(--space-l); }
.panel {
  position: relative;
  height: clamp(380px, 52vw, 540px);
  overflow: hidden;
  border-radius: var(--radius-xl);
  background: var(--c-surface);
  border: var(--hairline);
  display: flex; justify-content: center;
  padding-top: clamp(32px, 5vw, 56px);
}
.device--panel { --device-w: clamp(220px, 56vw, 290px); }
.panel::before {  /* 母题：和首屏同一块胡桃木层板，横在面板下部 */
  content: ""; position: absolute; left: 6%; right: 6%; bottom: 18%; height: 10px; border-radius: 5px; pointer-events: none; opacity: 0.85;
  background: linear-gradient(to bottom, var(--c-shelfPlank), var(--c-shelfPlankEdge));
}
.panel .device { position: relative; }
.panel--bottom { align-items: flex-end; padding-top: 0; padding-bottom: clamp(28px, 4vw, 44px); }
.panel--bottom::after {  /* 从底部对齐时，手机顶端被面板切掉：用面板底色渐隐，视线落到下半屏的关键画面 */
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 34%; pointer-events: none;
  background: linear-gradient(to bottom, var(--c-surface) 8%, transparent);
}
.panel--bottom.panel--dark::after { background: linear-gradient(to bottom, var(--c-canvas-dark) 8%, transparent); }
.panel--dark { background: var(--c-canvas-dark); border-color: var(--c-divider-dark); }
.panel--dark .screen { background: var(--c-surface-dark); }
@media (min-width: 900px) {
  .feature-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(48px, 7vw, 96px); }
  .feature--left .feature-grid { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); }
  .feature--left .feature-copy { order: 2; }
}

/* ── 通用分区 ───────────────────────────────────────── */
.section { padding-top: var(--section); }
.section--tight { padding-top: clamp(32px, 5vw, 56px); }
.split { display: grid; gap: 32px; }
@media (min-width: 900px) {
  .split { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 48px; }
  .split--even { grid-template-columns: 1fr 1fr; }
}
.ruled > li { border-top: var(--hairline); padding-block: 22px; display: grid; gap: 4px; }
.ruled > li:last-child { border-bottom: var(--hairline); }
.ruled strong { font-family: var(--font-display); font-weight: var(--display-weight); font-size: var(--step-2); line-height: 1.2; }
html[lang^="zh"] .ruled strong { font-weight: 600; }
.ruled span { color: var(--c-textSecondary); }
.ruled--plain > li { padding-block: 14px; }

.plans .h2 { max-width: 14em; }
.tiers { display: grid; gap: 0; margin-top: 40px; border-top: 2px solid var(--c-textPrimary); }
.tier { padding-block: 24px 28px; }
.tier + .tier { border-top: var(--hairline); }
.tier-name { font-size: var(--step-2); margin-bottom: var(--space-l); }
.checks li { position: relative; padding-left: 28px; margin-top: 10px; }
.checks li::before { content: ""; position: absolute; left: 4px; top: 0.42em; width: 11px; height: 6px; border-left: 2px solid var(--c-brand); border-bottom: 2px solid var(--c-brand); transform: rotate(-45deg); }
.note { margin-top: var(--space-l); color: var(--c-textSecondary); font-size: var(--step--1); max-width: 44em; }
@media (min-width: 760px) {
  .tiers { grid-template-columns: 1fr 1fr; }
  .tier { padding-right: 32px; }
  .tier + .tier { border-top: 0; border-left: var(--hairline); padding-left: 32px; }
}

.qa details { border-top: var(--hairline); }
.qa details:last-child { border-bottom: var(--hairline); }
.qa summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; padding-block: 20px; font-size: var(--step-1); font-weight: 600; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: "+"; color: var(--c-textSecondary); font-weight: 400; font-size: 1.4em; line-height: 0.9; }
.qa details[open] summary::after { content: "−"; }
.qa details p { padding-bottom: 22px; color: var(--c-textSecondary); max-width: 36em; }

.cta-band { display: grid; gap: 8px; padding: clamp(32px, 6vw, 64px); border-radius: var(--radius-xl); background: var(--c-surface); border: var(--hairline); }
.cta-band .muted { margin-top: var(--space-s); }
.cta-band .badges { margin-top: var(--space-l); }
@media (min-width: 860px) { .cta-band { grid-template-columns: 1fr auto; align-items: end; } .cta-band .badges { margin-top: 0; } }
@media (max-width: 420px) { .cta-band .badges { gap: 12px; } .cta-band .badge img { height: 40px; } }  /* 窄屏收尾区两个徽章并排放得下；仍不小于 App Store 要求的 40 px */

/* ── 子页面 ───────────────────────────────────────── */
.page-head { padding-top: clamp(40px, 7vw, 96px); }
.page-head h1.display { font-size: clamp(2.4rem, 1.7rem + 3vw, 3.75rem); max-width: 14em; }
.page-head .lead { margin-top: var(--space-l); }
.prose { max-width: 40rem; margin-top: 40px; }
html[lang^="zh"] .prose { max-width: 36rem; }
.prose h2 { font-size: var(--step-1); font-weight: 650; margin-top: 2.2em; margin-bottom: 0.6em; }
.prose p, .prose ul, .prose ol, .prose blockquote { margin-bottom: 1em; }
.prose ul { list-style: disc; padding-left: 1.25em; }
.prose ol { list-style: decimal; padding-left: 1.25em; }
.prose li + li { margin-top: 0.4em; }
.prose a { overflow-wrap: anywhere; }
.prose blockquote { border-left: 3px solid var(--c-divider); padding-left: 1em; color: var(--c-textSecondary); }
.page-date { margin-top: var(--space-m); }
.legal-grid { display: grid; gap: 48px; margin-top: 40px; }
.legal .prose { margin-top: 0; }
.prose h2 { scroll-margin-top: 24px; }
.toc { display: none; }
@media (min-width: 1100px) {
  .legal-grid { grid-template-columns: minmax(0, 40rem) minmax(0, 1fr); gap: 80px; }
  .toc { display: block; position: sticky; top: 32px; align-self: start; font-size: var(--step--1); border-left: var(--hairline); padding-left: 20px; }
  .toc li + li { margin-top: 8px; }
  .toc a { color: var(--c-textSecondary); text-decoration: none; }
  .toc a:hover { color: var(--c-textPrimary); }
}

.contact-mail { font-size: var(--step-2); font-weight: 600; letter-spacing: -0.01em; margin-block: 4px 12px; overflow-wrap: anywhere; }
.contact-mail a { text-decoration: none; }
.contact-mail a:hover { text-decoration: underline; }
.contact .muted + .muted { margin-top: 8px; }
.topic { border-top: var(--hairline); padding-block: 22px; }
.topic:last-child { border-bottom: var(--hairline); }
.topic-q { font-size: var(--step-1); font-weight: 600; margin-bottom: 6px; }
.topic p { color: var(--c-textSecondary); max-width: 36em; }
.links { margin-top: 10px; display: grid; gap: 6px; }

.steps-grid { display: grid; gap: 20px; margin-bottom: 48px; }
.step-card { border: var(--hairline); border-radius: var(--radius-l); padding: 28px; background: var(--c-surface); }
.steps { counter-reset: s; display: grid; gap: 12px; }
.steps li { counter-increment: s; display: grid; grid-template-columns: 28px 1fr; gap: 8px; }
.steps li::before { content: counter(s); width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--c-outline); font-size: 0.8125rem; display: grid; place-items: center; margin-top: 0.15em; }
@media (min-width: 760px) { .steps-grid { grid-template-columns: 1fr 1fr; } }

.releases { display: grid; }
.release { display: grid; gap: 12px; border-top: var(--hairline); padding-block: 28px; }
.release-meta { display: flex; align-items: baseline; gap: 14px; }
.release-v { font-size: var(--step-2); }
.release time { color: var(--c-textSecondary); font-size: var(--step--1); }
.release ul { display: grid; gap: 6px; }
.release ul li { padding-left: 18px; position: relative; }
.release ul li::before { content: ""; position: absolute; left: 0; top: 0.7em; width: 6px; height: 6px; border-radius: 50%; background: var(--c-divider); }
@media (min-width: 760px) { .release { grid-template-columns: 220px 1fr; } }

.facts-list div { display: grid; grid-template-columns: 9em 1fr; gap: 12px; border-top: var(--hairline); padding-block: 12px; }
.facts-list dt { color: var(--c-textSecondary); }
.facts-list dd { margin: 0; }
.press-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 28px 20px; margin-block: 28px 56px; }
.press-item { display: grid; gap: 10px; justify-items: start; font-size: var(--step--1); color: var(--c-textSecondary); }
.press-icon img { border-radius: 22.37%; box-shadow: 0 0 0 1px var(--c-divider); }

.post-list li { border-top: var(--hairline); }
.post-list a { display: grid; gap: 6px; padding-block: 24px; text-decoration: none; color: inherit; }
.post-list time { font-size: var(--step--1); color: var(--c-textSecondary); }
.post-title { font-size: var(--step-2); }
.post-list a:hover .post-title { text-decoration: underline; text-decoration-thickness: 1px; }
.post .lead { margin-top: var(--space-l); }
.post-cta { margin-top: 48px; padding-top: 8px; border-top: var(--hairline); max-width: 40rem; }
.notfound .text-link { font-weight: 600; }
.notfound .lead { margin-bottom: var(--space-xl); }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}
@media print {
  .site-header, .site-footer, .badges, .hero-stage, .feature-media { display: none; }
}
