:root {
  color-scheme: light;
  --bg: #E3EEF1;
  --bg-top: #EEF5F7;
  --bg-bottom: #DCE9ED;
  --panel: #F7FBFC;
  --panel2: #D6E5EA;
  --border: #C6D8DE;
  --border-strong: #AFC6CE;
  --accent: #7A3FE8;
  --accent-light: #8D5AF2;
  --accent-dark: #5A26C4;
  --text: #121826;
  --text-soft: #2B3747;
  --ink-2: #2A3445;
  --muted: #526070;
  --success: #12936A;
  --warn: #B9760A;
  --error: #CF3646;
  --ink-deep: #101C26;
  --white: #FFFFFF;
  --ice: #9ED6E3;
  --on-dark-muted: #9DB0BC;
  --trace: #C2D5DC;
  --trace-strong: #A9C2CB;
  --pad-glow: #5FA9BC;
  --trace-dark: rgba(158,214,227,.06);
  --trace-dark-node: rgba(158,214,227,.12);
  --glass: rgba(247,251,252,.72);
  --glass-edge: rgba(255,255,255,.86);
  --glass-groove: rgba(214,229,234,.62);
  --panel-80: rgba(247,251,252,.8);
  --panel-88: rgba(247,251,252,.88);
  --white-90: rgba(255,255,255,.9);
  --white-60: rgba(255,255,255,.6);
  --white-30: rgba(255,255,255,.3);
  --white-24: rgba(255,255,255,.24);
  --white-18: rgba(255,255,255,.18);
  --ink-06: rgba(18,24,38,.06);
  --ink-12: rgba(18,24,38,.12);
  --ink-18: rgba(18,24,38,.18);
  --ink-24: rgba(18,24,38,.24);
  --veil: rgba(16,28,38,.48);
  --border-40: rgba(198,216,222,.4);
  --muted-50: rgba(82,96,112,.5);
  --accent-12: rgba(122,63,232,.12);
  --accent-20: rgba(122,63,232,.2);
  --accent-28: rgba(122,63,232,.28);
  --accent-40: rgba(122,63,232,.4);
  --success-15: rgba(18,147,106,.15);
  --flag-red: #D02B3C;
  --flag-blue: #263A8A;
  --flag-white: #FFFFFF;
  --flag-edge: rgba(18,24,38,.14);
  --clear: transparent;

  --font-display: "Inter","Noto Sans SC","PingFang SC","Hiragino Sans GB","Microsoft YaHei",system-ui,sans-serif;
  --font-body: "Inter","Noto Sans SC","PingFang SC","Hiragino Sans GB","Microsoft YaHei",system-ui,-apple-system,sans-serif;
  --font-mono: "JetBrains Mono",ui-monospace,"SFMono-Regular",Menlo,Consolas,monospace;
  --size-body: 16px;
  --size-small: 13px;
  --size-label: 12px;
  --size-h1: clamp(52px,5.2vw,66px);
  --size-h2: clamp(28px,3.2vw,40px);
  --size-h3: 22px;
  --size-lede: 20px;
  --r-xs: 7px;
  --r-sm: 8px;
  --r-md: 10px;
  --r-lg: 12px;
  --r-pill: 999px;
  --r-round: 50%;
  --gutter: 24px;
  --wrap-width: 1248px;
  --reading-width: 800px;
  --section-space: 80px;
  --header-edge: 112px;
  --anchor-offset: 96px;
  --toc-offset: 16px;
  --toc-clearance: 96px;
  --hi: inset 0 1px 0 var(--white-90);
  --shadow-tint: 0 24px 48px var(--accent-12);
  --shadow-soft: 0 1px 2px var(--ink-06);
  --shadow-nav: 0 6px 20px var(--ink-06);
  --ease: .15s ease;
  --reveal-time: .35s;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: var(--anchor-offset); scroll-behavior: smooth; }
body { font-family: var(--font-body); font-size: var(--size-body); line-height: 1.6; color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
button, summary, select { touch-action: manipulation; }
button:disabled, [aria-disabled="true"] { cursor: not-allowed; opacity: .55; }
img { max-width: 100%; height: auto; display: block; }
svg { flex-shrink: 0; }
ul { list-style: none; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: var(--r-xs); }
h1, h2, h3 { font-family: var(--font-display); font-weight: 900; text-wrap: balance; overflow-wrap: break-word; }
h1 { font-size: var(--size-h1); line-height: 1.1; letter-spacing: -.02em; }
h2 { font-size: var(--size-h2); line-height: 1.2; letter-spacing: -.02em; }
h3 { font-size: var(--size-h3); line-height: 1.35; }
p { overflow-wrap: break-word; }
code { font-family: var(--font-mono); overflow-wrap: anywhere; }
pre { max-width: 100%; overflow-x: auto; padding: 20px; background: var(--panel2); border: 1px solid var(--border); border-radius: var(--r-sm); }
pre code { white-space: pre; overflow-wrap: normal; font-size: var(--size-small); }
.no-break { white-space: nowrap; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.wrap { width: 100%; max-width: var(--wrap-width); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-top: var(--section-space); padding-bottom: var(--section-space); }
.reading-wrap { max-width: var(--reading-width); margin-inline: auto; min-width: 0; }
.grid { display: grid; gap: 24px; }
.grid > *, .stage > *, .footer-grid > *, .feature-board > * { min-width: 0; }
.grid-three { grid-template-columns: repeat(3,minmax(0,1fr)); }
.grid-five { grid-template-columns: repeat(5,minmax(0,1fr)); }
.stack { display: grid; gap: 20px; }
.section-head { margin-bottom: 32px; }
.section-head p { max-width: 720px; color: var(--muted); margin-top: 12px; }
.text-link { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 4px; }
.panel, .card { min-width: 0; background: var(--panel); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--hi),var(--shadow-soft),var(--shadow-tint); padding: 24px; }
.panel-inset { background: var(--panel2); box-shadow: inset 0 1px 2px var(--ink-06); }
.prose { min-width: 0; }
.prose p, .prose ul, .prose ol, .prose pre, .prose blockquote { margin-block: 20px; }
.prose h2 { margin-top: 48px; margin-bottom: 20px; }
.prose h3 { margin-top: 32px; margin-bottom: 16px; }
.prose ul { list-style: disc; padding-left: 24px; }
.prose ol { padding-left: 24px; }
.prose li + li { margin-top: 8px; }
.prose a { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 3px; }
.prose code { font-size: .9em; background: var(--panel2); border-radius: var(--r-xs); padding: 2px 5px; }
.prose pre code { padding: 0; background: none; }
.prose section[id] { padding-top: 16px; }
.reveal { transition: opacity var(--reveal-time) ease,transform var(--reveal-time) ease; }
.reveal.pending { opacity: 0; transform: translateY(16px); }
.reveal.shown { opacity: 1; transform: none; }
#server-status { position: relative; display: block; min-width: 0; max-width: 100%; overflow: hidden; margin-block: 24px; }
#server-status + * { margin-top: 24px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding-inline: 26px; font-size: var(--size-body); font-weight: 650; border: 1px solid var(--clear); border-radius: var(--r-md); transition: transform var(--ease),opacity var(--ease); white-space: nowrap; flex-shrink: 0; }
.btn svg { width: 16px; height: 16px; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary { color: var(--white); background: linear-gradient(180deg,var(--accent-light),var(--accent)); box-shadow: inset 0 1px 0 var(--white-30),0 0 0 1px var(--accent-dark),0 10px 24px var(--accent-28); }
.btn-primary:hover { background: linear-gradient(180deg,var(--accent),var(--accent-dark)); }
.btn-ghost, .btn-secondary { color: var(--text); background: var(--panel); border-color: var(--border); box-shadow: var(--hi),0 2px 6px var(--ink-06); }
.btn-ghost:hover, .btn-secondary:hover { background: var(--bg-top); }
.btn-ink { color: var(--white); background: linear-gradient(180deg,var(--ink-2),var(--text)); box-shadow: inset 0 1px 0 var(--white-18),0 2px 6px var(--ink-12); }
.btn-small { height: 36px; padding-inline: 16px; font-size: 14px; }
.cta-row { position: relative; z-index: 1; display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

.topline { background: var(--text); color: var(--white); font-size: 13.5px; line-height: 1; }
.topline-in { display: flex; align-items: center; justify-content: center; gap: 16px; min-height: 36px; }
.topline-sep { width: 1px; height: 14px; background: var(--white-24); flex-shrink: 0; }
.topline a { font-weight: 600; display: inline-flex; align-items: center; gap: 6px; min-height: 24px; white-space: nowrap; }
.topline a:hover { text-decoration: underline; text-underline-offset: 3px; }
#site-header { position: relative; z-index: 80; }
.nav { display: flex; align-items: center; gap: 18px; height: 52px; margin-top: 12px; padding: 0 8px 0 16px; background: var(--panel-88); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--hi),var(--shadow-nav); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.brand { display: inline-flex; align-items: center; gap: 10px; flex: none; min-height: 32px; }
.brand img { display: block; width: 28px; height: 28px; }
.brand-word { font-family: var(--font-display); font-size: 17px; font-weight: 800; letter-spacing: -.02em; color: var(--text); white-space: nowrap; }
.nav-divider { width: 1px; height: 22px; background: var(--border); flex: none; }
.dotnav { flex: 1; min-width: 0; }
.dotnav ul { display: flex; align-items: center; list-style: none; margin: 0; padding: 0; white-space: nowrap; }
.dotnav li { display: flex; align-items: center; font-size: 14px; color: var(--text-soft); }
.dotnav li + li::before { content: "·"; margin-inline: 6px; color: var(--muted-50); font-weight: 700; }
.dotnav a { display: inline-flex; align-items: center; min-height: 32px; padding: 6px 1px; border-radius: var(--r-xs); }
.dotnav a:hover { color: var(--text); }
.dotnav a[aria-current="page"] { color: var(--text); font-weight: 650; box-shadow: inset 0 -2px 0 var(--text); }
.nav-more { position: relative; }
.nav-more summary { display: flex; align-items: center; gap: 6px; min-height: 32px; padding: 6px 1px; cursor: pointer; list-style: none; }
.nav-more summary::-webkit-details-marker { display: none; }
.nav-more summary::after { content: "▾"; }
.dotnav .nav-more-panel { position: absolute; z-index: 110; top: calc(100% + 10px); left: 0; display: flex; flex-direction: column; align-items: stretch; min-width: 200px; padding: 6px; background: var(--panel); border: 1px solid var(--border); border-radius: var(--r-md); box-shadow: var(--hi),var(--shadow-tint); }
.nav-more:not([open]) > .nav-more-panel { display: none; }
.dotnav .nav-more-panel li::before { content: none; }
.dotnav .nav-more-panel a { width: 100%; min-height: 44px; padding: 8px 12px; }
.dotnav .nav-more-panel a:hover { background: var(--panel2); }
.nav-end { display: flex; align-items: center; gap: 6px; margin-left: auto; flex-shrink: 0; }
.lang-switch { position: relative; }
.lang { display: inline-flex; align-items: center; justify-content: center; gap: 4px; min-height: 34px; min-width: 44px; width: auto; padding-inline: 10px; font-size: 13.5px; color: var(--muted); border-radius: var(--r-sm); white-space: nowrap; }
.lang svg { width: 16px; height: 16px; }
.lang-name { white-space: nowrap; }
.lang:hover { background: var(--panel2); color: var(--text); }
.lang-panel { position: absolute; z-index: 110; right: 0; top: calc(100% + 10px); width: 184px; padding: 6px; background: var(--panel); border: 1px solid var(--border); border-radius: var(--r-md); box-shadow: var(--hi),var(--shadow-tint); }
.lang-panel a { display: flex; align-items: center; min-height: 44px; padding: 8px 12px; border-radius: var(--r-xs); font-size: 14px; }
.lang-panel a:hover, .lang-panel a[aria-current] { background: var(--panel2); color: var(--text); }
.btn-login { display: inline-flex; align-items: center; justify-content: center; height: 34px; padding-inline: 16px; font-size: 14px; font-weight: 650; color: var(--white); background: linear-gradient(180deg,var(--ink-2),var(--text)); border-radius: var(--r-sm); box-shadow: inset 0 1px 0 var(--white-18),0 2px 6px var(--ink-12); white-space: nowrap; }
.btn-login:hover { background: var(--text); }
.menu-toggle { display: none; align-items: center; justify-content: center; flex-direction: column; gap: 4px; min-width: 44px; min-height: 44px; color: var(--text); border-radius: var(--r-sm); }
.menu-line { display: block; width: 20px; height: 2px; background: currentColor; border-radius: var(--r-xs); }
.header-veil { position: fixed; z-index: 70; inset: var(--header-edge) 0 0; background: var(--veil); }
.mobile-drawer { position: fixed; z-index: 75; top: var(--header-edge); left: 0; right: 0; height: calc(100dvh - var(--header-edge)); max-height: calc(100dvh - var(--header-edge)); background: var(--panel); overflow-y: auto; overscroll-behavior: contain; padding: 16px var(--gutter) 40px; border-top: 1px solid var(--border); }
.mobile-drawer a { display: flex; align-items: center; width: 100%; min-height: 44px; padding: 12px; border-bottom: 1px solid var(--border); }
.mobile-drawer a[aria-current] { color: var(--accent-dark); font-weight: 700; background: var(--bg-top); }
.drawer-languages { margin-top: 20px; }
html.nav-open { overflow: hidden; }

.site-footer { padding-top: 64px; padding-bottom: 32px; background: var(--panel2); border-top: 1px solid var(--border); }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 48px; }
.footer-brand p { color: var(--muted); max-width: 360px; margin-top: 16px; }
.footer-title { font-size: 14px; font-weight: 750; margin-bottom: 12px; }
.footer-links { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 4px 16px; }
.footer-links a, .footer-languages a, .footer-legal a { display: inline-flex; align-items: center; min-height: 32px; font-size: 14px; }
.footer-links a:hover, .footer-languages a:hover, .footer-legal a:hover { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 4px; }
.footer-languages { display: flex; flex-wrap: wrap; gap: 8px 20px; padding-block: 24px; margin-top: 32px; border-block: 1px solid var(--border); }
.footer-languages a[aria-current] { font-weight: 750; }
.footer-bottom { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px 24px; padding-top: 20px; font-size: var(--size-small); color: var(--muted); }
.footer-legal { display: flex; flex-wrap: wrap; gap: 20px; }

@media (max-width: 1230px) {
  .nav { gap: 12px; }
  .dotnav li { font-size: 13px; }
  .dotnav li + li::before { margin-inline: 6px; }
}
@media (max-width: 1100px) {
  .nav { height: 64px; flex-wrap: nowrap; padding-inline: 12px 6px; }
  .dotnav, .nav-divider { display: none; }
  .nav-end { margin-left: auto; }
  .menu-toggle { display: flex; }
  .grid-five { grid-template-columns: repeat(3,minmax(0,1fr)); }
}
@media (min-width: 1101px) {
  .mobile-drawer, .header-veil { display: none; }
}
@media (max-width: 768px) {
  :root { --size-h1: 38px; --section-space: 56px; --size-h2: 30px; }
  .grid-three, .footer-grid { grid-template-columns: minmax(0,1fr); }
  .footer-grid { gap: 32px; }
}
@media (max-width: 640px) {
  :root { --gutter: 16px; --size-h1: 34px; }
  .no-break { white-space: normal; }
  .tilt, [data-tilt] { transform: none; }
  .topline-in { font-size: 12px; gap: 8px; }
  .topline-in > span:first-child { line-height: 1.35; }
  .brand { gap: 6px; }
  .brand-word { font-size: 15px; }
  .brand img { width: 25px; height: 25px; }
  .nav { gap: 6px; }
  .nav-end { gap: 2px; margin-left: auto; }
  .lang { padding-inline: 6px; min-height: 44px; }
  .lang-name { display: none; }
  .btn-login { padding-inline: 12px; min-height: 36px; }
  .btn { height: 46px; padding-inline: 22px; }
  .grid-five { grid-template-columns: minmax(0,1fr); }
  .panel, .card { padding: 20px; }
  .section { max-width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal, .reveal.pending, .reveal.shown { opacity: 1; transform: none; transition: none; }
  .btn { transition: none; }
  .btn:hover { transform: none; }
}