/* The geometry page: a drafting sheet. A narrow index column beside one reading column; every drawing sits on a white sheet. Everything is scoped under .geo, so the site's bar and footer keep their look. */
.geo {
  --rule: #062b8a2e; --hot: #c2410c; --code: #eef0f6;
  --sheet: #ffffff; --s-ink: #062b8a; --s-soft: #8fa3d6; --s-hot: #c2410c; --s-teal: #0f766e; --s-violet: #6d28d9; --s-grey: #77756f;
  --mono: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
  padding: 32px var(--margin) 0; font: 400 1.0625rem/1.6 var(--text);
}
.geo main ul { list-style: disc; }
.geo main ol { list-style: decimal; }
.geo .geo-note { margin-top: -40px; padding-top: 18px; border-top: 2px solid var(--ink); font-size: 0.9rem; color: var(--muted); max-width: none; }
.geo h1, .geo h2, .geo h3 { margin: 0; font-family: var(--display); font-weight: 700; letter-spacing: -0.03em; line-height: 1.02; text-wrap: balance; }
.geo h1 { font-size: clamp(2.6rem, 6.4vw, 5.4rem); letter-spacing: -0.045em; line-height: 0.94; }
.geo h2 { font-size: clamp(1.8rem, 3.2vw, 2.7rem); }
.geo h3 { font-size: 1.25rem; letter-spacing: -0.015em; line-height: 1.2; margin-top: 12px; }
.geo p, .geo ul, .geo ol, .geo figure, .geo dl, .geo dd, .geo pre, .geo table { margin: 0; }
.geo p, .geo li { max-width: 68ch; }
.geo ul, .geo ol { padding-left: 1.2em; display: grid; gap: 6px; }
.geo code, .geo pre, .geo .mono { font-family: var(--mono); }
.geo code { font-size: 0.86em; background: var(--code); padding: 1px 5px; border-radius: 3px; }
.geo pre { font-size: 0.8rem; line-height: 1.55; background: var(--code); padding: 16px 18px; overflow-x: auto; border-left: 3px solid var(--ink); }
.geo pre code { background: none; padding: 0; font-size: inherit; }
.geo .eyebrow { font: 600 0.74rem/1.3 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.geo header.top { display: grid; gap: 22px; padding-bottom: 36px; border-bottom: 2px solid var(--ink); }
.geo .lede { font-size: clamp(1.15rem, 1rem + 0.6vw, 1.5rem); line-height: 1.4; max-width: 46ch; }
.geo .layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; margin-top: 40px; }
.geo nav.index { font: 600 0.82rem/1.3 var(--display); }
.geo nav.index ol { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.geo nav.index a { text-decoration: none; color: var(--muted); }
.geo nav.index a:hover { color: var(--ink); text-decoration: underline; }
@media (min-width: 1080px) {
  .geo .layout { grid-template-columns: 180px minmax(0, 1fr); gap: 56px; }
  .geo nav.index { position: sticky; top: 24px; align-self: start; }
  .geo nav.index ol { flex-direction: column; gap: 9px; }
}
.geo main { display: grid; gap: 88px; min-width: 0; }
.geo section { display: grid; gap: 20px; min-width: 0; scroll-margin-top: 24px; }
.geo section > * { min-width: 0; }
.geo .sec-head { display: grid; gap: 10px; padding-top: 18px; border-top: 1px solid var(--rule); }
.geo figure { display: grid; gap: 10px; }
.geo .sheet { background: var(--sheet); border: 1px solid var(--rule); padding: 14px; overflow-x: auto; }
.geo .sheet svg { display: block; width: 100%; height: auto; min-width: 520px; }
.geo .demo .sheet svg, .geo .sheet.narrow svg { min-width: 0; }
.geo .sheet.narrow svg { max-width: 560px; margin: 0 auto; }
.geo figcaption { font-size: 0.93rem; line-height: 1.45; color: var(--muted); max-width: 78ch; }
.geo figcaption b { color: var(--ink); font-weight: 600; }
.geo figcaption [class^="c-"] { color: inherit; }
.geo figcaption .c-ink .sw { color: var(--s-ink); }
.geo figcaption .c-teal .sw { color: var(--s-teal); }
.geo figcaption .c-violet .sw { color: var(--s-violet); }
.geo figcaption .c-hot .sw { color: var(--s-hot); }
.geo .sw { display: inline-block; width: 0.8em; height: 0.8em; margin-right: 4px; vertical-align: -1px; background: currentColor; outline: 2px solid var(--sheet); }
/* drawing vocabulary on sheets */
.geo .sheet svg text { font: 500 13px var(--mono); fill: currentColor; stroke: none; }
.geo .sheet svg text.big { font: 700 22px var(--display); }
.geo .sheet svg text.sm { font-size: 11px; }
.geo .c-ink { color: var(--s-ink); }
.geo .c-soft { color: var(--s-soft); }
.geo .c-hot { color: var(--s-hot); }
.geo .c-teal { color: var(--s-teal); }
.geo .c-violet { color: var(--s-violet); }
.geo .c-grey { color: var(--s-grey); }
.geo .ln { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.geo .ln.thin { stroke-width: 0.9; }
.geo .ln.bold { stroke-width: 3; }
.geo .ln.dash { stroke-dasharray: 7 5; }
.geo .ln.dot { stroke-dasharray: 2 5; }
.geo .fl { fill: currentColor; stroke: none; }
.geo .tint { fill: currentColor; fill-opacity: 0.12; stroke: currentColor; stroke-width: 1.4; stroke-linejoin: round; }
.geo .tint2 { fill: currentColor; fill-opacity: 0.28; stroke: currentColor; stroke-width: 1.4; stroke-linejoin: round; }
.geo .band { fill: none; stroke: currentColor; stroke-opacity: 0.16; stroke-linecap: butt; }
.geo .none { fill: none; stroke: none; }
/* the live demo */
.geo .demo { display: grid; gap: 14px; }
.geo .demo-views { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 14px; }
.geo .demo .sheet { display: grid; gap: 8px; align-content: start; padding: 12px; }
.geo .demo canvas { display: block; width: 100%; max-width: 560px; height: auto; margin: 0 auto; }
.geo .tag { font: 600 0.7rem/1.2 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--s-ink); }
.geo .controls { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 12px 28px; background: var(--surface); padding: 14px 18px; }
.geo .controls label { display: grid; gap: 4px; font: 600 0.84rem/1.3 var(--display); }
.geo .controls output { font: 600 0.84rem var(--mono); font-variant-numeric: tabular-nums; }
.geo .controls span { display: flex; justify-content: space-between; gap: 12px; }
.geo input[type="range"] { width: 100%; accent-color: var(--ink); }
/* flow chains */
.geo .chain { display: flex; flex-wrap: wrap; gap: 8px 0; align-items: stretch; }
.geo .chain > div { flex: 1 1 150px; min-width: 0; border: 1.5px solid var(--ink); padding: 10px 12px; margin-right: 22px; position: relative; font-size: 0.9rem; line-height: 1.35; }
.geo .chain > div b { display: block; font: 700 0.86rem/1.2 var(--display); margin-bottom: 3px; }
.geo .chain > div:not(:last-child)::after { content: "→"; position: absolute; right: -19px; top: 50%; transform: translateY(-50%); font: 700 1rem var(--display); }
.geo .chain > div.core { background: var(--ink); color: var(--bg); }
.geo .rings { display: grid; gap: 0; border: 1.5px solid var(--ink); }
.geo .rings > div { display: grid; grid-template-columns: minmax(96px, 150px) minmax(0, 1fr); gap: 14px; padding: 10px 14px; border-top: 1px solid var(--rule); font-size: 0.92rem; }
.geo .rings > div:first-child { border-top: 0; }
.geo .rings > div.core { background: var(--ink); color: var(--bg); }
.geo .rings b { font: 700 0.9rem/1.3 var(--mono); }
.geo .bytes { display: flex; border: 1.5px solid var(--ink); font: 600 0.72rem/1.25 var(--mono); min-width: 620px; }
.geo .bytes > div { padding: 10px 8px; border-left: 1.5px solid var(--ink); }
.geo .bytes > div:first-child { border-left: 0; background: var(--ink); color: var(--bg); }
.geo .bytes small { display: block; font-weight: 400; opacity: 0.85; }
.geo .scroll { overflow-x: auto; }
.geo .two { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 20px 28px; align-items: start; }
.geo .two > * { min-width: 0; }
.geo .stack { display: grid; gap: 14px; }
.geo dl.facts { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 16px; font-size: 0.93rem; }
.geo dl.facts dt { font: 600 0.8rem/1.5 var(--mono); color: var(--muted); }
.geo table { border-collapse: collapse; width: 100%; font-size: 0.9rem; font-variant-numeric: tabular-nums; }
.geo th, .geo td { text-align: left; padding: 7px 12px 7px 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
.geo th { font: 700 0.76rem/1.3 var(--display); letter-spacing: 0.03em; text-transform: uppercase; color: var(--muted); }
.geo td.id { font: 600 0.8rem/1.5 var(--mono); white-space: nowrap; }
.geo td.num { font-family: var(--mono); white-space: nowrap; }
.geo details { border: 1px solid var(--rule); padding: 12px 16px; }
.geo summary { cursor: pointer; font: 700 0.95rem/1.3 var(--display); }
.geo details[open] summary { margin-bottom: 12px; }
.geo .note { border-left: 3px solid var(--hot); padding: 4px 0 4px 14px; font-size: 0.96rem; }
