:root {
  color-scheme: light;
  --c-bg: #ffffff;
  --c-panel: #f3f3f3;
  --c-canvas: #17130d;
  --c-border: #e2e2e0;
  --c-accent: #d2f065;
  --c-accent-dark: #4c7a1c;
  --c-text: #16150f;
  --c-muted: #5f5e58;
  --c-success: #2f8a3e;
  --c-warn: #b7791f;
  --c-error: #c8372d;
  --c-clear: transparent;
  --c-mask: #000000;
  --c-on-canvas: #f4f1e9;
  --c-on-canvas-muted: rgba(244, 241, 233, 0.72);
  --c-on-canvas-faint: rgba(244, 241, 233, 0.5);
  --c-canvas-line: rgba(244, 241, 233, 0.13);
  --c-canvas-line-soft: rgba(244, 241, 233, 0.08);
  --c-canvas-line-strong: rgba(244, 241, 233, 0.34);
  --c-canvas-fill: rgba(244, 241, 233, 0.06);
  --c-canvas-fill-hover: rgba(244, 241, 233, 0.12);
  --c-amber-core: rgba(212, 166, 110, 0.6);
  --c-amber-mid: rgba(156, 112, 64, 0.26);
  --c-amber-shaft: rgba(224, 184, 130, 0.08);
  --c-amber-halo: rgba(196, 146, 88, 0.24);
  --c-amber-rim: rgba(255, 222, 178, 0.3);
  --c-shade: rgba(8, 6, 3, 0.55);
  --c-accent-glow: rgba(210, 240, 101, 0.3);
  --c-accent-ring: rgba(210, 240, 101, 0.18);
  --c-metal-hi: #7a746a;
  --c-metal: #3b3832;
  --c-metal-lo: #1c1a16;
  --c-glass: #050403;
  --c-screen-hi: #c99a62;
  --c-screen-mid: #6e4c2b;
  --c-screen-bright: rgba(242, 198, 140, 0.55);
  --c-glare: rgba(255, 255, 255, 0.12);
  --c-mark-hi: #fbfbfa;
  --shadow-card-far: 0 1px 2px rgba(22, 21, 15, 0.06), 0 14px 28px -16px rgba(0, 0, 0, 0.5), 0 34px 60px -34px rgba(0, 0, 0, 0.5);
  --shadow-card-near: 0 1px 2px rgba(22, 21, 15, 0.08), 0 22px 40px -18px rgba(0, 0, 0, 0.58), 0 52px 90px -40px rgba(0, 0, 0, 0.62);
  --shadow-phone: 0 60px 100px -36px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(0, 0, 0, 0.6);
  --shadow-cta: 0 14px 32px -14px var(--c-accent-glow);
  --shadow-fab: 0 12px 30px -12px rgba(22, 21, 15, 0.38), 0 2px 6px rgba(22, 21, 15, 0.1);
  --shadow-soft: 0 12px 30px -18px rgba(22, 21, 15, 0.2);
  --f-display: "Inter", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --f-body: "Inter", "Noto Sans SC", -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --fs-xs: 12px;
  --fs-sm: 14px;
  --fs-body: 16px;
  --fs-lead: 20px;
  --fs-h1: clamp(34px, 3.35vw, 48px);
  --fs-h2: clamp(28px, 3vw, 42px);
  --fs-h3: clamp(21px, 2vw, 28px);
  --fw-normal: 400;
  --fw-medium: 500;
  --fw-semibold: 650;
  --fw-bold: 700;
  --fw-display: 800;
  --tracking-display: -0.025em;
  --tracking-cjk: -0.02em;
  --r-canvas: 32px;
  --r-card: 20px;
  --r-mark: 10px;
  --r-shot: 10px;
  --r-small: 8px;
  --r-key: 2px;
  --r-mobile-canvas: 24px;
  --r-pill: 999px;
  --r-circle: 50%;
  --r-phone: 48px;
  --r-screen: 40px;
  --head-h: 72px;
  --gutter: 32px;
  --edge: 24px;
  --canvas-pad: 80px;
  --content-w: 1200px;
  --reading-w: 800px;
  --header-w: 1280px;
  --section-gap: 144px;
  --stage-col: 620px;
  --stage-scale: 1;
  --t-fast: 0.2s;
  --t-reveal: 0.65s;
  --ease-enter: cubic-bezier(0.2, 0.7, 0.2, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--head-h) + 24px);
}

html.nav-open {
  overflow: hidden;
}

body {
  margin: 0;
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--f-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

[hidden] {
  display: none !important;
}

a {
  color: inherit;
  text-decoration: none;
}

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

button {
  cursor: pointer;
}

button,
input,
select,
textarea {
  max-width: 100%;
}

button {
  color: inherit;
}

img {
  max-width: 100%;
}

svg {
  display: block;
  flex-shrink: 0;
}

ul,
ol {
  padding-left: 1.4em;
}

h1,
h2,
h3,
h4 {
  font-family: var(--f-display);
  font-weight: var(--fw-display);
  letter-spacing: var(--tracking-display);
  line-height: 1.2;
  text-wrap: balance;
  overflow-wrap: break-word;
}

:lang(zh-CN) h1,
:lang(zh-CN) h2,
:lang(zh-CN) h3,
:lang(zh-TW) h1,
:lang(zh-TW) h2,
:lang(zh-TW) h3,
:lang(ja) h1,
:lang(ja) h2,
:lang(ja) h3 {
  letter-spacing: var(--tracking-cjk);
}

h1 {
  font-size: var(--fs-h1);
}

h2 {
  font-size: var(--fs-h2);
}

h3 {
  font-size: var(--fs-h3);
}

p {
  margin-top: 0;
  margin-bottom: 1.2em;
}

strong {
  font-weight: var(--fw-semibold);
}

code,
pre,
kbd,
samp {
  font-family: var(--f-mono);
}

code {
  overflow-wrap: anywhere;
  font-size: 0.9em;
}

pre {
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  padding: 24px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  background: var(--c-panel);
  color: var(--c-text);
  line-height: 1.8;
  overscroll-behavior-x: contain;
}

pre code {
  font-size: var(--fs-sm);
  white-space: pre;
  overflow-wrap: normal;
  word-break: normal;
}

:focus-visible {
  outline: 2px solid var(--c-accent-dark);
  outline-offset: 4px;
  border-radius: var(--r-small);
}

::selection {
  background: var(--c-accent);
  color: var(--c-text);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: var(--gutter);
  z-index: 100;
  padding: 10px 20px;
  border-radius: var(--r-pill);
  background: var(--c-accent);
  color: var(--c-text);
  transform: translateY(-180%);
}

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

.wrap {
  width: 100%;
  max-width: calc(var(--content-w) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.wrap--reading {
  max-width: calc(var(--reading-w) + var(--gutter) * 2);
}

.section {
  padding-top: var(--section-gap);
  padding-bottom: 0;
}

.section:last-child {
  padding-bottom: var(--section-gap);
}

.section-head {
  max-width: 820px;
  margin: 0 auto 64px;
  text-align: center;
}

.section-head h2 {
  margin-top: 0;
  margin-bottom: 24px;
}

.section-head p {
  color: var(--c-muted);
  max-width: 680px;
  margin-inline: auto;
}

.section-head .btn {
  margin-top: 16px;
}

.keep {
  white-space: nowrap;
}

.accent {
  color: var(--c-accent-dark);
}

.muted {
  color: var(--c-muted);
}

.lead {
  font-size: var(--fs-lead);
  line-height: 1.7;
  color: var(--c-muted);
}

.eyebrow {
  color: var(--c-accent-dark);
  font-size: var(--fs-xs);
  font-weight: var(--fw-bold);
  letter-spacing: 0.08em;
}

.grid-two,
.grid-three {
  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-two > *,
.grid-three > *,
.panel > *,
.card > *,
.hero__canvas > *,
.site-foot__grid > *,
.gallery-panel > * {
  min-width: 0;
}

.card,
.panel {
  min-width: 0;
  border: 1px solid var(--c-border);
  background: var(--c-bg);
  color: var(--c-text);
}

.card {
  padding: 28px;
  border-radius: var(--r-card);
  box-shadow: var(--shadow-soft);
}

.panel {
  padding: 48px;
  border-radius: var(--r-canvas);
  background: var(--c-panel);
  color: var(--c-text);
}

.card h3,
.panel h3 {
  margin-top: 0;
}

.card > :last-child,
.panel > :last-child {
  margin-bottom: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  max-width: 100%;
  padding: 12px 26px;
  border: 1px solid var(--c-clear);
  border-radius: var(--r-pill);
  font-family: var(--f-body);
  font-size: 15.5px;
  font-weight: var(--fw-semibold);
  line-height: 1.3;
  text-align: center;
  transition: transform var(--t-fast) ease, background-color var(--t-fast) ease, border-color var(--t-fast) ease;
}

.btn svg {
  width: 18px;
  height: 18px;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:active {
  transform: none;
}

.btn--primary {
  padding-left: 22px;
  background: var(--c-accent);
  color: var(--c-text);
  box-shadow: var(--shadow-cta);
}

.btn--secondary {
  border-color: var(--c-border);
  background: var(--c-bg);
  color: var(--c-text);
}

.btn--secondary:hover {
  background: var(--c-panel);
  color: var(--c-text);
}

.btn--ghost {
  border-color: var(--c-canvas-line-strong);
  background: var(--c-canvas-fill);
  color: var(--c-on-canvas);
}

.btn--ghost:hover {
  border-color: var(--c-on-canvas-muted);
  background: var(--c-canvas-fill-hover);
  color: var(--c-on-canvas);
}

.btn:disabled,
.btn[aria-disabled="true"] {
  background: var(--c-panel);
  color: var(--c-muted);
  border-color: var(--c-border);
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}

.text-link {
  color: var(--c-accent-dark);
  text-decoration: underline;
  text-underline-offset: 0.22em;
  font-weight: var(--fw-semibold);
}

.prose,
.article-body {
  min-width: 0;
  overflow-wrap: break-word;
}

.prose h2,
.article-body h2 {
  margin-top: 2.5em;
}

.prose h3,
.article-body h3 {
  margin-top: 2em;
}

.prose a:not(.btn):not(.store-button),
.article-body a:not(.btn):not(.store-button) {
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.prose li,
.article-body li {
  padding-left: 0.25em;
  margin-bottom: 0.6em;
}

.prose blockquote {
  margin-inline: 0;
}

.decorated,
.hero,
.feature-gallery {
  overflow-x: clip;
}

.reveal {
  opacity: 1;
  transform: none;
}

.reveal-ready .reveal:not(.shown) {
  opacity: 0;
  transform: translateY(20px);
}

.reveal-ready .reveal {
  transition: opacity var(--t-reveal) var(--ease-enter), transform var(--t-reveal) var(--ease-enter);
}

.reveal-ready .reveal.shown {
  opacity: 1;
  transform: none;
}

/* 页头单独使用宽版心，不借用正文 wrap。 */
.site-head {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--c-bg);
  color: var(--c-text);
  border-bottom: 1px solid var(--c-border);
}

.site-head__inner {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: min(100%, calc(var(--header-w) + var(--gutter) * 2));
  height: var(--head-h);
  margin-inline: auto;
  padding-inline: var(--gutter);
  display: flex;
  align-items: center;
  gap: 28px;
  background: var(--c-bg);
  color: var(--c-text);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-right: auto;
  flex-shrink: 0;
}

.brand__mark {
  display: block;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
  border-radius: var(--r-circle);
}

.brand__placeholder {
  border-radius: var(--r-mark);
  background: linear-gradient(145deg, var(--c-mark-hi), var(--c-panel) 55%, var(--c-border));
  color: var(--c-text);
  border: 1px solid var(--c-border);
}

.brand__name {
  font-family: var(--f-display);
  font-weight: var(--fw-display);
  font-size: 17px;
  letter-spacing: -0.015em;
}

.brand__tag {
  font-size: var(--fs-xs);
  font-weight: var(--fw-semibold);
  color: var(--c-muted);
  padding: 2px 8px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-pill);
}

.main-nav {
  min-width: 0;
}

.main-nav__list {
  display: flex;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 2px;
}

.main-nav__link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 13px;
  border-radius: var(--r-pill);
  color: var(--c-muted);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
  white-space: nowrap;
  transition: background-color var(--t-fast) ease, color var(--t-fast) ease;
}

.main-nav__link svg {
  width: 16px;
  height: 16px;
}

.main-nav__link:hover,
.main-nav__link[aria-current="page"] {
  background: var(--c-panel);
  color: var(--c-text);
}

.main-nav__link[aria-current="page"] {
  font-weight: var(--fw-semibold);
}

.main-nav__link[aria-current="page"] svg {
  color: var(--c-accent-dark);
}

.head-tools {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.language {
  position: relative;
}

.lang-switch,
.menu-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 44px;
  padding: 8px 14px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-pill);
  background: var(--c-bg);
  color: var(--c-text);
  font-size: var(--fs-sm);
  font-weight: var(--fw-medium);
}

.lang-switch svg {
  width: 16px;
  height: 16px;
  color: var(--c-muted);
}

.lang-switch__short {
  display: none;
}

.lang-switch__caret {
  color: var(--c-muted);
  font-size: var(--fs-xs);
}

.lang-switch:hover {
  border-color: var(--c-muted);
}

.language__list {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 6;
  width: 196px;
  margin: 0;
  padding: 8px;
  list-style: none;
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  background: var(--c-bg);
  color: var(--c-text);
  box-shadow: var(--shadow-soft);
}

.language__list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 44px;
  padding: 10px 14px;
  border-radius: var(--r-small);
}

.language__list a:hover,
.language__list a[aria-current="true"] {
  background: var(--c-panel);
  color: var(--c-text);
}

.menu-toggle {
  display: none;
  min-width: 44px;
  padding: 10px;
}

.menu-toggle svg {
  width: 22px;
  height: 22px;
}

.mobile-drawer {
  position: absolute;
  top: 100%;
  right: 0;
  left: 0;
  z-index: 5;
  max-height: calc(100dvh - var(--head-h));
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 16px var(--gutter) 28px;
  border-top: 1px solid var(--c-border);
  border-bottom: 1px solid var(--c-border);
  background: var(--c-bg);
  color: var(--c-text);
}

.mobile-drawer ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.mobile-drawer a {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 48px;
  padding: 12px 16px;
  border-radius: var(--r-small);
}

.mobile-drawer a svg {
  width: 18px;
  height: 18px;
}

.mobile-drawer a:hover,
.mobile-drawer a[aria-current] {
  background: var(--c-panel);
  color: var(--c-text);
}

.mobile-drawer__languages {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--c-border);
}

.mobile-drawer__label {
  margin: 0 16px 8px;
  color: var(--c-muted);
  font-size: var(--fs-xs);
}

.nav-veil {
  position: fixed;
  z-index: 0;
  inset: var(--head-h) 0 0;
  padding: 0;
  border: 0;
  background: var(--c-shade);
  color: var(--c-on-canvas);
}

/* 页脚为白底阅读区保留充足下边距，避开常驻入口。 */
.site-foot {
  margin-top: var(--section-gap);
  padding-top: 64px;
  padding-bottom: 112px;
  border-top: 1px solid var(--c-border);
  background: var(--c-panel);
  color: var(--c-text);
}

.site-foot__grid {
  display: grid;
  grid-template-columns: 1.35fr 0.8fr 1.2fr 0.7fr;
  gap: 48px;
}

.site-foot__brand .brand {
  margin-bottom: 20px;
}

.site-foot__brand p {
  max-width: 340px;
  font-size: var(--fs-sm);
  color: var(--c-muted);
}

.site-foot h2 {
  font-size: var(--fs-sm);
  margin: 0 0 16px;
  letter-spacing: 0;
}

.site-foot ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.site-foot li a {
  display: inline-block;
  padding-top: 6px;
  padding-bottom: 6px;
  font-size: var(--fs-sm);
  overflow-wrap: anywhere;
}

.site-foot a:hover {
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

.site-foot__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px 32px;
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--c-border);
  color: var(--c-muted);
  font-size: var(--fs-xs);
}

.site-foot__legal {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.site-foot__bottom p {
  margin: 0;
}

@media (max-width: 1320px) {
  :root {
    --canvas-pad: 56px;
    --stage-col: 540px;
    --stage-scale: 0.86;
  }

  .main-nav__link {
    padding-inline: 10px;
  }

  .site-head__inner {
    gap: 20px;
  }
}

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

  .head-tools {
    margin-left: auto;
  }

  .menu-toggle {
    display: inline-flex;
  }

  .brand__tag {
    display: none;
  }
}

@media (min-width: 1201px) {
  .mobile-drawer,
  .nav-veil {
    display: none !important;
  }
}

@media (max-width: 1100px) {
  :root {
    --canvas-pad: 40px;
    --stage-col: 450px;
    --stage-scale: 0.72;
  }

  .site-foot__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  :root {
    --gutter: 24px;
    --fs-h1: 30px;
    --section-gap: 144px;
  }

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

  .section-head {
    margin-bottom: 40px;
  }

  .panel {
    padding: 32px;
  }
}

@media (max-width: 640px) {
  :root {
    --gutter: 20px;
    --fs-h1: clamp(24px, 7vw, 30px);
  }

  .grid-two,
  .site-foot__grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .site-head__inner {
    gap: 10px;
  }

  .brand {
    gap: 8px;
  }

  .brand__name {
    font-size: var(--fs-sm);
  }

  .brand__mark {
    width: 30px;
    height: 30px;
  }

  .lang-switch__text {
    display: none;
  }

  .lang-switch__short {
    display: inline;
  }

  .lang-switch {
    padding-inline: 10px;
  }

  .lang-switch > svg {
    display: none;
  }

  .head-tools {
    gap: 6px;
    margin-left: auto;
  }

  .panel,
  .card {
    padding: 24px;
  }

  .tilt,
  [data-tilt] {
    transform: none !important;
  }

  .section-head {
    text-align: left;
  }

  .site-foot__grid {
    gap: 32px;
  }

  pre {
    padding: 18px;
  }
}

@media (max-width: 360px) {
  :root {
    --gutter: 16px;
  }

  .brand__name {
    font-size: 13px;
  }

  .brand__mark {
    width: 28px;
    height: 28px;
  }
}

@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;
  }

  .btn:hover {
    transform: none;
  }
}