/* ==========================================================================
   OLA Alumni Platform — Proposal
   Greyfeathers · for the Old Lawrencians' Association, Lawrence School Lovedale
   ========================================================================== */

:root {
  --paper:      #F2EEE5;
  --paper-2:    #E9E3D6;
  --paper-3:    #DED6C5;
  --ink:        #14202E;
  --graphite:   #33322F;
  --pencil:     #6E6A62;
  --pencil-2:   #9A958A;
  --pine:       #2C4A3B;
  --brass:      #A97C3F;
  --madder:     #93372A;
  --rule:       rgba(20, 32, 46, 0.13);
  --rule-soft:  rgba(20, 32, 46, 0.07);

  --serif: 'Cormorant Garamond', 'Iowan Old Style', 'Palatino Linotype', Palatino, Georgia, serif;
  --sans:  'Inter', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --hand:  'Caveat', 'Bradley Hand', 'Segoe Script', cursive;
  --mono:  ui-monospace, 'SF Mono', 'Cascadia Mono', Menlo, monospace;

  --shell: min(1180px, 92vw);
  --ease:  cubic-bezier(0.22, 0.61, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(17px, 1.05vw + 13px, 20px);
  line-height: 1.62;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* Paper grain — a single inline SVG turbulence, no network request. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.82' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='220' height='220' filter='url(%23n)' opacity='0.4'/%3E%3C/svg%3E");
  mix-blend-mode: multiply;
}

/* ---------- typography primitives ---------- */

h1, h2, h3, h4 {
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -0.015em;
  margin: 0;
  text-wrap: balance;
}

h2 { font-size: clamp(2.3rem, 4.6vw, 4.1rem); }
h3 { font-size: clamp(1.5rem, 2.3vw, 2.1rem); }

p { margin: 0 0 1.1em; text-wrap: pretty; }

a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 1px; }

.eyebrow {
  font-family: var(--sans);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--brass);
  margin: 0 0 1.4rem;
  display: flex;
  align-items: center;
  gap: 0.9rem;
}
.eyebrow::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, var(--rule), transparent);
}

.lede {
  font-size: clamp(1.22rem, 1.7vw, 1.62rem);
  line-height: 1.5;
  color: var(--graphite);
  max-width: 34ch;
}

.hand {
  font-family: var(--hand);
  font-size: 1.35em;
  line-height: 1.3;
  color: var(--pencil);
}

.tabular { font-variant-numeric: tabular-nums; }

/* ---------- layout ---------- */

.shell {
  width: var(--shell);
  margin-inline: auto;
  position: relative;
  z-index: 1;
}

section { position: relative; z-index: 1; }

.band { padding: clamp(6rem, 13vh, 11rem) 0; }
.band--tight { padding: clamp(4rem, 8vh, 6.5rem) 0; }

.band--dark {
  background: var(--ink);
  color: var(--paper);
}
.band--dark .eyebrow { color: #D2A868; }
.band--dark .lede { color: rgba(242, 238, 229, 0.74); }
.band--dark .hand { color: rgba(242, 238, 229, 0.6); }

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(2.5rem, 6vw, 6rem);
  align-items: start;
}

.rule {
  height: 1px;
  background: var(--rule);
  border: 0;
  margin: 0;
}

/* ==========================================================================
   ACT 0 — the OLA overture
   ========================================================================== */

#overture {
  position: fixed;
  inset: 0;
  z-index: 90;
  background: var(--paper);
  display: grid;
  place-items: center;
  transition: opacity 1s var(--ease), visibility 1s;
}
#overture.done { opacity: 0; visibility: hidden; pointer-events: none; }

.overture-stage {
  width: min(1000px, 90vw);
  text-align: center;
}

.monogram { width: 100%; height: auto; overflow: visible; }

.monogram .stroke {
  fill: none;
  stroke: var(--ink);
  stroke-width: 3.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Each letter draws itself, then the expansion word writes in beside it. */
.expansion {
  font-family: var(--serif);
  font-size: 58px;
  fill: var(--graphite);
  opacity: 0;
  letter-spacing: 0.01em;
}

.overture-tag {
  font-family: var(--sans);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--pencil-2);
  opacity: 0;
  margin-top: 2.4rem;
}

.skip {
  position: absolute;
  bottom: 2rem;
  right: 2rem;
  font-family: var(--sans);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pencil-2);
  background: none;
  border: 0;
  cursor: pointer;
  padding: 0.7rem 1rem;
  transition: color 0.3s;
}
.skip:hover { color: var(--ink); }

/* ==========================================================================
   ACT 1 — the sketch that draws itself
   ========================================================================== */

#sketch-act { height: 560vh; position: relative; }

.sketch-pin {
  position: sticky;
  top: 0;
  height: 100svh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  align-items: center;
  overflow: hidden;
}

.sketch-frame {
  position: relative;
  width: min(1500px, 96vw);
  margin-inline: auto;
}

#lovedale { width: 100%; height: auto; display: block; overflow: visible; }

/* No vector-effect: non-scaling-stroke here, deliberately. WebKit applies
   stroke-dasharray in device space when it is set, while Chrome and Firefox
   keep dashes in user space. Our dash lengths come from getTotalLength(),
   which is user space, so on Safari every long stroke was cut short by the
   scale factor — the drawing appeared broken on iPad while looking correct
   in Chromium. Strokes now scale with the artwork; the media queries below
   keep them from thinning to threads on small screens. */
#lovedale .ln {
  fill: none;
  stroke: var(--graphite);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
#lovedale .ln--fine  { stroke-width: 1;   stroke: var(--pencil); }
#lovedale .ln--faint { stroke-width: 0.9; stroke: var(--pencil-2); }
#lovedale .ln--bold  { stroke-width: 2.4; }

/* Graphite hatching sits under the linework and fades in per chapter. */
#lovedale .wash {
  fill: var(--graphite);
  opacity: 0;
  transition: opacity 0.9s var(--ease);
}
#lovedale .wash.lit { opacity: 0.055; }

.sketch-caption {
  position: absolute;
  left: 0;
  bottom: -1rem;
  max-width: 30ch;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
  pointer-events: none;
}
.sketch-caption.on { opacity: 1; transform: none; }
.sketch-caption .n {
  font-family: var(--sans);
  font-size: 0.64rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--brass);
  display: block;
  margin-bottom: 0.5rem;
}
.sketch-caption p { font-size: 1.02rem; line-height: 1.45; margin: 0; color: var(--graphite); }

.sketch-head {
  text-align: center;
  padding-top: clamp(1.5rem, 5vh, 3.5rem);
}
.sketch-head .kicker {
  font-family: var(--sans);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--pencil-2);
}

.scroll-cue {
  justify-self: center;
  padding-bottom: 2rem;
  font-family: var(--sans);
  font-size: 0.64rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--pencil-2);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.7rem;
  transition: opacity 0.5s;
}
.scroll-cue i {
  width: 1px;
  height: 34px;
  background: linear-gradient(var(--pencil-2), transparent);
  animation: cue 2.1s var(--ease) infinite;
}
@keyframes cue {
  0%   { transform: scaleY(0); transform-origin: top; }
  45%  { transform: scaleY(1); transform-origin: top; }
  55%  { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

/* The progress bar reads as a pencil laying down graphite. */
.draw-progress {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 5.2rem;
  width: min(420px, 62vw);
  height: 2px;
  background: var(--rule-soft);
}
.draw-progress span {
  display: block;
  height: 100%;
  width: 0%;
  background: var(--graphite);
}

/* ==========================================================================
   The gap — 8,000 / 4,000 / 5,000
   ========================================================================== */

.figure-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.5rem, 4vw, 3.5rem);
  margin-top: 4rem;
}
.figure-stat .v {
  font-size: clamp(3.4rem, 7vw, 6rem);
  line-height: 0.92;
  letter-spacing: -0.03em;
  display: block;
  font-variant-numeric: tabular-nums;
}
.figure-stat .k {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pencil);
  margin-top: 1rem;
  display: block;
}
.figure-stat .d { font-size: 0.95rem; color: var(--pencil); margin-top: 0.6rem; }
.band--dark .figure-stat .k,
.band--dark .figure-stat .d { color: rgba(242, 238, 229, 0.55); }

/* dot field visualising 8,000 OLs */
#dotfield { width: 100%; height: auto; display: block; margin-top: 3rem; }

/* ==========================================================================
   Notable alumni
   ========================================================================== */

.ol-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 1px;
  background: var(--rule);
  border-block: 1px solid var(--rule);
  margin-top: 3.5rem;
}
.ol {
  background: var(--paper);
  padding: 2rem 1.6rem 2.2rem;
  transition: background 0.4s var(--ease);
}
.ol:hover { background: var(--paper-2); }
.ol .yr {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: var(--brass);
}
.ol .nm { font-size: 1.3rem; margin: 0.7rem 0 0.4rem; line-height: 1.15; }
.ol .rl { font-family: var(--sans); font-size: 0.82rem; color: var(--pencil); line-height: 1.5; }

/* ==========================================================================
   Interactive demo blocks
   ========================================================================== */

.demo {
  border: 1px solid var(--rule);
  background: rgba(255, 255, 255, 0.42);
  margin-top: 3rem;
}

.demo-bar {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  padding: 0.85rem 1.2rem;
  border-bottom: 1px solid var(--rule);
  background: var(--paper-2);
}
.demo-bar .dots { display: flex; gap: 6px; }
.demo-bar .dots i {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--pencil-2); opacity: 0.5;
}
.demo-bar .ttl {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pencil);
}
.demo-bar .live {
  margin-left: auto;
  font-family: var(--sans);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--pine);
  display: flex; align-items: center; gap: 0.45rem;
}
.demo-bar .live::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: var(--pine); animation: pulse 2s infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.25; } }

.demo-body { padding: clamp(1.4rem, 3vw, 2.4rem); }

.demo-grid {
  display: grid;
  grid-template-columns: minmax(0, 300px) minmax(0, 1fr);
  gap: clamp(1.6rem, 3.5vw, 3rem);
  align-items: start;
}

/* controls */
.ctl { margin-bottom: 1.7rem; }
.ctl label {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--pencil);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 0.7rem;
}
.ctl label b {
  font-family: var(--serif);
  font-size: 1.45rem;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 22px;
  background: none;
  cursor: grab;
}
input[type="range"]:active { cursor: grabbing; }
input[type="range"]::-webkit-slider-runnable-track {
  height: 2px; background: var(--rule);
}
input[type="range"]::-moz-range-track { height: 2px; background: var(--rule); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 18px; height: 18px; margin-top: -8px;
  border-radius: 50%;
  background: var(--ink);
  border: 3px solid var(--paper);
  box-shadow: 0 0 0 1px var(--ink);
  transition: transform 0.18s var(--ease);
}
input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.18); }
input[type="range"]::-moz-range-thumb {
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--ink); border: 3px solid var(--paper);
  box-shadow: 0 0 0 1px var(--ink);
}

.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chip {
  font-family: var(--sans);
  font-size: 0.76rem;
  padding: 0.5rem 0.9rem;
  border: 1px solid var(--rule);
  background: transparent;
  color: var(--graphite);
  cursor: pointer;
  border-radius: 100px;
  transition: all 0.22s var(--ease);
}
.chip:hover { border-color: var(--pencil); }
.chip.on { background: var(--ink); color: var(--paper); border-color: var(--ink); }

.btn {
  font-family: var(--sans);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.85rem 1.5rem;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  cursor: pointer;
  transition: all 0.22s var(--ease);
}
.btn:hover { background: transparent; color: var(--ink); }
.btn--ghost { background: transparent; color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: var(--paper); }

/* readouts */
.readouts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  margin-top: 1.6rem;
}
.readout { background: var(--paper); padding: 1.1rem 1rem; }
.readout .v {
  font-size: 1.85rem;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  display: block;
}
.readout .k {
  font-family: var(--sans);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--pencil);
  margin-top: 0.55rem;
  display: block;
}

.assumption {
  font-family: var(--sans);
  font-size: 0.72rem;
  line-height: 1.6;
  color: var(--pencil);
  border-left: 2px solid var(--rule);
  padding-left: 0.9rem;
  margin-top: 1.6rem;
}

/* charts */
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart .axis { stroke: var(--rule); stroke-width: 1; }
.chart .gridline { stroke: var(--rule-soft); stroke-width: 1; }
.chart .tick {
  font-family: var(--sans);
  font-size: 10px;
  fill: var(--pencil-2);
  letter-spacing: 0.08em;
}
.chart .series { fill: none; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

/* house leaderboard */
.house-row {
  display: grid;
  grid-template-columns: 132px 1fr 68px;
  align-items: center;
  gap: 1rem;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--rule-soft);
}
.house-row .h-name { font-size: 1.08rem; }
.house-row .h-motto {
  font-family: var(--sans);
  font-size: 0.64rem;
  letter-spacing: 0.08em;
  color: var(--pencil-2);
  display: block;
  margin-top: 2px;
}
.h-track { height: 12px; background: var(--paper-3); position: relative; overflow: hidden; }
.h-fill {
  position: absolute; inset: 0 auto 0 0;
  width: 0%;
  transition: width 0.9s var(--ease);
}
.house-row .h-pts {
  text-align: right;
  font-variant-numeric: tabular-nums;
  font-size: 1.05rem;
}

/* personal graph canvas */
.graph-wrap {
  position: relative;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  aspect-ratio: 16 / 10;
}
#graph { width: 100%; height: 100%; display: block; }
.graph-hint {
  position: absolute;
  left: 1rem; bottom: 1rem;
  font-family: var(--sans);
  font-size: 0.7rem;
  color: var(--pencil);
  background: rgba(242, 238, 229, 0.86);
  padding: 0.4rem 0.7rem;
  pointer-events: none;
}

/* AI search demo */
.searchbox {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  border: 1px solid var(--ink);
  padding: 0.95rem 1.1rem;
  background: var(--paper);
}
.searchbox input {
  flex: 1;
  border: 0;
  background: none;
  font-family: var(--serif);
  font-size: 1.1rem;
  color: var(--ink);
  outline: none;
  min-width: 0;
}
.searchbox input::placeholder { color: var(--pencil-2); }

.result {
  border-bottom: 1px solid var(--rule-soft);
  padding: 0.95rem 0;
  opacity: 0;
  transform: translateY(8px);
  animation: rise 0.5s var(--ease) forwards;
}
@keyframes rise { to { opacity: 1; transform: none; } }
.result .r-nm { font-size: 1.06rem; }
.result .r-mt {
  font-family: var(--sans);
  font-size: 0.74rem;
  color: var(--pencil);
  margin-top: 0.25rem;
}

.meter { height: 6px; background: var(--paper-3); margin-top: 0.6rem; }
.meter span { display: block; height: 100%; background: var(--brass); width: 0%; transition: width 0.5s var(--ease); }

.switch {
  display: inline-flex; align-items: center; gap: 0.7rem;
  font-family: var(--sans); font-size: 0.74rem; color: var(--pencil);
  cursor: pointer; user-select: none;
}
.switch i {
  width: 38px; height: 21px; border-radius: 100px;
  background: var(--paper-3); position: relative;
  transition: background 0.28s var(--ease);
}
.switch i::after {
  content: ""; position: absolute; top: 3px; left: 3px;
  width: 15px; height: 15px; border-radius: 50%;
  background: var(--paper);
  box-shadow: 0 1px 3px rgba(0,0,0,.25);
  transition: transform 0.28s var(--ease);
}
.switch.on i { background: var(--pine); }
.switch.on i::after { transform: translateX(17px); }

/* event P&L */
.ledger { width: 100%; border-collapse: collapse; font-family: var(--sans); font-size: 0.86rem; }
.ledger th {
  text-align: left;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--pencil);
  padding: 0 0 0.8rem;
  border-bottom: 1px solid var(--rule);
}
.ledger td { padding: 0.7rem 0; border-bottom: 1px solid var(--rule-soft); }
.ledger td:last-child, .ledger th:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.ledger input {
  width: 92px;
  border: 0;
  border-bottom: 1px dashed var(--pencil-2);
  background: none;
  font-family: var(--sans);
  font-size: 0.86rem;
  color: var(--ink);
  text-align: right;
  padding: 2px 0;
  outline: none;
  font-variant-numeric: tabular-nums;
}
.ledger input:focus { border-bottom-color: var(--ink); }
.ledger td.grp {
  text-align: left;
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brass);
  padding: 1.4rem 0 0.35rem;
  border-bottom: 0;
}
.ledger tr:first-child td.grp { padding-top: 0.4rem; }

.ledger tr.total td {
  border-bottom: 0;
  border-top: 2px solid var(--ink);
  padding-top: 0.9rem;
  font-weight: 600;
  font-size: 1rem;
}

/* ==========================================================================
   Roadmap
   ========================================================================== */

.phase {
  display: grid;
  grid-template-columns: minmax(0, 0.6fr) minmax(0, 1.4fr);
  gap: clamp(1.5rem, 5vw, 4.5rem);
  padding: clamp(3rem, 6vw, 5rem) 0;
  border-top: 1px solid var(--rule);
}
.phase-tag {
  font-family: var(--sans);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--brass);
}
.phase h3 { margin: 0.9rem 0 1rem; }
.phase .when { font-family: var(--sans); font-size: 0.78rem; color: var(--pencil); }

.feat {
  border-bottom: 1px solid var(--rule-soft);
  padding: 1.15rem 0;
  display: grid;
  grid-template-columns: 26px 1fr;
  gap: 1rem;
  opacity: 0;
  transform: translateY(16px);
}
.feat.in { opacity: 1; transform: none; transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
.feat .no {
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--pencil-2);
  padding-top: 0.35rem;
}
.feat .ft { font-size: 1.16rem; line-height: 1.3; }
.feat .fd { font-family: var(--sans); font-size: 0.85rem; line-height: 1.6; color: var(--pencil); margin-top: 0.4rem; }

/* ==========================================================================
   Terms, next steps, close
   ========================================================================== */

.terms { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 2.5rem; margin-top: 3.5rem; }
.term h4 { font-size: 1.2rem; margin-bottom: 0.6rem; }
.term p { font-family: var(--sans); font-size: 0.87rem; line-height: 1.65; color: var(--pencil); margin: 0; }
.band--dark .term p { color: rgba(242, 238, 229, 0.62); }

.countdown {
  display: flex;
  align-items: baseline;
  gap: 1.2rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}
.countdown .big {
  font-size: clamp(3rem, 8vw, 6.5rem);
  line-height: 0.9;
  letter-spacing: -0.04em;
  font-variant-numeric: tabular-nums;
}

.steps { list-style: none; padding: 0; margin: 3rem 0 0; counter-reset: s; }
.steps li {
  counter-increment: s;
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 1.2rem;
  padding: 1.4rem 0;
  border-top: 1px solid var(--rule);
  align-items: start;
}
.steps li::before {
  content: counter(s, decimal-leading-zero);
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--brass);
  padding-top: 0.4rem;
}
.steps li .who {
  font-family: var(--sans);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--pencil-2);
  margin-top: 0.35rem;
  display: block;
}

.close-mark { text-align: center; padding: clamp(6rem, 16vh, 12rem) 0; }
.close-mark .motto {
  font-size: clamp(3rem, 9vw, 8rem);
  line-height: 1;
  letter-spacing: -0.03em;
}
.close-mark .years {
  font-family: var(--mono);
  font-size: 0.8rem;
  letter-spacing: 0.3em;
  color: var(--pencil);
  margin-top: 2rem;
}

.colophon {
  border-top: 1px solid var(--rule);
  padding: 2.5rem 0 4rem;
  font-family: var(--sans);
  font-size: 0.76rem;
  color: var(--pencil);
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
}

/* ---------- reveal-on-scroll ---------- */
.rv { opacity: 0; transform: translateY(24px); }
.rv.in { opacity: 1; transform: none; transition: opacity 0.85s var(--ease), transform 0.85s var(--ease); }

/* ---------- progress rail ---------- */
#rail {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 2px;
  z-index: 80;
  background: transparent;
}
#rail span { display: block; height: 100%; width: 0%; background: var(--brass); }

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 900px) {
  .split, .demo-grid, .phase { grid-template-columns: 1fr; }
  .figure-row { grid-template-columns: 1fr; gap: 2.5rem; }
  #sketch-act { height: 420vh; }
  .sketch-caption { position: static; margin-top: 1.5rem; max-width: none; }
  .draw-progress { bottom: 3.4rem; }
  .house-row { grid-template-columns: 96px 1fr 54px; gap: 0.7rem; }
  .expansion { font-size: 40px; }
}

@media (max-width: 560px) {
  .ol-grid { grid-template-columns: 1fr; }
  .colophon { flex-direction: column; }
  .ledger input { width: 74px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .rv, .feat { opacity: 1; transform: none; }
}

@media print {
  #overture, #rail, .scroll-cue, .draw-progress { display: none !important; }
  #sketch-act { height: auto; }
  .sketch-pin { position: static; height: auto; }
  .rv, .feat, .sketch-caption { opacity: 1 !important; transform: none !important; }
  .band { padding: 2rem 0; }
}

/* ==========================================================================
   PROLOGUE — the opening motion sequence
   ========================================================================== */

#prologue { height: 640vh; position: relative; }

.prologue-pin {
  position: sticky;
  top: 0;
  height: 100svh;
  display: grid;
  grid-template-rows: auto 1fr auto auto;
  align-content: center;
  overflow: hidden;
}

.prologue-stage { display: grid; place-items: center; min-height: 0; }
.prologue-svg { width: min(1200px, 94vw); height: auto; max-height: 62svh; overflow: visible; }

.prologue-svg .pl-ln {
  fill: none; stroke: var(--graphite); stroke-width: 1.5;
  stroke-linecap: round; stroke-linejoin: round;
}
.prologue-svg .pl-ln--bold  { stroke-width: 2.1; }
.prologue-svg .pl-ln--faint { stroke: var(--pencil-2); stroke-width: 1; }
.prologue-svg .pl-rule { stroke: var(--rule); stroke-width: 1; }

.prologue-svg .pl-year {
  font-family: var(--mono); font-size: 11px; fill: var(--pencil-2); letter-spacing: .12em;
}
.prologue-svg .pl-paper { fill: var(--paper); stroke: var(--pencil-2); stroke-width: 1.2; }
.prologue-svg .pl-scribble { stroke: var(--pencil-2); stroke-width: 1.4; opacity: .5; }
.prologue-svg .pl-paper-lbl {
  font-family: var(--sans); font-size: 10px; fill: var(--pencil); letter-spacing: .04em;
}
.prologue-svg .pl-card { fill: none; stroke: var(--ink); stroke-width: 1.4; }
.prologue-svg .pl-card-lbl {
  font-family: var(--sans); font-size: 14px; font-weight: 500; fill: var(--ink); letter-spacing: .05em;
}
.prologue-svg .pl-feed { fill: none; stroke: var(--brass); stroke-width: 1.3; }
.prologue-svg .pl-core-lbl {
  font-family: var(--sans); font-size: 11px; font-weight: 600;
  fill: var(--brass); letter-spacing: .2em;
}
.prologue-svg .pl-synapse { stroke: var(--pine); stroke-width: 1; opacity: .45; }
.prologue-svg .pl-node { fill: var(--pine); }
.prologue-svg .pl-bond { fill: none; stroke: var(--graphite); stroke-width: 1.1; opacity: .38; }

.prologue-caption {
  text-align: center;
  max-width: 60ch;
  margin: 0 auto;
  padding: clamp(1.6rem, 5vh, 3.4rem) 1.5rem 0;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity .5s var(--ease), transform .5s var(--ease);
}
.prologue-caption.on { opacity: 1; transform: none; }
.prologue-caption .pk {
  display: block;
  font-family: var(--sans);
  font-size: .66rem; font-weight: 600;
  letter-spacing: .24em; text-transform: uppercase;
  color: var(--brass);
  margin-bottom: .9rem;
}
.prologue-caption p {
  font-size: clamp(1.18rem, 1.95vw, 1.68rem);
  line-height: 1.45; color: var(--ink); margin: 0;
  text-wrap: pretty;
}

/* ==========================================================================
   CURRENT -> FUTURE
   ========================================================================== */

.shiftgrid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
  margin-top: 3.5rem;
}
.shiftcol { border: 1px solid var(--rule); padding: 2rem 1.8rem; }
.shiftcol h3 { font-size: 1.15rem; margin-bottom: 1.2rem; }
.shiftcol ul { list-style: none; margin: 0; padding: 0; }
.shiftcol li {
  font-family: var(--sans); font-size: .87rem; line-height: 1.5;
  padding: .6rem 0 .6rem 1.2rem; position: relative;
  border-bottom: 1px solid var(--rule-soft);
}
.shiftcol li:last-child { border-bottom: 0; }
.shiftcol li::before {
  content: ""; position: absolute; left: 0; top: 1.05rem;
  width: 5px; height: 1px; background: var(--pencil-2);
}
.shiftcol--now { background: transparent; color: var(--pencil); }
.shiftcol--now h3 { color: var(--pencil); }
.shiftcol--next { background: rgba(255,255,255,.5); border-color: var(--ink); }
.shiftcol--next li::before { background: var(--brass); width: 7px; height: 2px; }
.shiftarrow { color: var(--pencil-2); width: 90px; }
.shiftarrow svg { width: 100%; height: auto; display: block; }

/* ==========================================================================
   CONSTRAINTS TABLE
   ========================================================================== */

.ctable { margin-top: 3.5rem; border-top: 1px solid var(--rule); }
.ctrow {
  display: grid;
  grid-template-columns: minmax(0, 0.34fr) minmax(0, 1fr);
  gap: clamp(1rem, 4vw, 3rem);
  padding: 1.6rem 0;
  border-bottom: 1px solid var(--rule);
}
.ctrow .ck {
  font-family: var(--sans); font-size: .7rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase; color: var(--brass);
  padding-top: .25rem;
}
.ctrow .cv { font-size: 1.05rem; line-height: 1.55; }

/* ==========================================================================
   OLA HQ DIAGRAM
   ========================================================================== */

.hqwrap { margin: 3.5rem auto 0; max-width: 760px; }
#hqdiagram { width: 100%; height: auto; display: block; overflow: visible; }

#hqdiagram .hq-spoke { stroke: rgba(242,238,229,.3); stroke-width: 1; }
#hqdiagram .hq-hub circle { fill: none; stroke: #D2A868; stroke-width: 2; }
#hqdiagram .hq-hub-inner { stroke: rgba(210,168,104,.34) !important; stroke-width: 1 !important; }
#hqdiagram .hq-hub-t {
  font-family: var(--serif); font-size: 26px; fill: var(--paper);
}
#hqdiagram .hq-hub-s {
  font-family: var(--sans); font-size: 9px; font-weight: 600;
  letter-spacing: .18em; fill: rgba(242,238,229,.55);
}
#hqdiagram .hq-node circle { fill: var(--ink); stroke: rgba(242,238,229,.55); stroke-width: 1.2; }
#hqdiagram .hq-node--passion circle { stroke-dasharray: 4 4; }
#hqdiagram .hq-node text {
  font-family: var(--sans); font-size: 12.5px; fill: var(--paper); letter-spacing: .02em;
}
#hqdiagram .hq-legend text {
  font-family: var(--sans); font-size: 11px; fill: rgba(242,238,229,.55); letter-spacing: .06em;
}
#hqdiagram .hq-key { fill: none; stroke: rgba(242,238,229,.55); stroke-width: 1.2; }
#hqdiagram .hq-key--passion { stroke-dasharray: 3 3; }

.hqflow {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2.5rem; margin-top: 3.5rem;
}
.hqf-arrow {
  display: inline-block; font-size: 1.4rem; color: #D2A868; line-height: 1; margin-bottom: .7rem;
}
.hqf h4 { font-size: 1.15rem; margin-bottom: .55rem; }
.hqf p {
  font-family: var(--sans); font-size: .87rem; line-height: 1.65;
  color: rgba(242,238,229,.62); margin: 0;
}

/* ==========================================================================
   WAVE PLAN EXTRAS
   ========================================================================== */

.wave-note {
  font-family: var(--sans); font-size: .78rem; line-height: 1.6;
  color: var(--pencil); margin-top: 1.2rem;
  border-left: 2px solid var(--rule); padding-left: .9rem;
}

.yearbar {
  display: flex; gap: 3px; margin-top: 3.5rem; height: 46px;
}
.yearbar .yb {
  width: var(--w); background: var(--paper-3);
  display: grid; place-items: center; position: relative;
  transition: background .3s var(--ease);
}
.yearbar .yb:nth-child(odd) { background: var(--paper-2); }
.yearbar .yb span {
  font-family: var(--sans); font-size: .66rem; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase; color: var(--pencil);
}

.feat--flag { background: rgba(169,124,63,.055); }
.flag-mark {
  display: inline-block; margin-left: .7rem; vertical-align: middle;
  font-family: var(--sans); font-size: .56rem; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--madder); border: 1px solid rgba(147,55,42,.4);
  padding: .18rem .45rem; border-radius: 2px;
}

/* ==========================================================================
   CAPABILITY CARDS
   ========================================================================== */

.caps {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 1px; background: var(--rule);
  border: 1px solid var(--rule); margin-top: 3.5rem;
}
.cap { background: var(--paper); padding: 2.2rem 1.9rem; }
.cap h3 { font-size: 1.28rem; margin-bottom: .9rem; }
.cap ul { list-style: none; margin: 1.4rem 0 0; padding: 0; }
.cap li {
  font-family: var(--sans); font-size: .85rem; line-height: 1.6;
  color: var(--graphite); padding: .8rem 0;
  border-top: 1px solid var(--rule-soft);
}
.cap li.warn { padding-left: 1.5rem; position: relative; }
.cap li.warn::before {
  content: "!"; position: absolute; left: 0; top: .85rem;
  width: 15px; height: 15px; border-radius: 50%;
  border: 1px solid var(--madder); color: var(--madder);
  font-size: .6rem; font-weight: 700; line-height: 13px; text-align: center;
}
.verdict {
  display: inline-block;
  font-family: var(--sans); font-size: .62rem; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase;
  padding: .3rem .6rem; border-radius: 2px;
}
.verdict--ok   { color: var(--pine);   background: rgba(44,74,59,.09); }
.verdict--warn { color: var(--madder); background: rgba(147,55,42,.09); }

/* ==========================================================================
   STORY BROWSER
   ========================================================================== */

.story-filters { display: grid; gap: 1rem; margin-bottom: 1.6rem; }
.filter-row { display: grid; grid-template-columns: 58px 1fr; gap: 1rem; align-items: start; }
.filter-lbl {
  font-family: var(--sans); font-size: .62rem; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase; color: var(--pencil-2);
  padding-top: .62rem;
}
.story-count {
  font-family: var(--mono); font-size: .72rem; color: var(--pencil);
  border-top: 1px solid var(--rule); padding-top: 1rem; margin: 0 0 .5rem;
}
.story-group { margin-top: 2rem; }
.story-group h4 {
  font-family: var(--sans); font-size: .68rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase; color: var(--brass);
  display: flex; align-items: center; gap: .8rem;
  padding-bottom: .7rem; border-bottom: 1px solid var(--rule);
}
.story-group h4 span {
  font-family: var(--mono); font-size: .66rem; color: var(--pencil-2);
  letter-spacing: .04em; margin-left: auto;
}
.story {
  display: grid; grid-template-columns: 116px 1fr; gap: 1.1rem;
  padding: .85rem 0; border-bottom: 1px solid var(--rule-soft);
  align-items: start;
}
.story p { margin: 0; font-size: .98rem; line-height: 1.5; }
.story p em { color: var(--pencil); font-style: italic; }
.role-tag {
  font-family: var(--sans); font-size: .58rem; font-weight: 600;
  letter-spacing: .1em; text-transform: uppercase;
  padding: .28rem .5rem; border-radius: 2px; text-align: center;
  margin-top: .2rem;
}
.role--alumnus   { color: var(--ink);    background: rgba(20,32,46,.08); }
.role--chapter   { color: var(--pine);   background: rgba(44,74,59,.1); }
.role--organiser { color: var(--brass);  background: rgba(169,124,63,.12); }
.role--admin     { color: var(--madder); background: rgba(147,55,42,.09); }
.role--treasurer { color: #2B4668;       background: rgba(43,70,104,.1); }
.role--donor     { color: var(--pencil); background: rgba(110,106,98,.1); }

/* ==========================================================================
   DECISIONS
   ========================================================================== */

.decisions { list-style: none; padding: 0; margin: 3.5rem 0 0; counter-reset: d; }
.decisions li {
  counter-increment: d;
  display: grid; grid-template-columns: 52px 1fr; gap: 1.4rem;
  padding: 2rem 0; border-top: 1px solid var(--rule);
}
.decisions li::before {
  content: counter(d, decimal-leading-zero);
  font-family: var(--mono); font-size: .8rem; color: var(--brass); padding-top: .35rem;
}
/* ::before counts as a grid item, so without this the heading takes column 2
   and the paragraph wraps into column 1 of the next row — i.e. into the 52px
   number gutter, one word per line. Pin all real content to column 2. */
.decisions li > * { grid-column: 2; }
.decisions h4 { font-size: 1.35rem; margin-bottom: .6rem; }
.decisions p {
  font-family: var(--sans); font-size: .88rem; line-height: 1.65;
  color: var(--pencil); margin: 0; max-width: 62ch;
}

/* ==========================================================================
   Responsive additions
   ========================================================================== */

@media (max-width: 900px) {
  #prologue { height: 500vh; }
  .shiftgrid { grid-template-columns: 1fr; }
  .shiftarrow { justify-self: center; transform: rotate(90deg); width: 60px; }
  .ctrow { grid-template-columns: 1fr; gap: .6rem; }
  .story { grid-template-columns: 1fr; gap: .5rem; }
  .role-tag { justify-self: start; }
  .filter-row { grid-template-columns: 1fr; gap: .5rem; }
  .filter-lbl { padding-top: 0; }
  .decisions li { grid-template-columns: 1fr; gap: .5rem; }
  .decisions li::before { padding-top: 0; }
  .yearbar { height: 38px; }
  .yearbar .yb span { font-size: .55rem; letter-spacing: .06em; }
}

@media print {
  #prologue { height: auto; }
  .prologue-pin { position: static; height: auto; }
  .prologue-caption { opacity: 1 !important; transform: none !important; }
}

/* Module icons in the prologue: same weight as the card outline. */
.prologue-svg .pl-icon path {
  fill: none;
  stroke: var(--ink);
  stroke-width: 1.25;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ==========================================================================
   Deck controls — step the prologue beats like slides
   ========================================================================== */

.deck {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(1rem, 3vw, 1.8rem);
  padding-bottom: .9rem;
}

/* At the last beat the forward arrow points down and this cue appears, so the
   viewer is never parked on a pinned screen wondering what to do next. Fixed
   height means showing it does not shift the deck. */
.deck-cue {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  height: 1.5rem;
  margin: 0 0 clamp(1.2rem, 3.5vh, 2.2rem);
  font-family: var(--sans);
  font-size: .66rem; font-weight: 600;
  letter-spacing: .2em; text-transform: uppercase;
  color: var(--brass);
  opacity: 0; transform: translateY(-5px);
  transition: opacity .5s var(--ease), transform .5s var(--ease);
  pointer-events: none;
  cursor: pointer;
}
.deck-cue.on { opacity: 1; transform: none; pointer-events: auto; }
.deck-cue i {
  width: 7px; height: 7px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  animation: cuebob 1.9s var(--ease) infinite;
}
@keyframes cuebob {
  0%, 100% { transform: rotate(45deg) translate(0, 0); }
  50%      { transform: rotate(45deg) translate(2.5px, 2.5px); }
}
.deck-cue:focus-visible { outline: 2px solid var(--brass); outline-offset: 4px; }

/* Forward arrow becomes a "continue down" control on the final beat. */
.deck-arrow.is-continue svg { transform: rotate(90deg); }
.deck-arrow svg { transition: transform .3s var(--ease); }
.deck-arrow.is-continue {
  background: var(--ink); border-color: var(--ink); color: var(--paper);
}

.deck-arrow {
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid var(--rule);
  background: transparent;
  color: var(--graphite);
  display: grid; place-items: center;
  cursor: pointer;
  transition: background .22s var(--ease), color .22s var(--ease), border-color .22s var(--ease), opacity .22s;
}
.deck-arrow svg { width: 16px; height: 16px; display: block; }
.deck-arrow:hover:not(:disabled) { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.deck-arrow:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; }
.deck-arrow:disabled { opacity: .25; cursor: default; }

.deck-dots { display: flex; align-items: center; gap: .6rem; }
.deck-dot {
  width: 8px; height: 8px; padding: 0;
  border-radius: 50%;
  border: 1px solid var(--pencil-2);
  background: transparent;
  cursor: pointer;
  transition: background .22s var(--ease), border-color .22s var(--ease), transform .22s var(--ease);
}
.deck-dot.past { background: var(--pencil-2); }
.deck-dot.on { background: var(--ink); border-color: var(--ink); transform: scale(1.35); }
.deck-dot:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; }

/* ==========================================================================
   The 25th — the monthly scoping ritual
   ========================================================================== */

.ritual {
  display: grid;
  grid-template-columns: minmax(0, 190px) minmax(0, 1fr);
  gap: clamp(1.6rem, 4vw, 3.5rem);
  align-items: start;
  margin-top: clamp(3rem, 6vw, 4.5rem);
  padding: clamp(2rem, 4vw, 3rem);
  border: 1px solid var(--ink);
  background: rgba(255, 255, 255, .5);
}
.ritual-date {
  text-align: center;
  border-right: 1px solid var(--rule);
  padding-right: clamp(1rem, 3vw, 2rem);
}
.ritual-date .d {
  display: block;
  font-size: clamp(4.5rem, 9vw, 7rem);
  line-height: .86;
  letter-spacing: -.045em;
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}
.ritual-date .m {
  display: block;
  font-family: var(--sans);
  font-size: .64rem; font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--brass);
  margin-top: .9rem;
}
.ritual-body h3 { font-size: clamp(1.4rem, 2.2vw, 1.95rem); margin-bottom: 1rem; }
.ritual-body p { font-size: 1.02rem; line-height: 1.6; color: var(--graphite); margin-bottom: .8rem; }
.ritual-note {
  font-family: var(--sans) !important;
  font-size: .85rem !important;
  color: var(--pencil) !important;
  border-left: 2px solid var(--brass);
  padding-left: .9rem;
  margin: 1.2rem 0 0 !important;
}

/* ==========================================================================
   The ask, closing the decisions
   ========================================================================== */

.close-ask {
  margin-top: clamp(3rem, 6vw, 4.5rem);
  padding-top: clamp(2.4rem, 5vw, 3.4rem);
  border-top: 2px solid var(--ink);
}
.close-ask h3 { font-size: clamp(1.9rem, 3.4vw, 2.9rem); margin-bottom: 1.2rem; }
.close-ask p { max-width: 56ch; color: var(--graphite); }
.ask-people {
  font-family: var(--sans);
  font-size: .9rem;
  line-height: 2;
  color: var(--pencil) !important;
  margin-top: 2rem !important;
}
.ask-people strong { color: var(--ink); }

/* ==========================================================================
   Engagement — fee and what it buys
   ========================================================================== */

.fee {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  gap: 1px;
  background: var(--ink);
  border: 1px solid var(--ink);
  margin-top: 3.5rem;
}
.fee-main {
  background: var(--ink);
  color: var(--paper);
  padding: clamp(2.2rem, 5vw, 3.4rem);
  display: flex; flex-direction: column; justify-content: center;
}
.fee-k {
  font-family: var(--sans);
  font-size: .64rem; font-weight: 600;
  letter-spacing: .2em; text-transform: uppercase;
  color: #D2A868;
}
.fee-v {
  font-size: clamp(3rem, 7vw, 5.2rem);
  line-height: 1;
  letter-spacing: -.035em;
  font-variant-numeric: tabular-nums;
  margin: 1.1rem 0 .7rem;
}
.fee-s {
  font-family: var(--sans);
  font-size: .84rem;
  color: rgba(242, 238, 229, .66);
  letter-spacing: .04em;
}
.fee-side {
  background: var(--paper);
  padding: clamp(1.4rem, 3vw, 2.2rem) clamp(1.6rem, 3.5vw, 2.6rem);
  display: flex; flex-direction: column; justify-content: center;
}
.fee-row {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: 1rem;
  padding: 1.05rem 0;
  border-bottom: 1px solid var(--rule-soft);
}
.fee-row:last-child { border-bottom: 0; }
.fee-row .k {
  font-family: var(--sans);
  font-size: .64rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--pencil-2);
}
.fee-row .v { font-size: 1.15rem; color: var(--ink); text-align: right; }

.incl {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
  margin-top: 3rem;
}
.incl-item {
  background: var(--paper);
  padding: clamp(1.8rem, 3vw, 2.4rem);
  transition: background .4s var(--ease);
}
.incl-item:hover { background: rgba(255, 255, 255, .55); }
.incl-n {
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--brass);
  display: block;
  margin-bottom: 1rem;
}
.incl-item h3 { font-size: 1.28rem; line-height: 1.2; margin-bottom: .8rem; }
.incl-item p {
  font-family: var(--sans);
  font-size: .87rem; line-height: 1.65;
  color: var(--pencil);
  margin: 0;
}

@media (max-width: 760px) {
  .ritual { grid-template-columns: 1fr; }
  .ritual-date {
    border-right: 0; border-bottom: 1px solid var(--rule);
    padding: 0 0 1.4rem; text-align: left;
    display: flex; align-items: baseline; gap: 1rem;
  }
  .ritual-date .m { margin-top: 0; }
  .fee { grid-template-columns: 1fr; }
}

/* ==========================================================================
   Wave stages — design, approval gate, development, testing, production
   ========================================================================== */

.stages {
  margin-top: 1.8rem;
  border-top: 1px solid var(--rule);
}
.stage {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: .68rem 0 .68rem 1.1rem;
  border-bottom: 1px solid var(--rule-soft);
  position: relative;
}
/* the rail that reads as one continuous run through the wave */
.stage::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 1px;
  background: var(--rule);
}
.stage .s-n {
  font-family: var(--sans);
  font-size: .72rem; font-weight: 500;
  letter-spacing: .08em;
  color: var(--graphite);
}
.stage .s-w {
  font-family: var(--mono);
  font-size: .72rem;
  color: var(--pencil);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.stage--design { background: rgba(169, 124, 63, .07); }
.stage--design .s-n { color: var(--brass); font-weight: 600; }
.stage--design::before { background: var(--brass); width: 2px; }

.stage--total {
  border-bottom: 0;
  border-top: 1px solid var(--ink);
  padding-top: .8rem;
  margin-top: .2rem;
}
.stage--total::before { display: none; }
.stage--total .s-n { color: var(--ink); font-weight: 600; }
.stage--total .s-w { color: var(--ink); font-size: .82rem; }

/* the gate is the point of the whole strip: nothing is built before this */
.gate {
  position: relative;
  padding: .5rem 0 .5rem 1.1rem;
  border-bottom: 1px solid var(--rule-soft);
}
.gate::before {
  content: "";
  position: absolute;
  left: -3px; top: 50%;
  width: 7px; height: 7px;
  margin-top: -3.5px;
  border-radius: 50%;
  background: var(--brass);
}
.gate span {
  font-family: var(--sans);
  font-size: .6rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--brass);
}

.stages-none {
  font-family: var(--sans);
  font-size: .78rem; line-height: 1.6;
  color: var(--pencil);
  margin-top: 1.6rem;
  padding-top: 1.2rem;
  border-top: 1px solid var(--rule);
}

/* programme bar carries its week count */
.yearbar .yb em {
  display: block;
  font-family: var(--mono);
  font-style: normal;
  font-size: .58rem;
  color: var(--pencil-2);
  margin-top: .2rem;
  letter-spacing: .04em;
}

/* ==========================================================================
   Link button, and the story teaser
   ========================================================================== */

.btn-link {
  display: inline-flex;
  align-items: center;
  gap: .8rem;
  font-family: var(--sans);
  font-size: .76rem; font-weight: 500;
  letter-spacing: .1em; text-transform: uppercase;
  text-decoration: none;
  padding: .95rem 1.6rem;
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  transition: background .22s var(--ease), color .22s var(--ease);
}
.btn-link svg { width: 15px; height: 15px; transition: transform .22s var(--ease); }
.btn-link:hover { background: transparent; color: var(--ink); }
.btn-link:hover svg { transform: translateX(3px); }
.btn-link:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; }

.story-stat {
  font-family: var(--mono);
  font-size: .78rem;
  color: var(--pencil);
  margin-top: 1.6rem;
  letter-spacing: .04em;
}
.story-stat strong { color: var(--ink); font-weight: 500; }

/* ==========================================================================
   Sub-pages (the backlog)
   ========================================================================== */

body.subpage .shell { padding: clamp(2.5rem, 6vh, 4.5rem) 0 5rem; }

.backlink {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  font-family: var(--sans);
  font-size: .68rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase;
  color: var(--pencil);
  text-decoration: none;
  margin-bottom: clamp(2rem, 5vh, 3.5rem);
  transition: color .22s var(--ease);
}
.backlink svg { width: 13px; height: 13px; transition: transform .22s var(--ease); }
.backlink:hover { color: var(--ink); }
.backlink:hover svg { transform: translateX(-3px); }

.sub-head { margin-bottom: clamp(2.5rem, 5vh, 3.5rem); }
.sub-head h1 {
  font-size: clamp(2.4rem, 5vw, 4rem);
  font-weight: 500;
  line-height: 1.06;
  letter-spacing: -.02em;
  margin: 0 0 1.6rem;
  text-wrap: balance;
}
.subpage .colophon { margin-top: 4rem; }
.subpage .colophon a { color: var(--pencil); text-decoration: none; }
.subpage .colophon a:hover { color: var(--ink); }

/* ==========================================================================
   Grid hairlines without the empty-cell artefact

   These grids drew their dividing lines with `gap:1px` over a rule-coloured
   container background. That works only when the item count fills every cell:
   any leftover cell paints as a solid grey block. With auto-fit columns the
   leftover count changes with the viewport — the alumni grid showed four grey
   blocks at 1440px. Borders on the items instead, so a missing cell shows
   nothing at all.
   ========================================================================== */

.ol-grid, .caps, .incl, .readouts {
  gap: 0;
  background: transparent;
  border: 0;
  border-top: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}
.ol, .cap, .incl-item, .readout {
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
}

/* multi-paragraph inclusion cards need air between paragraphs */
.incl-item p + p { margin-top: .85rem; }

/* Column counts chosen so the item counts divide evenly, rather than letting
   auto-fit strand one card alone on a final row: 6 alumni as 3x2, 4 capability
   cards as 2x2, 4 readouts always across. */
.ol-grid { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.caps    { grid-template-columns: repeat(auto-fit, minmax(430px, 1fr)); }
.readouts { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 620px) {
  .readouts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Stroke weight compensation, now that strokes scale with the drawing.
   #lovedale is a 1600-unit viewBox in a min(1500px, 96vw) frame, so the scale
   runs from ~0.94 on a wide desktop down to ~0.23 on a phone. Without these
   the linework would render well under a pixel on small screens. */
@media (max-width: 1100px) {
  #lovedale .ln        { stroke-width: 2.4; }
  #lovedale .ln--fine  { stroke-width: 1.6; }
  #lovedale .ln--faint { stroke-width: 1.4; }
  #lovedale .ln--bold  { stroke-width: 3.4; }
}
@media (max-width: 700px) {
  #lovedale .ln        { stroke-width: 4.2; }
  #lovedale .ln--fine  { stroke-width: 2.8; }
  #lovedale .ln--faint { stroke-width: 2.4; }
  #lovedale .ln--bold  { stroke-width: 6; }
}
