/* Found and Failed v3: "case file + split" (approved direction AB, 2026-11-15).
   Archive paper and manila tabs carry the system; the picture is split by one red seam:
   the company that died in grey with a SHUT DOWN stamp, the one that won in colour.
   Red = died, yellow = won (Kelvin option 5, 2026-11-15); the seam is red | ink | yellow. Two fonts: Archivo + IBM Plex Mono (self-hosted, OFL). */
@font-face { font-family: "Archivo"; src: url("fonts/archivo.woff2") format("woff2"); font-weight: 100 900; font-stretch: 62% 125%; font-display: swap; }
@font-face { font-family: "Plex Mono"; src: url("fonts/plexmono-medium.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Plex Mono"; src: url("fonts/plexmono-bold.woff2") format("woff2"); font-weight: 700; font-display: swap; }

:root {
  --paper: #f1eadb;     /* page */
  --manila: #d8c6a0;    /* tabs, bands */
  --manila-2: #c9b68c;  /* tab shadow edge */
  --ink: #141519;       /* text */
  --ink-2: #3d4149;     /* secondary text (AA on paper) */
  --slate: #59616b;     /* the dead side, rules */
  --red: #e0301e;       /* died: stamp, seam left band (paper on red = 3.8:1, large text only) */
  --yellow: #f5c518;    /* won: labels, seam right band (ink on yellow = 11.2:1) */
  --red-ink: #b02a17;   /* red for small text on paper (AA) */
  --sans: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --mono: "Plex Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;
  --gut: clamp(16px, 4.5vw, 64px);
  --max: 1312px;        /* 1440 - 2 x 64: one edge for every block */
  --measure: 65ch;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  color-scheme: light;
}
:root { --hair: #cdbf9f; }
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 1.1875rem/1.65 var(--sans); font-stretch: 100%;
  text-rendering: optimizeLegibility;
}
::selection { background: var(--red); color: var(--paper); }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration-color: var(--red); text-underline-offset: 0.2em; text-decoration-thickness: 2px; }
a:hover { color: var(--red-ink); }
:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; }
h1, h2, h3 { margin: 0; text-wrap: balance; font-weight: 800; letter-spacing: -0.02em; }
p { text-wrap: pretty; }
.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--gut)); margin-inline: auto; padding-inline: var(--gut); }
.skip { position: absolute; left: 8px; top: 0; transform: translateY(-120%); background: var(--ink); color: var(--paper); padding: 8px 12px; z-index: 9; }
.skip:focus { transform: none; }

/* mono label voice: case numbers, dates, nav */
.kicker, .tab, .case-meta, .mast nav, .timeline time, .ledger dt, .figures dt, .mark-kicker, .byline {
  font-family: var(--mono); font-weight: 500; letter-spacing: 0.04em;
}

/* ---------- masthead */
.mast { border-bottom: 2px solid var(--ink); }
.mast-in { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-block: 14px; }
.mark { text-decoration: none; display: grid; gap: 2px; }
.mark-kicker { font-size: 0.6875rem; text-transform: uppercase; color: var(--red-ink); }
.mark-word { display: flex; align-items: stretch; gap: 10px; font: 900 1.5rem/1 var(--sans); letter-spacing: -0.01em; text-transform: uppercase; }
.mw-found { color: var(--ink); }
.mw-failed { color: var(--ink); }
.mw-seam { width: 6px; background: linear-gradient(90deg, var(--red) 0 33%, var(--ink) 33% 67%, var(--yellow) 67%); }
.mast nav { display: flex; gap: clamp(14px, 3vw, 32px); font-size: 0.8125rem; text-transform: uppercase; }
.mast nav a { text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.mast nav a:hover { text-decoration: underline; color: var(--ink); }
.mast nav .sub { color: var(--red-ink); }

/* ---------- home front */
.front { padding-block: clamp(40px, 8vw, 112px) clamp(32px, 5vw, 64px); }
.front h1 { font-size: clamp(2.375rem, 6.2vw, 5.5rem); line-height: 0.98; letter-spacing: -0.035em; font-stretch: 88%; max-width: 15ch; }
.h-won { color: inherit; }
.stand { color: var(--ink-2); font-size: clamp(1.125rem, 1.6vw, 1.3125rem); max-width: 40rem; margin: 28px 0 0; }

/* ---------- the split (signature device) */
.split { margin: 0; display: grid; grid-template-columns: 1fr 12px 1fr; }
.side { position: relative; overflow: hidden; background: var(--slate); }
.side img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.died img { filter: grayscale(1) contrast(0.95) brightness(0.72); }
.died::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgb(22 24 29 / 0.7), transparent 55%); }
.won img { filter: saturate(1.1); }
.seam { background: linear-gradient(90deg, var(--red) 0 33%, var(--ink) 33% 67%, var(--yellow) 67%); }
.tab {
  position: absolute; z-index: 2; left: 0; top: 0; margin: 0;
  background: var(--manila); color: var(--red-ink); font-weight: 700; font-size: clamp(0.8125rem, 1.2vw, 1rem);
  padding: 8px 16px 8px clamp(12px, 2vw, 24px); box-shadow: inset 0 -2px 0 var(--manila-2);
}
.tag { position: absolute; z-index: 2; left: clamp(12px, 2vw, 28px); right: 12px; top: clamp(52px, 6vw, 72px); margin: 0; display: grid; gap: 4px; color: var(--paper); }
.tag .who { font: 900 clamp(2rem, 5vw, 4.5rem)/0.95 var(--sans); letter-spacing: -0.02em; text-transform: uppercase; }
.tag .when { font: 500 0.875rem/1.3 var(--mono); letter-spacing: 0.04em; }
.stamp {
  position: absolute; z-index: 2; left: clamp(12px, 2vw, 28px); bottom: clamp(14px, 2.4vw, 32px); margin: 0;
  background: var(--red); color: var(--paper); text-transform: uppercase;
  font: 900 clamp(1.125rem, 2.6vw, 2.25rem)/1 var(--sans); letter-spacing: 0.01em;
  padding: 0.32em 0.5em; outline: 2px solid var(--paper); outline-offset: -6px;
  transform: rotate(-4deg); transform-origin: 30% 60%;
}
.won-label {
  position: absolute; z-index: 2; left: 0; bottom: clamp(14px, 2.4vw, 32px); margin: 0;
  background: var(--yellow); color: var(--ink); text-transform: uppercase;
  font: 900 clamp(1rem, 2.2vw, 1.875rem)/1 var(--sans); padding: 0.4em 0.6em 0.4em clamp(12px, 2vw, 28px);
}
.split figcaption { grid-column: 1 / -1; font-size: 0.875rem; line-height: 1.45; color: var(--ink-2); padding-top: 10px; }
.split-big .side img { aspect-ratio: 16 / 10; }

/* one authored moment on load: the stamp lands. Transform only; nothing is ever hidden. */
@media (prefers-reduced-motion: no-preference) {
  .stamp { animation: stamp-in 420ms var(--ease-out) 200ms both; }
  @keyframes stamp-in { from { transform: rotate(-9deg) scale(1.18); } to { transform: rotate(-4deg) scale(1); } }
}

/* ---------- home cases */
.cases { display: grid; gap: clamp(56px, 8vw, 112px); }
.case-link { text-decoration: none; display: block; }
.case-link h2 { font-size: clamp(1.75rem, 3.6vw, 3rem); line-height: 1.05; margin-top: 22px; max-width: 24ch; }
.case-link:hover h2 { text-decoration: underline; text-decoration-color: var(--red); text-decoration-thickness: 3px; }
.case-link .won img { transition: transform 600ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .case-link:hover .won img { transform: scale(1.02); } }
.case-sum { max-width: var(--measure); color: var(--ink-2); margin: 14px 0 0; }
.case-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 24px; margin: 12px 0 0; font-size: 0.875rem; text-transform: uppercase; }
.case-meta span { color: var(--red-ink); font-weight: 700; }
.case-meta a { display: inline-flex; align-items: center; min-height: 44px; }

.rule-two { margin-top: clamp(80px, 11vw, 144px); padding-block: clamp(32px, 5vw, 56px) 0; display: grid; gap: 24px; }
.rule-two::before { content: ""; grid-column: 1 / -1; height: 8px; background: var(--manila); box-shadow: inset 0 -2px 0 var(--manila-2); }
.pull { margin: 0; font: 900 clamp(2rem, 4.6vw, 3.75rem)/1.02 var(--sans); letter-spacing: -0.03em; max-width: 14ch; }
.rule-body { max-width: var(--measure); color: var(--ink-2); }

/* ---------- article */
.file-head { padding-block: clamp(36px, 6vw, 88px) clamp(28px, 4vw, 48px); }
.kicker { margin: 0 0 16px; font-size: 0.875rem; text-transform: uppercase; color: var(--red-ink); font-weight: 700; }
.file-head h1 { font-size: clamp(2.375rem, 6.4vw, 5.25rem); line-height: 1; letter-spacing: -0.035em; font-stretch: 88%; max-width: 18ch; }
.answer { font-size: clamp(1.25rem, 2vw, 1.5rem); line-height: 1.45; margin: 26px 0 0; max-width: 40rem; }
.byline { color: var(--ink-2); font-size: 0.8125rem; margin: 20px 0 0; }

.file-body { display: grid; grid-template-columns: minmax(0, 1fr); padding-top: clamp(40px, 6vw, 80px); }
.file-body > * { min-width: 0; }
.ledger dl { margin: 0; display: grid; border-top: 2px solid var(--ink); }
.ledger dl > div { padding: 12px 0; border-bottom: 1px solid var(--hair); display: grid; grid-template-columns: 9rem 1fr; gap: 12px; }
.ledger dt, .figures dt { font-size: 0.75rem; line-height: 1.5; text-transform: uppercase; color: var(--ink-2); padding-top: 4px; }
.ledger dd { margin: 0; font-weight: 600; }
.won-ink { color: var(--ink); }

.sec { margin-top: clamp(56px, 8vw, 96px); }
.sec h2 { font-size: clamp(1.75rem, 3.2vw, 2.5rem); line-height: 1.08; margin-bottom: 24px; }
.sec p { max-width: var(--measure); }

.timeline { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--slate); }
.timeline li { position: relative; padding: 0 0 24px 24px; }
.timeline li::before { content: ""; position: absolute; left: -7px; top: 9px; width: 12px; height: 2px; background: var(--slate); }
.timeline time { font-size: 0.875rem; color: var(--red-ink); font-weight: 700; }
.timeline p { margin: 2px 0 0; max-width: var(--measure); }

.player { margin: clamp(56px, 8vw, 96px) 0 0; }
.lite { all: unset; cursor: pointer; display: block; position: relative; width: 100%; }
.lite img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.lite:focus-visible { outline: 3px solid var(--red); outline-offset: 4px; }
.play {
  position: absolute; left: 0; bottom: 0; display: flex; align-items: center; gap: 10px;
  background: var(--yellow); color: var(--ink); padding: 14px 20px 14px 16px;
  font: 800 0.9375rem/1 var(--sans); text-transform: uppercase;
  transition: transform 160ms var(--ease-out);
}
.play svg { width: 20px; height: 20px; fill: currentColor; }
.lite:active .play { transform: scale(0.97); }
.player iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; display: block; }

.figures { margin: 0; border-top: 2px solid var(--ink); }
.figures > div { display: grid; gap: 2px; padding: 16px 0; border-bottom: 1px solid var(--hair); }
.figures dd { margin: 0; font-size: clamp(1.5rem, 2.8vw, 2rem); line-height: 1.15; font-weight: 800; font-variant-numeric: lining-nums tabular-nums; }

.won-sec { border-top: 8px solid var(--yellow); padding-top: 28px; }
.won-sec .lead { font-size: clamp(1.25rem, 2vw, 1.5rem); line-height: 1.45; }

.qa { border-top: 1px solid var(--hair); max-width: var(--measure); }
.qa:last-of-type { border-bottom: 1px solid var(--hair); }
.qa summary { list-style: none; cursor: pointer; display: grid; grid-template-columns: 1fr 20px; gap: 16px; align-items: center; padding: 16px 0; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after {
  content: ""; width: 14px; height: 14px; justify-self: end;
  background: linear-gradient(var(--red), var(--red)) center / 14px 2px no-repeat, linear-gradient(var(--red), var(--red)) center / 2px 14px no-repeat;
  transition: transform 200ms var(--ease-out);
}
.qa[open] summary::after { transform: rotate(45deg); }
.qa h3 { font-size: 1.1875rem; line-height: 1.35; font-weight: 700; letter-spacing: -0.005em; }
.qa p { margin: 0 0 20px; color: var(--ink-2); }

.src-note { color: var(--ink-2); font-size: 1rem; }
.sources { padding-left: 1.6em; font-size: 1rem; color: var(--ink-2); max-width: var(--measure); }
.sources li { padding: 3px 0; overflow-wrap: anywhere; }
.sources li::marker { font-family: var(--mono); font-size: 0.875rem; }

.prose > * { max-width: var(--measure); }
.prose h2 { font-size: 1.75rem; margin: 48px 0 12px; }
.sub-link { color: var(--red-ink); font-weight: 700; }

/* ---------- footer */
.foot { margin-top: clamp(80px, 11vw, 144px); background: var(--manila); border-top: 2px solid var(--ink); color: var(--ink); font-size: 0.9375rem; }
.foot-in { padding-block: 32px 40px; }
.foot p { margin: 6px 0; }
.foot-line { font: 900 1.25rem/1.2 var(--sans); text-transform: uppercase; }
.foot-links { display: flex; flex-wrap: wrap; gap: 0 24px; list-style: none; padding: 0; margin: 8px 0; font: 700 0.875rem/1 var(--mono); text-transform: uppercase; }
.foot-links a { display: inline-flex; align-items: center; min-height: 44px; }
.foot-links.small { font-weight: 500; text-transform: none; font-family: var(--sans); font-size: 0.9375rem; }
.foot-note { color: var(--ink-2); font-size: 0.875rem; }

/* ---------- phone: the seam turns horizontal */
@media (max-width: 719px) {
  .split { grid-template-columns: 1fr; grid-template-rows: auto 9px auto; }
  .seam { background: linear-gradient(180deg, var(--red) 0 33%, var(--ink) 33% 67%, var(--yellow) 67%); }
  .split .side img { aspect-ratio: 16 / 10; }
  .ledger dl > div { grid-template-columns: 8rem 1fr; }
  .mark-word { font-size: 1.125rem; gap: 7px; }
  .mast-in { flex-wrap: wrap; row-gap: 0; }
  .mast nav { gap: 18px; font-size: 0.75rem; }
}

/* ---------- desktop: ledger column beside the reading column */
@media (min-width: 1024px) {
  .file-body { grid-template-columns: 15rem minmax(0, var(--measure)); column-gap: clamp(48px, 6vw, 96px); }
  .ledger { grid-row: 1 / span 20; }
  .ledger dl { position: sticky; top: 24px; }
  .ledger dl > div { grid-template-columns: 1fr; gap: 2px; }
  .ledger + .sec { margin-top: 0; }
  .rule-two { grid-template-columns: minmax(0, 1fr) minmax(0, 40rem); align-items: start; }
  .figures { display: grid; grid-template-columns: 1fr 1fr; column-gap: 32px; }
}
.figures > div { align-content: start; }

/* ---------- social logos (Simple Icons, CC0), ink colour, red on hover */
.foot-links .soc{display:inline-flex;align-items:center;gap:.5rem;min-height:44px}
.foot-links .soc svg{width:20px;height:20px;flex:none;transition:color .15s ease-out}
.foot-links .soc:hover svg,.foot-links .soc:focus-visible svg{color:var(--red,#D2321E)}

/* single-image case header (Short Cases and specials without a died/won pair) */
.solo { margin: 0; position: relative; }
.solo img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; }
