/* markusbehmann.com — design system
   Dark only, page background #000. Warm yellow (--volt) = buttons and controls only. Teal (--acc) = labels, links and marks, blue, teal and violet = cards, data and light, orange = errors and warnings. No red.
   No outlines on chips, inputs or cards. Sections are all #000: no grey bands and no hairlines between them, light comes from slanted glow slabs.
   Headline gradient = blue → teal (nerdy.money).
   Hard edges: radius 6–12px, 1px lines, glow only on the accent.
   No inline styles in markup – add a class here instead (npm run check fails on style="…"). */

@font-face { font-family: "Urbanist"; font-weight: 300 800; font-display: swap; src: url(../fonts/urbanist-var.woff2) format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 100 900; font-display: swap; src: url(../fonts/inter-var.woff2) format("woff2"); }
@font-face { font-family: "IBM Plex Mono"; font-weight: 500; font-display: swap; src: url(../fonts/plex-mono-500.woff2) format("woff2"); }

/* ------------------------------------------------------------------ tokens */
:root {
  --bg: #000; --surf: rgba(255, 255, 255, .04); --surf2: rgba(255, 255, 255, .075); --line: rgba(255, 255, 255, .06); --line2: rgba(255, 255, 255, .13);
  --card-sh: inset 0 1px 0 rgba(255, 255, 255, .06);
  --text: #d9dde4; --text2: #949ba8; --head: #fff;
  --volt: #ffd84a; --volt-ink: #151000;
  --blue: #4d8dff; --blue2: #2a74ff; --blue-wash: rgba(77, 141, 255, .12);
  --teal: #2dd4bf; --teal-wash: rgba(45, 212, 191, .12);
  --warn: #ff9f5a; --warn-wash: rgba(255, 159, 90, .12);
  --violet: #a78bfa; --pink: #e879f9;
  --grad: linear-gradient(100deg, #6aa2ff 0%, #3b82ff 45%, #2dd4bf 100%); /* text gradient: blue → teal, same as nerdy.money */
  --r-s: 6px; --r: 10px; --r-l: 14px;
  --f-head: "Urbanist", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Inter", "Helvetica Neue", Arial, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --wrap: clamp(1200px, 80vw, 1680px); --gutter: clamp(16px, 4vw, 40px); --bar-h: 68px;
  --glow: 0 0 0 1px rgba(255, 216, 74, .35), 0 12px 50px -12px rgba(255, 216, 74, .45);
  --acc: var(--teal); --acc-wash: var(--teal-wash); /* text accents, labels, links. Yellow is for buttons and controls only */
  --c: var(--blue);
  color-scheme: dark;
}
.c-blue { --c: var(--blue); } .c-teal { --c: var(--teal); } .c-pink { --c: var(--pink); } .c-orange { --c: var(--warn); }
.tri:nth-child(2), .talk:nth-child(2), .step:nth-child(2) { --c: var(--teal); } .tri:nth-child(3), .talk:nth-child(3), .step:nth-child(3) { --c: var(--violet); } .talk:nth-child(4), .step:nth-child(4) { --c: var(--pink); } .c-violet { --c: var(--violet); }

/* ------------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; background: var(--bg); }
html.no-scroll { overflow: hidden; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } [data-reveal] { opacity: 1 !important; transform: none !important; } }
body { margin: 0; background: var(--bg); color: var(--text); font: 400 1.0625rem/1.65 var(--f-body); overflow-x: hidden; -webkit-font-smoothing: antialiased; }
main { overflow-x: clip; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--acc); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: #fff; }
h1, h2, h3, h4 { font-family: var(--f-head); color: var(--head); line-height: 1.08; letter-spacing: -.02em; margin: 0 0 .5em; font-weight: 800; text-wrap: balance; overflow-wrap: break-word; }
h1 { font-size: clamp(2.5rem, 6.4vw, 4.9rem); }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.8rem); }
h3 { font-size: 1.3rem; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.2em; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; }
[hidden] { display: none !important; }
::selection { background: var(--blue2); color: #fff; }
:focus-visible { outline: 2px solid var(--volt); outline-offset: 3px; border-radius: 4px; }
kbd { font: 500 .75rem/1 var(--f-mono); padding: 4px 6px; border-radius: 5px; color: var(--text2); background: var(--surf); }
code { font: 500 .88em var(--f-mono); background: var(--surf2); border: 1px solid var(--line); padding: .1em .4em; border-radius: 5px; color: #cfe0ff; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 200; background: var(--volt); color: var(--volt-ink); padding: 10px 16px; border-radius: var(--r-s); font-weight: 600; }
.skip:focus { left: 8px; }
.i { width: 1.1em; height: 1.1em; flex: none; display: inline-block; vertical-align: -.18em; }
.wrap { width: min(var(--wrap), 100% - 2 * var(--gutter)); margin-inline: auto; }
.wrap-narrow { width: min(820px, 100% - 2 * var(--gutter)); }
.wrap-article { width: min(var(--wrap), 100% - 2 * var(--gutter)); }
.section { padding: clamp(56px, 8vw, 110px) 0; position: relative; }
.section-tight { padding: clamp(36px, 5vw, 64px) 0; }
/* Bands: no grey, no lines. A slanted slab of light marks the change of section. */
.section-band { background: #000; isolation: isolate; padding-block: clamp(90px, 12vw, 170px); }
.section-band::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  clip-path: polygon(0 clamp(40px, 7vw, 110px), 100% 0, 100% calc(100% - clamp(40px, 7vw, 110px)), 0 100%);
  background: radial-gradient(70% 90% at 100% 0%, rgba(42, 116, 255, .22), transparent 62%), radial-gradient(60% 80% at 0% 100%, rgba(45, 212, 191, .13), transparent 60%), linear-gradient(180deg, rgba(255, 255, 255, .035), rgba(255, 255, 255, .01)); }
.section-band:nth-of-type(4n)::before { clip-path: polygon(0 0, 100% clamp(40px, 7vw, 110px), 100% 100%, 0 calc(100% - clamp(40px, 7vw, 110px)));
  background: radial-gradient(70% 90% at 0% 0%, rgba(45, 212, 191, .18), transparent 62%), radial-gradient(60% 80% at 100% 100%, rgba(167, 139, 250, .16), transparent 60%), linear-gradient(180deg, rgba(255, 255, 255, .035), rgba(255, 255, 255, .01)); }
.section-band::after { content: ""; position: absolute; z-index: -1; pointer-events: none; width: 46vw; height: 46vw; max-width: 640px; max-height: 640px; right: -12vw; top: -8vw; border-radius: 50%; background: radial-gradient(closest-side, rgba(77, 141, 255, .16), transparent 70%); filter: blur(30px); animation: drift 16s ease-in-out infinite alternate; }
@keyframes drift { to { transform: translate(-8vw, 6vw) scale(1.15); } }
.section-tool { padding-top: 0; }
.volt, .grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.kicker, .block-k { font: 500 .78rem/1.4 var(--f-mono); color: var(--acc); letter-spacing: .04em; text-transform: lowercase; margin: 0 0 14px; }
.block-k { display: flex; align-items: center; gap: 8px; }
.lead { font-size: clamp(1.05rem, 1.6vw, 1.22rem); color: var(--text2); max-width: 62ch; }
.lead a { color: var(--head); }
.fine { font-size: .9rem; color: var(--text2); }
.src { font: 500 .75rem/1.6 var(--f-mono); color: var(--text2); margin: 22px 0 0; }
.src a { color: var(--text2); }
.empty { color: var(--text2); font-family: var(--f-mono); font-size: .9rem; }
.hex { font: 500 .75rem/1 var(--f-mono); color: var(--text2); letter-spacing: .04em; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin: 28px 0 0; }
.stack { display: grid; gap: 16px; margin-top: 48px; }
.more { display: inline-flex; align-items: center; gap: 8px; font: 500 .8rem/1 var(--f-mono); color: var(--c); margin-top: auto; padding-top: 16px; }
.more .i { transition: transform .2s; }
a:hover > .more .i, a:hover .more .i { transform: translateX(4px); }
.disclaimer { display: flex; gap: 10px; align-items: flex-start; font-size: .88rem; color: var(--text2); border-radius: var(--r); padding: 14px 16px; margin: 40px 0 0; }
.disclaimer .i { margin-top: .25em; color: var(--text2); }

.chip, .tag { border: 0; display: inline-flex; align-items: center; gap: 6px; font: 500 .75rem/1 var(--f-mono); padding: 6px 9px; border-radius: 5px; color: var(--text2); background: var(--surf); white-space: nowrap; text-decoration: none; }
.chip { background: var(--surf2); }
.tag { color: var(--c); background: color-mix(in srgb, var(--c) 14%, transparent); }
.chip-link, .chip-btn { color: var(--text); transition: color .15s, background .15s; }
.chip-link:hover, .chip-btn:hover { background: rgba(255, 255, 255, .13); color: #fff; }
.chip-btn { padding: 9px 13px; font-size: .8rem; }
.chip-btn.is-on { background: var(--volt); color: var(--volt-ink); }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; font: 700 1rem/1 var(--f-head); letter-spacing: .005em; padding: 16px 22px; border-radius: var(--r); border: 1px solid transparent; text-decoration: none; transition: transform .15s, box-shadow .2s, background .2s, border-color .2s, color .2s; white-space: nowrap; }
.btn:active { transform: translateY(1px); }
.btn-volt { background: var(--volt); color: var(--volt-ink); box-shadow: 0 8px 40px -14px rgba(255, 216, 74, .7); }
.btn-volt:hover { background: #ffe27a; color: var(--volt-ink); box-shadow: var(--glow); }
.btn-ghost { background: rgba(255, 255, 255, .08); color: var(--head); }
.btn-ghost:hover { background: rgba(255, 255, 255, .15); color: #fff; }
.btn-light { background: #fff; color: #000; }
.btn-light:hover { background: var(--volt); color: var(--volt-ink); }
.btn-sm { padding: 11px 15px; font-size: .9rem; border-radius: 8px; }
.btn[disabled] { opacity: .6; cursor: wait; }
.linkbtn { background: none; border: 0; padding: 0; color: var(--text2); display: inline-flex; align-items: center; gap: 6px; text-decoration: underline; text-underline-offset: 3px; }
.linkbtn:hover { color: var(--acc); }

/* ------------------------------------------------------------------ header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(0, 0, 0, .72); backdrop-filter: saturate(160%) blur(14px); -webkit-backdrop-filter: saturate(160%) blur(14px); transition: background .2s; }
.site-header.is-stuck { background: rgba(0, 0, 0, .86); }
/* widths as on nerdy.money: content 80% of the screen between 1200 and 1680px, header a bit wider */
/* three columns: the nav sits in the true middle while both sides have room, and moves over only as far as it must */
.bar { width: min(calc(var(--wrap) + 80px), 100% - 2 * var(--gutter)); margin-inline: auto; height: var(--bar-h); display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 28px; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--head); flex: none; grid-column: 1; justify-self: start; }
/* the face rocks gently, as on the boat it was cut out of; the wordmark is stacked like on nerdy.money */
.logo-face { width: 40px; height: 40px; flex: none; border-radius: 50%; overflow: hidden; background: var(--volt); transition: background .25s; }
.logo:hover .logo-face { background: var(--teal); }
.logo-face img { display: block; width: 100%; height: 100%; transform-origin: 50% 100%; animation: logo-ride 5s ease-in-out infinite; transition: transform .35s cubic-bezier(.3, 1.6, .5, 1); }
.logo:hover .logo-face img { animation: none; transform: scale(1.12) rotate(-7deg); }
@keyframes logo-ride { 0%, 100% { transform: rotate(-3deg); } 50% { transform: rotate(3deg); } }
@keyframes blink { 50% { opacity: 0; } }
.logo-name { display: grid; justify-items: center; gap: 3px; line-height: 1; }
.logo-name b { font: 800 1.42rem/.9 var(--f-head); letter-spacing: -.03em; color: var(--head); }
.logo-name small { font: 600 .56rem/1 var(--f-head); letter-spacing: .36em; margin-right: -.36em; text-transform: uppercase; color: var(--text2); }
.mainnav { display: flex; align-items: center; gap: 2px; grid-column: 2; }
.navgroup { position: relative; }
.navlink { white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; padding: 10px 13px; border-radius: 8px; font: 500 .95rem/1 var(--f-body); color: var(--text); text-decoration: none; transition: background .15s, color .15s; }
.navlink:hover, .navlink[aria-expanded="true"] { background: rgba(255, 255, 255, .07); color: #fff; }
.navlink.is-current { color: var(--acc); }
.chev { width: .9em; height: .9em; transition: transform .2s; }
[aria-expanded="true"] > .chev, details[open] > summary .chev { transform: rotate(180deg); }
.menu { position: absolute; top: calc(100% + 10px); left: -8px; width: 330px; background: #000; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1), 0 30px 80px -20px #000; border-radius: var(--r-l); padding: 8px; animation: pop .16s ease-out; }
.menu::before { content: ""; position: absolute; inset: -12px 0 auto; height: 12px; }
@keyframes pop { from { opacity: 0; transform: translateY(-6px); } }
.menu ul, .mobnav ul { list-style: none; margin: 0; padding: 0; }
.menu a { display: block; padding: 10px 12px; border-radius: 8px; text-decoration: none; color: var(--head); }
.menu a:hover, .menu a[aria-current] { background: var(--surf2); }
.menu b { display: block; font: 700 .98rem/1.3 var(--f-head); }
.menu small { display: block; color: var(--text2); font-size: .82rem; line-height: 1.4; }
.bar-actions { display: flex; align-items: center; gap: 10px; grid-column: 3; justify-self: end; }
.searchbtn { display: inline-flex; align-items: center; gap: 8px; background: var(--surf); border-radius: 8px; padding: 8px 10px; color: var(--text2); font-size: .88rem; }
.searchbtn:hover { background: var(--surf2); color: #fff; }
.bar-cta { white-space: nowrap; display: inline-flex; align-items: center; gap: 10px; background: var(--volt); color: var(--volt-ink); font: 700 .92rem/1 var(--f-head); padding: 7px 7px 7px 14px; border-radius: 9px; text-decoration: none; transition: box-shadow .2s, background .2s; }
.bar-cta:hover { background: #ffe27a; color: var(--volt-ink); box-shadow: var(--glow); }
.bar-cta .chip { background: #151000; color: var(--volt); }
.langsw { background: var(--surf); display: inline-flex; border-radius: 8px; overflow: hidden; font: 500 .75rem/1 var(--f-mono); flex: none; }
.langsw a, .langsw span { padding: 9px 9px; color: var(--text2); text-decoration: none; }
.langsw a:hover { color: var(--acc); }
.langsw .is-on { background: var(--surf2); color: var(--head); }
.mobrow { display: flex; justify-content: center; padding-top: 8px; }
.menubtn { display: none; background: var(--surf); border-radius: 8px; padding: 9px; color: #fff; }
.menubtn .i { width: 1.3em; height: 1.3em; }
.progress { height: 2px; background: transparent; }
.progress i { display: block; height: 100%; background: var(--acc); transform: scaleX(0); transform-origin: left; }
.mob { position: fixed; inset: 0; z-index: 90; background: #000; overflow: auto; padding: 0 var(--gutter) 32px; display: flex; flex-direction: column; }
.mobhead { height: var(--bar-h); display: flex; align-items: center; justify-content: space-between; flex: none; }
.mob .menubtn { display: inline-flex; }
.mobsearch { display: flex; align-items: center; gap: 10px; width: 100%; background: var(--surf); border-radius: var(--r); padding: 14px; color: var(--text2); margin: 8px 0 12px; }
.mobnav summary, .mobtop { display: flex; align-items: center; gap: 12px; padding: 18px 2px; font: 800 1.5rem/1 var(--f-head); color: #fff; text-decoration: none; list-style: none; cursor: pointer; }
.mobnav summary::-webkit-details-marker { display: none; }
.mobnav summary .chev { margin-left: auto; }
.mobnav li a { display: block; padding: 12px 2px 12px 46px; text-decoration: none; color: #fff; }
.mobnav li b { display: block; font: 700 1.05rem/1.3 var(--f-head); }
.mobnav li small { color: var(--text2); font-size: .85rem; }
.mobfoot { display: grid; gap: 10px; margin-top: 24px; }

/* ------------------------------------------------------------------ heroes */
.grid-bg { position: absolute; inset: 0; pointer-events: none; -webkit-mask-image: linear-gradient(#000 55%, transparent); mask-image: linear-gradient(#000 55%, transparent); }
.grid-bg canvas { display: block; width: 100%; height: 100%; }
.glow { position: absolute; pointer-events: none; width: 760px; height: 760px; right: -200px; top: -320px; background: radial-gradient(closest-side, rgba(77, 141, 255, .26), rgba(167, 139, 250, .12) 55%, transparent 72%); filter: blur(20px); }
.hero, .phero { position: relative; overflow: hidden; }
.hero { padding: clamp(40px, 6vw, 84px) 0 clamp(56px, 7vw, 100px); }
/* on a desktop the home hero fills the first screen, content in the middle, so the next section starts below the fold */
@media (min-width: 961px) and (min-height: 640px) {
  .hero { min-height: min(100svh - var(--bar-h), 1200px); display: grid; align-items: center; padding-bottom: clamp(72px, 9vh, 130px); }
}
.hero-in { position: relative; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.hero h1 { font-size: clamp(2.7rem, 6.6vw, 5.4rem); margin-bottom: .15em; }
.ast { color: var(--volt); font-size: .6em; vertical-align: .55em; margin-left: .06em; display: inline-block; animation: spin 14s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.foot { font: 500 .82rem/1.4 var(--f-mono); color: var(--text2); margin: 0 0 26px; }
.iwant { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 30px 0 0; font-size: .9rem; color: var(--text2); }
.phero { padding: clamp(28px, 4vw, 56px) 0 clamp(36px, 5vw, 64px); }
.phero-in { position: relative; }
.phero-in.has-aside { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.phero h1 { font-size: clamp(2.2rem, 5.2vw, 4rem); }
.phero-article h1 { font-size: clamp(2rem, 4.4vw, 3.3rem); max-width: 22ch; }
.phero-aside { display: flex; justify-content: center; }
.phero-404 { padding-block: clamp(60px, 10vw, 140px); }
.phero .tag, .phero .kicker { --c: var(--c); color: var(--c); }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; padding: 0; margin: 0 0 22px; font: 500 .82rem/1.4 var(--f-mono); color: var(--text2); text-transform: lowercase; }
.crumbs li + li::before { content: "/"; color: var(--text2); }
.crumbs a { color: var(--text2); text-decoration: none; }
.crumbs a:hover { color: var(--acc); }
.crumbs [aria-current] { color: var(--head); display: inline-block; max-width: 32ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: bottom; }
/* the prompt waits after the current page */
.crumbs li:last-child::after { content: ""; display: inline-block; width: .55em; height: 1.05em; margin-left: .4em; vertical-align: -.18em; border-radius: 1px; background: var(--acc); animation: blink 1.1s steps(1) infinite; }

/* ------------------------------------------------------------------ terminal cards */
.termcard { position: relative; width: 100%; background: rgba(0, 0, 0, .6); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border-radius: var(--r-l); overflow: hidden; box-shadow: 0 40px 100px -40px rgba(77, 141, 255, .4), var(--card-sh); }
.term-bar { display: flex; align-items: center; gap: 12px; padding: 11px 14px; background: rgba(255, 255, 255, .03); font: 500 .76rem/1 var(--f-mono); color: var(--text2); }
.term-bar .linkbtn { margin-left: auto; text-decoration: none; }
.dots { display: inline-flex; gap: 6px; }
.dots i { width: 10px; height: 10px; border-radius: 50%; background: #3a3f48; }
.dots i:nth-child(1) { background: #ff5f57; } .dots i:nth-child(2) { background: #febc2e; } .dots i:nth-child(3) { background: #28c840; }
.term-body { margin: 0; padding: 18px; font: 500 .84rem/1.9 var(--f-mono); color: var(--text); white-space: pre-wrap; min-height: 200px; }
.tl { display: block; }
.tl.is-wait { visibility: hidden; }
.tl-cmd { color: #fff; } .tl-ok, .term-out .ok { color: var(--acc); } .tl-bad, .term-out .bad { color: var(--warn); } .tl-dim, .term-out .dim { color: var(--text2); }

/* ------------------------------------------------------------------ section heads, stats, cards */
.shead { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 32px; margin: 0 0 36px; }
.shead p:last-child { color: var(--text2); margin: 0; max-width: 60ch; }
.shead h2 { margin-bottom: .3em; max-width: 22ch; }
* + .shead { margin-top: 72px; }
.wrap > .shead:first-child, .wrap > .kicker:first-child { margin-top: 0; }
[data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity .5s ease, transform .5s ease; }
html:not(.js) [data-reveal], [data-reveal].is-in { opacity: 1; transform: none; }
/* safety net: if site.js never runs, nothing gets the class is-in, and the content shows by itself after three seconds */
html.js:not(:has(.is-in)) [data-reveal] { animation: reveal-safe .5s 3s forwards; }
@keyframes reveal-safe { to { opacity: 1; transform: none; } }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.stat { background: var(--surf); box-shadow: var(--card-sh); border-radius: var(--r-l); padding: 26px 24px; }
.stat-v { display: block; font: 800 clamp(2.2rem, 4vw, 3.1rem)/1 var(--f-head); color: var(--head); letter-spacing: -.03em; }
.stat:first-child .stat-v { color: var(--teal); }
.stat-l { display: block; font: 500 .76rem/1.4 var(--f-mono); color: var(--acc); margin: 10px 0 8px; }
.stat p { margin: 0; font-size: .92rem; color: var(--text2); }

.topics, .trio, .talks, .steps { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.topic, .tri, .talk, .step, .tcard, .pcard-link { position: relative; display: flex; flex-direction: column; background: var(--surf); border-radius: var(--r-l); padding: 24px; text-decoration: none; color: var(--text2); transition: border-color .2s, transform .2s, background .2s, box-shadow .2s; min-height: 100%; }
a.topic:hover, a.tri:hover, .tcard:hover, .pcard-link:hover { transform: translateY(-3px); background: var(--surf2); color: var(--text2); box-shadow: 0 24px 60px -30px color-mix(in srgb, var(--c) 60%, transparent); }
.topic b, .tri b, .talk b, .step b, .tcard b { font: 800 1.35rem/1.15 var(--f-head); color: var(--head); letter-spacing: -.015em; margin: 0 0 8px; }
.topic-ic, .tri-ic, .tcard-ic, .callout-ic { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 9px; background: color-mix(in srgb, var(--c) 18%, transparent); color: var(--c); margin: 18px 0 18px; flex: none; }
.topic-ic .i, .tri-ic .i, .tcard-ic .i, .callout-ic .i { width: 22px; height: 22px; }
.topic-t, .tcard-t { font-size: .95rem; line-height: 1.55; }
.tri .chip, .talk .chip { align-self: flex-start; margin: 0 0 14px; }
.tri-ic { margin-top: 0; }
.tri p, .talk p, .step p { font-size: .95rem; margin: 0; }
.talk .chip { margin: 16px 0 0; }
.step .hex { color: var(--c); margin-bottom: 18px; }

.tgrid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.tgrid-big { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.tcard { padding: 20px; }
.tcard-ic { margin: 0 0 16px; width: 40px; height: 40px; }
.tcard-cmd { font: 500 .75rem/1.3 var(--f-mono); color: var(--text2); margin: 0 0 8px; }
.tcard b { font-size: 1.18rem; }

.pgrid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.pcard { display: flex; }
.pcard-link { width: 100%; }
.pcard-link::before { content: ""; position: absolute; left: 0; top: 22px; bottom: 22px; width: 2px; background: var(--c); border-radius: 2px; opacity: .8; }
.pcard-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font: 500 .75rem/1 var(--f-mono); color: var(--text2); margin: 0 0 16px; }
.pcard h3 { font-size: 1.32rem; line-height: 1.18; margin-bottom: 10px; }
.pcard p:not(.pcard-meta) { font-size: .94rem; margin: 0; }
.pcard-big { grid-column: span 2; }
.pcard-big h3 { font-size: clamp(1.6rem, 2.6vw, 2.1rem); }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 28px; }

.planb-teaser, .rules, .pro, .method { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.ticks { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 10px; }
.ticks li { display: flex; gap: 10px; align-items: flex-start; color: var(--text); }
.ticks .i { color: var(--acc); margin-top: .3em; }
.ticks-plain li { color: var(--text2); font-size: .96rem; }
.xp-mini { font: 500 .8rem/1 var(--f-mono); color: var(--acc); }

.levels { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; position: relative; }
.levels a { display: flex; align-items: center; gap: 16px; padding: 16px 18px; background: var(--surf); border-radius: var(--r); text-decoration: none; color: var(--text2); transition: border-color .2s, background .2s, transform .2s; }
.levels a:hover { background: var(--surf2); transform: translateX(4px); color: var(--text2); }
.lvl { display: grid; place-items: center; flex: none; width: 38px; height: 38px; border-radius: 8px; font: 500 .9rem/1 var(--f-mono); color: var(--head); background: var(--surf2); }
.lvl-body { display: grid; gap: 4px; min-width: 0; }
.lvl-t { font: 700 1.08rem/1.25 var(--f-head); color: var(--head); }
.lvl-d { font-size: .9rem; line-height: 1.45; }
.lvl-meta { font: 500 .75rem/1.4 var(--f-mono); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.lvl-xp { margin-left: auto; font: 500 .75rem/1 var(--f-mono); color: var(--acc); white-space: nowrap; }
.levels .is-done .lvl { background: var(--teal); color: #00201b; }
.levels .is-done .lvl-xp::before { content: "✓ "; }
.levels-mini a { padding: 11px 14px; }
.levels-mini .lvl { width: 30px; height: 30px; font-size: .8rem; }
.levels-mini .lvl-t { font-size: .98rem; }

.rulelist { list-style: none; padding: 0; margin: 0; display: grid; gap: 0; }
.rulelist li { display: flex; gap: 20px; padding: 18px 0; }
.rulelist .hex { color: var(--acc); padding-top: 8px; }
.rulelist b { font: 800 1.4rem/1.2 var(--f-head); color: var(--head); display: block; margin-bottom: 4px; }
.rulelist p { margin: 0; color: var(--text2); }

.aboutt { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(24px, 5vw, 64px); align-items: center; }
.avatar { width: 220px; height: 220px; object-fit: cover; border-radius: var(--r-l); filter: grayscale(1) contrast(1.08); transition: filter .4s; box-shadow: 0 30px 80px -30px rgba(77, 141, 255, .7); }
.avatar:hover { filter: none; }
/* interactive blocks in articles and lessons */
.guess, .explorer { background: var(--surf); box-shadow: var(--card-sh); border-radius: var(--r-l); padding: 22px 24px; margin: 1.8em 0; }
.guess { background: linear-gradient(135deg, rgba(167, 139, 250, .14), rgba(77, 141, 255, .08)), var(--surf); }
.guess .block-k { color: var(--violet); }
.guess-q { font: 700 1.2rem/1.35 var(--f-head); color: var(--head); margin: 0 0 16px; }
.guess-in { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px; align-items: center; }
.guess-val { font: 800 1.7rem/1 var(--f-head); color: var(--teal); min-width: 4.5ch; text-align: right; font-variant-numeric: tabular-nums; }
.guess .actions { margin-top: 16px; }
.guess-bars { display: grid; gap: 10px; margin: 20px 0 16px; }
.guess-bars div { display: grid; grid-template-columns: 70px minmax(0, 1fr); gap: 12px; align-items: center; font: 500 .75rem/1 var(--f-mono); color: var(--text2); padding-right: 5.5rem; /* room for the value behind a full bar */ }
.guess-bars i { display: block; height: 26px; width: 0; border-radius: 6px; background: var(--blue); transition: width .9s cubic-bezier(.2, .8, .2, 1); position: relative; }
.guess-bars div:last-child i { background: var(--teal); transition-delay: .25s; }
.guess-bars i::after { content: attr(data-v); position: absolute; left: calc(100% + 8px); top: 50%; transform: translateY(-50%); color: var(--head); white-space: nowrap; }
.guess-verdict { font: 800 1.3rem/1.3 var(--f-head); color: var(--head); margin: 0 0 8px; }
.guess-why { color: var(--text2); font-size: .98rem; margin: 0; }
.explorer .block-k { color: var(--teal); }
.explorer-out { display: grid; gap: 16px; margin: 20px 0 14px; }
.ex-row { display: grid; grid-template-columns: 9.5rem minmax(0, 1fr); gap: 4px 18px; align-items: baseline; }
.ex-row b { font: 800 1.6rem/1.1 var(--f-head); color: var(--head); grid-row: span 3; font-variant-numeric: tabular-nums; }
.ex-row span { font-size: .92rem; color: var(--text); line-height: 1.4; }
.ex-row small { font: 500 .75rem/1.4 var(--f-mono); color: var(--text2); }
.ex-bar { display: block; height: 8px; border-radius: 4px; background: var(--surf2); overflow: hidden; }
.ex-bar i { display: block; height: 100%; width: 0; border-radius: 4px; background: var(--s); transition: width .8s cubic-bezier(.2, .8, .2, 1); }
.ex-say { margin: 4px 0 0; padding: 14px 16px; border-left: 2px solid var(--teal); background: var(--teal-wash); border-radius: 0 var(--r) var(--r) 0; color: #dff5f1; font-size: .96rem; }
.inline-tool { margin: 2em 0; }
.prose .inline-tool a.btn { text-decoration: none; }
.chart svg.is-first .line:not(.is-dash) { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw 1.1s ease-out forwards; }
.chart svg.is-first .area { animation: fadein 1.2s ease-out both; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fadein { from { opacity: 0; } }
.xpchip { display: inline-flex; align-items: center; gap: 6px; padding: 8px 10px; border-radius: 8px; background: rgba(45, 212, 191, .16); color: var(--teal); font: 500 .76rem/1 var(--f-mono); text-decoration: none; white-space: nowrap; }
.xpchip:hover { background: rgba(45, 212, 191, .28); color: #fff; }

/* manifesto on the home page */
.manifesto { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.manifesto blockquote { margin: 26px 0 0; padding: 0 0 0 20px; border-left: 3px solid var(--teal); font: 600 1.2rem/1.45 var(--f-head); color: var(--head); }
.manifesto cite { display: block; margin-top: 8px; font: 500 .76rem/1.4 var(--f-mono); color: var(--text2); font-style: normal; }
.beliefs { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.beliefs li { background: var(--surf); box-shadow: var(--card-sh); border-radius: var(--r-l); padding: 20px 22px; }
.beliefs li:nth-child(1) { --c: var(--blue); } .beliefs li:nth-child(2) { --c: var(--teal); } .beliefs li:nth-child(3) { --c: var(--violet); }
.beliefs .hex { color: var(--c); }
.beliefs b { display: block; font: 800 1.25rem/1.2 var(--f-head); color: var(--head); margin: 8px 0 4px; }
.beliefs p { margin: 0; color: var(--text2); font-size: .95rem; }
.hub-photo { margin: 0; width: min(340px, 78vw); }
.post-photo { margin: 0; justify-self: center; }
.phero-article .has-aside { grid-template-columns: minmax(0, 1.4fr) minmax(0, .6fr); }
/* never crop a person: the photo keeps its shape and only gets smaller */
.post-photo .photo { width: auto; max-width: 100%; max-height: min(560px, 70vh); }
.livecalc .live-in { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 28px; margin: 6px 0 20px; }
.livecalc .field label { font-family: var(--f-body); font-size: .92rem; }
.livecalc td, .livecalc tbody th { font-family: var(--f-mono); font-size: .86rem; }
.live-say { margin: 0 0 10px; color: var(--head); font-weight: 500; }
.live-say:empty { display: none; }
.post-photo figcaption, .hub-photo figcaption { font: 500 .75rem/1.5 var(--f-mono); color: var(--text2); margin-top: 12px; }
/* photos of Markus: colour, soft corners, a glow instead of a frame */
.photo { display: block; width: 100%; height: auto; border-radius: var(--r-l); box-shadow: 0 40px 100px -40px rgba(77, 141, 255, .65), 0 0 0 1px rgba(255, 255, 255, .04); }
.photo-hero { width: min(380px, 80vw); transform: rotate(2deg); transition: transform .4s; }
.photo-hero:hover { transform: none; }
.photo-tall { width: min(340px, 70vw); transform: rotate(-2deg); transition: transform .4s; }
.photo-tall:hover { transform: none; }
.photos { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: end; margin: 1.8em 0 2.4em; }
.photos figure { margin: 0; }
.photos figcaption { font: 500 .76rem/1.5 var(--f-mono); color: var(--text2); margin-top: 10px; }
.avatar-sm { width: 72px; height: 72px; border-radius: 10px; box-shadow: none; }

/* roadmap (start here) */
.roadmap { list-style: none; margin: 0; padding: 0; position: relative; }
.roadmap::before { content: ""; position: absolute; left: 21px; top: 10px; bottom: 10px; width: 1px; background: linear-gradient(var(--acc), var(--line2)); }
.roadmap > li { position: relative; display: flex; gap: 24px; padding: 0 0 44px; }
.road-n { position: relative; z-index: 1; flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 10px; background: var(--grad); color: #00142e; font: 800 1.2rem/1 var(--f-head); }
.roadmap h2 { font-size: 1.7rem; margin: 6px 0 6px; }
.roadmap p { color: var(--text2); margin: 0 0 14px; }
.road-links { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.road-links a { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: var(--r); background: var(--surf); color: var(--head); text-decoration: none; font-weight: 500; font-size: .96rem; transition: background .2s, transform .2s; }
.road-links a:hover { transform: translateX(4px); background: var(--surf2); }
.road-links .i { margin-left: auto; color: var(--acc); }
.road-links .tag { min-width: 62px; justify-content: center; }

/* plan b */
.xpcard, .procard { width: 100%; background: var(--surf); border-radius: var(--r-l); padding: 24px; }
.xp-rank { font: 800 2rem/1.1 var(--f-head); color: var(--head); margin: 0 0 16px; }
.xpbar { height: 10px; border-radius: 5px; background: var(--surf2); overflow: hidden; }
.xpbar i { display: block; height: 100%; background: var(--acc); transform: scaleX(0); transform-origin: left; transition: transform .8s cubic-bezier(.2, .8, .2, 1); }
.xp-num { font: 500 .8rem/1.4 var(--f-mono); color: var(--text2); margin: 12px 0 8px; }
.xp-num b { color: var(--acc); }
.procard > b { display: block; font: 800 1.4rem/1.2 var(--f-head); color: var(--head); margin-bottom: 16px; }
.pro h2 { margin-bottom: .4em; }

/* faq */
.faq { display: grid; gap: 8px; }
.faq details { background: var(--surf); box-shadow: var(--card-sh); border-radius: var(--r); padding: 0 20px; }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px 0; font: 700 1.15rem/1.3 var(--f-head); color: var(--head); cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--acc); }
.faq .plus { color: var(--acc); transition: transform .35s cubic-bezier(.3, 1.6, .5, 1); }
.faq details[open] .plus { transform: rotate(45deg); }
.faq details > div { padding: 0 0 20px; color: var(--text2); max-width: 70ch; }

/* podcast player mock */
.player { width: min(380px, 100%); background: var(--surf); border-radius: var(--r-l); padding: 22px; }
.player-top { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.player-ic { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 10px; background: var(--volt); color: var(--volt-ink); }
.player-top b { display: block; font: 800 1.2rem/1.2 var(--f-head); color: var(--head); }
.player-top span span, .player-top div span { font: 500 .76rem/1 var(--f-mono); color: var(--text2); }
.wave { display: flex; align-items: center; gap: 3px; height: 64px; }
.wave i { flex: 1; background: var(--acc); border-radius: 2px; opacity: .85; animation: wave 1.6s ease-in-out infinite; transform-origin: center; }
.wave .w0 { height: 30%; } .wave .w1 { height: 70%; animation-delay: -.3s; } .wave .w2 { height: 45%; animation-delay: -.6s; } .wave .w3 { height: 95%; animation-delay: -.9s; } .wave .w4 { height: 55%; animation-delay: -1.2s; }
@keyframes wave { 50% { transform: scaleY(.35); } }
.player-bar { height: 4px; background: var(--surf2); border-radius: 2px; margin-top: 18px; }
.player-bar i { display: block; width: 8%; height: 100%; background: var(--text2); border-radius: 2px; }

/* glossary */
.glsearch { display: flex; align-items: center; gap: 10px; background: var(--surf); border-radius: var(--r); padding: 0 14px; color: var(--text2); }
.glsearch:focus-within { box-shadow: 0 0 0 3px rgba(77, 141, 255, .35); }
.glsearch input:focus { background: none; box-shadow: none; }
.glsearch input { flex: 1; background: none; border: 0; outline: 0; padding: 15px 0; }
.letters { display: flex; flex-wrap: wrap; gap: 6px; margin: 18px 0 36px; }
.letters a { display: grid; place-items: center; width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 7px; font: 500 .82rem/1 var(--f-mono); text-decoration: none; color: var(--text); }
.letters a:hover { border-color: var(--acc); color: var(--acc); }
.gl { margin: 0; }
.gl-group { position: relative; padding: 0 0 8px 64px; }
.gl-letter { position: absolute; left: 0; top: 22px; font: 800 2.2rem/1 var(--f-head); color: var(--acc); margin: 0; }
.gl-item { padding: 22px 0; }
.gl-item:target dt { color: var(--acc); }
.gl dt { font: 800 1.25rem/1.25 var(--f-head); color: var(--head); margin-bottom: 6px; }
.gl dd { margin: 0; color: var(--text2); }
.see { display: block; font: 500 .78rem/1.5 var(--f-mono); margin-top: 10px; }

/* tables */
.table-wrap { overflow-x: auto; border-radius: var(--r); margin: 0 0 1.4em; }
/* a table that doesn't fit fades out on the side where more is waiting, and says so underneath */
.table-wrap.is-scroll { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 56px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 56px), transparent); margin-bottom: .5em; }
.table-wrap.is-scroll.at-end { -webkit-mask-image: linear-gradient(270deg, #000 calc(100% - 56px), transparent); mask-image: linear-gradient(270deg, #000 calc(100% - 56px), transparent); }
.table-hint { display: flex; align-items: center; justify-content: flex-end; gap: 8px; margin: 0 0 1.4em; font: 500 .75rem/1 var(--f-mono); color: var(--teal); }
.table-hint .i { width: 14px; height: 14px; animation: nudge 1.6s ease-in-out infinite; }
@keyframes nudge { 50% { transform: translateX(5px); } }
table { width: 100%; border-collapse: collapse; font-size: .92rem; }
th, td { padding: 12px 14px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { font: 500 .75rem/1.4 var(--f-mono); color: var(--acc); text-transform: lowercase; letter-spacing: .04em; background: var(--surf); vertical-align: bottom; min-width: 6.5rem; text-wrap: balance; }
tbody th { color: var(--head); font-weight: 600; }
tbody th small { display: block; font-weight: 400; color: var(--text2); font-size: .8rem; }
tbody tr:last-child > * { border-bottom: 0; }
td { font-variant-numeric: tabular-nums; color: var(--text); }
td small { color: var(--text2); }

/* ------------------------------------------------------------------ forms */
.hp { position: absolute; left: -9999px; }
input:not([type="range"], [type="checkbox"], [type="radio"]), textarea { width: 100%; border: 0; background: var(--surf2); border-radius: var(--r); padding: 14px 14px; color: #fff; outline: 0; transition: border-color .15s, box-shadow .15s; }
input:focus, textarea:focus { background: rgba(255, 255, 255, .11); box-shadow: 0 0 0 3px rgba(77, 141, 255, .35); }
::placeholder { color: #8a919e; opacity: 1; }
.waitlist { display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: start; }
.waitlist > p { grid-column: 1 / -1; margin: 0; }
.form-note { font-size: .82rem; color: var(--text2); }
.form-note a { color: var(--text2); }
.form-status { font: 500 .85rem/1.5 var(--f-mono); min-height: 0; }
.form-status.is-ok { color: var(--acc); } .form-status.is-bad { color: var(--warn); }
.form { display: grid; gap: 16px; }
.frow { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.f label { display: block; font: 500 .78rem/1.4 var(--f-mono); color: var(--text2); margin-bottom: 7px; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: .88rem; color: var(--text2); }
.check input { width: 20px; height: 20px; accent-color: var(--volt); margin-top: 2px; flex: none; }
.form .btn { justify-self: start; }

/* ------------------------------------------------------------------ calculators */
.calc { backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 0; background: var(--surf); border-radius: var(--r-l); overflow: hidden; margin-top: clamp(-40px, -3vw, -20px); position: relative; }
/* a hairline of the brand gradient along the top edge */
.calc::before, .termcard::before { content: ""; position: absolute; inset: 0 0 auto; height: 1px; background: var(--grad); opacity: .85; pointer-events: none; z-index: 1; }
.calc-mini::before { display: none; }
.calc-in { padding: clamp(18px, 3vw, 32px); display: grid; gap: 20px; align-content: start; margin: 0; }
.calc-out { padding: clamp(18px, 3vw, 32px); background: transparent; display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; background: var(--surf2); border-radius: var(--r); }
.seg label { position: relative; display: grid; }
.seg input { position: absolute; opacity: 0; inset: 0; }
.seg span { display: grid; place-items: center; text-align: center; padding: 10px 8px; border-radius: 7px; font: 700 .9rem/1.2 var(--f-head); color: var(--text2); cursor: pointer; }
.seg input:checked + span { background: var(--volt); color: var(--volt-ink); }
.seg input:focus-visible + span { outline: 2px solid var(--volt); outline-offset: 2px; }
.field label { display: block; font-weight: 500; font-size: .92rem; color: var(--text); margin-bottom: 8px; }
.field-row { display: grid; grid-template-columns: minmax(0, 1fr) 8.75rem; gap: 14px; align-items: center; }
.numwrap { position: relative; display: block; }
.numwrap input { background: rgba(255, 255, 255, .07); padding: 10px calc(2.3rem + 22px) 10px 12px; font: 500 .95rem/1.2 var(--f-mono); text-align: right; border-radius: 8px; -moz-appearance: textfield; appearance: textfield; }
.numwrap input::-webkit-outer-spin-button, .numwrap input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.unit { position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font: 500 .75rem/1 var(--f-mono); color: var(--text2); pointer-events: none; }
.seg-scenario span { font-size: .84rem; }
.seg-scenario input[value="stress"]:checked + span { background: var(--warn); color: #1a0d00; }
.field-select select { width: 100%; appearance: none; -webkit-appearance: none; border: 0; border-radius: 8px; padding: 12px 40px 12px 14px; color: #fff; background: rgba(255, 255, 255, .07) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23949ba8' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center / 18px; font: 500 .95rem/1.2 var(--f-body); }
.field-select select:focus { outline: 0; box-shadow: 0 0 0 3px rgba(77, 141, 255, .35); }
.field-select option { background: #111; color: #fff; }
/* country picker: search field with suggestions */
.field-select { position: relative; z-index: 1; }
.field-select:focus-within { z-index: 40; }
.combo { position: relative; }
.combo input { width: 100%; border: 0; border-radius: 8px; padding: 12px 40px 12px 14px; color: #fff; font: 500 .95rem/1.3 var(--f-body); background: rgba(255, 255, 255, .07) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239aa3b5' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") no-repeat right 12px center / 16px; }
.combo input:focus { outline: 0; box-shadow: 0 0 0 3px rgba(77, 141, 255, .35); }
.combo-list { position: absolute; z-index: 30; left: -8px; right: -8px; top: calc(100% + 6px); margin: 0; padding: 6px; list-style: none; max-height: 264px; overflow-y: auto; overscroll-behavior: contain; border-radius: 10px; background: #14171d; box-shadow: 0 24px 60px -12px rgba(0, 0, 0, .9), 0 0 0 1px rgba(255, 255, 255, .08); }
.combo-list li { padding: 10px 12px; border-radius: 7px; font-size: .95rem; color: var(--text); cursor: pointer; }
.combo-list li[aria-selected="true"], .combo-list li[data-v]:hover { background: rgba(45, 212, 191, .16); color: #fff; }
.combo-list li.is-on { color: var(--teal); }
.combo-list .combo-none { color: var(--text2); cursor: default; font-size: .88rem; }
.more-fields { background: var(--surf); border-radius: var(--r); padding: 0 14px; }
.more-fields summary { display: flex; align-items: center; gap: 10px; padding: 13px 0; cursor: pointer; font-weight: 500; font-size: .92rem; color: var(--text); list-style: none; }
.more-fields summary::-webkit-details-marker { display: none; }
.more-fields .plus { color: var(--acc); transition: transform .35s cubic-bezier(.3, 1.6, .5, 1); }
.more-fields[open] .plus { transform: rotate(45deg); }
.more-fields .field { padding-bottom: 16px; }
.hint { font-size: .8rem; color: var(--text2); margin: 7px 0 0; line-height: 1.45; }
input[type="range"] { -webkit-appearance: none; appearance: none; width: 100%; height: 26px; background: transparent; cursor: pointer; --p: 50%; margin: 0; }
input[type="range"]::-webkit-slider-runnable-track { height: 4px; border-radius: 2px; background: linear-gradient(90deg, var(--blue), var(--teal) var(--p), var(--line2) var(--p)); }
input[type="range"]::-moz-range-track { height: 4px; border-radius: 2px; background: var(--line2); }
input[type="range"]::-moz-range-progress { height: 4px; border-radius: 2px; background: linear-gradient(90deg, var(--blue), var(--teal)); }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; margin-top: -8px; border-radius: 6px; background: var(--teal); border: 3px solid #000; box-shadow: 0 0 0 1px var(--teal); transition: transform .12s; }
input[type="range"]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 6px; background: var(--teal); border: 3px solid #000; box-shadow: 0 0 0 1px var(--teal); }
input[type="range"]:hover::-webkit-slider-thumb { transform: scale(1.15); }
input[type="range"]:focus::-webkit-slider-thumb, input[type="range"]:active::-webkit-slider-thumb { box-shadow: 0 0 0 1px var(--teal), 0 0 0 7px var(--teal-wash), 0 0 18px rgba(45, 212, 191, .55); }
input[type="range"]:focus::-moz-range-thumb, input[type="range"]:active::-moz-range-thumb { box-shadow: 0 0 0 1px var(--teal), 0 0 0 7px var(--teal-wash), 0 0 18px rgba(45, 212, 191, .55); }
.switch { display: flex !important; align-items: center; gap: 12px; cursor: pointer; margin: 0 !important; }
.switch input { position: absolute; opacity: 0; }
.switch-ui { width: 44px; height: 26px; border-radius: 8px; background: var(--line2); position: relative; transition: background .2s; flex: none; }
.switch-ui::after { content: ""; position: absolute; left: 3px; top: 3px; width: 20px; height: 20px; border-radius: 6px; background: #fff; transition: transform .2s; }
.switch input:checked + .switch-ui { background: var(--volt); }
.switch input:checked + .switch-ui::after { transform: translateX(18px); background: #000; }
.switch input:focus-visible + .switch-ui { outline: 2px solid var(--volt); outline-offset: 3px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; border-radius: var(--r); overflow: hidden; }
.kpis[data-n="4"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.kpis[data-n="5"] { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.kpis[data-n="5"] .kpi { grid-column: span 2; }
.kpis[data-n="5"] .kpi:nth-child(n+4) { grid-column: span 3; }
.kpis[data-n="3"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kpi { background: var(--surf); box-shadow: var(--card-sh); border-radius: var(--r); padding: 16px; display: grid; gap: 6px; align-content: start; min-width: 0; }
.kpi-l { font: 500 .75rem/1.35 var(--f-mono); color: var(--text2); text-transform: lowercase; }
.kpi-v { font: 800 clamp(1.5rem, 2.6vw, 2.05rem)/1 var(--f-head); color: var(--head); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.kpi-u { font-size: .76rem; line-height: 1.35; color: var(--text2); }
/* the headline result wears the blue-to-teal gradient; yellow stays with the buttons */
.t-volt .kpi-v { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; justify-self: start; padding-bottom: .12em; } .t-teal .kpi-v { color: var(--teal); } .t-warn .kpi-v { color: var(--warn); } .t-blue .kpi-v { color: var(--blue); }
.kpi-d { grid-column: 1 / -1; margin: 0; padding: 2px 4px; font: 500 .75rem/1.5 var(--f-mono); color: var(--text2); }
.say { margin: 0; padding: 14px 16px; border-left: 2px solid var(--acc); background: var(--acc-wash); border-radius: 0 var(--r) var(--r) 0; color: #dff5f1; font-size: .96rem; }
.calc-actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; }
.chart { position: relative; margin: 0; }
.chart svg { width: 100%; height: auto; overflow: visible; touch-action: pan-y; }
.chart .grid { stroke: var(--line); stroke-width: 1; }
.chart .ax { font: 500 11px var(--f-mono); fill: #7c8491; }
.chart .ax-y { text-anchor: end; } .chart .ax-x { text-anchor: middle; } .chart .ax-l { text-anchor: end; }
.chart .line { fill: none; stroke: var(--s); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.chart .line.is-dash { stroke-dasharray: 6 6; stroke-width: 2; }
.chart .area { fill: var(--s); opacity: .13; }
.chart .bar { fill: var(--s); }
.chart .cursor { stroke: #fff; stroke-width: 1; opacity: .35; }
.s-volt { --s: var(--volt); } .s-blue { --s: var(--blue); } .s-teal { --s: var(--teal); }
.chart figcaption { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 10px; }
.lg { display: inline-flex; align-items: center; gap: 8px; font: 500 .75rem/1.3 var(--f-mono); color: var(--text2); }
.lg::before { content: ""; width: 14px; height: 3px; border-radius: 2px; background: var(--s); }
.lg.is-dash::before { background: repeating-linear-gradient(90deg, var(--s) 0 4px, transparent 4px 7px); }
.chart-tip { position: absolute; top: 6px; width: 34%; min-width: 170px; background: rgba(0, 0, 0, .92); border-radius: 8px; padding: 10px 12px; display: grid; gap: 5px; pointer-events: none; font: 500 .75rem/1.3 var(--f-mono); }
.chart-tip b { color: #fff; font-weight: 500; }
.chart-tip i { font-style: normal; color: #fff; margin-left: auto; }
.chart-tip .lg { display: flex; }
.calc-mini { grid-template-columns: minmax(0, 1fr); margin: 0; border-radius: 0; box-shadow: none; background: transparent; }
.calc-mini .calc-in { padding: 20px 20px 6px; gap: 16px; }
.calc-mini .calc-out { padding: 14px 20px 20px; background: transparent; gap: 14px; }
.calc-mini .kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.calc-mini .kpi { padding: 12px; }
.calc-mini .kpi-v { font-size: clamp(1.2rem, 2vw, 1.55rem); }
.calc-mini .field-row { grid-template-columns: minmax(0, 1fr) 8.25rem; }
.calc-mini .say { font-size: .88rem; padding: 10px 12px; }
.calc-mini .btn { width: 100%; }
.method h2 { margin-bottom: .5em; }

/* ------------------------------------------------------------------ article */
.article-grid { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; padding-block: clamp(36px, 5vw, 64px) clamp(56px, 8vw, 100px); }
.article-grid > .prose:only-child { grid-column: 1 / -1; margin-inline: auto; }
.lesson > .wrap-article { padding-block: clamp(36px, 5vw, 64px) clamp(56px, 8vw, 100px); }
.lesson .prose { margin-inline: auto; }
.toc { position: sticky; top: 100px; font-size: .88rem; }
.toc ol { list-style: none; padding: 0; margin: 0; }
.toc a { display: block; padding: 7px 0 7px 14px; margin-left: -1px; border-left: 1px solid transparent; color: var(--text2); text-decoration: none; line-height: 1.35; }
.toc a:hover { color: var(--acc); border-left-color: var(--acc); }
/* the list folds on small screens once the template wraps it in <details class="toc-d"> */
.toc summary { display: flex; align-items: center; gap: 8px; list-style: none; }
.toc summary::-webkit-details-marker { display: none; }
.toc summary .chev { display: none; margin-left: auto; }
@media (min-width: 961px) { .toc summary { pointer-events: none; } }
.prose > .table-wrap, .prose > .math, .prose > .inline-tool, .prose > .explorer, .prose > .livecalc { max-width: min(100%, 1080px); }
.prose > * { max-width: 820px; }
.prose { min-width: 0; font-size: 1.07rem; line-height: 1.75; }
.prose > :first-child { margin-top: 0; }
.prose h2 { font-size: clamp(1.6rem, 2.8vw, 2.1rem); margin: 2em 0 .55em; position: relative; }
.prose h3 { font-size: 1.32rem; margin: 1.7em 0 .5em; position: relative; }
.prose p, .prose ul, .prose ol { margin-bottom: 1.15em; }
.prose li { margin-bottom: .4em; }
.prose li::marker { color: var(--acc); font-family: var(--f-mono); font-size: .85em; }
.prose strong { color: var(--head); font-weight: 600; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.4em 0; }
.prose a:not(.btn) { color: var(--head); text-decoration-color: var(--acc); text-decoration-thickness: 2px; }
.prose a:not(.btn):hover { color: var(--acc); }
.h-anchor { position: absolute; left: -1.1em; top: 0; opacity: 0; text-decoration: none !important; color: var(--acc) !important; font-family: var(--f-mono); font-weight: 500; font-size: .8em; padding-right: .3em; }
h2:hover > .h-anchor, h3:hover > .h-anchor, .h-anchor:focus { opacity: 1; }
.num { font-family: var(--f-mono); font-size: .92em; color: #cfe0ff; white-space: nowrap; }
.prose h2#sources { font: 500 .8rem/1.4 var(--f-mono); color: var(--acc); text-transform: lowercase; letter-spacing: .04em; margin-top: 3.4em; padding-top: 1.6em; border-top: 1px solid var(--line); }
.prose h2#sources::before { content: "// "; }
.prose h2#sources ~ ul { font-size: .85rem; line-height: 1.55; color: var(--text2); list-style: none; padding: 0; }
.prose h2#sources ~ ul a { color: var(--text2) !important; text-decoration-color: var(--line2) !important; text-decoration-thickness: 1px !important; overflow-wrap: anywhere; }
.prose h2#sources ~ ul .num { color: inherit; font-size: 1em; font-family: inherit; }
.gl-tip { position: relative; text-decoration: underline dotted var(--text2) !important; text-decoration-thickness: 1px !important; cursor: help; }
.gl-tip::after { content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 10px); transform: translateX(-50%) translateY(4px); width: min(320px, 80vw); background: #000; border: 1px solid var(--acc); border-radius: var(--r); padding: 12px 14px; font: 400 .84rem/1.5 var(--f-body); color: var(--text); opacity: 0; pointer-events: none; transition: opacity .15s, transform .15s; z-index: 20; box-shadow: 0 20px 50px -10px #000; }
.gl-tip:hover::after, .gl-tip:focus-visible::after, .gl-tip.is-open::after { opacity: 1; transform: translateX(-50%); }

.tldr, .math, .note, .tip, .quiz, .mission, .complete, .author, .callout { border-radius: var(--r-l); background: var(--surf); padding: 22px 24px; margin: 1.8em 0; }
.tldr { background: linear-gradient(180deg, var(--blue-wash), transparent 70%), var(--surf); font-size: 1rem; }
.tldr .block-k { color: var(--blue); }
.tldr ul, .math > :last-child, .note div > :last-child, .tip div > :last-child { margin-bottom: 0; }
.tldr li::marker { content: "→  "; color: var(--blue); }
.math { background: transparent; font-size: .98rem; }
.math .block-k { color: var(--blue); }
.math .table-wrap { margin-bottom: 1em; }
.math .table-wrap:last-child { margin-bottom: 0; }
.math td, .math th { font-family: var(--f-mono); font-size: .84rem; }
.note, .tip { display: flex; gap: 14px; align-items: flex-start; font-size: .98rem; }
.note > .i, .tip > .i { margin-top: .3em; color: var(--blue); width: 20px; height: 20px; }
.note-warn { background: linear-gradient(180deg, var(--warn-wash), transparent 80%), var(--surf); }
.note-warn > .i { color: var(--warn); }
.tip { background: linear-gradient(180deg, var(--teal-wash), transparent 80%), var(--surf); }
.tip > .i { color: var(--acc); }
.callout { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 18px; align-items: center; margin: 2em 0; }
.callout-nerdy { --c: var(--blue); } .callout-planb { --c: #fff; background: linear-gradient(120deg, rgba(167, 139, 250, .2), rgba(77, 141, 255, .12)), var(--surf); }
.callout-ic { margin: 0; }
.callout b { display: block; font: 800 1.25rem/1.2 var(--f-head); color: var(--head); }
.callout p { margin: 4px 0 0; font-size: .92rem; color: var(--text2); line-height: 1.5; }
.callout .callout-k { font: 500 .75rem/1.4 var(--f-mono); color: var(--text2); margin: 0 0 4px; }
.prose .callout a.btn { text-decoration: none; }

.quiz { padding: 24px; }
.q { border: 0; padding: 20px 0 6px; margin: 0; min-width: 0; }
.q:first-of-type { border-top: 0; padding-top: 4px; }
.q legend { font: 700 1.12rem/1.35 var(--f-head); color: var(--head); padding: 0; margin-bottom: 12px; float: left; width: 100%; }
.q legend .hex { color: var(--acc); margin-right: 6px; }
.opt { clear: both; display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border-radius: var(--r); margin-bottom: 8px; cursor: pointer; font-size: .98rem; line-height: 1.45; transition: background .15s; }
.opt, .task { background: var(--surf); }
.opt:hover, .task:hover { background: var(--surf2); }
.opt input { accent-color: var(--volt); width: 18px; height: 18px; margin-top: 3px; flex: none; }
.is-answered .opt { cursor: default; }
.is-answered .opt:hover { background: var(--surf); }
.opt.is-right, .is-answered .opt.is-right:hover { background: rgba(45, 212, 191, .2); color: #fff; }
.opt.is-wrong, .is-answered .opt.is-wrong:hover { background: rgba(255, 159, 90, .2); }
.why { font-size: .92rem; color: var(--text2); border-left: 2px solid var(--acc); padding: 2px 0 2px 14px; margin: 12px 0 14px; }
.is-bad .why { border-left-color: var(--warn); }
.quiz-score { font: 500 .85rem/1.5 var(--f-mono); color: var(--acc); margin: 8px 0 0; }
.mission ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.mission li { margin: 0; }
.task { display: flex; gap: 14px; align-items: flex-start; padding: 12px 14px; border-radius: var(--r); cursor: pointer; font-size: .98rem; line-height: 1.5; }
.task input { position: absolute; opacity: 0; }
.tick { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 6px; background: rgba(255, 255, 255, .14); color: transparent; flex: none; margin-top: 2px; transition: background .15s; }
.tick .i { width: 14px; height: 14px; stroke-width: 3; }
.task input:checked ~ .tick { background: var(--volt); color: var(--volt-ink); }
.task input:checked ~ span:last-child { color: var(--text2); text-decoration: line-through; text-decoration-color: var(--line2); }
.task input:focus-visible ~ .tick { outline: 2px solid var(--volt); outline-offset: 3px; }
.complete { position: relative; text-align: left; background: linear-gradient(120deg, rgba(45, 212, 191, .14), rgba(77, 141, 255, .1)), var(--surf); margin-top: 3em; }
.complete > b { display: block; font: 800 1.7rem/1.15 var(--f-head); color: var(--head); margin-bottom: 6px; }
.complete p { color: var(--text2); font-size: .98rem; }
.complete .actions { margin-top: 18px; }
.complete.is-done > b { color: var(--acc); }
.burst { position: absolute; left: 90px; top: 110px; pointer-events: none; }
.burst i { position: absolute; width: 8px; height: 8px; border-radius: 2px; background: var(--volt); animation: burst 1.1s cubic-bezier(.1, .7, .3, 1) forwards; }
.burst .b1 { background: var(--blue); } .burst .b2 { background: #fff; }
@keyframes burst { to { transform: translate(var(--x), var(--y)) rotate(200deg); opacity: 0; } }
.author { display: flex; gap: 18px; align-items: flex-start; margin-top: 3em; }
.author-face .logo-face { width: 72px; height: 72px; }
.author b { font: 800 1.2rem/1.2 var(--f-head); color: var(--head); }
.author p { font-size: .92rem; color: var(--text2); margin: 4px 0 0; }
.author .block-k { margin-bottom: 4px; color: var(--text2); }
.prevnext { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; max-width: 740px; margin: 40px auto 0; }
.prevnext a { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: var(--r); text-decoration: none; color: var(--head); font: 700 1rem/1.3 var(--f-head); background: var(--surf); }
.prevnext a:hover { color: var(--acc); }
.prevnext .next { justify-content: flex-end; text-align: right; }
.prevnext small { display: block; font: 500 .75rem/1.4 var(--f-mono); color: var(--text2); }
.dots-nav { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 26px 0 0; }
.dots-nav a { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 7px; font: 500 .8rem/1 var(--f-mono); color: var(--text2); text-decoration: none; background: var(--surf2); }
.dots-nav a:hover { color: var(--acc); }
.dots-nav .is-done a { background: rgba(45, 212, 191, .22); color: var(--teal); }
.dots-nav a[aria-current] { background: var(--volt); color: var(--volt-ink); }
.done-flag { color: var(--acc); display: inline-flex; align-items: center; gap: 5px; }
.prose-legal { font-size: 1rem; }
.prose-legal h2 { font-size: 1.4rem; }

/* cards get a soft top light instead of an outline */
.topic, .tri, .talk, .step, .tcard, .pcard-link, .levels a, .road-links a, .prevnext a, .xpcard, .procard, .player, .tldr, .math, .note, .tip, .quiz, .mission, .complete, .author, .callout, .table-wrap, .calc, .disclaimer { box-shadow: var(--card-sh); }
.calc { box-shadow: var(--card-sh), 0 40px 120px -50px rgba(77, 141, 255, .4); }
.complete.is-done, .levels .is-next a { box-shadow: var(--card-sh), 0 0 40px -12px rgba(45, 212, 191, .55); }

/* ------------------------------------------------------------------ footer */
.site-footer { position: relative; isolation: isolate; background: #000; padding-top: clamp(64px, 8vw, 120px); overflow: hidden; }
.footer-top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(24px, 5vw, 64px); align-items: end; padding-bottom: clamp(40px, 6vw, 72px); }
.footer-go { display: flex; flex-wrap: wrap; gap: 12px; justify-content: flex-end; }
.footer-claim { font: 800 clamp(2.4rem, 5.5vw, 4.2rem)/1 var(--f-head); color: var(--head); letter-spacing: -.03em; margin: 0 0 14px; }
.footer-sub { color: var(--text2); margin: 0; max-width: 46ch; }
.footer-cols { display: grid; grid-template-columns: 1.5fr repeat(3, minmax(0, 1fr)); gap: 32px; padding-block: clamp(36px, 5vw, 60px); }
.footer-brand p { color: var(--text2); font-size: .92rem; max-width: 38ch; margin: 16px 0 0; }
.social { display: flex; gap: 8px; }
.soc { background: var(--surf2); display: grid; place-items: center; width: 40px; height: 40px; border-radius: 8px; color: var(--text); }
.soc:hover { background: rgba(255, 255, 255, .13); color: var(--acc); }
.sisters { display: flex; flex-wrap: wrap; gap: 6px 18px; font: 500 .8rem/1.4 var(--f-mono); }
.sisters a { color: var(--text2); text-decoration: none; display: inline-flex; gap: 6px; align-items: center; }
.sisters a:hover { color: var(--acc); }
.footer-h { font: 500 .76rem/1.4 var(--f-mono); color: var(--acc); text-transform: lowercase; letter-spacing: .04em; margin: 0 0 14px; }
.footer-h::before { content: "// "; }
.footer-cols ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.footer-cols nav a { color: var(--text); text-decoration: none; font-size: .95rem; }
.footer-cols nav a:hover { color: var(--acc); }
.site-footer::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; clip-path: polygon(0 0, 100% clamp(40px, 7vw, 110px), 100% 100%, 0 100%); background: radial-gradient(60% 50% at 50% 100%, rgba(42, 116, 255, .2), transparent 70%), linear-gradient(180deg, rgba(255, 255, 255, .04), transparent 40%); }
.footer-mark { font: 800 clamp(2rem, 12.2vw, 13rem)/.8 var(--f-head); letter-spacing: -.05em; text-align: center; margin: 0 0 -.06em; color: transparent; background: linear-gradient(180deg, rgba(255, 255, 255, .14), rgba(255, 255, 255, .02)); -webkit-background-clip: text; background-clip: text; white-space: nowrap; user-select: none; }
.footer-mark span { -webkit-text-fill-color: var(--blue); }
.footer-legal { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; padding-block: 22px; font-size: .8rem; color: var(--text2); }
.footer-legal p { margin: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; }
.footer-legal a, .footer-legal .linkbtn { color: var(--text2); text-decoration: none; }
.footer-legal a:hover, .footer-legal .linkbtn:hover { color: var(--acc); }
.totop { background: var(--surf2); display: grid !important; place-items: center; width: 34px; height: 34px; border-radius: 8px; }

/* ------------------------------------------------------------------ overlays: search, terminal */
.search, .term { position: fixed; inset: 0; z-index: 100; background: rgba(0, 0, 0, .78); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: grid; align-items: start; justify-items: center; padding: min(14vh, 120px) 16px 16px; }
.search-box, .term-box { width: min(680px, 100%); background: #07080c; border-radius: var(--r-l); box-shadow: 0 40px 120px -20px #000, 0 0 90px -30px rgba(77, 141, 255, .5), var(--card-sh); overflow: hidden; animation: pop .16s ease-out; }
.search-in { display: flex; align-items: center; gap: 12px; padding: 4px 16px; color: var(--text2); }
/* the fields have no box of their own, so the row shows the focus */
.search-in:focus-within { box-shadow: inset 0 -2px 0 var(--acc); color: var(--acc); }
.term-in:focus-within { box-shadow: inset 2px 0 0 var(--acc); }
.search-in input { border: 0 !important; box-shadow: none !important; background: none !important; padding: 16px 0 !important; font-size: 1.05rem; }
.search-h { font: 500 .75rem/1 var(--f-mono); color: var(--text2); text-transform: lowercase; letter-spacing: .05em; margin: 0; padding: 14px 18px 6px; }
.search-results { list-style: none; margin: 0; padding: 6px 8px; max-height: min(52vh, 460px); max-height: min(52dvh, 460px); overflow: auto; }
.search-results a { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 2px 12px; padding: 10px; border-radius: 8px; text-decoration: none; color: var(--head); font: 700 1rem/1.3 var(--f-head); }
.search-results a span { grid-row: span 2; align-self: start; font: 500 .75rem/1 var(--f-mono); color: var(--acc); padding-top: 4px; text-transform: lowercase; }
.search-results a small { font: 400 .82rem/1.4 var(--f-body); color: var(--text2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-results a[aria-selected="true"], .search-results a:hover { background: var(--surf2); }
.search-results .empty { padding: 18px 10px; }
.search-foot { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 0; padding: 12px 18px; font-size: .76rem; color: var(--text2); }
.search-foot span { display: inline-flex; gap: 5px; align-items: center; }
.term-out { padding: 16px 18px 4px; font: 500 .86rem/1.8 var(--f-mono); max-height: 46vh; max-height: 46dvh; min-height: 140px; overflow: auto; white-space: pre-wrap; }
.term-out .cmd { color: #fff; }
.term-in { display: flex; align-items: center; gap: 10px; padding: 6px 18px 16px; font: 500 .9rem/1 var(--f-mono); color: var(--acc); }
.term-in input { border: 0 !important; box-shadow: none !important; background: none !important; padding: 8px 0 !important; font: 500 .9rem/1 var(--f-mono); caret-color: var(--acc); }

/* ------------------------------------------------------------------ responsive */
@media (max-width: 1240px) {
  .searchlbl, .searchbtn kbd { display: none; }
  .bar { gap: 16px; }
}
@media (max-width: 1180px) {
  .bar .langsw, .bar-cta .chip, .xpchip span { display: none; }
  .bar-cta { padding: 11px 14px; }
  .navlink { padding: 10px 9px; }
}
@media (max-width: 960px) {
  .mainnav, .bar-cta, .bar .langsw { display: none; }
  .menubtn { display: inline-flex; }
  .bar { grid-template-columns: auto minmax(0, 1fr); }
  .bar-actions { grid-column: 2; }
  .hero-in, .phero-in.has-aside, .planb-teaser, .rules, .pro, .method, .manifesto, .footer-top { grid-template-columns: minmax(0, 1fr); }
  .phero-aside { justify-content: flex-start; }
  .calc { grid-template-columns: minmax(0, 1fr); }
  .article-grid { grid-template-columns: minmax(0, 1fr); }
  .toc { position: static; border-radius: var(--r); padding: 16px 18px; background: var(--surf); box-shadow: var(--card-sh); }
  .toc summary { cursor: pointer; margin: 0; min-height: 28px; }
  .toc summary .chev { display: block; }
  .toc details[open] > summary { margin-bottom: 10px; }
  .footer-cols { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer-brand { grid-column: 1 / -1; }
  .pcard-big { grid-column: auto; }
  .h-anchor { display: none; }
}
/* glossary tips: a sheet at the bottom wherever a bubble above the word could leave the screen, and on every touch screen */
@media (max-width: 960px), (hover: none) {
  .gl-tip::after { position: fixed; left: 16px; right: 16px; bottom: 16px; width: auto; max-width: 560px; margin-inline: auto; transform: translateY(6px); }
  .gl-tip:hover::after, .gl-tip:focus-visible::after, .gl-tip.is-open::after { transform: none; }
}
@media (max-width: 640px) {
  body { font-size: 1rem; }
  h1, h2, h3, h4 { -webkit-hyphens: auto; hyphens: auto; }
  .btn { white-space: normal; text-align: center; line-height: 1.2; }
  .waitlist, .frow { grid-template-columns: minmax(0, 1fr); }
  .waitlist .btn { width: 100%; }
  .footer-cols { grid-template-columns: 1fr 1fr; }
  .callout { grid-template-columns: auto minmax(0, 1fr); }
  .callout .btn { grid-column: 1 / -1; }
  .aboutt { grid-template-columns: minmax(0, 1fr); }
  .photos { grid-template-columns: minmax(0, 1fr); }
  .livecalc .live-in { grid-template-columns: minmax(0, 1fr); }
  .ex-row { grid-template-columns: minmax(0, 1fr); }
  .ex-row b { grid-row: auto; }
  .guess, .explorer { padding: 18px; }
  .avatar { width: 160px; height: 160px; }
  .field-row, .calc-mini .field-row { grid-template-columns: minmax(0, 1fr) 8.75rem; gap: 10px; }
  /* under 16px iOS zooms into the page when a field gets the focus */
  .numwrap input, .field-select select, .combo input, .term-in input { font-size: 16px; }
  .kpis[data-n="5"] { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpis[data-n="5"] .kpi, .kpis[data-n="5"] .kpi:nth-child(n+4) { grid-column: auto; }
  .kpis[data-n="5"] .kpi:last-child { grid-column: 1 / -1; }
  .kpis[data-n="3"], .calc-mini .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpis[data-n="3"] .kpi:last-child { grid-column: 1 / -1; }
  .calc-mini .kpi:last-child { grid-column: 1 / -1; }
  .levels a { align-items: flex-start; flex-wrap: wrap; }
  .lvl-xp { margin-left: 54px; }
  .lvl-body { flex: 1 1 60%; }
  .gl-group { padding-left: 0; }
  .gl-letter { position: static; padding-top: 20px; }
  .prevnext { grid-template-columns: minmax(0, 1fr); }
  .pgrid, .tgrid, .tgrid-big { grid-template-columns: minmax(0, 1fr); }
  .actions .btn { flex: 1 1 auto; }
  .tldr, .math, .note, .tip, .quiz, .mission, .complete, .author, .callout { padding: 18px; }
  .search, .term { padding-top: 12px; }
  .chart-tip { min-width: 150px; }
}
/* fingers: every control gets a target of 44px. Inline links grow by padding, which does not move the lines */
@media (pointer: coarse) {
  .chip-link, .chip-btn, .xpchip, .searchbtn, .menubtn { min-height: 44px; min-width: 44px; justify-content: center; }
  .langsw a, .langsw span { display: inline-flex; align-items: center; min-height: 44px; padding-inline: 14px; }
  .letters a, .dots-nav a, .totop, .soc { width: 44px; height: 44px; }
  .seg span { padding-block: 13px; }
  .toc a { padding-block: 12px; }
  .footer-cols ul { gap: 0; }
  .footer-cols nav a { display: inline-block; padding-block: 10px; }
  .crumbs a, .footer-legal a, .footer-legal .linkbtn, .sisters a, .src a, .form-note a { padding-block: 13px; }
  .term-bar .linkbtn { padding: 16px; margin: -11px -14px -11px auto; }
  input[type="range"] { height: 44px; }
  input[type="range"]::-webkit-slider-thumb { width: 28px; height: 28px; margin-top: -12px; border-radius: 8px; }
  input[type="range"]::-moz-range-thumb { width: 22px; height: 22px; border-radius: 8px; }
}
@media (hover: none) { .search-foot { display: none; } }
/* big screens: everything a size up, like nerdy.money does */
@media (min-width: 1700px) { html { font-size: 112.5%; } :root { --bar-h: 76px; } }
@media (min-width: 2300px) { html { font-size: 125%; } }

@media print {
  .site-header, .site-footer, .mob, .search, .term, .toc, .callout, .complete, .prevnext { display: none !important; }
  body { background: #fff; color: #000; }
  h1, h2, h3, .prose strong { color: #000; }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
}
