/* goutham.work, night-race edition.
   Layout: a fixed WebGL circuit behind everything; the hero floats over it like a
   broadcast graphic, then content panels scroll over a dimmed track.
   One deliberate dark look, so there is no light theme. */
@font-face { font-family: "Big Shoulders Display"; src: url("../fonts/big-shoulders-display-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Schibsted Grotesk"; src: url("../fonts/schibsted-grotesk-latin-wght-normal.woff2") format("woff2"); font-weight: 400 900; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("../fonts/jetbrains-mono-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "JetBrains Mono"; src: url("../fonts/jetbrains-mono-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --asphalt: #0a0c10;      /* page */
  --panel: #12151b;        /* raised surfaces */
  --panel-2: #181c24;
  --line: #262b36;
  --ink: #eeebe4;          /* floodlight white */
  --mute: #9aa1ad;
  --soft-c: #ff4b4b;       /* compounds */
  --med-c: #ffc53d;
  --hard-c: #e9edf3;
  --purple: #b18cff;       /* timing screens: fastest overall */
  --green: #3ddc84;        /* timing screens: personal best */
  --accent: var(--purple);
  --good: var(--green);
  --warn: #ffb547;
  --grid: #222733;

  --f-display: "Big Shoulders Display", "Arial Narrow", "Roboto Condensed", Impact, sans-serif;
  --f-body: "Schibsted Grotesk", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --f-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --gutter: clamp(16px, 4vw, 48px);
  --max: 1180px;
  --radius: 14px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 76px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--asphalt); color: var(--ink); font-family: var(--f-body); font-size: 1.0625rem; line-height: 1.6; overflow-x: hidden; }
img, svg { max-width: 100%; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.1; text-wrap: balance; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 100; background: var(--ink); color: var(--asphalt); padding: 10px 14px; border-radius: 8px; font-weight: 700; }
.skip:focus { top: 12px; }
.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }

.eyebrow, .project__meta, .tower__head, .tower__k, .readout__label, .timeline__when, .tools dt, .tags, .kbd, .hud, .viz__title, .card__facts dt, .legend__cap {
  font-family: var(--f-mono); font-size: .74rem; letter-spacing: .08em; text-transform: uppercase; font-weight: 500;
}
.eyebrow { color: var(--mute); }

/* ---------- canvas ---------- */
#scene { position: fixed; inset: 0; width: 100vw; height: 100vh; height: 100lvh; display: block; z-index: 0; touch-action: pan-y; cursor: grab; transition: opacity .2s linear; }
#scene.is-drag { cursor: grabbing; }
.nogl-bg { display: none; }
.no-gl #scene { display: none; }
.no-gl .nogl-bg { display: block; position: fixed; inset: 0; z-index: 0; background:
  radial-gradient(60% 50% at 70% 40%, rgb(255 75 75 / .16), transparent 70%),
  radial-gradient(40% 40% at 85% 65%, rgb(255 197 61 / .12), transparent 70%),
  var(--asphalt); }
.no-gl .legend { display: none; }

/* ---------- bar ---------- */
.bar { position: fixed; top: 0; left: 0; right: 0; z-index: 30; padding-top: env(safe-area-inset-top, 0px); transition: background .25s, border-color .25s; border-bottom: 1px solid transparent; }
.bar.is-solid { background: rgb(10 12 16 / .9); border-bottom-color: var(--line); }
@supports (backdrop-filter: blur(4px)) { .bar.is-solid { background: rgb(10 12 16 / .72); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); } }
.bar__inner { max-width: var(--max); margin-inline: auto; padding: 12px var(--gutter); display: flex; align-items: center; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--f-mono); font-size: .86rem; }
.brand__mark { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 8px; background: var(--ink); color: var(--asphalt); font-family: var(--f-display); font-weight: 900; font-size: 1.1rem; letter-spacing: .02em; }
.nav { display: flex; gap: 4px; margin-left: auto; }
.nav a { text-decoration: none; color: var(--mute); padding: 8px 12px; border-radius: 8px; font-size: .95rem; }
.nav a:hover { color: var(--ink); }
.nav a[aria-current="true"] { color: var(--ink); background: rgb(255 255 255 / .06); }
.menu-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 6px 12px; border-radius: 10px; border: 1px solid var(--line); background: rgb(18 21 27 / .7); color: var(--ink); font: inherit; font-size: .9rem; cursor: pointer; }
.menu-btn:hover { border-color: var(--mute); }
.menu-btn__label { display: none; }
.kbd { display: inline-flex; align-items: center; gap: 4px; padding: 1px 6px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; color: var(--mute); font-size: .7rem; letter-spacing: .04em; }
@media (max-width: 880px) { .nav { display: none; } .menu-btn { margin-left: auto; } .menu-btn .kbd { display: none; } .menu-btn__label { display: inline; } }

/* ---------- hero ---------- */
.hero {
  position: relative; z-index: 1; min-height: 100svh; pointer-events: none;
  max-width: calc(var(--max) + 2 * var(--gutter)); margin-inline: auto;
  padding: calc(80px + env(safe-area-inset-top, 0px)) var(--gutter) 22px;
  display: grid; gap: 18px;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto 1fr auto;
  grid-template-areas: "hud legend" "main ." "tower tower";
}
.hero::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(90deg, rgb(10 12 16 / .78) 0%, rgb(10 12 16 / .35) 42%, transparent 62%),
              linear-gradient(0deg, rgb(10 12 16 / .7) 0%, transparent 34%); }
.hero a, .hero button { pointer-events: auto; }
.hud { grid-area: hud; align-self: start; align-items: center; display: flex; flex-wrap: wrap; gap: 8px 22px; color: var(--mute); }
.hud b { color: var(--ink); font-weight: 500; font-variant-numeric: tabular-nums; }
.hud__live { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); }
.hud__live i { width: 8px; height: 8px; border-radius: 50%; background: var(--soft-c); box-shadow: 0 0 0 0 rgb(255 75 75 / .6); animation: live 1.8s infinite; }
@keyframes live { 70% { box-shadow: 0 0 0 8px rgb(255 75 75 / 0); } 100% { box-shadow: 0 0 0 0 rgb(255 75 75 / 0); } }

.hero__main { grid-area: main; align-self: end; display: grid; gap: 16px; max-width: 46rem; text-shadow: 0 2px 24px rgb(10 12 16 / .9); }
.hero__title { font-family: var(--f-display); font-weight: 900; text-transform: uppercase; line-height: .84; letter-spacing: -.005em; font-size: clamp(4.4rem, 1.6rem + 9vw, 10rem); display: grid; }
.hero__title span:last-child { color: transparent; -webkit-text-stroke: 2px var(--ink); text-shadow: none; }
@supports not (-webkit-text-stroke: 2px white) { .hero__title span:last-child { color: var(--ink); } }
.hero__lede { font-size: clamp(1.1rem, 1rem + .5vw, 1.4rem); line-height: 1.45; max-width: 34ch; }
.status { display: inline-flex; align-items: center; gap: 10px; color: var(--mute); font-size: .95rem; }
.status__dot { width: 9px; height: 9px; border-radius: 50%; background: var(--green); flex: none; box-shadow: 0 0 12px var(--green); }
.cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 20px; border-radius: 999px; border: 1px solid var(--line); background: rgb(18 21 27 / .8); color: var(--ink); font: inherit; font-weight: 600; font-size: .98rem; text-decoration: none; cursor: pointer; transition: transform .15s, border-color .15s, background .15s; }
.btn:hover { border-color: var(--mute); transform: translateY(-1px); }
.btn--primary { background: var(--ink); color: var(--asphalt); border-color: var(--ink); text-shadow: none; }
.btn--primary:hover { background: #fff; }
.btn__meta { font-family: var(--f-mono); font-size: .66rem; letter-spacing: .08em; color: var(--mute); }

/* timing tower */
.tower { grid-area: tower; margin-top: 12px; pointer-events: auto; background: rgb(12 14 19 / .78); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; font-variant-numeric: tabular-nums; }
.tower__head { display: flex; justify-content: space-between; padding: 7px 14px; color: var(--mute); border-bottom: 1px solid var(--line); background: rgb(255 255 255 / .03); }
.tower ol { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tower li { border-right: 1px solid rgb(255 255 255 / .06); }
.tower li:last-child { border-right: 0; }
.tower li { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 14px; border-bottom: 1px solid rgb(255 255 255 / .05); border-left: 3px solid transparent; }
.tower li { border-bottom: 0; }
.tower__k { color: var(--mute); font-size: .68rem; line-height: 1.35; }
.tower__v { font-family: var(--f-display); font-weight: 800; font-size: 1.75rem; line-height: 1; text-align: right; display: grid; }
.tower__v small { font-family: var(--f-mono); font-weight: 400; font-size: .64rem; color: var(--mute); letter-spacing: .04em; text-transform: uppercase; margin-top: 3px; }
.tower li.is-fastest { border-left-color: var(--purple); background: linear-gradient(90deg, rgb(177 140 255 / .14), transparent 70%); }
.tower li.is-fastest .tower__v { color: var(--purple); }

.legend { grid-area: legend; align-self: start; justify-self: end; display: grid; gap: 8px; text-align: right; }
.legend__hint { color: var(--mute); font-size: .88rem; }
.legend__btns { display: flex; gap: 6px; justify-content: flex-end; flex-wrap: wrap; }
.lane { display: inline-flex; align-items: center; gap: 7px; min-height: 36px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: rgb(18 21 27 / .8); color: var(--ink); font: inherit; font-size: .86rem; cursor: pointer; }
.lane::before { content: ""; width: 11px; height: 11px; border-radius: 50%; border: 3px solid var(--c); }
.lane--S { --c: var(--soft-c); } .lane--M { --c: var(--med-c); } .lane--H { --c: var(--hard-c); }
.lane[aria-pressed="true"] { border-color: var(--c); background: color-mix(in srgb, var(--c) 16%, rgb(18 21 27)); }
.legend__cap { color: var(--mute); font-size: .64rem; max-width: 34ch; justify-self: end; }

@media (max-width: 880px) {
  .hero { grid-template-columns: minmax(0, 1fr); grid-template-areas: "hud" "legend" "main" "tower"; grid-template-rows: auto auto 1fr auto; min-height: auto; padding-top: calc(76px + env(safe-area-inset-top, 0px)); }
  .hero::before { background: linear-gradient(0deg, rgb(10 12 16 / .9) 0%, rgb(10 12 16 / .55) 55%, rgb(10 12 16 / .2) 100%); }
  .hero__main { padding-top: 22vh; }
  .legend__cap { display: none; }
  .hero__title { font-size: min(23vw, 9rem); }
  .tower { margin-top: 0; }
  .tower ol { display: grid; grid-template-columns: 1fr 1fr; }
  .tower li { flex-direction: column; align-items: flex-start; border-left: 0; border-right: 1px solid rgb(255 255 255 / .05); }
  .tower li .tower__v { text-align: left; }
  .tower li.is-fastest { border-left: 0; box-shadow: inset 3px 0 0 var(--purple); }
  .legend { justify-self: start; text-align: left; }
  .legend__btns { justify-content: flex-start; }
  .legend__cap { justify-self: start; }
  .hud__wide { display: none; }
  .hero__title span:last-child { -webkit-text-stroke-width: 1.5px; }
}
@media (hover: none) { .drag-hint { display: none; } }

/* ---------- sections ---------- */
main > .section { position: relative; z-index: 1; background: rgb(10 12 16 / .9); padding-block: clamp(72px, 9vw, 128px); border-top: 1px solid var(--line); }
.section__head { display: grid; gap: 12px; margin-bottom: clamp(32px, 5vw, 56px); max-width: 62ch; }
.section h2 { font-family: var(--f-display); font-weight: 800; text-transform: uppercase; font-size: clamp(2.6rem, 1.6rem + 4vw, 4.8rem); line-height: .92; letter-spacing: .005em; }
.section__intro { color: var(--mute); font-size: 1.08rem; }

/* projects */
.project { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 28px clamp(24px, 4vw, 56px); padding-block: clamp(36px, 5vw, 56px); border-top: 1px solid var(--line); }
.project:first-of-type { border-top: 0; padding-top: 0; }
.project__lead { display: grid; gap: 14px; align-content: start; min-width: 0; }
.project__meta { display: flex; flex-wrap: wrap; gap: 6px 16px; color: var(--mute); }
.project__title { font-family: var(--f-display); font-weight: 800; text-transform: uppercase; font-size: clamp(2rem, 1.4rem + 2.4vw, 3.3rem); line-height: .95; }
.project__summary { font-size: 1.12rem; max-width: 46ch; }
.project__links { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.project__links a { color: var(--purple); font-weight: 600; text-underline-offset: 4px; }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; }
.chip { font-size: .84rem; padding: 5px 11px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--line); }
.chip--win { border-color: rgb(177 140 255 / .5); color: var(--purple); background: rgb(177 140 255 / .08); }
.case { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.case > div { padding: 20px; border-left: 1px solid var(--line); min-width: 0; }
.case > div:first-child { border-left: 0; }
.case h4 { font-family: var(--f-mono); font-size: .72rem; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--mute); margin-bottom: 8px; }
.case p { font-size: .96rem; line-height: 1.55; }
.tags { grid-column: 1 / -1; color: var(--mute); font-size: .7rem; }
@media (max-width: 980px) { .case { grid-template-columns: 1fr 1fr; } .case > div:nth-child(3) { border-left: 0; } .case > div:nth-child(n+3) { border-top: 1px solid var(--line); } }
@media (max-width: 760px) { .project { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) { .case { grid-template-columns: 1fr; } .case > div { border-left: 0; } .case > div + div { border-top: 1px solid var(--line); } }

/* project visuals */
.viz { margin: 0; align-self: start; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; display: grid; gap: 16px; min-width: 0; }
.viz__title { color: var(--mute); }
.viz__note { color: var(--mute); font-size: .8rem; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.key { display: inline-block; width: 12px; height: 4px; border-radius: 2px; }
.key--base { background: #3a404d; } .key--val { background: var(--green); margin-left: 8px; }
.key--soft { background: var(--soft-c); } .key--hard { background: var(--hard-c); margin-left: 8px; }
.bars { display: grid; gap: 14px; }
.bars__row { display: grid; grid-template-columns: 7.5rem minmax(0, 1fr) 5.5rem; align-items: center; gap: 12px; font-size: .9rem; }
.bars__row b { font-family: var(--f-mono); font-weight: 500; font-size: .86rem; text-align: right; font-variant-numeric: tabular-nums; }
.bars__track { position: relative; height: 12px; }
.bars__base { position: absolute; inset: 0; border-radius: 3px; background: #2a2f3a; }
.bars__val { position: absolute; left: 0; top: 3px; bottom: 3px; width: var(--v); border-radius: 3px; background: var(--green); transform-origin: left; }
.bars__val--slow { background: var(--soft-c); top: 0; bottom: 0; }
.viz--speed .bars__val { top: 0; bottom: 0; }
.reveal .bars__val { transition: transform 1s cubic-bezier(.2,.7,.2,1) .2s; }
.js .reveal:not(.is-in) .bars__val { transform: scaleX(.15); }
@media (max-width: 420px) { .bars__row { grid-template-columns: 5.6rem minmax(0, 1fr) 4.6rem; gap: 8px; font-size: .84rem; } }
.viz svg { width: 100%; height: auto; display: block; overflow: visible; }
.viz .g line { stroke: var(--grid); }
.viz .t { font-family: var(--f-mono); font-size: 9px; fill: var(--mute); }
.viz .t--pit { fill: var(--ink); }
.viz .s1, .viz .s2 { fill: none; stroke-width: 3; stroke-linecap: round; }
.viz .s1 { stroke: var(--soft-c); } .viz .s2 { stroke: var(--hard-c); }
.viz .pit { stroke: var(--ink); stroke-dasharray: 3 4; }
.js .reveal .s1, .js .reveal .s2 { stroke-dasharray: 300; stroke-dashoffset: 0; transition: stroke-dashoffset 1.4s ease .2s; }
.js .reveal:not(.is-in) .s1, .js .reveal:not(.is-in) .s2 { stroke-dashoffset: 300; }
.flow { list-style: none; display: grid; gap: 10px; counter-reset: f; }
.flow li { position: relative; display: grid; gap: 2px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2); }
.flow li + li::before { content: ""; position: absolute; left: 22px; top: -11px; width: 1px; height: 10px; background: var(--mute); }
.flow b { font-weight: 600; font-size: .95rem; }
.flow span { color: var(--mute); font-size: .85rem; }
.flow li.is-key { border-color: rgb(61 220 132 / .55); background: rgb(61 220 132 / .07); }
.flow li.is-key span { color: var(--green); }
.pipe { display: flex; flex-wrap: wrap; gap: 6px; font-family: var(--f-mono); font-size: .72rem; }
.pipe span { padding: 4px 8px; border-radius: 6px; border: 1px solid var(--line); color: var(--mute); }
.pipe span + span::before { content: "→ "; color: #4a5160; }
.pipe .is-key { color: var(--green); border-color: rgb(61 220 132 / .5); }
.also { margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line); color: var(--mute); max-width: 75ch; }
.also .eyebrow { margin-right: 8px; color: var(--ink); }
.also a { color: var(--purple); font-weight: 600; text-underline-offset: 4px; white-space: nowrap; }

/* reveal: elements rise from a visible resting state */
.js .reveal { transition: transform .8s cubic-bezier(.2,.7,.2,1), opacity .8s; }
.js .reveal:not(.is-in) { transform: translateY(28px); opacity: .35; }
@media (prefers-reduced-motion: reduce) { .js .reveal, .js .reveal * { transition: none !important; transform: none !important; opacity: 1 !important; stroke-dashoffset: 0 !important; } }

/* ---------- pit wall ---------- */
.section--pit { background: rgb(13 15 20 / .94) !important; }
.pit { display: grid; grid-template-columns: minmax(0, 300px) minmax(0, 1fr); gap: clamp(20px, 3vw, 32px); align-items: start; }
@media (max-width: 860px) { .pit { grid-template-columns: minmax(0, 1fr); } }
.pit__controls, .pit__board { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; min-width: 0; }
.pit__controls { display: grid; gap: 22px; }
.seg { border: 0; padding: 0; margin: 0; min-width: 0; }
.seg legend, .slider label { font-weight: 600; font-size: .92rem; margin-bottom: 8px; padding: 0; }
.seg__opts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.seg__opts input { position: absolute; opacity: 0; pointer-events: none; }
.cmp { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 42px; border: 1px solid var(--line); border-radius: 8px; font-size: .88rem; cursor: pointer; background: var(--panel-2); user-select: none; }
.cmp::before { content: ""; width: 12px; height: 12px; border-radius: 50%; border: 3px solid var(--c); flex: none; }
.cmp--S { --c: var(--soft-c); } .cmp--M { --c: var(--med-c); } .cmp--H { --c: var(--hard-c); }
.seg__opts input:checked + .cmp { border-color: var(--c); font-weight: 700; background: color-mix(in srgb, var(--c) 14%, var(--panel-2)); }
.seg__opts input:focus-visible + .cmp { outline: 3px solid var(--accent); outline-offset: 2px; }
.slider label { display: block; }
.slider output { font-family: var(--f-mono); font-weight: 500; color: var(--purple); }
input[type="range"] { width: 100%; accent-color: var(--purple); min-height: 28px; }
.readout { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.readout__item { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.readout__label { color: var(--mute); }
.readout__val { font-family: var(--f-mono); font-size: clamp(1.05rem, .9rem + .7vw, 1.5rem); font-weight: 500; font-variant-numeric: tabular-nums; }
.readout__val.is-best { color: var(--purple); }
.readout__val.is-slow { color: var(--warn); }
@media (max-width: 520px) { .readout { grid-template-columns: 1fr 1fr; } .readout__item:first-child { grid-column: 1 / -1; } }
.rule-note { margin-top: 12px; padding: 10px 12px; border-radius: 8px; background: rgb(255 181 71 / .1); border: 1px solid rgb(255 181 71 / .4); font-size: .92rem; }
.chart { margin-top: 18px; width: 100%; aspect-ratio: 640 / 280; max-width: 100%; }
.chart svg { width: 100%; height: 100%; display: block; overflow: visible; }
.chart__cap { margin-top: 10px; color: var(--mute); font-size: .9rem; }
.ax { font-family: var(--f-mono); font-size: 11px; fill: var(--mute); }
.gridline { stroke: var(--grid); stroke-width: 1; }
.pitline { stroke: var(--ink); stroke-width: 1.5; stroke-dasharray: 4 4; }
.bestline { stroke: var(--purple); stroke-width: 1.5; stroke-dasharray: 2 4; }
.lbl { font-family: var(--f-mono); font-size: 11px; }
.lbl--pit { fill: var(--ink); } .lbl--best { fill: var(--purple); }
.method { margin-top: 20px; max-width: 72ch; }
.method > summary { cursor: pointer; font-weight: 600; min-height: 32px; }
.method__body { display: grid; gap: 10px; margin-top: 10px; color: var(--mute); }
.method__warn { color: var(--ink); }

/* ---------- about ---------- */
.about { display: grid; grid-template-columns: minmax(0, 320px) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
@media (max-width: 820px) { .about { grid-template-columns: minmax(0, 1fr); } }
.card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); overflow: hidden; }
.card__photo { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 35%; }
.card__mono { aspect-ratio: 4 / 3; display: grid; place-items: center; font-family: var(--f-display); font-weight: 900; font-size: 6rem; color: var(--asphalt);
  background: repeating-linear-gradient(-45deg, transparent 0 14px, rgb(10 12 16 / .08) 14px 15px), linear-gradient(135deg, var(--purple), #7f5bff); }
.card__facts { padding: 6px 18px 14px; display: grid; }
.card__facts div { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.card__facts div:last-child { border-bottom: 0; }
.card__facts dt { color: var(--mute); }
.card__facts dd { margin: 0; text-align: right; font-size: .95rem; }
.about__text { display: grid; gap: 16px; max-width: 64ch; }
.about__text h2 { margin-bottom: 6px; }

/* ---------- experience ---------- */
.timeline { list-style: none; display: grid; }
.timeline li { display: grid; grid-template-columns: minmax(0, 190px) minmax(0, 1fr); gap: 8px 28px; padding: 20px 0; border-top: 1px solid var(--line); }
.timeline li:last-child { border-bottom: 1px solid var(--line); }
.timeline__when { color: var(--mute); padding-top: 4px; }
.timeline h3 { font-size: 1.12rem; font-weight: 600; margin-bottom: 4px; }
.timeline p { color: var(--mute); }
@media (max-width: 640px) { .timeline li { grid-template-columns: minmax(0, 1fr); } }

/* ---------- recognition + toolbox ---------- */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(36px, 6vw, 80px); }
@media (max-width: 820px) { .split { grid-template-columns: minmax(0, 1fr); } }
.split h2 { font-size: clamp(2rem, 1.4rem + 2.4vw, 3rem); margin-bottom: 20px; }
.list { list-style: none; display: grid; gap: 10px; }
.list li { padding-left: 18px; position: relative; }
.list li::before { content: ""; position: absolute; left: 0; top: .7em; width: 7px; height: 7px; border-radius: 2px; background: var(--purple); }
.list--quiet li { color: var(--mute); }
.list--quiet li::before { background: #3a404d; }
.sub { font-size: 1rem; font-weight: 600; margin: 28px 0 12px; }
.tools { display: grid; gap: 0; margin: 0; }
.tools div { padding: 14px 0; border-top: 1px solid var(--line); display: grid; gap: 4px; }
.tools dt { color: var(--mute); }
.tools dd { margin: 0; }

/* ---------- contact ---------- */
.section--contact { background: linear-gradient(180deg, rgb(10 12 16 / .9), rgb(10 12 16 / .55)) !important; padding-block: clamp(96px, 14vw, 180px) !important; }
.contact__title { font-size: clamp(4rem, 2rem + 10vw, 10rem) !important; margin: 10px 0 18px; }
.contact__lede { max-width: 52ch; color: var(--mute); font-size: 1.12rem; }
.contact__email { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 32px; }
.contact__email a { font-family: var(--f-mono); font-size: clamp(1.05rem, .8rem + 1.3vw, 1.7rem); text-decoration-color: var(--purple); text-underline-offset: 6px; word-break: break-all; }
.toast { color: var(--green); font-size: .92rem; min-height: 1.4em; }
.contact__links { list-style: none; display: flex; flex-wrap: wrap; gap: 10px 26px; margin-top: 28px; }
.contact__links a { font-weight: 600; text-decoration: none; border-bottom: 1px solid var(--line); padding-bottom: 2px; }
.contact__links a:hover { border-color: var(--purple); }

.foot { position: relative; z-index: 1; background: var(--asphalt); border-top: 1px solid var(--line); padding-block: 28px calc(28px + env(safe-area-inset-bottom, 0px)); color: var(--mute); font-size: .86rem; }
.foot__inner { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; }

/* ---------- quick menu ---------- */
.palette { border: 0; padding: 0; background: transparent; width: min(560px, calc(100vw - 32px)); margin-top: 12vh; color: var(--ink); }
.palette::backdrop { background: rgb(5 6 9 / .6); backdrop-filter: blur(3px); }
.palette__box { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 30px 80px rgb(0 0 0 / .6); overflow: hidden; }
.palette__input { width: 100%; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: var(--ink); font: inherit; font-size: 1.02rem; padding: 16px 18px; }
.palette__input:focus { outline: none; }
.palette__input::placeholder { color: var(--mute); }
.palette__list { list-style: none; margin: 0; padding: 6px; max-height: 50vh; overflow-y: auto; }
.palette__item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border-radius: 8px; cursor: pointer; min-height: 40px; }
.palette__item[aria-selected="true"] { background: rgb(177 140 255 / .14); color: var(--purple); }
.palette__item small { font-family: var(--f-mono); color: var(--mute); font-size: .7rem; text-transform: uppercase; letter-spacing: .06em; }
.palette__empty { padding: 14px 12px; color: var(--mute); }
.palette__hint { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 10px 14px; border-top: 1px solid var(--line); color: var(--mute); font-size: .8rem; }

/* ---------- photos ---------- */
.photo { margin: 0; display: grid; gap: 10px; min-width: 0; }
.photo img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: var(--radius); border: 1px solid var(--line); background: var(--panel); }
.photo figcaption { color: var(--mute); font-size: .88rem; }
.photo--wide { grid-column: 1 / -1; }
.photo--wide img { aspect-ratio: 21 / 9; object-position: 50% 40%; }
@media (max-width: 760px) { .photo--wide img { aspect-ratio: 4 / 3; object-position: 62% 50%; } }
.gallery { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); grid-template-areas: "a b" "c c"; gap: 22px; }
.photo--a { grid-area: a; } .photo--b { grid-area: b; } .photo--c { grid-area: c; }
.photo--a img, .photo--b img { aspect-ratio: 4 / 3; }
.photo--b img { object-position: 42% 50%; }
.photo--c img { aspect-ratio: 16 / 9; object-position: 50% 30%; }
@media (max-width: 820px) { .gallery { grid-template-columns: minmax(0, 1fr); grid-template-areas: "a" "b" "c"; } .photo--c img { aspect-ratio: 4 / 3; object-position: 68% 30%; } }

/* ---------- more products ---------- */
.more { padding-top: clamp(36px, 5vw, 56px); border-top: 1px solid var(--line); }
.more__head { display: grid; gap: 8px; margin-bottom: 24px; }
.more__title { font-family: var(--f-display); font-weight: 800; text-transform: uppercase; font-size: clamp(1.8rem, 1.3rem + 1.8vw, 2.6rem); line-height: .95; }
.more__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
@media (max-width: 1080px) { .more__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 680px) { .more__grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) { .more__grid { grid-template-columns: minmax(0, 1fr); } }
.product { position: relative; display: grid; grid-template-columns: minmax(0, 200px) minmax(0, 1fr); text-decoration: none; color: inherit; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: border-color .2s, transform .2s; }
.product:hover { border-color: var(--mute); transform: translateY(-2px); }
.product__shot { display: block; background: #000; border-right: 1px solid var(--line); }
.product__shot img { display: block; width: 100%; height: 100%; max-height: 300px; object-fit: cover; object-position: left top; }
.product__body { display: grid; align-content: start; gap: 8px; padding: 20px; }
.product__status { font-family: var(--f-mono); font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; color: var(--green); }
.product__name { color: inherit; text-decoration: none; font-family: var(--f-display); font-weight: 800; font-size: 1.9rem; text-transform: uppercase; line-height: 1; }
.product__text { color: var(--mute); font-size: .95rem; }
@media (max-width: 460px) { .product { grid-template-columns: minmax(0, 1fr); } .product__shot { border-right: 0; border-bottom: 1px solid var(--line); } .product__shot img { max-height: 220px; } }
.product__name::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }
.product__name:focus-visible { outline: none; }
.product__name:focus-visible::after { outline: 3px solid var(--accent); outline-offset: 2px; }
.product__code { position: relative; z-index: 1; justify-self: start; margin-top: 4px; color: var(--purple); font-weight: 600; font-size: .9rem; text-underline-offset: 4px; }
.product__links { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 6px 18px; }
/* stacked cards in the 3-up grid */
.more__grid .product { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr; }
.more__grid .product__shot { border-right: 0; border-bottom: 1px solid var(--line); }
.more__grid .product__shot img { height: 210px; max-height: none; }
