:root {
  color-scheme: light;
  --bg: #FCFCFA;
  --panel: #FFFFFF;
  --panel-2: #F4F4F1;
  --panel-3: #F9F9F7;
  --border: #E6E5E1;
  --border-strong: #D6D5D0;
  --accent: #3F6E8C;
  --accent-dark: #2B4E66;
  --accent-soft: #EAF0F4;
  --text: #23252A;
  --text-muted: #6B6E74;
  --text-faint: #9B9DA2;
  --success: #3E8A62;
  --warn: #C98A2E;
  --error: #C4553F;
  --badge: #D46A52;
  --badge-text: #A44835;
  --ink: var(--text);
  --ink-hover: #3A3D44;
  --on-ink: var(--panel);
  --veil: rgba(35,37,42,.24);
  --clear: transparent;

  --scene-sky: #F3CDB2;
  --scene-sky-mid: #EFD3BF;
  --scene-haze: #EAD9C9;
  --scene-sun: #F9E4D1;
  --scene-cloud: #FBF2EA;
  --scene-hill-far: #CDD0C4;
  --scene-hill-near: #B5BEB1;
  --scene-bank: #C0C2AD;
  --scene-bank-deep: #A7AE99;
  --scene-water: #9DBBBE;
  --scene-water-deep: #8DAFB3;
  --scene-water-lit: #CADBD9;
  --scene-label: var(--panel);
  --scene-line: rgba(255,255,255,.72);
  --scene-edge: rgba(35,37,42,.05);

  --font-display: 'Inter','Noto Sans SC','PingFang SC','Microsoft YaHei',system-ui,sans-serif;
  --font-body: 'Inter','Noto Sans SC','PingFang SC','Hiragino Sans GB','Microsoft YaHei',system-ui,sans-serif;
  --font-mono: 'JetBrains Mono',ui-monospace,'SFMono-Regular',Menlo,Consolas,monospace;
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-label: 600;
  --size-body: 15px;
  --size-small: 13px;
  --size-h1: clamp(34px,4vw,48px);
  --size-h2: clamp(24px,3vw,36px);
  --size-h3: clamp(18px,2vw,22px);
  --size-hero: clamp(34px,3.1vw,44px);
  --size-feature: clamp(28px,4vw,48px);

  --r-xs: 4px;
  --r-sm: 6px;
  --r-md: 8px;
  --r-lg: 10px;
  --r-pill: 999px;
  --r-round: 50%;
  --shadow-xs: 0 1px 2px rgba(35,37,42,.06);
  --shadow-card: 0 1px 2px rgba(35,37,42,.05),0 8px 20px rgba(35,37,42,.06);
  --shadow-window: 0 7px 0 -3px var(--panel-3),0 7px 0 -2px var(--border),0 2px 5px rgba(35,37,42,.06),0 34px 70px -22px rgba(52,58,66,.34);
  --shadow-drawer: 0 2px 5px rgba(35,37,42,.07),0 22px 46px -14px rgba(52,58,66,.34);

  --gutter: 40px;
  --content-width: 1120px;
  --reading-width: 76ch;
  --nav-h: 72px;
  --button-h: 46px;
  --tap: 44px;
  --section-space: clamp(60px,8vw,120px);
  --ease-ui: .15s ease;
  --z-toc: 5;
  --z-fab: 10;
  --z-veil: 29;
  --z-header: 30;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 16px;
}
html.nav-open { overflow: hidden; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: var(--size-body)/1.6 var(--font-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-wrap: break-word;
}
:where(main, section, article, aside, nav, div, li, figure, p) { min-width: 0; }
:where(img, svg, video) { max-width: 100%; vertical-align: middle; }
:where(button, input, select, textarea) { font: inherit; color: inherit; }
button {
  background: var(--clear);
  color: inherit;
  border: 0;
  padding: 0;
  cursor: pointer;
}
button:disabled { cursor: not-allowed; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { color: var(--accent-dark); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
h1, h2, h3 {
  margin: 0 0 .55em;
  font-family: var(--font-display);
  font-weight: var(--weight-regular);
  line-height: 1.2;
  letter-spacing: -.015em;
  text-wrap: balance;
}
h1 { font-size: var(--size-h1); }
h2 { font-size: var(--size-h2); }
h3 { font-size: var(--size-h3); }
p { margin: 0 0 1em; }
small { font-size: var(--size-small); }
code, pre, kbd { font-family: var(--font-mono); }
code { overflow-wrap: anywhere; }
pre {
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--panel-3);
  color: var(--text);
  white-space: pre;
  font-size: var(--size-small);
}
pre code { overflow-wrap: normal; word-break: normal; }

.wrap, .hero-wrap, .bar-shell {
  margin-inline: auto;
  padding-inline: var(--gutter);
  width: 100%;
}
.wrap { max-width: calc(var(--content-width) + var(--gutter) * 2); }
.hero-wrap { max-width: 1400px; }
.bar-shell { max-width: min(100%, calc(1280px + var(--gutter) * 2)); }
.reading { max-width: var(--reading-width); min-width: 0; }
.sec { padding-block: var(--section-space); }
.nowrap { white-space: nowrap; }
.muted { color: var(--text-muted); }
.decor-clip { overflow-x: clip; }
.icon, .pill-dot, .brand-mark, .status-dot { flex-shrink: 0; }
.cluster { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 16px; }
.card-grid > *, .footer-grid > *, .hero-grid > *, .win-body > * { min-width: 0; }
.card, .panel {
  padding: clamp(16px,2.3vw,28px);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--panel);
  color: var(--text);
  box-shadow: var(--shadow-card);
}
.panel { background: var(--panel-3); color: var(--text); }
:is(.card, .panel) > :last-child { margin-block-end: 0; }

.btn, .btn-bar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  max-width: 100%;
  min-height: var(--button-h);
  padding: 8px 20px;
  border-radius: var(--r-lg);
  font-weight: var(--weight-medium);
  line-height: 1.3;
  text-align: center;
  text-decoration: none;
  transition: background var(--ease-ui), border-color var(--ease-ui);
}
.btn svg { width: 16px; height: 16px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.btn-main, .btn-bar { background: var(--ink); color: var(--on-ink); }
.btn-main { box-shadow: var(--shadow-card); }
.btn-main:hover, .btn-main:active, .btn-bar:hover, .btn-bar:active {
  background: var(--ink-hover);
  color: var(--on-ink);
}
.btn-ghost { background: var(--panel); color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover, .btn-ghost:active { background: var(--panel); color: var(--text); border-color: var(--border-strong); }
.btn:disabled, .btn[aria-disabled="true"] { background: var(--panel-2); color: var(--text); border: 1px solid var(--border); box-shadow: none; }
.btn-bar { min-height: 38px; padding-inline: 18px; border-radius: var(--r-pill); font-size: 14px; white-space: nowrap; }

.topbar { position: relative; z-index: var(--z-header); height: var(--nav-h); }
.topbar .bar-shell {
  height: 100%;
  display: grid;
  grid-template-columns: minmax(0,1fr) auto minmax(0,1fr);
  align-items: center;
}
.brand { display: inline-flex; align-items: center; gap: 10px; justify-self: start; color: var(--text); text-decoration: none; flex-shrink: 0; }
.brand:hover { color: var(--text); }
.brand-mark { width: 30px; height: 30px; display: block; }
.brand-name { font-size: 15.5px; font-weight: var(--weight-medium); letter-spacing: -.005em; }
.primary-nav { min-width: 0; }
.primary-nav > ul { display: flex; align-items: center; list-style: none; gap: 6px; margin: 0; padding: 0; }
.primary-nav > ul > li > a, .more-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 8px 14px;
  font-size: 14.5px;
  color: var(--text);
  border-radius: var(--r-sm);
  text-decoration: none;
  white-space: nowrap;
  transition: color var(--ease-ui);
}
.primary-nav > ul > li > a:hover, .more-btn:hover, .more-btn[aria-expanded="true"],
.primary-nav a[aria-current="page"], .more-btn.has-current { color: var(--accent); }
.chev { width: 10px; height: 10px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.more, .lang-picker { position: relative; }
.dropdown {
  position: absolute;
  z-index: 1;
  inset-block-start: calc(100% + 8px);
  min-width: 232px;
  max-width: min(280px, calc(100vw - var(--gutter) * 2));
  padding: 6px;
  background: var(--panel);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-card);
}
.dropdown a {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: var(--tap);
  padding: 9px 12px;
  color: var(--text);
  border-radius: var(--r-sm);
  text-decoration: none;
}
.dropdown a:hover { background: var(--panel-2); color: var(--text); }
.dropdown strong { font-size: 14px; font-weight: var(--weight-medium); }
.dropdown a span { font-size: 12.5px; color: var(--text-muted); line-height: 1.5; }
.bar-end { justify-self: end; display: flex; align-items: center; gap: 14px; flex-shrink: 0; }
.lang {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 10px;
  font-size: 14px;
  color: var(--text-muted);
  border-radius: var(--r-sm);
  white-space: nowrap;
}
.lang:hover { color: var(--text); }
.lang svg { width: 15px; height: 15px; flex-shrink: 0; fill: none; stroke: currentColor; stroke-width: 1.4; }
.lang-menu { inset-inline-end: 0; min-width: 152px; }
.lang-short, .hamburger, .mobile-nav, .nav-veil { display: none; }
.hamburger {
  min-width: var(--tap);
  min-height: var(--tap);
  place-items: center;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--panel);
  color: var(--text);
}
.hamburger svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; }
.topbar details > summary { cursor: pointer; list-style: none; }
.topbar details > summary::-webkit-details-marker { display: none; }

.site-footer { border-top: 1px solid var(--border); padding-block: 56px 22px; }
.footer-grid { display: grid; grid-template-columns: 1.45fr .8fr 1.3fr .75fr; gap: 28px; }
.footer-grid p { margin-top: 12px; color: var(--text-muted); }
.footer-grid h2 { margin-bottom: 12px; font-size: 15px; font-weight: var(--weight-medium); }
.footer-grid ul, .footer-legal { margin: 0; padding: 0; list-style: none; }
.footer-grid li + li { margin-top: 6px; }
.footer-grid nav a, .footer-legal a { text-decoration: none; }
.footer-grid nav a:hover, .footer-legal a:hover { text-decoration: underline; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; border-top: 1px solid var(--border); padding-top: 18px; margin-top: 36px; color: var(--text-muted); }
.footer-legal { display: flex; flex-wrap: wrap; gap: 8px 18px; }

.reveal-ready .reveal:not(.shown):not(:focus-within):not(:target) { opacity: 0; }
.reveal-ready .reveal { transition: opacity .45s ease; }

@media (max-width: 1280px) {
  :is(html[lang="en"], html[lang="ja"], html[lang="ko"]) .topbar:not(.preview-bar) .primary-nav { display: none; }
  :is(html[lang="en"], html[lang="ja"], html[lang="ko"]) .topbar:not(.preview-bar) .bar-shell { grid-template-columns: auto minmax(0,1fr); }
  :is(html[lang="en"], html[lang="ja"], html[lang="ko"]) .hamburger { display: grid; }
}
@media (max-width: 860px) {
  .primary-nav { display: none; }
  .topbar .bar-shell { grid-template-columns: auto minmax(0,1fr); }
  .hamburger { display: grid; }
}
html.nav-open .topbar { position: sticky; top: 0; background: var(--bg); color: var(--text); }
html.nav-open .nav-veil { display: block; position: fixed; inset: var(--nav-h) 0 0; z-index: var(--z-veil); background: var(--veil); color: var(--text); }
html.nav-open .mobile-nav, .preview-mobile[open] .mobile-nav {
  display: block;
  position: absolute;
  inset: 100% 0 auto;
  max-height: calc(100dvh - var(--nav-h));
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 12px var(--gutter) 22px;
  background: var(--panel);
  color: var(--text);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow-card);
}
.mobile-nav a {
  display: flex;
  align-items: center;
  min-height: var(--tap);
  width: 100%;
  padding: 9px 10px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  text-decoration: none;
}
.mobile-nav a:hover, .mobile-nav a[aria-current] { color: var(--accent); }
.mobile-nav p { margin: 16px 10px 4px; color: var(--text-muted); }
.bar-end { margin-inline-start: auto; }
.preview-mobile { display: none; }

@media (max-width: 768px) {
  :root { --gutter: 20px; --size-h1: clamp(24px,5vw,30px); --size-hero: var(--size-h1); }
  .footer-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 860px) {
  .preview-mobile { display: block; }
}
@media (max-width: 640px) {
  .tilt, [data-tilt] { transform: none !important; }
  .bar-end { gap: 6px; }
  .lang { min-height: var(--tap); padding-inline: 7px; }
  .lang-full { display: none; }
  .lang-short { display: inline; }
  .brand { gap: 7px; }
  .brand-name { font-size: 14px; }
}
@media (max-width: 520px) {
  .topbar .btn-bar { display: none; }
  .footer-grid { gap: 24px 16px; }
  .footer-intro { grid-column: 1 / -1; }
}
@media (max-width: 360px) {
  .bar-end .lang svg { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal-ready .reveal:not(.shown):not(:focus-within):not(:target) { opacity: 1; }
}