/* Inverse Scaled Intelligence — site stylesheet
   Identity: "inverse scale" — the smallest thing on the page (the answer) is set the largest.
   Paper & ink, one signal colour, an editorial grid with margin notes. */

:root {
  --paper: #F3F0E8;
  --paper-2: #EAE6DB;
  --paper-3: #E1DCCF;
  --ink: #151513;
  --ink-2: #4F4D46;
  --ink-3: #85827A;
  --rule: #D6D1C4;
  --rule-strong: #151513;
  --signal: #E5461A;        /* cadmium */
  --signal-text: #B5370E;   /* cadmium, AA on paper */
  --correct: #1D7550;       /* viridian */
  --wrong: #A0281F;         /* oxide */
  --selection: rgba(229, 70, 26, .18);

  --serif: "Newsreader", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --gutter: clamp(16px, 4vw, 56px);
  --maxw: 1320px;
  --section: clamp(80px, 11vw, 168px);
  --ease: cubic-bezier(.2, .7, .1, 1);

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #121210; --paper-2: #1A1A17; --paper-3: #23221E;
    --ink: #ECE7DA; --ink-2: #B3AFA3; --ink-3: #7E7B71;
    --rule: #2D2C27; --rule-strong: #ECE7DA;
    --signal: #FF6433; --signal-text: #FF7A4D;
    --correct: #5CBF8F; --wrong: #FF7F70;
    --selection: rgba(255, 100, 51, .28);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #121210; --paper-2: #1A1A17; --paper-3: #23221E;
  --ink: #ECE7DA; --ink-2: #B3AFA3; --ink-3: #7E7B71;
  --rule: #2D2C27; --rule-strong: #ECE7DA;
  --signal: #FF6433; --signal-text: #FF7A4D;
  --correct: #5CBF8F; --wrong: #FF7F70;
  --selection: rgba(255, 100, 51, .28);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 88px; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.1875rem;
  line-height: 1.5;
  font-optical-sizing: auto;
  font-kerning: normal;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
::selection { background: var(--selection); }
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { text-decoration-color: var(--signal); }
:focus-visible { outline: 2px solid var(--signal); outline-offset: 3px; border-radius: 1px; }
button { font: inherit; color: inherit; }
p { margin: 0 0 1em; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; letter-spacing: -0.015em; line-height: 1.08; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: var(--gutter); top: -60px; background: var(--ink); color: var(--paper); padding: 8px 12px; z-index: 50; font-family: var(--mono); font-size: .8125rem; }
.skip:focus { top: 12px; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.mono { font-family: var(--mono); }
.num { font-variant-numeric: lining-nums tabular-nums; }

/* ---------------------------------------------------------------- header */
.site-head { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: saturate(1.2) blur(8px); -webkit-backdrop-filter: saturate(1.2) blur(8px); border-bottom: 1px solid var(--rule); }
.site-head .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); white-space: nowrap; }
.brand svg { width: 26px; height: 26px; flex: none; }
.brand .name { font-size: 1.0625rem; font-weight: 500; letter-spacing: -0.005em; }
.brand .name i { font-style: italic; font-weight: 400; }
.nav { display: flex; align-items: center; gap: clamp(14px, 2.2vw, 30px); font-size: 1rem; }
.nav a { text-decoration: none; color: var(--ink-2); padding: 6px 0; position: relative; }
.nav a:hover { color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); }
.nav a[aria-current="page"]::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: var(--signal); }
.theme-toggle { background: none; border: 0; padding: 6px 0 6px 6px; cursor: pointer; color: var(--ink-3); display: inline-flex; align-items: center; }
.theme-toggle:hover { color: var(--ink); }
.theme-toggle svg { width: 18px; height: 18px; }
.menu-btn { display: none; background: none; border: 1px solid var(--rule); padding: 7px 10px; cursor: pointer; font-family: var(--mono); font-size: .8125rem; }

@media (max-width: 760px) {
  .brand .name .long { display: none; }
  .menu-btn { display: inline-block; }
  .nav { position: fixed; inset: 64px 0 auto 0; background: var(--paper); border-bottom: 1px solid var(--rule); flex-direction: column; align-items: stretch; gap: 0; padding: 8px var(--gutter) 20px; transform: translateY(-8px); opacity: 0; pointer-events: none; transition: opacity .2s var(--ease), transform .2s var(--ease); }
  .nav.open { opacity: 1; transform: none; pointer-events: auto; }
  .nav a { padding: 14px 0; border-bottom: 1px solid var(--rule); font-size: 1.25rem; }
  .nav a[aria-current="page"]::after { display: none; }
  .nav a[aria-current="page"] { color: var(--signal-text); }
  .theme-toggle { padding: 14px 0; justify-content: flex-start; gap: 10px; font-family: var(--mono); font-size: .8125rem; }
}
@media (min-width: 761px) { .theme-toggle .label { display: none; } }

/* ---------------------------------------------------------------- type */
.lede { font-size: clamp(1.3rem, 2.1vw, 1.625rem); line-height: 1.38; color: var(--ink); max-width: 34ch; font-weight: 350; letter-spacing: -0.008em; }
.lede em { font-style: italic; }
.h1 { font-size: clamp(2.5rem, 6.2vw, 5.25rem); font-weight: 330; letter-spacing: -0.028em; line-height: 1.0; }
.h2 { font-size: clamp(2rem, 4.2vw, 3.5rem); font-weight: 340; letter-spacing: -0.024em; line-height: 1.04; }
.h3 { font-size: clamp(1.35rem, 2vw, 1.625rem); font-weight: 420; letter-spacing: -0.012em; line-height: 1.2; }
.h1 em, .h2 em, .h3 em { font-style: italic; font-weight: 300; }
.dek { color: var(--ink-2); max-width: 46ch; font-size: 1.1875rem; }
.small { font-size: .9375rem; }
.muted { color: var(--ink-2); }
.faint { color: var(--ink-3); }
.note { font-size: .9375rem; line-height: 1.45; color: var(--ink-3); }
.note b, .note strong { color: var(--ink-2); font-weight: 500; }
.note .mark { color: var(--signal-text); }

/* ---------------------------------------------------------------- sections + margin-note grid */
.section { padding-block: var(--section); border-top: 1px solid var(--rule); }
.section.first { border-top: 0; }
.spread { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); }
.spread > .margin { grid-column: 1 / span 3; }
.spread > .main { grid-column: 4 / span 9; }
.spread > .main.narrow { grid-column: 4 / span 7; }
.margin .note + .note { margin-top: 1.2em; }
.margin .sticky { position: sticky; top: 96px; }
@media (max-width: 900px) {
  .spread { display: block; }
  .spread > .margin { margin-bottom: 20px; }
  .margin .sticky { position: static; }
}
.section-head { margin-bottom: clamp(36px, 5vw, 64px); }
.section-head .h2 { max-width: 16ch; }
.section-head .dek { margin-top: 18px; }

/* ---------------------------------------------------------------- buttons */
.btn { display: inline-flex; align-items: center; gap: 10px; font-family: var(--mono); font-size: .8125rem; line-height: 1; padding: 12px 16px; border: 1px solid var(--ink); background: transparent; color: var(--ink); cursor: pointer; text-decoration: none; transition: background .15s, color .15s; border-radius: 0; }
.btn:hover { background: var(--ink); color: var(--paper); }
.btn[disabled] { opacity: .4; cursor: not-allowed; }
.btn[disabled]:hover { background: transparent; color: var(--ink); }
.btn.solid { background: var(--ink); color: var(--paper); }
.btn.solid:hover { background: var(--signal); border-color: var(--signal); color: #fff; }
.btn .k { opacity: .55; }
.textlink { font-family: var(--serif); font-style: italic; color: var(--ink); text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: .22em; }
.textlink:hover { text-decoration-color: var(--signal); }
.arrow::after { content: " →"; font-style: normal; }

/* ---------------------------------------------------------------- source label (reference / model) */
.source { display: inline-flex; align-items: baseline; gap: 8px; font-family: var(--mono); font-size: .75rem; color: var(--ink-3); letter-spacing: .01em; }
.source .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ink-3); transform: translateY(-1px); flex: none; align-self: center; }
.source.is-model .dot { background: var(--signal); }
.source.is-model { color: var(--ink-2); }
.verdict { font-family: var(--mono); font-size: .8125rem; display: inline-flex; align-items: center; gap: 6px; }
.verdict.ok { color: var(--correct); }
.verdict.no { color: var(--wrong); }
.verdict svg { width: 14px; height: 14px; }

/* ---------------------------------------------------------------- task sheet (prompt + output) */
.sheet { border-top: 1px solid var(--rule-strong); }
.sheet-row { display: grid; grid-template-columns: 9rem minmax(0, 1fr); gap: 20px; padding: 18px 0; border-bottom: 1px solid var(--rule); }
.sheet-row > .label { font-size: .9375rem; font-style: italic; color: var(--ink-3); padding-top: 2px; }
.sheet-row .label .sub { display: block; font-style: normal; font-family: var(--mono); font-size: .6875rem; margin-top: 6px; color: var(--ink-3); }
@media (max-width: 640px) {
  .sheet-row { grid-template-columns: 1fr; gap: 6px; }
}
.prompt { font-size: 1.1875rem; line-height: 1.45; overflow-wrap: anywhere; }
.prompt.block, .out { font-family: var(--mono); font-size: .875rem; line-height: 1.62; white-space: pre-wrap; overflow-wrap: anywhere; }
.prompt.block { max-height: 22rem; overflow: auto; }
.out { color: var(--ink-2); }
.out .ln { display: block; }
.out .ln.is-result { color: var(--ink); }
.out .ln.is-result::before { content: ""; display: inline-block; width: 6px; height: 6px; background: var(--signal); margin-right: 10px; transform: translateY(-2px); }
.answer-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px 22px; }
.answer-line .val { font-size: clamp(1.5rem, 3vw, 2.125rem); font-weight: 400; letter-spacing: -0.015em; font-variant-numeric: lining-nums tabular-nums; overflow-wrap: anywhere; }
.answer-line .val.long { font-family: var(--mono); font-size: 1rem; letter-spacing: 0; }
.answer-line .sub { color: var(--ink-2); font-size: 1rem; }
.meta-line { display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; }
.sheet-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; align-items: center; }
.sheet-actions .status { font-family: var(--mono); font-size: .75rem; color: var(--ink-3); }

/* ---------------------------------------------------------------- HERO: the resolve */
.hero { padding-top: clamp(40px, 6vw, 84px); padding-bottom: clamp(48px, 7vw, 96px); }
.hero-intro { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); align-items: end; margin-bottom: clamp(36px, 5vw, 60px); }
.hero-intro .lede { grid-column: 1 / span 7; }
.hero-intro .aside { grid-column: 9 / span 4; }
@media (max-width: 900px) { .hero-intro { display: block; } .hero-intro .aside { margin-top: 18px; } }

.stage { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); border-top: 1px solid var(--rule-strong); position: relative; }
.stage .work { grid-column: 1 / span 7; padding-top: 22px; min-width: 0; }
.stage .result { grid-column: 8 / span 5; padding-top: 22px; border-left: 1px solid var(--rule); padding-left: clamp(16px, 2.4vw, 32px); display: flex; flex-direction: column; min-height: 30rem; min-width: 0; }
@media (max-width: 900px) {
  .stage { display: block; }
  .stage .result { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule); margin-top: 24px; min-height: 0; }
}
.stage-meta { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.stage-meta .where { font-style: italic; color: var(--ink-2); font-size: 1rem; }
.stage-meta .where b { font-style: normal; font-weight: 500; color: var(--ink); }
.stage .prompt { min-height: 5.8em; transition: opacity .35s var(--ease); }
.stage .prompt.block { max-height: 14rem; }
.stage .out { margin-top: 20px; padding-top: 16px; border-top: 1px dashed var(--rule); min-height: 11rem; }
.stage .out .ln { opacity: 0; transform: translateY(4px); transition: opacity .28s var(--ease), transform .28s var(--ease); }
.stage .out .ln.on { opacity: 1; transform: none; }
.stage .out .ln .hit { transition: color .3s, background-color .3s; }
.stage .out .ln .hit.lit { color: var(--signal-text); background: var(--selection); }
.caret { display: inline-block; width: .55em; height: 1.05em; background: var(--signal); vertical-align: -0.16em; margin-left: 2px; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

.result .label { font-style: italic; color: var(--ink-3); font-size: .9375rem; }
.answer-slot { position: relative; margin-top: 10px; flex: 1; display: flex; flex-direction: column; justify-content: center; min-height: 12rem; }
.big-answer { font-size: clamp(3.4rem, 8.4vw, 8.25rem); line-height: .92; font-weight: 300; letter-spacing: -0.035em; font-variant-numeric: lining-nums tabular-nums; transform-origin: 0 50%; overflow-wrap: anywhere; will-change: transform, opacity; }
.big-answer.m { font-size: clamp(2.6rem, 5.6vw, 5.5rem); }
.big-answer.s { font-size: clamp(2rem, 3.8vw, 3.6rem); letter-spacing: -0.02em; }
.big-answer.xs { font-size: clamp(1.4rem, 2.4vw, 2.1rem); letter-spacing: -0.01em; line-height: 1.1; }
.big-answer .unit { font-size: .32em; letter-spacing: 0; color: var(--ink-2); margin-left: .25em; font-style: italic; }
.answer-sub { margin-top: 16px; color: var(--ink-2); font-size: 1.0625rem; min-height: 1.5em; }
.underline { height: 2px; background: var(--signal); width: 100%; transform: scaleX(0); transform-origin: 0 50%; margin-top: 18px; transition: transform .7s var(--ease); }
.underline.on { transform: scaleX(1); }
.readout { margin-top: auto; padding-top: 22px; display: grid; grid-template-columns: repeat(3, auto); justify-content: start; gap: 6px 28px; font-family: var(--mono); font-size: .75rem; color: var(--ink-3); }
.readout .v { display: block; font-family: var(--serif); font-size: 1.5rem; color: var(--ink); letter-spacing: -0.01em; font-variant-numeric: lining-nums tabular-nums; margin-top: 2px; }
.readout.hidden { visibility: hidden; }
.stage-foot { display: flex; justify-content: space-between; gap: 18px; align-items: center; flex-wrap: wrap; margin-top: 26px; padding-top: 16px; border-top: 1px solid var(--rule); }
.ticker { display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: 1rem; }
.ticker button { background: none; border: 0; padding: 4px 0; cursor: pointer; color: var(--ink-3); position: relative; }
.ticker button:hover { color: var(--ink); }
.ticker button[aria-pressed="true"] { color: var(--ink); }
.ticker button[aria-pressed="true"]::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: var(--signal); }
.stage-controls { display: flex; gap: 8px; }
.stage.wipe .work, .stage.wipe .result { animation: wipe .5s var(--ease); }
@keyframes wipe { from { opacity: 0; clip-path: inset(0 0 100% 0); } to { opacity: 1; clip-path: inset(0 0 0 0); } }

/* ---------------------------------------------------------------- range index (home) */
.range { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); column-gap: clamp(16px, 2.4vw, 32px); }
.range-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule-strong); }
.range-list li { border-bottom: 1px solid var(--rule); }
.range-list a { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: baseline; padding: 14px 0; text-decoration: none; }
.range-list .n { font-size: clamp(1.35rem, 2.4vw, 1.875rem); letter-spacing: -0.015em; font-weight: 360; transition: color .15s, transform .25s var(--ease); display: inline-block; }
.range-list .c { font-family: var(--mono); font-size: .75rem; color: var(--ink-3); white-space: nowrap; }
.range-list a:hover .n, .range-list a:focus-visible .n, .range-list a.active .n { color: var(--signal-text); transform: translateX(6px); }
.range-preview { position: sticky; top: 96px; align-self: start; padding-left: clamp(16px, 2.4vw, 32px); border-left: 1px solid var(--rule); min-height: 22rem; }
.range-preview .about { font-size: 1.25rem; line-height: 1.4; margin-bottom: 18px; }
.range-preview .pv { font-family: var(--mono); font-size: .8125rem; line-height: 1.6; color: var(--ink-2); white-space: pre-wrap; overflow-wrap: anywhere; max-height: 16rem; overflow: hidden; -webkit-mask-image: linear-gradient(#000 75%, transparent); mask-image: linear-gradient(#000 75%, transparent); }
.range-preview .tt { font-style: italic; color: var(--ink-3); font-size: .9375rem; margin-bottom: 8px; }
@media (max-width: 900px) { .range { display: block; } .range-preview { display: none; } }

/* ---------------------------------------------------------------- figures (speed & cost) */
.figures { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--rule-strong); }
.figure { padding: 24px clamp(12px, 2vw, 28px) 8px 0; }
.figure + .figure { border-left: 1px solid var(--rule); padding-left: clamp(12px, 2vw, 28px); }
.figure .v { font-size: clamp(2.6rem, 4.9vw, 5rem); font-weight: 300; letter-spacing: -0.035em; line-height: 1; font-variant-numeric: lining-nums tabular-nums; }
.figure .v small { font-size: .38em; letter-spacing: -0.01em; color: var(--ink-2); font-style: italic; margin-left: .15em; }
.figure .k { margin-top: 14px; font-size: 1.0625rem; color: var(--ink-2); max-width: 22ch; }
@media (max-width: 760px) { .figures { grid-template-columns: 1fr; } .figure + .figure { border-left: 0; border-top: 1px solid var(--rule); padding-left: 0; } }

/* ---------------------------------------------------------------- feature spread (markets on home) */
.feature { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); }
.feature .left { grid-column: 1 / span 5; }
.feature .right { grid-column: 7 / span 6; }
@media (max-width: 900px) { .feature { display: block; } .feature .right { margin-top: 36px; } }

/* ---------------------------------------------------------------- worlds teaser drawing */
.iso { width: 100%; height: auto; color: var(--ink); }
.iso .wall { fill: var(--paper); stroke: var(--ink); stroke-width: .6; }
.iso .wall.top { fill: var(--paper-2); }
.iso .floor { fill: var(--paper-3); stroke: var(--rule); stroke-width: .5; }
.iso .walker { fill: var(--signal); }
.iso .walk-path { fill: none; stroke: var(--signal); stroke-width: 1.2; stroke-dasharray: 3 3; }

/* ---------------------------------------------------------------- tasks explorer */
.explorer { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); padding-block: clamp(32px, 5vw, 64px) var(--section); }
.cat-index { grid-column: 1 / span 3; }
.cat-index .sticky { position: sticky; top: 88px; max-height: calc(100vh - 110px); overflow: auto; padding-bottom: 20px; }
.cat-index ol { list-style: none; margin: 0; padding: 0; }
.cat-index a { display: flex; justify-content: space-between; gap: 10px; text-decoration: none; color: var(--ink-2); padding: 7px 0; font-size: 1.0625rem; border-bottom: 1px solid var(--rule); }
.cat-index a:hover { color: var(--ink); }
.cat-index a[aria-current="true"] { color: var(--ink); }
.cat-index a[aria-current="true"] .nm { box-shadow: inset 0 -1.5px 0 var(--signal); }
.cat-index .ct { font-family: var(--mono); font-size: .6875rem; color: var(--ink-3); padding-top: 5px; }
.cat-select { display: none; width: 100%; font: inherit; font-size: 1.125rem; padding: 12px; border: 1px solid var(--ink); background: var(--paper); color: var(--ink); border-radius: 0; }
.cat-main { grid-column: 4 / span 9; min-width: 0; }
.cat-head { margin-bottom: 26px; }
.cat-head .h2 { max-width: none; }
.cat-head .dek { margin-top: 12px; }
.task-list { display: flex; flex-wrap: wrap; gap: 2px 0; margin: 0 0 30px; padding: 0; list-style: none; font-size: 1.0625rem; line-height: 1.9; }
.task-list li { display: inline; white-space: nowrap; }
.task-list li:not(:last-child)::after { content: "·"; color: var(--ink-3); margin: 0 .6em; }
.task-list button { background: none; border: 0; padding: 0; cursor: pointer; color: var(--ink-2); text-align: left; }
.task-list button:hover { color: var(--ink); text-decoration: underline; text-decoration-color: var(--rule); text-underline-offset: .22em; }
.task-list button[aria-pressed="true"] { color: var(--ink); box-shadow: inset 0 -1.5px 0 var(--signal); }
@media (max-width: 900px) {
  .explorer { display: block; }
  .cat-index .sticky { position: static; max-height: none; }
  .cat-index ol { display: none; }
  .cat-select { display: block; margin-bottom: 28px; }
}

/* ---------------------------------------------------------------- markets page */
.checks { counter-reset: none; }
.check { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); padding-block: clamp(48px, 7vw, 96px); border-top: 1px solid var(--rule); }
.check:first-child { border-top: 1px solid var(--rule-strong); }
.check .about { grid-column: 1 / span 4; }
.check .about .h3 { margin-bottom: 14px; }
.check .about p { color: var(--ink-2); font-size: 1.0625rem; }
.check .formula { font-family: var(--mono); font-size: .8125rem; color: var(--ink-2); padding: 10px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); margin-top: 16px; overflow-wrap: anywhere; }
.check .sheet-wrap { grid-column: 6 / span 7; min-width: 0; }
@media (max-width: 900px) { .check { display: block; } .check .sheet-wrap { margin-top: 26px; } }
.more-list { columns: 3 14rem; column-gap: 32px; margin: 0; padding: 0; list-style: none; }
.more-list li { break-inside: avoid; border-bottom: 1px solid var(--rule); }
.more-list a { display: block; padding: 9px 0; text-decoration: none; color: var(--ink-2); }
.more-list a:hover { color: var(--ink); }

/* ---------------------------------------------------------------- worlds page */
.world { padding-block: clamp(40px, 6vw, 80px); border-top: 1px solid var(--rule); }
.world:first-of-type { border-top: 1px solid var(--rule-strong); }
.world-head { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); margin-bottom: 26px; align-items: end; }
.world-head .t { grid-column: 1 / span 6; }
.world-head .honest { grid-column: 8 / span 5; }
@media (max-width: 900px) { .world-head { display: block; } .world-head .honest { margin-top: 12px; } }
.honest { font-size: .9375rem; color: var(--ink-2); border-left: 2px solid var(--signal); padding-left: 14px; }
.viewport { position: relative; width: 100%; aspect-ratio: 16 / 9; background: var(--paper-2); overflow: hidden; }
.viewport canvas { width: 100% !important; height: 100% !important; touch-action: none; }
@media (max-width: 640px) { .viewport { aspect-ratio: 4 / 5; } }
.viewport .loading { position: absolute; inset: 0; display: grid; place-items: center; font-style: italic; color: var(--ink-3); }
.viewport .hud { position: absolute; left: 14px; right: 14px; bottom: 12px; pointer-events: none; font-family: var(--mono); font-size: .75rem; color: var(--ink-2); }
.viewport svg.drawing { position: absolute; inset: 6% 4%; width: 92%; height: 88%; }
.viewport canvas:focus-visible { outline-offset: -3px; }
.iso .road { fill: var(--ink-3); opacity: .35; stroke: none; }
.world-controls { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px 24px; align-items: start; margin-top: 16px; }
.world-controls .walk-prompt { font-size: 1.125rem; }
.world-controls .walk-prompt .k { font-style: italic; color: var(--ink-3); font-size: .9375rem; display: block; margin-bottom: 2px; }
.world-controls .btns { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.walk-steps { margin: 14px 0 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 4px 14px; font-family: var(--mono); font-size: .75rem; color: var(--ink-3); }
.walk-steps li.on { color: var(--ink); box-shadow: inset 0 -1.5px 0 var(--signal); }
.walk-steps li.done { color: var(--ink-2); }
.walk-pick { min-width: 0; width: 22rem; font: inherit; font-size: .9375rem; padding: 10px 12px; border: 1px solid var(--rule); background: var(--paper); color: var(--ink); max-width: 100%; border-radius: 0; }
@media (max-width: 640px) { .world-controls { grid-template-columns: minmax(0, 1fr); } .world-controls .btns { justify-content: flex-start; } .walk-pick { width: 100%; } }

/* market simulation */
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--rule-strong); margin-bottom: 30px; }
.kpis > div { padding: 16px 16px 0 0; }
.kpis > div + div { border-left: 1px solid var(--rule); padding-left: 16px; }
.kpis .v { font-size: clamp(1.6rem, 3vw, 2.5rem); font-weight: 340; letter-spacing: -0.02em; font-variant-numeric: lining-nums tabular-nums; }
.kpis .k { font-size: .9375rem; color: var(--ink-3); font-style: italic; }
@media (max-width: 760px) { .kpis { grid-template-columns: 1fr 1fr; } .kpis > div:nth-child(3) { border-left: 0; padding-left: 0; } .kpis > div:nth-child(n+3) { border-top: 1px solid var(--rule); } }
.chart { width: 100%; height: auto; overflow: visible; }
.chart .grid line { stroke: var(--rule); stroke-width: 1; }
.chart .axis text { fill: var(--ink-3); font-family: var(--mono); font-size: 11px; }
.chart .nav-line { fill: none; stroke: var(--signal); stroke-width: 2; }
.chart .inv-line { fill: none; stroke: var(--ink-3); stroke-width: 1.25; stroke-dasharray: 3 3; }
.chart .hover-line { stroke: var(--ink); stroke-width: 1; }
.chart .hover-dot { fill: var(--signal); }
.chart-legend { display: flex; gap: 22px; font-size: .9375rem; color: var(--ink-2); margin-top: 10px; flex-wrap: wrap; }
.chart-legend i { display: inline-block; width: 18px; height: 2px; background: var(--signal); vertical-align: middle; margin-right: 8px; }
.chart-legend i.inv { background: none; border-top: 1.5px dashed var(--ink-3); }
.chart-read { font-family: var(--mono); font-size: .75rem; color: var(--ink-3); min-height: 1.4em; margin-top: 6px; }
.table-wrap { overflow-x: auto; margin-top: 8px; }
table.ledger { width: 100%; border-collapse: collapse; font-size: .9375rem; font-variant-numeric: lining-nums tabular-nums; }
.ledger th { text-align: right; font-weight: 400; font-style: italic; color: var(--ink-3); font-size: .875rem; padding: 10px 12px 10px 0; border-bottom: 1px solid var(--rule-strong); white-space: nowrap; }
.ledger td { text-align: right; padding: 10px 12px 10px 0; border-bottom: 1px solid var(--rule); white-space: nowrap; font-family: var(--mono); font-size: .8125rem; }
.ledger th:first-child, .ledger td:first-child { text-align: left; }
.ledger td.name { font-family: var(--serif); font-size: .9375rem; }
.ledger .pos { color: var(--correct); } .ledger .neg { color: var(--wrong); }
.trades { max-height: 26rem; overflow: auto; border-bottom: 1px solid var(--rule); }
.two-col { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); margin-top: 48px; }
.two-col > :first-child { grid-column: 1 / span 6; min-width: 0; }
.two-col > :last-child { grid-column: 7 / span 6; min-width: 0; }
@media (max-width: 900px) { .two-col { display: block; } .two-col > :last-child { margin-top: 40px; } }

/* ---------------------------------------------------------------- chat */
.chat { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); padding-block: clamp(32px, 5vw, 64px) var(--section); }
.chat .margin { grid-column: 1 / span 3; }
.chat .thread-wrap { grid-column: 4 / span 7; min-width: 0; }
@media (max-width: 900px) { .chat { display: block; } .chat .margin { margin-bottom: 24px; } }
.thread { border-top: 1px solid var(--rule-strong); min-height: 18rem; }
.msg { padding: 18px 0; border-bottom: 1px solid var(--rule); display: grid; grid-template-columns: 5.5rem minmax(0, 1fr); gap: 16px; }
.msg .who { font-style: italic; color: var(--ink-3); font-size: .9375rem; }
.msg .body { white-space: pre-wrap; overflow-wrap: anywhere; }
.msg.model .body { font-family: var(--mono); font-size: .875rem; line-height: 1.6; }
.msg .meta { font-family: var(--mono); font-size: .6875rem; color: var(--ink-3); margin-top: 8px; }
.msg.system .body { color: var(--ink-2); font-style: italic; }
@media (max-width: 520px) { .msg { grid-template-columns: 1fr; gap: 4px; } }
.composer { display: flex; gap: 0; margin-top: 18px; border: 1px solid var(--ink); }
.composer textarea { flex: 1; font: inherit; font-size: 1.0625rem; padding: 14px; border: 0; background: transparent; color: var(--ink); resize: none; min-height: 3.2rem; max-height: 12rem; }
.composer textarea:focus { outline: none; }
.composer:focus-within { outline: 2px solid var(--signal); outline-offset: 3px; }
.composer button { border: 0; border-left: 1px solid var(--ink); }
.composer.off { border-color: var(--rule); }
.composer.off button { border-left-color: var(--rule); }
.state-pill { display: inline-flex; align-items: center; gap: 8px; font-family: var(--mono); font-size: .75rem; color: var(--ink-2); }
.state-pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ink-3); }
.state-pill.live .dot { background: var(--correct); }

/* ---------------------------------------------------------------- page heads */
.page-head { padding-top: clamp(48px, 7vw, 104px); padding-bottom: clamp(28px, 4vw, 48px); }
.page-head .h1 { max-width: 14ch; }
.page-head .lede { margin-top: 22px; max-width: 38ch; color: var(--ink-2); }

/* prose (notes) */
.prose { max-width: 36em; }
.prose h2 { font-size: 1.75rem; font-weight: 380; margin: 2.2em 0 .6em; letter-spacing: -0.015em; }
.prose h2:first-child { margin-top: 0; }
.prose p, .prose li { color: var(--ink); }
.prose ul { padding-left: 1.1em; }
.prose li { margin-bottom: .5em; }
.prose .kv { display: grid; grid-template-columns: 12rem minmax(0, 1fr); gap: 6px 20px; border-top: 1px solid var(--rule); padding-top: 12px; margin: 1em 0 1.4em; font-size: 1rem; }
.prose .kv dt { font-style: italic; color: var(--ink-3); }
.prose .kv dd { margin: 0; }
@media (max-width: 560px) { .prose .kv { grid-template-columns: 1fr; } .prose .kv dd { margin-bottom: 10px; } }

/* ---------------------------------------------------------------- footer */
.site-foot { border-top: 1px solid var(--rule-strong); padding-block: 48px 40px; margin-top: 0; }
.site-foot .cols { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); row-gap: 28px; }
.site-foot .c1 { grid-column: 1 / span 5; }
.site-foot .c2 { grid-column: 7 / span 3; }
.site-foot .c3 { grid-column: 10 / span 3; }
.site-foot .brand { margin-bottom: 14px; }
.site-foot ul { list-style: none; margin: 0; padding: 0; }
.site-foot li a { display: inline-block; padding: 4px 0; text-decoration: none; color: var(--ink-2); }
.site-foot li a:hover { color: var(--ink); }
.site-foot .legal { margin-top: 44px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-family: var(--mono); font-size: .75rem; color: var(--ink-3); }
@media (max-width: 760px) { .site-foot .cols { display: block; } .site-foot .c2, .site-foot .c3 { margin-top: 26px; } }

/* 404 */
.nf { min-height: 62vh; display: flex; flex-direction: column; justify-content: center; padding-block: 80px; }
.nf .big-answer { margin: 12px 0 18px; }

/* ---------------------------------------------------------------- reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .caret { animation: none; }
}

/* ---------------------------------------------------------------- creator */
.creator-head { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); align-items: end; padding-top: clamp(48px, 7vw, 104px); padding-bottom: clamp(40px, 6vw, 80px); }
.creator-head .ch-text { grid-column: 1 / span 11; }
.creator-head .ch-text .h1 { margin-top: 10px; max-width: none; }
.creator-head .ch-text .lede { margin-top: 18px; color: var(--ink-2); }
@media (max-width: 900px) {
  .creator-head { display: block; }
  }
.creed { border-top: 1px solid var(--rule-strong); border-bottom: 1px solid var(--rule); padding-block: clamp(72px, 12vw, 176px); }
.creed-text { margin: 22px 0 0; font-size: clamp(2.1rem, 5.4vw, 5rem); line-height: 1.07; font-weight: 300; letter-spacing: -0.03em; max-width: 23ch; }
.creed-text .second { margin-top: .45em; }
.creed-text em { font-style: italic; }
.creed-text p { margin: 0; }
.creed-text .w { color: var(--ink-3); transition: color .45s var(--ease); }
.creed-text .w.lit { color: var(--ink); }
.creed-sig { margin-top: 36px; font-style: italic; color: var(--ink-2); font-size: 1.1875rem; }
.creed-rule { height: 2px; background: var(--signal); width: 7rem; margin-top: 30px; transform: scaleX(0); transform-origin: 0 50%; transition: transform .9s var(--ease); }
.creed-rule.on { transform: scaleX(1); }
.link-row { list-style: none; margin: 28px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 12px 32px; font-size: 1.25rem; }

/* essay (creator) */
.essay { padding-block: clamp(8px, 2vw, 24px) 0; }
.essay-part { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: clamp(16px, 2.4vw, 32px); padding-block: clamp(56px, 8vw, 112px); border-top: 1px solid var(--rule); }
.essay-part:first-child { border-top: 0; }
.essay-part > .margin { grid-column: 1 / span 3; }
.essay-part > .margin .note { position: sticky; top: 96px; font-style: italic; }
.essay-part > .main { grid-column: 4 / span 7; }
.essay-part .h2 { font-size: clamp(1.9rem, 3.6vw, 3rem); max-width: 20ch; margin-bottom: 28px; }
.essay-part p { font-size: 1.25rem; line-height: 1.58; max-width: 34em; }
.essay-part p.note { font-size: .9375rem; }
.dropcap::first-letter { float: left; font-size: 4.6em; line-height: .82; font-weight: 300; margin: .06em .1em 0 -.02em; color: var(--signal-text); }
@media (max-width: 900px) { .essay-part { display: block; } .essay-part > .margin .note { position: static; margin-bottom: 14px; } }
.pull { margin: 0; padding-block: clamp(56px, 9vw, 128px); border-top: 1px solid var(--rule-strong); border-bottom: 1px solid var(--rule-strong); }
.pull blockquote { margin: 0 auto; max-width: 22ch; text-align: center; font-size: clamp(2rem, 4.8vw, 4.25rem); line-height: 1.08; font-weight: 300; letter-spacing: -0.028em; }
.pull blockquote p { margin: 0; }
.pull em { color: var(--signal-text); }
.principles { border-top: 1px solid var(--rule); padding-block: clamp(72px, 11vw, 160px); background: var(--paper-2); }
.principle-list { list-style: none; margin: 28px 0 0; padding: 0; }
.principle-list li { font-size: clamp(2rem, 5.6vw, 5rem); line-height: 1.08; letter-spacing: -0.03em; font-weight: 300; padding-block: .22em; border-bottom: 1px solid var(--rule); }
.principle-list li:first-child { border-top: 1px solid var(--rule-strong); }
.principle-list li:nth-child(even) { padding-left: clamp(0px, 8vw, 160px); }
.principle-list em { font-weight: 300; }
.closing-text { font-size: clamp(1.5rem, 2.8vw, 2.25rem); line-height: 1.3; font-weight: 340; letter-spacing: -0.015em; margin: 0; max-width: 26ch; }
.closing .link-row { margin-top: 36px; }
.essay-part > .main.wide { grid-column: 4 / span 9; }
.question { font-size: clamp(1.7rem, 3.4vw, 2.75rem) !important; line-height: 1.18 !important; letter-spacing: -0.02em; font-weight: 320; max-width: 22ch !important; margin-bottom: 28px; }
.question em { color: var(--signal-text); }
.habits { margin: 8px 0 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: clamp(20px, 3vw, 48px); }
.habits > div { border-top: 1px solid var(--rule-strong); padding: 20px 0 34px; }
.habits > div.span { grid-column: 1 / -1; }
.habits > div.span dd { max-width: 62ch; }
.habits dt { font-size: clamp(1.5rem, 2.4vw, 2rem); letter-spacing: -0.015em; font-weight: 360; line-height: 1.15; margin-bottom: 12px; }
.habits dd { margin: 0; color: var(--ink-2); font-size: 1.0625rem; line-height: 1.55; }
@media (max-width: 760px) { .habits { grid-template-columns: 1fr; } }
.who { font-size: clamp(1.6rem, 3.2vw, 2.5rem) !important; line-height: 1.2 !important; letter-spacing: -0.018em; font-weight: 300; max-width: 24ch !important; }
.bet { font-size: clamp(1.5rem, 2.6vw, 2.1rem) !important; line-height: 1.25 !important; letter-spacing: -0.015em; font-weight: 340; margin-top: 28px; }
.bet em { color: var(--signal-text); }
.terms { margin: 8px 0 40px; }
.terms > div { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 8px 32px; align-items: baseline; border-top: 1px solid var(--rule); padding: 20px 0; }
.terms > div:first-child { border-top-color: var(--rule-strong); }
.terms dt { font-size: clamp(1.6rem, 3vw, 2.5rem); font-style: italic; font-weight: 300; letter-spacing: -0.02em; line-height: 1.1; }
.terms dd { margin: 0; font-size: 1.1875rem; line-height: 1.5; color: var(--ink-2); }
@media (max-width: 640px) { .terms > div { grid-template-columns: 1fr; } }
