/*
 * A starting point for a new deck's own talk.css (#5899): copy it into the deck folder as talk.css
 * (scripts/talks/new-deck-v1.mjs copies it for a new deck, #5900).
 * It styles the deck's scenes in the theme's --t-* tokens only, so the deck can change theme by
 * changing scenes.json talk.theme and re-running the bake. Add the deck's own rules below these.
 */

/* an image set inline in a line of text, such as a brand wordmark: at the text's capital height (L88) */
.inline-icon {
  height: var(--t-wordmark-inline-height);
  width: auto;
  vertical-align: baseline;
}

/* a highlighted word in a statement */
.scene .hl {
  color: var(--t-accent);
}

/* a deck heading in the theme's display face */
.scene .statement {
  font-family: var(--t-font-display, var(--t-font));
}

/* a caption under a picture */
.object figcaption {
  color: var(--t-muted);
  font: 500 clamp(14px, 1.1vw, 18px) / 1.4 var(--t-font);
}

/* ── The HUD's relay dish and its two slots (from the Closing the Loop decks: r14, Matt's pick of
   2026-10-21, and Lane G #5873), which the deck checks measure (verify-talk-engine check 28). The
   dish is this deck's own asset: a relative path in a custom property resolves against the
   stylesheet where var() is used, so the mask that uses it stays here, in the deck's own talk.css.
   Mint (the accent) when connected, amber and pulsing while it connects or retries, grey with a red
   slash when lost; the words stay in the element (role=status) but are not drawn. ── */
.hud .relay-chip {
  --relay-c: var(--t-muted);
  --relay-icon: url("assets/hud/relay-dish.svg");
  position: relative;
  box-sizing: border-box;
  width: 18px;
  height: 18px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: none;
  font-size: 0;
  color: transparent;
  grid-row: 1;
  grid-column: 10;
  align-self: center;
  margin-left: 6px;
  pointer-events: auto;
}
.hud .relay-chip::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--relay-c);
  -webkit-mask: var(--relay-icon) center / contain no-repeat;
  mask: var(--relay-icon) center / contain no-repeat;
}
.hud .relay-chip::after {
  content: "";
  display: none;
  position: absolute;
  left: 50%;
  top: -3px;
  bottom: -3px;
  width: 2.5px;
  margin-left: -1.25px;
  border-radius: 2px;
  background: var(--t-danger);
  box-shadow: 0 0 0 1.5px var(--t-bg);
  transform: rotate(-45deg);
}
.hud .relay-chip[data-state="live"] {
  --relay-c: var(--t-accent);
}
.hud .relay-chip[data-state="wait"] {
  --relay-c: var(--t-warn);
  animation: relay-wait 1.4s ease-in-out infinite;
}
.hud .relay-chip[data-state="down"]::after {
  display: block;
}
@keyframes relay-wait {
  50% {
    opacity: 0.35;
  }
}
.hud-right .relay-chip ~ .ctr,
.hud-right .relay-chip:empty ~ .ctr {
  grid-column: 1 / span 9;
}
/* the talk timer takes the top-right slot beside the counter; the dish and the sign-in mark move
   to the top-left slot under the wordmark */
@media (min-width: 761px) {
  .hud .relay-chip {
    position: absolute;
    left: var(--pad);
    top: calc(22px + var(--r9-logo-h) + 12px);
    margin: 0;
  }
  .hud #talk-identity {
    position: absolute;
    left: calc(var(--pad) + 30px);
    top: calc(22px + var(--r9-logo-h) + 7px);
  }
  .hud-right .tt-timer {
    grid-row: 1;
    grid-column: 10;
    justify-self: end;
    margin-left: 14px;
    min-width: 4.2em;
    text-align: right;
  }
}
@media (max-width: 760px) {
  .hud-right .tt-timer {
    grid-row: 2;
  }
}
/* the phone page: the step control sits under the count, so the HUD band is one icon row taller
   (88 px) than the engine's 84 px top padding; a scene starts below the band and its fade strip
   (both delivered decks carry this rule; verify-talk-engine check 22 measures it) */
@media (max-width: 760px) {
  html:not(.is-stage) .scene {
    padding-top: calc(118px + env(safe-area-inset-top, 0px));
  }
}

/* ---------- Ported from the Oct 28 deck (closing-the-loop-ese5180) by extract-layout-css-v1.py: the about, here and platform layouts ---------- */
/* 02-A + 03-A: About Me. The square headshot fills a rounded card; build 1 dissolves it to the 2005
   face (the stack's second layer); build 2 opens the show photo behind the whole scene (the bleed)
   and the card shrinks to a tilted print beside the poster-sized lyric. */
.scene-spine.layout-about .cred {
  font-size: clamp(18px, 1.7vw, 28px);
}
.scene-spine.layout-about .beat {
  margin-top: clamp(8px, 1vw, 14px);
  font-size: clamp(18px, 1.7vw, 28px);
}
.scene-spine.layout-about .object-stack {
  background: none;
  border: 0;
  justify-self: center;
  width: min(100%, 36vw, 62vh);
  aspect-ratio: 1;
  border-radius: 28px;
  overflow: hidden;
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(255, 255, 255, 0.08);
  transition:
    width 1200ms var(--ease),
    transform 1200ms var(--ease),
    box-shadow 1200ms var(--ease);
}
.scene-spine.layout-about .object-stack img.layer,
.scene-spine.layout-about .object-stack img.layer.on {
  max-height: none;
  border-radius: 0;
  /* both faces scale from the top edge: the 2005 scan's padded foot leaves the frame, the eye
  lines move together, and the hair stays */
  transform: scale(1.14);
  transform-origin: 50% 0;
}
/* build 2: the 2005 face slides onto the same face in the show photo and fades away there
   (Matt, 2026-10-19). The card's layers put the 2005 eyes at the card's centre; on a 16:9 stage
   the show photo (cover, 60% 40%) puts his face 10.85vw left of and 1.5vh above the card's,
   at 0.56 of the card's face scale, with his head tipped back about 15 degrees. Measured from
   the two photos' faces (forehead to chin, eyes to mouth). The move runs first, the fade starts
   as it lands. */
.scene-spine.layout-about[data-build="2"] .object-stack {
  transform: translate(-10.57vw, -2.73vh) rotate(-15deg) scale(0.4485);
  transform-origin: 50% 50%;
  opacity: 0;
  box-shadow:
    0 0 0 4px rgba(255, 255, 255, 0.9),
    0 30px 80px rgba(0, 0, 0, 0.6);
  transition:
    transform 1600ms var(--ease),
    box-shadow 1600ms var(--ease),
    opacity 1100ms var(--ease) 1300ms;
}
.scene-spine.layout-about .quote .lyric {
  font-size: clamp(26px, 2.9vw, 50px);
  max-width: 18em;
}
.scene-spine.layout-about .beat-icon.square {
  background: #fff;
}
.scene-spine.layout-about .beat-icon.mark {
  padding: 6px;
  background: rgba(255, 255, 255, 0.06);
}
/* 04a-A: the Pi and the session list, side by side, under the statement */
.scene-spine.layout-here .two {
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  grid-template-rows: auto minmax(0, 1fr);
  gap: clamp(14px, 2vh, 26px) clamp(24px, 3vw, 56px);
  align-items: start;
}
.scene-spine.layout-here .two > .text {
  grid-column: 1;
  grid-row: 1;
}
/* the group's two objects become grid children: the Pi under the words, the clip at the right */
.scene-spine.layout-here .object-group.duo {
  display: contents;
}
.scene-spine.layout-here .object-group.duo > .object-image {
  grid-column: 1;
  grid-row: 2;
  width: min(100%, 30vw);
  align-self: start;
}
.scene-spine.layout-here .object-group.duo > .object-video {
  grid-column: 2;
  grid-row: 1 / 3;
  align-self: center;
  transform: perspective(1800px) rotateY(-10deg) rotateX(2deg);
  transform-origin: left center;
}
.scene-spine.layout-here .object-group.duo > .object-image {
  background: none;
  border: 0;
}
.scene-spine.layout-here .object-group.duo > .object-image img {
  filter: drop-shadow(0 40px 60px rgba(0, 0, 0, 0.65));
  max-height: 40vh;
}
.scene-spine.layout-here .object-group.duo > .object-image .credit {
  text-align: center;
}
.scene-spine.layout-here .object-video {
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55);
}
@media (max-width: 760px) {
  html:not(.is-stage) .scene-spine.layout-here .object-group.duo {
    display: grid;
  }
  html:not(.is-stage)
    .scene-spine.layout-here
    .object-group.duo
    > .object-video {
    transform: none;
  }
  /* the reading page stacks the duo: the Pi photo under the words, the clip under it (the stage's
     grid placement collapsed the photo's column to nothing at phone width, 2026-10-19) */
  html:not(.is-stage)
    .scene-spine.layout-here
    .object-group.duo
    > .object-image,
  html:not(.is-stage)
    .scene-spine.layout-here
    .object-group.duo
    > .object-video {
    grid-column: auto;
    grid-row: auto;
    width: 100%;
    align-self: start;
  }
  html:not(.is-stage)
    .scene-spine.layout-here
    .object-group.duo
    > .object-image {
    width: min(100%, 240px);
  }
  html:not(.is-stage) .scene-spine.layout-about .object-stack,
  html:not(.is-stage) .scene-spine.layout-about[data-build="2"] .object-stack {
    width: min(100%, 320px);
    justify-self: start;
    transform: none;
    /* the phone shows no show photo to fade into: the card stays */
    opacity: 1;
  }
}
@media (max-height: 820px) {
  .scene-spine.layout-about .quote .lyric {
    font-size: clamp(18px, 2vw, 28px);
  }
  .scene-spine.layout-about .quote {
    margin-top: 12px;
  }
  .scene-spine.layout-about .marks {
    margin-top: 12px;
    padding-top: 10px;
  }
  .scene-spine.layout-about .statement {
    font-size: clamp(30px, 3.6vw, 52px);
  }
}
/* About me: the opening mark sits below the kicker, and the lyric closes with a mark too */
.scene-spine.layout-about .quote .kicker {
  margin-bottom: clamp(18px, 2.4vh, 30px);
}
.scene-spine.layout-about .lyric::before {
  top: -0.1em;
}
.scene-spine.layout-about .lyric::after {
  content: "\201D";
  font: 800 1.6em/0 var(--hb-font);
  color: var(--hb-mint);
  margin-left: 0.08em;
  vertical-align: -0.42em;
}
/* ABOUT-C: the show photo as a Polaroid print on the right; the lyric not bold; its credit under it */
.scene-spine.layout-about .quote .lyric {
  font-weight: 400;
}
.scene-spine.layout-about .bleed {
  inset: auto;
  right: 5vw;
  top: 14vh;
  padding: 1.4vh 1.4vh 8vh;
  background: #f4f4f0;
  transform: rotate(2deg);
  transform-origin: 50% 50%;
  box-shadow: 0 40px 90px rgba(0, 0, 0, 0.6);
  opacity: 0;
  transition: opacity 900ms var(--ease);
}
.scene-spine.layout-about .bleed.on {
  opacity: 1;
  transform: rotate(2deg);
}
.scene-spine.layout-about .bleed::after {
  display: none;
}
.scene-spine.layout-about .bleed img {
  display: block;
  height: 62vh;
  width: auto;
  object-fit: contain;
}
/* the 2005 card lands on the face in the print: measured from the print's geometry (62vh tall at
   5vw from the right, 14vh from the top, a 1.4vh border, turned 2 degrees) and the 2005 crop's face */
.scene-spine.layout-about[data-build="2"] .object-stack {
  transform: translate(4.99vw, -7.19vh) rotate(-13deg) scale(0.1772);
}
@media (max-width: 760px) {
  html:not(.is-stage) .scene-spine.layout-about .bleed {
    display: none;
  }
}
/* 1.0: "Senior Electrical Engineer at" followed by the wordmark as it draws itself */
.scene-spine.layout-about .beat:first-of-type::after {
  content: "";
  display: inline-block;
  width: 6.4em;
  height: 1.07em;
  margin-left: 0.4em;
  vertical-align: -0.12em;
  background: url("assets/act7/spd-wordmark.svg") left center / contain
    no-repeat;
}
/* 1.1: both marks the same size and mint; the lyric and its attribution in a rounded card */
.scene-spine.layout-about .lyric {
  padding-left: 0;
}
.scene-spine.layout-about .lyric::before {
  position: static;
  font: 800 1.6em/0 var(--hb-font);
  vertical-align: -0.42em;
  margin-right: 0.08em;
  opacity: 1;
}
.scene-spine.layout-about .lyric-card {
  border: 1px solid var(--hb-line-strong);
  border-radius: 18px;
  background: rgba(35, 35, 37, 0.92);
  padding: clamp(14px, 1.6vw, 24px) clamp(16px, 1.8vw, 28px)
    clamp(12px, 1.3vw, 20px);
  max-width: 30em;
}
.scene-spine.layout-about .lyric-credit {
  margin: 10px 0 0;
  text-align: right;
}
/* the automatic sequence: build 1 the 2006 face large; build 2 the print and the landing; build 3 the fade */
.scene-spine.layout-about[data-build="1"] .object-stack {
  transform: scale(1.22);
  transform-origin: 50% 50%;
}
.scene-spine.layout-about[data-build="2"] .object-stack {
  opacity: 1;
  transition:
    transform 1600ms var(--ease),
    box-shadow 1600ms var(--ease);
}
.scene-spine.layout-about[data-build="3"] .object-stack {
  transform: translate(4.99vw, -7.19vh) rotate(-13deg) scale(0.1772);
  transform-origin: 50% 50%;
  opacity: 0;
  box-shadow:
    0 0 0 4px rgba(255, 255, 255, 0.9),
    0 30px 80px rgba(0, 0, 0, 0.6);
  transition: opacity 1300ms var(--ease);
}
@media (max-width: 760px) {
  html:not(.is-stage) .scene-spine.layout-about .object-stack,
  html:not(.is-stage) .scene-spine.layout-about[data-build="3"] .object-stack {
    transform: none;
    opacity: 1;
  }
}
/* round 7 fixes, measured: the eyebrow is the text block's first p, so the wordmark follows the
   second; the definition is the beat that arrives at build 1; the lyric card takes the column */
.scene-spine.layout-about .beat:first-of-type::after {
  content: none;
}
.scene-spine.layout-about .text > p.beat:nth-of-type(2)::after {
  content: "";
  display: inline-block;
  width: 6.4em;
  height: 1.07em;
  margin-left: 0.4em;
  vertical-align: -0.12em;
  background: url("assets/act7/spd-wordmark.svg") left center / contain
    no-repeat;
}
.scene-spine.layout-about .lyric-card {
  max-width: 44vw;
}
.scene-spine.layout-about .quote .lyric {
  font-size: clamp(22px, 2.25vw, 40px);
  max-width: none;
}
/* ── 1.0: the SPD wordmark at the line's own size. Its letters fill 0.279 of its height and Inter's
   capitals are 0.727 em, so a 2.61 em tall wordmark sets its letters at the text's capital height; the
   beat centres its items, which puts the wordmark's letters on the text's baseline. The wordmark's own
   left margin (0.72 em at this size) and the beat's gap are taken back so a word space remains. */
.scene-spine.layout-about .text > p.beat:nth-of-type(2) {
  max-width: none;
}
.scene-spine.layout-about .text > p.beat:nth-of-type(2)::after {
  content: "";
  flex: none;
  display: block;
  width: 15.66em;
  height: 2.61em;
  margin: -0.6em 0 -0.6em calc(0.28em - 16px - 0.72em);
  background: url("assets/act7/spd-wordmark.svg") left center / contain
    no-repeat;
}
/* ── 3.0 and 3.1: What is [the wordmark]? The title and its answer run across the top; under them
   the words take the left and the interface the right, the desktop hung from the definition's
   first line and the phone in front of it, standing on the last line of the reasons. */
.scene-spine.layout-platform {
  align-content: start;
  padding-top: max(150px, 14vh);
}
.scene-spine.layout-platform .statement .keep {
  /* the wordmark stands in for the name: its letters at the title's capital height and its baseline
     on the title's (the mark's capitals are 0.548 of its box, Inter's 0.727 em); the margins take
     back the mark's own side bearings so the word spaces match the title's */
  display: inline-block;
  width: 4.89em;
  height: 1.327em;
  margin: 0 -0.08em 0 -0.1em;
  vertical-align: -0.371em;
  overflow: hidden;
  text-indent: 120%;
  color: transparent;
  background: url("assets/act2b/wordmark-pingpong.svg") left bottom / contain
    no-repeat;
}
.scene-spine.layout-platform .sub {
  max-width: none;
  margin-top: clamp(12px, 1.4vh, 20px);
  font-weight: 600;
  color: var(--hb-text);
}
.scene-spine.layout-platform .beat {
  max-width: none;
}
.scene-spine.layout-platform .sub + .beat {
  /* the definition: the lead paragraph, a mint rule at its left */
  margin-top: 0;
  padding-left: clamp(16px, 1.3vw, 26px);
  border-left: 3px solid var(--hb-mint);
  font: 500 clamp(16px, 1.3vw, 25px) / 1.46 var(--hb-font);
  color: var(--hb-text);
}
.scene-spine.layout-platform .sub + .beat + .beat {
  /* Why use a meta-harness? */
  margin-top: clamp(22px, 3.4vh, 44px);
  font: 800 clamp(17px, 1.4vw, 27px) / 1.2 var(--hb-font);
  letter-spacing: -0.01em;
  color: var(--hb-mint);
}
.scene-spine.layout-platform .beat.with-label {
  display: block;
  margin-top: clamp(14px, 2.2vh, 28px);
  font: 500 clamp(13px, 0.98vw, 18px) / 1.42 var(--hb-font);
  color: var(--hb-text-secondary);
}
.scene-spine.layout-platform .beat.with-label .beat-label {
  display: block;
  margin-bottom: 0.3em;
  padding: 0;
  border: 0;
  border-radius: 0;
  white-space: normal;
  font: 800 clamp(15px, 1.1vw, 21px) / 1.25 var(--hb-font);
  letter-spacing: -0.005em;
  text-transform: none;
  color: var(--hb-text);
}
.scene-spine.layout-platform .object-group.desk {
  position: relative;
  display: block;
  overflow: visible;
  border: 0;
  background: none;
}
.scene-spine.layout-platform .object-group.desk > .object.cover {
  border-radius: 14px;
  border: 1px solid var(--hb-line-strong);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.55);
}
.scene-spine.layout-platform .object-group.desk > .object img {
  height: auto;
}
.scene-spine.layout-platform .object-group.desk > .object.phone {
  border-radius: 22px;
  border: 3px solid #3a3a3c;
  background: #000;
  box-shadow:
    0 0 0 8px var(--hb-bg),
    0 30px 60px rgba(0, 0, 0, 0.6);
}
.scene-spine.layout-platform .object-group.desk > .credit {
  padding: 0;
  font: 600 clamp(12px, 0.85vw, 15px) / 1 var(--hb-mono);
  letter-spacing: 0.06em;
}
@media (min-width: 761px) {
  /* the scene's own grid: the title and its answer across, then two columns of reasons beside
     the interface (the text block's children join the grid). Sizes in --u, a hundredth of a 16:9
     stage's width, so 1280x720 is exactly two thirds of 1920x1080 */
  .scene-spine.layout-platform {
    --u: min(1vw, 1.7778vh);
    padding-top: calc(var(--u) * 6.9);
  }
  .scene-spine.layout-platform .statement {
    font-size: calc(var(--u) * 4.375);
  }
  .scene-spine.layout-platform .sub {
    margin-top: calc(var(--u) * 1);
    font-size: calc(var(--u) * 1.5625);
  }
  .scene-spine.layout-platform .sub + .beat {
    padding-left: calc(var(--u) * 1.35);
    font-size: calc(var(--u) * 1.3);
  }
  .scene-spine.layout-platform .sub + .beat + .beat {
    margin-top: calc(var(--u) * 1.9);
    font-size: calc(var(--u) * 1.4);
  }
  .scene-spine.layout-platform .beat.with-label {
    margin-top: calc(var(--u) * 1.25);
    font-size: calc(var(--u) * 0.9375);
  }
  .scene-spine.layout-platform .beat.with-label .beat-label {
    font-size: calc(var(--u) * 1.094);
  }
  .scene-spine.layout-platform .object-group.desk > .credit {
    font-size: calc(var(--u) * 0.78);
  }
  .scene-spine.layout-platform .two {
    grid-template-columns:
      minmax(0, 1fr) minmax(0, 1fr)
      minmax(0, 1.62fr);
    column-gap: calc(var(--u) * 2.3);
    row-gap: 0;
    align-items: start;
  }
  .scene-spine.layout-platform .text {
    display: contents;
  }
  .scene-spine.layout-platform .text > * {
    grid-column: 1 / 3;
  }
  .scene-spine.layout-platform .text > .statement,
  .scene-spine.layout-platform .text > .sub {
    grid-column: 1 / -1;
  }
  .scene-spine.layout-platform .text > .sub {
    margin-bottom: calc(var(--u) * 2);
  }
  .scene-spine.layout-platform .text > .beat.with-label {
    grid-column: auto;
  }
  .scene-spine.layout-platform .object-group.desk {
    grid-column: 3;
    grid-row: 3 / span 6;
    align-self: stretch;
    margin-left: calc(var(--u) * 1.8);
  }
  /* 2026-10-28 (Matt's review): a deck that puts the act kicker (.eyebrow-xl) above the title adds a
     grid row before the statement; without this the kicker fell into the interface's column and the
     subtitle was pushed under the screenshots. The kicker runs full width like the title, and the
     interface starts one row later, under the subtitle. */
  .scene-spine.layout-platform .text > .eyebrow-xl {
    grid-column: 1 / -1;
  }
  .scene-spine.layout-platform:has(.text > .eyebrow-xl) .object-group.desk {
    grid-row: 4 / span 6;
  }
  .scene-spine.layout-platform .object-group.desk > .object.phone {
    position: absolute;
    left: -4%;
    bottom: 0;
    width: 31%;
  }
  .scene-spine.layout-platform .object-group.desk > .credit {
    position: absolute;
    right: 0;
    bottom: 0;
  }
}
@media (max-width: 760px) {
  .scene-spine.layout-about .text > p.beat:nth-of-type(2) {
    flex-wrap: wrap;
    row-gap: 6px;
  }
  .scene-spine.layout-about .text > p.beat:nth-of-type(2)::after {
    width: 11em;
    height: 1.84em;
    margin: 0 0 0 calc(40px + 16px - 0.5em);
  }
}
@media (max-width: 760px) {
  .scene-spine.layout-platform .object-group.desk > .object.phone {
    width: 52%;
    margin: 18px auto 0;
  }
}
@media (min-width: 761px) and (max-aspect-ratio: 3/2) and (min-aspect-ratio: 5/4) {
  /* About: the lyric card stays left of the print (its left edge sits at 39 percent of the width here) */
  .scene-spine.layout-about .lyric-card {
    max-width: 31.5vw;
  }
  .scene-spine.layout-about .quote .lyric {
    font-size: 1.7vw;
  }
  .scene-spine.layout-about .text > p.beat:nth-of-type(2) {
    flex-wrap: wrap;
    row-gap: 0.2em;
  }
  .scene-spine.layout-about .text > p.beat:nth-of-type(2)::after {
    margin-left: calc(clamp(40px, 3.6vw, 60px) + 16px - 0.72em);
  }
}
/* r10 P1/P2 (slide 2.0): the Pi 20 percent larger and a little lower; the clip flat, whole,
   and sharp-edged, so it reads as the real app window and the file is reusable. */
.scene-spine.layout-here .object-group.duo > .object-video {
  transform: none;
  align-self: start;
  width: min(100%, 58vw);
  justify-self: end;
}
.scene-spine.layout-here .object-group.duo > .object-video video {
  display: block;
  width: 100%;
  height: auto;
}
.scene-spine.layout-here .object-group.duo > .object-image {
  /* the trimmed photo has no margins now: 25vw puts the 85 mm board a fifth larger than before */
  width: min(100%, 25vw);
  margin-top: clamp(10px, 3vh, 36px);
}
.scene-spine.layout-here .object-group.duo > .object-image img {
  max-height: 44vh;
}
/* ── r10 About Me (A2, A4, B1 to B4) ──
   Build 0: the name and the two credential lines. Press 1 (build 1): the credentials leave and
   the Rewind line takes their place, large; the 2005 face dissolves in. Press 2 (build 2): the
   Mose Giganticus wordmark replaces the Rewind line, the lyric card fades in under it, the print
   appears and the 2005 face lands on it; build 3 (automatic) fades the face. */
.scene-spine.layout-about .text > p.beat:nth-of-type(2)::after {
  content: none;
  display: none;
}
.scene-spine.layout-about h2.statement + .beat.cred {
  margin-top: clamp(18px, 2.4vw, 38px);
}
.scene-spine.layout-about .beat .spd {
  font-family: "DM Sans", var(--hb-font);
  font-weight: 700;
  letter-spacing: 0.01em;
}
@media (min-width: 761px) {
  .scene-spine.layout-about[data-build="1"] .beat.cred,
  .scene-spine.layout-about[data-build="2"] .beat.cred,
  .scene-spine.layout-about[data-build="3"] .beat.cred,
  .scene-spine.layout-about[data-build="2"] .beat.rewind,
  .scene-spine.layout-about[data-build="3"] .beat.rewind {
    display: none;
  }
}
.scene-spine.layout-about .beat.rewind {
  margin-top: clamp(18px, 2.4vw, 38px);
  font: 800 clamp(26px, 2.7vw, 46px) / 1.1 var(--hb-font);
  color: var(--hb-mint);
}
.scene-spine.layout-about .beat.mose {
  margin-top: clamp(18px, 2.4vw, 38px);
  align-items: center;
}
.scene-spine.layout-about .beat.mose .beat-text {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}
.scene-spine.layout-about .beat-icon.mose {
  width: auto;
  height: clamp(22px, 2.3vw, 40px);
  max-width: 100%;
  background: none;
  border: 0;
  padding: 0;
  border-radius: 0;
  object-fit: contain;
}
/* the lyric card hugs its lines: no left rule, the opening mark hangs outside the text, the
   attribution ends where the lyrics end */
.scene-spine.layout-about .lyric-card {
  width: fit-content;
  max-width: min(50vw, 100%);
}
.scene-spine.layout-about .lyric {
  position: relative;
  border-left: 0;
  padding-left: 0;
  margin-left: 0.55em;
}
.scene-spine.layout-about .lyric::before {
  position: absolute;
  left: -0.62em;
  top: 0.12em;
  margin: 0;
}
.scene-spine.layout-about .lyric-credit {
  text-align: right;
  margin-left: 0.55em;
}
/* ── r10 A1: the credential tiles, both 5:3, the SPD mark and Drexel at one size ── */
.scene-spine.layout-about .beat-icon.wide {
  width: 3.5em;
  height: 2.1em;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: none;
  object-fit: contain;
}
@media (min-width: 761px) {
  .scene-spine.layout-platform .two {
    grid-template-columns: minmax(0, 1.78fr) minmax(0, 1fr) minmax(0, 1fr);
    column-gap: calc(var(--u) * 2.6);
  }
  .scene-spine.layout-platform .text > * {
    grid-column: 2 / 4;
  }
  .scene-spine.layout-platform .text > .statement,
  .scene-spine.layout-platform .text > .sub {
    grid-column: 1 / -1;
  }
  .scene-spine.layout-platform .text > .beat.with-label {
    grid-column: auto;
  }
  /* the six points fill the two right columns in order (the first labelled beat is the text
     block's fourth p, so even ones go left) */
  .scene-spine.layout-platform .text > .beat.with-label:nth-of-type(even) {
    grid-column: 2;
  }
  .scene-spine.layout-platform .text > .beat.with-label:nth-of-type(odd) {
    grid-column: 3;
  }
  .scene-spine.layout-platform .object-group.desk {
    grid-column: 1;
    grid-row: 3 / span 6;
    margin-left: 0;
    margin-right: calc(var(--u) * 1.2);
    align-self: start;
  }
  .scene-spine.layout-platform .object-group.desk > .object.phone {
    left: auto;
    right: -2%;
    bottom: -10%;
    width: 22%;
  }
  .scene-spine.layout-platform .object-group.desk > .credit {
    right: auto;
    left: 0;
    bottom: -8%;
  }
}
@media (max-width: 760px) {
  .scene-spine.layout-about .lyric-card {
    width: auto;
    max-width: 100%;
  }
}
/* r10 P2 (the media lane's finding): the clip's "black left strip" was a letterbox, not the file:
   with width 100% and a 62vh cap, object-fit left black bands at wider screens. The clip now keeps
   its own size inside the cap, on a transparent box that hugs it; and the Pi cut-out drops its
   drop-shadow, which read as a dark halo. */
.scene-spine.layout-here .object-group.duo > .object-video {
  width: fit-content;
  max-width: 58vw;
  justify-self: end;
}
.scene-spine.layout-here .object-group.duo > .object-video video {
  width: auto;
  max-width: 100%;
  max-height: 62vh;
  height: auto;
  margin-inline: auto;
  background: transparent;
}
.scene-spine.layout-here .object-group.duo > .object-image img {
  filter: none;
}
@media (min-width: 761px) {
  .scene-spine.layout-about {
    align-content: start;
    padding-top: 15vh;
  }
  .scene-spine.layout-about .two {
    align-items: start;
  }
  .scene-spine.layout-about .object-stack {
    width: min(36vw, 62vh);
    align-self: start;
  }
  .scene-spine.layout-about .lyric-card {
    width: 100%;
    max-width: min(50vw, 100%);
  }
  .scene-spine.layout-about .quote .lyric {
    max-width: none;
  }
  .scene-spine.layout-about .beat.mose {
    margin-top: clamp(14px, 1.6vw, 26px);
    padding-left: 0;
    margin-left: 0;
  }
  .scene-spine.layout-about .beat-icon.mose {
    height: clamp(20px, 2.07vw, 36px);
    margin-left: 0;
  }
  .scene-spine.layout-about .beat.mose + .quote,
  .scene-spine.layout-about .quote {
    margin-top: clamp(12px, 1.4vw, 24px);
  }
}
@media (min-width: 761px) {
  .scene-spine.layout-here .two {
    align-items: start;
    grid-template-rows: auto minmax(0, 1fr);
  }
  .scene-spine.layout-here .object-group.duo > .object-video {
    align-self: start;
  }
  .scene-spine.layout-here .object-group.duo > .object-image {
    align-self: end;
    justify-self: start;
  }
  .scene-spine.layout-here .object-group.duo > .object-image img {
    max-height: 30vh;
  }
}
@media (min-width: 761px) {
  .scene-spine.layout-about[data-build="1"] .object-stack {
    transform: none;
  }
}
.scene-spine.layout-here .object-group.duo > .object-video img.clip-poster {
  width: auto;
  max-width: 100%;
  max-height: 62vh;
  height: auto;
  margin-inline: auto;
}
@media (min-width: 761px) {
  .scene-spine.layout-about[data-build="2"] .object-stack,
  .scene-spine.layout-about[data-build="3"] .object-stack {
    transform: translate(var(--land-x, 5.15vw), var(--land-y, 3.64vh))
      rotate(-13deg) scale(0.1772);
  }
  .scene-spine.layout-about .text > .beat.mose,
  .scene-spine.layout-about .text > .quote {
    translate: 0 var(--mose-y, 15.6vh);
  }
}
@media (min-width: 761px) and (max-height: 800px) {
  .scene-spine.layout-about[data-build="2"] .object-stack,
  .scene-spine.layout-about[data-build="3"] .object-stack {
    transform: translate(var(--land-x, 5.22vw), var(--land-y, 0.73vh))
      rotate(-13deg) scale(0.1772);
  }
  .scene-spine.layout-about .text > .beat.mose,
  .scene-spine.layout-about .text > .quote {
    translate: 0 var(--mose-y, 10.5vh);
  }
}
@media (min-width: 761px) {
  .scene-spine.layout-platform .text > .sub + .beat + .beat {
    grid-column: 2 / 4;
  }
  .scene-spine.layout-platform .text > .beat.with-label:nth-of-type(odd) {
    grid-column: 2;
  }
  .scene-spine.layout-platform .text > .beat.with-label:nth-of-type(even) {
    grid-column: 3;
  }
}

/* ---------- Ported from the Oct 28 deck: rules scoped to the here-we-are scene by its id ---------- */
@media (min-width: 761px) {
  .scene[data-scene-id="here-we-are"] .two > .text,
  .scene[data-scene-id="local-models"] .two > .text {
    display: contents;
  }
  .scene[data-scene-id="here-we-are"] .two .eyebrow-xl,
  .scene[data-scene-id="local-models"] .two .eyebrow-xl {
    grid-column: 1 / -1;
    grid-row: 1;
  }
  .scene[data-scene-id="here-we-are"] .two .statement,
  .scene[data-scene-id="local-models"] .two .statement {
    grid-column: 1 / -1;
    grid-row: 2;
    max-width: none;
  }
  /* here we are: the line and the Pi under the headline at the left, the clip at the right */
  .scene[data-scene-id="here-we-are"] .two {
    grid-template-rows: auto auto auto minmax(0, 1fr);
    row-gap: 0;
  }
  .scene[data-scene-id="here-we-are"] .two .sub {
    grid-column: 1;
    grid-row: 3;
  }
  .scene[data-scene-id="here-we-are"] .object-group.duo > .object-image {
    grid-column: 1;
    grid-row: 4;
  }
  .scene[data-scene-id="here-we-are"] .object-group.duo > .object-video {
    grid-column: 2;
    grid-row: 3 / 5;
    margin-top: clamp(14px, 2vh, 26px);
  }
}

/* ---------- Ported from the Oct 28 deck (lanea.css and talk.css): the five-point layout of the build-bench scene ---------- */
/* the headline holds still from build to build: the slide hangs from the top instead of re-centring as
   each point's height changes */
.scene-spine[class*="layout-lanea-m"] {
  align-content: start;
}
.scene-spine[class*="layout-lanea-m"] .text {
  display: contents;
}
.scene-spine[class*="layout-lanea-m"] .two {
  grid-template-columns: repeat(5, minmax(0, 1fr)) minmax(0, 5.15fr);
  grid-template-rows: auto auto auto auto auto auto auto auto 1fr;
  column-gap: 0.9vw;
  row-gap: 0;
  align-items: start;
}
.scene-spine[class*="layout-lanea-m"] .eyebrow-xl {
  grid-column: 1 / 6;
  grid-row: 1;
}
.scene-spine[class*="layout-lanea-m"] .statement {
  grid-column: 1 / -1;
  grid-row: 2;
  max-width: none;
  font-size: min(3.35vw, 5.95vh);
  margin-bottom: 1.6vh;
}
@media (min-width: 761px) {
  /* Lane L: the tiles and the viewport sit a little further below the headline */
  .scene-spine[class*="layout-lanea-m"] .statement {
    margin-bottom: 3.6vh;
  }
}
/* Matt's headline rule: across the top at full slide width, one line when it fits (both sentences fit) */
.scene-spine[class*="layout-lanea-m"] .statement {
  white-space: nowrap;
}
.scene-spine[class*="layout-lanea-m"] .statement .sentence {
  display: inline;
}
.scene-spine[class*="layout-lanea-m"] .statement .sentence + .sentence::before {
  content: " ";
}
.scene-spine[class*="layout-lanea-m"] .two > .object.lanea-desk {
  grid-column: 6;
  grid-row: 3 / 10;
  justify-self: end;
  align-self: start;
  margin-left: 1.6vw;
  border-radius: 14px;
  background: none;
  box-shadow:
    0 18px 60px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(255, 255, 255, 0.08);
}
.scene-spine[class*="layout-lanea-m"] .two > .object.lanea-desk img {
  display: block;
  height: min(
    60vh,
    34vw
  ); /* the image fits its column: 1.229 wide per unit tall */
  width: auto;
  max-height: none;
  border-radius: 14px;
}
/* the shared pieces of a point */
.scene-spine[class*="layout-lanea-m"] .beat {
  max-width: none;
  margin: 0;
}
.scene-spine[class*="layout-lanea-m"] .beat .beat-label {
  font: 800 clamp(11px, 0.9vw, 17px) / 1 var(--hb-mono);
  letter-spacing: 0.14em;
  color: var(--hb-mint);
  border-color: rgba(90, 230, 171, 0.45);
  background: rgba(90, 230, 171, 0.08);
  justify-self: start;
  align-self: center;
}
.scene-spine[class*="layout-lanea-m"] [class*="lanea-pt"] {
  grid-column: 1 / 6;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  grid-template-rows: auto auto;
  column-gap: 1.2vw;
  row-gap: 0.6vh;
  align-items: center;
}
.scene-spine[class*="layout-lanea-m"] [class*="lanea-pt"] .beat-icon {
  grid-row: 1 / 3;
  grid-column: 1;
  height: auto;
  width: 6.2vw;
  border-radius: 16px;
  background: var(--hb-surface, #2c2c2e);
}
.scene-spine[class*="layout-lanea-m"] [class*="lanea-pt"] .beat-label {
  grid-column: 2;
  grid-row: 1;
  align-self: end;
}
.scene-spine[class*="layout-lanea-m"] [class*="lanea-pt"] .beat-text {
  grid-column: 2;
  grid-row: 2;
  align-self: start;
  font: 750 min(1.95vw, 3.5vh) / 1.15 var(--hb-font);
  color: var(--hb-text);
  letter-spacing: -0.01em;
}
.scene-spine[class*="layout-lanea-m"] [class*="lanea-body"] {
  grid-column: 1 / 6;
  font: 500 min(1.36vw, 2.45vh) / 1.42 var(--hb-font);
  color: var(--hb-text-secondary);
  margin-top: 1.6vh;
}
.scene-spine[class*="layout-lanea-m"] [class*="lanea-ex"] {
  grid-column: 1 / 6;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 0.8vw;
  align-items: baseline;
  margin-top: 1.4vh;
  padding: 1.1vh 1vw;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.07);
  font: 500 min(1.25vw, 2.25vh) / 1.42 var(--hb-font);
  color: var(--hb-text-secondary);
}
.scene-spine[class*="layout-lanea-m"] [class*="lanea-ex"] .beat-label {
  color: var(--hb-text);
  border-color: rgba(255, 255, 255, 0.25);
  background: none;
  align-self: start;
  margin-top: 0.15em;
}
/* the overview rows (build 0): icon, label, the one-line version */
.scene-spine[class*="layout-lanea-m"] [class*="lanea-idx"] {
  grid-column: 1 / 6;
  display: grid;
  grid-template-columns: auto 9.2em minmax(0, 1fr);
  column-gap: 1vw;
  align-items: center;
  margin-top: 1.2vh;
  font: 500 min(1.25vw, 2.25vh) / 1.35 var(--hb-font);
  color: var(--hb-text-secondary);
}
.scene-spine[class*="layout-lanea-m"] [class*="lanea-idx"] .beat-icon {
  height: auto;
  width: 4.4vw;
  border-radius: 12px;
  background: var(--hb-surface, #2c2c2e);
}
.scene-spine[class*="layout-lanea-m"] [class*="lanea-idx"] .beat-label {
  min-width: 7.4em;
  text-align: center;
}
.scene-spine[class*="layout-lanea-m"] .lanea-idx1 {
  grid-row: 3;
}
.scene-spine[class*="layout-lanea-m"] .lanea-idx2 {
  grid-row: 4;
}
.scene-spine[class*="layout-lanea-m"] .lanea-idx3 {
  grid-row: 5;
}
.scene-spine[class*="layout-lanea-m"] .lanea-idx4 {
  grid-row: 6;
}
.scene-spine[class*="layout-lanea-m"] .lanea-idx5 {
  grid-row: 7;
}
/* ── M1 spotlight: build 0 lists the five; each build then opens one point in full, the five as chips above ── */
.scene-spine.layout-lanea-m1 [class*="lanea-pt"],
.scene-spine.layout-lanea-m1 [class*="lanea-body"],
.scene-spine.layout-lanea-m1 [class*="lanea-ex"] {
  display: none;
}
.scene-spine.layout-lanea-m1:not([data-build="0"]) [class*="lanea-idx"] {
  grid-row: 3;
  grid-template-columns: 1fr;
  justify-items: center;
  row-gap: 0.7vh;
  margin: 0 0 6vh; /* Lane L: clear room between the five tiles and the opened point */
  padding: 1vh 0.4vw 1.2vh;
  border-radius: 14px;
  border: 1px solid transparent;
  opacity: 0.45;
  transition:
    opacity 400ms var(--ease),
    border-color 400ms var(--ease),
    background 400ms var(--ease);
}
.scene-spine.layout-lanea-m1:not([data-build="0"])
  [class*="lanea-idx"]
  .beat-text {
  display: none;
}
.scene-spine.layout-lanea-m1:not([data-build="0"])
  [class*="lanea-idx"]
  .beat-icon {
  width: 4.6vw;
}
.scene-spine.layout-lanea-m1:not([data-build="0"])
  [class*="lanea-idx"]
  .beat-label {
  min-width: 0;
}
.scene-spine.layout-lanea-m1:not([data-build="0"]) .lanea-idx1 {
  grid-column: 1;
}
.scene-spine.layout-lanea-m1:not([data-build="0"]) .lanea-idx2 {
  grid-column: 2;
}
.scene-spine.layout-lanea-m1:not([data-build="0"]) .lanea-idx3 {
  grid-column: 3;
}
.scene-spine.layout-lanea-m1:not([data-build="0"]) .lanea-idx4 {
  grid-column: 4;
}
.scene-spine.layout-lanea-m1:not([data-build="0"]) .lanea-idx5 {
  grid-column: 5;
}
.scene-spine.layout-lanea-m1 [class*="lanea-pt"] {
  grid-row: 4;
}
.scene-spine.layout-lanea-m1 [class*="lanea-body"] {
  grid-row: 5;
}
.scene-spine.layout-lanea-m1 [class*="lanea-ex"] {
  grid-row: 6;
}
.scene-spine.layout-lanea-m1[data-build="1"] .lanea-idx1 {
  opacity: 1;
  border-color: rgba(90, 230, 171, 0.55);
  background: rgba(90, 230, 171, 0.07);
}
.scene-spine.layout-lanea-m1[data-build="1"] .lanea-pt1 {
  display: grid;
  animation: lanea-in 520ms var(--ease) both;
}
.scene-spine.layout-lanea-m1[data-build="1"] .lanea-body1 {
  display: block;
  animation: lanea-in 520ms var(--ease) 90ms both;
}
.scene-spine.layout-lanea-m1[data-build="1"] .lanea-ex1 {
  display: grid;
  animation: lanea-in 520ms var(--ease) 180ms both;
}
.scene-spine.layout-lanea-m1[data-build="2"] .lanea-idx2 {
  opacity: 1;
  border-color: rgba(90, 230, 171, 0.55);
  background: rgba(90, 230, 171, 0.07);
}
.scene-spine.layout-lanea-m1[data-build="2"] .lanea-pt2 {
  display: grid;
  animation: lanea-in 520ms var(--ease) both;
}
.scene-spine.layout-lanea-m1[data-build="2"] .lanea-body2 {
  display: block;
  animation: lanea-in 520ms var(--ease) 90ms both;
}
.scene-spine.layout-lanea-m1[data-build="2"] .lanea-ex2 {
  display: grid;
  animation: lanea-in 520ms var(--ease) 180ms both;
}
.scene-spine.layout-lanea-m1[data-build="3"] .lanea-idx3 {
  opacity: 1;
  border-color: rgba(90, 230, 171, 0.55);
  background: rgba(90, 230, 171, 0.07);
}
.scene-spine.layout-lanea-m1[data-build="3"] .lanea-pt3 {
  display: grid;
  animation: lanea-in 520ms var(--ease) both;
}
.scene-spine.layout-lanea-m1[data-build="3"] .lanea-body3 {
  display: block;
  animation: lanea-in 520ms var(--ease) 90ms both;
}
.scene-spine.layout-lanea-m1[data-build="3"] .lanea-ex3 {
  display: grid;
  animation: lanea-in 520ms var(--ease) 180ms both;
}
.scene-spine.layout-lanea-m1[data-build="4"] .lanea-idx4 {
  opacity: 1;
  border-color: rgba(90, 230, 171, 0.55);
  background: rgba(90, 230, 171, 0.07);
}
.scene-spine.layout-lanea-m1[data-build="4"] .lanea-pt4 {
  display: grid;
  animation: lanea-in 520ms var(--ease) both;
}
.scene-spine.layout-lanea-m1[data-build="4"] .lanea-body4 {
  display: block;
  animation: lanea-in 520ms var(--ease) 90ms both;
}
.scene-spine.layout-lanea-m1[data-build="4"] .lanea-ex4 {
  display: grid;
  animation: lanea-in 520ms var(--ease) 180ms both;
}
.scene-spine.layout-lanea-m1[data-build="5"] .lanea-idx5 {
  opacity: 1;
  border-color: rgba(90, 230, 171, 0.55);
  background: rgba(90, 230, 171, 0.07);
}
.scene-spine.layout-lanea-m1[data-build="5"] .lanea-pt5 {
  display: grid;
  animation: lanea-in 520ms var(--ease) both;
}
.scene-spine.layout-lanea-m1[data-build="5"] .lanea-body5 {
  display: block;
  animation: lanea-in 520ms var(--ease) 90ms both;
}
.scene-spine.layout-lanea-m1[data-build="5"] .lanea-ex5 {
  display: grid;
  animation: lanea-in 520ms var(--ease) 180ms both;
}
@media (max-width: 760px) {
  /* a plain block, so the stage's grid placements (the points share rows there) do not apply */
  html:not(.is-stage) .scene-spine[class*="layout-lanea-m"] .two {
    display: block;
  }
  html:not(.is-stage) .scene-spine[class*="layout-lanea-m"] .statement {
    font-size: clamp(32px, 9.5vw, 44px);
  }
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    .statement
    .sentence {
    display: block; /* one sentence per line: the phone breaks only at the boundary */
  }
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    .statement
    .sentence
    + .sentence::before {
    content: none;
  }
  html:not(.is-stage) .scene-spine[class*="layout-lanea-m"] .statement {
    white-space: normal;
  }
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    [class*="lanea-idx"] {
    display: none;
  }
  html:not(.is-stage) .scene-spine[class*="layout-lanea-m"] [class*="lanea-pt"],
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    [class*="lanea-ex"] {
    display: grid;
    opacity: 1;
    animation: none;
  }
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    [class*="lanea-body"] {
    display: block;
    opacity: 1;
    animation: none;
    padding-left: 0;
    font-size: 17px;
  }
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    [class*="lanea-pt"] {
    margin-top: 22px;
  }
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    [class*="lanea-pt"]
    .beat-icon {
    width: 64px;
  }
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    [class*="lanea-pt"]
    .beat-text {
    font-size: 20px;
  }
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    [class*="lanea-ex"] {
    margin-left: 0;
    font-size: 15px;
  }
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    .two
    > .object.lanea-desk {
    margin: 18px 0 0;
    justify-self: stretch;
  }
  html:not(.is-stage)
    .scene-spine[class*="layout-lanea-m"]
    .two
    > .object.lanea-desk
    img {
    width: 100%;
    height: auto;
  }
}
@keyframes lanea-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  .scene img[src*="/assets/penn/lanea-memory.svg"] {
    content: url("assets/penn/lanea-memory-static.svg");
  }
}

/* ═══ Ported from the Oct 28 deck (closing-the-loop-ese5180): the scene bench-nexus, "The last bottleneck was me".
   Rules from its talk.css, ring-r10.css and lanea.css, in that load order (extract-layout-css-v1.py). ═══ */

/* ── from talk.css ── */
/* Act 4 (ACT4-A): the loop with me in it, then without: a stack of two drawings, no card */
.scene-spine.layout-nexus .object-stack {
  background: none;
  border: 0;
  aspect-ratio: 3 / 2;
}
.scene-spine.layout-nexus .object-stack img.layer {
  object-fit: contain;
}
.scene-spine.layout-nexus .beat {
  color: var(--hb-mint);
  font-weight: 700;
}
/* Act 5, 7.0 and 7.1: the loop at the right, the issue-workflow row along the bottom, Test and
   Feedback outlined in red on their own a moment after the slide lands */
.scene-spine.layout-nexus .object-group.nexus2 {
  display: contents;
}
/* LOOP-D: callouts beside the loop; the waiting one goes when the loop closes */
.scene-spine.layout-nexus .object-group.loopbox {
  position: relative;
  display: block;
}
.scene-spine.layout-nexus .object-group.loopbox > .object.waits,
.scene-spine.layout-nexus .object-group.loopbox > .object.outside {
  position: absolute;
  background: none;
  border: 0;
  z-index: 3;
  transition: opacity 700ms var(--ease);
}
.scene-spine.layout-nexus .object-group.loopbox > .object.waits {
  left: 2%;
  bottom: -2%;
  width: 46%;
}
.scene-spine.layout-nexus .object-group.loopbox > .object.outside {
  right: 0;
  top: -9%;
  width: 66%;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-group.loopbox
  > .object.waits {
  opacity: 0;
}
.scene-spine.layout-nexus .object-group.loopbox > .object.outside:not(.on) {
  opacity: 0;
}
.scene-spine.layout-nexus .object-group.loopbox > .object img {
  max-height: none;
  border-radius: 0;
}
.scene-spine.layout-nexus .object-group.loopbox > .object.waits {
  width: 50%;
}
.scene-spine.layout-nexus .object-group.loopbox > .object.outside {
  width: 78%;
}
@media (max-width: 760px) {
  html:not(.is-stage)
    .scene-spine.layout-nexus
    .object-group.loopbox
    > .object.waits,
  html:not(.is-stage)
    .scene-spine.layout-nexus
    .object-group.loopbox
    > .object.outside {
    transition: none;
  }
}
.scene-rail .station .object.meloop {
  width: min(100%, 44vw);
}
/* ── 8.0 and 8.1: the issue-workflow row under the loop. Each step is one cell: its number, its mark
   and its word on top, Human or AI under them. At 8.0 Test and Feedback light red a moment after
   the slide lands; at 8.1, with me off the ring, Test drops its red and flips to AI, Feedback leaves
   the row, the row closes the gap, and Close takes number 07: Human first, then AI on every step.
   Every step of 8.1 is a class the engine sets at once; the delays here put them in order. */
.pipeline-row {
  --g: 12px;
  display: flex;
  gap: var(--g);
}
.pipeline-row .cell {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: baseline;
  align-content: start;
  column-gap: 0.55em;
  padding: 0.75em 0.9em 0.8em;
  overflow: hidden;
  border-radius: 14px;
  background: rgba(44, 44, 46, 0.8);
  border: 1px solid var(--hb-line);
  box-shadow: inset 0 0 0 1px transparent;
  transition:
    border-color 600ms var(--ease),
    background 600ms var(--ease),
    box-shadow 600ms var(--ease),
    opacity 450ms var(--ease),
    flex-grow 750ms cubic-bezier(0.55, 0, 0.25, 1),
    padding 750ms cubic-bezier(0.55, 0, 0.25, 1),
    margin 750ms cubic-bezier(0.55, 0, 0.25, 1),
    border-width 750ms cubic-bezier(0.55, 0, 0.25, 1);
}
.pipeline-row .cell.ai {
  border-color: rgba(90, 230, 171, 0.35);
}
.pipeline-row .cell.red {
  border-color: #f87171;
  box-shadow: inset 0 0 0 1px #f87171;
  background: rgba(248, 113, 113, 0.1);
}
.pipeline-row .cell.gone {
  /* Feedback leaves: it fades, then its slot closes and the cells after it slide into the gap */
  flex-grow: 0.0001;
  opacity: 0;
  padding-left: 0;
  padding-right: 0;
  border-width: 0;
  margin-right: calc(var(--g) * -1);
  transition-delay: 0ms, 0ms, 0ms, 1400ms, 1850ms, 1850ms, 1850ms, 1850ms;
}
.pipeline-row .n {
  grid-column: 1;
  grid-row: 1;
  display: inline-grid;
  font: 600 0.55em / 1 var(--hb-mono);
  color: var(--hb-muted);
}
.pipeline-row .n b {
  grid-area: 1 / 1;
  font-weight: inherit;
}
.pipeline-row .n .was {
  opacity: 0;
}
.pipeline-row .cell.renum .n .was {
  animation: renum-out 420ms var(--ease) 2650ms both;
}
.pipeline-row .cell.renum .n .now {
  animation: renum-in 420ms var(--ease) 2650ms both;
}
.pipeline-row .s {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  align-items: baseline;
  gap: 0.32em;
  min-width: 0;
  white-space: nowrap;
  font: 700 1em / 1.18 var(--hb-font);
  color: var(--hb-text);
}
.pipeline-row .s .emoji {
  font-style: normal;
}
.pipeline-row .s .lines {
  /* a two-line word: the second line ends where the first does */
  display: inline-grid;
}
.pipeline-row .s .lines .r {
  justify-self: end;
}
.pipeline-row .chip {
  /* on the cell's floor, so every chip sits on one line whatever the word above it */
  position: absolute;
  left: 1.45em;
  bottom: 1.3em;
  display: inline-flex;
  padding: 0.32em 0.8em;
  border-radius: 999px;
  border: 1px solid rgba(199, 199, 204, 0.55);
  background: transparent;
  color: var(--hb-text);
  font: 700 0.62em / 1 var(--hb-font);
  transition:
    background 450ms var(--ease),
    border-color 450ms var(--ease),
    color 450ms var(--ease);
}
.pipeline-row .chip b {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  font-weight: inherit;
  transition:
    max-width 450ms var(--ease),
    opacity 300ms var(--ease);
}
.pipeline-row .chip .h {
  max-width: 5em;
}
.pipeline-row .chip .a {
  max-width: 0;
  opacity: 0;
}
.pipeline-row .cell.ai .chip {
  background: var(--hb-mint);
  border-color: var(--hb-mint);
  color: var(--hb-mint-deep);
}
.pipeline-row .cell.ai .chip .h {
  max-width: 0;
  opacity: 0;
}
.pipeline-row .cell.ai .chip .a {
  max-width: 3em;
  opacity: 1;
}
.pipeline-row .cell.flipped .chip,
.pipeline-row .cell.flipped .chip b {
  transition-delay: 700ms;
}
.scene-spine.layout-nexus .pipeline-row {
  grid-column: 1 / -1;
  margin-top: clamp(14px, 2.6vh, 32px);
  font-size: clamp(14px, 1.15vw, 22px);
}
@media (min-width: 761px) {
  .scene-spine.layout-nexus {
    --u: min(1vw, 1.7778vh);
  }
  .scene-spine.layout-nexus .pipeline-row {
    --g: calc(var(--u) * 0.62);
    font-size: calc(var(--u) * 1.15);
  }
  .scene-spine.layout-nexus .pipeline-row .cell {
    height: calc(var(--u) * 6.3);
    box-sizing: border-box;
  }
}
@media (max-width: 760px) {
  html:not(.is-stage) .pipeline-row {
    flex-wrap: wrap;
  }
  html:not(.is-stage) .pipeline-row .cell {
    flex: 1 1 40%;
  }
  html:not(.is-stage) .pipeline-row .cell.gone {
    display: none;
  }
  html:not(.is-stage) .pipeline-row .cell,
  html:not(.is-stage) .pipeline-row .cell *,
  html:not(.is-stage) .pipeline-row .n b {
    transition: none;
    animation: none;
  }
  html:not(.is-stage) .pipeline-row .cell.renum .n .was {
    opacity: 0;
  }
}
@media (max-width: 760px) {
  .pipeline-row .cell {
    height: auto;
    row-gap: 8px;
  }
  .pipeline-row .chip {
    position: static;
    grid-column: 1 / -1;
    justify-self: start;
  }
}
@media (max-width: 760px) {
  html:not(.is-stage)
    .scene-spine.layout-nexus[data-build="2"]
    .object-group.loopbox
    > .object.onloop.on {
    transition: none;
    transition-delay: 0s;
    opacity: 1;
  }
}
@keyframes renum-out {
  from {
    opacity: 1;
    transform: none;
  }
  to {
    opacity: 0;
    transform: translateY(-0.6em);
  }
}
@keyframes renum-in {
  from {
    opacity: 0;
    transform: translateY(0.6em);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* ── from ring-r10.css ── */
/* ── Test and Feedback to AI turn red the first time the pulse reaches me, and stay red ── */
.scene-rail[data-ring="waiting"] .pipeline .cell[data-cell="test"],
.scene-rail[data-ring="waiting"] .pipeline .cell[data-cell="feedback"],
.scene-spine.layout-nexus[data-ring="waiting"]
  .pipeline-row
  .cell[data-cell="test"]:not(.flipped):not(.gone),
.scene-spine.layout-nexus[data-ring="waiting"]
  .pipeline-row
  .cell[data-cell="feedback"]:not(.flipped):not(.gone) {
  border-color: #f87171;
  box-shadow: inset 0 0 0 1px #f87171;
  background: rgba(248, 113, 113, 0.1);
}
/* ── 8.0 and 8.1: the words over the ring. The ring's centre is (480, 330) of its 900 x 600 box ── */
.scene-spine.layout-nexus .object-group.loopbox > .object.inloop,
.scene-spine.layout-nexus .object-group.loopbox > .object.onloop {
  position: absolute;
  left: 53.333%;
  top: 55%;
  width: 42%;
  transform: translate(-50%, -50%);
  background: none;
  border: 0;
  z-index: 3;
  opacity: 0;
  pointer-events: none;
  transition: opacity 700ms var(--ease);
}
.scene-spine.layout-nexus[data-ring="waiting"]:not([data-build="2"])
  .object-group.loopbox
  > .object.inloop {
  opacity: 1;
}
/* 8.1: the red "in" gives way to the mint "on" as the loop closes */
.scene-spine.layout-nexus[data-build="2"]
  .object-group.loopbox
  > .object.onloop.on {
  opacity: 1;
  transition-delay: 450ms;
}
/* the callouts sit centred above the ring, on its centre line; the waiting one arrives with the red */
.scene-spine.layout-nexus .object-group.loopbox > .object.waits,
.scene-spine.layout-nexus .object-group.loopbox > .object.outside {
  top: -9%;
  bottom: auto;
  left: 53.333%;
  right: auto;
  transform: translateX(-50%);
}
.scene-spine.layout-nexus .object-group.loopbox > .object.waits {
  width: 50%;
}
.scene-spine.layout-nexus .object-group.loopbox > .object.outside {
  width: 65%;
}
.scene-spine.layout-nexus:not([data-ring="waiting"])
  .object-group.loopbox
  > .object.waits {
  opacity: 0;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-group.loopbox
  > .object.outside.on {
  transition-delay: 450ms;
}
/* ── 8.1: the steps the agent now runs glow mint, framed together under the word Automated ── */
.scene-spine.layout-nexus .pipeline-row {
  position: relative;
}
.scene-spine.layout-nexus .pipeline-row::before,
.scene-spine.layout-nexus .pipeline-row::after {
  position: absolute;
  /* after Feedback leaves, seven cells share the row: the frame starts after the first */
  left: calc((100% - 6 * var(--g)) / 7 + var(--g) / 2);
  right: calc(var(--g) / -2);
  opacity: 0;
  pointer-events: none;
  transition: opacity 700ms var(--ease);
}
.scene-spine.layout-nexus .pipeline-row::after {
  content: "";
  top: calc(var(--g) / -2);
  bottom: calc(var(--g) / -2);
  border: 2px solid var(--hb-mint, #5ae6ab);
  border-radius: 18px;
  box-shadow:
    0 0 24px rgba(90, 230, 171, 0.35),
    inset 0 0 18px rgba(90, 230, 171, 0.12);
}
.scene-spine.layout-nexus .pipeline-row::before {
  content: "Automated";
  bottom: calc(100% + var(--g) / 2 + 0.25em);
  padding-left: 0.2em;
  color: var(--hb-mint, #5ae6ab);
  font-size: 1.35em;
  font-weight: 600;
  line-height: 1;
}
.scene-spine.layout-nexus[data-build="2"] .pipeline-row::before,
.scene-spine.layout-nexus[data-build="2"] .pipeline-row::after {
  opacity: 1;
  transition-delay: 2700ms;
}
.scene-spine.layout-nexus[data-build="2"] .pipeline-row .cell.ai:not(.gone) {
  border-color: rgba(90, 230, 171, 0.75);
  box-shadow: 0 0 16px rgba(90, 230, 171, 0.28);
  transition-delay: 2700ms;
}
@media (prefers-reduced-motion: reduce) {
  .scene-spine.layout-nexus .object-stack img.layer.base,
  .scene-rail .station .object.meloop img {
    content: url("assets/act5b/nexus-me-in-loop-static.svg");
  }
  .scene-spine.layout-nexus .object-stack img.layer:not(.base) {
    content: url("assets/act5b/loop-closed-me-static.svg");
  }
}
@media (max-width: 760px) {
  html:not(.is-stage) .scene-spine.layout-nexus .object-stack img.layer.base,
  html:not(.is-stage) .scene-rail .station .object.meloop img {
    content: url("assets/act5b/nexus-me-in-loop-static.svg");
  }
  html:not(.is-stage)
    .scene-spine.layout-nexus
    .object-stack
    img.layer:not(.base) {
    content: url("assets/act5b/loop-closed-me-static.svg");
  }
  /* the reading page shows every build at once: no fades or delays here, so each [data-at]
     element is fully shown the moment the page is ready (verifier check 2) */
  html:not(.is-stage) .scene-spine.layout-nexus .object-group.loopbox > .object,
  html:not(.is-stage) .scene-spine.layout-nexus .pipeline-row .cell,
  html:not(.is-stage) .scene-rail .pipeline .cell {
    transition: none;
  }
  html:not(.is-stage)
    .scene-spine.layout-nexus
    .object-group.loopbox
    > .object.onloop.on,
  html:not(.is-stage)
    .scene-spine.layout-nexus
    .object-group.loopbox
    > .object.outside.on {
    opacity: 1;
  }
  /* room above the ring for the callout, clear of the line above it */
  html:not(.is-stage) .scene-spine.layout-nexus .object-group.loopbox {
    margin-top: 11%;
  }
  html:not(.is-stage) .scene-spine.layout-nexus .pipeline-row::before,
  html:not(.is-stage) .scene-spine.layout-nexus .pipeline-row::after {
    display: none;
  }
}

/* ── from lanea.css ── */
/* ═══ Lane A (#5867) — slide 6 (bench-nexus): build 0 holds on the spinner with me opaque (the drawing is
   assets/penn/lanea-nexus-me-in-loop.svg); build 1 is one motion. My waiting marks fade, I lift off the
   ring to my place beside it, the agent, the firmware, and the board slide to their places on the closed
   ring, the instruments and the readings arrive in the gap, and the animated closed loop takes over.
   The moves are lanea-ring-v1.py's MOVES as percentages of the 900 x 600 frame. Keyframes run each time
   build 1 arrives; stepping back drops them, so the pieces snap away. ═══ */
.scene-spine.layout-nexus
  .object-stack
  img.layer[class*="lanea-rg-"]:not(.lanea-rg-final) {
  opacity: 0;
  transform: none;
  transition: none;
  border-radius: 0;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-final {
  transition: opacity 700ms var(--ease) 2300ms;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-line,
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-mepanel,
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-mewait,
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-me,
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-agent,
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-firmware,
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-board,
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-instruments,
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-readings {
  animation-duration: 3100ms;
  animation-fill-mode: both;
  animation-timing-function: linear;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-line {
  animation-name: lanea-hold;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-mewait {
  animation-name: lanea-wait-out;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-mepanel {
  animation-name: lanea-panel-out;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-me {
  animation-name: lanea-me-lift;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-agent {
  animation-name: lanea-agent-move;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-firmware {
  animation-name: lanea-firmware-move;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-board {
  animation-name: lanea-board-move;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-instruments {
  animation-name: lanea-arrive-1;
  transform-origin: 33.7% 78.2%;
}
.scene-spine.layout-nexus[data-build="2"]
  .object-stack
  img.layer.on.lanea-rg-readings {
  animation-name: lanea-arrive-2;
  transform-origin: 21.6% 46.1%;
}
/* the words over the ring wait for the loop to close */
.scene-spine.layout-nexus[data-build="2"][data-scene-id="bench-nexus"]
  .object-group.loopbox
  > .object.onloop.on,
.scene-spine.layout-nexus[data-build="2"][data-scene-id="bench-nexus"]
  .object-group.loopbox
  > .object.outside.on {
  transition-delay: 2600ms;
}
@media (prefers-reduced-motion: reduce) {
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"]
    .object-stack
    img.layer.base {
    content: url("assets/penn/lanea-nexus-me-in-loop-static.svg");
  }
  .scene-spine.layout-nexus
    .object-stack
    img.layer[class*="lanea-rg-"]:not(.lanea-rg-final) {
    display: none;
  }
}
@media (max-width: 760px) {
  /* the reading page shows every build at once, with no fades (verifier check 2) */
  html:not(.is-stage)
    .scene-spine.layout-nexus[data-build="2"]
    .object-stack
    img.layer.on.lanea-rg-final {
    transition: none;
  }
  html:not(.is-stage)
    .scene-spine.layout-nexus[data-scene-id="bench-nexus"]
    .object-stack
    img.layer.base {
    content: url("assets/penn/lanea-nexus-me-in-loop-static.svg");
  }
  html:not(.is-stage)
    .scene-spine.layout-nexus
    .object-stack
    img.layer[class*="lanea-rg-"]:not(.lanea-rg-final) {
    display: none;
  }
}
@media (min-width: 761px) {
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .two {
    grid-template-columns: minmax(0, 1fr) minmax(0, 0.92fr);
    grid-template-rows:
      auto auto auto minmax(0, 1fr) auto minmax(0, 1fr) auto
      minmax(0, 1fr) auto;
    column-gap: calc(var(--u) * 3);
    row-gap: 0;
    align-items: start;
  }
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .text {
    display: contents;
  }
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .eyebrow-xl {
    grid-column: 1 / -1;
    grid-row: 1;
  }
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .statement {
    grid-column: 1 / -1;
    grid-row: 2;
    max-width: none;
    white-space: nowrap;
  }
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .statement .sentence {
    display: inline;
  }
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .sub {
    grid-column: 1;
    grid-row: 3;
  }
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .beat {
    grid-column: 1;
    grid-row: 5;
    margin: 0;
    max-width: none;
    font-size: calc(var(--u) * 1.8);
    line-height: 1.3;
  }
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .beat + .beat {
    grid-row: 7;
  }
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .object-group.loopbox {
    grid-column: 2;
    grid-row: 3 / 9;
    align-self: start;
    margin-top: calc(var(--u) * 4.2);
  }
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .pipeline-row {
    grid-row: 9;
  }
}
@keyframes lanea-hold {
  0%,
  84% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}
@keyframes lanea-wait-out {
  0% {
    opacity: 1;
  }
  13%,
  100% {
    opacity: 0;
  }
}
@keyframes lanea-panel-out {
  0%,
  8% {
    opacity: 1;
  }
  24%,
  100% {
    opacity: 0;
  }
}
@keyframes lanea-me-lift {
  0%,
  8% {
    opacity: 1;
    transform: none;
    animation-timing-function: cubic-bezier(0.45, 0, 0.25, 1);
  }
  47% {
    opacity: 1;
    transform: translate(-7.333%, -42.133%);
  }
  84% {
    opacity: 1;
    transform: translate(-7.333%, -42.133%);
  }
  99% {
    opacity: 0;
    transform: translate(-7.333%, -42.133%);
  }
  /* faded out: back to its origin, so a spent piece never sits outside the frame */
  100% {
    opacity: 0;
    transform: none;
  }
}
@keyframes lanea-agent-move {
  0%,
  32% {
    opacity: 1;
    transform: none;
    animation-timing-function: cubic-bezier(0.45, 0, 0.25, 1);
  }
  65%,
  84% {
    opacity: 1;
    transform: translate(0%, -4%);
  }
  99% {
    opacity: 0;
    transform: translate(0%, -4%);
  }
  /* faded out: back to its origin, so a spent piece never sits outside the frame */
  100% {
    opacity: 0;
    transform: none;
  }
}
@keyframes lanea-firmware-move {
  0%,
  32% {
    opacity: 1;
    transform: none;
    animation-timing-function: cubic-bezier(0.45, 0, 0.25, 1);
  }
  65%,
  84% {
    opacity: 1;
    transform: translate(-1.631%, -9.858%);
  }
  99% {
    opacity: 0;
    transform: translate(-1.631%, -9.858%);
  }
  /* faded out: back to its origin, so a spent piece never sits outside the frame */
  100% {
    opacity: 0;
    transform: none;
  }
}
@keyframes lanea-board-move {
  0%,
  32% {
    opacity: 1;
    transform: none;
    animation-timing-function: cubic-bezier(0.45, 0, 0.25, 1);
  }
  65%,
  84% {
    opacity: 1;
    transform: translate(19.593%, -6.808%);
  }
  99% {
    opacity: 0;
    transform: translate(19.593%, -6.808%);
  }
  /* faded out: back to its origin, so a spent piece never sits outside the frame */
  100% {
    opacity: 0;
    transform: none;
  }
}
@keyframes lanea-arrive-1 {
  0%,
  42% {
    opacity: 0;
    transform: translateY(5%) scale(0.86);
    animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1);
  }
  65%,
  84% {
    opacity: 1;
    transform: none;
  }
  100% {
    opacity: 0;
    transform: none;
  }
}
@keyframes lanea-arrive-2 {
  0%,
  48% {
    opacity: 0;
    transform: translateY(5%) scale(0.86);
    animation-timing-function: cubic-bezier(0.2, 0.8, 0.2, 1);
  }
  71%,
  84% {
    opacity: 1;
    transform: none;
  }
  100% {
    opacity: 0;
    transform: none;
  }
}

/* This deck keeps the kit's eyebrow (engine.css), which with its margin is 8 px taller than the Oct 28 deck's
   own. On a short projector that pushed this scene 3 px past the stage (check L12 at 1280x720), so the gap
   under the eyebrow tightens here, as the Oct 28 deck's did at the same height. */
@media (max-height: 820px) {
  .scene-spine.layout-nexus[data-scene-id="bench-nexus"] .eyebrow-xl {
    margin-bottom: 12px;
  }
}

/* ═══ The answer pages ═══ */
/* The question takes the band's full width, clear of the button (the Oct 28 deck's rule 17). The kit caps the
   headline's width, which wrapped a question that fits on one line (check L1). */
.scene-answer .qtext {
  flex: 1 1 auto;
  min-width: 0;
}
.scene-answer .qtext .statement.compact {
  max-width: none;
}

/* An object's figure has rounded corners and clips its overflow (engine.css .object). Its caption sits flush left
   at the bottom, so the rounded bottom-left corner cut the first letter of the caption's last line ("from" read
   as "rom", "Matt's" as "att's"). On an answer page the object is a plain table or a picture that rounds its own
   corners, so the figure neither rounds nor clips here. */
.scene-answer .object {
  border-radius: 0;
  overflow: visible;
}

/* ═══ The formats Matt picked on 2026-11-19 (lifted from mockups/build-format-mockups-v2.py by add-picked-formats-v1.py). Every one: the headline across the slide on one
   line, the content under it at full width, and a figure that neither rounds nor clips. ═══ */
.scene-spine[class*="layout-ese-"] {
  align-content: start;
  padding-top: 12vh;
  padding-bottom: 5vh;
}
.scene-spine[class*="layout-ese-"] .two {
  display: block;
}
.scene-spine[class*="layout-ese-"] .statement {
  max-width: none;
  white-space: nowrap;
  font-size: clamp(30px, 3.3vw, 62px);
}
.scene-spine[class*="layout-ese-"] .statement .sentence {
  display: inline;
}
.scene-spine[class*="layout-ese-"] .sub,
.scene-spine[class*="layout-ese-"] .beat {
  max-width: none;
}
.scene-spine[class*="layout-ese-"] .object {
  border-radius: 0;
  overflow: visible;
}
.scene-spine[class*="layout-ese-"] .two > .object {
  margin-top: clamp(18px, 3.2vh, 40px);
}
.scene-spine[class*="layout-ese-"] .object table {
  display: block;
  font-size: clamp(15px, 1.5vw, 29px);
}
.scene-spine[class*="layout-ese-"] .object .credit {
  font-size: clamp(12px, 0.95vw, 17px);
}

/* ── F2: the measurement table, shared ── */
.ese-meas table,
.ese-keyed table {
  width: 100%;
  font-size: clamp(18px, 1.8vw, 35px) !important;
}
.ese-meas tr,
.ese-keyed tr {
  display: grid;
  grid-template-columns: 1.5fr 1fr 0.8fr;
}
.ese-meas th,
.ese-meas td,
.ese-keyed th,
.ese-keyed td {
  padding: 0.62em 0.6em;
}
.ese-meas td:first-child,
.ese-keyed td:first-child {
  font-weight: 700;
  color: var(--t-text);
}
.ese-meas td:not(:first-child),
.ese-meas th:not(:first-child),
.ese-keyed td:not(:first-child),
.ese-keyed th:not(:first-child) {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* ── F2 v2: parts as tiles ── */
.ese-ex2 {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  column-gap: 4vw;
  align-items: center;
}
.ese-tiles {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.ese-tiles .object-table {
  padding: 1em 0.5em;
  border: 1px solid var(--t-line-strong);
  border-radius: 16px !important;
  background: rgba(var(--t-surface-rgb), 0.7);
  text-align: center;
}
.ese-tiles tr,
.ese-tiles th,
.ese-tiles td {
  display: block;
  border: 0;
  padding: 0;
  text-align: center;
}
.ese-tiles th {
  font-size: 2.6em;
  line-height: 1.1;
  letter-spacing: 0;
}
.ese-tiles td {
  padding-top: 0.45em;
  font-size: 0.95em;
  line-height: 1.2;
  font-weight: 600;
  color: var(--t-text);
  min-height: 2.4em;
}

/* ── F3 v3: three places I touch the loop ── */
.ese-three {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 2.6vw;
}
.ese-three .object-table {
  border-top: 3px solid var(--t-accent);
}
.ese-three tr {
  display: grid;
  grid-template-columns: 1.5em 1fr;
  column-gap: 0.5em;
}
.ese-three tr:first-child {
  display: block;
}
.ese-three th,
.ese-three td {
  border: 0;
  padding: 0;
}
.ese-three th {
  display: block;
  padding: 0.9em 0 0.2em;
  font: 700 clamp(13px, 1.05vw, 19px) / 1 var(--t-mono);
  color: var(--t-accent);
}
.ese-three tr:nth-child(even) {
  margin-top: 1.3em;
}
.ese-three tr:nth-child(even) td:first-child {
  font: 800 1.9em/1 var(--t-font);
  color: var(--t-accent);
}
.ese-three tr:nth-child(even) td:last-child {
  font-weight: 800;
  font-size: 1.15em;
  line-height: 1.2;
  color: var(--t-text);
}
.ese-three tr:nth-child(odd):not(:first-child) td:last-child {
  margin-top: 0.4em;
  line-height: 1.3;
  color: var(--t-text-secondary);
}

/* ── F4 v2: five groups side by side ── */
.ese-cols5 {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  column-gap: 18px;
  align-items: start;
}
.ese-cols5 tr,
.ese-cols5 th,
.ese-cols5 td {
  display: block;
  border: 0;
}
.ese-cols5 th {
  padding: 0 0 0.7em;
  font: 800 clamp(20px, 1.9vw, 36px) / 1 var(--t-font);
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--t-accent);
}
.ese-cols5 td {
  margin-bottom: 12px;
  padding: 0.75em 0.85em;
  border: 1px solid var(--t-line-strong);
  border-radius: 14px;
  background: rgba(var(--t-surface-rgb), 0.7);
  font-size: 0.83em;
  line-height: 1.28;
  color: var(--t-text);
}
.ese-cols5 > .object:nth-of-type(5) td {
  border-style: dashed;
  background: none;
  color: var(--t-text-secondary);
}
.ese-cols5 > .credit {
  grid-column: 1 / -1;
}

/* ── F5 v2: five steps on a ring ── */
.scene-spine.layout-ese-loop-ring .two {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  column-gap: 3vw;
  row-gap: 0;
  align-items: start;
}
.scene-spine.layout-ese-loop-ring .text {
  display: contents;
}
.scene-spine.layout-ese-loop-ring .eyebrow-xl,
.scene-spine.layout-ese-loop-ring .statement {
  grid-column: 1 / -1;
}
.scene-spine.layout-ese-loop-ring .sub,
.scene-spine.layout-ese-loop-ring .beat {
  grid-column: 1;
}
.scene-spine.layout-ese-loop-ring .beat {
  margin-top: 0.7em;
  padding-left: 1.2em;
  position: relative;
  font-size: clamp(18px, 1.7vw, 33px);
  color: var(--t-text);
}
.scene-spine.layout-ese-loop-ring .beat::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 0.5em;
  height: 0.5em;
  border-radius: 50%;
  background: var(--t-danger);
}
.scene-spine.layout-ese-loop-ring .two > .object {
  grid-column: 2;
  grid-row: 3 / span 6;
  margin-top: 10vh;
}
.ese-ring {
  position: relative;
  width: 52vh;
  height: 52vh;
  margin: 0 auto;
}
.ese-ring::before {
  content: "";
  position: absolute;
  inset: 0;
  border: 5px solid rgba(var(--t-accent-rgb), 0.45);
  border-radius: 50%;
}
.ese-ring .object-table {
  position: absolute;
  width: 12.5em;
  transform: translate(-50%, -50%);
  padding: 0.7em 0.8em 0.8em;
  text-align: center;
  border: 1px solid var(--t-line-strong);
  border-radius: 18px !important;
  background: var(--t-surface);
}
.ese-ring th {
  font-size: 1.7em;
  line-height: 1;
  letter-spacing: 0;
  text-align: center;
}
.ese-ring td {
  margin-top: 0.35em;
  text-align: center;
  font-weight: 800;
  line-height: 1.2;
  color: var(--t-text);
}
.ese-ring table {
  font-size: clamp(14px, 1.3vw, 25px) !important;
}
.ese-ring .ese-you {
  border: 2px solid var(--t-danger);
}
.ese-ring .object-table:nth-of-type(1) {
  left: 50%;
  top: 0;
}
.ese-ring .object-table:nth-of-type(2) {
  left: 97.6%;
  top: 34.5%;
}
.ese-ring .object-table:nth-of-type(3) {
  left: 79.4%;
  top: 90.5%;
}
.ese-ring .object-table:nth-of-type(4) {
  left: 20.6%;
  top: 90.5%;
}
.ese-ring .object-table:nth-of-type(5) {
  left: 2.4%;
  top: 34.5%;
}

/* ── F6 v1: three lanes ── */
.ese-lanes {
  display: grid;
  grid-template-columns: 5.2em repeat(7, 1fr);
  grid-template-rows: repeat(3, auto);
  column-gap: 12px;
  row-gap: 0;
}
.ese-lanes table {
  font-size: clamp(12px, 1.22vw, 23.5px) !important;
}
.ese-lanes tr,
.ese-lanes th,
.ese-lanes td,
.ese-chain7 tr,
.ese-chain7 th,
.ese-chain7 td {
  display: block;
  border: 0;
  padding: 0;
}
.ese-lanes .ese-lane1,
.ese-lanes .ese-lane2,
.ese-lanes .ese-lane3 {
  grid-column: 1 / -1;
  padding: 0.9em 0 0.9em 0.2em;
  border-top: 1px solid var(--t-line-strong);
  min-height: 20.5vh;
  box-sizing: border-box;
}
.ese-lanes .ese-lane1 {
  grid-row: 1;
}
.ese-lanes .ese-lane2 {
  grid-row: 2;
}
.ese-lanes .ese-lane3 {
  grid-row: 3;
}
.ese-lanes .ese-lane1 th,
.ese-lanes .ese-lane2 th,
.ese-lanes .ese-lane3 th {
  width: 6.4em;
  font: 700 0.78em/1.3 var(--t-mono);
  color: var(--t-accent);
}
.ese-lanes .ese-in1,
.ese-lanes .ese-in2,
.ese-lanes .ese-in3 {
  align-self: center;
  padding: 0.7em 0.8em 0.8em;
  border: 1px solid var(--t-line-strong);
  border-radius: 14px !important;
  background: var(--t-surface);
  z-index: 1;
}
.ese-lanes .ese-in1 {
  grid-row: 1;
}
.ese-lanes .ese-in2 {
  grid-row: 2;
}
.ese-lanes .ese-in3 {
  grid-row: 3;
}
.ese-lanes > .object:nth-of-type(4) {
  grid-column: 2;
}
.ese-lanes > .object:nth-of-type(5) {
  grid-column: 3;
}
.ese-lanes > .object:nth-of-type(6) {
  grid-column: 4;
}
.ese-lanes > .object:nth-of-type(7) {
  grid-column: 5;
}
.ese-lanes > .object:nth-of-type(8) {
  grid-column: 6;
}
.ese-lanes > .object:nth-of-type(9) {
  grid-column: 7;
}
.ese-lanes > .object:nth-of-type(10) {
  grid-column: 8;
}
.ese-lanes [class*="ese-in"] th,
.ese-chain7 th {
  font: 800 1.7em/1 var(--t-font);
  letter-spacing: 0;
  color: var(--t-accent);
}
.ese-lanes [class*="ese-in"] tr:nth-child(2) td,
.ese-chain7 tr:nth-child(2) td {
  margin-top: 0.3em;
  font-weight: 700;
  line-height: 1.22;
  color: var(--t-text);
}
.ese-lanes [class*="ese-in"] tr:nth-child(3) td,
.ese-chain7 tr:nth-child(3) td {
  margin-top: 0.6em;
  font: 600 0.8em/1.35 var(--t-mono);
  color: var(--t-warn);
}

/* ── F7 v2: one table, five rows ── */
.ese-wt table {
  width: 100%;
  font-size: clamp(13px, 1.22vw, 23.5px) !important;
}
.ese-wt tr {
  display: grid;
  grid-template-columns: 2em 1fr 1.35fr 1.1fr;
  column-gap: 1.2em;
}
.ese-wt th,
.ese-wt td {
  padding: 0.75em 0;
}
.ese-wt td:first-child {
  font: 800 1.9em/1 var(--t-font);
  color: var(--t-accent);
}
.ese-wt td:nth-child(2) {
  font-weight: 800;
  color: var(--t-text);
}
.ese-wt td:nth-child(3) {
  color: var(--t-text-secondary);
}
.ese-wt td:nth-child(4) {
  color: var(--t-accent);
  font-weight: 600;
}

/* ── what a real slide needs beyond its mockup ── */

/* long headlines: a smaller size keeps each on one line across the slide */
.scene[data-scene-id="loop-defined"] .statement {
  font-size: clamp(22px, 2.42vw, 46.5px);
}
.scene[data-scene-id="loop-closed"] .statement,
.scene[data-scene-id="ex2-device"] .statement,
.scene[data-scene-id="worst-case"] .statement {
  font-size: clamp(24px, 2.65vw, 51px);
}
.scene[data-scene-id="three-failures"] .statement {
  font-size: clamp(26px, 2.95vw, 56.5px);
}

/* the ring: its cells are plain blocks; a numbered ring (nobody marked); the lines beside it */
.ese-ring tr,
.ese-ring th,
.ese-ring td {
  display: block;
  border: 0;
  padding: 0;
}
.ese-ring .ese-step th {
  font: 800 1.5em/1 var(--t-font);
  color: var(--t-accent);
}
.scene-spine.layout-ese-loop-ring .beat.ese-end::before {
  background: var(--t-accent);
}
.scene[data-scene-id="loop-defined"] .sub {
  font-size: clamp(17px, 1.6vw, 31px);
  line-height: 1.4;
  color: var(--t-text);
}

/* the question to the room, on an example's second press */
.beat.ese-ask {
  margin-top: 4.5vh;
  padding: 0.7em 1em;
  border-left: 5px solid var(--t-accent);
  background: rgba(var(--t-accent-rgb), 0.09);
  font: 700 clamp(18px, 1.9vw, 36px) / 1.3 var(--t-font);
  color: var(--t-text);
}
.scene-spine.layout-ese-ex-tiles .two {
  display: flex;
  flex-direction: column;
  /* the engine's two-column gap and centring do not apply to this column */
  gap: 0;
  align-items: stretch;
}
.scene-spine.layout-ese-ex-tiles .text {
  display: contents;
}
.scene-spine.layout-ese-ex-tiles .beat.ese-ask {
  order: 2;
}
.scene-spine.layout-ese-ex-tiles .two > .object {
  order: 1;
}

/* Example 2: five tiles in three columns, and a measurement table whose third column is words */
.ese-tiles3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.ese-tiles3 .object-table {
  padding: 1em 0.5em;
  border: 1px solid var(--t-line-strong);
  border-radius: 16px !important;
  background: rgba(var(--t-surface-rgb), 0.7);
  text-align: center;
}
.ese-tiles3 tr,
.ese-tiles3 th,
.ese-tiles3 td {
  display: block;
  border: 0;
  padding: 0;
  text-align: center;
}
.ese-tiles3 th {
  font-size: 2.6em;
  line-height: 1.1;
  letter-spacing: 0;
}
.ese-tiles3 td {
  padding-top: 0.45em;
  font-size: 0.9em;
  line-height: 1.2;
  font-weight: 600;
  color: var(--t-text);
  min-height: 3.6em;
}
.ese-meas2 table {
  width: 100%;
  font-size: clamp(16px, 1.45vw, 28px) !important;
}
.ese-meas2 tr {
  display: grid;
  grid-template-columns: 1.25fr 0.9fr 1.25fr;
  column-gap: 0.8em;
}
.ese-meas2 th,
.ese-meas2 td {
  padding: 0.62em 0.3em;
}
.ese-meas2 td:first-child {
  font-weight: 700;
  color: var(--t-text);
}
.ese-meas2 td:nth-child(2) {
  text-align: right;
  font-weight: 700;
  color: var(--t-text);
  font-variant-numeric: tabular-nums;
}
.ese-meas2 th:nth-child(2) {
  text-align: right;
}
.ese-meas2 td:nth-child(3) {
  font-size: 0.78em;
  line-height: 1.35;
}

/* builds, on the stage only (the browse page shows every slide complete) */
html.is-stage .layout-ese-worst-table .ese-wt tr {
  transition: opacity 400ms var(--ease);
}
html.is-stage
  .layout-ese-worst-table[data-scene-id="worst-case"][data-build="0"]
  .ese-wt
  tr:nth-child(n + 3) {
  opacity: 0;
}
html.is-stage
  .layout-ese-worst-table[data-scene-id="worst-case"][data-build="1"]
  .ese-wt
  tr:nth-child(n + 4) {
  opacity: 0;
}
html.is-stage
  .layout-ese-worst-table[data-scene-id="worst-case"][data-build="2"]
  .ese-wt
  tr:nth-child(n + 5) {
  opacity: 0;
}
html.is-stage
  .layout-ese-worst-table[data-scene-id="worst-case"][data-build="3"]
  .ese-wt
  tr:nth-child(n + 6) {
  opacity: 0;
}
html.is-stage
  .layout-ese-jobs-three[data-build="1"]
  .ese-three
  tr:not(:first-child) {
  opacity: 0.3;
}
html.is-stage
  .layout-ese-jobs-three[data-build="1"]
  .ese-three
  > .object:nth-of-type(1)
  tr:nth-child(2),
html.is-stage
  .layout-ese-jobs-three[data-build="1"]
  .ese-three
  > .object:nth-of-type(1)
  tr:nth-child(3) {
  opacity: 1;
}
html.is-stage
  .layout-ese-jobs-three[data-build="2"]
  .ese-three
  tr:not(:first-child) {
  opacity: 0.3;
}
html.is-stage
  .layout-ese-jobs-three[data-build="2"]
  .ese-three
  > .object:nth-of-type(1)
  tr:nth-child(4),
html.is-stage
  .layout-ese-jobs-three[data-build="2"]
  .ese-three
  > .object:nth-of-type(1)
  tr:nth-child(5) {
  opacity: 1;
}
html.is-stage
  .layout-ese-jobs-three[data-build="3"]
  .ese-three
  tr:not(:first-child) {
  opacity: 0.3;
}
html.is-stage
  .layout-ese-jobs-three[data-build="3"]
  .ese-three
  > .object:nth-of-type(2)
  tr:nth-child(2),
html.is-stage
  .layout-ese-jobs-three[data-build="3"]
  .ese-three
  > .object:nth-of-type(2)
  tr:nth-child(3) {
  opacity: 1;
}
html.is-stage
  .layout-ese-jobs-three[data-build="4"]
  .ese-three
  tr:not(:first-child) {
  opacity: 0.3;
}
html.is-stage
  .layout-ese-jobs-three[data-build="4"]
  .ese-three
  > .object:nth-of-type(2)
  tr:nth-child(4),
html.is-stage
  .layout-ese-jobs-three[data-build="4"]
  .ese-three
  > .object:nth-of-type(2)
  tr:nth-child(5) {
  opacity: 1;
}
html.is-stage
  .layout-ese-jobs-three[data-build="5"]
  .ese-three
  tr:not(:first-child) {
  opacity: 0.3;
}
html.is-stage
  .layout-ese-jobs-three[data-build="5"]
  .ese-three
  > .object:nth-of-type(3)
  tr:nth-child(2),
html.is-stage
  .layout-ese-jobs-three[data-build="5"]
  .ese-three
  > .object:nth-of-type(3)
  tr:nth-child(3) {
  opacity: 1;
}
html.is-stage
  .layout-ese-jobs-three[data-build="6"]
  .ese-three
  tr:not(:first-child) {
  opacity: 0.3;
}
html.is-stage
  .layout-ese-jobs-three[data-build="6"]
  .ese-three
  > .object:nth-of-type(3)
  tr:nth-child(4),
html.is-stage
  .layout-ese-jobs-three[data-build="6"]
  .ese-three
  > .object:nth-of-type(3)
  tr:nth-child(5) {
  opacity: 1;
}
html.is-stage .layout-ese-jobs-three .ese-three tr {
  transition: opacity 400ms var(--ease);
}

/* ── the phone form (the browse page at 393 px): what sits side by side on the stage stacks here ── */
@media (max-width: 760px) {
  .scene-spine[class*="layout-ese-"] .statement,
  .scene[data-scene-id="loop-defined"] .statement,
  .scene[data-scene-id="loop-closed"] .statement,
  .scene[data-scene-id="ex2-device"] .statement,
  .scene[data-scene-id="worst-case"] .statement,
  .scene[data-scene-id="three-failures"] .statement {
    white-space: normal;
    font-size: 27px;
  }
  .scene-spine[class*="layout-ese-"] .object table {
    font-size: 15px !important;
  }
  .ese-cols5,
  .ese-three,
  .ese-ex2 {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 22px;
  }
  .ese-tiles,
  .ese-tiles3 {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }
  .ese-meas tr,
  .ese-meas2 tr {
    grid-template-columns: 1.3fr 1fr 0.8fr;
    column-gap: 6px;
  }
  .ese-meas2 tr {
    grid-template-columns: 1fr 0.8fr 1fr;
  }
  .beat.ese-ask {
    font-size: 17px;
    margin-top: 18px;
  }
  /* the ring keeps its shape, smaller, under the words */
  .scene-spine.layout-ese-loop-ring .two {
    display: block;
  }
  .scene-spine.layout-ese-loop-ring .two > .object {
    margin-top: 64px;
    margin-bottom: 44px;
  }
  .ese-ring {
    width: 62vw;
    height: 62vw;
  }
  .ese-ring .object-table {
    width: 7.4em;
    padding: 0.45em 0.4em 0.5em;
  }
  .ese-ring table {
    font-size: 12.5px !important;
  }
  /* the lanes become one list, each step naming who acts */
  .ese-lanes {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 10px;
  }
  .ese-lanes .ese-lane1,
  .ese-lanes .ese-lane2,
  .ese-lanes .ese-lane3 {
    display: none;
  }
  .ese-lanes > .object[class*="ese-in"] {
    grid-column: 1;
    grid-row: auto;
  }
  .ese-lanes .ese-in1::before,
  .ese-lanes .ese-in2::before,
  .ese-lanes .ese-in3::before {
    display: block;
    margin-bottom: 0.3em;
    font: 700 11px/1 var(--t-mono);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--t-accent);
  }
  .ese-lanes .ese-in1::before {
    content: "Me";
  }
  .ese-lanes .ese-in2::before {
    content: "Hapimatic and the agent";
  }
  .ese-lanes .ese-in3::before {
    content: "The bench";
  }
  /* the four-column tables: one cause per block */
  .ese-wt tr {
    grid-template-columns: 1.6em minmax(0, 1fr);
    column-gap: 0.5em;
    padding: 0.5em 0;
  }
  .ese-wt tr:first-child {
    display: none;
  }
  .ese-wt td {
    padding: 0.15em 0;
    grid-column: 2;
  }
  .ese-wt td:first-child {
    grid-column: 1;
    grid-row: 1 / span 3;
  }
}

/* A 720 px stage is short for an example slide once its question to the room is up: tighter spacing there */
@media (max-height: 820px) {
  .scene-spine.layout-ese-ex-tiles {
    padding-top: 11vh;
    padding-bottom: 3vh;
  }
  .scene-spine.layout-ese-ex-tiles .two > .object {
    margin-top: 14px;
  }
  .ese-tiles .object-table,
  .ese-tiles3 .object-table {
    padding: 0.55em 0.4em;
  }
  .ese-tiles td,
  .ese-tiles3 td {
    min-height: 0;
  }
  .beat.ese-ask {
    margin-top: 14px;
    padding: 0.5em 0.9em;
    font-size: clamp(17px, 1.65vw, 30px);
  }
}

/* The three lanes on a 720 px stage: tighter lanes and cards, so the seventh card clears the bottom */
@media (max-height: 820px) {
  .scene-spine.layout-ese-req-lanes {
    padding-top: 11vh;
    padding-bottom: 3vh;
  }
  .ese-lanes .ese-lane1,
  .ese-lanes .ese-lane2,
  .ese-lanes .ese-lane3 {
    min-height: 19vh;
    padding: 0.5em 0 0.5em 0.2em;
  }
  .ese-lanes .ese-in1,
  .ese-lanes .ese-in2,
  .ese-lanes .ese-in3 {
    padding: 0.5em 0.6em 0.55em;
  }
}

/* The two four-column tables have room to spare on the stage: larger type for the back rows */
@media (min-width: 761px) {
  .scene[data-scene-id="worst-case"] .ese-wt table {
    font-size: clamp(14px, 1.36vw, 26px) !important;
  }
  .scene[data-scene-id="three-failures"] .ese-wt table {
    font-size: clamp(15px, 1.75vw, 33.5px) !important;
  }
}

/* On a phone the engine stacks every group in one column. Tiles stay two across there, and compact, because
   one tile per row cost a screen of scrolling for eight parts. */
@media (max-width: 760px) {
  html:not(.is-stage) .object-group.ese-tiles,
  html:not(.is-stage) .object-group.ese-tiles3 {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px;
  }
  .ese-tiles .object-table,
  .ese-tiles3 .object-table {
    padding: 0.5em 0.4em;
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    column-gap: 0.5em;
    text-align: left;
  }
  .ese-tiles table,
  .ese-tiles3 table {
    display: contents !important;
  }
  .ese-tiles tr,
  .ese-tiles3 tr {
    display: contents;
  }
  .ese-tiles th,
  .ese-tiles3 th {
    font-size: 1.5em;
  }
  .ese-tiles td,
  .ese-tiles3 td {
    padding-top: 0;
    min-height: 0;
    text-align: left;
    font-size: 13.5px;
  }
}

/* ═══ The base slides (add-base-slides-v1.py): a list, a table of terms, a figure beside its text, a pair of
   pictures, a quotation, and the cycle drawn to scale ═══ */

/* long headlines on one line */
.scene[data-scene-id="step-reproduce"] .statement,
.scene[data-scene-id="ex1-answer"] .statement {
  font-size: clamp(26px, 2.9vw, 55.5px);
}
.scene[data-scene-id="work-name"] .statement,
.scene[data-scene-id="five-claim"] .statement {
  font-size: clamp(24px, 2.6vw, 50px);
}
.scene[data-scene-id="ex2-cause"] .statement {
  font-size: clamp(22px, 2.3vw, 44px);
}
/* two sentences: one line each */
.scene[data-scene-id="five-claim"] .statement .sentence {
  display: block;
}

/* a numbered list */
.ese-list table {
  width: 100%;
  font-size: clamp(19px, 2.5vw, 48px) !important;
}
.ese-list tr {
  display: grid;
  grid-template-columns: 1.6em 1fr;
  align-items: baseline;
  border-top: 1px solid var(--t-line);
}
.ese-list tr:first-child {
  display: none;
}
.ese-list td {
  border: 0;
  padding: 0.6em 0;
}
.ese-list td:first-child {
  font: 800 1.15em/1 var(--t-font);
  color: var(--t-accent);
}
.ese-list td:last-child {
  font-weight: 700;
  color: var(--t-text);
}

/* a plain list under a heading */
.ese-list1 table {
  width: 100%;
  font-size: clamp(18px, 2.1vw, 40px) !important;
}
.ese-list1 tr,
.ese-list1 th,
.ese-list1 td {
  display: block;
}
.ese-list1 td {
  padding: 0.42em 0;
  font-weight: 700;
  color: var(--t-text);
}
.ese-list1 .credit {
  margin-top: 1.2em;
  font: 700 clamp(18px, 1.9vw, 36px) / 1.3 var(--t-font) !important;
  color: var(--t-accent);
}

/* a table of terms: a short name, then what it means */
.ese-terms table,
.ese-terms7 table {
  width: 100%;
  font-size: clamp(16px, 1.75vw, 33.5px) !important;
}
.ese-terms7 table {
  font-size: clamp(13px, 1.3vw, 25px) !important;
}
.ese-terms tr,
.ese-terms7 tr {
  display: grid;
  grid-template-columns: minmax(0, 0.42fr) minmax(0, 1fr);
  column-gap: 2.4vw;
}
.ese-terms7 tr {
  grid-template-columns: minmax(0, 0.24fr) minmax(0, 1fr);
}
.ese-terms th,
.ese-terms td,
.ese-terms7 th,
.ese-terms7 td {
  padding: 0.62em 0;
}
.ese-terms7 td {
  padding: 0.5em 0;
}
.ese-terms td:first-child,
.ese-terms7 td:first-child {
  font-weight: 800;
  color: var(--t-text);
}
/* the arithmetic table has no column headings */
.scene[data-scene-id="ex2-numbers"] .ese-terms tr:first-child {
  display: none;
}
.ese-terms .credit {
  margin-top: 1.3em;
  font: 700 clamp(18px, 1.9vw, 36px) / 1.3 var(--t-font) !important;
  color: var(--t-accent);
}

/* a figure beside its text */
.scene-spine.layout-ese-figure .two {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  column-gap: 4vw;
  row-gap: 0;
  align-items: start;
}
.scene-spine.layout-ese-figure .text {
  display: contents;
}
.scene-spine.layout-ese-figure .eyebrow-xl,
.scene-spine.layout-ese-figure .statement {
  grid-column: 1 / -1;
}
.scene-spine.layout-ese-figure .sub,
.scene-spine.layout-ese-figure .beat {
  grid-column: 1;
}
.scene-spine.layout-ese-figure .sub {
  margin-top: 5vh;
  font-size: clamp(19px, 2.1vw, 40px);
  line-height: 1.3;
  color: var(--t-text);
}
.scene-spine.layout-ese-figure .two > .object {
  grid-column: 2;
  grid-row: 3 / span 6;
  margin-top: 5vh;
}
.scene-spine.layout-ese-figure .object img {
  width: 100%;
  max-height: 60vh;
  object-fit: contain;
  object-position: top;
}
.beat.ese-idea {
  margin-top: 0.9em;
  padding-left: 1em;
  border-left: 4px solid var(--t-accent);
  font-size: clamp(17px, 1.7vw, 33px);
  font-weight: 600;
  color: var(--t-text);
}

/* a pair of pictures under the text */
.ese-pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 2.6vw;
  align-items: start;
}
.ese-pair img {
  width: 100%;
  max-height: 52vh;
  object-fit: contain;
  object-position: top;
  border-radius: 10px;
}
.ese-stack2 {
  display: grid;
  row-gap: 1.6vh;
}
.ese-stack2 img {
  max-height: 25vh;
}
.scene-spine.layout-ese-wide .sub {
  font-size: clamp(17px, 1.65vw, 32px);
}
.scene-spine.layout-ese-wide .two > .object {
  margin-top: 3vh;
}

/* a quotation: the prompt above, the sentence large */
.scene-spine.layout-ese-quote .two {
  display: flex;
  flex-direction: column;
  gap: 0;
  align-items: stretch;
}
.scene-spine.layout-ese-quote .text {
  display: contents;
}
.scene-spine.layout-ese-quote .two > .object {
  order: 1;
  margin-top: 4vh;
}
.scene-spine.layout-ese-quote .statement {
  order: 2;
  margin-top: 7vh;
  white-space: normal;
  max-width: 17em;
  font-size: clamp(34px, 4.6vw, 88px);
  color: var(--t-accent);
}
.ese-prompt tr,
.ese-prompt th,
.ese-prompt td {
  display: block;
  border: 0;
  padding: 0;
}
.ese-prompt td {
  margin-top: 0.5em;
  font-size: clamp(19px, 2.1vw, 40px);
  line-height: 1.3;
  color: var(--t-text-secondary);
}

/* the example's answer: the table, the cycle to scale, then the three ideas */
.scene-spine.layout-ese-ex-strip .two {
  display: flex;
  flex-direction: column;
  gap: 0;
  align-items: stretch;
}
.scene-spine.layout-ese-ex-strip .text {
  display: contents;
}
.scene-spine.layout-ese-ex-strip .two > .object {
  order: 1;
}
.scene-spine.layout-ese-ex-strip .beat {
  order: 2;
}
.scene-spine.layout-ese-ex-strip .ese-strip {
  height: 15vh;
}
.scene-spine.layout-ese-ex-strip .ese-ex3 {
  row-gap: 2.4vh;
}
.scene-spine.layout-ese-ex-strip .ese-keyed table {
  font-size: clamp(16px, 1.55vw, 30px) !important;
}
.scene-spine.layout-ese-ex-strip .ese-keyed th,
.scene-spine.layout-ese-ex-strip .ese-keyed td {
  padding: 0.42em 0.6em;
}
.scene-spine.layout-ese-ex-strip .beat.ese-idea {
  margin-top: 0.55em;
  font-size: clamp(16px, 1.5vw, 29px);
}

/* the phone form */
@media (max-width: 760px) {
  .scene[data-scene-id="step-reproduce"] .statement,
  .scene[data-scene-id="ex1-answer"] .statement,
  .scene[data-scene-id="work-name"] .statement,
  .scene[data-scene-id="five-claim"] .statement,
  .scene[data-scene-id="ex2-cause"] .statement {
    white-space: normal;
    font-size: 27px;
  }
  .scene-spine.layout-ese-figure .two {
    display: block;
  }
  .scene-spine.layout-ese-figure .sub,
  .scene-spine.layout-ese-figure .two > .object {
    margin-top: 18px;
  }
  .ese-list table,
  .ese-list1 table {
    font-size: 19px !important;
  }
  .ese-terms tr,
  .ese-terms7 tr {
    grid-template-columns: minmax(0, 1fr);
  }
  .ese-terms td,
  .ese-terms7 td {
    padding: 0.2em 0;
  }
  .ese-terms td:first-child,
  .ese-terms7 td:first-child {
    padding-top: 0.7em;
    border-top: 1px solid var(--t-line);
  }
  .ese-terms td:last-child,
  .ese-terms7 td:last-child {
    border-top: 0;
  }
  .ese-terms tr:first-child,
  .ese-terms7 tr:first-child {
    display: none;
  }
  .ese-pair img,
  .ese-stack2 img {
    max-height: none;
  }
  .scene-spine.layout-ese-quote .statement {
    font-size: 30px;
    margin-top: 28px;
  }
  .scene-spine.layout-ese-ex-strip .ese-strip {
    height: 90px;
  }
  .beat.ese-idea {
    font-size: 16px;
  }
}

/* ── the cycle drawn to scale (the mockup builder's format 2, variant 3) ── */
.beat.ese-inline {
  margin-top: 0.7em;
  font-size: clamp(15px, 1.3vw, 25px);
}
.ese-ex3 {
  display: grid;
  row-gap: 3.4vh;
}
.ese-keyed td:first-child {
  padding-left: 1.6em;
  position: relative;
}
.ese-keyed td:first-child::before {
  content: "";
  position: absolute;
  left: 0.3em;
  top: 50%;
  width: 0.8em;
  height: 0.8em;
  transform: translateY(-50%);
  border-radius: 3px;
}
.ese-keyed tr:nth-child(2) td:first-child::before {
  background: var(--t-warn);
}
.ese-keyed tr:nth-child(3) td:first-child::before {
  background: var(--t-info);
}
.ese-keyed tr:nth-child(4) td:first-child::before {
  background: var(--t-accent);
}
.ese-strip {
  display: grid;
  grid-template-columns: 94.4fr 39.62fr 900fr;
  column-gap: 3px;
  align-items: end;
  height: 26vh;
  position: relative;
  padding-bottom: 2.6em;
  border-bottom: 0;
}
.ese-strip > .object-table {
  border-radius: 4px 4px 0 0 !important;
}
.ese-strip > .object-table table {
  display: none;
}
.ese-strip > .seg-a {
  height: 100%;
  background: var(--t-warn);
}
.ese-strip > .seg-b {
  height: 92.8%;
  background: var(--t-info);
}
.ese-strip > .seg-c {
  height: 92.8%;
  background: var(--t-accent);
}
.ese-strip > .credit {
  position: absolute;
  left: 0;
  bottom: 0;
  margin: 0;
}

/* The two reused figures are animated drawings. Under reduced motion each shows its still twin (check L34). */
@media (prefers-reduced-motion: reduce) {
  .scene[data-scene-id="ex1-result"] img[src$="4-audio-fig.svg"] {
    content: url("assets/act5/cases/low-power/4-audio-fig-static.svg");
  }
  .scene[data-scene-id="ex2-cause"] img[src$="3-wearable-fig.svg"] {
    content: url("assets/act5/cases/fuel-gauge/3-wearable-fig-static.svg");
  }
}

/* the answer slide's tighter cells must keep room for the colour key before each state's name */
.scene-spine.layout-ese-ex-strip .ese-keyed td:first-child {
  padding-left: 1.6em;
}

/* On a phone the engine stacks every group in one column, which broke the to-scale strip into three full-width
   bars. The strip keeps its three time-proportional columns there. */
@media (max-width: 760px) {
  html:not(.is-stage) .object-group.ese-strip {
    grid-template-columns: 94.4fr 39.62fr 900fr !important;
    gap: 2px;
  }
}

/* ═══ Part 6, before and now: one engineer inside one loop, then above several (the ring Matt picked) ═══ */
.ese-bn {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  column-gap: 5vw;
  row-gap: 2.6vh;
  align-items: start;
  justify-items: center;
}
/* one group, placed in two columns: the heading and the ring on the left, the "now" pieces on the right */
.ese-bn > .ese-head-before {
  grid-column: 1;
  grid-row: 1;
}
.ese-bn > .ese-ring6 {
  grid-column: 1;
  grid-row: 2 / span 3;
}
.ese-bn > .ese-head-now {
  grid-column: 2;
  grid-row: 1;
}
.ese-bn > .ese-me {
  grid-column: 2;
  grid-row: 2;
}
.ese-bn > .ese-loops3 {
  grid-column: 2;
  grid-row: 3;
}
.ese-bn > .ese-touch {
  grid-column: 2;
  grid-row: 4;
}
.ese-bn > .ese-head-before,
.ese-bn > .ese-head-now {
  justify-self: stretch;
  padding-bottom: 0.7em;
  border-bottom: 2px solid var(--t-accent);
}
.ese-bn > .ese-head-before {
  border-bottom-color: var(--t-danger);
}
.ese-head-before th,
.ese-head-now th {
  display: block;
  padding: 0;
  border: 0;
  font: 700 clamp(16px, 1.5vw, 29px) / 1.25 var(--t-font);
  letter-spacing: 0;
  text-transform: none;
  color: var(--t-text);
}
.ese-ring6 {
  position: relative;
  width: 44vh;
  height: 44vh;
  margin: 7vh 0 6vh;
}
.ese-ring6::before {
  content: "";
  position: absolute;
  inset: 0;
  border: 5px solid rgba(var(--t-danger-rgb), 0.5);
  border-radius: 50%;
}
.ese-ring6 .object-table {
  position: absolute;
  width: 9.6em;
  transform: translate(-50%, -50%);
  padding: 0.5em 0.6em 0.6em;
  text-align: center;
  border: 2px solid var(--t-danger);
  border-radius: 16px !important;
  background: var(--t-surface);
}
.ese-ring6 table,
.ese-me table,
.ese-mini table,
.ese-touch table {
  font-size: clamp(13px, 1.25vw, 24px) !important;
}
.ese-ring6 tr,
.ese-ring6 th,
.ese-ring6 td,
.ese-me tr,
.ese-me th,
.ese-me td,
.ese-mini tr,
.ese-mini th,
.ese-mini td,
.ese-touch tr,
.ese-touch th,
.ese-touch td {
  display: block;
  border: 0;
  padding: 0;
  text-align: center;
}
.ese-ring6 th,
.ese-me th,
.ese-mini th {
  font-size: 1.5em;
  line-height: 1;
  letter-spacing: 0;
}
.ese-ring6 td {
  margin-top: 0.25em;
  font-weight: 800;
  line-height: 1.2;
  color: var(--t-text);
}
.ese-ring6 .object-table:nth-of-type(1) {
  left: 50%;
  top: 0;
}
.ese-ring6 .object-table:nth-of-type(2) {
  left: 93.3%;
  top: 25%;
}
.ese-ring6 .object-table:nth-of-type(3) {
  left: 93.3%;
  top: 75%;
}
.ese-ring6 .object-table:nth-of-type(4) {
  left: 50%;
  top: 100%;
}
.ese-ring6 .object-table:nth-of-type(5) {
  left: 6.7%;
  top: 75%;
}
.ese-ring6 .object-table:nth-of-type(6) {
  left: 6.7%;
  top: 25%;
}
.ese-me {
  padding: 0.6em 1.4em 0.7em;
  border: 2px solid var(--t-accent);
  border-radius: 999px !important;
  background: rgba(var(--t-accent-rgb), 0.1);
}
.ese-me td {
  font-weight: 800;
  color: var(--t-text);
}
.ese-loops3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: 2vw;
  justify-items: center;
}
.ese-mini {
  width: 9.4em;
  aspect-ratio: 1;
  display: grid;
  align-content: center;
  border: 5px solid rgba(var(--t-accent-rgb), 0.5);
  border-radius: 50% !important;
}
.ese-mini td {
  margin-top: 0.3em;
  padding: 0 0.8em;
  font-weight: 700;
  line-height: 1.2;
  color: var(--t-text);
}
.ese-touch {
  justify-self: stretch;
}
.ese-touch table {
  width: 100%;
}
.ese-touch th {
  padding-bottom: 0.6em;
  font: 700 0.62em/1 var(--t-mono);
  color: var(--t-accent);
}
.ese-touch td {
  padding: 0.42em 0;
  border-top: 1px solid var(--t-line);
  font-weight: 700;
  color: var(--t-text);
}
@media (max-width: 760px) {
  .ese-ring6 {
    width: 60vw;
    height: 60vw;
    margin: 48px auto 40px;
  }
  .ese-ring6 .object-table {
    width: 6.6em;
    padding: 0.35em 0.3em 0.4em;
  }
  .ese-ring6 table,
  .ese-me table,
  .ese-mini table {
    font-size: 12.5px !important;
  }
  html:not(.is-stage) .object-group.ese-loops3 {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    column-gap: 6px;
  }
  .ese-mini {
    width: 100%;
    border-width: 3px;
  }
}

/* before and now, on a phone: one column, in reading order (the stage's two-column placement is undone) */
@media (max-width: 760px) {
  .ese-bn > .object {
    grid-column: 1;
    grid-row: auto;
  }
  .ese-bn > .ese-ring6 {
    justify-self: center;
  }
}
@media (min-width: 761px) {
  .ese-mini {
    width: 10.4em;
  }
}

/* ── the eight-step procedure: four checks, then a loop (Matt's pick of 2026-11-19; the mockup builder's F1 v3) ── */
.ese-flow {
  display: grid;
  row-gap: 3vh;
}
.ese-flow table {
  font-size: clamp(14px, 1.36vw, 26px) !important;
}
.ese-flow > .object-group {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  column-gap: 2.6vw;
}
.ese-flow .object-table {
  position: relative;
  padding: 0.9em 1em 1em;
  border: 1px solid var(--t-line-strong);
  border-radius: 16px !important;
  background: rgba(var(--t-surface-rgb), 0.7);
}
.ese-flow tr,
.ese-flow th,
.ese-flow td {
  display: block;
  border: 0;
  padding: 0;
}
.ese-flow th {
  font: 800 2.2em/1 var(--t-font);
  letter-spacing: 0;
  color: var(--t-accent);
  padding-bottom: 0.3em;
}
.ese-flow tr:nth-child(2) td {
  font-weight: 700;
  font-size: 1.2em;
  line-height: 1.22;
  color: var(--t-text);
}
.ese-flow tr:nth-child(3) td {
  margin-top: 0.45em;
  color: var(--t-text-secondary);
  line-height: 1.3;
  min-height: 2.6em;
}
.ese-flow .object-table:not(:last-of-type)::after {
  content: "→";
  position: absolute;
  right: -1.3vw;
  top: 50%;
  transform: translate(50%, -50%);
  font: 700 1.7em/1 var(--t-font);
  color: var(--t-accent);
}
.ese-flow > .ese-loop {
  position: relative;
  padding: 3.3em 1.5em 1.4em;
  margin: 0 -1.5em;
  border: 2px dashed rgba(var(--t-accent-rgb), 0.6);
  border-radius: 26px !important;
}
.ese-flow > .ese-loop > .credit {
  position: absolute;
  left: 1.5em;
  top: 0.8em;
  margin: 0;
  font: 700 clamp(16px, 1.35vw, 26px) / 1 var(--t-font) !important;
  color: var(--t-accent);
}
.scene-spine.layout-ese-proc-loop .sub {
  color: var(--t-accent);
  font-weight: 700;
}

/* ── what the procedure slide needs beyond its mockup ── */
/* the phone form: the steps stack as compact rows (number left, words right), with no arrows */
@media (max-width: 760px) {
  .ese-flow {
    row-gap: 18px;
  }
  .ese-flow table {
    font-size: 15px !important;
  }
  .ese-flow .object-table {
    display: grid;
    grid-template-columns: 1.7em minmax(0, 1fr);
    column-gap: 0.5em;
    align-items: start;
    padding: 0.55em 0.75em 0.6em;
    border-radius: 12px !important;
  }
  .ese-flow .object-table table,
  .ese-flow .object-table tbody,
  .ese-flow .object-table tr {
    display: contents !important;
  }
  .ese-flow th {
    grid-row: 1 / span 2;
    font-size: 1.6em;
    padding: 0;
  }
  .ese-flow tr:nth-child(2) td {
    font-size: 1em;
  }
  .ese-flow tr:nth-child(3) td {
    margin-top: 0.2em;
    min-height: 0;
    font-size: 13.5px;
  }
  .ese-flow .object-table::after {
    content: none;
  }
  html:not(.is-stage) .object-group.ese-row,
  html:not(.is-stage) .object-group.ese-loop {
    grid-template-columns: minmax(0, 1fr) !important;
    row-gap: 8px;
  }
  .ese-flow > .ese-loop {
    margin: 0;
    padding: 2.7em 0.6em 0.7em;
    border-radius: 18px !important;
  }
  .ese-flow > .ese-loop > .credit {
    left: 0.9em;
    top: 0.9em;
    font-size: 15px !important;
  }
}

/* The procedure on a phone: the mockup's arrow rule carries :not(:last-of-type), so the override needs the same
   selector to win; the loop's label shrinks to fit the narrow box */
@media (max-width: 760px) {
  .ese-flow .object-table:not(:last-of-type)::after {
    content: none;
  }
  .ese-flow > .ese-loop > .credit {
    font-size: 13.5px !important;
  }
}

/* The procedure on a 720 px stage: tighter spacing, so the loop of steps 5 to 8 clears the bottom */
@media (max-height: 820px) and (min-width: 761px) {
  .scene-spine.layout-ese-proc-loop {
    padding-top: 11vh;
    padding-bottom: 3vh;
  }
  .ese-flow {
    row-gap: 2vh;
  }
  .ese-flow .object-table {
    padding: 0.6em 0.85em 0.7em;
  }
  .ese-flow th {
    font-size: 1.8em;
    padding-bottom: 0.15em;
  }
  .ese-flow tr:nth-child(3) td {
    min-height: 0;
  }
  .ese-flow > .ese-loop {
    padding-top: 2.8em;
    padding-bottom: 1em;
  }
}

/* ═══ Part 7, the test fixture (add-fixture-v1.py): two renders of different shapes at one height, captions in one row ═══ */
.ese-fx {
  display: grid;
  grid-template-columns: minmax(0, 2.17fr) minmax(0, 1.1fr);
  column-gap: 2.6vw;
  align-items: start;
}
.ese-fx img {
  width: 100%;
  height: 46vh;
  object-fit: contain;
  object-position: center bottom;
}
.ese-fx > .credit {
  grid-column: 1 / -1;
}
.scene[data-scene-id="fixture"] .sub {
  font-size: clamp(16px, 1.55vw, 30px);
}
@media (max-height: 820px) {
  .ese-fx img {
    height: 40vh;
  }
}
@media (max-width: 760px) {
  .ese-fx img {
    height: auto;
  }
}

/* ═══ Part 2, the loop's target (apply-nick-reply-v1.py): the manual's requirement, quoted ═══ */
.scene[data-scene-id="loop-target"] .statement {
  font-size: clamp(24px, 2.6vw, 50px);
}
.scene-spine.layout-ese-target .two {
  display: block;
}
.scene-spine.layout-ese-target .two > .object {
  margin-top: 4.5vh;
}
.ese-req {
  display: grid;
  row-gap: 3.2vh;
}
.ese-req tr,
.ese-req th,
.ese-req td {
  display: block;
  border: 0;
  padding: 0;
}
.ese-reqquote table {
  font-size: clamp(20px, 2.35vw, 45px) !important;
}
.ese-reqquote th {
  margin-bottom: 0.8em;
  font: 700 0.42em/1.2 var(--t-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--t-accent);
}
.ese-reqquote td {
  padding-left: 0.8em;
  border-left: 6px solid var(--t-accent);
  font-weight: 700;
  line-height: 1.3;
  color: var(--t-text);
}
.ese-reqnums table {
  font-size: clamp(18px, 2.1vw, 40px) !important;
}
.ese-reqnums tr {
  display: flex;
  gap: 1.2em;
}
.ese-reqnums th {
  padding: 0.45em 1em;
  border: 2px solid var(--t-accent);
  border-radius: 999px;
  background: rgba(var(--t-accent-rgb), 0.1);
  /* a header cell: the engine gives th a small mono face, so set the face itself */
  font: 800 1em/1.2 var(--t-font);
  letter-spacing: 0;
  text-transform: none;
  color: var(--t-text);
}
.ese-reqdone table {
  font-size: clamp(18px, 2.1vw, 40px) !important;
}
.ese-reqdone th {
  font: 600 1em/1.35 var(--t-font);
  letter-spacing: 0;
  text-transform: none;
  color: var(--t-text-secondary);
}
@media (max-width: 760px) {
  .scene[data-scene-id="loop-target"] .statement {
    white-space: normal;
    font-size: 27px;
  }
  .ese-reqquote table {
    font-size: 19px !important;
  }
  .ese-reqnums table,
  .ese-reqdone table {
    font-size: 15px !important;
  }
  .ese-reqnums tr {
    flex-wrap: wrap;
    gap: 8px;
  }
}

/* loop-target on a phone: the label over the quote stays legible (0.42em of 19px was 8px) */
@media (max-width: 760px) {
  .ese-reqquote th {
    font-size: 11px;
  }
}

/* ═══ Part 5, the investigation (add-part5-v1.py): the device, the requirement, two charts, the budget, the video cards ═══ */
.ese-vidph table {
  margin: 6vh auto 0;
  font-size: clamp(22px, 2.6vw, 50px) !important;
}
.ese-vidph tr,
.ese-vidph th,
.ese-vidph td {
  display: block;
  border: 0;
  padding: 0;
  text-align: center;
}
.ese-vidph th {
  padding: 1.1em 1.6em 0.3em;
  border: 2px dashed var(--t-accent);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
  font: 800 1em/1.2 var(--t-font);
  letter-spacing: 0;
  text-transform: none;
  color: var(--t-accent);
}
.ese-vidph td {
  padding: 0.2em 1.6em 1.1em;
  border: 2px dashed var(--t-accent);
  border-top: 0;
  border-radius: 0 0 18px 18px;
  font-size: 0.5em;
  color: var(--t-text-secondary);
}
.scene[data-scene-id="p5-budget"] .statement,
.scene[data-scene-id="p5-requirement"] .statement,
.scene[data-scene-id="p5-video-1"] .statement,
.scene[data-scene-id="p5-results"] .statement {
  font-size: clamp(24px, 2.6vw, 50px);
}
.ese-opts table {
  font-size: clamp(17px, 1.85vw, 35px) !important;
}
.ese-opts tr {
  display: block;
}
.ese-opts th,
.ese-opts td {
  display: block;
  padding: 0.28em 0 0.28em 0.9em;
  border: 0;
  border-left: 5px solid var(--t-accent-muted);
  margin-bottom: 0.35em;
  font: 600 1em/1.3 var(--t-font);
  letter-spacing: 0;
  text-transform: none;
  color: var(--t-text);
}
.scene[data-scene-id="p5-budget"] .ese-req {
  row-gap: 2.4vh !important;
}
@media (max-width: 760px) {
  .ese-vidph table {
    font-size: 22px !important;
  }
  .ese-opts table {
    font-size: 15px !important;
  }
}

/* ═══ Part 5, the two chapters (swap-part5-videos-v1.py): the video under the headline, as large as fits ═══ */
.ese-p5video video {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: 62vh;
  margin: 1.5vh auto 0;
  border-radius: 12px;
  background: #161618;
}
.ese-p5video figcaption {
  text-align: center;
}

/* ═══ Part 6, the productivity timeline (add-productivity-v1.py): the chart fits a 1280x720 stage (check L12) ═══ */
.scene[data-scene-id="pr-timeline"] .object img {
  max-height: 56vh;
  width: auto;
  max-width: 100%;
}

/* ── mh-preview begin: the meta-harness slides (add-meta-harness-slides-v8.py) ── */
/* MH1's ladder: three steps left to right, a drawing over a caption, an arrow in each gap */
.mh-ladder {
  --mh-gap: clamp(30px, 3.6vw, 68px);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: var(--mh-gap);
  align-items: start;
}
.mh-ladder > .object {
  position: relative;
  margin: 0;
}
:is(.mh-step, .mh-step-last) {
  display: grid;
  gap: clamp(8px, 0.8vw, 14px);
}
:is(.mh-step, .mh-step-last) > .object {
  margin: 0;
}
:is(.mh-step, .mh-step-last) .object-svg img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--t-line-strong);
  border-radius: 16px;
  background: rgba(var(--t-surface-rgb), 0.55);
}
:is(.mh-step, .mh-step-last) table {
  display: block;
}
:is(.mh-step, .mh-step-last) tr,
:is(.mh-step, .mh-step-last) th,
:is(.mh-step, .mh-step-last) td {
  display: block;
  border: 0;
  padding: 0;
}
:is(.mh-step, .mh-step-last) th {
  font: 800 clamp(18px, 1.55vw, 30px) / 1.15 var(--t-font);
  letter-spacing: -0.005em;
  text-transform: none;
  color: var(--t-text);
}
.mh-step-last th {
  color: var(--t-accent);
}
:is(.mh-step, .mh-step-last) td {
  margin-top: 0.3em;
  font-size: 0.74em;
  line-height: 1.32;
  color: var(--t-text-secondary);
}
/* the arrow from one step to the next, in the gap before steps 2 and 3, level with the middle of the drawings: a
   vertical margin in % is a share of the width, and each drawing is 340/560 of its width tall */
.mh-ladder > .object + .object:not(.mh-quote)::before {
  content: "";
  position: absolute;
  top: 0;
  margin-top: calc(30.36% - 2px);
  left: calc(var(--mh-gap) * -0.82);
  width: calc(var(--mh-gap) * 0.64);
  height: 4px;
  border-radius: 2px;
  background: var(--t-accent);
}
.mh-ladder > .object + .object:not(.mh-quote)::after {
  content: "";
  position: absolute;
  top: 0;
  margin-top: calc(30.36% - 11px);
  left: calc(var(--mh-gap) * -0.2 - 6px);
  border: 11px solid transparent;
  border-right-width: 0;
  border-left: 14px solid var(--t-accent);
}
/* the premium table: no column headings, a wider name column */
.scene[data-scene-id="mh-premium"] .ese-terms tr:first-child {
  display: none;
}
.scene[data-scene-id="mh-premium"] .ese-terms tr {
  grid-template-columns: minmax(0, 0.62fr) minmax(0, 1fr);
}
/* MH3: three columns (number, what it enables, what that means), rows a little tighter than the four-column tables */
.scene[data-scene-id="mh-ledger"] .ese-wt tr {
  grid-template-columns: 2em minmax(0, 0.85fr) minmax(0, 1.6fr);
}
.scene[data-scene-id="mh-ledger"] .ese-wt th,
.scene[data-scene-id="mh-ledger"] .ese-wt td {
  padding: 0.55em 0;
}
/* six tiles: a large figure over one line of text */
.ese-tiles6 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px 22px;
  align-items: stretch;
}
.ese-tiles6 > .object {
  margin: 0;
}
.ese-tiles6 table {
  display: block;
  height: 100%;
  padding: 0.6em 0.85em 0.7em;
  border: 1px solid var(--t-line-strong);
  border-radius: 14px;
  background: rgba(var(--t-surface-rgb), 0.7);
}
.ese-tiles6 tr,
.ese-tiles6 th,
.ese-tiles6 td {
  display: block;
  border: 0;
  padding: 0;
}
.ese-tiles6 th {
  padding-bottom: 0.22em;
  font: 800 clamp(26px, 2.9vw, 56px) / 1.05 var(--t-font);
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--t-accent);
}
.ese-tiles6 td {
  font-size: 0.84em;
  line-height: 1.3;
  color: var(--t-text);
}
.ese-tiles6 > .credit {
  grid-column: 1 / -1;
}
/* the add-on line, small and quiet */
.beat.mh-fine {
  margin-top: 0.6em;
  font: 400 clamp(14px, 1vw, 20px) / 1.4 var(--t-mono);
  color: var(--t-text-secondary);
}
@media (max-width: 760px) {
  .ese-tiles6 {
    grid-template-columns: minmax(0, 1fr);
  }
  .mh-ladder {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 18px;
  }
  .mh-ladder > .object + .object:not(.mh-quote)::before,
  .mh-ladder > .object + .object:not(.mh-quote)::after {
    display: none;
  }
}

/* option Q: Anthropic's line under MH1's three steps, across all three columns, arriving with the third */
.mh-ladder > .mh-quote {
  grid-column: 1 / -1;
  margin-top: 0.9em;
}
.mh-quote table {
  display: block;
  padding-left: 0.9em;
  border-left: 4px solid var(--t-accent);
}
.mh-quote tr,
.mh-quote th,
.mh-quote td {
  display: block;
  border: 0;
  padding: 0;
}
.mh-quote th {
  font: 600 clamp(18px, 1.8vw, 34px) / 1.3 var(--t-font);
  letter-spacing: 0;
  text-transform: none;
  color: var(--t-text);
}
.mh-quote td {
  margin-top: 0.3em;
  font-size: 0.72em;
  color: var(--t-text-secondary);
}
/* ── mh-preview end ── */

/* ---------- The class's questions (Matt's note of 2026-11-22; deck-tools/apply-asked-callouts-v1.py writes the beats,
   class "asked"): a one-line card that pops up last on each slide that answers a group of them, "N students asked"
   and the question. On a wide page it sits in the eyebrow's row, right-aligned: on every slide that row is the act
   kicker at the left and empty to the right (measured at 1280x720: the kicker at y 98-111, the title from y 131). The
   text column is positioned (engine.css .scene .text) or display: contents, so on a slide with a card it gives that
   up and the card takes the scene as its box. About Me's photo fills that row, so its card sits under the quote. On
   the phone reading page the card stays in the flow, after the slide's words. ---------- */
.scene .text:has(> .beat.asked) {
  position: static;
}
/* the act kicker is a full-width block; on a slide with a card it takes only its words' width, so its box ends where
   its text does and the card beside it overlaps nothing (nothing visible changes: it is left-aligned, with no rule) */
.scene .text:has(> .beat.asked) > .eyebrow-xl {
  width: fit-content;
}
.scene.scene-spine .text > .beat.asked.with-label {
  position: absolute;
  top: -1vh;
  right: 0;
  left: auto;
  grid-column: auto;
  grid-row: auto;
  z-index: 3;
  display: flex;
  align-items: baseline;
  gap: 0.75em;
  box-sizing: border-box;
  max-width: calc(100% - 26vw);
  margin: 0;
  padding: 0.34em 1em 0.4em 0.85em;
  border: 1px solid rgba(var(--t-accent-rgb), 0.6);
  border-radius: 999px;
  background:
    linear-gradient(
      90deg,
      rgba(var(--t-accent-rgb), 0.2),
      rgba(var(--t-accent-rgb), 0.08)
    ),
    rgba(14, 16, 18, 0.94);
  box-shadow:
    0 8px 22px rgba(0, 0, 0, 0.45),
    0 0 0 4px rgba(var(--t-accent-rgb), 0.08);
  white-space: nowrap;
  font: 500 clamp(12px, 1.2vw, 23px) / 1.25 var(--hb-font);
  color: var(--hb-text);
  text-align: left;
  transform-origin: 100% 50%;
}
.scene.scene-spine .text > .beat.asked .beat-label {
  display: inline;
  flex: none;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: none;
  font: 800 clamp(10px, 0.9vw, 17px) / 1.25 var(--hb-font);
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--t-accent);
}
.scene.scene-spine .text > .beat.asked .beat-text {
  overflow: hidden;
  text-overflow: ellipsis;
  font-style: italic;
}
.scene.scene-spine .text > .beat.asked .beat-text::before {
  content: "\201C";
}
.scene.scene-spine .text > .beat.asked .beat-text::after {
  content: "\201D";
}
/* About Me: the photo fills the kicker's row on the right, so the card sits under the slide's words, at the left */
.scene.scene-spine.layout-about .text > .beat.asked.with-label {
  top: calc(100% + 1.2vh);
  bottom: auto;
  right: auto;
  left: 0;
  max-width: 46vw;
  transform-origin: 0 50%;
}
/* the pop: a little scale with an overshoot, on top of the engine's build reveal */
.scene.scene-spine .text > .beat.asked[data-at] {
  transform: scale(0.86);
  transition:
    opacity 300ms var(--ease),
    transform 440ms cubic-bezier(0.2, 1.5, 0.45, 1);
}
.scene.scene-spine .text > .beat.asked[data-at].on {
  transform: none;
}
@media (prefers-reduced-motion: reduce) {
  .scene.scene-spine .text > .beat.asked[data-at] {
    transform: none;
    transition: opacity 200ms linear;
  }
}
@media (max-width: 760px) {
  html:not(.is-stage) .scene .text:has(> .beat.asked) {
    position: relative;
  }
  html:not(.is-stage) .scene.scene-spine .text > .beat.asked.with-label,
  html:not(.is-stage)
    .scene.scene-spine.layout-about
    .text
    > .beat.asked.with-label {
    position: static;
    display: block;
    max-width: none;
    margin-top: 16px;
    padding: 10px 14px 11px;
    border-radius: 14px;
    white-space: normal;
    font-size: 16px;
    transform: none;
  }
  html:not(.is-stage) .scene.scene-spine .text > .beat.asked .beat-label {
    display: block;
    margin-bottom: 4px;
    font-size: 12px;
  }
}

/* "What is Hapimatic?" (2026-11-22): three points under the definition, why Matt built it, what it does and what it
   is for, stacked in the right-hand columns. The layout's older rules lay six reasons out in two columns and style the
   second beat as a heading; .point takes the three lines out of both. */
@media (min-width: 761px) {
  .scene-spine.layout-platform .text > .beat.with-label.point {
    grid-column: 2 / 4;
    margin-top: calc(var(--u) * 1.5);
    padding-left: calc(var(--u) * 1.35);
    border-left: 2px solid rgba(var(--t-accent-rgb), 0.35);
    font: 500 calc(var(--u) * 1.2) / 1.42 var(--hb-font);
    color: var(--hb-text-secondary);
  }
  .scene-spine.layout-platform .text > .beat.with-label.point .beat-label {
    margin-bottom: 0.25em;
    font: 800 calc(var(--u) * 1.3) / 1.25 var(--hb-font);
    color: var(--hb-text);
  }
}

/* Slide 7 (Matt's note of 2026-11-22, deck-tools/apply-note-loop-by-hand-v1.py): a lead line before the three "you"
   steps and the point after them. Neither is a step a person did, so neither carries the red dot. */
.scene-spine.layout-ese-loop-ring .beat.ese-lead,
.scene-spine.layout-ese-loop-ring .beat.ese-goal {
  padding-left: 0;
}
.scene-spine.layout-ese-loop-ring .beat.ese-lead::before,
.scene-spine.layout-ese-loop-ring .beat.ese-goal::before {
  content: none;
}
.scene-spine.layout-ese-loop-ring .beat.ese-lead {
  margin-top: 1em;
  font-size: clamp(15px, 1.35vw, 26px);
  color: var(--hb-text-secondary);
}
.scene-spine.layout-ese-loop-ring .beat.ese-goal {
  margin-top: 1.1em;
  padding-top: 0.6em;
  border-top: 2px solid rgba(var(--t-accent-rgb), 0.5);
  font-size: clamp(16px, 1.45vw, 28px);
  font-weight: 700;
  color: var(--t-accent);
}

/* Slides 6 to 8 on the Drexel loop (Matt's note of 2026-11-22, deck-tools/apply-note-loop-assets-v1.py): the nexus
   layout's loop without the issue-workflow row. The engine's ring clock (data-ring="waiting") runs only on a nexus
   scene with that row, so here "Human in the loop" and the waiting callout come on with the slide (slide 8: until its
   loop closes at build 2, where the existing rules bring in "Human on the loop"). Their words keep the loop-ring look. */
.scene-spine.layout-nexus.is-current[data-scene-id="loop-by-hand"]
  .object-group.loopbox
  > :is(.object.inloop, .object.waits),
.scene-spine.layout-nexus.is-current[data-scene-id="loop-closed"]:not(
    [data-build="2"]
  )
  .object-group.loopbox
  > :is(.object.inloop, .object.waits) {
  opacity: 1;
  transition-delay: 900ms;
}
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  )
  .beat {
  position: relative;
  margin-top: 0.7em;
  padding-left: 1.2em;
  font-size: clamp(18px, 1.7vw, 33px);
  font-weight: 500;
  color: var(--t-text);
}
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  )
  .beat::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 0.5em;
  height: 0.5em;
  border-radius: 50%;
  background: var(--t-danger);
}
.scene-spine.layout-nexus[data-scene-id="loop-closed"] .beat.ese-end::before {
  background: var(--t-accent);
}
.scene-spine.layout-nexus[data-scene-id="loop-by-hand"]
  .beat:is(.ese-lead, .ese-goal) {
  padding-left: 0;
}
.scene-spine.layout-nexus[data-scene-id="loop-by-hand"]
  .beat:is(.ese-lead, .ese-goal)::before {
  content: none;
}
.scene-spine.layout-nexus[data-scene-id="loop-by-hand"] .beat.ese-lead {
  margin-top: 1em;
  font-size: clamp(15px, 1.35vw, 26px);
  color: var(--hb-text-secondary);
}
.scene-spine.layout-nexus[data-scene-id="loop-by-hand"] .beat.ese-goal {
  margin-top: 1.1em;
  padding-top: 0.6em;
  border-top: 2px solid rgba(var(--t-accent-rgb), 0.5);
  font-size: clamp(16px, 1.45vw, 28px);
  font-weight: 700;
  color: var(--t-accent);
}
/* the ese family's frame for these three slides (the nexus layout is built for slide 33's title-beside-loop form):
   the title across the top on one line, the words at the left, the loop at the right */
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-defined"],
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  ) {
  padding-top: 12vh;
  padding-bottom: 5vh;
}
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-defined"],
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  )
  .two {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  column-gap: 3vw;
  row-gap: 0;
  align-items: start;
}
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-defined"],
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  )
  .text {
  display: contents;
}
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-defined"],
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  )
  :is(.eyebrow-xl, .statement) {
  grid-column: 1 / -1;
}
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-defined"],
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  )
  :is(.sub, .beat) {
  grid-column: 1;
  max-width: none;
}
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-defined"],
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  )
  .statement {
  max-width: none;
  white-space: nowrap;
}
/* slides 6 and 8 keep their own smaller one-line sizes (the long-headline rules above); slide 7 takes the family's */
.scene-spine.layout-nexus[data-scene-id="loop-by-hand"] .statement {
  font-size: clamp(30px, 3.3vw, 62px);
}
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-defined"],
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  )
  .statement
  .sentence {
  display: inline;
}
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-defined"],
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  )
  .object-group.loopbox {
  grid-column: 2;
  grid-row: 3 / span 6;
  margin-top: 1vh;
}
/* slides 7 and 8 carry the waiting callout above the ring: the loop starts lower, so the callout clears the title */
.scene-spine.layout-nexus:is(
    [data-scene-id="loop-by-hand"],
    [data-scene-id="loop-closed"]
  )
  .object-group.loopbox {
  margin-top: 7vh;
}
.scene-spine.layout-nexus .object-group.loopbox > .object.loopimg {
  background: none;
  border: 0;
  padding: 0;
}
@media (max-width: 760px) {
  html:not(.is-stage)
    .scene-spine.layout-nexus:is(
      [data-scene-id="loop-defined"],
      [data-scene-id="loop-by-hand"],
      [data-scene-id="loop-closed"]
    )
    .two {
    display: block;
  }
  html:not(.is-stage)
    .scene-spine.layout-nexus:is(
      [data-scene-id="loop-defined"],
      [data-scene-id="loop-by-hand"],
      [data-scene-id="loop-closed"]
    )
    .object-group.loopbox {
    margin-top: 32px;
  }
}
/* the still twins (check L34 and the reading page), as slide 33 does for its stack */
@media (prefers-reduced-motion: reduce) {
  .scene-spine.layout-nexus[data-scene-id="loop-defined"] .object.loopimg img {
    content: url("assets/act5b/loop-closed-me-static.svg");
  }
  .scene-spine.layout-nexus[data-scene-id="loop-by-hand"] .object.loopimg img,
  .scene-spine.layout-nexus[data-scene-id="loop-closed"]
    .object-stack
    img.layer.base {
    content: url("assets/penn/lanea-nexus-me-in-loop-static.svg");
  }
}
@media (max-width: 760px) {
  html:not(.is-stage)
    .scene-spine.layout-nexus[data-scene-id="loop-defined"]
    .object.loopimg
    img {
    content: url("assets/act5b/loop-closed-me-static.svg");
  }
  html:not(.is-stage)
    .scene-spine.layout-nexus[data-scene-id="loop-by-hand"]
    .object.loopimg
    img,
  html:not(.is-stage)
    .scene-spine.layout-nexus[data-scene-id="loop-closed"]
    .object-stack
    img.layer.base {
    content: url("assets/penn/lanea-nexus-me-in-loop-static.svg");
  }
}

/* Cases 1 and 2, step by step (Matt's note of 2026-11-22, deck-tools/apply-note-cases-v1.py): eight rows in the dense
   table's spacing, at the largest size that keeps the slide on a 16:9 stage (1.75vw overflowed by 15 to 23 percent) */
.scene:is([data-scene-id="case1-walk"], [data-scene-id="case2-walk"])
  .ese-terms7
  table {
  font-size: clamp(14px, 1.42vw, 27px) !important;
}

/* Long titles that ran past the right margin at 1280x720 (Matt's note of 2026-11-22: Safari on his iPhone clipped the
   last letter of slide 23's title). Measured in Chromium at 1280x720 (docs/talks/2026-11-23-penn-ese5190/deck-tools/
   measure-titles-v1.py); each title now ends at least 48 px inside the content edge, room for Safari's wider text. */
.scene:is(
    [data-scene-id="p5-device"],
    [data-scene-id="p5-stage1"],
    [data-scene-id="step-loop"],
    [data-scene-id="ex1-device"],
    [data-scene-id="case2-walk"],
    [data-scene-id="request-path"],
    [data-scene-id="colleague-tool"],
    [data-scene-id="case1-walk"],
    [data-scene-id="tools-intro"]
  )
  .statement {
  font-size: clamp(26px, 2.95vw, 56.5px);
}
.scene:is([data-scene-id="ex2-device"], [data-scene-id="loop-target"])
  .statement {
  font-size: clamp(22px, 2.5vw, 48px);
}

/* The power budget (Matt's note of 2026-11-22, deck-tools/apply-note-budget-v1.py): stage 1's four cuts "off the
   table" in two columns while the room calls out ideas; at Matt's click the ten trade-offs take their place, in two
   columns, "Give something up" and "Give up nothing". The reading page shows both. */
.ese-off table,
:is(.ese-tradecol, .ese-tradefree) table {
  font-size: clamp(14px, 1.45vw, 28px) !important;
}
.ese-off th,
:is(.ese-tradecol, .ese-tradefree) th {
  margin-bottom: 0.5em;
  font: 700 0.62em/1.2 var(--t-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--t-accent);
}
.ese-off td {
  position: relative;
  padding-left: 1.3em;
  font-weight: 600;
  line-height: 1.3;
  color: var(--t-text-secondary);
}
.ese-off td::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--t-accent);
}
.ese-trade {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  column-gap: 2.2vw;
  align-items: start;
}
:is(.ese-tradecol, .ese-tradefree) td {
  margin-bottom: 0.32em;
  padding: 0.16em 0 0.16em 0.75em;
  border-left: 4px solid var(--t-accent-muted);
  font-weight: 600;
  line-height: 1.28;
  color: var(--t-text);
}
.ese-tradefree td {
  border-left-color: var(--t-accent);
}
html.is-stage .scene[data-scene-id="p5-budget"][data-build="1"] .ese-off {
  display: none;
}
html.is-stage
  .scene[data-scene-id="p5-budget"]:not([data-build="1"])
  .ese-trade {
  display: none;
}
@media (max-width: 760px) {
  .ese-trade {
    display: block;
  }
  .ese-off table,
  :is(.ese-tradecol, .ese-tradefree) table {
    font-size: 15px !important;
  }
  .ese-tradefree {
    margin-top: 14px;
  }
}

/* The results slide (Matt's note of 2026-11-22, deck-tools/apply-note-results-v1.py): the trade-off chosen from the
   budget slide's list, highlighted; the one not chosen and why; and what a further cut would cost. */
.scene[data-scene-id="p5-results"]
  .beat.with-label:is(.ese-chosen, .ese-notchosen, .ese-further) {
  display: block;
  margin-top: 0.75em;
  padding: 0.45em 0.8em 0.5em;
  border-left: 4px solid var(--t-accent-muted);
  border-radius: 0 10px 10px 0;
  font: 500 clamp(13px, 1.18vw, 22.5px) / 1.34 var(--t-font);
  color: var(--t-text-secondary);
}
.scene[data-scene-id="p5-results"]
  .beat.with-label:is(.ese-chosen, .ese-notchosen, .ese-further)
  .beat-label {
  display: block;
  margin: 0 0 0.2em;
  padding: 0;
  border: 0;
  background: none;
  font: 800 0.8em/1.2 var(--t-mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--t-text);
}
.scene[data-scene-id="p5-results"] .beat.ese-chosen {
  border-left-color: var(--t-accent);
  background: rgba(var(--t-accent-rgb), 0.12);
  color: var(--t-text);
}
.scene[data-scene-id="p5-results"] .beat.ese-chosen .beat-label {
  color: var(--t-accent);
}
.scene[data-scene-id="p5-results"] .beat.ese-notchosen {
  opacity: 0.85;
}
/* the Espressif line (build 1) moves under the chart, where the right column has room; the left column holds the cards */
@media (min-width: 761px) {
  .scene[data-scene-id="p5-results"] .text > .beat.ese-idea {
    grid-column: 2;
    align-self: start;
    margin-top: 1.2em;
    font-size: clamp(14px, 1.3vw, 25px);
  }
}

/* Before and now (Matt's note of 2026-11-22, deck-tools/apply-note-before-now-v1.py): the talks' motion graphics in
   place of the card rings. Left: the loop with me in it, the six hand steps under it. Right, at the click: me on top
   of three closed loops (the Drexel row, captions removed), this talk's three loops named under them. */
.ese-bn > .bn-before {
  grid-column: 1;
  grid-row: 2 / span 2;
  justify-self: stretch;
  margin-top: 2vh;
}
.ese-bn > .bn-steps {
  grid-column: 1;
  grid-row: 4;
  justify-self: stretch;
}
.ese-bn > .bn-now {
  grid-column: 2;
  grid-row: 3;
  justify-self: stretch;
}
.ese-bn :is(.bn-before, .bn-loops) {
  background: none;
  border: 0;
  padding: 0;
}
.ese-bn :is(.bn-before, .bn-loops) img {
  display: block;
  width: 100%;
  height: auto;
  max-height: none;
  border-radius: 0;
}
.bn-steps table,
.bn-caps table {
  font-size: clamp(12px, 1.1vw, 21px) !important;
}
.bn-steps tr,
.bn-steps th,
.bn-steps td {
  display: block;
  padding: 0;
  border: 0;
  text-align: center;
}
.bn-steps th {
  margin-bottom: 0.35em;
  font: 700 0.8em/1.2 var(--t-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--t-danger);
}
.bn-steps td {
  font-weight: 600;
  color: var(--t-text-secondary);
}
.bn-caps tr {
  display: flex;
}
.bn-caps :is(th, td) {
  display: block;
  flex: 1 1 0;
  letter-spacing: 0;
  text-transform: none;
  padding: 0.2em 0 0;
  border: 0;
  text-align: center;
  font: 700 1em/1.25 var(--t-font);
  color: var(--t-accent);
}
@media (prefers-reduced-motion: reduce) {
  .ese-bn .bn-before img {
    content: url("assets/penn/lanea-nexus-me-in-loop-static.svg");
  }
  .ese-bn .bn-loops img {
    content: url("assets/act6/loops-row-static.svg");
  }
}
@media (max-width: 760px) {
  html:not(.is-stage) .ese-bn .bn-before img {
    content: url("assets/penn/lanea-nexus-me-in-loop-static.svg");
  }
  html:not(.is-stage) .ese-bn .bn-loops img {
    content: url("assets/act6/loops-row-static.svg");
  }
}
/* the right column holds the loops, so the three places sit on one line here (the next slide, six jobs, opens them
   up in three columns) */
.scene[data-scene-id="before-now"] .ese-touch table {
  font-size: clamp(12px, 1.15vw, 22px) !important;
}
.scene[data-scene-id="before-now"] .ese-touch td {
  padding: 0.28em 0;
}
.scene[data-scene-id="before-now"] .ese-touch tr:not(:first-child) {
  display: inline;
}
.scene[data-scene-id="before-now"] .ese-touch td {
  display: inline;
  border: 0;
  padding: 0;
}
.scene[data-scene-id="before-now"]
  .ese-touch
  tr:not(:first-child)
  + tr
  td::before {
  content: " · ";
  color: var(--t-text-secondary);
}
.scene[data-scene-id="before-now"] .ese-touch table {
  text-align: center;
}
/* both graphics capped in height, so the bottom row (the six steps, the three places) stays on a 16:9 stage */
.ese-bn .bn-before img {
  max-height: 46vh;
  object-fit: contain;
}
.ese-bn .bn-loops img {
  max-height: 33vh;
  object-fit: contain;
}
.scene[data-scene-id="before-now"] .ese-bn {
  row-gap: 1.4vh;
}
.scene[data-scene-id="before-now"] :is(.ese-head-before, .ese-head-now) th {
  font-size: clamp(14px, 1.3vw, 25px);
}

/* ── six-jobs BEGIN (apply-note-six-jobs-v1.py; Matt's note n-mws90lj5-zbua) ── */
:is(.sj-p1, .sj-p2, .sj-p3, .sj-p4, .sj-p5, .sj-p6) {
  display: grid;
  row-gap: 1.3vh;
  align-content: start;
}
.sj-q tr,
.sj-q th,
.sj-q td,
.sj-b tr,
.sj-b th,
.sj-b td {
  display: block;
  border: 0;
  padding: 0;
  background: none;
}
.sj-q th {
  font: 700 clamp(11px, 0.95vw, 18px) / 1.2 var(--t-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--t-accent);
}
.sj-q td {
  margin-top: 0.4em;
  font-weight: 700;
  font-size: clamp(15px, 1.55vw, 30px);
  line-height: 1.25;
  color: var(--t-text);
}
.sj-shot img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: 29.5vh;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.scene-spine[class*="layout-ese-"] .object.sj-b table {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 1.6vw;
  row-gap: 1vh;
}
.sj-b tr:first-child {
  grid-column: 1 / -1;
}
.sj-b th {
  font: 600 clamp(11px, 0.9vw, 17px) / 1.3 var(--t-mono);
  text-transform: none;
  letter-spacing: 0;
  color: var(--t-text-secondary);
}
.sj-b td {
  padding-top: 0.55em;
  border-top: 2px solid rgba(var(--t-accent-rgb), 0.55);
  font-size: clamp(13px, 1.22vw, 23px);
  line-height: 1.3;
  color: var(--t-text);
}
html.is-stage
  .scene[data-scene-id="six-jobs"]
  :is(.sj-p1, .sj-p2, .sj-p3, .sj-p4, .sj-p5, .sj-p6) {
  display: none;
  grid-column: 2;
  grid-row: 1;
}
html.is-stage .scene[data-scene-id="six-jobs"]:not([data-build="0"]) .sj {
  display: grid;
  grid-template-columns: minmax(0, 35fr) minmax(0, 65fr);
  column-gap: 3vw;
  align-items: start;
}
html.is-stage
  .scene[data-scene-id="six-jobs"]:not([data-build="0"])
  .sj
  > .ese-three {
  grid-column: 1;
  grid-row: 1;
}
html.is-stage .scene[data-scene-id="six-jobs"][data-build="1"] .sj-p1,
html.is-stage .scene[data-scene-id="six-jobs"][data-build="2"] .sj-p2,
html.is-stage .scene[data-scene-id="six-jobs"][data-build="3"] .sj-p3,
html.is-stage .scene[data-scene-id="six-jobs"][data-build="4"] .sj-p4,
html.is-stage .scene[data-scene-id="six-jobs"][data-build="5"] .sj-p5,
html.is-stage .scene[data-scene-id="six-jobs"][data-build="6"] .sj-p6,
html.is-stage .scene[data-scene-id="six-jobs"][data-build="7"] .sj-p6 {
  display: grid;
}
html.is-stage
  .scene[data-scene-id="six-jobs"]:not([data-build="0"])
  .ese-three {
  grid-template-columns: minmax(0, 1fr);
  row-gap: 0.6vh;
}
html.is-stage
  .scene[data-scene-id="six-jobs"]:not([data-build="0"])
  .ese-three
  th {
  padding: 0.35em 0 0.05em;
}
html.is-stage
  .scene[data-scene-id="six-jobs"]:not([data-build="0"])
  .ese-three
  tr:nth-child(odd):not(:first-child) {
  display: none;
}
html.is-stage
  .scene[data-scene-id="six-jobs"]:not([data-build="0"])
  .ese-three
  tr:nth-child(even) {
  margin-top: 0.1em;
  padding: 0.25em 0.55em;
  border-radius: 6px;
  transform-origin: left center;
  transition:
    opacity 400ms var(--ease),
    background-color 400ms var(--ease),
    transform 400ms var(--ease);
}
html.is-stage
  .scene[data-scene-id="six-jobs"]:not([data-build="0"])
  .ese-three
  tr:nth-child(even)
  td:first-child {
  font-size: 1.25em;
}
html.is-stage
  .scene[data-scene-id="six-jobs"]:not([data-build="0"])
  .ese-three
  tr:nth-child(even)
  td:last-child {
  font-size: 0.9em;
}
html.is-stage
  .scene[data-scene-id="six-jobs"][data-build="1"]
  .ese-three
  > .object:nth-of-type(1)
  tr:nth-child(2),
html.is-stage
  .scene[data-scene-id="six-jobs"][data-build="2"]
  .ese-three
  > .object:nth-of-type(1)
  tr:nth-child(4),
html.is-stage
  .scene[data-scene-id="six-jobs"][data-build="3"]
  .ese-three
  > .object:nth-of-type(2)
  tr:nth-child(2),
html.is-stage
  .scene[data-scene-id="six-jobs"][data-build="4"]
  .ese-three
  > .object:nth-of-type(2)
  tr:nth-child(4),
html.is-stage
  .scene[data-scene-id="six-jobs"][data-build="5"]
  .ese-three
  > .object:nth-of-type(3)
  tr:nth-child(2),
html.is-stage
  .scene[data-scene-id="six-jobs"][data-build="6"]
  .ese-three
  > .object:nth-of-type(3)
  tr:nth-child(4),
html.is-stage
  .scene[data-scene-id="six-jobs"][data-build="7"]
  .ese-three
  > .object:nth-of-type(3)
  tr:nth-child(4) {
  background-color: rgba(var(--t-accent-rgb), 0.14);
  box-shadow: inset 3px 0 0 var(--t-accent);
  transform: scale(1.05);
}
html.is-stage
  .scene[data-scene-id="six-jobs"][data-build="7"]
  .ese-three
  tr:not(:first-child) {
  opacity: 0.3;
}
html.is-stage
  .scene[data-scene-id="six-jobs"][data-build="7"]
  .ese-three
  > .object:nth-of-type(3)
  tr:nth-child(4) {
  opacity: 1;
}
@media (prefers-reduced-motion: no-preference) {
  html.is-stage
    .scene[data-scene-id="six-jobs"]:not([data-build="0"])
    .ese-three {
    animation: sj-slide 700ms var(--ease) both;
  }
  html.is-stage
    .scene[data-scene-id="six-jobs"]
    :is(.sj-p1, .sj-p2, .sj-p3, .sj-p4, .sj-p5, .sj-p6) {
    animation: sj-in 450ms var(--ease) both;
  }
  html.is-stage .scene[data-scene-id="six-jobs"][data-build="1"] .sj-p1 {
    animation-delay: 420ms;
  }
}
@keyframes sj-slide {
  from {
    transform: translateX(34vw);
    opacity: 0.35;
  }
  to {
    transform: none;
    opacity: 1;
  }
}
@keyframes sj-in {
  from {
    transform: translateX(2.5vw);
    opacity: 0;
  }
  to {
    transform: none;
    opacity: 1;
  }
}
/* the reading page: the overview, then the six panels two by two (one column on a phone) */
html:not(.is-stage) .scene[data-scene-id="six-jobs"] .sj {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px 32px;
}
html:not(.is-stage) .scene[data-scene-id="six-jobs"] .sj > .ese-three {
  grid-column: 1 / -1;
}
html:not(.is-stage) .scene[data-scene-id="six-jobs"] .sj-b table {
  grid-template-columns: minmax(0, 1fr);
}
@media (max-width: 760px) {
  html:not(.is-stage) .scene[data-scene-id="six-jobs"] .sj {
    grid-template-columns: minmax(0, 1fr);
  }
}
/* ── six-jobs END ── */

/* ── tools-intro (Matt's note n-mws9g0ur-jkze, apply-note-structure-v1.py): the turn into the tools section, the two
   examples as pictures and the thirteen tools' five groups as chips ── */
.ti-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 0.6fr);
  column-gap: 2.4vw;
  align-items: start;
}
.ti-card {
  display: grid;
  row-gap: 1.4vh;
}
.ti-card img {
  display: block;
  width: 100%;
  height: 33vh;
  object-fit: cover;
  object-position: center top;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.scene[data-scene-id="tools-intro"] :is(.ti-card, .ti-more) :is(tr, th, td) {
  display: block;
  border: 0;
  padding: 0;
  background: none;
}
.scene[data-scene-id="tools-intro"] .ti-card th {
  font: 800 clamp(15px, 1.5vw, 29px) / 1.2 var(--t-font);
  letter-spacing: 0;
  text-transform: none;
  color: var(--t-text);
}
.scene[data-scene-id="tools-intro"] .ti-card td {
  margin-top: 0.35em;
  font-size: clamp(13px, 1.2vw, 23px);
  line-height: 1.3;
  color: var(--t-text-secondary);
}
.scene[data-scene-id="tools-intro"] .ti-more table {
  border-top: 3px solid var(--t-accent);
  padding-top: 0.8em;
}
.scene[data-scene-id="tools-intro"] .ti-more th {
  padding-bottom: 0.6em;
  font: 700 clamp(11px, 1vw, 19px) / 1.2 var(--t-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--t-accent);
}
.scene[data-scene-id="tools-intro"] .ti-more tr:not(:first-child) {
  margin-bottom: 0.9vh;
}
.scene[data-scene-id="tools-intro"] .ti-more td {
  display: inline-block;
  padding: 0.3em 0.9em;
  border: 1px solid rgba(var(--t-accent-rgb), 0.55);
  border-radius: 999px;
  font-weight: 700;
  font-size: clamp(13px, 1.25vw, 24px);
  color: var(--t-text);
}
@media (max-width: 760px) {
  .ti-row {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 24px;
  }
  .ti-card img {
    height: auto;
  }
}

/* ── reflection + firmware-rule BEGIN (apply-note-reflection-firmware-v1.py) ── */
.scene[data-scene-id="reflection"] .statement {
  font-size: clamp(26px, 2.95vw, 56.5px);
}
.rf {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  column-gap: 5vw;
  row-gap: 3.2vh;
  align-items: start;
}
.rf-verify {
  grid-column: 1 / -1;
}
.scene[data-scene-id="reflection"] .rf :is(tr, th, td),
.scene[data-scene-id="firmware-rule"] .fw :is(tr, th, td) {
  display: block;
  border: 0;
  padding: 0;
  background: none;
}
.scene[data-scene-id="reflection"] :is(.rf-from, .rf-to) th,
.scene[data-scene-id="firmware-rule"] :is(.fw-need, .fw-how, .fw-card) th {
  padding-bottom: 0.7em;
  font: 700 clamp(11px, 1vw, 19px) / 1.2 var(--t-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--t-accent);
}
.scene[data-scene-id="reflection"] .rf-from th {
  color: var(--t-text-secondary);
}
.scene[data-scene-id="reflection"] :is(.rf-from, .rf-to) tr:not(:first-child) {
  margin-top: 0.8vh;
  padding: 0.45em 0 0.45em 0.9em;
  border-left: 3px solid rgba(255, 255, 255, 0.18);
}
.scene[data-scene-id="reflection"] .rf-from td {
  font-size: clamp(15px, 1.55vw, 30px);
  line-height: 1.3;
  color: var(--t-text-secondary);
}
.scene[data-scene-id="reflection"] .rf-to {
  position: relative;
}
.scene[data-scene-id="reflection"] .rf-to::before {
  content: "→";
  position: absolute;
  left: -3.7vw;
  top: 42%;
  font: 800 2.6vw / 1 var(--t-font);
  color: var(--t-accent);
}
.scene[data-scene-id="reflection"] .rf-to tr:not(:first-child) {
  border-left-color: var(--t-accent);
  background: rgba(var(--t-accent-rgb), 0.07);
}
.scene[data-scene-id="reflection"] .rf-to td {
  font-weight: 700;
  font-size: clamp(15px, 1.55vw, 30px);
  line-height: 1.3;
  color: var(--t-text);
}
.scene[data-scene-id="reflection"] .rf-verify table {
  padding-top: 1.4vh;
  border-top: 3px solid var(--t-accent);
}
.scene[data-scene-id="reflection"] .rf-verify th {
  font-family: var(--t-font);
  font-weight: 800;
  font-size: clamp(18px, 2.05vw, 40px);
  line-height: 1.25;
  letter-spacing: 0;
  text-transform: none;
  color: var(--t-accent);
}
.scene[data-scene-id="reflection"] .rf-verify td {
  margin-top: 1vh;
  font-size: clamp(14px, 1.45vw, 28px);
  line-height: 1.35;
  color: var(--t-text);
}
.fw {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  column-gap: 4vw;
  row-gap: 3vh;
  align-items: start;
}
.scene[data-scene-id="firmware-rule"] .fw-need tr:not(:first-child) {
  display: grid;
  grid-template-columns: 1.6em 1fr;
  column-gap: 0.4em;
  align-items: baseline;
  margin-top: 1.8vh;
}
.scene[data-scene-id="firmware-rule"] .fw-need td:first-child {
  font: 800 clamp(22px, 2.3vw, 44px) / 1 var(--t-font);
  color: var(--t-accent);
}
.scene[data-scene-id="firmware-rule"] .fw-need td:last-child {
  font-weight: 700;
  font-size: clamp(16px, 1.75vw, 34px);
  line-height: 1.25;
  color: var(--t-text);
}
.scene[data-scene-id="firmware-rule"] :is(.fw-how, .fw-card) table {
  padding: 1.1em 1.2em;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
}
.scene[data-scene-id="firmware-rule"] .fw-card table {
  border-left: 3px solid var(--t-accent);
}
.scene[data-scene-id="firmware-rule"] :is(.fw-how, .fw-card) td {
  font-size: clamp(14px, 1.45vw, 28px);
  line-height: 1.35;
  color: var(--t-text);
}
.scene[data-scene-id="firmware-rule"] :is(.fw-how, .fw-card) td + td,
.scene[data-scene-id="firmware-rule"] .fw-how tr + tr {
  margin-top: 0.6em;
}
@media (max-width: 760px) {
  .rf,
  .fw {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 22px;
  }
  .scene[data-scene-id="reflection"] .rf-to::before {
    content: none;
  }
}
/* ── reflection + firmware-rule END ── */

/* ── mh-premium BEGIN (apply-note-mh-premium-v1.py; Matt's note n-mws93xlo-ocf6) ── */
.hx {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  column-gap: 3vw;
  align-items: center;
}
.hx-left {
  display: grid;
  row-gap: 1.8vh;
  align-content: start;
}
.hx-wm img {
  display: block;
  height: 5.6vh;
  width: auto;
}
.scene[data-scene-id="mh-premium"] .hx :is(tr, th, td) {
  border: 0;
  padding: 0;
  background: none;
}
.scene[data-scene-id="mh-premium"] .hx-tag th {
  display: block;
  font: 800 clamp(20px, 2.5vw, 48px) / 1.1 var(--t-font);
  letter-spacing: -0.01em;
  text-transform: none;
  color: var(--t-accent);
}
.scene[data-scene-id="mh-premium"] .hx-feat tr:first-child {
  display: none;
}
.scene[data-scene-id="mh-premium"] .hx-feat tr {
  display: grid;
  grid-template-columns: 1.2em minmax(0, 1fr);
  margin-top: 1.2vh;
}
.scene[data-scene-id="mh-premium"] .hx-feat tr::before {
  content: "";
  grid-row: 1 / span 2;
  width: 0.5em;
  height: 0.5em;
  margin-top: 0.45em;
  transform: rotate(45deg);
  background: var(--t-accent);
}
.scene[data-scene-id="mh-premium"] .hx-feat td {
  display: block;
  grid-column: 2;
}
.scene[data-scene-id="mh-premium"] .hx-feat td:first-child {
  font-weight: 800;
  font-size: clamp(15px, 1.5vw, 29px);
  line-height: 1.25;
  color: var(--t-text);
}
.scene[data-scene-id="mh-premium"] .hx-feat td:last-child {
  margin-top: 0.25em;
  font-size: clamp(12px, 1.12vw, 22px);
  line-height: 1.35;
  color: var(--t-text-secondary);
}
.scene[data-scene-id="mh-premium"] .hx-cta tr:last-child td:first-child {
  display: none;
}
.scene[data-scene-id="mh-premium"] .hx-cta tr:last-child td:last-child {
  display: block;
  margin-top: 0.2vh;
  font: 600 clamp(12px, 0.95vw, 19px) / 1.3 var(--t-mono);
  color: var(--t-text-secondary);
}
.scene[data-scene-id="mh-premium"] .hx-cta tr:first-child {
  display: flex;
  flex-wrap: wrap;
  gap: 1vw;
  margin-top: 1vh;
}
.scene[data-scene-id="mh-premium"] .hx-cta th {
  display: block;
  font-family: var(--t-font);
  letter-spacing: 0;
  text-transform: none;
  padding: 0.6em 1.1em;
  border-radius: 10px;
  font-weight: 700;
  font-size: clamp(12px, 1.1vw, 21px);
  line-height: 1.2;
}
.scene[data-scene-id="mh-premium"] .hx-cta th:first-child {
  background: var(--t-accent);
  color: #0f1f1a;
}
.scene[data-scene-id="mh-premium"] .hx-cta th:last-child {
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: var(--t-text);
}
.hx-shots {
  position: relative;
  padding: 0 2.6vw 5vh 0;
}
.hx-desk img {
  display: block;
  width: 100%;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 2vh 6vh rgba(0, 0, 0, 0.55);
}
.hx-shots .hx-phone {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 23%;
}
.hx-phone img {
  display: block;
  width: 100%;
  border-radius: 14px;
  border: 2px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 2vh 5vh rgba(0, 0, 0, 0.6);
}
@media (prefers-reduced-motion: reduce) {
  .scene img[src*="/assets/site/wordmark-bridge.svg"] {
    content: url("assets/site/wordmark-transmission.svg");
  }
}
html:not(.is-stage) .scene img[src*="/assets/site/wordmark-bridge.svg"] {
  content: url("assets/site/wordmark-transmission.svg");
}
@media (max-width: 760px) {
  .hx {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 28px;
  }
}
/* ── mh-premium END ── */

/* ── questions (Matt's note n-mwsaebnd-6lqf, apply-note-questions-v1.py): the students' nine in two columns, each with
   how many asked and the slide where the talk answered it ── */
.scene-spine.layout-kit-questions[data-scene-id="questions"] .qlist table {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(5, auto);
  grid-auto-flow: column;
  column-gap: 2.6vw;
}
.scene-spine.layout-kit-questions[data-scene-id="questions"] .qlist tr {
  padding: 0.45em 0;
}
.scene-spine.layout-kit-questions[data-scene-id="questions"]
  .qlist
  tr:nth-child(7) {
  border-top: 0;
}
.scene-spine.layout-kit-questions[data-scene-id="questions"]
  .qlist
  td:nth-child(2) {
  font-size: clamp(13px, 1.15vw, 24px);
}
.scene-spine.layout-kit-questions[data-scene-id="questions"]
  .qlist
  td:nth-child(3) {
  font: 600 clamp(12px, 0.95vw, 19px) / 1.3 var(--t-mono);
  color: var(--t-accent);
}
@media (max-width: 760px) {
  .scene-spine.layout-kit-questions[data-scene-id="questions"] .qlist table {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: none;
    grid-auto-flow: row;
  }
  .scene-spine.layout-kit-questions[data-scene-id="questions"]
    .qlist
    tr:nth-child(7) {
    border-top: 1px solid var(--t-line);
  }
}

/* ── round 2 (apply-round2-a-v1.py): slide 7's loop says "you" (its still twin too), and the request path lists what
   each of the agent's steps relies on, an icon from the five things before each ── */
@media (prefers-reduced-motion: reduce) {
  .scene-spine.layout-nexus[data-scene-id="loop-by-hand"] .object.loopimg img {
    content: url("assets/penn/lanea-nexus-you-in-loop-static.svg");
  }
}
html:not(.is-stage)
  .scene-spine.layout-nexus[data-scene-id="loop-by-hand"]
  .object.loopimg
  img {
  content: url("assets/penn/lanea-nexus-you-in-loop-static.svg");
}
/* slide 16 gained a row (print statements at checkpoints): a step smaller so all seven fit */
.scene[data-scene-id="step-power-comms"] .ese-terms table {
  font-size: clamp(12px, 1.2vw, 23px) !important;
}

/* ── request-path topics BEGIN (apply-round2-a-v1.py): each topic row draws its icon ── */
.ese-lanes [class*="ese-in"] tr:nth-child(n + 3) {
  display: flex;
  align-items: center;
  gap: 0.4em;
  margin-top: 0.3em;
}
.ese-lanes [class*="ese-in"] tr:nth-child(n + 3)::before {
  content: "";
  flex: 0 0 auto;
  width: 1.45em;
  height: 1.45em;
  background: center / contain no-repeat;
}
.ese-lanes [class*="ese-in"] tr:nth-child(n + 3) td {
  margin: 0;
  font: 600 0.78em / 1.2 var(--t-mono);
  color: var(--t-accent);
}
.ese-lanes [class*="ese-in"] tr:nth-child(3) {
  margin-top: 0.55em;
}
.ese-lanes > .object:nth-of-type(6) tr:nth-child(3)::before {
  background-image: url("assets/penn/lanea-discovery-static.svg");
}
.ese-lanes > .object:nth-of-type(6) tr:nth-child(4)::before {
  background-image: url("assets/penn/lanea-memory-static.svg");
}
.ese-lanes > .object:nth-of-type(7) tr:nth-child(3)::before {
  background-image: url("assets/penn/lanea-discovery-static.svg");
}
.ese-lanes > .object:nth-of-type(7) tr:nth-child(4)::before {
  background-image: url("assets/penn/lanea-knowledge-static.svg");
}
.ese-lanes > .object:nth-of-type(9) tr:nth-child(3)::before {
  background-image: url("assets/penn/lanea-access-static.svg");
}
.ese-lanes > .object:nth-of-type(9) tr:nth-child(4)::before {
  background-image: url("assets/penn/lanea-knowledge-static.svg");
}
.ese-lanes > .object:nth-of-type(9) tr:nth-child(5)::before {
  background-image: url("assets/penn/lanea-rules-static.svg");
}
.ese-lanes > .object:nth-of-type(10) tr:nth-child(3)::before {
  background-image: url("assets/penn/lanea-access-static.svg");
}
/* ── request-path topics END ── */

/* ── round 2 E BEGIN (apply-round2-e-v1.py): the PR timeline fills the stage below its title ── */
html.is-stage .scene[data-scene-id="pr-timeline"] .two > .object {
  margin-top: 1vh;
  text-align: center;
}
html.is-stage .scene[data-scene-id="pr-timeline"] .object img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: calc(100vh - 14.5vw - 7vh);
  margin: 0 auto;
}
.ese-bn > .bn-pre {
  grid-column: 1;
  grid-row: 2 / span 2;
  justify-self: stretch;
}
.ese-bn > .bn-gantt1 {
  grid-column: 1;
  grid-row: 4;
  justify-self: stretch;
}
.ese-bn > .bn-now {
  grid-column: 2;
  grid-row: 3;
}
.ese-bn > .bn-gantt8 {
  grid-column: 2;
  grid-row: 4;
  justify-self: stretch;
}
.ese-bn > .bn-quote {
  grid-column: 1 / -1;
  grid-row: 5;
  justify-self: stretch;
}
.scene[data-scene-id="before-now"]
  :is(.bn-pre, .bn-gantt1, .bn-gantt8, .bn-quote)
  :is(tr, th, td) {
  display: block;
  border: 0;
  padding: 0;
  background: none;
}
.scene[data-scene-id="before-now"] .bn-pre th,
.scene[data-scene-id="before-now"] :is(.bn-gantt1, .bn-gantt8) th {
  padding-bottom: 0.5em;
  font: 700 clamp(11px, 0.95vw, 18px) / 1.2 var(--t-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--t-text-secondary);
}
.scene[data-scene-id="before-now"] .bn-pre tr:not(:first-child) {
  display: grid;
  grid-template-columns: 1.5em minmax(0, 1fr);
  column-gap: 0.4em;
  align-items: baseline;
  margin-top: 0.9vh;
}
.scene[data-scene-id="before-now"] .bn-pre td:first-child {
  font: 800 clamp(16px, 1.6vw, 31px) / 1 var(--t-font);
  color: var(--t-danger);
}
.scene[data-scene-id="before-now"] .bn-pre td:last-child {
  font-weight: 700;
  font-size: clamp(14px, 1.35vw, 26px);
  line-height: 1.25;
  color: var(--t-text);
}
.scene[data-scene-id="before-now"] :is(.bn-gantt1, .bn-gantt8) td {
  display: grid;
  align-items: center;
  column-gap: 0.7em;
  font: 700 clamp(13px, 1.25vw, 24px) / 1.2 var(--t-font);
  color: var(--t-text);
}
.scene[data-scene-id="before-now"] .bn-gantt1 td {
  grid-template-columns: minmax(0, 1fr);
  row-gap: 0.4em;
}
.scene[data-scene-id="before-now"] .bn-gantt1 td::before {
  content: "";
  height: 1.3em;
  border-radius: 6px;
  background: rgba(var(--t-danger-rgb), 0.6);
}
.scene[data-scene-id="before-now"] .bn-gantt8 td {
  grid-template-columns: 12.5% minmax(0, 1fr);
}
.scene[data-scene-id="before-now"] .bn-gantt8 td::before {
  content: "";
  height: 3.7em;
  border-radius: 3px;
  background: repeating-linear-gradient(
    to bottom,
    var(--t-accent) 0 0.3em,
    transparent 0.3em 0.48em
  );
}
.scene[data-scene-id="before-now"] .ese-bn {
  row-gap: 1.6vh;
}
.scene[data-scene-id="before-now"] .bn-loops img {
  max-height: 20vh;
}
.scene[data-scene-id="before-now"] .bn-quote th {
  display: block;
  padding-top: 1vh;
  border-top: 1px solid var(--t-line-strong);
  font: 800 clamp(14px, 1.4vw, 27px) / 1.3 var(--t-font);
  letter-spacing: 0;
  text-transform: none;
  text-align: center;
  color: var(--t-accent);
}
@media (max-width: 760px) {
  .ese-bn > :is(.bn-pre, .bn-gantt1, .bn-gantt8, .bn-quote) {
    grid-column: 1;
    grid-row: auto;
  }
}
/* ── round 2 E END ── */

/* ── procedure-icons BEGIN (apply-note-procedure-icons-v2.py; Matt's notes on slide 13) ── */
.ese-flow {
  --ese-ico: calc(clamp(14px, 1.36vw, 26px) * 2.75);
}
.ese-flow > .object-group > .object-image.ese-ico {
  z-index: 1;
  overflow: visible;
  border-radius: 0;
  justify-self: end;
  align-self: start;
  width: var(--ese-ico);
  margin: 0.9em 1em 0 0;
  pointer-events: none;
}
.ese-flow > .object-group > .object-image.ese-ico img {
  display: block;
  width: 100%;
  height: auto;
  max-height: none;
  border-radius: 0;
}
@media (min-width: 761px) {
  .ese-flow > .object-group > .object-table {
    grid-row: 1;
  }
  .ese-flow > .object-group > .object-image.ese-ico {
    grid-row: 1;
  }
  .ese-flow > .object-group > :is(:nth-child(1), :nth-child(2)) {
    grid-column: 1;
  }
  .ese-flow > .object-group > :is(:nth-child(3), :nth-child(4)) {
    grid-column: 2;
  }
  .ese-flow > .object-group > :is(:nth-child(5), :nth-child(6)) {
    grid-column: 3;
  }
  .ese-flow > .object-group > :is(:nth-child(7), :nth-child(8)) {
    grid-column: 4;
  }
  .ese-flow th {
    width: fit-content;
    line-height: var(--ese-ico);
  }
}
@media (max-height: 820px) and (min-width: 761px) {
  .ese-flow {
    --ese-ico: calc(clamp(14px, 1.36vw, 26px) * 2.15);
    row-gap: 1.4vh;
  }
  .ese-flow .object-table {
    padding: 0.5em 0.75em 0.55em;
  }
  .ese-flow > .object-group > .object-image.ese-ico {
    margin: 0.5em 0.75em 0 0;
  }
  .ese-flow tr:nth-child(3) td {
    margin-top: 0.3em;
    font-size: 0.93em;
    line-height: 1.26;
  }
  .ese-flow > .ese-loop {
    padding-bottom: 0.7em;
  }
}
@media (max-width: 760px) {
  .ese-flow {
    --ese-ico: 38px;
  }
  .ese-flow > .object-group > * {
    grid-column: 1;
  }
  .ese-flow > .object-group > :is(:nth-child(1), :nth-child(2)) {
    grid-row: 1;
  }
  .ese-flow > .object-group > :is(:nth-child(3), :nth-child(4)) {
    grid-row: 2;
  }
  .ese-flow > .object-group > :is(:nth-child(5), :nth-child(6)) {
    grid-row: 3;
  }
  .ese-flow > .object-group > :is(:nth-child(7), :nth-child(8)) {
    grid-row: 4;
  }
  .ese-flow > .object-group > .object-image.ese-ico {
    align-self: center;
    margin: 0 0.7em 0 0;
  }
  .ese-flow .object-table {
    padding-right: calc(var(--ese-ico) + 1.3em);
  }
}
/* ── procedure-icons END ── */

/* ── round 2 G BEGIN (apply-round2-g-icons-v1.py): an icon per tool category and per job ── */
.scene[data-scene-id="tools"] .ese-cols5 th {
  display: flex;
  align-items: center;
  gap: 0.45em;
}
.scene[data-scene-id="tools"] .ese-cols5 th::before {
  content: "";
  flex: 0 0 auto;
  width: 1.55em;
  height: 1.55em;
  margin: -0.2em 0;
  background: center / contain no-repeat;
}
.scene[data-scene-id="tools-intro"] .ti-more tr:not(:first-child) td {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
}
.scene[data-scene-id="tools-intro"] .ti-more tr:not(:first-child) td::before {
  content: "";
  width: 1.35em;
  height: 1.35em;
  background: center / contain no-repeat;
}
.scene[data-scene-id="six-jobs"] .ese-three tr:nth-child(even) {
  grid-template-columns: 2.2em 1.5em minmax(0, 1fr);
  column-gap: 0.45em;
  align-items: center;
}
.scene[data-scene-id="six-jobs"] .ese-three tr:nth-child(even)::before {
  content: "";
  width: 2.2em;
  height: 2.2em;
  background: center / contain no-repeat;
}
.scene[data-scene-id="six-jobs"]
  .ese-three
  tr:nth-child(odd):not(:first-child) {
  padding-left: 2.65em;
}
html.is-stage
  .scene[data-scene-id="six-jobs"]:not([data-build="0"])
  .ese-three
  tr:nth-child(even) {
  grid-template-columns: 1.6em 1.3em minmax(0, 1fr);
  column-gap: 0.35em;
}
html.is-stage
  .scene[data-scene-id="six-jobs"]:not([data-build="0"])
  .ese-three
  tr:nth-child(even)::before {
  width: 1.6em;
  height: 1.6em;
}
.scene[data-scene-id="six-jobs"] [class*="sj-p"] .sj-q th {
  display: flex;
  align-items: center;
  gap: 0.5em;
}
.scene[data-scene-id="six-jobs"] [class*="sj-p"] .sj-q th::before {
  content: "";
  flex: 0 0 auto;
  width: 2em;
  height: 2em;
  background: center / contain no-repeat;
}
.scene[data-scene-id="tools"] .ese-cols5 > .object:nth-of-type(1) th::before {
  background-image: url("assets/icons/eye.svg");
}
.scene[data-scene-id="tools-intro"] .ti-more tr:nth-child(2) td::before {
  background-image: url("assets/icons/eye.svg");
}
.scene[data-scene-id="tools"] .ese-cols5 > .object:nth-of-type(2) th::before {
  background-image: url("assets/icons/presentation.svg");
}
.scene[data-scene-id="tools-intro"] .ti-more tr:nth-child(3) td::before {
  background-image: url("assets/icons/presentation.svg");
}
.scene[data-scene-id="tools"] .ese-cols5 > .object:nth-of-type(3) th::before {
  background-image: url("assets/icons/message-circle-question-mark.svg");
}
.scene[data-scene-id="tools-intro"] .ti-more tr:nth-child(4) td::before {
  background-image: url("assets/icons/message-circle-question-mark.svg");
}
.scene[data-scene-id="tools"] .ese-cols5 > .object:nth-of-type(4) th::before {
  background-image: url("assets/icons/shield-check.svg");
}
.scene[data-scene-id="tools-intro"] .ti-more tr:nth-child(5) td::before {
  background-image: url("assets/icons/shield-check.svg");
}
.scene[data-scene-id="tools"] .ese-cols5 > .object:nth-of-type(5) th::before {
  background-image: url("assets/icons/repeat.svg");
}
.scene[data-scene-id="tools-intro"] .ti-more tr:nth-child(6) td::before {
  background-image: url("assets/icons/repeat.svg");
}
.scene[data-scene-id="six-jobs"]
  .ese-three
  > .object:nth-of-type(1)
  tr:nth-child(2)::before {
  background-image: url("assets/icons/target.svg");
}
.scene[data-scene-id="six-jobs"] .sj-p1 .sj-q th::before {
  background-image: url("assets/icons/target.svg");
}
.scene[data-scene-id="six-jobs"]
  .ese-three
  > .object:nth-of-type(1)
  tr:nth-child(4)::before {
  background-image: url("assets/icons/clipboard-check.svg");
}
.scene[data-scene-id="six-jobs"] .sj-p2 .sj-q th::before {
  background-image: url("assets/icons/clipboard-check.svg");
}
.scene[data-scene-id="six-jobs"]
  .ese-three
  > .object:nth-of-type(2)
  tr:nth-child(2)::before {
  background-image: url("assets/icons/scale.svg");
}
.scene[data-scene-id="six-jobs"] .sj-p3 .sj-q th::before {
  background-image: url("assets/icons/scale.svg");
}
.scene[data-scene-id="six-jobs"]
  .ese-three
  > .object:nth-of-type(2)
  tr:nth-child(4)::before {
  background-image: url("assets/icons/scan-eye.svg");
}
.scene[data-scene-id="six-jobs"] .sj-p4 .sj-q th::before {
  background-image: url("assets/icons/scan-eye.svg");
}
.scene[data-scene-id="six-jobs"]
  .ese-three
  > .object:nth-of-type(3)
  tr:nth-child(2)::before {
  background-image: url("assets/icons/workflow.svg");
}
.scene[data-scene-id="six-jobs"] .sj-p5 .sj-q th::before {
  background-image: url("assets/icons/workflow.svg");
}
.scene[data-scene-id="six-jobs"]
  .ese-three
  > .object:nth-of-type(3)
  tr:nth-child(4)::before {
  background-image: url("assets/icons/book-open-check.svg");
}
.scene[data-scene-id="six-jobs"] .sj-p6 .sj-q th::before {
  background-image: url("assets/icons/book-open-check.svg");
}
/* ── round 2 G END ── */

/* ── round 2 H BEGIN (apply-round2-h-v1.py): the colleague's browser tool, large, with its five steps ── */
.scene[data-scene-id="colleague-tool"] .ct-grid {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  column-gap: 2.2vw;
  row-gap: 1.6vh;
  align-items: start;
}
.scene[data-scene-id="colleague-tool"] .ct-grid > .ct-hero {
  grid-column: 1;
  grid-row: 1;
}
.scene[data-scene-id="colleague-tool"] .ct-grid > :is(.ct-steps, .ct-proof) {
  grid-column: 2;
  grid-row: 1;
  align-self: start;
}
.scene[data-scene-id="colleague-tool"] .ct-grid > .ct-before {
  grid-column: 2;
  grid-row: 1;
  align-self: end;
}
.scene[data-scene-id="colleague-tool"] .ct-hero img {
  display: block;
  width: auto;
  height: min(calc(100vh - 19vw - 6.5vh), 34vw);
  max-width: none;
  max-height: none;
  border: 1px solid var(--t-line-strong);
  border-radius: 10px;
}
.scene[data-scene-id="colleague-tool"] .ct-before img {
  display: block;
  width: auto;
  max-width: 100%;
  height: 20vh;
  max-height: none;
  border-radius: 8px;
}
.scene[data-scene-id="colleague-tool"]
  :is(.ct-steps, .ct-proof)
  :is(table, tbody, tr, th, td) {
  display: block;
  border: 0;
  padding: 0;
  background: none;
}
.scene[data-scene-id="colleague-tool"] :is(.ct-steps, .ct-proof) th {
  padding-bottom: 0.6em;
  font: 700 clamp(11px, 0.95vw, 18px) / 1.2 var(--t-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--t-accent);
}
.scene[data-scene-id="colleague-tool"] .ct-steps tr:not(:first-child) {
  display: grid;
  grid-template-columns: 1.7em minmax(0, 1fr);
  column-gap: 0.55em;
  align-items: start;
  margin-bottom: 2.3vh;
}
.scene[data-scene-id="colleague-tool"] .ct-steps td:first-child {
  grid-row: 1 / span 2;
  display: grid;
  place-items: center;
  width: 1.7em;
  height: 1.7em;
  border-radius: 50%;
  background: #3ecf8e;
  font: 800 clamp(13px, 1.2vw, 23px) / 1 var(--t-font);
  color: #0b1f17;
}
.scene[data-scene-id="colleague-tool"] .ct-steps td:nth-child(2) {
  font: 800 clamp(15px, 1.6vw, 31px) / 1.2 var(--t-font);
  color: var(--t-text);
}
.scene[data-scene-id="colleague-tool"] .ct-steps td:nth-child(3) {
  font: 500 clamp(13px, 1.25vw, 24px) / 1.3 var(--t-font);
  color: var(--t-text-secondary);
}
.scene[data-scene-id="colleague-tool"] .ct-proof tr:not(:first-child) {
  display: grid;
  grid-template-columns: 4.6em minmax(0, 1fr);
  column-gap: 0.6em;
  align-items: baseline;
  margin-bottom: 2vh;
}
.scene[data-scene-id="colleague-tool"] .ct-proof td:first-child {
  font: 800 clamp(20px, 2.3vw, 44px) / 1 var(--t-font);
  color: var(--t-accent);
  white-space: nowrap;
}
.scene[data-scene-id="colleague-tool"] .ct-proof td:last-child {
  font: 600 clamp(14px, 1.35vw, 26px) / 1.3 var(--t-font);
  color: var(--t-text);
}
html.is-stage .scene[data-scene-id="colleague-tool"][data-build="1"] .ct-steps {
  visibility: hidden;
}
@media (max-width: 760px) {
  .scene[data-scene-id="colleague-tool"] .ct-grid {
    display: block;
  }
  .scene[data-scene-id="colleague-tool"] .ct-grid > * + * {
    margin-top: 16px;
  }
  .scene[data-scene-id="colleague-tool"] :is(.ct-hero, .ct-before) img {
    width: 100%;
    height: auto;
  }
}
/* ── round 2 H END ── */

/* ── phone overflow BEGIN (apply-fix-phone-overflow-v1.py): one-line stage titles wrap on a phone ── */
@media (max-width: 760px) {
  html:not(.is-stage)
    .scene-spine.layout-nexus:is(
      [data-scene-id="loop-defined"],
      [data-scene-id="loop-by-hand"],
      [data-scene-id="loop-closed"]
    )
    .statement {
    white-space: normal;
  }
  html:not(.is-stage) .statement .keep {
    white-space: normal;
  }
}
/* ── phone overflow END ── */

/* ── round 2 I BEGIN (apply-round2-i-v1.py): what this class covers, in captures of its own slides ── */
.scene[data-scene-id="class-covers"] .cc-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 2.2vw;
  align-items: start;
}
.scene[data-scene-id="class-covers"] .cc-col {
  display: grid;
  row-gap: 1.6vh;
  align-content: start;
}
.scene[data-scene-id="class-covers"] .cc-col :is(table, tbody, tr, th, td) {
  display: block;
  border: 0;
  padding: 0;
  background: none;
}
.scene[data-scene-id="class-covers"] .cc-col tr {
  display: grid;
  grid-template-columns: 1.15em minmax(0, 1fr);
  column-gap: 0.4em;
  align-items: start;
  height: 3em;
  padding-bottom: 0.6vh;
  border-bottom: 2px solid var(--t-accent-muted);
  font-size: clamp(16px, 1.65vw, 32px);
}
.scene[data-scene-id="class-covers"] .cc-col :is(th, td):first-child {
  font: 800 1.5em / 0.85 var(--t-font);
  color: var(--t-accent);
}
.scene[data-scene-id="class-covers"] .cc-col :is(th, td):last-child {
  font: 800 1em / 1.25 var(--t-font);
  letter-spacing: 0;
  text-transform: none;
  text-align: left;
  color: var(--t-text);
}
.scene[data-scene-id="class-covers"] .cc-col img {
  display: block;
  width: 100%;
  height: auto;
  max-height: none;
  aspect-ratio: 16 / 9;
  border: 1px solid var(--t-line-strong);
  border-radius: 8px;
  box-shadow: 0 0.6vh 2vh rgba(0, 0, 0, 0.45);
}
@media (max-width: 760px) {
  .scene[data-scene-id="class-covers"] .cc-grid {
    display: block;
  }
  .scene[data-scene-id="class-covers"] .cc-col {
    grid-template-columns: 1fr 1fr;
    column-gap: 10px;
    row-gap: 10px;
  }
  .scene[data-scene-id="class-covers"] .cc-col > .object-table {
    grid-column: 1 / -1;
  }
  .scene[data-scene-id="class-covers"] .cc-col + .cc-col {
    margin-top: 22px;
  }
}
/* ── round 2 I END ── */

/* ── round 2 D BEGIN (apply-round2-d-v1.py): the participation band, the group timer, the two cases ── */
/* The participation band (Matt's notes n-mwsl4smi-j5lj, n-mwslb8ek-b3ir): a beat of class pb (a student with a
   hand raised) or pb-groups (three students, and a countdown) across the bottom of the stage. The text column and its
   row give up their position on such a slide, so the band takes the scene as its box (none of these slides places
   anything against them). The countdown's length is PB_SECS in this tool. */
@property --pb-t {
  syntax: "<integer>";
  inherits: false;
  initial-value: 180;
}
@property --pb-m {
  syntax: "<integer>";
  inherits: false;
  initial-value: 3;
}
@property --pb-s {
  syntax: "<integer>";
  inherits: false;
  initial-value: 0;
}
.scene-spine {
  --pb-h: 10.5vh;
}
html.is-stage
  .scene-spine
  .two:has(> .text > .beat:is(.pb, .pb-groups, .pb-out)),
html.is-stage .scene-spine .text:has(> .beat:is(.pb, .pb-groups, .pb-out)) {
  position: static;
}
html.is-stage .scene-spine .text > .beat:is(.pb, .pb-groups, .pb-out) {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  top: auto;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 1.15vw;
  box-sizing: border-box;
  width: auto;
  max-width: none;
  height: var(--pb-h);
  margin: 0;
  padding: 0 5vw;
  border: 0;
  border-top: 2px solid rgba(var(--t-accent-rgb), 0.85);
  border-radius: 0;
  background:
    linear-gradient(
      90deg,
      rgba(var(--t-accent-rgb), 0.3),
      rgba(var(--t-accent-rgb), 0.1) 55%,
      rgba(var(--t-accent-rgb), 0.05)
    ),
    rgba(16, 18, 20, 0.97);
  box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.45);
  font: 600 1.75vw / 1.2 var(--hb-font);
  color: var(--hb-text);
  text-align: left;
  opacity: 1;
  transform: none;
  grid-column: auto;
  grid-row: auto;
}
html.is-stage .scene-spine .text > .beat:is(.pb, .pb-groups, .pb-out)::before {
  content: none;
}
html.is-stage
  .scene-spine
  .text
  > .beat:is(.pb, .pb-groups, .pb-out)
  .beat-icon {
  flex: none;
  width: auto;
  height: 6.8vh;
  margin: 0;
}
html.is-stage
  .scene-spine
  .text
  > .beat:is(.pb, .pb-groups, .pb-out)
  .beat-label {
  flex: none;
  margin: 0;
  padding: 0.5em 0.85em 0.48em;
  border: 1.5px solid rgba(var(--t-accent-rgb), 0.75);
  border-radius: 999px;
  background: rgba(var(--t-accent-rgb), 0.14);
  font: 800 1.2vw / 1 var(--hb-font);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--t-accent);
}
html.is-stage
  .scene-spine
  .text
  > .beat:is(.pb, .pb-groups, .pb-out)
  .beat-text {
  font: inherit;
  color: inherit;
  white-space: nowrap;
}
/* the countdown: m:ss from the registered integer --pb-t (m rounds (t - 30) / 60 to the nearest whole minute) */
.beat.pb-groups {
  --pb-t: 180;
  --pb-m: calc((var(--pb-t) - 30) / 60);
  --pb-s: calc(var(--pb-t) - var(--pb-m) * 60);
  counter-reset: pb-m var(--pb-m) pb-s var(--pb-s);
}
html.is-stage .scene-spine .text > .beat.pb-groups::after {
  content: counter(pb-m) ":" counter(pb-s, decimal-leading-zero);
  margin-left: auto;
  min-width: 3.4ch;
  padding: 0.06em 0.32em 0.1em;
  border: 2px solid rgba(var(--t-accent-rgb), 0.7);
  border-radius: 0.22em;
  background: rgba(0, 0, 0, 0.38);
  font: 800 4.4vw / 1 var(--hb-font);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  text-align: center;
  color: var(--hb-text);
}
/* "We're out of time": over the band from the scene's top, so its ::before can flash the whole slide */
html.is-stage .scene-spine .text > .beat.pb-out {
  top: 0;
  z-index: 5;
  align-items: flex-end;
  height: auto;
  padding: 0 calc(5vw + 13vw) 0 calc(5vw + 6.8vh * 1.1 + 1.15vw);
  border: 0;
  background: none;
  box-shadow: none;
  opacity: 0;
  pointer-events: none;
}
html.is-stage .scene-spine .text > .beat.pb-out .beat-text {
  display: flex;
  align-items: center;
  height: var(--pb-h);
  font: 800 2.5vw / 1 var(--hb-font);
  letter-spacing: 0.01em;
}
html.is-stage .scene-spine .text > .beat.pb-out::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(var(--t-accent-rgb), 0.42);
  opacity: 0;
}
/* Matt's Next click (build 1) starts it, on the current slide only: leaving the slide or going back a build resets
   it to 3:00. At 0:00 the band turns red, its words give way to "We're out of time", and the slide flashes mint three
   times (one a second). No sound. Each animation is a 3600 s cycle on repeat: the count, then the end state held. */
html.is-stage .scene.is-current[data-build="1"] .text > .beat.pb-groups {
  animation:
    pb-count 3600s linear infinite,
    pb-red 3600s step-end infinite;
}
html.is-stage
  .scene.is-current[data-build="1"]
  .text
  > .beat.pb-groups
  :is(.beat-label, .beat-text) {
  animation: pb-hide 3600s step-end infinite;
}
html.is-stage
  .scene.is-current[data-build="1"]
  .text
  > .beat.pb-groups
  .beat-icon {
  animation: pb-white 3600s step-end infinite;
}
html.is-stage .scene.is-current[data-build="1"] .text > .beat.pb-groups::after {
  animation: pb-timer-end 3600s step-end infinite;
}
html.is-stage .scene.is-current[data-build="1"] .text > .beat.pb-out {
  animation: pb-show 3600s step-end infinite;
}
html.is-stage .scene.is-current[data-build="1"] .text > .beat.pb-out::before {
  animation: pb-flash 3600s ease-in-out infinite;
}
@keyframes pb-count {
  0% {
    --pb-t: 180;
    animation-timing-function: steps(180, end);
  }
  5%,
  100% {
    --pb-t: 0;
  }
}
@keyframes pb-red {
  0% {
    border-top-color: rgba(var(--t-accent-rgb), 0.85);
    background:
      linear-gradient(
        90deg,
        rgba(var(--t-accent-rgb), 0.3),
        rgba(var(--t-accent-rgb), 0.1) 55%,
        rgba(var(--t-accent-rgb), 0.05)
      ),
      rgba(16, 18, 20, 0.97);
  }
  5%,
  100% {
    border-top-color: #fecaca;
    background:
      linear-gradient(90deg, rgba(220, 38, 38, 0.97), rgba(185, 28, 28, 0.95)),
      rgba(16, 18, 20, 0.97);
  }
}
@keyframes pb-hide {
  0% {
    opacity: 1;
  }
  5%,
  100% {
    opacity: 0;
  }
}
@keyframes pb-show {
  0% {
    opacity: 0;
  }
  5%,
  100% {
    opacity: 1;
  }
}
@keyframes pb-white {
  0% {
    filter: none;
  }
  5%,
  100% {
    filter: brightness(0) invert(1);
  }
}
@keyframes pb-timer-end {
  0% {
    border-color: rgba(var(--t-accent-rgb), 0.7);
    background: rgba(0, 0, 0, 0.38);
  }
  5%,
  100% {
    border-color: rgba(255, 255, 255, 0.85);
    background: rgba(0, 0, 0, 0.25);
  }
}
@keyframes pb-flash {
  5% {
    opacity: 0;
  }
  5.0125% {
    opacity: 1;
  }
  5.0278% {
    opacity: 0;
  }
  5.0403% {
    opacity: 1;
  }
  5.0556% {
    opacity: 0;
  }
  5.0681% {
    opacity: 1;
  }
  5.0833% {
    opacity: 0;
  }
  100% {
    opacity: 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  html.is-stage .scene.is-current[data-build="1"] .text > .beat.pb-out::before {
    animation: none;
  }
}
/* the reading page: the band is a card after the slide's words; the countdown and its end state are stage-only */
html:not(.is-stage) .text > .beat:is(.pb, .pb-groups, .pb-out) {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 22px;
  padding: 10px 14px;
  border: 1px solid rgba(var(--t-accent-rgb), 0.55);
  border-radius: 14px;
  background: rgba(var(--t-accent-rgb), 0.1);
  font-weight: 600;
}
html:not(.is-stage) .text > .beat:is(.pb, .pb-groups, .pb-out)::before {
  content: none;
}
html:not(.is-stage) .text > .beat:is(.pb, .pb-groups, .pb-out) .beat-icon {
  width: 34px;
  height: 34px;
  margin: 0;
}
html:not(.is-stage) .text > .beat:is(.pb, .pb-groups, .pb-out) .beat-label {
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--t-accent);
}
html:not(.is-stage) .text > .beat.pb-out {
  display: none;
}

/* the slides above the band: each keeps its content clear of it (measured at 1280x720 and 1920x1080) */
html.is-stage .scene[data-scene-id="loop-by-hand"] .object-group.loopbox {
  width: 86%;
  margin-left: auto;
  margin-top: 3vh;
}
html.is-stage .scene[data-scene-id="loop-by-hand"] .sub {
  font-size: 1.65vw;
}
html.is-stage
  .scene[data-scene-id="loop-by-hand"]
  .text
  > .beat:is(.ese-lead, .ese-dot, .ese-goal) {
  margin-top: 1.25vh;
}
/* p5-budget: the room calls out its ideas at build 0; at build 1 the list fills the slide and the band steps aside */
html.is-stage .scene[data-scene-id="p5-budget"] .text > .beat.pb {
  transition:
    opacity 400ms var(--ease),
    transform 400ms var(--ease);
}
html.is-stage
  .scene[data-scene-id="p5-budget"]:not([data-build="0"])
  .text
  > .beat.pb {
  opacity: 0;
  transform: translateY(100%);
}
html.is-stage
  .scene:is([data-scene-id="case1-groups"], [data-scene-id="case2-groups"])
  .ese-terms
  td,
html.is-stage
  .scene:is([data-scene-id="case1-groups"], [data-scene-id="case2-groups"])
  .ese-terms
  th {
  padding-top: 0.42em;
  padding-bottom: 0.42em;
}

/* Case 1 and Case 2, the facts (n-mwslcvps-f2g4, n-mwslgcw5-9ypq): the parts and the measurement at the left, the
   graph at the right, all above the band */
html.is-stage .object-group:is(.r2-ex1, .r2-ex2) {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  grid-template-rows: auto 1fr;
  column-gap: 3vw;
  row-gap: 2.2vh;
  align-items: start;
}
html.is-stage .object-group:is(.r2-ex1, .r2-ex2) > .object-svg {
  grid-column: 2;
  grid-row: 1 / 3;
  margin: 0;
}
/* the table's caption and the graph's share one line: both figures end on the grid's last line */
html.is-stage
  .object-group:is(.r2-ex1, .r2-ex2)
  > :is(.object-table, .object-svg) {
  align-self: end;
}
html.is-stage .object-group:is(.r2-ex1, .r2-ex2) > .object-table {
  grid-column: 1;
  grid-row: 2;
}
html.is-stage .object-group:is(.r2-ex1, .r2-ex2) > .object-svg img {
  display: block;
  width: 100%;
  height: auto;
  max-height: calc(100vh - var(--pb-h) - 39vh);
  object-fit: contain;
  object-position: left top;
}
html.is-stage .object-group:is(.r2-ex1, .r2-ex2) > .object-svg .credit {
  margin-top: 0.8vh;
}
html.is-stage .object-group.r2-ex1 .ese-tiles,
html.is-stage .object-group.r2-ex2 .ese-tiles3 {
  gap: 0.8vw;
}
html.is-stage .object-group.r2-ex1 .ese-tiles {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
html.is-stage
  .object-group:is(.r2-ex1, .r2-ex2)
  :is(.ese-tiles, .ese-tiles3)
  .object-table {
  padding: 0.55vh 0.3vw 0.75vh;
  border-radius: 12px !important;
}
html.is-stage
  .object-group:is(.r2-ex1, .r2-ex2)
  :is(.ese-tiles, .ese-tiles3)
  table {
  font-size: 1.05vw !important;
}
html.is-stage
  .object-group:is(.r2-ex1, .r2-ex2)
  :is(.ese-tiles, .ese-tiles3)
  th {
  font-size: 2.1em;
}
html.is-stage
  .object-group:is(.r2-ex1, .r2-ex2)
  :is(.ese-tiles, .ese-tiles3)
  td {
  min-height: 0;
  padding-top: 0.25em;
  font-size: 1em;
}
html.is-stage .object-group.r2-ex1 .ese-keyed table {
  font-size: 1.32vw !important;
}
html.is-stage .object-group.r2-ex2 .ese-meas2 table {
  font-size: 1.2vw !important;
}
html.is-stage .object-group.r2-ex2 .ese-meas2 td:nth-child(3) {
  font-size: 0.82em;
}
html.is-stage
  .object-group:is(.r2-ex1, .r2-ex2)
  :is(.ese-keyed, .ese-meas2)
  :is(th, td) {
  padding-top: 0.5em;
  padding-bottom: 0.5em;
}
html.is-stage
  .scene:is([data-scene-id="ex1-device"], [data-scene-id="ex2-device"])
  .sub {
  margin-bottom: 0;
}

/* The answer to each case (n-mwsleerh-kx2k, n-mwslhfo4-zabd): the kicker names it, and the answer sits in a mint
   card with a check mark, so it reads as the end point of the case and not as one more title */
.scene:is([data-scene-id="ex1-answer"], [data-scene-id="ex2-cause"])
  .eyebrow-xl {
  font-size: 1.25em;
  color: var(--t-accent);
}
.scene:is([data-scene-id="ex1-answer"], [data-scene-id="ex2-cause"])
  .statement {
  position: relative;
  white-space: normal;
  text-wrap: balance;
  font-size: clamp(26px, 2.9vw, 55.5px);
  box-sizing: border-box;
  width: fit-content;
  max-width: 100%;
  padding: 0.38em 0.75em 0.44em 2.35em;
  border: 2px solid rgba(var(--t-accent-rgb), 0.9);
  border-radius: 0.45em;
  background:
    linear-gradient(
      90deg,
      rgba(var(--t-accent-rgb), 0.24),
      rgba(var(--t-accent-rgb), 0.07)
    ),
    rgba(14, 16, 18, 0.6);
  box-shadow:
    0 0 0 0.16em rgba(var(--t-accent-rgb), 0.1),
    0 12px 30px rgba(0, 0, 0, 0.4);
  color: var(--hb-text);
}
.scene:is([data-scene-id="ex1-answer"], [data-scene-id="ex2-cause"])
  .statement::before {
  content: "";
  position: absolute;
  left: 0.6em;
  top: 50%;
  width: 1.3em;
  height: 1.3em;
  transform: translateY(-50%);
  background: url("assets/act4/r2/answer-check.svg") center / contain no-repeat;
}
/* two balanced lines: the card hugs them (a wrapped box does not shrink to its lines by itself); the figure sits a
   little closer under it, so the slide stays inside 720 px */
.scene[data-scene-id="ex2-cause"] .statement {
  max-width: min(100%, 24em);
}
html.is-stage .scene[data-scene-id="ex2-cause"] .two > .object {
  margin-top: 1.2vh;
}
html.is-stage .scene[data-scene-id="ex1-answer"] .ese-strip {
  height: 14vh;
}
html.is-stage .scene[data-scene-id="ex1-answer"] .ese-ex3 {
  row-gap: 1.8vh;
}
html.is-stage .scene[data-scene-id="ex1-answer"] .ese-keyed :is(th, td) {
  padding-top: 0.4em;
  padding-bottom: 0.4em;
}
html.is-stage .scene[data-scene-id="ex1-answer"] .two > .object {
  margin-top: 2.2vh;
}
/* ── round 2 D END ── */

/* ── video 2 title BEGIN (apply-video2-title-v1.py): the Part 5 title size, as video 1 ── */
.scene[data-scene-id="p5-video-2"] .statement {
  font-size: clamp(24px, 2.6vw, 50px);
}
/* ── video 2 title END ── */
