:root {
  --c-bg: #ffffff;
  --c-panel: #f7f7f9;
  --c-panel-2: #eef0fb;
  --c-border: #e6e7ec;
  --c-accent: #6872e0;
  --c-accent-dark: #3e46ad;
  --c-text: #17181c;
  --c-muted: #6b6f7b;
  --c-success: #1f9d6b;
  --c-warn: #c98a12;
  --c-error: #d6453d;
  --c-faint: #a4a7b2;
  --c-ink-hover: #2b2d34;
  --c-on-ink: #ffffff;
  --c-accent-soft: rgb(104 114 224 / 0.12);
  --c-accent-ring: rgb(104 114 224 / 0.22);
  --c-error-soft: rgb(214 69 61 / 0.08);
  --c-glow-core: rgb(104 114 224 / 0.34);
  --c-glow-mid: rgb(104 114 224 / 0.13);
  --c-glow-off: rgb(104 114 224 / 0);
  --c-veil: rgb(23 24 28 / 0.18);
  --c-transparent: transparent;
  --mask-on: rgb(0 0 0 / 1);
  --mask-off: rgb(0 0 0 / 0);

  --sh-hairline: 0 1px 2px rgb(23 24 28 / 0.05);
  --sh-float: 0 32px 80px rgb(62 70 173 / 0.12);
  --sh-lift: 0 10px 28px rgb(62 70 173 / 0.10);
  --sh-ink: 0 1px 2px rgb(23 24 28 / 0.18), inset 0 1px 0 rgb(255 255 255 / 0.10);

  --r-panel: 22px;
  --r-sheet: 14px;
  --r-btn: 11px;
  --r-tab: 8px;
  --r-logo: 8px;
  --r-focus: 6px;
  --r-shot: 10px;
  --r-mobile-panel: 18px;
  --r-pill: 999px;
  --r-circle: 50%;

  --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-body: 15px;
  --fs-small: 13px;
  --fs-label: 12px;
  --fs-nav: 14.5px;
  --fs-h1: clamp(34px, 2.4vw + 14px, 48px);
  --fs-h1-mobile: clamp(24px, 6.4vw, 30px);
  --fs-h2: 32px;
  --fs-h3: 22px;
  --fw-normal: 400;
  --fw-title: 500;
  --lh-body: 1.6;
  --lh-copy: 1.8;
  --lh-title: 1.14;
  --tracking-display: -0.035em;
  --tracking-cjk: -0.02em;
  --tracking-small: -0.01em;

  --gutter: 40px;
  --width-content: 1200px;
  --width-reading: 780px;
  --width-header: 1280px;
  --header-height: 64px;
  --section-space: 96px;
  --card-space: 28px;
  --gap-grid: 24px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --duration: .2s;
}

*, *::before, *::after { box-sizing: border-box; }
html {
  background: var(--c-bg);
  color: var(--c-text);
  scroll-behavior: smooth;
  scroll-padding-top: 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: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
[hidden] { display: none !important; }
img, svg { max-width: 100%; vertical-align: middle; }
img { height: auto; }
svg { flex-shrink: 0; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
button, a { -webkit-tap-highlight-color: var(--c-transparent); }
button:disabled { cursor: not-allowed; }
a { color: inherit; text-underline-offset: .2em; }
button, summary, a { touch-action: manipulation; }
:focus-visible {
  outline: 2px solid var(--c-accent);
  outline-offset: 3px;
  border-radius: var(--r-focus);
}
::selection { background: var(--c-accent-ring); color: var(--c-text); }

h1, h2, h3, h4 {
  font-family: var(--f-display);
  font-weight: var(--fw-title);
  color: var(--c-text);
  text-wrap: balance;
  overflow-wrap: break-word;
}
h1 {
  font-size: var(--fs-h1);
  line-height: var(--lh-title);
  letter-spacing: var(--tracking-cjk);
}
h2 { font-size: var(--fs-h2); line-height: 1.25; letter-spacing: var(--tracking-cjk); }
h3 { font-size: var(--fs-h3); line-height: 1.35; letter-spacing: var(--tracking-cjk); }
p { margin-block: 0 1em; }
strong { font-weight: var(--fw-title); }
code, pre, kbd, samp { font-family: var(--f-mono); }
code { overflow-wrap: anywhere; }
pre {
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  padding: 20px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-sheet);
  background: var(--c-panel);
  color: var(--c-text);
  font-size: var(--fs-small);
  line-height: 1.8;
  tab-size: 2;
  -webkit-overflow-scrolling: touch;
}
pre code { white-space: pre; overflow-wrap: normal; word-break: normal; }
hr { border: 0; border-top: 1px solid var(--c-border); margin-block: 32px; }
:where(section, article, aside, main, div, li) { min-width: 0; }
.nowrap { white-space: nowrap; }
.muted { color: var(--c-muted); }
.mono { font-family: var(--f-mono); }
.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 {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 100;
  padding: 8px 14px;
  border-radius: var(--r-btn);
  background: var(--c-text);
  color: var(--c-on-ink);
  font-size: var(--fs-small);
  text-decoration: none;
}
.skip:focus { top: 12px; }
.shell, .wrap {
  width: 100%;
  max-width: calc(var(--width-content) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.reading {
  width: 100%;
  max-width: calc(var(--width-reading) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.section { padding-top: var(--section-space); padding-bottom: var(--section-space); }
.section__head { max-width: 680px; margin-bottom: 36px; }
.section__head h2 { margin-block: 12px 16px; }
.eyebrow {
  margin: 0;
  color: var(--c-muted);
  font-family: var(--f-mono);
  font-size: var(--fs-label);
  letter-spacing: .02em;
}
.grid-two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gap-grid);
}
.grid-two > *, .grid-three > * { min-width: 0; }
.grid-three {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--gap-grid);
}
.actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 26px;
}
.actions--start { justify-content: flex-start; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 46px;
  max-width: 100%;
  padding: 10px 22px;
  border: 1px solid var(--c-transparent);
  border-radius: var(--r-btn);
  font-family: var(--f-body);
  font-size: var(--fs-body);
  font-weight: var(--fw-title);
  line-height: 1.4;
  letter-spacing: -.005em;
  text-align: center;
  text-decoration: none;
  transition: background-color var(--duration) var(--ease), border-color var(--duration) var(--ease), transform var(--duration) var(--ease);
}
.btn svg { width: 16px; height: 16px; }
.btn:active, .btn.is-active { transform: translateY(1px); }
.btn--ink {
  background: var(--c-text);
  color: var(--c-on-ink);
  border-color: var(--c-text);
  box-shadow: var(--sh-ink);
}
.btn--ink:hover, .btn--ink.is-hover {
  background: var(--c-ink-hover);
  color: var(--c-on-ink);
  border-color: var(--c-ink-hover);
}
.btn--line {
  background: var(--c-bg);
  color: var(--c-text);
  border-color: var(--c-border);
  box-shadow: var(--sh-hairline);
}
.btn--line:hover, .btn--line.is-hover { border-color: var(--c-faint); }
.btn--line svg { width: 14px; height: 14px; color: var(--c-muted); }
.btn.is-focus { outline: 2px solid var(--c-accent); outline-offset: 3px; }
.btn:disabled, .btn[aria-disabled="true"] {
  background: var(--c-panel);
  color: var(--c-muted);
  border-color: var(--c-border);
  box-shadow: none;
  transform: none;
}
.card, .panel {
  padding: var(--card-space);
  border: 1px solid var(--c-border);
  border-radius: var(--r-panel);
  background: var(--c-bg);
  color: var(--c-text);
  box-shadow: var(--sh-hairline);
}
.panel--float { box-shadow: var(--sh-hairline), var(--sh-float); }
.card h3, .panel h3 { margin-top: 0; }
.card > :last-child, .panel > :last-child { margin-bottom: 0; }
.prose { line-height: var(--lh-copy); overflow-wrap: break-word; }
.prose h2 { margin-block: 2.5em .8em; }
.prose h3 { margin-block: 1.8em .7em; }
.prose :where(ul, ol) { padding-left: 1.5em; }
.prose li + li { margin-top: .5em; }
.prose :where(p, li) > code {
  padding: .1em .3em;
  border-radius: var(--r-focus);
  background: var(--c-panel);
  color: var(--c-text);
}
.prose a { text-decoration-thickness: 1px; }
.prose > :first-child { margin-top: 0; }

.masthead, #site-header {
  position: relative;
  z-index: 40;
  background: var(--c-bg);
  color: var(--c-text);
  border-bottom: 1px solid var(--c-border);
}
.header-shell {
  width: 100%;
  max-width: min(100%, calc(var(--width-header) + var(--gutter) * 2));
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.masthead__bar {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 28px;
  min-height: var(--header-height);
}
.brand {
  display: inline-flex;
  flex-shrink: 0;
  align-items: center;
  gap: 11px;
  color: var(--c-text);
  font-size: var(--fs-body);
  font-weight: var(--fw-title);
  letter-spacing: var(--tracking-small);
  text-decoration: none;
}
.brand__mark {
  flex-shrink: 0;
  display: block;
  width: 30px;
  height: 30px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-logo);
  background: var(--c-bg);
  color: var(--c-text);
  box-shadow: var(--sh-hairline);
}
.brand__mark--placeholder {
  box-shadow: var(--sh-hairline), inset 0 0 0 5px var(--c-bg), inset 0 0 0 6px var(--c-accent-ring);
}
.topnav { min-width: 0; margin-left: auto; }
.topnav__list {
  display: flex;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 30px;
}
.topnav__link {
  display: inline-block;
  padding-block: 6px;
  color: var(--c-muted);
  font-size: var(--fs-nav);
  text-decoration: none;
  white-space: nowrap;
  transition: color var(--duration) var(--ease);
}
.topnav__link:hover { color: var(--c-text); }
.topnav__link[aria-current="page"] { color: var(--c-text); font-weight: var(--fw-title); }
.header-tools { display: flex; flex-shrink: 0; align-items: center; gap: 12px; }
.language { position: relative; }
.langswitch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 44px;
  padding: 0 0 0 26px;
  border: 0;
  background: var(--c-bg);
  color: var(--c-text);
  font-size: 14px;
  white-space: nowrap;
}
.langswitch::before {
  content: "";
  position: absolute;
  left: 0;
  width: 1px;
  height: 20px;
  background: var(--c-border);
}
.langswitch__caret { font-size: 10px; color: var(--c-muted); }
.langswitch__short { display: none; }
.language__list {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 5;
  width: 180px;
  margin: 0;
  padding: 6px;
  list-style: none;
  border: 1px solid var(--c-border);
  border-radius: var(--r-sheet);
  background: var(--c-bg);
  color: var(--c-text);
  box-shadow: var(--sh-lift);
}
.language__list a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 12px;
  border-radius: var(--r-tab);
  text-decoration: none;
}
.language__list a:hover, .language__list a[aria-current="true"] {
  background: var(--c-panel);
  color: var(--c-text);
}
.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 10px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-btn);
  background: var(--c-bg);
  color: var(--c-text);
}
.menu-toggle svg { width: 20px; height: 20px; }
.menu-veil {
  position: fixed;
  inset: var(--header-height) 0 0;
  z-index: 0;
  border: 0;
  background: var(--c-veil);
  color: var(--c-text);
}
.mobile-drawer {
  position: absolute;
  z-index: 3;
  top: 100%;
  left: 0;
  right: 0;
  max-height: calc(100dvh - var(--header-height));
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 16px var(--gutter) 24px;
  border-bottom: 1px solid var(--c-border);
  background: var(--c-bg);
  color: var(--c-text);
  box-shadow: var(--sh-lift);
}
.mobile-drawer ul { list-style: none; margin: 0; padding: 0; }
.mobile-drawer a {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 48px;
  padding: 12px;
  border-radius: var(--r-tab);
  color: var(--c-text);
  text-decoration: none;
}
.mobile-drawer a:hover, .mobile-drawer a[aria-current] {
  background: var(--c-panel);
  color: var(--c-text);
}
.mobile-drawer__label {
  margin: 16px 12px 4px;
  padding-top: 16px;
  border-top: 1px solid var(--c-border);
  color: var(--c-muted);
  font-size: var(--fs-small);
}
.static-language summary { list-style: none; cursor: pointer; }
.static-language summary::-webkit-details-marker { display: none; }
.static-mobile-menu { display: none; }

.site-footer {
  padding-top: 64px;
  padding-bottom: 100px;
  border-top: 1px solid var(--c-border);
  background: var(--c-bg);
  color: var(--c-text);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr .7fr 1.2fr .65fr;
  gap: 40px;
}
.footer-grid > * { min-width: 0; }
.footer-intro { max-width: 320px; margin-top: 18px; color: var(--c-muted); font-size: var(--fs-small); }
.footer-title { margin-block: 0 16px; font-size: var(--fs-small); font-weight: var(--fw-title); }
.footer-links { list-style: none; margin: 0; padding: 0; }
.footer-links a {
  display: inline-block;
  padding-block: 5px;
  color: var(--c-muted);
  font-size: var(--fs-small);
  text-decoration: none;
  overflow-wrap: anywhere;
}
.footer-links a:hover { color: var(--c-text); }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  margin-top: 40px;
  padding-top: 22px;
  border-top: 1px solid var(--c-border);
  color: var(--c-muted);
  font-size: var(--fs-label);
}
.footer-bottom p { margin: 0; }

.reveal { opacity: 1; transform: none; }
.reveal-enabled .reveal:not(.shown) { opacity: 0; transform: translateY(16px); }
.reveal-enabled .reveal {
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
.reveal-enabled .reveal.shown { opacity: 1; transform: none; }
.hero, .decorated-section, [data-hero-visual] { overflow-x: clip; }

@media (max-width: 1100px) {
  .topnav { display: none; }
  .header-tools { margin-left: auto; }
  .menu-toggle { display: inline-flex; }
  .masthead__bar { gap: 16px; }
  .static-mobile-menu { display: block; }
  .static-mobile-menu > summary { display: flex; list-style: none; }
  .static-mobile-menu > summary::-webkit-details-marker { display: none; }
  .static-mobile-menu .mobile-drawer { top: var(--header-height); }
}
@media (max-width: 900px) {
  :root { --gutter: 20px; --section-space: 72px; }
  .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) {
  h1 { font-size: var(--fs-h1-mobile); }
  h2 { font-size: 26px; }
  .grid-two, .grid-three { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  :root { --gutter: 16px; --section-space: 56px; --card-space: 22px; }
  .tilt, [data-tilt] { transform: none !important; }
  .header-tools { margin-left: auto; gap: 6px; }
  .masthead__bar { gap: 8px; }
  .brand { gap: 8px; font-size: var(--fs-small); }
  .brand__mark { width: 28px; height: 28px; }
  .langswitch { padding-left: 10px; }
  .langswitch::before { display: none; }
  .langswitch__full { display: none; }
  .langswitch__short { display: inline; }
  .footer-grid { gap: 28px 18px; }
  .footer-grid__brand { grid-column: 1 / -1; }
  .footer-bottom { display: block; }
  .footer-bottom p + p { margin-top: 10px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal-enabled .reveal:not(.shown) { opacity: 1; transform: none; }
}