:root {
  --bg: #FFFFFF;
  --bg-panel: #F7F7F8;
  --bg-panel-2: #EFEFF1;
  --border: #E4E4E7;
  --accent: #0A70EB;
  --accent-dark: #0756B8;
  --text: #18181B;
  --text-muted: #6B6B73;
  --success: #2E9E5B;
  --warn: #EE8A1F;
  --error: #D93B3B;
  --ink-rgb: 24 24 27;
  --text-faint: color-mix(in srgb, var(--text-muted) 62%, var(--bg));
  --line-soft: color-mix(in srgb, var(--border) 62%, var(--bg));
  --accent-soft: color-mix(in srgb, var(--accent) 9%, var(--bg));
  --accent-line: color-mix(in srgb, var(--accent) 26%, var(--bg));
  --accent-wash: color-mix(in srgb, var(--accent) 8%, transparent);
  --warn-soft: color-mix(in srgb, var(--warn) 8%, var(--bg));
  --warn-edge: color-mix(in srgb, var(--warn) 42%, var(--bg));
  --warn-ink: color-mix(in srgb, var(--warn) 56%, var(--text));
  --sheen: color-mix(in srgb, var(--bg) 22%, transparent);
  --veil: rgb(var(--ink-rgb) / .22);
  --clear: transparent;
  --font-display: "Inter", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-body: "Inter", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --r-plate: 28px;
  --r-card: 18px;
  --r-win: 16px;
  --r-btn: 12px;
  --r-chip: 10px;
  --r-sm: 8px;
  --r-code: 6px;
  --r-pill: 999px;
  --r-circle: 50%;
  --shadow-hair: 0 1px 1px rgb(var(--ink-rgb) / .04);
  --shadow-card: 0 1px 2px rgb(var(--ink-rgb) / .05), 0 8px 22px -10px rgb(var(--ink-rgb) / .12);
  --shadow-win: 0 0 0 1px var(--border), 0 1px 2px rgb(var(--ink-rgb) / .04), 0 14px 28px -10px rgb(var(--ink-rgb) / .08), 0 52px 110px -28px rgb(var(--ink-rgb) / .18);
  --shadow-memo: 0 1px 2px rgb(var(--ink-rgb) / .06), 0 10px 24px -8px rgb(var(--ink-rgb) / .16);
  --shadow-primary: 0 1px 2px color-mix(in srgb, var(--accent) 40%, transparent), 0 8px 20px -8px color-mix(in srgb, var(--accent) 55%, transparent), inset 0 1px 0 var(--sheen);
  --shadow-switch: 0 1px 2px rgb(var(--ink-rgb) / .22);
  --shadow-fab: 0 14px 30px -12px rgb(var(--ink-rgb) / .3);
  --shadow-light: inset 0 0 0 .5px rgb(var(--ink-rgb) / .14);
  --gutter: 40px;
  --content-max: 1200px;
  --reading-max: 800px;
  --nav-h: 72px;
  --peek: 44px;
  --section-space: 88px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --fast: 150ms;
  --reveal-time: 600ms;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 28px; }
html, body { margin: 0; padding: 0; }
html.nav-open { overflow: hidden; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
[hidden] { display: none !important; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button, summary, a { -webkit-tap-highlight-color: var(--accent-wash); }
button { cursor: pointer; }
button { color: var(--text); }
button:disabled { cursor: not-allowed; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
svg, .dot, .step-mark { flex-shrink: 0; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
::selection { background: var(--accent-soft); color: var(--text); }
h1, h2, h3, h4 { font-family: var(--font-display); text-wrap: balance; }
h1 { font-size: clamp(34px, 3.4vw, 48px); line-height: 1.14; font-weight: 800; letter-spacing: -.02em; }
h2 { font-size: clamp(25px, 2.6vw, 34px); line-height: 1.25; letter-spacing: -.02em; font-weight: 800; }
h3 { font-size: 21px; line-height: 1.4; font-weight: 700; letter-spacing: -.01em; }
p { margin-top: 0; }
code, pre, kbd { font-family: var(--font-mono); }
code { overflow-wrap: anywhere; font-size: .9em; }
pre { max-width: 100%; overflow-x: auto; padding: 20px; border: 1px solid var(--border); border-radius: var(--r-btn); background: var(--bg-panel); color: var(--text); font-size: 13px; line-height: 1.75; }
pre code { overflow-wrap: normal; word-break: normal; white-space: pre; font-size: inherit; }
hr { border: 0; border-top: 1px solid var(--border); margin-block: 32px; }
.wrap { width: 100%; max-width: calc(var(--content-max) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.frame { max-width: 1440px; margin-inline: auto; padding-inline: var(--gutter); }
.reading { width: 100%; max-width: calc(var(--reading-max) + var(--gutter) * 2); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-top: var(--section-space); padding-bottom: var(--section-space); }
.section-heading { margin-bottom: 36px; }
.section-heading h2 { margin-top: 0; margin-bottom: 12px; }
.section-heading p { color: var(--text-muted); max-width: 640px; margin-inline: auto; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.muted { color: var(--text-muted); }
.accent-text { color: var(--accent-dark); }
.stack > * + * { margin-top: 20px; }
.grid { display: grid; gap: 24px; }
.grid-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid > *, .hero-grid > *, .footer-grid > *, .review-layout > * { min-width: 0; }
.card, .panel { min-width: 0; border: 1px solid var(--border); }
.card { border-radius: var(--r-card); background: var(--bg); color: var(--text); padding: 28px; box-shadow: var(--shadow-card); }
.card h3 { margin-top: 0; margin-bottom: 10px; }
.card p:last-child { margin-bottom: 0; }
.panel { border-radius: var(--r-plate); background: var(--bg-panel); color: var(--text); padding: 40px; }
.card-link { display: block; transition: transform var(--fast) var(--ease), box-shadow var(--fast) var(--ease); }
.card-link:hover { transform: translateY(-3px); box-shadow: var(--shadow-memo); }
.prose { min-width: 0; line-height: 1.85; }
.prose h2 { margin-top: 56px; margin-bottom: 20px; }
.prose h3 { margin-top: 32px; margin-bottom: 14px; }
.prose a { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 3px; }
.prose p, .prose li { overflow-wrap: break-word; }
.prose li + li { margin-top: 8px; }
.prose :not(pre) > code { padding: 2px 5px; border-radius: var(--r-code); background: var(--bg-panel-2); color: var(--text); }
.prose img { max-width: 100%; }
.ic { fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.btn {
  display: inline-flex; justify-content: center; align-items: center; gap: 9px;
  min-height: 48px; padding: 10px 22px; border: 1px solid var(--clear);
  border-radius: var(--r-btn); font-size: 15.5px; font-weight: 600; letter-spacing: -.005em;
  text-decoration: none; transition: background-color var(--fast) ease, border-color var(--fast) ease;
}
.btn svg { width: 17px; height: 17px; }
.btn-main { background: var(--accent); color: var(--bg); box-shadow: var(--shadow-primary); }
.btn-main:hover, .btn-main.is-hover { background: var(--accent-dark); color: var(--bg); }
.btn-alt { background: var(--bg); color: var(--text); border-color: var(--border); box-shadow: var(--shadow-hair); }
.btn-alt svg { color: var(--text-muted); }
.btn-alt:hover, .btn-alt.is-hover { border-color: var(--text-faint); background: var(--bg-panel); color: var(--text); }
.btn:active, .btn.is-pressed { transform: translateY(1px); }
.btn:disabled, .btn[aria-disabled="true"] { background: var(--bg-panel-2); color: var(--text-muted); box-shadow: none; border-color: var(--border); }
.btn[aria-disabled="true"] { pointer-events: none; }
.btn.is-focus { outline: 3px solid var(--accent); outline-offset: 4px; }
.button-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.skip-link { position: fixed; top: 8px; left: 16px; z-index: 100; padding: 10px 16px; background: var(--bg); color: var(--accent-dark); border-radius: var(--r-sm); box-shadow: var(--shadow-card); transform: translateY(-160%); }
.skip-link:focus { transform: none; }
/* 页头独立宽版心，不复用阅读版心。 */
.masthead { height: var(--nav-h); position: relative; z-index: 40; background: var(--bg); color: var(--text); }
.masthead .header-frame {
  width: 100%; max-width: min(100%, calc(1280px + var(--gutter) * 2));
  margin-inline: auto; padding-inline: var(--gutter); height: 100%;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand-mark { width: 30px; height: 30px; flex-shrink: 0; }
.brand-name { font-family: var(--font-display); font-weight: 800; font-size: 18px; letter-spacing: -.015em; color: var(--text); }
.desktop-nav { margin-left: auto; min-width: 0; }
.dotline { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; font-size: 14.5px; }
.dotline li { display: flex; align-items: center; gap: 4px; flex-shrink: 0; }
.dotline li + li::before { content: "·"; color: var(--text-faint); font-size: 13px; user-select: none; }
.dotline a { display: block; color: var(--text-muted); padding: 6px; border-radius: var(--r-sm); transition: color var(--fast) ease; white-space: nowrap; }
.dotline a:hover { color: var(--text); }
.dotline a[aria-current="page"] { color: var(--text); font-weight: 600; }
.header-tools { display: flex; align-items: center; gap: 10px; flex-shrink: 0; margin-left: 4px; }
.language-picker { position: relative; }
.lang { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 38px; padding-inline: 14px; border: 1px solid var(--border); border-radius: var(--r-btn); background: var(--bg); color: var(--text); font-size: 14px; box-shadow: var(--shadow-hair); white-space: nowrap; }
.lang svg { width: 15px; height: 15px; color: var(--text-muted); }
.caret { color: var(--text-muted); font-size: 11px; }
.language-menu { position: absolute; top: calc(100% + 10px); right: 0; width: 190px; padding: 8px; margin: 0; list-style: none; border: 1px solid var(--border); border-radius: var(--r-btn); background: var(--bg); color: var(--text); box-shadow: var(--shadow-memo); z-index: 4; }
.language-menu a { display: flex; align-items: center; min-height: 44px; padding: 10px 12px; border-radius: var(--r-sm); }
.language-menu a:hover, .language-menu a[aria-current] { background: var(--bg-panel); color: var(--accent-dark); }
.menu-toggle { display: none; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; padding: 10px; border: 1px solid var(--border); border-radius: var(--r-btn); background: var(--bg); color: var(--text); }
.menu-toggle svg { width: 20px; height: 20px; }
.mobile-drawer { display: none; }
.nav-veil { position: fixed; inset: var(--nav-h) 0 0; z-index: 30; border: 0; background: var(--veil); color: var(--text); }
.static-mobile { display: none; }
/* 默认可读；只有观察器成功初始化才启用隐藏态。 */
.reveal { opacity: 1; transform: none; }
.reveal-ready .reveal:not(.shown) { opacity: 0; transform: translateY(18px); }
.reveal-ready .reveal { transition: opacity var(--reveal-time) var(--ease), transform var(--reveal-time) var(--ease); }
.reveal-ready .reveal.shown { opacity: 1; transform: none; }
.site-footer { position: relative; z-index: 6; border-top: 1px solid var(--border); background: var(--bg); color: var(--text); padding-top: 64px; padding-bottom: 88px; }
.footer-grid { display: grid; grid-template-columns: 1.3fr .8fr 1.5fr .7fr; gap: 40px; }
.footer-brand p { margin-top: 18px; max-width: 280px; color: var(--text-muted); font-size: 14px; }
.footer-title { font-size: 14px; font-weight: 700; margin: 0 0 16px; }
.footer-links { list-style: none; margin: 0; padding: 0; }
.footer-links a { display: block; padding-block: 5px; color: var(--text-muted); font-size: 14px; }
.footer-links a:hover { color: var(--accent-dark); }
.footer-links a[aria-current] { color: var(--text); font-weight: 600; }
.footer-bottom { margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--border); color: var(--text-muted); font-size: 13px; }
@media (max-width: 1100px) {
  .desktop-nav { display: none; }
  .header-tools { margin-left: auto; }
  .menu-toggle { display: inline-flex; }
  .mobile-drawer:not([hidden]) { display: block; }
  .mobile-drawer {
    position: absolute; top: var(--nav-h); inset-inline: 0; z-index: 3;
    max-height: calc(100dvh - var(--nav-h)); overflow-y: auto; overscroll-behavior: contain;
    padding: 16px var(--gutter) 24px; border-block: 1px solid var(--border);
    background: var(--bg); color: var(--text); box-shadow: var(--shadow-card);
  }
  .mobile-drawer ul { list-style: none; margin: 0; padding: 0; }
  .mobile-drawer a { display: flex; align-items: center; width: 100%; min-height: 46px; padding: 11px 12px; border-radius: var(--r-sm); }
  .mobile-drawer a:hover, .mobile-drawer a[aria-current] { background: var(--bg-panel); color: var(--accent-dark); }
  .drawer-languages { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--border); }
  .static-mobile { display: block; position: relative; }
  .static-mobile summary { list-style: none; min-width: 44px; min-height: 44px; display: grid; place-items: center; border: 1px solid var(--border); border-radius: var(--r-btn); background: var(--bg); color: var(--text); }
  .static-mobile nav { position: absolute; right: 0; top: 52px; width: min(280px, calc(100vw - 40px)); background: var(--bg); color: var(--text); border: 1px solid var(--border); border-radius: var(--r-btn); padding: 10px; box-shadow: var(--shadow-card); }
  .static-mobile nav a { display: block; padding: 11px 12px; min-height: 44px; }
}
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px; }
  .grid-three { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 768px) {
  :root { --gutter: 24px; --section-space: 56px; }
  h1 { font-size: clamp(24px, 5vw, 30px); }
  .grid-two, .grid-three { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  :root { --gutter: 20px; }
  .brand-name { font-size: 16px; }
  .brand { gap: 7px; }
  .brand-mark { width: 27px; height: 27px; }
  .masthead .header-frame { gap: 8px; }
  .header-tools { gap: 6px; margin-left: auto; }
  .lang { padding-inline: 9px; gap: 5px; }
  .lang svg { display: none; }
  .panel { padding: 24px 20px; }
  .card { padding: 24px 20px; }
  .footer-grid { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .footer-links a { min-height: 40px; padding-block: 8px; }
  .tilt, [data-tilt] { transform: none !important; }
}
@media (max-width: 359px) {
  :root { --gutter: 16px; }
  .brand-name { font-size: 14px; }
  .lang { font-size: 12px; padding-inline: 7px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal-ready .reveal:not(.shown) { opacity: 1; transform: none; }
}