/* tempergraph site. One stylesheet for every page; colours are tokens, redefined for dark mode.
   The temper colours (straw, bronze, purple, blue) come from the logo; text never wears them raw on light surfaces. */

:root {
  --straw: #E3B04B;
  --bronze: #C9773A;
  --purple: #8A5CB0;
  --blue: #4A7FC1;
  --ember: #E5602D;
  --steel: #7D8EA0;

  --bg: #f7f6f2;
  --bg-2: #efede7;
  --surface: #ffffff;
  --ink: #15171c;
  --ink-2: #555b66;
  --ink-3: #7c828c;
  --line: #e2dfd7;
  --line-2: #cfcbc1;
  --code-bg: #f1efe9;

  /* Accents dark enough to be text on the light surface. */
  --a-straw: #8a6410;
  --a-bronze: #a2531c;
  --a-purple: #6c3f98;
  --a-blue: #2b5f9f;

  /* Tints for diagram boxes. */
  --t-straw: #fbf1db;
  --t-bronze: #f8e7da;
  --t-purple: #eee5f6;
  --t-blue: #e3ecf8;
  --t-steel: #eceff3;

  --hero-bg: #0f1116;
  --hero-ink: #f1f2f5;
  --hero-ink-2: #b4bac5;

  --radius: 14px;
  --radius-lg: 22px;
  --shadow: 0 1px 2px rgba(20, 22, 28, .05), 0 8px 24px rgba(20, 22, 28, .06);
  --maxw: 1120px;
  --gutter: clamp(16px, 4vw, 32px);

  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;

  --bands: linear-gradient(90deg, var(--straw) 0 25%, var(--bronze) 25% 50%, var(--purple) 50% 75%, var(--blue) 75% 100%);
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e1014;
    --bg-2: #13161b;
    --surface: #171a20;
    --ink: #eceef2;
    --ink-2: #a5acb8;
    --ink-3: #7d8491;
    --line: #272b33;
    --line-2: #363b45;
    --code-bg: #12151a;
    --a-straw: #e8bd62;
    --a-bronze: #e09a66;
    --a-purple: #b996e0;
    --a-blue: #7fa9e0;
    --t-straw: #2a2316;
    --t-bronze: #2b1f17;
    --t-purple: #241d2e;
    --t-blue: #18222f;
    --t-steel: #1d2128;
    --hero-bg: #08090c;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #0e1014;
  --bg-2: #13161b;
  --surface: #171a20;
  --ink: #eceef2;
  --ink-2: #a5acb8;
  --ink-3: #7d8491;
  --line: #272b33;
  --line-2: #363b45;
  --code-bg: #12151a;
  --a-straw: #e8bd62;
  --a-bronze: #e09a66;
  --a-purple: #b996e0;
  --a-blue: #7fa9e0;
  --t-straw: #2a2316;
  --t-bronze: #2b1f17;
  --t-purple: #241d2e;
  --t-blue: #18222f;
  --t-steel: #1d2128;
  --hero-bg: #08090c;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25);
  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; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.6 var(--sans);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { max-width: 100%; height: auto; }
a { color: var(--a-blue); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; border-radius: 4px; }
code, pre, kbd { font-family: var(--mono); font-size: .88em; }
:not(pre) > code { background: var(--code-bg); border: 1px solid var(--line); border-radius: 6px; padding: .08em .36em; overflow-wrap: anywhere; }
h1, h2, h3, h4 { line-height: 1.15; letter-spacing: -.02em; margin: 0 0 .5em; }
h2 { font-size: clamp(28px, 4vw, 42px); font-weight: 750; }
h3 { font-size: 20px; font-weight: 700; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--surface); color: var(--ink); padding: 8px 14px; border-radius: 8px; box-shadow: var(--shadow); }
.skip:focus { top: 12px; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--hero-bg) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, .07);
  color: var(--hero-ink);
}
.site-header::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--bands); opacity: .9; }
.nav { display: flex; align-items: center; gap: 16px; height: 60px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; font-weight: 750; letter-spacing: -.01em; font-size: 18px; white-space: nowrap; }
.brand img { width: 30px; height: 30px; }
.brand .sub { color: var(--hero-ink-2); font-weight: 500; }
.nav-links { display: flex; gap: 4px; margin-left: auto; align-items: center; }
.nav-links a { color: var(--hero-ink-2); text-decoration: none; font-size: 15px; padding: 6px 10px; border-radius: 8px; white-space: nowrap; }
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--hero-ink); background: rgba(255, 255, 255, .07); }
.nav-links .gh { color: var(--hero-ink); display: inline-flex; gap: 6px; align-items: center; padding: 6px 8px; }
.nav-links .gh span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.nav-links .gh svg { width: 19px; height: 19px; }
.nav-links .cta { color: var(--hero-bg); background: var(--hero-ink); font-weight: 650; margin-left: 6px; }
.nav-links .cta:hover { color: var(--hero-bg); background: var(--straw); }
.theme-toggle, .menu-toggle { background: none; border: 1px solid rgba(255, 255, 255, .16); color: var(--hero-ink); width: 36px; height: 36px; border-radius: 8px; cursor: pointer; display: grid; place-items: center; flex: none; }
.theme-toggle svg, .menu-toggle svg { width: 18px; height: 18px; }
.menu-toggle { display: none; }
.menu-toggle .m-close { display: none; }
.menu-open .menu-toggle .m-open { display: none; }
.menu-open .menu-toggle .m-close { display: inline; }
/* Phones: the links fold into a panel under the header; without scripting they wrap onto a second row. */
@media (max-width: 760px) {
  .nav { flex-wrap: wrap; height: auto; min-height: 60px; gap: 10px; padding-top: 8px; padding-bottom: 8px; }
  .nav-links { order: 3; width: 100%; flex-wrap: wrap; margin-left: 0; }
  .js .menu-toggle { display: grid; margin-left: auto; }
  .js .nav-links { display: none; flex-direction: column; align-items: stretch; gap: 2px; padding: 6px 0 10px; }
  .js .menu-open .nav-links { display: flex; }
  .js .nav-links a { font-size: 17px; padding: 12px 10px; }
  .js .nav-links .gh span { position: static; width: auto; height: auto; clip: auto; }
  .js .nav-links .cta { margin: 6px 0 0; text-align: center; }
}

/* Hero */
.hero {
  position: relative; overflow: hidden;
  background: var(--hero-bg); color: var(--hero-ink);
  padding: clamp(56px, 9vw, 112px) 0 clamp(56px, 8vw, 96px);
  isolation: isolate;
}
.hero::before {
  content: ""; position: absolute; inset: -40% -10% auto auto; width: 900px; height: 900px; z-index: -1;
  background: radial-gradient(closest-side, rgba(229, 96, 45, .22), rgba(138, 92, 176, .12) 55%, transparent 72%);
  filter: blur(10px);
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: .35;
  background-image: linear-gradient(rgba(255, 255, 255, .045) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse at 70% 30%, #000 20%, transparent 70%);
  -webkit-mask-image: radial-gradient(ellipse at 70% 30%, #000 20%, transparent 70%);
}
.hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }
.eyebrow { display: inline-flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.pill { font-size: 13px; font-weight: 600; letter-spacing: .02em; padding: 4px 11px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .16); color: var(--hero-ink-2); background: rgba(255, 255, 255, .04); }
.pill.hot { color: #ffd9a8; border-color: rgba(227, 176, 75, .45); background: rgba(227, 176, 75, .08); }
.hero h1 { font-size: clamp(40px, 6.4vw, 72px); font-weight: 800; letter-spacing: -.035em; line-height: 1.02; margin-bottom: 22px; }
.temper-text {
  background: linear-gradient(90deg, var(--straw), var(--bronze) 35%, #b07fd8 65%, #6fa0e0);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero .lede { font-size: clamp(18px, 2vw, 21px); color: var(--hero-ink-2); max-width: 36em; margin-bottom: 30px; }
.hero .lede strong { color: var(--hero-ink); font-weight: 600; }
.ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 20px; border-radius: 11px; font-weight: 650; font-size: 16px; text-decoration: none; border: 1px solid transparent; transition: transform .15s ease, background .15s ease; }
.btn:hover { transform: translateY(-1px); text-decoration: none; }
.btn-primary { background: linear-gradient(135deg, var(--straw), var(--bronze)); color: #1a1208; }
.btn-ghost { color: var(--hero-ink); border-color: rgba(255, 255, 255, .2); background: rgba(255, 255, 255, .04); }
.btn-ghost:hover { background: rgba(255, 255, 255, .09); }
.btn-dark { background: var(--ink); color: var(--bg); }
.btn-line { border-color: var(--line-2); color: var(--ink); background: var(--surface); }
.hero-note { margin-top: 26px; font-size: 14px; color: var(--hero-ink-2); max-width: 40em; }
.hero-note a { color: #9fc0ec; }

.hero-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .02));
  border: 1px solid rgba(255, 255, 255, .1); border-radius: var(--radius-lg);
  padding: 18px; box-shadow: 0 30px 80px rgba(0, 0, 0, .45);
}
.hero-card svg { display: block; width: 100%; }
.hero-card .cap { font-size: 13px; color: var(--hero-ink-2); margin: 10px 4px 0; }

/* Sections */
section { padding: clamp(64px, 9vw, 112px) 0; }
section.alt { background: var(--bg-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.kicker { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--a-bronze); margin-bottom: 14px; }
.kicker::before { content: ""; width: 28px; height: 3px; border-radius: 2px; background: var(--bands); }
.section-head { max-width: 780px; margin-bottom: clamp(32px, 5vw, 52px); }
.section-head p { font-size: 19px; color: var(--ink-2); }
.center { text-align: center; margin-left: auto; margin-right: auto; }

.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 960px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .g2, .g3, .g4 { grid-template-columns: 1fr; } }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); min-width: 0; }
.card h3 { margin-bottom: 8px; }
.card p:last-child, .card ul:last-child { margin-bottom: 0; }
.card p, .card li { color: var(--ink-2); font-size: 16px; }
.card .icon { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; margin-bottom: 14px; font-weight: 800; font-size: 17px; }
.i-straw { background: var(--t-straw); color: var(--a-straw); }
.i-bronze { background: var(--t-bronze); color: var(--a-bronze); }
.i-purple { background: var(--t-purple); color: var(--a-purple); }
.i-blue { background: var(--t-blue); color: var(--a-blue); }
.i-steel { background: var(--t-steel); color: var(--ink-2); }
.card.bad { border-top: 3px solid var(--ember); }
.card.good { border-top: 3px solid var(--blue); }
.card.feature { border-top: 3px solid transparent; border-image: var(--bands) 1; border-image-slice: 1 0 0 0; }

ul.ticks { list-style: none; padding: 0; margin: 0 0 1em; }
ul.ticks li { position: relative; padding-left: 26px; margin-bottom: 8px; }
ul.ticks li::before { content: ""; position: absolute; left: 2px; top: .52em; width: 12px; height: 7px; border-left: 2.5px solid var(--blue); border-bottom: 2.5px solid var(--blue); transform: rotate(-45deg); }
ul.crosses li::before { border: 0; width: 12px; height: 12px; top: .42em; transform: none; background: linear-gradient(45deg, transparent 43%, var(--ember) 43% 57%, transparent 57%), linear-gradient(-45deg, transparent 43%, var(--ember) 43% 57%, transparent 57%); }
.cmds { margin-top: 14px; display: flex; flex-wrap: wrap; gap: 6px; }
.cmds code { font-size: 12.5px; }

.principles { counter-reset: p; }
.principle { position: relative; padding-top: 58px; }
.principle::before { counter-increment: p; content: "0" counter(p); position: absolute; top: 20px; left: 24px; font: 800 28px/1 var(--sans); letter-spacing: -.03em; background: var(--bands); -webkit-background-clip: text; background-clip: text; color: transparent; }

.callout { display: grid; grid-template-columns: auto 1fr; gap: 16px; align-items: start; background: var(--t-straw); border: 1px solid color-mix(in srgb, var(--straw) 45%, transparent); border-radius: var(--radius); padding: 18px 20px; color: var(--ink); }
.callout .mark { width: 26px; height: 26px; border-radius: 50%; background: var(--straw); color: #1a1208; display: grid; place-items: center; font-weight: 800; font-size: 15px; }
.callout p { margin: 0; color: var(--ink); font-size: 16px; }

.quote { font-size: clamp(22px, 3vw, 30px); font-weight: 650; letter-spacing: -.02em; line-height: 1.3; max-width: 860px; }
.quote .dim { color: var(--ink-3); }

/* Figures */
figure { margin: 0; }
.figure { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: clamp(14px, 3vw, 28px); box-shadow: var(--shadow); overflow: hidden; }
.figure + .figure { margin-top: 18px; }
figcaption { font-size: 14px; color: var(--ink-3); margin-top: 14px; }
.split { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(24px, 4vw, 48px); align-items: center; }
.split.rev { grid-template-columns: .9fr 1.1fr; }
@media (max-width: 900px) { .split, .split.rev { grid-template-columns: 1fr; } }
.scroll-x { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.scroll-x > svg { min-width: 680px; }
.theme-img-dark { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .theme-img-light { display: none; } :root:not([data-theme="light"]) .theme-img-dark { display: block; } }
:root[data-theme="dark"] .theme-img-light { display: none; }
:root[data-theme="dark"] .theme-img-dark { display: block; }
.only-wide { display: block; }
.only-narrow { display: none; }
@media (max-width: 700px) { .only-wide { display: none; } .only-narrow { display: block; } }

/* Diagram vocabulary (inline SVG). */
.dg text { font-family: var(--sans); fill: var(--ink); }
.dg .t { font-size: 14px; font-weight: 650; }
.dg .ts { font-size: 12.5px; fill: var(--ink-2); font-weight: 450; }
.dg .tl { font-size: 11.5px; font-weight: 750; letter-spacing: .12em; fill: var(--ink-2); }
.dg .tm { font-family: var(--mono); font-size: 12px; fill: var(--ink-2); }
.dg .box { fill: var(--surface); stroke: var(--line-2); stroke-width: 1.2; }
.dg .b-straw { fill: var(--t-straw); stroke: color-mix(in srgb, var(--straw) 70%, transparent); stroke-width: 1.2; }
.dg .b-bronze { fill: var(--t-bronze); stroke: color-mix(in srgb, var(--bronze) 70%, transparent); stroke-width: 1.2; }
.dg .b-purple { fill: var(--t-purple); stroke: color-mix(in srgb, var(--purple) 70%, transparent); stroke-width: 1.2; }
.dg .b-blue { fill: var(--t-blue); stroke: color-mix(in srgb, var(--blue) 70%, transparent); stroke-width: 1.2; }
.dg .b-steel { fill: var(--t-steel); stroke: var(--line-2); stroke-width: 1.2; }
.dg .band { fill: none; stroke-width: 1.4; stroke-dasharray: none; }
.dg .bd-straw { stroke: var(--straw); fill: color-mix(in srgb, var(--t-straw) 55%, transparent); }
.dg .bd-purple { stroke: var(--purple); fill: color-mix(in srgb, var(--t-purple) 70%, transparent); }
.dg .bd-blue { stroke: var(--blue); fill: color-mix(in srgb, var(--t-blue) 70%, transparent); }
.dg .bd-bronze { stroke: var(--bronze); fill: color-mix(in srgb, var(--t-bronze) 70%, transparent); }
.dg .dash { stroke-dasharray: 5 4; }
.dg .ln { fill: none; stroke: var(--ink-3); stroke-width: 1.6; }
.dg .ln.back { stroke: var(--a-bronze); stroke-dasharray: 5 4; }
.dg .ln.pause { stroke: var(--a-purple); }
.dg .ln.loop { stroke: var(--a-straw); }
.dg .ln.ok { stroke: var(--a-blue); }
.dg .ah { fill: var(--ink-3); }
.dg .ah-back { fill: var(--a-bronze); }
.dg .ah-pause { fill: var(--a-purple); }
.dg .ah-loop { fill: var(--a-straw); }
.dg .ah-ok { fill: var(--a-blue); }
.dg .gate { fill: var(--straw); stroke: color-mix(in srgb, var(--bronze) 70%, transparent); stroke-width: 1; }
.dg .term { fill: var(--ink); }
.dg .term-t { fill: var(--bg); font-size: 13.5px; font-weight: 700; }
.dg .chip-t { font-size: 12px; font-weight: 650; }
.dg .dot { fill: var(--ember); }
.dg .pulse { animation: pulse 2.4s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes pulse { 0%, 100% { opacity: .35; } 50% { opacity: 1; } }

/* Hero diagram (always on the dark hero). */
.hd text { font-family: var(--sans); fill: #eef0f4; }
.hd .t { font-size: 15px; font-weight: 700; }
.hd .ts { font-size: 12.5px; fill: #aab1bd; }
.hd .tl { font-size: 11px; font-weight: 750; letter-spacing: .14em; fill: #8c94a1; }
.hd .node { fill: rgba(255, 255, 255, .05); stroke: rgba(255, 255, 255, .16); stroke-width: 1.2; }
.hd .n-step { stroke: var(--bronze); fill: rgba(201, 119, 58, .12); }
.hd .n-check { stroke: var(--blue); fill: rgba(74, 127, 193, .14); }
.hd .n-judge { stroke: var(--purple); fill: rgba(138, 92, 176, .16); }
.hd .gate { fill: var(--straw); }
.hd .ln { fill: none; stroke: rgba(255, 255, 255, .35); stroke-width: 1.6; }
.hd .ln.back { stroke: var(--bronze); stroke-dasharray: 5 4; }
.hd .ln.retry { stroke: var(--straw); stroke-dasharray: 5 4; }
.hd .ln.pause { stroke: #b48ce0; }
.hd .ah { fill: rgba(255, 255, 255, .5); }
.hd .ah-back { fill: var(--bronze); }
.hd .ah-retry { fill: var(--straw); }
.hd .ah-pause { fill: #b48ce0; }
.hd .spark { fill: var(--ember); filter: drop-shadow(0 0 6px rgba(229, 96, 45, .9)); }
.hd .term { fill: #eef0f4; }
.hd .term-t { fill: #111; font-weight: 750; font-size: 13px; }

/* Bars (one series, direct labels). */
.bars { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.bars li { display: grid; grid-template-columns: minmax(96px, 9.5em) 1fr auto; gap: 12px; align-items: center; font-size: 15px; }
.bars .lab { color: var(--ink-2); }
.bars .track { display: block; height: 12px; background: var(--bg-2); border-radius: 0 4px 4px 0; overflow: hidden; }
.bars .fill { display: block; height: 100%; background: var(--blue); border-radius: 0 4px 4px 0; }
.bars .val { font-variant-numeric: tabular-nums; font-weight: 650; min-width: 4.5em; text-align: right; }
.bars.bronze .fill { background: var(--bronze); }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
@media (max-width: 860px) { .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.stat { background: var(--surface); padding: 24px 22px; min-width: 0; }
.stat .num { font-size: clamp(30px, 4vw, 42px); font-weight: 800; letter-spacing: -.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.stat .num small { font-size: .5em; font-weight: 700; color: var(--ink-3); letter-spacing: 0; }
.stat .what { margin-top: 10px; color: var(--ink-2); font-size: 15px; line-height: 1.45; }
.source { font-size: 13.5px; color: var(--ink-3); margin-top: 16px; }
.source code { font-size: 12px; }

/* Status table */
.status { width: 100%; border-collapse: collapse; font-size: 15.5px; }
.status th, .status td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.status th { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: var(--ink-3); font-weight: 700; }
.status td:first-child { font-weight: 650; white-space: nowrap; }
.tag { display: inline-block; font-size: 12.5px; font-weight: 700; padding: 2px 9px; border-radius: 999px; white-space: nowrap; }
.tag.built { background: var(--t-blue); color: var(--a-blue); }
.tag.prog { background: var(--t-straw); color: var(--a-straw); }
.tag.designed { background: var(--t-purple); color: var(--a-purple); }
.tag.measured { background: var(--t-bronze); color: var(--a-bronze); }
.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }

/* Code */
.code { position: relative; background: #0f1218; color: #e6e8ee; border-radius: var(--radius); border: 1px solid #222733; overflow: hidden; min-width: 0; }
.code .bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 12px 8px 16px; background: #151924; border-bottom: 1px solid #222733; font: 600 12.5px var(--mono); color: #9aa3b2; }
.code pre { margin: 0; padding: 16px; overflow-x: auto; font-size: 13.5px; line-height: 1.6; }
.code .copy { background: transparent; color: #9aa3b2; border: 1px solid #2c3242; border-radius: 7px; font: 600 12px var(--sans); padding: 4px 10px; cursor: pointer; }
.code .copy:hover { color: #fff; border-color: #48506a; }
.code .c { color: #7d8799; }
.code .k { color: #c9a0f0; }
.code .s { color: #e8c07a; }
.code .p { color: #79b0ec; }
.code .n { color: #f09a6a; }

.steps { counter-reset: s; display: grid; gap: 18px; }
.step-row { display: grid; grid-template-columns: 52px 1fr; gap: 18px; align-items: start; }
.step-row::before { counter-increment: s; content: counter(s); width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-weight: 800; font-size: 18px; color: #1a1208; background: linear-gradient(135deg, var(--straw), var(--bronze)); }
.step-row h3 { margin-top: 8px; }
.step-row > div { min-width: 0; }
.prompt { border-left: 3px solid var(--purple); background: var(--t-purple); padding: 10px 14px; border-radius: 0 10px 10px 0; color: var(--ink); font-size: 16px; margin: 10px 0 12px; }

/* Roadmap */
.timeline { position: relative; display: grid; gap: 18px; }
.timeline .card { display: grid; grid-template-columns: 170px 1fr; gap: 18px; }
@media (max-width: 640px) { .timeline .card { grid-template-columns: 1fr; gap: 6px; } }
.timeline h3 { margin: 0; }

/* Story: founder note, journey, latest posts. */
.founder { margin: 0; display: flex; flex-direction: column; justify-content: space-between; gap: 18px; }
.founder blockquote { margin: 0; }
.founder blockquote p { font-size: 17px; color: var(--ink); line-height: 1.6; }
.founder h3 { margin: 4px 0 0; font-size: 22px; }
.author-card { display: flex; align-items: center; gap: 16px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.author-card > div { display: grid; gap: 2px; min-width: 0; }
.author-card strong { font-size: 17px; color: var(--ink); }
.author-card span { color: var(--ink-3); font-size: 14px; }
.author-links a { font-size: 14px; }
.avatar { flex: none; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 3px var(--surface), 0 0 0 5px var(--bronze); background: var(--t-bronze); color: var(--a-bronze); display: inline-grid; place-items: center; font-weight: 750; font-size: 22px; letter-spacing: .02em; }
.avatar.bot { box-shadow: 0 0 0 2px var(--line-2); background: var(--hero-bg); padding: 4px; }
.byline .avatar { font-size: 14px; box-shadow: 0 0 0 2px var(--hero-bg), 0 0 0 4px var(--bronze); }
.journey { list-style: none; margin: 0; padding: 0 0 0 22px; position: relative; display: grid; gap: 16px; align-content: start; }
.journey::before { content: ""; position: absolute; left: 5px; top: 6px; bottom: 6px; width: 3px; border-radius: 2px; background: linear-gradient(var(--straw), var(--bronze), var(--purple), var(--blue)); }
.journey li { position: relative; display: grid; gap: 2px; }
.journey li::before { content: ""; position: absolute; left: -22px; top: 6px; width: 13px; height: 13px; border-radius: 50%; background: var(--surface); border: 3px solid var(--a-bronze); }
.journey time { font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--a-bronze); }
.journey span { color: var(--ink-2); }
.latest { margin-top: 48px; }
.latest-head { display: flex; align-items: baseline; gap: 16px; margin-bottom: 12px; }
.latest-head h3 { margin: 0 auto 0 0; }

/* Blog */
.page-hero { padding: clamp(40px, 7vw, 80px) 0 clamp(36px, 6vw, 64px); }
.page-hero h1 { font-size: clamp(32px, 5vw, 52px); }
.page-hero .lede { margin-bottom: 14px; }
.page-hero .crumbs, .page-hero .post-meta { color: var(--hero-ink-2); font-size: 15px; margin: 0 0 14px; }
.page-hero a { color: var(--hero-ink); }
.wrap.narrow { max-width: 820px; }
.post-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; margin-top: 22px; }
.page-hero .post-head .post-meta { margin: 0; }
.byline { display: flex; align-items: center; gap: 12px; }
.byline > div { display: grid; gap: 0; line-height: 1.35; }
.byline strong { color: var(--hero-ink); font-size: 15.5px; }
.byline strong a { color: inherit; text-decoration: none; }
.byline .by-role { color: var(--hero-ink-2); font-size: 13.5px; }
.tag.auto { background: rgba(255, 255, 255, .1); color: var(--hero-ink); font-size: 11.5px; vertical-align: 1px; margin-left: 4px; }
.tag.release { background: var(--t-blue); color: var(--a-blue); }
.tag.article { background: var(--t-bronze); color: var(--a-bronze); }
.post-tags .tag { background: var(--bg-2); color: var(--ink-2); margin: 0 6px 6px 0; font-weight: 600; }
.featured { display: grid; gap: 8px; padding: clamp(22px, 4vw, 34px); margin-bottom: 28px; border-radius: var(--radius-lg); background: var(--hero-bg); color: var(--hero-ink); text-decoration: none; position: relative; overflow: hidden; isolation: isolate; }
.featured::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: var(--bands); }
.featured::after { content: ""; position: absolute; inset: auto -15% -70% auto; width: 460px; height: 460px; z-index: -1; background: radial-gradient(closest-side, rgba(227, 176, 75, .22), transparent 70%); }
.featured strong { font-size: clamp(22px, 3.2vw, 30px); line-height: 1.2; }
.featured > span { color: var(--hero-ink-2); }
.featured .post-meta { color: var(--hero-ink-2); }
.featured .more { color: var(--straw); font-weight: 650; }
.post-filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 8px; }
.post-filter[hidden] { display: none; }
.post-filter button { font: inherit; font-size: 14.5px; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink-2); cursor: pointer; }
.post-filter button span { color: var(--ink-3); margin-left: 4px; }
.post-filter button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.post-filter button[aria-pressed="true"] span { color: inherit; opacity: .7; }
.post-year h2 { font-size: 15px; letter-spacing: .08em; color: var(--ink-3); margin: 28px 0 10px; }
.post-year[hidden], .post-row[hidden] { display: none; }
.post-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.post-row > a { display: grid; grid-template-columns: 64px 1fr; gap: 16px; padding: 18px 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); color: inherit; text-decoration: none; box-shadow: var(--shadow); }
.post-row > a:hover { border-color: var(--line-2); }
.post-row time { font: 700 12.5px var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); padding-top: 3px; }
.post-body { display: grid; gap: 4px; min-width: 0; }
.post-row strong { font-size: 18px; color: var(--ink); }
.post-body > span { color: var(--ink-2); font-size: 15.5px; }
.post-row .post-meta, .post-meta { font-size: 13px; color: var(--ink-3); letter-spacing: .02em; }
@media (max-width: 560px) {
  .post-row > a { grid-template-columns: 1fr; gap: 6px; padding: 16px; }
}
.toc { margin: 0 0 32px; padding: 16px 20px; border: 1px solid var(--line); border-left: 3px solid var(--bronze); border-radius: 10px; background: var(--surface); font-size: 15px; }
.toc strong { display: block; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 6px; }
.toc ol { margin: 0; padding-left: 20px; }
.toc li { margin: 2px 0; }
.upgrade { margin: 0 0 28px; padding: 16px 20px; border-radius: 10px; background: var(--t-blue); }
.upgrade p { margin: 0; color: var(--ink); font-size: 16px; }
.upgrade pre { margin: 10px 0 0; padding: 10px 14px; border-radius: 8px; background: var(--hero-bg); color: var(--hero-ink); overflow-x: auto; }
.callout { margin: 0 0 28px; padding: 4px 20px 8px; border-radius: 10px; background: var(--t-straw); }
.prose .callout h2 { font-size: 18px; margin: 14px 0 6px; }
.for-you { font-size: 15.5px; }
.for-you > span { display: inline-block; font-size: 12px; font-weight: 750; letter-spacing: .05em; text-transform: uppercase; color: var(--a-bronze); margin-right: 6px; }
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 28px 0 8px; }
.post-nav a { display: grid; gap: 2px; padding: 14px 18px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); text-decoration: none; color: var(--ink); font-weight: 600; font-size: 15.5px; }
.post-nav a span { font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.post-nav a:last-child { text-align: right; }
@media (max-width: 560px) { .post-nav { grid-template-columns: 1fr; } .post-nav a:last-child { text-align: left; } }
.page-index { border-bottom: 1px solid var(--line); background: var(--bg-2); }
.page-index .wrap { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; padding-top: 8px; padding-bottom: 8px; }
.page-index .wrap::-webkit-scrollbar { display: none; }
.page-index a { flex: none; padding: 6px 12px; border-radius: 999px; color: var(--ink-2); text-decoration: none; font-size: 14.5px; white-space: nowrap; }
.page-index a:hover { background: var(--surface); color: var(--ink); }
.prose { font-size: 17.5px; line-height: 1.7; }
.prose h2 { font-size: clamp(24px, 3vw, 30px); margin: 40px 0 12px; }
.prose h3 { font-size: 17px; margin: 26px 0 6px; overflow-wrap: anywhere; }
.prose p, .prose li { color: var(--ink-2); }
.prose ul { padding-left: 22px; }
.prose li { margin-bottom: 6px; }
.prose .bars { margin: 18px 0; padding: 0; }
.prose .note, .note { font-size: 14.5px; color: var(--ink-3); }
.prose code { overflow-wrap: anywhere; }

/* Promo band (to the temperspec section and back). */
.promo { position: relative; overflow: hidden; border-radius: var(--radius-lg); background: var(--hero-bg); color: var(--hero-ink); padding: clamp(28px, 5vw, 56px); display: grid; grid-template-columns: 1.3fr .7fr; gap: 28px; align-items: center; isolation: isolate; }
.promo::before { content: ""; position: absolute; inset: auto -20% -60% auto; width: 600px; height: 600px; z-index: -1; background: radial-gradient(closest-side, rgba(74, 127, 193, .3), transparent 70%); }
.promo p { color: var(--hero-ink-2); font-size: 18px; }
.promo h2 { color: var(--hero-ink); }
.promo .kicker { color: #e8bd62; }
@media (max-width: 800px) { .promo { grid-template-columns: 1fr; } }

/* Footer */
.site-footer { background: var(--hero-bg); color: var(--hero-ink-2); padding: 48px 0 40px; font-size: 15px; position: relative; }
.site-footer::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 3px; background: var(--bands); }
.foot { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 28px; }
@media (max-width: 760px) { .foot { grid-template-columns: 1fr 1fr; } }
.site-footer h4 { color: var(--hero-ink); font-size: 14px; letter-spacing: .06em; text-transform: uppercase; margin-bottom: 12px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.site-footer a { color: var(--hero-ink-2); text-decoration: none; }
.site-footer a:hover { color: var(--hero-ink); text-decoration: underline; }
.fine { margin-top: 32px; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, .08); font-size: 13.5px; display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: space-between; }

/* Reveal on scroll, only when scripting is on. */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s ease; }
.js .reveal.in { opacity: 1; transform: none; }
@media print { .js .reveal { opacity: 1; transform: none; } .site-header { position: static; } }
@media (prefers-reduced-motion: reduce) { .hd .spark { display: none; } }
.hero :not(pre) > code, .promo :not(pre) > code { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .14); color: var(--hero-ink); }

/* Docs: sidebar, article, on-this-page list; one column on phones */
.doc-main { padding: 28px 0 56px; }
.doc-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr) 200px; gap: 40px; align-items: start; }
.doc-side, .doc-aside { position: sticky; top: 84px; max-height: calc(100vh - 100px); overflow-y: auto; font-size: 14.5px; }
.doc-article { min-width: 0; }
.doc-article > h1 { font-size: clamp(30px, 4.4vw, 44px); font-weight: 800; letter-spacing: -.03em; margin: 0 0 18px; overflow-wrap: anywhere; }
.doc-article .crumbs { font-size: 14px; color: var(--ink-3); margin: 0 0 8px; }
.doc-article h2, .doc-article h3, .doc-article h4 { scroll-margin-top: 80px; }
.doc-article h4 { font-size: 16px; margin: 22px 0 6px; }
.doc-article .code { margin: 14px 0 18px; }
.doc-article blockquote { margin: 16px 0; padding: 4px 16px; border-left: 3px solid var(--line-2); }
.doc-article ol { padding-left: 22px; }
.anchor { margin-left: .35em; color: var(--ink-3); text-decoration: none; opacity: 0; font-weight: 500; }
h2:hover > .anchor, h3:hover > .anchor, h4:hover > .anchor, .anchor:focus { opacity: 1; }
.lede-doc { font-size: 19px; color: var(--ink) !important; }
.doc-source { margin-top: 20px; }
.table-scroll { overflow-x: auto; margin: 14px 0 22px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.table-scroll table { border-collapse: collapse; width: 100%; font-size: 15px; }
.table-scroll th, .table-scroll td { text-align: left; vertical-align: top; padding: 9px 14px; border-bottom: 1px solid var(--line); color: var(--ink-2); }
.table-scroll tr:last-child td { border-bottom: 0; }
.table-scroll th { font-size: 13px; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-3); background: var(--bg-2); }
table.args td:first-child, table.verbs td:first-child { white-space: nowrap; width: 1%; }
table.args td:first-child code { overflow-wrap: normal; }
.arg-note { display: block; margin-top: 2px; font-size: 13px; color: var(--ink-3); }
.doc-nav-wrap > summary { display: none; }
.doc-nav ul { list-style: none; margin: 0 0 10px; padding: 0; }
.doc-nav li a { display: block; padding: 4px 10px; border-radius: 7px; color: var(--ink-2); text-decoration: none; }
.doc-nav li a:hover { color: var(--ink); background: var(--bg-2); }
.doc-nav li a[aria-current="page"] { color: var(--ink); background: var(--t-bronze); font-weight: 650; box-shadow: inset 3px 0 0 var(--bronze); }
.doc-nav li code { background: none; border: 0; padding: 0; font-size: 13.5px; }
.doc-nav-title, .doc-nav summary, .doc-toc strong { display: block; margin: 16px 0 6px; font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.doc-nav details summary { cursor: pointer; margin: 8px 0 4px; padding-left: 10px; text-transform: none; letter-spacing: 0; font-size: 14px; color: var(--ink-2); font-weight: 650; }
.doc-toc ul { list-style: none; margin: 0; padding: 0 0 0 10px; border-left: 1px solid var(--line); }
.doc-toc li { margin: 4px 0; }
.doc-toc li.l3 { padding-left: 12px; font-size: 13.5px; }
.doc-toc a { color: var(--ink-2); text-decoration: none; }
.doc-toc a:hover { color: var(--ink); }
.doc-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 20px 0 24px; }
.doc-card { display: grid; gap: 6px; align-content: start; padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); text-decoration: none; color: var(--ink); }
.doc-card:hover { border-color: var(--bronze); }
.doc-card span { font-size: 15px; color: var(--ink-2); }
.doc-search { position: relative; margin: 0 0 8px; }
.doc-search input { width: 100%; box-sizing: border-box; padding: 9px 34px 9px 12px; border: 1px solid var(--line-2); border-radius: 9px; background: var(--surface); color: var(--ink); font: 15px var(--sans); }
.doc-search kbd { position: absolute; right: 9px; top: 8px; padding: 0 6px; border: 1px solid var(--line-2); border-radius: 5px; color: var(--ink-3); font-size: 12px; line-height: 20px; }
.doc-results { position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 6px); max-height: 60vh; overflow-y: auto; margin: 0; padding: 6px; list-style: none; background: var(--surface); border: 1px solid var(--line-2); border-radius: 10px; box-shadow: var(--shadow); }
.doc-results a { display: block; padding: 8px 10px; border-radius: 7px; color: var(--ink); text-decoration: none; }
.doc-results a span { display: block; font-size: 13px; color: var(--ink-3); }
.doc-results a:hover, .doc-results a[aria-selected="true"] { background: var(--t-bronze); }
.doc-results .none { padding: 8px 10px; color: var(--ink-3); }
@media (max-width: 1100px) { .doc-layout { grid-template-columns: 220px minmax(0, 1fr); } .doc-aside { display: none; } }
@media (max-width: 820px) {
  .doc-layout { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .doc-side { position: static; max-height: none; overflow: visible; }
  .doc-nav-wrap { border: 1px solid var(--line); border-radius: 10px; background: var(--surface); padding: 0 12px; }
  .doc-nav-wrap > summary { display: block; cursor: pointer; padding: 10px 0; font-weight: 650; color: var(--ink); }
  .doc-cards { grid-template-columns: 1fr; }
}
@media (min-width: 1101px) { .doc-layout:has(.doc-aside:empty) { grid-template-columns: 240px minmax(0, 860px); } .doc-aside:empty { display: none; } }
