.ep-story {
  --ep-ink: #183e44;
  --ep-teal: #167c72;
  --ep-rust: #ad4b37;
  --ep-stroke: #b4cbc1;
  --ep-sheet: #edf3ed;
  min-width: 0;
}
.ep-story * { box-sizing: border-box; }
.ep-comparison { width:100%; table-layout:fixed; border-collapse:collapse; text-align:left; font:500 clamp(14px,1.14vw,17px)/1.3 var(--sans); }
.ep-comparison caption { text-align:left; color:var(--ink); font:600 clamp(17px,1.55vw,23px)/1.3 var(--sans); margin-bottom:14px; text-wrap:balance; }
.ep-model { display:inline-block; white-space:nowrap; }
.ep-model select { background:transparent; border:0; border-bottom:1px solid var(--line); border-radius:0; padding:2px 0; color:var(--body); font:inherit; cursor:pointer; }
.ep-comparison thead { color:var(--soft); }
.ep-comparison thead th { font-weight:550; }
.ep-comparison th:first-child { width:32%; }
.ep-comparison :is(th,td) { padding:10px clamp(9px,1.5vw,24px); border-bottom:1px solid var(--line); vertical-align:middle; }
.ep-comparison tr > :first-child { padding-left:8px; }
.ep-comparison tbody tr { --ep-bar:#818e94; --ep-strong:var(--body); }
.ep-comparison [data-pilot=text] { --ep-bar:#b56855; --ep-strong:#984b3a; }
.ep-comparison [data-pilot=visual] { --ep-bar:#6386a7; --ep-strong:#406588; }
.ep-comparison [data-pilot=one-shot] { --ep-bar:#9482ab; --ep-strong:#70538b; }
.ep-comparison tbody tr:not([data-pilot]) th { padding-left:26px; font-weight:500; color:var(--soft); }
.ep-variant { display:block; margin-top:.1em; color:var(--body); font-weight:450; }
.ep-comparison tbody tr:has(button) { cursor:pointer; }
.ep-comparison tbody tr:has(button):hover { background: color-mix(in srgb,var(--ep-bar) 5%,transparent); }
.ep-comparison tbody tr.ep-selected { background: color-mix(in srgb,var(--ep-bar) 10%,transparent); }
.ep-comparison tbody button { display:inline-flex; align-items:center; gap:9px; min-height:30px; text-align:left; padding:0; color:var(--body); font:inherit; font-weight:600; }
.ep-comparison tbody button::before { content:''; display:block; flex:none; width:9px; height:9px; border:1.5px solid var(--ep-bar); border-radius:50%; }
.ep-comparison button[aria-pressed=true] { color:var(--ep-strong); }
.ep-comparison button[aria-pressed=true]::before { border-color:var(--ep-strong); background:var(--ep-strong); }
.ep-score { display:grid; grid-template-columns:minmax(16px,1fr) 3.6ch; align-items:center; gap:10px; }
.ep-score i { height:.5em; background:#dce6e1; overflow:hidden; border-radius:2px; }
.ep-score i::before { content:''; display:block; height:100%; width:var(--score); background:var(--ep-bar); transform-origin:left; }
.ep-score b { text-align:right; font-weight:550; color:var(--body); font-variant-numeric:tabular-nums; }
.ep-selected .ep-score b { color:var(--ep-strong); }
.ep-stage {
  display: grid;
  grid-template-columns: minmax(0,1.35fr) minmax(0,1fr);
  align-items: center;
  gap: clamp(24px,4vw,60px);
  padding-block: clamp(20px,2.6vw,40px);
}
.ep-picture {
  position: relative;
  isolation: isolate;
  background: var(--ep-sheet);
  overflow: hidden;
  container-type: inline-size;
  border-radius: 3px;
  color: var(--ep-ink);
  aspect-ratio: 16/9;
  font-family: var(--sans);
}
.ep-picture > div { position:absolute; inset:0; }
.ep-picture img { display:block; width:100%; }
.ep-picture small,.ep-picture figcaption,.ep-picture span { line-height: 1.3; }
.ep-narration { min-width:0; }
.ep-narration h3 { margin:0 0 10px; font:600 clamp(16px,1.35vw,20px)/1.3 var(--sans); color:var(--body); }
.ep-narration section > p { margin:0; font:500 clamp(23px,2.23vw,36px)/1.19 var(--serif); letter-spacing:-.025em; text-wrap:pretty; color:var(--ink); }
.ep-narration section[hidden] { display:none; }
.ep-counts {
  display:grid; grid-template-columns:repeat(2,minmax(0,1fr));
  gap:clamp(14px,2vw,32px); max-width:32rem; margin-top:clamp(14px,1.6vw,24px);
}
.ep-counts strong { display:block; color:var(--ep-teal); font:650 clamp(30px,3vw,46px)/1.1 var(--sans); font-variant-numeric:tabular-nums; }
.ep-counts div + div strong { color:var(--ep-rust); }
.ep-counts b { font:inherit; }
.ep-counts small { color:var(--soft); font-size:.52em; font-weight:500; white-space:nowrap; }
.ep-counts span { display:block; margin-top:4px; color:var(--body); font:500 clamp(14px,1.14vw,17px)/1.3 var(--sans); }
.ep-guide img { display:block; flex:none; width:clamp(60px,5.7vw,82px); height:auto; object-fit:contain; }
.ep-story > .ep-narration { display:grid; gap:18px; max-width:64ch; }
.ep-playbar { display:flex; flex-wrap:wrap; justify-content:space-between; align-items:center; gap:10px 25px; padding-block:12px; border-block:1px solid var(--line); }
.ep-controls { display:flex; align-items:center; flex-wrap:wrap; }
.ep-controls { gap:clamp(12px,2.2vw,32px); }
.ep-controls button { min-height:37px; padding:3px 0; text-align:start; }
.ep-play { color:var(--body); font:600 13px var(--sans); }
.ep-play span { display:inline-block; width:16px; font:700 12px var(--sans); }
.ep-next { color:var(--ep-ink); font:650 15px var(--sans); }
.ep-next span { text-decoration:underline; text-underline-offset:4px; text-decoration-color:#97b9ad; }
.ep-next i { font-style:normal;display:inline-block;margin-left:3px; }
.ep-next:hover { color:var(--ep-teal); }
.ep-sr { position:absolute; width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap; }

/* Each pilot pairs the example with its finding from the paper. */
#pilot-story { --ep-sheet:#f0f3ed; }
#pilot-story .ep-stage { grid-template-columns:minmax(0,1.17fr) minmax(0,1fr); }
#pilot-story .ep-picture { aspect-ratio:1.82; }
#pilot-story[data-beat="1"] .ep-picture { aspect-ratio:auto; }
.ep-picture > .ep-notes { position:relative; }
.ep-notes {
  display:grid; grid-template-columns:.74fr 2fr; align-items:start; gap:clamp(10px,1.3vw,20px);
  padding:clamp(12px,2vw,28px); color:var(--ink); background:#f2f0e8; border-radius:3px;
}
.ep-story > .ep-notes { max-width:720px; margin:24px 0; }
.ep-notes figure { margin:0; min-width:0; }
.ep-notes img { display:block; width:100%; height:auto; aspect-ratio:1; border-radius:2px; }
.ep-query-crop { padding-top:calc(1.6rem + 10%); }
.ep-note-pair { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px clamp(8px,1vw,16px); }
.ep-note-pair p { grid-column:1/-1; margin:0; font:600 clamp(14px,1.15vw,17px)/1.25 var(--sans); }
.ep-notes figcaption { margin-top:7px; font:600 clamp(14px,1.12vw,17px)/1.35 var(--sans); }
.ep-note-pair strong, .ep-note-pair q { display:block; }
.ep-note-pair figure:first-of-type strong { color:var(--ep-teal); }
.ep-note-pair figure:last-of-type strong { color:var(--ep-rust); }
.ep-note-pair q { margin-top:4px; font:400 clamp(15px,1.17vw,18px)/1.3 var(--serif); }
.ep-search-output span,.ep-ledger small,.ep-route-label { display:block;font:550 clamp(13px,1.8cqw,15px)/1.25 var(--sans);color:#556862; }
.ep-route>strong { font:500 clamp(17px,4.1cqw,36px)/1.08 var(--serif);letter-spacing:-.025em; }
.ep-search { background:#e9f1ed; }
.ep-search-image { position:absolute;inset:13% 38% 22% 3%;box-shadow:0 2px 8px #27473a22;transform:rotate(-2deg); }
.ep-search-image img { width:100%;height:100%;object-fit:fill;display:block; }
.ep-search-image i { position:absolute;left:24.84%;top:28.89%;width:23.13%;height:41.11%;border:clamp(2px,.55cqw,4px) solid #ffe3a0;box-shadow:0 0 0 1px #343d3f; }
.ep-search-output { position:absolute;z-index:1;left:58%;right:3%;top:32%;background:#fffef9;padding:3%;border-left:3px solid var(--ep-teal);box-shadow:0 2px 7px #27473a18; }
.ep-search-output b { display:block;font:600 clamp(12px,2.65cqw,22px)/1.2 var(--sans);margin:4% 0 6%; }
.ep-search-output small { font:550 clamp(13px,2.1cqw,18px)/1.4 var(--sans);color:#46554f;white-space:nowrap; }
.ep-search-output em { color:var(--ep-rust);font-style:normal; }
.ep-route { padding:5% 7% 5% 6%;background:#eff2e9; }
.ep-route>strong { display:block;margin:.12em 0 .45em; }
.ep-ledger { width:fit-content;max-width:100%;border-left:3px solid #b99852;padding:2.2% 3%;background:#fffefa; }
.ep-ledger div { display:flex; gap:clamp(7px,2.8cqw,22px);align-items:baseline;margin-top:6%; }
.ep-ledger b { position:relative;font:500 clamp(15px,3.7cqw,30px)/1 var(--mono); }
.ep-ledger b:not(:last-child)::after { content:'·';position:absolute;right:-1.65cqw;color:#b5beb8; }
.ep-late-query { position:absolute;bottom:5%;right:5%;width:57%;display:flex;align-items:center;gap:5%; }
.ep-late-query img { width:23%;transform:rotate(5deg);border:3px solid white;box-shadow:0 2px 3px #27473a22; }
.ep-late-query b { color:var(--ep-rust);font:600 clamp(12px,2.8cqw,22px)/1.1 var(--sans); }

@media (prefers-reduced-motion:no-preference) {
  .ep-score i::before { transition:width 820ms cubic-bezier(.215,.61,.355,1); }
  .ep-comparison.ep-awaiting .ep-score i::before { width:0; }
  .ep-comparison.ep-awaiting .ep-score b { visibility:hidden; }
  :is(.ep-playing,.ep-prompted) .ep-notes figure { animation:ep-rise .4s both; }
  :is(.ep-playing,.ep-prompted) .ep-note-pair figure:first-of-type { animation-delay:.12s; }
  :is(.ep-playing,.ep-prompted) .ep-note-pair figure:last-of-type { animation-delay:.24s; }
  :is(.ep-playing,.ep-prompted) .ep-search-image i { animation:ep-scan 1.8s cubic-bezier(.2,.7,.23,1) both; }
  :is(.ep-playing,.ep-prompted) .ep-search-output { animation:ep-rise .6s 1.15s both; }
  :is(.ep-playing,.ep-prompted) .ep-ledger b { animation:ep-stamp .44s calc(.26s * var(--i)) backwards; }
  :is(.ep-playing,.ep-prompted) .ep-late-query { animation:ep-rise .7s 1.6s backwards; }
  @keyframes ep-rise { from{translate:0 13px;opacity:0;} }
  @keyframes ep-scan { 0%{translate:155% 0;scale:1.12;} 35%{translate:95% -22%;} 70%{translate:-8% 5%;} }
  @keyframes ep-stamp { from{transform:scale(1.6) rotate(-10deg);opacity:0;} }
}
@media(max-width:760px) {
  .ep-stage,#pilot-story .ep-stage { grid-template-columns:1fr;gap:17px; }
  .ep-playbar { align-items:flex-start; }
}
@media(max-width:600px) {
  .ep-comparison th:first-child { width:38%; }
  .ep-comparison :is(th,td) { padding:7px 5px; }
  .ep-comparison tr > :first-child { padding-left:2px; }
  .ep-comparison tbody tr:not([data-pilot]) th { padding-left:16px; }
  .ep-comparison tbody button { gap:5px; min-height:36px; }
  .ep-score { display:flex; flex-direction:column-reverse; align-items:flex-start; gap:3px; }
  .ep-score i { width:100%; height:4px; }
}
@media(max-width:440px) {
  .ep-stage { padding-block:14px 17px; }
  .ep-controls { width:100%; }
  .ep-controls { justify-content:space-between; }
  .ep-next { font-size:13px; }
  .ep-narration h3 { margin-bottom:6px; }
}
