:root {
  --bg: #04050a;
  --ink: #eef0f6;
  --ink-2: #b4bacb;
  --ink-3: #7c849c;
  --line: rgba(255,255,255,0.12);
  --line-2: rgba(255,255,255,0.06);
  --serif: 'Cormorant Garamond', 'Iowan Old Style', Georgia, serif;
  --sans: 'Space Grotesk', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, Menlo, monospace;
  --night: #ff2bd6;      /* v1's magenta */
  --personal: #ffb000;   /* the fork, left strand */
  --consulting: #4aa8ff; /* the fork, right strand */
  --pad: clamp(1.1rem, 4vw, 3rem);
  --max: 1180px;
  --rail: 88px;
  --node-y: 4.6rem;      /* node centre from the top of a rung; the rail's fixed-height joint blocks depend on it */
  --joint-h: 4.5rem;
}
* { box-sizing: border-box; }
html { background: var(--bg); color-scheme: dark; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--sans); color: var(--ink); background: var(--bg); line-height: 1.55; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
h1, h2, h3, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }
a { color: inherit; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
::selection { background: var(--personal); color: var(--bg); }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--pad); }
.mono { font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-3); }
/* the brand is lower case wherever the mono idiom would upper-case it */
.lc, .chips--site .chip { text-transform: none; }

/* ----- masthead ----- */
.top { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 0.9rem var(--pad); font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-3); border-bottom: 1px solid var(--line); }
.top b { color: var(--ink); font-weight: 500; }
.top .dot { display: inline-block; width: 0.55em; height: 0.55em; background: var(--personal); transform: rotate(45deg); margin-right: 0.7em; }
.top nav { display: flex; gap: 1.4rem; }
.top nav a { text-decoration: none; }
.top nav a:hover { color: var(--ink); }
@media (max-width: 640px) { .top nav { display: none; } }

/* ----- hero ----- */
.hero { padding: clamp(3rem, 8vw, 6rem) 0 clamp(2rem, 5vw, 3.5rem); }
.eyebrow { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.25em; text-transform: uppercase; color: var(--ink-3); display: flex; align-items: center; gap: 0.9rem; flex-wrap: wrap; }
.eyebrow::before { content: ''; width: 2rem; height: 1px; background: currentColor; }
.hero h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(3rem, 9.5vw, 7.2rem); line-height: 0.94; letter-spacing: -0.015em; margin-top: 1rem; }
.hero h1 em { font-style: italic; color: var(--ink-2); }
.hero .count { margin-top: 1.1rem; display: flex; flex-wrap: wrap; gap: 0.4rem 1.6rem; }
.hero .count b { color: var(--ink); font-weight: 500; }
.lede { margin-top: clamp(1.6rem, 3vw, 2.2rem); max-width: 46rem; color: var(--ink-2); font-size: 1rem; }
.lede em { color: var(--ink); font-style: normal; }

/* ----- the line: one rail column, drawn in three fixed/stretched blocks per rung ----- */
.rung, .outro { display: grid; grid-template-columns: var(--rail) 1fr; gap: 0 clamp(1rem, 3vw, 2.5rem); position: relative; }
.rail { position: relative; }
.rail svg { position: absolute; left: 0; width: 100%; display: block; overflow: visible; }
.rail .r-in { top: 0; height: var(--node-y); }
.rail .r-joint { top: var(--node-y); height: var(--joint-h); }
.rail .r-rest { top: calc(var(--node-y) + var(--joint-h)); height: calc(100% - var(--node-y) - var(--joint-h)); }
.rail path, .rail line { fill: none; stroke-width: 2; vector-effect: non-scaling-stroke; stroke-linejoin: miter; }
.rail .n { stroke: var(--night); }
.rail .p { stroke: var(--personal); } .rail .c { stroke: var(--consulting); }
.rail .node { position: absolute; top: var(--node-y); transform: translate(-50%, -50%); width: 14px; height: 14px; border-radius: 50%; background: var(--bg); border: 2px solid var(--ink); z-index: 1; }
.rail .node--tie { width: calc(40 / 88 * 100% + 14px); border-radius: 7px; }
.rail .num { position: absolute; left: 50%; top: var(--node-y); transform: translate(-50%, 1rem); font-family: var(--serif); font-style: italic; font-size: 1.3rem; color: var(--ink-3); background: var(--bg); padding: 0.1rem 0.35rem; z-index: 1; white-space: nowrap; }
.rail .num.on { color: var(--ink); }
.x44 { left: 50%; } .x24 { left: calc(24 / 88 * 100%); } .x64 { left: calc(64 / 88 * 100%); }

/* ----- rungs ----- */
.body { padding: 3rem 0 clamp(2.5rem, 6vw, 5rem); border-top: 1px solid var(--line); min-width: 0; }
.rung--night .body { border-top-color: transparent; padding-top: 2rem; }
.body .eyebrow { margin-bottom: 0.9rem; }
.body h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(2rem, 4.6vw, 3.6rem); line-height: 1; letter-spacing: -0.01em; max-width: 18ch; }
.body h2 em { font-style: italic; color: var(--personal); }
.rung--v1 .body h2 em { color: var(--night); }
.body .desc { margin-top: 1.1rem; max-width: 46rem; color: var(--ink-2); font-size: 1rem; }
.body .changes { margin-top: 1.1rem; max-width: 46rem; display: grid; gap: 0.35rem; }
.body .changes li { display: grid; grid-template-columns: 1rem 1fr; gap: 0.6rem; color: var(--ink-2); font-size: 0.92rem; }
.body .changes li::before { content: '—'; color: var(--ink-3); }

/* v1 keeps its own type */
.spec { position: relative; border: 1px solid var(--line); overflow: hidden; display: grid; grid-template-rows: auto 1fr auto; min-height: 440px; }
.spec--wide { margin-top: 1.8rem; min-height: 0; grid-template-columns: 1fr 1fr; grid-template-rows: auto; }
@media (max-width: 760px) { .spec--wide { grid-template-columns: 1fr; } }
.spec__tag { position: absolute; top: 0.9rem; left: 1rem; z-index: 2; font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.25em; text-transform: uppercase; }
.spec__date { position: absolute; top: 0.9rem; right: 1rem; z-index: 2; font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.2em; color: var(--ink-3); }
.spec__body { padding: 3.4rem 1.4rem 1.2rem; }
.spec__foot { padding: 0 1.4rem 1.4rem; display: flex; justify-content: space-between; align-items: end; gap: 1rem; }
.spec__foot p { font-size: 0.86rem; color: var(--ink-2); max-width: 30ch; }
.spec__go { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase; text-decoration: none; padding: 0.7em 1em; border: 1px solid currentColor; white-space: nowrap; }
.spec__go:hover { background: currentColor; }
.spec__go:hover span { color: var(--bg); }

.spec--night { background: linear-gradient(to bottom, #04050c, #160a33 55%, #4a0e5c); color: #e9edf9; }
.spec--night::before { content: ''; position: absolute; inset: 0; z-index: 3; pointer-events: none; background: repeating-linear-gradient(to bottom, rgba(255,255,255,0.035) 0 1px, transparent 1px 3px); mix-blend-mode: overlay; }
.spec--night .spec__tag, .spec--night .spec__tag b { color: #00f0ff; }
.spec--night .meta { font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.22em; text-transform: uppercase; color: #9aa3c4; }
.spec--night h3 { font-family: 'Orbitron', sans-serif; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; line-height: 1.02; font-size: clamp(2rem, 3.6vw, 3rem); margin-top: 0.9rem; }
.spec--night h3 .l1 { display: block; color: #00f0ff; text-shadow: 0 0 18px rgba(0,240,255,0.6); }
.spec--night h3 .l2 { display: block; color: #fff; text-shadow: 0 0 22px rgba(255,43,214,0.55); }
.spec--night .sectors { display: flex; flex-wrap: wrap; gap: 0.45rem 0.9rem; margin-top: 1rem; font-family: var(--mono); font-size: 0.6rem; letter-spacing: 0.18em; text-transform: uppercase; color: #9aa3c4; }
.spec--night .sectors b { color: #ffb000; font-weight: 500; }
.spec--night .spec__foot { position: relative; z-index: 2; align-self: end; }
.spec--night .spec__foot p { color: #9aa3c4; }
.spec--night .spec__go { color: #00f0ff; border-color: #00f0ff; }
.spec--night .right { position: relative; display: grid; grid-template-rows: 1fr auto; min-height: 300px; }
.scene { position: relative; margin: 3.4rem 1.4rem 0; height: 170px; overflow: hidden; }
.scene .sun { position: absolute; left: 50%; top: 8px; width: 96px; height: 96px; transform: translateX(-50%); border-radius: 50%; background: linear-gradient(#ffd166, #ff2bd6 55%, #7b2cff); box-shadow: 0 0 40px rgba(255,43,214,0.55); -webkit-mask: repeating-linear-gradient(to bottom, #000 0 9px, transparent 9px 13px); mask: repeating-linear-gradient(to bottom, #000 0 9px, transparent 9px 13px); }
.scene .hz { position: absolute; left: 0; right: 0; top: 80px; height: 2px; background: #ff2bd6; box-shadow: 0 0 10px #ff2bd6; }
.scene .floor { position: absolute; left: 0; right: 0; top: 82px; bottom: 0; background: #04050c; background-image: linear-gradient(rgba(0,240,255,0.18) 1px, transparent 1px), linear-gradient(90deg, rgba(0,240,255,0.12) 1px, transparent 1px); background-size: 100% 12px, 40px 100%; transform: perspective(120px) rotateX(48deg); transform-origin: top; }
.scene .road { position: absolute; left: 50%; top: 82px; bottom: 0; width: 46%; transform: translateX(-50%); background: #0b0e16; clip-path: polygon(46% 0, 54% 0, 100% 100%, 0 100%); }
.scene .road::after { content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: repeating-linear-gradient(to bottom, #ffb000 0 8px, transparent 8px 16px); }

/* placeholder / image slot. `data-capture` names the file in captures/. */
.ph { position: relative; aspect-ratio: 16 / 10; border: 1px solid var(--line); background: #07080e; display: grid; place-items: center; text-align: center; padding: 1rem; overflow: hidden; }
.ph span { position: relative; font-family: var(--mono); font-size: 0.6rem; letter-spacing: 0.15em; text-transform: uppercase; color: var(--ink-3); line-height: 1.7; }
.ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ph.has span { display: none; }
.ph.missing { border-style: dashed; border-color: rgba(255,255,255,0.28); }

/* ----- comparator: this rung against the one before it ----- */
.cmp { margin-top: 1.8rem; }
.cmp__bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.6rem 1.4rem; margin-bottom: 0.7rem; }
.cmp__bar .mono b { color: var(--ink); font-weight: 500; }
.cmp__sets { display: flex; flex-wrap: wrap; gap: 0.5rem 1.4rem; align-items: center; }
.chips { display: flex; flex-wrap: wrap; gap: 0.3rem; align-items: center; }
.chips[hidden] { display: none; }
.chip { font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.15em; text-transform: uppercase; padding: 0.42em 0.7em; border: 1px solid var(--line); color: var(--ink-3); }
.chip:hover { color: var(--ink); border-color: rgba(255,255,255,0.35); }
.chip[aria-pressed="true"] { color: var(--bg); background: var(--ink); border-color: var(--ink); }
.chips--site .chip[data-site="personal"][aria-pressed="true"] { background: var(--personal); border-color: var(--personal); }
.chips--site .chip[data-site="consulting"][aria-pressed="true"] { background: var(--consulting); border-color: var(--consulting); }
.chip--live { border-color: rgba(255,255,255,0.3); color: var(--ink); }
.chip--live::after { content: ' ⤢'; }
@media (max-width: 899px), (hover: none) { .chip--live { display: none; } }

.stage img, .live__stage iframe { -webkit-user-drag: none; user-select: none; }
.stage { position: relative; aspect-ratio: 16 / 10; border: 1px solid var(--line); overflow: hidden; user-select: none; -webkit-user-select: none; touch-action: pan-y; cursor: ew-resize; background: #07080e; --x: 50%; }
.stage .ph { position: absolute; inset: 0; aspect-ratio: auto; border: 0; }
.stage .side--a { clip-path: inset(0 calc(100% - var(--x)) 0 0); z-index: 1; }
.stage .bar { position: absolute; top: 0; bottom: 0; left: var(--x); width: 1px; background: var(--ink); box-shadow: 0 0 0 1px rgba(0,0,0,0.6); z-index: 2; pointer-events: none; }
.stage .knob { position: absolute; top: 50%; left: var(--x); transform: translate(-50%, -50%); width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--ink); background: rgba(4,5,10,0.85); display: grid; place-items: center; font-family: var(--mono); font-size: 0.6rem; color: var(--ink); z-index: 2; pointer-events: none; }
.stage .lab { position: absolute; top: 0.7rem; font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink); background: rgba(4,5,10,0.72); padding: 0.35em 0.6em; z-index: 3; pointer-events: none; white-space: nowrap; }
.stage .lab b { font-weight: 500; }
.stage .lab--a { left: 0.7rem; } .stage .lab--b { right: 0.7rem; }
.stage .lab--a b { color: var(--ink-2); }
.stage .ph span { max-width: 44%; }
.stage .side--a span { position: absolute; left: 1rem; bottom: 1rem; text-align: left; }
.stage .side--b span { position: absolute; right: 1rem; bottom: 1rem; text-align: right; }
@media (max-width: 640px) { .stage .lab--b { top: auto; bottom: 0.7rem; } .stage .ph span { display: none; } }
.cmp__foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.4rem 1rem; margin-top: 0.6rem; }
.cmp__foot a { text-decoration: none; }
.cmp__foot a:hover { color: var(--ink); }
.cmp__foot a::after { content: ' ↗'; }

/* open the two faces */
.faces { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1.2rem; }
@media (max-width: 640px) { .faces { grid-template-columns: 1fr; } }
.faces a { text-decoration: none; border: 1px solid var(--line); padding: 0.9rem 1.1rem; display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; }
.faces a:hover { border-color: currentColor; }
.faces small { font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.22em; text-transform: uppercase; }
.faces b { font-family: var(--serif); font-weight: 400; font-size: 1.35rem; line-height: 1; color: var(--ink); }
.faces b i { font-style: italic; color: currentColor; }
.faces .f-p { color: var(--personal); } .faces .f-c { color: var(--consulting); }
.faces .go { font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-3); }
.faces a:hover .go { color: var(--ink); }

/* ----- the strands leave the page ----- */
.outro { padding-bottom: clamp(3rem, 8vw, 6rem); }
.outro .body { border-top: 1px solid var(--line); }
.live-sites { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1.4rem; }
@media (max-width: 640px) { .live-sites { grid-template-columns: 1fr; } }
.live-sites a { text-decoration: none; border: 1px solid var(--line); padding: 1.2rem 1.3rem; display: grid; gap: 0.3rem; }
.live-sites a:hover { border-color: currentColor; }
.live-sites small { font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.22em; text-transform: uppercase; }
.live-sites b { font-family: var(--serif); font-weight: 400; font-size: 1.7rem; line-height: 1; color: var(--ink); }
.live-sites b i { font-style: italic; color: currentColor; }
.live-sites .f-p { color: var(--personal); } .live-sites .f-c { color: var(--consulting); }

footer.colophon { border-top: 1px solid var(--line); padding: 1.4rem var(--pad) 2.4rem; font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-3); display: flex; flex-wrap: wrap; gap: 0.6rem 2rem; justify-content: space-between; }

/* ----- live mode: two archived pages, full screen, one wiped over the other ----- */
.live { position: fixed; inset: 0; z-index: 1000; background: var(--bg); display: none; }
.live.open { display: block; }
body.live-open { overflow: hidden; }
.live__scroll { position: absolute; inset: 0; overflow-y: scroll; overflow-x: hidden; scrollbar-width: none; outline: none; }
.live__scroll::-webkit-scrollbar { display: none; }
.live__track { position: relative; }
.live__stage { position: sticky; top: 0; height: 100vh; overflow: hidden; cursor: ew-resize; --x: 50%; }
.live__stage iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; pointer-events: none; background: var(--bg); }
.live__clip { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--x)) 0 0); z-index: 1; }
.live__stage .bar { position: absolute; top: 0; bottom: 0; left: var(--x); width: 1px; background: var(--ink); box-shadow: 0 0 0 1px rgba(0,0,0,0.6); z-index: 2; pointer-events: none; }
.live__stage .lab { position: absolute; top: 4rem; font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink); background: rgba(4,5,10,0.72); padding: 0.35em 0.6em; z-index: 3; pointer-events: none; }
.live__stage .lab--a { left: 1rem; } .live__stage .lab--b { right: 1rem; }
.live__stage .lab--a b { color: var(--ink-2); } .live__stage .lab b { font-weight: 500; }
.live__stage .knob { position: absolute; top: 50%; left: var(--x); transform: translate(-50%, -50%); width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--ink); background: rgba(4,5,10,0.85); display: grid; place-items: center; font-family: var(--mono); font-size: 0.62rem; color: var(--ink); z-index: 2; pointer-events: none; }
.live__wait { position: absolute; inset: 0; display: grid; place-items: center; z-index: 4; background: var(--bg); font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.25em; text-transform: uppercase; color: var(--ink-3); transition: opacity 0.5s ease; }
.live__wait.gone { opacity: 0; pointer-events: none; }
.live__hud { position: absolute; left: 0; right: 0; bottom: 0; z-index: 5; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1.4rem; padding: 0.7rem var(--pad); background: rgba(4,5,10,0.86); border-top: 1px solid var(--line); backdrop-filter: blur(6px); }
.live__hud .mono b { color: var(--ink); font-weight: 500; }
.live__hud .side { display: flex; gap: 1.2rem; }
.live__hud .side a { text-decoration: none; }
.live__hud .side a:hover { color: var(--ink); }
.live__hud .side a::after { content: ' ↗'; }
.live__hud .side .a b { color: var(--ink-2); }
/* The only way out of full screen, so it is the one filled control in the bar
   and never overlaps the archived page's own chrome. */
.live__close { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.2em; text-transform: uppercase;
  padding: 0.7em 1.1em; border: 1px solid var(--ink); background: var(--ink); color: var(--bg);
  font-weight: 500; cursor: pointer; display: flex; align-items: center; gap: 0.6em; }
.live__close small { font-size: 0.78em; letter-spacing: 0.16em; opacity: 0.55; border: 1px solid currentColor; padding: 0.1em 0.4em; }
.live__close:hover { background: transparent; color: var(--ink); }

@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.7s ease, transform 0.7s ease; }
  .reveal.in { opacity: 1; transform: none; }
}
@media (max-width: 640px) {
  :root { --rail: 52px; --node-y: 3.6rem; }
  .rail .num { font-size: 1.05rem; }
  .body { padding-top: 2.2rem; }
  .spec__date { display: none; }
}
