/* ============================================================
   HUMAN ERROR — stylesheet
   Implements DESIGN.md. Tokens first, then components.
   ============================================================ */

/* ---------- 1. Tokens ---------- */

:root {
  /* Paper & ink */
  --paper:        #FBF7F0;
  --paper-raised: #FFFDF8;
  --paper-sunk:   #F2EFF5;
  --ink:          #0A0A0A;
  --ink-deep:     #1E1428;
  --ink-muted:    #3C3246;
  --ink-faint:    #6B6473;
  --rule:         rgba(10, 10, 10, 0.14);
  --rule-strong:  rgba(10, 10, 10, 0.24);
  --red:          #C03A20;
  --red-deep:     #8E2614;
  --white:        #FFFFFF;

  /* Type */
  --font-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --font-serif:   "Instrument Serif", Georgia, serif;
  --font-ui:      "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-read:    Georgia, "Times New Roman", serif;

  /* Spacing scale */
  --s-1:  4px;  --s-2:  8px;  --s-3: 12px;  --s-4: 16px;
  --s-5: 24px;  --s-6: 32px;  --s-7: 40px;  --s-8: 56px;
  --s-9: 80px;  --s-10: 120px; --s-11: 160px;

  /* Radii */
  --r-overlay: 12px;
  --r-card:    16px;
  --r-image:   20px;
  --r-pill:    100px;

  /* Elevation */
  --lift: 0 0.602187px 0.602187px -1.25px rgba(0,0,0,.18),
          0 2.28853px 2.28853px -2.5px rgba(0,0,0,.16),
          0 10px 10px -3.75px rgba(0,0,0,.06);
  --overlay-shadow: 0 20px 40px rgba(0,0,0,0.15);

  /* Motion */
  --ease: cubic-bezier(.22, 1, .36, 1);
  --ease-spring: cubic-bezier(.3, 1.28, .5, 1);
  --dur-1: 160ms;   /* state changes: color, small hovers */
  --dur-2: 280ms;   /* component moves: lifts, drawers */
  --dur-3: 520ms;   /* fades on entry */
  --dur-4: 900ms;   /* travel on entry: long, so it lands softly */
  --stagger: 70ms;  /* gap between siblings arriving */

  /* Layout */
  --gutter: 80px;
  --container: 1360px;
  --nav-h: 56px;

  /* Section rhythm. Two values, because they do different jobs:
     --section-pad is HALF the gap between two sections on the same ground,
     so stacking them produces the gap once, not twice.
     --band-pad is the inset a section with its own background needs so its
     edge does not crowd its content. */
  --section-pad: var(--s-9);
  --band-pad: var(--s-10);
}

/* ---------- 2. Reset ---------- */

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, p, figure, blockquote { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
button { font: inherit; color: inherit; border: 0; background: none; cursor: pointer; }

:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ---------- 3. Layout primitives ---------- */

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  padding-block: var(--section-pad);
}

/* A section with its own background is a band: it needs internal inset,
   and its neighbours supply the gap outside it. */
.section--sunk {
  background: var(--paper-sunk);
  padding-block: var(--band-pad);
}

/* The nav is fixed, so anchored sections must not land beneath it. */
[id] { scroll-margin-top: calc(var(--nav-h) + var(--s-5)); }

/* The signature asymmetry: full-width headline, left-column lead. */
.lead {
  max-width: 62ch;
  width: 50%;
  min-width: 320px;
  font-size: 1.125rem;
  line-height: 1.5;
  color: var(--ink-muted);
  margin-top: var(--s-5);
}

/* ---------- 4. Type ---------- */

.wordmark {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 125%;
  font-variation-settings: "wdth" 125;
  text-transform: uppercase;
  letter-spacing: -0.04em;
  line-height: 0.9;
  color: var(--ink);
}

.headline {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(2.25rem, 7vw, 6.8rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--ink-deep);
  /* em, not ch: Instrument Serif's zero is narrow, so ch under-measures badly.
     The widest line in use needs 8.64em; 9.5em leaves headroom and scales with
     the clamp at every breakpoint. */
  max-width: 9.5em;
}

/* The claim. Rationed: two per viewport, maximum. */
.headline .claim { color: var(--red); display: block; }

.subhead {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--ink-deep);
}

/* Eyebrow — always behind its 36px hairline. */
.eyebrow {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  line-height: 1.2;
  text-transform: uppercase;
  color: var(--ink-faint);
  margin-bottom: var(--s-5);
}

.eyebrow::before {
  content: "";
  width: 36px;
  height: 1px;
  background: var(--rule-strong);
  flex: none;
}

.unit-label {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 125%;
  font-variation-settings: "wdth" 125;
  font-size: 1.1rem;
  letter-spacing: -0.03em;
  line-height: 1.1;
  text-transform: uppercase;
  color: var(--ink-faint);
}

.prose {
  font-family: var(--font-read);
  font-size: 1.25rem;
  line-height: 1.6;
  color: var(--ink);
  max-width: 62ch;
}

.prose p + p { margin-top: var(--s-5); }

/* A numbered list inside long-form prose keeps its figures — unlike .takeaways,
   the sequence is the content here. */
.prose-list {
  margin-top: var(--s-5);
  margin-bottom: 0;
  padding-left: 1.3em;
  display: grid;
  gap: var(--s-4);
  max-width: 62ch;
}

.prose-list li { padding-left: var(--s-2); }
.prose-list li::marker { color: var(--ink-faint); }

.caption {
  font-size: 0.8125rem;
  line-height: 1.2;
  color: var(--ink-faint);
}

/* ---------- 5. Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  padding: 14px 24px;
  border-radius: var(--r-pill);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  background: var(--ink);
  color: var(--paper);
  transition: background 180ms var(--ease), transform 180ms var(--ease);
}

.btn .arrow { transition: transform 180ms var(--ease); }
.btn:hover { background: var(--ink-deep); }
.btn:hover .arrow { transform: translateX(4px); }
.btn:active { transform: scale(0.985); }

.btn[disabled], .btn.is-disabled {
  background: var(--ink-faint);
  cursor: not-allowed;
  pointer-events: none;
}

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--rule);
}

.btn--ghost:hover {
  background: var(--paper-raised);
  border-color: var(--rule-strong);
}

/* Text link with the sweeping underline. */
.link {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--ink);
}

.link::after {
  content: "";
  position: absolute;
  left: 0; bottom: -4px;
  width: 100%; height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 240ms var(--ease);
}

.link:hover { color: var(--red); }
.link:hover::after { transform: scaleX(1); }

/* ---------- 6. Card ---------- */

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding: var(--s-7);
  background: var(--paper-raised);
  border: 1px solid var(--rule);
  border-radius: var(--r-card);
  transition: transform 240ms var(--ease), box-shadow 240ms var(--ease);
}

.card__rule {
  width: 36px; height: 1px;
  background: var(--rule-strong);
  margin-block: var(--s-1);
}

.card__name { margin-bottom: var(--s-1); }

.card__body {
  color: var(--ink-muted);
  font-size: 1rem;
  line-height: 1.5;
  max-width: 42ch;
}

.card__foot { margin-top: auto; padding-top: var(--s-5); }

.card:hover,
.card:focus-within {
  transform: translateY(-4px);
  box-shadow: var(--lift);
}

/* An honest empty slot, not an invented company. */
.card--vacant {
  background: transparent;
  border-style: dashed;
  color: var(--ink-faint);
}

.card--vacant:hover { transform: none; box-shadow: none; }

.grid-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-5);
  margin-top: var(--s-9);
}

/* ---------- 7. Directory rows ---------- */

.directory { margin-top: var(--s-9); border-top: 1px solid var(--rule); }

.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-5);
  padding: 28px 0;
  border-bottom: 1px solid var(--rule);
  transition: background 240ms var(--ease), padding 240ms var(--ease);
}

.row__name {
  font-size: 1.5rem;
  letter-spacing: -0.03em;
  line-height: 1.1;
  transition: transform 240ms var(--ease);
}

.row__note { color: var(--ink-faint); font-size: 0.9375rem; }

.row__arrow {
  flex: none;
  display: grid;
  place-items: center;
  width: 32px; height: 32px;
  border: 1px solid var(--rule);
  border-radius: 100%;
  transition: background 240ms var(--ease), color 240ms var(--ease),
              border-color 240ms var(--ease);
}

.row:hover {
  background: var(--paper-raised);
  box-shadow: -24px 0 0 var(--paper-raised), 24px 0 0 var(--paper-raised);
}

.row:hover .row__name { transform: translateX(8px); }

.row:hover .row__arrow {
  background: var(--ink);
  color: var(--paper);
  border-color: var(--ink);
}

/* ---------- 8. Statistics ---------- */

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-7);
  border-top: 1px solid var(--rule);
  padding-top: var(--s-7);
}

.stat__value {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: 3.9rem;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--ink-deep);
}

.stat__label {
  margin-top: var(--s-3);
  font-size: 0.9375rem;
  color: var(--ink-faint);
}

/* ---------- 9. Pull-quote ---------- */

.pullquote {
  font-family: var(--font-read);
  font-size: 1.75rem;
  line-height: 1.45;
  color: var(--ink-muted);
  max-width: 48ch;
  text-indent: -0.42em;
}

.pullquote__attr {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  margin-top: var(--s-5);
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--ink);
}

.pullquote__attr::before {
  content: "";
  width: 28px; height: 1px;
  background: var(--rule-strong);
}

/* ---------- 10. Marquee ---------- */

.marquee {
  overflow: hidden;
  padding-block: var(--s-8);
  border-block: 1px solid var(--rule);
  user-select: none;
}

.marquee__track {
  display: flex;
  width: max-content;
  gap: var(--s-7);
  animation: marquee 40s linear infinite;
}

.marquee:hover .marquee__track { animation-play-state: paused; }

.marquee__item {
  font-size: clamp(2.5rem, 6vw, 5rem);
  white-space: nowrap;
}

@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* ---------- 11. Nav ---------- */

.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-5);
  padding: var(--s-4) var(--gutter);
  background: transparent;
  transition: background 240ms var(--ease), box-shadow 240ms var(--ease),
              border-color 240ms var(--ease);
  border-bottom: 1px solid transparent;
}

.nav.is-stuck {
  background: rgba(255, 253, 248, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: var(--rule);
}

.nav__mark { font-size: 1.0625rem; }

.nav__links {
  display: flex;
  gap: var(--s-6);
  font-size: 0.875rem;
  color: var(--ink-muted);
}

.nav__links a {
  position: relative;
  transition: color var(--dur-1) var(--ease);
}

.nav__links a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -6px;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform var(--dur-2) var(--ease);
}

.nav__links a:hover,
.nav__links a[aria-current="page"] { color: var(--ink); }

/* Leaves to the right, arrives from the left. */
.nav__links a:hover::after,
.nav__links a[aria-current="page"]::after {
  transform: scaleX(1);
  transform-origin: left;
}

.nav__toggle { display: none; }
.nav__panel  { display: none; }

/* Every tap target in the chrome: no 300ms delay, no grey flash. */
.nav a,
.nav button,
.nav__panel a {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.nav__toggle-chevron {
  display: inline-block;
  transition: transform 240ms var(--ease);
}

.nav__toggle[aria-expanded="true"] .nav__toggle-chevron {
  transform: rotate(180deg);
}

/* ---------- 12. Hero ---------- */

.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: var(--s-9);
  padding: 100px 20px var(--s-9);
}

/* The mark is a particle field across the full width (section 19). */
.hero__mark.ptw {
  width: 100%;
  aspect-ratio: 4 / 1;
  min-height: 120px;
  margin-inline: auto;
  border-radius: 0;
}

.hero__meta {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: calc(var(--gutter) - 20px);
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--s-7);
}

.hero__statement {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 2.6vw, 2.25rem);
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--ink-deep);
  max-width: 22ch;
}

/* ---------- 13. Footer ---------- */

.footer {
  background: var(--ink);
  color: var(--paper);
  padding-block: var(--band-pad) var(--s-7);
}

.footer .wordmark { color: var(--paper); }

/* Hairlines and rules invert with the ground. */
.footer .eyebrow::before { background: rgba(251, 247, 240, 0.35); }

.footer__top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--s-7);
  padding-bottom: var(--s-8);
}

.footer__mark { font-size: clamp(2rem, 5vw, 4rem); }

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-5);
  justify-content: space-between;
  padding-top: var(--s-5);
  border-top: 1px solid rgba(251, 247, 240, 0.18);
  font-size: 0.8125rem;
  color: rgba(251, 247, 240, 0.6);
}

.footer__bottom a:hover { color: var(--paper); }

.footer .btn {
  background: var(--paper);
  color: var(--ink);
}

.footer .btn:hover { background: var(--white); }

/* ---------- 14. Entry animation ---------- */

/* Everything here is gated on .js (set inline in <head>), so the page is
   complete and readable if scripts never run. Motion is transform and
   opacity only. Each thing arrives once and then holds still. */

/* Hiding is instant; only the arrival is animated. If a browser paints
   before the script has grouped things, nothing fades out and back in. */
.js .reveal {
  opacity: 0;
  transform: translate3d(0, 18px, 0);
}

.js .reveal.is-in {
  opacity: 1;
  transform: none;
  transition: opacity var(--dur-3) var(--ease), transform var(--dur-4) var(--ease);
}

/* What opens the page is hidden from the first frame, before any script,
   so it cannot flash. The inline script in <head> drops .js again if
   main.js never arrives, which shows everything. */
.js .hero__meta:not(.is-done) > *,
.js .page-head > .container:not(.is-done) > *,
.js .ref-head > .container:not(.is-done) > * {
  opacity: 0;
  transform: translate3d(0, 14px, 0);
}

/* A group stays put and sends its children in one after another.
   main.js numbers them (--i). Once the entry has played it adds .is-done,
   which releases every child back to its own transitions and hovers. */
.js .reveal--group,
.js .reveal--group.is-in { opacity: 1; transform: none; transition: none; }

.js .reveal--group:not(.is-done) > * {
  opacity: 0;
  transform: translate3d(0, 14px, 0);
}

.js .reveal--group.is-in:not(.is-done) > * {
  opacity: 1;
  transform: none;
  transition: opacity var(--dur-3) var(--ease), transform var(--dur-4) var(--ease);
  transition-delay: calc(var(--i, 0) * var(--stagger));
}

/* Headlines do not fade. Each line rises out from behind its own baseline,
   the claim a beat after the line it answers. */
.headline { text-wrap: balance; }

.headline .line {
  display: block;
  overflow: hidden;
  /* Room for descenders, so the mask never shaves a g or a y. */
  padding-bottom: 0.14em;
  margin-bottom: -0.14em;
}

.headline .line__in { display: block; }

.js .reveal--group:not(.is-done) > .headline { opacity: 1; transform: none; }

.js .reveal--group:not(.is-done) .line__in { transform: translate3d(0, 108%, 0); }

.js .reveal--group.is-in:not(.is-done) .line__in {
  transform: none;
  transition: transform var(--dur-4) var(--ease);
  transition-delay: calc(var(--i, 0) * var(--stagger) + var(--l, 0) * 110ms);
}

/* The eyebrow's hairline draws itself from the left. */
.js .reveal--group:not(.is-done) .eyebrow::before {
  transform: scaleX(0);
  transform-origin: left;
}

.js .reveal--group.is-in:not(.is-done) .eyebrow::before {
  transform: scaleX(1);
  transition: transform var(--dur-4) var(--ease);
  transition-delay: calc(var(--i, 0) * var(--stagger) + 120ms);
}

/* The home hero waits for the mark to finish arriving. */
.js .hero__meta.reveal--group.is-in:not(.is-done) > * {
  transition-delay: calc(300ms + var(--i, 0) * 120ms);
}

/* ---------- 15. Responsive ---------- */

@media (max-width: 1439px) {
  :root { --gutter: 56px; }
}

@media (max-width: 1023px) {
  :root {
    --gutter: 40px;
    --section-pad: var(--s-8);
    --band-pad: 88px;
  }
  .grid-cards { grid-template-columns: repeat(2, 1fr); }
  .lead { width: 66.666%; }
  .stat__value { font-size: 2.75rem; }
}

@media (max-width: 767px) {
  :root {
    --gutter: 20px;
    --section-pad: 48px;
    --band-pad: var(--s-8);
  }

  .lead { width: 100%; min-width: 0; }

  .grid-cards { grid-template-columns: 1fr; margin-top: var(--s-7); }

  .card { padding: var(--s-5); }

  .directory { margin-top: var(--s-7); }

  /* Rows keep their arrows, drop the hover bleed. */
  .row:hover { background: transparent; box-shadow: none; }
  .row:hover .row__name { transform: none; }

  .stats {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .stat {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: var(--s-5);
    padding-block: var(--s-5);
    border-bottom: 1px solid var(--rule);
  }

  .stat__value { font-size: 2.5rem; }
  .stat__label { margin-top: 0; text-align: right; }

  /* On a phone the hero sizes to its content. A full-height, centred hero
     left a screen of dead paper above the mark and below the button. */
  .hero {
    min-height: 0;
    justify-content: flex-start;
    gap: var(--s-7);
    padding: calc(var(--nav-h) + var(--s-9)) 20px var(--s-9);
  }
  .hero__meta { gap: var(--s-6); }

  /* Headroom so the quotes never touch the gutters on a narrow phone. */
  .ptw-fallback { font-size: clamp(1.5rem, 8.6vw, 3rem); }
  .hero__meta { padding-inline: 0; }

  .nav__links { display: none; }
  .nav__cta  { display: none; }

  .nav__toggle {
    display: inline-flex;
    align-items: center;
    gap: var(--s-2);
    font-size: 0.875rem;
    font-weight: 600;
  }

  /* The drawer. Laid out at all times so it can animate; hidden with
     visibility so it stays out of the tab order and the a11y tree. */
  .nav__panel {
    position: fixed;
    inset: var(--nav-h) 0 auto 0;
    z-index: 49;
    display: flex;
    flex-direction: column;
    padding: var(--s-2) var(--gutter) var(--s-6);
    background: var(--paper-raised);
    border-bottom: 1px solid var(--rule);
    box-shadow: var(--overlay-shadow);

    max-height: calc(100svh - var(--nav-h));
    overflow-y: auto;
    overscroll-behavior: contain;

    opacity: 0;
    visibility: hidden;
    transform: translateY(-12px);
    transition:
      opacity 200ms var(--ease),
      transform 200ms var(--ease),
      visibility 0s linear 200ms;
  }

  .nav__panel.is-open {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition:
      opacity 260ms var(--ease),
      transform 260ms var(--ease),
      visibility 0s;
  }

  /* Items read as the directory rows they echo, and arrive just behind
     the panel so the drawer resolves rather than appears all at once. */
  .nav__panel a:not(.btn) {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--s-4);
    min-height: 56px;
    font-size: 1.5rem;
    letter-spacing: -0.03em;
    line-height: 1.1;
    color: var(--ink);
    border-bottom: 1px solid var(--rule);
  }

  .nav__panel a:not(.btn):active { color: var(--red); }

  .nav__panel-arrow { color: var(--ink-faint); }

  .nav__panel .btn {
    align-self: flex-start;
    margin-top: var(--s-6);
    min-height: 44px;
  }

  .nav__panel > * {
    opacity: 0;
    transform: translateY(-6px);
    transition:
      opacity 180ms var(--ease),
      transform 180ms var(--ease);
  }

  .nav__panel.is-open > * { opacity: 1; transform: none; }

  .nav__panel.is-open > :nth-child(1) { transition-delay: 50ms; }
  .nav__panel.is-open > :nth-child(2) { transition-delay: 85ms; }
  .nav__panel.is-open > :nth-child(3) { transition-delay: 120ms; }
  .nav__panel.is-open > :nth-child(4) { transition-delay: 155ms; }

  .pullquote { font-size: 1.375rem; }
}

/* ---------- 16. Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  .marquee__track { animation: none; }

  .js .reveal,
  .js .hero__meta:not(.is-done) > *,
  .js .page-head > .container:not(.is-done) > *,
  .js .ref-head > .container:not(.is-done) > *,
  .js .reveal--group:not(.is-done) > *,
  .js .reveal--group:not(.is-done) .line__in {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .js .reveal--group:not(.is-done) .eyebrow::before { transform: scaleX(1); transition: none; }
  .feature:hover .card__mark { transform: none; }
  .read-progress { display: none; }

  .card:hover, .card:focus-within { transform: none; }
  .row:hover .row__name { transform: none; }

  .nav__panel,
  .nav__panel.is-open { transform: none; }
  .nav__panel > *,
  .nav__panel.is-open > * { transform: none; transition-delay: 0s; }
  .nav__toggle[aria-expanded="true"] .nav__toggle-chevron { transform: none; }
  .btn:hover .arrow { transform: none; }
  .btn:active { transform: none; }

  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ---------- 17. Holding mark ----------
   A held company keeps its own identity: its logo sits as drawn, in its own
   colors. The one image permitted inside a card. */

.card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
}

.card__mark {
  flex: none;
  width: 56px;
  height: 56px;
  border-radius: 12px;
  object-fit: contain;
}

/* An honestly empty slot shows the well and nothing in it. */
.card__mark--empty {
  border: 1px dashed var(--rule-strong);
  background: transparent;
}

/* ---------- 18. Featured build ----------
   One real build gets the full width; the pipeline is a line, not empty cards. */

.feature {
  display: grid;
  grid-template-columns: minmax(200px, 1fr) 2fr;
  gap: var(--s-8);
  align-items: start;
  margin-top: var(--s-9);
  padding: var(--s-8);
}

.feature .card__head { flex-direction: column; align-items: flex-start; gap: var(--s-5); }
.feature .card__mark { width: 88px; height: 88px; border-radius: 18px; }
.feature .card__body { font-size: 1.125rem; max-width: 52ch; }
.feature:hover, .feature:focus-within { transform: none; box-shadow: none; }

.pipeline {
  margin-top: var(--s-5);
  font-size: 0.9375rem;
  color: var(--ink-faint);
}

.pipeline strong {
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 125%;
  font-variation-settings: "wdth" 125;
  letter-spacing: -0.03em;
  color: var(--ink-muted);
}

/* Fields: a short, quiet section — breaks the eyebrow/headline/lead rhythm. */
.section--tight { padding-block: var(--s-8); }
.section--tight .directory { margin-top: var(--s-6); }

/* Status rows aren't links: no hover, no arrow. */
div.row:hover { background: transparent; box-shadow: none; }
div.row:hover .row__name { transform: none; }

/* Approach: the line that was buried in the prose becomes the headline. */
.headline--statement { max-width: 12em; }

/* ---------- 19. Hero mark, made of particles ----------
   js/particle-word.js draws the word as a few hundred particles. They rest
   in ink and run toward Correction Red as they speed up. The plain-text
   fallback holds the place: hidden once scripts run, shown again if the
   particles never arrive. */

.ptw {
  --tone: #0A0A0A;      /* var(--ink); spelled out because the script parses it */
  --tone-hot: #C03A20;  /* var(--red) */
  position: relative;
  display: block;
  width: clamp(300px, 94%, 620px);
  aspect-ratio: 3 / 2;
  padding: 0;
  border: 0;
  border-radius: 20px;
  background: transparent;
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 125%;
  font-variation-settings: "wdth" 125;
  cursor: crosshair;
  touch-action: pan-y;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-user-select: none;
}

.ptw:focus-visible { outline: 2px solid var(--red); outline-offset: -2px; }

.ptw-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  opacity: 0;
  transition: opacity var(--dur-3) var(--ease);
}

.ptw.is-live .ptw-canvas { opacity: 1; }

.ptw-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: clamp(1.75rem, 7.8vw, 7.8rem);
  white-space: nowrap;
  color: var(--ink);
  pointer-events: none;
}

.js .ptw-fallback { visibility: hidden; }
.js .ptw.is-failed:not(.is-live) .ptw-fallback { visibility: visible; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

@media (max-width: 767px) {
  .feature { grid-template-columns: 1fr; gap: var(--s-5); padding: var(--s-5); margin-top: var(--s-7); }
  .feature .card__head { flex-direction: row; align-items: center; justify-content: space-between; }
  .feature .card__mark { width: 56px; height: 56px; border-radius: 12px; }
  .section--tight { padding-block: var(--s-7); }
}

/* ---------- 20. The Archive ----------
   An index of issues, and the issue pages themselves. Reuses the directory
   row; adds a page head, a year marker and the takeaways block. */

/* A page that opens on text rather than the full-viewport hero. */
.page-head { padding: calc(var(--nav-h) + var(--s-9)) 0 var(--s-7); }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  min-height: 44px;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--ink-faint);
  transition: color 180ms var(--ease);
}

.back-link:hover { color: var(--ink); }

.archive-count {
  margin-top: var(--s-5);
  font-size: 1.125rem;
  color: var(--ink-muted);
  font-variant-numeric: tabular-nums;
}

/* Year marker: a label with a rule running out to the edge. */
.archive-year {
  display: flex;
  align-items: center;
  gap: var(--s-4);
  margin-top: var(--s-8);
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 125%;
  font-variation-settings: "wdth" 125;
  font-size: 1.1rem;
  letter-spacing: -0.03em;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
}

.archive-year::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--rule);
}

.archive-list { margin-top: var(--s-5); border-top: 1px solid var(--rule); }

/* Title takes the slack so it sits beside its number instead of drifting
   into the middle of the row. */
.archive-list .row__name { flex: 1; }

/* Dates line up, so they get tabular figures. */
.row__note { font-variant-numeric: tabular-nums; }

.row__index {
  flex: none;
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 125%;
  font-variation-settings: "wdth" 125;
  font-size: 0.9375rem;
  letter-spacing: -0.03em;
  color: var(--ink-faint);
}

/* ---------- 21. An issue ---------- */

.issue__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-5);
  margin-top: var(--s-6);
  padding-top: var(--s-5);
  border-top: 1px solid var(--rule);
  font-size: 0.875rem;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
}

.issue__body { margin-top: var(--s-9); }

.issue__body h3 {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(1.5rem, 2.6vw, 2rem);
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--ink-deep);
  margin-top: var(--s-8);
  margin-bottom: var(--s-4);
  max-width: 24ch;
}

/* What people can take away. One per issue, at the end. */
.takeaways {
  margin-top: var(--s-9);
  padding: var(--s-7);
  background: var(--paper-raised);
  border: 1px solid var(--rule);
  border-radius: var(--r-card);
  max-width: 62ch;
}

.takeaways ol {
  /* The reset only clears ul; this ol carries its own counter. */
  list-style: none;
  padding: 0;
  counter-reset: take;
  display: grid;
  gap: var(--s-5);
  margin-top: var(--s-5);
}

/* Positioned marker, not a grid column: inline <strong> or <code> inside the
   item would otherwise become a grid item and break the sentence apart. */
.takeaways li {
  counter-increment: take;
  position: relative;
  padding-left: 2.75rem;
  font-size: 1.0625rem;
  line-height: 1.5;
  color: var(--ink-muted);
}

.takeaways li::before {
  content: counter(take, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 0;
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 125%;
  font-variation-settings: "wdth" 125;
  font-size: 0.9375rem;
  letter-spacing: -0.03em;
  color: var(--red);
  font-variant-numeric: tabular-nums;
}

.takeaways li strong { color: var(--ink); font-weight: 600; }

@media (max-width: 767px) {
  .page-head { padding-top: calc(var(--nav-h) + var(--s-7)); }
  .takeaways { padding: var(--s-5); }
  .row__index { display: none; }
}

/* ---------- 22. Small motion ---------- */

/* The one build on the page: its mark leans in when you reach for it. */
.feature .card__mark { transition: transform var(--dur-3) var(--ease-spring); }
.feature:hover .card__mark { transform: rotate(-4deg) scale(1.05); }

/* Reading progress on an issue. Driven by scroll position on the compositor,
   no script. Browsers without scroll timelines simply never show it. */
.read-progress {
  position: fixed;
  inset: 0 0 auto 0;
  height: 2px;
  z-index: 60;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  pointer-events: none;
}

@supports (animation-timeline: scroll()) {
  .read-progress {
    animation: read-progress linear both;
    animation-timeline: scroll(root);
  }
}

@keyframes read-progress { to { transform: scaleX(1); } }

/* ---------- 23. Page to page ----------
   Same-origin navigations cross-fade instead of blinking, and the nav holds
   still through the change, so only the page beneath it moves. */

@view-transition { navigation: auto; }

.nav { view-transition-name: site-nav; }

::view-transition-old(root) {
  animation: vt-out var(--dur-1) var(--ease) both;
}

::view-transition-new(root) {
  animation: vt-in var(--dur-3) var(--ease) both;
}

@keyframes vt-out { to { opacity: 0; } }
@keyframes vt-in  { from { opacity: 0; transform: translate3d(0, 10px, 0); } }

@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
}
