
:root {
  --primary-50: #EDF5F8;
  --primary-100: #DAEAF1;
  --primary-200: #B5D6E3;
  --primary-300: #87BED4;
  --primary-400: #53A5C6;
  --primary-500: #2D86A9;
  --primary-600: #206B88;
  --primary-700: #1B5B74;
  --primary-800: #134458;
  --primary-900: #0C2E3B;
  --neutral-0: #FFFFFF;
  --neutral-50: #F7F8F8;
  --neutral-100: #ECEEEE;
  --neutral-200: #DADCDD;
  --neutral-300: #BDC0C2;
  --neutral-400: #959B9D;
  --neutral-500: #71777A;
  --neutral-600: #575E60;
  --neutral-700: #414749;
  --neutral-800: #2B2F31;
  --neutral-900: #1A1D1E;
  --neutral-950: #121415;
  --bg: #F6F5F1;
  --surface-1: #FBFAF7;
  --surface-2: #FFFFFF;
  --surface-3: #EFEDE7;
  --text: #1A1D1E;
  --text-muted: #575E60;
  --border-subtle: #E3E0D8;
  --border-strong: #71777A;
  --accent: #1B5B74;
  --accent-hover: #134458;
  --on-accent: #FFFFFF;
  --link: #1B5B74;
  --focus-ring: #2D86A9;
  --up: #2F6B4F;
  --down: #A3443A;
  --success-fg: #2F6B4F;
  --success-bg: #E8F1EC;
  --success-border: #9DC4AE;
  --warning-fg: #7A5300;
  --warning-bg: #FBF1DA;
  --warning-border: #E2C27A;
  --danger-fg: #A3443A;
  --danger-bg: #F8E8E5;
  --danger-border: #E0A59D;
  --info-fg: #1B5B74;
  --info-bg: #EDF5F8;
  --info-border: #B5D6E3;
  --accent-subtle: var(--primary-50);
  --accent-muted: var(--primary-200);
  --scrim: rgba(10, 12, 13, 0.45);
  --font-sans: 'Geist', 'Geist Fallback', ui-sans-serif, system-ui, sans-serif;
  --font-mono: 'Geist Mono', 'Geist Mono Fallback', ui-monospace, 'SFMono-Regular', Menlo, monospace;
  --fs-body: 1.0625rem; --fs-sm: 0.9375rem; --fs-xs: 0.8125rem; --fs-lg: 1.1875rem;
  --fs-h3: clamp(1.25rem, 1.1rem + 0.5vw, 1.4375rem); --fs-h2: clamp(1.5rem, 1.25rem + 1vw, 1.9375rem); --fs-h1: clamp(2.125rem, 1.6rem + 2.4vw, 3.5rem); --fs-display: clamp(2.5rem, 1.8rem + 3.2vw, 4.25rem);
  --lh-body: 1.68; --lh-tight: 1.12; --lh-heading: 1.2; --measure: 68ch;
  --sp-1: 4px; --sp-2: 8px; --sp-3: 12px; --sp-4: 16px; --sp-5: 24px; --sp-6: 32px; --sp-7: 48px; --sp-8: 64px; --sp-9: 96px; --sp-10: 128px;
  --container: 1240px; --gutter: 24px; --rail: 320px;
  --radius-sm: 4px; --radius: 6px; --radius-lg: 8px;
  --elev-0: none; --elev-1: 0 1px 2px rgba(17, 20, 21, 0.06); --elev-2: 0 8px 24px -12px rgba(17, 20, 21, 0.22); --elev-3: 0 24px 48px -24px rgba(17, 20, 21, 0.35);
  --z-base: 1; --z-sticky: 100; --z-dropdown: 200; --z-overlay: 300; --z-modal: 400; --z-toast: 500;
  --dur-1: 120ms; --dur-2: 200ms; --dur-3: 320ms; --ease-out: cubic-bezier(0.16, 1, 0.3, 1); --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  color-scheme: light;
}
:root[data-theme='dark'] {
  --bg: #111415;
  --surface-1: #171B1D;
  --surface-2: #1D2225;
  --surface-3: #14181A;
  --text: #ECEAE4;
  --text-muted: #A9ADAE;
  --border-subtle: #2A3134;
  --border-strong: #5B6569;
  --accent: #7FC0DA;
  --accent-hover: #A3D3E6;
  --on-accent: #0B1417;
  --link: #7FC0DA;
  --focus-ring: #7FC0DA;
  --up: #7BC29C;
  --down: #E58C80;
  --success-fg: #7BC29C;
  --success-bg: #13241B;
  --success-border: #2E5A42;
  --warning-fg: #E6C072;
  --warning-bg: #2A2210;
  --warning-border: #5C4A1E;
  --danger-fg: #E58C80;
  --danger-bg: #2B1714;
  --danger-border: #6A3029;
  --info-fg: #7FC0DA;
  --info-bg: #112830;
  --info-border: #245466;
  --accent-subtle: #112830; --accent-muted: #245466; --scrim: rgba(0, 0, 0, 0.6);
  --elev-1: 0 1px 2px rgba(0, 0, 0, 0.4); --elev-2: 0 8px 24px -12px rgba(0, 0, 0, 0.7); --elev-3: 0 24px 48px -24px rgba(0, 0, 0, 0.8);
  color-scheme: dark;
}
@media (max-width: 640px) { :root { --gutter: 16px; } }
@font-face { font-family: 'Geist'; src: url('/assets/fonts/geist-sans-latin-400-normal.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Geist'; src: url('/assets/fonts/geist-sans-latin-500-normal.woff2') format('woff2'); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: 'Geist'; src: url('/assets/fonts/geist-sans-latin-600-normal.woff2') format('woff2'); font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: 'Geist Mono'; src: url('/assets/fonts/geist-mono-latin-400-normal.woff2') format('woff2'); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: 'Geist Mono'; src: url('/assets/fonts/geist-mono-latin-500-normal.woff2') format('woff2'); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: 'Geist Fallback'; src: local('Arial'); size-adjust: 104%; ascent-override: 92%; descent-override: 24%; line-gap-override: 0%; }
@font-face { font-family: 'Geist Mono Fallback'; src: local('Courier New'); size-adjust: 100%; ascent-override: 90%; descent-override: 24%; }
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: var(--sp-8); }
body { margin: 0; background-color: var(--bg); color: var(--text); font-family: var(--font-sans); font-size: var(--fs-body); line-height: var(--lh-body); font-feature-settings: 'ss01', 'cv11'; -webkit-font-smoothing: antialiased; }
img, svg, video { max-width: 100%; height: auto; }
img { display: block; }
h1, h2, h3, h4 { font-weight: 600; line-height: var(--lh-heading); letter-spacing: -0.02em; margin: 0; text-wrap: balance; }
h1 { font-size: var(--fs-h1); line-height: var(--lh-tight); letter-spacing: -0.035em; }
h2 { font-size: var(--fs-h2); letter-spacing: -0.025em; }
h3 { font-size: var(--fs-h3); }
p, ul, ol, dl, table, figure, blockquote { margin-block: 0 var(--sp-5); margin-inline: 0; }
p { text-wrap: pretty; }
a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 0.18em; transition: color var(--dur-1) var(--ease-out); }
a:hover { color: var(--accent-hover); }
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 3px; border-radius: 2px; }
::selection { background: var(--accent-muted); color: var(--text); }
code, kbd, .num { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
code { font-size: 0.92em; background: var(--surface-3); padding-inline: var(--sp-1); border-radius: var(--radius-sm); }
kbd { font-size: var(--fs-xs); border: 1px solid var(--border-subtle); border-block-end-width: 2px; border-radius: var(--radius-sm); padding-inline: 5px; background: var(--surface-2); }
hr { border: 0; border-block-start: 1px solid var(--border-subtle); margin-block: var(--sp-6); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; inset-inline-start: var(--sp-4); inset-block-start: -100px; z-index: var(--z-modal); background: var(--accent); color: var(--on-accent); padding: var(--sp-3) var(--sp-4); border-radius: var(--radius); font-weight: 500; }
.skip-link:focus { inset-block-start: var(--sp-4); color: var(--on-accent); }
.container { max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.eyebrow { font-size: var(--fs-xs); font-weight: 500; color: var(--text-muted); letter-spacing: 0.01em; }
.muted { color: var(--text-muted); }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: 0.01ms; animation-iteration-count: 1; transition-duration: 0.01ms; scroll-behavior: auto; } }
.masthead { padding-block: 72px 64px; text-align: center; }
.brand { display: inline-flex; flex-direction: column; align-items: center; gap: var(--sp-4); color: var(--text); text-decoration: none; }
.brand:hover { color: var(--text); }
.brand-mark { width: 72px; height: 72px; }
.brand-word { font-size: clamp(2rem, 1.4rem + 2.6vw, 3.5rem); font-weight: 600; letter-spacing: -0.045em; line-height: 1; }
.brand-word span { color: var(--accent); }
.brand-tag { display: block; margin-block: var(--sp-4) 0; font-size: var(--fs-sm); color: var(--text-muted); }
.navbar { position: sticky; inset-block-start: 0; z-index: var(--z-sticky); background-color: var(--surface-3); border-block: 1px solid var(--border-subtle); }
.navbar-inner { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4); min-height: 58px; }
.nav-sections { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-1); margin: 0; padding: 0; list-style: none; flex: 1 1 auto; }
.nav-sections a { display: inline-flex; align-items: center; min-height: 44px; padding-inline: var(--sp-4); border-radius: var(--radius); color: var(--text); text-decoration: none; font-size: var(--fs-sm); font-weight: 500; }
.nav-sections a:hover { background-color: var(--surface-2); color: var(--text); }
.nav-sections a[aria-current='page'], .nav-sections a[aria-current='true'] { color: var(--accent); box-shadow: inset 0 -2px 0 var(--accent); border-radius: 0; }
.nav-utility { display: flex; align-items: center; gap: var(--sp-2); }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--sp-2); min-width: 44px; min-height: 44px; padding-inline: var(--sp-3); border: 1px solid transparent; border-radius: var(--radius); background: transparent; color: var(--text); font: 500 var(--fs-sm) var(--font-sans); cursor: pointer; transition: background-color var(--dur-1) var(--ease-out); }
.icon-btn:hover { background-color: var(--surface-2); }
.icon-btn:active { transform: translateY(1px); }
.icon-btn svg { width: 20px; height: 20px; }
.icon-btn .kbd-hint { color: var(--text-muted); font-family: var(--font-mono); font-size: var(--fs-xs); }
.nav-menu-btn { display: none; }
.strip { border-block-end: 1px solid var(--border-subtle); }
.strip-inner { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--sp-2) var(--sp-5); min-height: 40px; align-items: center; font-size: var(--fs-xs); color: var(--text-muted); padding-block: var(--sp-2); }
.strip-inner a { color: var(--text); font-weight: 500; margin-inline-start: var(--sp-3); }
@media (max-width: 900px) {
  .masthead { padding-block: var(--sp-6) var(--sp-5); }
  .brand { flex-direction: row; gap: var(--sp-3); }
  .brand-mark { width: 44px; height: 44px; }
  .brand-word { font-size: 1.75rem; }
  .brand-tag { font-size: var(--fs-xs); }
  .nav-sections { display: none; }
  .nav-menu-btn { display: inline-flex; }
  .icon-btn .kbd-hint { display: none; }
}
.drawer { position: fixed; inset: 0; z-index: var(--z-modal); display: none; }
.drawer[data-open='true'] { display: block; }
.drawer-backdrop { position: absolute; inset: 0; background: var(--scrim); }
.drawer-panel { position: absolute; inset-block: 0; inset-inline-end: 0; width: min(360px, 88vw); background: var(--bg); padding: var(--sp-5); padding-block-end: calc(var(--sp-5) + env(safe-area-inset-bottom)); overflow-y: auto; box-shadow: var(--elev-3); display: flex; flex-direction: column; gap: var(--sp-5); }
.drawer-head { display: flex; justify-content: space-between; align-items: center; }
.drawer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.drawer-links a { display: flex; min-height: 48px; align-items: center; color: var(--text); text-decoration: none; font-size: var(--fs-lg); font-weight: 500; border-block-end: 1px solid var(--border-subtle); }
.drawer-sub { list-style: none; margin: 0; padding: 0 0 var(--sp-2) var(--sp-4); }
.drawer-sub a { font-size: var(--fs-body); font-weight: 400; color: var(--text-muted); border: 0; min-height: 44px; }
.strip-inner p { margin: 0; text-align: center; }
.masthead { padding-block: 0; }
.masthead .brand { display: flex; align-items: center; justify-content: center; min-height: 300px; padding-block: var(--sp-7); }
.brand-lockup { width: min(560px, 86vw); height: auto; display: block; }
@media (max-width: 900px) { .masthead .brand { min-height: 140px; padding-block: var(--sp-5); } .brand-lockup { width: min(340px, 86vw); } }
.nav-utility { min-width: 240px; justify-content: flex-end; }
@media (max-width: 900px) { .nav-utility { min-width: 0; } }
.page { padding-block: var(--sp-7) var(--sp-9); }
.page-grid { display: grid; grid-template-columns: minmax(0, 1fr) var(--rail); gap: var(--sp-8); align-items: start; }
.page-main { min-width: 0; }
.page-rail { display: flex; flex-direction: column; gap: var(--sp-6); position: sticky; inset-block-start: 84px; }
.page-rail.not-sticky { position: static; }
@media (max-width: 1024px) { .page-grid { grid-template-columns: minmax(0, 1fr); gap: var(--sp-7); } .page-rail { position: static; } }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: var(--sp-2); list-style: none; margin: 0 0 var(--sp-4); padding: 0; font-size: var(--fs-xs); color: var(--text-muted); }
.breadcrumb li + li::before { content: '/'; margin-inline-end: var(--sp-2); color: var(--border-strong); }
.breadcrumb a { color: var(--text-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--text); text-decoration: underline; }
.page-head { margin-block-end: var(--sp-6); }
.page-head .lede { font-size: var(--fs-lg); color: var(--text-muted); max-width: 60ch; margin-block: var(--sp-4) 0; }
.byline { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-4); align-items: center; margin-block-start: var(--sp-5); padding-block-end: var(--sp-5); border-block-end: 1px solid var(--border-subtle); font-size: var(--fs-sm); color: var(--text-muted); }
.byline strong { color: var(--text); font-weight: 500; }
.intro { padding-block-end: var(--sp-6); margin-block-end: var(--sp-6); border-block-end: 1px solid var(--border-subtle); }
.intro h1 { font-size: var(--fs-display); max-width: 15ch; }
.intro p { font-size: var(--fs-lg); color: var(--text-muted); max-width: 56ch; margin-block: var(--sp-4) 0; }
.intro-actions { display: flex; flex-wrap: wrap; gap: var(--sp-3) var(--sp-5); align-items: center; margin-block-start: var(--sp-5); }
.feed { display: flex; flex-direction: column; }
.post { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: var(--sp-5); padding-block: var(--sp-7); border-block-end: 1px solid var(--border-subtle); }
.post:first-child { padding-block-start: 0; }
.post-meta { display: flex; flex-direction: column; align-items: center; gap: var(--sp-2); padding-block-start: var(--sp-1); }
.post-badge { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 64px; height: 64px; border-radius: var(--radius-lg); background: var(--surface-3); color: var(--text); }
.post-badge .num { font-size: 1.375rem; font-weight: 500; line-height: 1; }
.post-badge small { font-size: 0.6875rem; color: var(--text-muted); margin-block-start: 3px; }
.post-cat { writing-mode: horizontal-tb; font-size: 0.6875rem; color: var(--text-muted); text-align: center; line-height: 1.3; }
.post h2 { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.125rem); letter-spacing: -0.03em; }
.post h2 a { color: var(--text); text-decoration: none; }
.post h2 a:hover { color: var(--accent); }
.post-kicker { font-size: var(--fs-xs); font-weight: 500; color: var(--accent); margin-block-end: var(--sp-2); }
.post-figure { margin-block: var(--sp-5); border-radius: var(--radius-lg); overflow: hidden; background: var(--surface-2); border: 1px solid var(--border-subtle); }
.post-figure img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.post-figure figcaption { font-size: var(--fs-xs); color: var(--text-muted); padding: var(--sp-2) var(--sp-3); }
.post p.excerpt { max-width: var(--measure); }
.read-more { display: inline-flex; align-items: center; gap: var(--sp-2); font-weight: 500; text-decoration: none; min-height: 44px; }
.read-more svg { width: 16px; height: 16px; transition: transform var(--dur-2) var(--ease-out); }
.read-more:hover svg { transform: translateX(3px); }
@media (max-width: 640px) {
  .post { grid-template-columns: minmax(0, 1fr); gap: var(--sp-3); padding-block: var(--sp-6); }
  .post-meta { flex-direction: row; justify-content: flex-start; }
  .post-badge { flex-direction: row; gap: var(--sp-1); width: auto; height: auto; padding: var(--sp-1) var(--sp-3); }
  .post-badge small { margin: 0; }
}
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: var(--sp-5); margin: 0 0 var(--sp-6); padding: 0; list-style: none; }
.card { display: flex; flex-direction: column; gap: var(--sp-2); padding: var(--sp-5); border-radius: var(--radius-lg); background: var(--surface-2); border: 1px solid var(--border-subtle); transition: border-color var(--dur-2) var(--ease-out), box-shadow var(--dur-2) var(--ease-out); position: relative; }
.card:hover { border-color: var(--border-strong); box-shadow: var(--elev-2); }
.card:focus-within { border-color: var(--accent); }
.card h3 { font-size: 1.125rem; letter-spacing: -0.015em; }
.card h3 a { color: var(--text); text-decoration: none; }
.card h3 a::after { content: ''; position: absolute; inset: 0; border-radius: inherit; }
.card p { margin: 0; font-size: var(--fs-sm); color: var(--text-muted); }
.card .card-foot { margin-block-start: auto; padding-block-start: var(--sp-2); font-size: var(--fs-xs); color: var(--text-muted); }
.card-img { margin: calc(var(--sp-5) * -1) calc(var(--sp-5) * -1) var(--sp-3); border-radius: var(--radius-lg) var(--radius-lg) 0 0; overflow: hidden; }
.card-img img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.card--compact { padding: var(--sp-4); }
.card--compact .card-img { margin: calc(var(--sp-4) * -1) calc(var(--sp-4) * -1) var(--sp-2); }
.card--featured { grid-column: 1 / -1; display: grid; grid-template-columns: 1.2fr 1fr; gap: var(--sp-5); align-items: center; }
.card--featured .card-img { margin: calc(var(--sp-5) * -1) 0 calc(var(--sp-5) * -1) calc(var(--sp-5) * -1); border-radius: var(--radius-lg) 0 0 var(--radius-lg); height: calc(100% + var(--sp-5) * 2); }
.card--featured .card-img img { height: 100%; aspect-ratio: auto; }
@media (max-width: 720px) { .card--featured { grid-template-columns: minmax(0, 1fr); } .card--featured .card-img { margin: calc(var(--sp-5) * -1) calc(var(--sp-5) * -1) var(--sp-3); border-radius: var(--radius-lg) var(--radius-lg) 0 0; height: auto; } }
.tag { display: inline-flex; align-items: center; min-height: 28px; padding-inline: var(--sp-3); border-radius: var(--radius); background: var(--surface-3); color: var(--text); font-size: var(--fs-xs); font-weight: 500; text-decoration: none; }
a.tag:hover { background: var(--accent-subtle); color: var(--accent); }
.widget { padding: var(--sp-5); border-radius: var(--radius-lg); background: var(--surface-2); border: 1px solid var(--border-subtle); }
.widget-title { font-size: var(--fs-sm); font-weight: 600; letter-spacing: -0.005em; margin: 0 0 var(--sp-3); }
.widget p { font-size: var(--fs-sm); color: var(--text-muted); margin-block-end: var(--sp-3); }
.widget p:last-child { margin: 0; }
.widget ul { list-style: none; margin: 0; padding: 0; }
.widget li a { display: flex; justify-content: space-between; gap: var(--sp-3); min-height: 40px; align-items: center; color: var(--text); text-decoration: none; font-size: var(--fs-sm); border-block-end: 1px solid var(--border-subtle); }
.widget li:last-child a { border: 0; }
.widget li a:hover { color: var(--accent); }
.widget li a .count { color: var(--text-muted); font-family: var(--font-mono); font-size: var(--fs-xs); }
.desk { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: var(--sp-4); align-items: start; }
.desk-mark { width: 56px; height: 56px; border-radius: var(--radius-lg); background: var(--accent-subtle); display: flex; align-items: center; justify-content: center; }
.desk-mark svg { width: 32px; height: 32px; }
.steps-mini { counter-reset: s; }
.steps-mini li { counter-increment: s; }
.steps-mini li a::before { content: counter(s); flex: 0 0 24px; height: 24px; border-radius: 50%; background: var(--accent-subtle); color: var(--accent); font: 500 var(--fs-xs) var(--font-mono); display: inline-flex; align-items: center; justify-content: center; }
.steps-mini li a { justify-content: flex-start; }
.rail-search { display: flex; gap: var(--sp-2); }
.rail-search input { flex: 1 1 auto; min-width: 0; }
.toc { font-size: var(--fs-sm); }
.toc ol { list-style: none; margin: 0; padding: 0; border-inline-start: 1px solid var(--border-subtle); }
.toc a { display: block; padding: var(--sp-2) var(--sp-3); margin-inline-start: -1px; border-inline-start: 2px solid transparent; color: var(--text-muted); text-decoration: none; line-height: 1.4; }
.toc a:hover { color: var(--text); }
.toc a[aria-current='true'] { color: var(--accent); border-inline-start-color: var(--accent); font-weight: 500; }
.toc-mobile { display: none; margin-block-end: var(--sp-6); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); background: var(--surface-2); }
.toc-mobile summary { min-height: 48px; display: flex; align-items: center; padding-inline: var(--sp-4); font-weight: 500; cursor: pointer; }
.toc-mobile .toc { padding: 0 var(--sp-4) var(--sp-4); }
@media (max-width: 1024px) { .toc-mobile { display: block; } .page-rail .toc-widget { display: none; } }
.widget .toc li a { display: block; min-height: 0; border-block-end: 0; padding: var(--sp-2) var(--sp-3); font-size: var(--fs-sm); color: var(--text-muted); }
.widget .toc li a:hover { color: var(--text); }
.widget .toc li a[aria-current='true'] { color: var(--accent); }
.prose { max-width: var(--measure); }
.prose > h2 { margin-block: var(--sp-8) var(--sp-4); scroll-margin-top: 88px; }
.prose > h3 { margin-block: var(--sp-6) var(--sp-3); scroll-margin-top: 88px; }
.prose h2 .anchor, .prose h3 .anchor { margin-inline-start: var(--sp-2); opacity: 0; color: var(--text-muted); text-decoration: none; font-weight: 400; transition: opacity var(--dur-1) var(--ease-out); }
.prose h2:hover .anchor, .prose h3:hover .anchor, .prose .anchor:focus-visible { opacity: 1; }
.prose ul, .prose ol { padding-inline-start: 1.3em; }
.prose li { margin-block-end: var(--sp-2); }
.prose li::marker { color: var(--text-muted); }
.prose blockquote { border-inline-start: 2px solid var(--accent); padding-inline-start: var(--sp-5); color: var(--text); font-size: var(--fs-lg); }
.prose blockquote cite { display: block; margin-block-start: var(--sp-2); font-size: var(--fs-sm); font-style: normal; color: var(--text-muted); }
sup.cite { font-size: 0.72em; line-height: 0; margin-inline-start: 1px; }
sup.cite a { font-family: var(--font-mono); text-decoration: none; padding-inline: 2px; border-radius: 3px; }
sup.cite a:hover { background: var(--accent-subtle); }
.quick-answer { margin-block-end: var(--sp-6); padding: var(--sp-5) var(--sp-5) var(--sp-5) var(--sp-6); border-radius: var(--radius-lg); background: var(--accent-subtle); position: relative; }
.quick-answer::before { content: ''; position: absolute; inset-block: var(--sp-5); inset-inline-start: 0; width: 3px; border-radius: 0 2px 2px 0; background: var(--accent); }
.quick-answer .label { font-size: var(--fs-xs); font-weight: 600; color: var(--accent); margin-block-end: var(--sp-2); }
.quick-answer p { margin: 0; font-size: var(--fs-lg); line-height: 1.55; }
.takeaways { margin-block-end: var(--sp-6); }
.takeaways h2 { font-size: var(--fs-sm); margin-block-end: var(--sp-3); }
.takeaways ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-3); }
.takeaways li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: var(--sp-3); align-items: start; margin: 0; }
.takeaways li svg { width: 20px; height: 20px; margin-block-start: 4px; color: var(--accent); }
.figure { margin-block: var(--sp-6); }
.figure img { width: 100%; border-radius: var(--radius-lg); }
.figure figcaption, .credit { font-size: var(--fs-xs); color: var(--text-muted); margin-block-start: var(--sp-2); line-height: 1.5; }
.figure--lead { margin-block: 0 var(--sp-6); }
.figure--lead img { aspect-ratio: 16 / 9; object-fit: cover; }
.figure--wide { margin-inline: 0; }
.diagram { padding: var(--sp-5); border-radius: var(--radius-lg); background: var(--surface-2); border: 1px solid var(--border-subtle); }
.diagram svg { width: 100%; height: auto; display: block; }
.diagram .d-v { display: none; }
@media (max-width: 640px) { .diagram .d-h { display: none; } .diagram .d-v { display: block; } }
.table-wrap { overflow-x: auto; margin-block: var(--sp-6); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); background: var(--surface-2); }
table.data { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); margin: 0; }
table.data caption { text-align: start; padding: var(--sp-3) var(--sp-4); font-weight: 600; font-size: var(--fs-sm); }
table.data th, table.data td { padding: var(--sp-3) var(--sp-4); text-align: start; vertical-align: top; border-block-start: 1px solid var(--border-subtle); }
table.data thead th { font-size: var(--fs-xs); font-weight: 500; color: var(--text-muted); border-block-start: 0; background: var(--surface-1); }
table.data td.num, table.data th.num { text-align: end; font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
@media (max-width: 640px) {
  .table-wrap { border: 0; background: transparent; overflow: visible; }
  table.data thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  table.data, table.data tbody, table.data tr, table.data td { display: block; width: 100%; }
  table.data tr { margin-block-end: var(--sp-3); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); background: var(--surface-2); padding: var(--sp-2) 0; }
  table.data td { border: 0; padding: var(--sp-2) var(--sp-4); display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: var(--sp-3); text-align: start; }
  table.data td.num { text-align: start; }
  table.data td::before { content: attr(data-label); font-size: var(--fs-xs); color: var(--text-muted); font-family: var(--font-sans); }
}
.callout { margin-block: var(--sp-6); padding: var(--sp-4) var(--sp-5); border-radius: var(--radius-lg); border: 1px solid var(--info-border); background: var(--info-bg); display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: var(--sp-3); }
.callout svg { width: 20px; height: 20px; margin-block-start: 3px; color: var(--info-fg); }
.callout-title { font-weight: 600; font-size: var(--fs-sm); margin-block-end: var(--sp-1); color: var(--info-fg); }
.callout p { margin: 0 0 var(--sp-2); font-size: var(--fs-sm); }
.callout p:last-child { margin: 0; }
.callout--tip { border-color: var(--success-border); background: var(--success-bg); }
.callout--tip svg, .callout--tip .callout-title { color: var(--success-fg); }
.callout--warning { border-color: var(--warning-border); background: var(--warning-bg); }
.callout--warning svg, .callout--warning .callout-title { color: var(--warning-fg); }
.callout--example { border-color: var(--border-subtle); background: var(--surface-2); }
.callout--example svg, .callout--example .callout-title { color: var(--text); }
.callout--danger { border-color: var(--danger-border); background: var(--danger-bg); }
.callout--danger svg, .callout--danger .callout-title { color: var(--danger-fg); }
.steps { list-style: none; counter-reset: step; margin-block: var(--sp-6); padding: 0; display: grid; gap: 0; }
.steps li { counter-increment: step; display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: var(--sp-4); padding-block-end: var(--sp-5); position: relative; margin: 0; }
.steps li::before { content: counter(step); width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--border-strong); background: var(--bg); display: flex; align-items: center; justify-content: center; font: 500 var(--fs-sm) var(--font-mono); position: relative; z-index: 1; }
.steps li::after { content: ''; position: absolute; inset-inline-start: 19.5px; inset-block: 40px 0; width: 1px; background: var(--border-subtle); }
.steps li:last-child::after { display: none; }
.steps .step-title { font-weight: 600; display: block; margin-block: var(--sp-2) var(--sp-1); }
.factbox { margin-block: var(--sp-6); border-radius: var(--radius-lg); border: 1px solid var(--border-subtle); background: var(--surface-2); overflow: hidden; }
.factbox-title { padding: var(--sp-3) var(--sp-5); font-size: var(--fs-sm); font-weight: 600; background: var(--surface-1); border-block-end: 1px solid var(--border-subtle); }
.factbox dl { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); margin: 0; }
.factbox dl > div { padding: var(--sp-4) var(--sp-5); border-block-end: 1px solid var(--border-subtle); }
.factbox dt { font-size: var(--fs-xs); color: var(--text-muted); }
.factbox dd { margin: var(--sp-1) 0 0; font: 500 1.25rem/1.3 var(--font-mono); font-variant-numeric: tabular-nums; }
.factbox dd small { display: block; font: 400 var(--fs-xs) var(--font-sans); color: var(--text-muted); margin-block-start: var(--sp-1); }
.mistakes { margin-block: var(--sp-6); display: grid; gap: var(--sp-3); list-style: none; padding: 0; }
.mistakes li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: var(--sp-3); padding: var(--sp-4); border-radius: var(--radius-lg); background: var(--surface-2); border: 1px solid var(--border-subtle); margin: 0; }
.mistakes li svg { width: 20px; height: 20px; color: var(--danger-fg); margin-block-start: 3px; }
.mistakes strong { display: block; }
.faq { margin-block: var(--sp-5); border-block-start: 1px solid var(--border-subtle); }
.faq details { border-block-end: 1px solid var(--border-subtle); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: var(--sp-4); align-items: center; min-height: 56px; padding-block: var(--sp-3); font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font: 400 1.5rem/1 var(--font-mono); color: var(--text-muted); transition: transform var(--dur-2) var(--ease-out); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .faq-a { padding-block-end: var(--sp-4); }
.faq .faq-a p:last-child { margin: 0; }
.checked { margin-block: var(--sp-7) var(--sp-5); padding: var(--sp-5); border-radius: var(--radius-lg); background: var(--surface-3); font-size: var(--fs-sm); }
.checked h2 { font-size: var(--fs-sm); margin-block-end: var(--sp-2); }
.checked p { margin: 0; color: var(--text-muted); }
.sources { font-size: var(--fs-sm); }
.sources ol { padding-inline-start: 1.6em; }
.sources li { margin-block-end: var(--sp-3); scroll-margin-top: 96px; }
.sources li:target { background: var(--accent-subtle); border-radius: var(--radius-sm); }
.sources .src-meta { color: var(--text-muted); }
.disclaimer { margin-block-start: var(--sp-6); font-size: var(--fs-xs); color: var(--text-muted); border-block-start: 1px solid var(--border-subtle); padding-block-start: var(--sp-4); }
.further { margin-block: var(--sp-6); }
.further h2 { font-size: var(--fs-h3); margin-block-end: var(--sp-4); }
.term-def { font-size: var(--fs-lg); line-height: 1.55; }
.az-bar { position: sticky; inset-block-start: 60px; z-index: var(--z-base); display: flex; flex-wrap: wrap; gap: var(--sp-1); padding-block: var(--sp-3); background: var(--bg); border-block-end: 1px solid var(--border-subtle); margin-block-end: var(--sp-5); }
.az-bar a, .az-bar span { min-width: 36px; min-height: 36px; display: inline-flex; align-items: center; justify-content: center; border-radius: var(--radius); font: 500 var(--fs-sm) var(--font-mono); text-decoration: none; }
.az-bar a:hover { background: var(--surface-3); }
.az-bar span { color: var(--border-strong); }
.az-group { margin-block-end: var(--sp-6); scroll-margin-top: 140px; }
.az-group h2 { font: 500 var(--fs-h3) var(--font-mono); color: var(--accent); margin-block-end: var(--sp-3); }
.az-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--sp-3) var(--sp-5); }
.az-list a { font-weight: 500; }
.az-list p { margin: 0; font-size: var(--fs-sm); color: var(--text-muted); }
.progress { position: fixed; inset-block-start: 0; inset-inline: 0; height: 2px; z-index: var(--z-toast); background: transparent; }
.progress span { display: block; height: 100%; width: 100%; background: var(--accent); transform-origin: 0 50%; transform: scaleX(0); }
table.data tbody th { font-weight: 500; padding: var(--sp-3) var(--sp-4); text-align: start; vertical-align: top; border-block-start: 1px solid var(--border-subtle); }
@media (max-width: 640px) { table.data tbody th { display: block; width: 100%; border: 0; padding: var(--sp-2) var(--sp-4); font-weight: 600; } }
.brand-mark--sm { width: 32px; height: 32px; }
@media (max-width: 640px) { .prose h2 .anchor, .prose h3 .anchor { display: none; } }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--sp-2); min-height: 44px; padding-inline: var(--sp-5); border-radius: var(--radius); border: 1px solid transparent; font: 500 var(--fs-sm) var(--font-sans); text-decoration: none; cursor: pointer; transition: background-color var(--dur-1) var(--ease-out), border-color var(--dur-1) var(--ease-out), transform var(--dur-1) var(--ease-out); }
.btn:active { transform: translateY(1px); }
.btn svg { width: 18px; height: 18px; }
.btn--primary { background: var(--accent); color: var(--on-accent); }
.btn--primary:hover { background: var(--accent-hover); color: var(--on-accent); }
.btn--secondary { background: var(--surface-2); border-color: var(--border-strong); color: var(--text); }
.btn--secondary:hover { border-color: var(--text); color: var(--text); }
.btn--ghost { background: transparent; color: var(--text); }
.btn--ghost:hover { background: var(--surface-3); color: var(--text); }
.btn--sm { min-height: 36px; padding-inline: var(--sp-3); font-size: var(--fs-xs); }
.btn--lg { min-height: 52px; padding-inline: var(--sp-6); font-size: var(--fs-body); }
.btn[disabled], .btn[aria-disabled='true'] { opacity: 0.5; cursor: not-allowed; transform: none; }
.text-link { font-weight: 500; color: var(--text); text-decoration: underline; text-decoration-color: var(--border-strong); }
.text-link:hover { color: var(--accent); text-decoration-color: var(--accent); }
.field { display: flex; flex-direction: column; gap: var(--sp-2); margin-block-end: var(--sp-4); }
.field label { font-size: var(--fs-sm); font-weight: 500; }
.field .hint { font-size: var(--fs-xs); color: var(--text-muted); }
.field .error { font-size: var(--fs-xs); color: var(--danger-fg); }
input, select, textarea { font: 400 1rem var(--font-sans); color: var(--text); background: var(--surface-2); border: 1px solid var(--border-strong); border-radius: var(--radius); padding: var(--sp-3) var(--sp-4); min-height: 48px; width: 100%; transition: border-color var(--dur-1) var(--ease-out), box-shadow var(--dur-1) var(--ease-out); }
input:hover, select:hover, textarea:hover { border-color: var(--text-muted); }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-muted); }
input[aria-invalid='true'], textarea[aria-invalid='true'] { border-color: var(--danger-fg); }
input[disabled] { opacity: 0.55; }
input[type='number'] { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
textarea { min-height: 140px; resize: vertical; }
.check { display: flex; gap: var(--sp-3); align-items: flex-start; font-size: var(--fs-sm); min-height: 44px; }
.check input { width: 20px; height: 20px; min-height: 0; margin-block-start: 2px; accent-color: var(--accent); }
.form-status { margin-block-start: var(--sp-3); font-size: var(--fs-sm); padding: var(--sp-3) var(--sp-4); border-radius: var(--radius); }
.form-status[data-state='ok'] { background: var(--success-bg); color: var(--success-fg); }
.form-status[data-state='err'] { background: var(--danger-bg); color: var(--danger-fg); }
.form-status[data-state='busy'] { background: var(--surface-3); color: var(--text-muted); }
.tool { margin-block: var(--sp-6); display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); border-radius: var(--radius-lg); border: 1px solid var(--border-subtle); background: var(--surface-2); overflow: hidden; }
.tool-form { padding: var(--sp-6); border-inline-end: 1px solid var(--border-subtle); }
.tool-form .field:last-child { margin: 0; }
.tool-out { padding: var(--sp-6); background: var(--surface-1); display: flex; flex-direction: column; gap: var(--sp-5); }
.tool-out .result { display: flex; flex-direction: column; gap: var(--sp-1); }
.tool-out .result-label { font-size: var(--fs-xs); color: var(--text-muted); }
.tool-out .result-value { font: 500 1.75rem/1.2 var(--font-mono); font-variant-numeric: tabular-nums; }
.tool-out .result-value.is-main { color: var(--accent); font-size: 2.25rem; }
.tool-out .result-value.is-loss { color: var(--down); }
.tool-out .result-note { font-size: var(--fs-xs); color: var(--text-muted); }
.tool-note { font-size: var(--fs-xs); color: var(--text-muted); margin-block-start: var(--sp-3); }
.tool [data-noscript] { font-size: var(--fs-sm); color: var(--text-muted); }
@media (max-width: 720px) { .tool { grid-template-columns: minmax(0, 1fr); } .tool-form { border-inline-end: 0; border-block-end: 1px solid var(--border-subtle); padding: var(--sp-5); } .tool-out { padding: var(--sp-5); } }
.formula { font-family: var(--font-mono); font-size: var(--fs-sm); padding: var(--sp-4); background: var(--surface-3); border-radius: var(--radius); overflow-x: auto; }
.site-footer { border-block-start: 1px solid var(--border-subtle); background-color: var(--surface-3); padding-block: var(--sp-8) var(--sp-6); padding-block-end: calc(var(--sp-6) + env(safe-area-inset-bottom)); font-size: var(--fs-sm); }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: var(--sp-6); }
.footer-grid h2 { font-size: var(--fs-sm); margin-block-end: var(--sp-3); }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li a { display: inline-flex; min-height: 44px; align-items: center; color: var(--text-muted); text-decoration: none; }
.footer-grid li a:hover { color: var(--text); text-decoration: underline; }
.footer-brand p { color: var(--text-muted); max-width: 34ch; margin-block: var(--sp-3) 0; }
.risk-note { margin-block-start: var(--sp-7); padding-block-start: var(--sp-5); border-block-start: 1px solid var(--border-subtle); color: var(--text-muted); font-size: var(--fs-xs); line-height: 1.6; max-width: 110ch; }
.risk-note strong { color: var(--text); }
.footer-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--sp-3); margin-block-start: var(--sp-5); color: var(--text-muted); font-size: var(--fs-xs); }
@media (max-width: 900px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .footer-brand { grid-column: 1 / -1; } }
.to-top { position: fixed; inset-inline-end: var(--sp-4); inset-block-end: calc(var(--sp-4) + env(safe-area-inset-bottom)); z-index: var(--z-sticky); opacity: 0; pointer-events: none; transform: translateY(8px); transition: opacity var(--dur-2) var(--ease-out), transform var(--dur-2) var(--ease-out); background: var(--surface-2); border: 1px solid var(--border-subtle); box-shadow: var(--elev-2); }
.to-top[data-show='true'] { opacity: 1; pointer-events: auto; transform: none; }
.toast { position: fixed; inset-block-end: calc(var(--sp-5) + env(safe-area-inset-bottom)); inset-inline-start: 50%; transform: translateX(-50%); z-index: var(--z-toast); background: var(--text); color: var(--bg); padding: var(--sp-3) var(--sp-5); border-radius: var(--radius); font-size: var(--fs-sm); box-shadow: var(--elev-3); }
.toast[hidden] { display: none; }
.search-dialog { position: fixed; inset: 0; z-index: var(--z-modal); display: none; }
.search-dialog[data-open='true'] { display: block; }
.search-dialog .drawer-backdrop { position: absolute; inset: 0; }
.search-panel { position: relative; max-width: 640px; margin: 10vh auto 0; background: var(--bg); border-radius: var(--radius-lg); box-shadow: var(--elev-3); border: 1px solid var(--border-subtle); overflow: hidden; }
.search-panel header { display: flex; gap: var(--sp-2); padding: var(--sp-3); border-block-end: 1px solid var(--border-subtle); }
.search-panel input { border: 0; background: transparent; font-size: 1.125rem; }
.search-panel input:focus-visible { box-shadow: none; }
.search-results { list-style: none; margin: 0; padding: var(--sp-2); max-height: 60vh; overflow-y: auto; }
.search-results a { display: block; padding: var(--sp-3); border-radius: var(--radius); text-decoration: none; color: var(--text); }
.search-results a:hover, .search-results a[aria-selected='true'] { background: var(--surface-3); }
.search-results .r-type { font-size: var(--fs-xs); color: var(--text-muted); }
.search-results .r-title { font-weight: 500; display: block; }
.search-empty { padding: var(--sp-5); color: var(--text-muted); font-size: var(--fs-sm); }
.search-panel footer { padding: var(--sp-2) var(--sp-4); border-block-start: 1px solid var(--border-subtle); font-size: var(--fs-xs); color: var(--text-muted); display: flex; gap: var(--sp-4); }
.skeleton { background: linear-gradient(90deg, var(--surface-3), var(--surface-2), var(--surface-3)); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; border-radius: var(--radius); min-height: 18px; }
@keyframes shimmer { to { background-position: -200% 0; } }
.notfound { text-align: start; max-width: 56ch; }
.notfound .code { font: 500 var(--fs-xs) var(--font-mono); color: var(--text-muted); }
.sg-swatches { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: var(--sp-3); list-style: none; padding: 0; }
.sg-swatch { border: 1px solid var(--border-subtle); border-radius: var(--radius); overflow: hidden; font-size: var(--fs-xs); background: var(--surface-2); }
.sg-swatch span { display: block; height: 52px; }
.sg-swatch p { margin: 0; padding: var(--sp-2); font-family: var(--font-mono); }
.sg-row { display: flex; flex-wrap: wrap; gap: var(--sp-3); align-items: center; margin-block-end: var(--sp-5); }
.reveal { opacity: 0; transform: translateY(12px); transition: opacity 600ms var(--ease-out), transform 600ms var(--ease-out); }
.reveal.is-in { opacity: 1; transform: none; }
