/* Chompy homepage: one day at Juniper.
   The page runs from early morning to midnight. Each chapter paints its slice of the sky, so
   the day turns continuously without script. Brand colors come from the Chompy mark: navy
   outline, teal body, and ticket yellow. Supporting pages keep home.css. */

@font-face {
  font-family: Archivo;
  src: url("/fonts/archivo-variable-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-stretch: 62% 125%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: Figtree;
  src: url("/fonts/figtree-latin.woff2") format("woff2");
  font-weight: 300 900;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: light;
  --ink: #003649;
  --ink-soft: #3d5f6b;
  --teal: #37bfc2;
  --teal-deep: #137d82;
  --ticket: #f5da36;
  --paper: #fffdf6;
  --night: #052c3d;
  --midnight: #021b26;

  /* The sky, in the order the day passes. */
  --sky-dawn: #cfe9e5;
  --sky-morning: #e5f4f1;
  --sky-bright: #f4faf7;
  --sky-warm: #fbf3d6;
  --sky-golden: #f6dc8a;
  --sky-sage: #b5d2a8;
  --sky-dusk: #3f8f92;
  --sky-evening: #0e4456;

  --display: Archivo, "Arial Narrow", sans-serif;
  --text: Figtree, Arial, sans-serif;
  --gutter: clamp(20px, 5vw, 80px);
  --header-height: 76px;
  --sticker: 6px 6px 0 var(--ink);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 8px);
  background: var(--midnight);
}
/* The root background fills the gap when a trackpad or touch scroll bounces past either end.
   home.js marks the upper half of the page so the top bounce shows dawn sky above the hero, while
   the bottom bounce keeps midnight below the footer. */
html.overscroll-dawn {
  background: var(--sky-dawn);
}
body {
  margin: 0;
  color: var(--ink);
  background: var(--sky-dawn);
  font-family: var(--text);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1,
h2,
h3,
h4,
p,
dl,
dd,
ol {
  margin: 0;
}
ol {
  padding: 0;
  list-style: none;
}
a {
  color: inherit;
  text-decoration: none;
}
button {
  font: inherit;
  color: inherit;
  border: 0;
  background: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
svg {
  display: block;
}
[hidden] {
  display: none !important;
}
::selection {
  background: var(--ticket);
  color: var(--ink);
}
:focus-visible {
  outline: 3px solid var(--teal-deep);
  outline-offset: 4px;
  border-radius: 6px;
}
[data-theme="dark"] :focus-visible,
.footer :focus-visible {
  outline-color: var(--ticket);
}
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip {
  position: fixed;
  top: -100px;
  left: 20px;
  z-index: 50;
  padding: 12px 16px;
  border-radius: 10px;
  background: var(--paper);
  font-weight: 700;
}
.skip:focus {
  top: 12px;
}
.container {
  width: min(1280px, 100% - var(--gutter) * 2);
  margin-inline: auto;
}
.sprite {
  position: absolute;
}

/* ---------- Header and the day clock ---------- */

.day-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 30;
  height: var(--header-height);
  color: var(--ink);
  transition:
    color 300ms ease,
    background-color 300ms ease,
    box-shadow 300ms ease;
}
.day-header.is-scrolled {
  background: color-mix(in srgb, var(--header-tint, var(--sky-morning)) 78%, transparent);
  backdrop-filter: blur(14px) saturate(1.4);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  box-shadow: 0 1px 0 rgb(0 54 73 / 0.08);
}
.day-header.is-dark {
  color: #fff;
  --header-tint: var(--night);
}
.day-header.is-dark.is-scrolled {
  box-shadow: 0 1px 0 rgb(255 255 255 / 0.08);
}
.day-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  height: 100%;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo-mark {
  width: 40px;
  height: 43px;
}
.logo-word {
  width: 120px;
  height: 26px;
}
.day-clock {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-left: auto;
  padding: 8px 14px 8px 16px;
  border: 1.5px solid currentColor;
  border-radius: 999px;
  font-family: var(--display);
  font-stretch: 75%;
  font-weight: 650;
  font-size: 15px;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.day-clock-time {
  min-width: 4.6em;
  text-align: right;
}
.day-clock-track {
  position: relative;
  width: 72px;
  height: 2px;
  border-radius: 2px;
  background: color-mix(in srgb, currentColor 25%, transparent);
}
.day-clock-sun {
  position: absolute;
  top: 50%;
  left: calc(var(--day, 0.1) * 100%);
  width: 12px;
  height: 12px;
  margin: -6px 0 0 -6px;
  border-radius: 50%;
  background: var(--ticket);
  box-shadow:
    0 0 0 1.5px var(--ink),
    0 0 12px rgb(245 218 54 / 0.8);
  transition: background-color 400ms ease;
}
.day-header.is-dark .day-clock-sun {
  background: #f8f1cf;
  box-shadow:
    0 0 0 1.5px #f8f1cf,
    0 0 14px rgb(248 241 207 / 0.6);
}
.day-nav-signin {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 18px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
}
.day-header.is-dark .day-nav-signin {
  background: #fff;
  color: var(--ink);
}

/* ---------- Chapters ---------- */

.chapter {
  position: relative;
  padding-block: clamp(72px, 8vw, 120px);
}
.chapter-dawn {
  background: linear-gradient(180deg, var(--sky-dawn), var(--sky-morning));
}
.chapter-morning {
  background: linear-gradient(180deg, var(--sky-morning), var(--sky-bright));
}
.chapter-midday {
  background: linear-gradient(180deg, var(--sky-bright), var(--sky-warm));
}
.chapter-afternoon {
  background: linear-gradient(180deg, var(--sky-warm), var(--sky-golden));
}
.chapter-dusk {
  background: linear-gradient(
    180deg,
    var(--sky-golden) 0%,
    var(--sky-sage) 30%,
    var(--sky-dusk) 64%,
    var(--sky-evening) 100%
  );
}
.chapter-night {
  background: linear-gradient(180deg, var(--sky-evening), var(--night));
  color: #fff;
}
.chapter-midnight {
  background: linear-gradient(180deg, var(--night), var(--midnight));
  color: #fff;
}

.chapter-time {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 14px;
  margin-bottom: 22px;
}
.chapter-time time {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--display);
  font-stretch: 70%;
  font-weight: 700;
  font-size: clamp(22px, 2.2vw, 28px);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.005em;
  line-height: 1;
}
.chapter-time time::before {
  content: "";
  width: 0.5em;
  height: 0.5em;
  border-radius: 50%;
  background: var(--ticket);
  box-shadow: 0 0 0 2px var(--ink);
  transform: translateY(-0.04em);
}
[data-theme="dark"] .chapter-time time::before {
  background: #f8f1cf;
  box-shadow: 0 0 0 2px #f8f1cf, 0 0 14px rgb(248 241 207 / 0.7);
}
.chapter-time span {
  font-size: 15px;
  color: var(--ink-soft);
}
[data-theme="dark"] .chapter-time span {
  color: rgb(255 255 255 / 0.68);
}

.chapter h2 {
  font-family: var(--display);
  font-weight: 800;
  font-stretch: 108%;
  font-size: clamp(44px, 6.2vw, 92px);
  line-height: 0.94;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
.chapter-head h2 {
  max-width: 12ch;
}
.chapter-head {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  align-items: end;
  gap: 24px 64px;
  margin-bottom: clamp(40px, 5vw, 64px);
}
.chapter-head > p,
.ask-copy > p,
.team-copy > p {
  max-width: 34ch;
  font-size: 19px;
  line-height: 1.55;
  color: var(--ink-soft);
}
[data-theme="dark"] .chapter-head > p {
  color: rgb(255 255 255 / 0.74);
}
.section-takeaway {
  margin-top: 44px;
  font-family: var(--display);
  font-stretch: 100%;
  font-weight: 600;
  font-size: clamp(20px, 2vw, 26px);
  letter-spacing: -0.015em;
  text-align: center;
  text-wrap: balance;
}

.cta {
  display: inline-flex;
  align-items: center;
  min-height: 56px;
  padding: 0 28px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--ticket);
  color: var(--ink);
  font-weight: 800;
  font-size: 17px;
  box-shadow: 4px 4px 0 var(--ink);
  transition:
    transform 160ms var(--ease-out),
    box-shadow 160ms var(--ease-out);
}
.cta:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--ink);
}
.cta:active {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 var(--ink);
}

/* ---------- Hero: 7:30 AM ---------- */

.hero {
  min-height: 100svh;
  padding-top: calc(var(--header-height) + clamp(28px, 5vw, 72px));
  padding-bottom: clamp(36px, 5vw, 64px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: clamp(40px, 6vw, 80px);
}
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
  align-items: center;
  gap: clamp(32px, 4vw, 64px);
}
.hero-copy {
  container-type: inline-size;
  position: relative;
  z-index: 2;
}
.hero h1 {
  font-family: var(--display);
  font-weight: 850;
  font-stretch: 92%;
  /* Sized to the copy column so the longest rotating phrase stays on one line. */
  font-size: clamp(44px, 11.6cqi, 116px);
  line-height: 0.9;
  letter-spacing: -0.04em;
}
.hero-title-main {
  display: block;
}
.hero-rotator {
  display: grid;
  overflow: hidden;
  margin: 0 -0.08em;
  color: var(--teal-deep);
}
.hero-rotator-line {
  grid-area: 1 / 1;
  padding: 0.04em 0.08em 0.1em;
  visibility: hidden;
  white-space: nowrap;
}
.hero-rotator-line.is-active,
.hero-rotator-line.is-leaving {
  visibility: visible;
}
.hero-rotator-word {
  display: inline-block;
  vertical-align: top;
  clip-path: inset(-0.12em -0.12em -0.2em);
}
.hero-rotator-word-text {
  display: inline-block;
  transform: translateY(120%);
}
.is-active .hero-rotator-word-text {
  transform: translateY(0);
}
.is-entering .hero-rotator-word-text {
  animation: word-enter 560ms cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: calc(160ms + var(--word-index) * 50ms);
}
.is-leaving .hero-rotator-word-text {
  animation: word-leave 280ms cubic-bezier(0.5, 0, 0.75, 0) both;
}
@keyframes word-enter {
  from {
    opacity: 0;
    transform: translateY(110%);
  }
}
/* The leaving line has dropped .is-active, so its resting transform is below the line again. Start
   explicitly from the shown position so the words continue upward instead of jumping back first. */
@keyframes word-leave {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(-110%);
  }
}
.hero-hospitality {
  margin-top: clamp(20px, 2.4vw, 32px);
  font-size: clamp(19px, 1.7vw, 23px);
  color: var(--ink-soft);
}
.hero-copy .cta {
  margin-top: 32px;
}

.hero-stage {
  position: relative;
  padding-top: 88px;
  isolation: isolate;
}
.hero-sun {
  position: absolute;
  z-index: -2;
  top: -40px;
  right: -12%;
  width: min(520px, 46vw);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, #fbe766 0 52%, #f8e47a 53% 60%, rgb(248 228 122 / 0) 70%);
  animation: sun-rise 1400ms var(--ease-out) both;
}
@keyframes sun-rise {
  from {
    transform: translateY(46%);
    opacity: 0.4;
  }
}
/* Chompy peeks up from behind the card and speaks to the right. The host has no z-index, so the
   card (z-index 1) covers Chompy's lower half while the bubble (z-index 2) sits above the card. */
.hero-host {
  position: absolute;
  top: 0;
  left: 28px;
  display: flex;
  align-items: flex-start;
  gap: 6px;
}
.hero-mascot {
  flex: none;
  width: 118px;
  height: 127px;
  margin-top: -16px;
  /* Give Chompy its own GPU layer up front. Creating it and painting the detailed SVG when the peek
     starts made the first frames choppy on iPhone. */
  will-change: transform;
  animation: peek 700ms 400ms var(--ease-out) both;
}
@keyframes peek {
  from {
    transform: translateY(70%);
  }
}
.hero-speech {
  position: relative;
  z-index: 2;
  margin-top: 6px;
  padding: 10px 16px 11px;
  border: 2px solid var(--ink);
  border-radius: 16px 16px 16px 4px;
  background: var(--paper);
  font-family: var(--display);
  font-stretch: 100%;
  font-weight: 800;
  font-size: 17px;
  line-height: 1.2;
  box-shadow: 3px 3px 0 var(--ink);
  transform: rotate(2deg);
  animation: speech-in 420ms 1000ms var(--ease-out) both;
}
.hero-speech span {
  display: block;
  color: var(--teal-deep);
}
@keyframes speech-in {
  from {
    opacity: 0;
    transform: rotate(2deg) translateY(8px) scale(0.92);
  }
}

.morning-card {
  position: relative;
  border: 2px solid var(--ink);
  border-radius: 22px;
  background: var(--paper);
  box-shadow: var(--sticker);
  overflow: hidden;
  z-index: 1;
}
.morning-card-bar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 22px;
  border-bottom: 1.5px solid rgb(0 54 73 / 0.12);
  font-size: 13px;
  color: var(--ink-soft);
}
.morning-card-bar strong {
  color: var(--ink);
  margin-right: 4px;
}
.morning-card-body {
  padding: 22px 22px 22px;
}
.morning-kicker {
  font-size: 13px;
  font-weight: 700;
  color: var(--teal-deep);
}
.morning-headline {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-top: 8px;
}
.morning-headline h2 {
  font-family: var(--display);
  font-stretch: 100%;
  font-weight: 750;
  font-size: clamp(22px, 2vw, 27px);
  line-height: 1.08;
  letter-spacing: -0.025em;
}
.morning-lift {
  text-align: right;
  flex: none;
}
.morning-lift strong {
  display: block;
  font-family: var(--display);
  font-stretch: 88%;
  font-weight: 800;
  font-size: clamp(40px, 4vw, 54px);
  line-height: 0.9;
  letter-spacing: -0.04em;
  color: #11845c;
}
.morning-lift strong span {
  font-size: 0.55em;
  margin-left: 0.04em;
}
.morning-lift > span {
  font-size: 12px;
  color: var(--ink-soft);
}
.morning-bars {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}
.morning-bar {
  display: grid;
  grid-template-columns: 1fr auto;
  row-gap: 6px;
  font-size: 13px;
}
.morning-bar span {
  color: var(--ink-soft);
}
.morning-bar strong {
  font-variant-numeric: tabular-nums;
}
.morning-bar i {
  grid-column: 1 / -1;
  height: 8px;
  border-radius: 8px;
  background: rgb(0 54 73 / 0.08);
  position: relative;
  overflow: hidden;
}
.morning-bar i::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--bar);
  border-radius: inherit;
  background: var(--ink);
}
.morning-bar.is-baseline i::after {
  background: rgb(0 54 73 / 0.28);
}
.morning-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-top: 18px;
  border-block: 1.5px solid rgb(0 54 73 / 0.1);
}
.morning-metrics > div {
  padding: 12px 0;
}
.morning-metrics > div + div {
  padding-left: 18px;
  border-left: 1.5px solid rgb(0 54 73 / 0.1);
}
.morning-metrics dt {
  font-size: 12px;
  color: var(--ink-soft);
}
.morning-metrics dd {
  font-family: var(--display);
  font-stretch: 90%;
  font-weight: 750;
  font-size: 24px;
  letter-spacing: -0.02em;
}
.morning-metrics dd.is-up {
  color: #11845c;
}
.morning-explanation {
  margin-top: 14px;
  font-size: 14px;
}
.morning-outlook {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: end;
  gap: 2px 16px;
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--sky-morning);
}
.morning-outlook span {
  font-size: 12px;
  color: var(--ink-soft);
}
.morning-outlook strong {
  grid-row: 2;
  font-family: var(--display);
  font-stretch: 90%;
  font-weight: 800;
  font-size: 28px;
  letter-spacing: -0.03em;
  line-height: 1;
}
.morning-outlook p {
  grid-row: 1 / 3;
  grid-column: 2;
  font-size: 12px;
  color: var(--ink-soft);
}
.hero-stage .sample-label {
  margin-top: 16px;
  font-size: 13px;
  text-align: right;
  color: var(--ink-soft);
}

/* The day's chapters, spaced by when they happen. */
.day-index ol {
  position: relative;
  height: 76px;
  margin-inline: 6px;
}
.day-index ol::before {
  content: "";
  position: absolute;
  top: 6px;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(
    90deg,
    var(--sky-golden) 0%,
    var(--ticket) 50%,
    var(--sky-dusk) 75%,
    var(--night) 100%
  );
  border-radius: 2px;
}
.day-index li {
  position: absolute;
  top: 0;
  left: var(--at);
}
.day-index li:nth-child(1) {
  --at: 0%;
}
.day-index li:nth-child(2) {
  --at: 17.1%;
}
.day-index li:nth-child(3) {
  --at: 54.3%;
}
.day-index li:nth-child(4) {
  --at: 74%;
}
.day-index li:nth-child(5) {
  --at: 100%;
}
.day-index a {
  position: relative;
  display: grid;
  gap: 2px;
  padding: 24px 6px 6px 0;
  margin-left: -7px;
  white-space: nowrap;
}
.day-index li:last-child a {
  margin-left: 0;
  transform: translateX(-100%);
  text-align: right;
  padding-right: 0;
}
.day-index a::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--paper);
  border: 2px solid var(--ink);
  transition:
    background-color 160ms ease,
    transform 160ms var(--ease-out);
}
.day-index li:last-child a::before {
  left: auto;
  right: -7px;
  background: var(--night);
}
.day-index a:hover::before {
  background: var(--ticket);
  transform: scale(1.25);
}
.day-index time {
  font-family: var(--display);
  font-stretch: 72%;
  font-weight: 700;
  font-size: 17px;
  font-variant-numeric: tabular-nums;
}
.day-index span {
  font-size: 14px;
  color: var(--ink-soft);
}
.day-index a:hover span {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------- Product panels ---------- */

.app-panel {
  --app-muted: #566b75;
  --app-line: #e1e7e9;
  --app-blue: #0b77ad;
  border: 2px solid var(--ink);
  border-radius: 24px;
  background: var(--paper);
  box-shadow: 8px 8px 0 var(--ink);
  overflow: hidden;
  color: #1f3a4c;
}
.app-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 54px;
  padding: 0 24px;
  border-bottom: 1.5px solid var(--app-line);
  background: #f7f9f7;
}
.app-top strong {
  font-family: var(--display);
  font-stretch: 100%;
  font-weight: 750;
  font-size: 17px;
  color: var(--ink);
}
.demo-tag {
  font-size: 12px;
  color: var(--app-muted);
}
.today-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}
.today-half {
  padding: 30px 32px 34px;
}
.today-half + .today-half {
  border-left: 1.5px solid var(--app-line);
}
.app-heading-row {
  font-family: var(--display);
  font-stretch: 100%;
  font-weight: 700;
  font-size: 18px;
  color: var(--ink);
}
.app-top strong,
.app-heading-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.app-top .glyph,
.app-heading-row .glyph {
  flex: none;
  width: 0.95em;
  height: 0.95em;
  color: var(--teal-deep);
}
.app-sub {
  margin-top: 2px;
  font-size: 13px;
  color: var(--app-muted);
}
.sales-value {
  margin-top: 20px;
  font-family: var(--display);
  font-stretch: 88%;
  font-weight: 800;
  font-size: clamp(40px, 4vw, 54px);
  line-height: 1;
  letter-spacing: -0.035em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.ops-label {
  display: block;
  margin-top: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--app-muted);
}
.delta {
  margin-top: 8px;
  font-size: 14px;
  font-weight: 650;
}
.positive {
  color: #11845c;
}
.sample-context {
  margin-top: 4px;
  font-size: 12px;
  color: var(--app-muted);
}
.service-narrative {
  margin-top: 22px;
  padding: 16px 18px;
  border-radius: 14px;
  background: var(--sky-morning);
}
.service-narrative strong {
  display: block;
  font-size: 15px;
  color: var(--ink);
}
.service-narrative p {
  margin-top: 4px;
  font-size: 14px;
}
.briefing-facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 22px;
}
.briefing-facts .ops-label {
  margin: 0 0 4px;
  font-size: 12px;
}
.briefing-facts strong {
  font-family: var(--display);
  font-stretch: 90%;
  font-weight: 750;
  font-size: 26px;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.app-insight {
  margin-top: 22px;
  padding-left: 16px;
  border-left: 3px solid var(--teal);
}
.app-insight strong {
  font-size: 15px;
  color: var(--ink);
}
.app-insight p {
  margin-top: 4px;
  font-size: 14px;
}
.forecast-body {
  margin-top: 20px;
  padding-left: 18px;
  border-left: 3px solid var(--ticket);
}
.forecast-body .ops-label {
  margin: 0;
}
.forecast-body .sales-value {
  margin-top: 6px;
}
.forecast-body p {
  margin-top: 8px;
  max-width: 36ch;
  font-size: 14px;
}
.planning-range {
  margin-top: 28px;
}
.estimate-track {
  position: relative;
  height: 10px;
  margin-top: 12px;
  border-radius: 10px;
  background: repeating-linear-gradient(90deg, rgb(0 54 73 / 0.08) 0 2px, transparent 2px 10px);
}
.estimate-track i {
  position: absolute;
  inset: 0 14% 0 6%;
  border-radius: inherit;
  background: linear-gradient(90deg, rgb(55 191 194 / 0.4), var(--teal), rgb(55 191 194 / 0.4));
}
.estimate-track i::after {
  content: "";
  position: absolute;
  top: -5px;
  left: 50%;
  width: 4px;
  height: 20px;
  margin-left: -2px;
  border-radius: 2px;
  background: var(--ink);
}
.estimate-bounds {
  display: flex;
  justify-content: space-between;
  margin-top: 8px;
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.day .seasonal-pattern {
  margin-top: 26px;
  padding-top: 22px;
  border-top: 1.5px solid var(--app-line);
}
.day .seasonal-pattern h4 {
  font-family: var(--display);
  font-stretch: 100%;
  font-weight: 700;
  font-size: 15px;
  color: var(--ink);
}
.day .seasonal-pattern p {
  font-size: 14px;
  line-height: 1.6;
  color: #1f3a4c;
}
.day .pattern-comparison strong {
  font-family: var(--display);
  font-stretch: 90%;
  font-weight: 750;
  font-size: 24px;
  color: var(--ink);
}
.day .pattern-comparison span {
  font-size: 12px;
}
.day .pattern-comparison i {
  height: 6px;
  background: rgb(55 191 194 / 0.45);
}
.day .pattern-comparison div + div i {
  background: var(--teal-deep);
}

/* ---------- Ask Chompy: 10:30 AM ---------- */

.ask-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
  align-items: start;
  gap: clamp(36px, 6vw, 96px);
}
.ask-copy > p {
  margin-top: 22px;
}
.question-list {
  display: grid;
  gap: 10px;
  margin-top: 32px;
  max-width: 440px;
}
.question {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 56px;
  padding: 12px 20px 12px 48px;
  border: 2px solid rgb(0 54 73 / 0.22);
  border-radius: 16px;
  background: rgb(255 253 246 / 0.6);
  font-weight: 650;
  font-size: 16px;
  text-align: left;
  transition:
    border-color 160ms ease,
    background-color 160ms ease,
    box-shadow 160ms var(--ease-out),
    transform 160ms var(--ease-out);
}
.question::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 50%;
  width: 14px;
  height: 14px;
  margin-top: -7px;
  border-radius: 50%;
  border: 2px solid rgb(0 54 73 / 0.35);
  transition:
    background-color 160ms ease,
    border-color 160ms ease;
}
.question:hover {
  border-color: var(--ink);
}
.question[aria-pressed="true"] {
  border-color: var(--ink);
  background: var(--paper);
  box-shadow: 4px 4px 0 var(--ink);
  transform: translate(-2px, -2px);
}
.question[aria-pressed="true"]::before {
  border-color: var(--ink);
  background: var(--ticket);
}
/* Phones show the short label as a chip; see the 640px breakpoint. */
.question-short,
.team-choice-short {
  display: none;
}

.ask-printer {
  position: relative;
  max-width: 520px;
  justify-self: center;
  width: 100%;
}
.printer-head {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 12px;
  height: 74px;
  padding: 0 22px 10px;
  border-radius: 22px 22px 14px 14px;
  background: linear-gradient(180deg, #0c4a60, var(--ink) 70%);
  color: #fff;
  box-shadow:
    inset 0 1.5px 0 rgb(255 255 255 / 0.16),
    0 14px 30px -14px rgb(0 54 73 / 0.6);
}
.printer-mark {
  width: 34px;
  height: 37px;
  filter: drop-shadow(0 0 0 #fff);
}
.printer-name {
  font-family: var(--display);
  font-stretch: 100%;
  font-weight: 800;
  font-size: 17px;
}
.printer-light {
  width: 9px;
  height: 9px;
  margin-left: auto;
  border-radius: 50%;
  background: var(--teal);
  box-shadow: 0 0 10px var(--teal);
}
.ask-printer.is-printing .printer-light {
  animation: blink 260ms steps(2) infinite;
}
@keyframes blink {
  50% {
    background: #0c4a60;
    box-shadow: none;
  }
}
.printer-slot {
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 9px;
  height: 6px;
  border-radius: 6px;
  background: #001a24;
  box-shadow: inset 0 2px 3px rgb(0 0 0 / 0.6);
}
.ticket-feed {
  position: relative;
  z-index: 1;
  margin: -14px 34px 0;
  padding: 0 14px 24px;
  overflow: hidden;
}
.ticket {
  --edge: 10px;
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 30px 26px calc(26px + var(--edge));
  background: #fffef9;
  color: #1c2f38;
  font-size: 15px;
  box-shadow: 0 18px 28px -18px rgb(0 54 73 / 0.5);
  /* Torn edge along the bottom. */
  -webkit-mask:
    linear-gradient(#000 0 0) top / 100% calc(100% - var(--edge)) no-repeat,
    conic-gradient(from -45deg at 50% 100%, #000 90deg, #0000 0) bottom / calc(var(--edge) * 2) var(--edge) repeat-x;
  mask:
    linear-gradient(#000 0 0) top / 100% calc(100% - var(--edge)) no-repeat,
    conic-gradient(from -45deg at 50% 100%, #000 90deg, #0000 0) bottom / calc(var(--edge) * 2) var(--edge) repeat-x;
}
.ticket.is-feeding {
  animation: feed 900ms steps(18, end) both;
}
@keyframes feed {
  from {
    transform: translateY(-100%);
  }
}
/* A torn-off copy of the previous answer, dropped by home.js. It sits above the feed but below the
   printer head, and is not clipped by the feed, so it can fall out of view. */
.ticket-torn {
  position: absolute;
  z-index: 1;
  margin: 0;
  pointer-events: none;
  transform-origin: 50% 0;
}
.ticket-top {
  display: flex;
  justify-content: space-between;
  padding-bottom: 12px;
  border-bottom: 2px dashed rgb(28 47 56 / 0.3);
  font-family: var(--display);
  font-stretch: 70%;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: 0.02em;
}
.ticket-question {
  margin-top: 16px;
  padding: 12px 14px;
  border-radius: 10px;
  background: #eef6f5;
  font-weight: 700;
  font-size: 16px;
}
.ticket-question::before {
  content: "Q";
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  margin-right: 10px;
  border-radius: 6px;
  background: var(--ink);
  color: #fff;
  font-family: var(--display);
  font-size: 12px;
  vertical-align: 1px;
}
.ticket-answer {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 14px;
  margin-top: 18px;
}
/* home.js sizes the ticket for its longest answer; shorter answers keep the footnote at the bottom. */
.ticket-answer > .evidence {
  margin-top: auto;
}
.answer-lead {
  font-family: var(--display);
  font-stretch: 100%;
  font-size: 22px;
  line-height: 1.15;
  letter-spacing: -0.02em;
}
.answer-lead strong {
  font-weight: 800;
}
.quick-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-block: 2px dashed rgb(28 47 56 / 0.22);
}
.quick-metrics > div {
  display: grid;
  padding: 12px 0;
}
.quick-metrics > div + div {
  padding-left: 16px;
  border-left: 2px dashed rgb(28 47 56 / 0.22);
}
.quick-metrics strong {
  font-family: var(--display);
  font-stretch: 85%;
  font-weight: 800;
  font-size: 32px;
  line-height: 1.05;
  letter-spacing: -0.03em;
}
.quick-metrics span {
  font-size: 13px;
  color: #4e646e;
}
.quick-note {
  display: grid;
  gap: 2px;
  padding: 12px 14px;
  border-left: 4px solid var(--ticket);
  background: #fdf8dc;
  border-radius: 0 10px 10px 0;
}
.quick-note strong {
  font-size: 15px;
}
.quick-note span {
  font-size: 14px;
}
.quick-window {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
}
.quick-window strong {
  font-family: var(--display);
  font-stretch: 80%;
  font-weight: 800;
  font-size: 26px;
}
.overtime-person {
  display: flex;
  align-items: center;
  gap: 12px;
}
.person-initials {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--teal);
  border: 2px solid var(--ink);
  font-weight: 800;
  font-size: 14px;
}
.overtime-person > div {
  display: grid;
}
.overtime-person > div > span {
  font-size: 13px;
  color: #4e646e;
}
.evidence {
  padding-top: 12px;
  border-top: 2px dashed rgb(28 47 56 / 0.22);
  font-family: var(--display);
  font-stretch: 75%;
  font-weight: 550;
  font-size: 13px;
  color: #4e646e;
}

/* ---------- Team: 3:45 PM ---------- */

.day .team-section {
  background: linear-gradient(180deg, var(--sky-warm), var(--sky-golden));
}
.day .team-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(36px, 6vw, 96px);
  align-items: center;
}
.day .team-copy {
  max-width: 560px;
}
.day .team-copy h2 {
  font-family: var(--display);
  font-weight: 800;
  font-stretch: 108%;
  font-size: clamp(44px, 6.2vw, 92px);
  line-height: 0.94;
  letter-spacing: -0.035em;
}
.day .team-copy > p {
  margin-top: 22px;
  max-width: 34ch;
  font-size: 19px;
  color: var(--ink-soft);
}
.day .team-choices {
  gap: 8px;
  margin-top: 30px;
  max-width: 460px;
}
.day .team-choice {
  display: block;
  padding: 14px 18px;
  border: 2px solid transparent;
  border-radius: 16px;
  color: var(--ink);
  transition:
    border-color 160ms ease,
    background-color 160ms ease,
    box-shadow 160ms var(--ease-out),
    transform 160ms var(--ease-out);
}
.day .team-choice strong {
  font-family: var(--display);
  font-stretch: 100%;
  font-weight: 750;
  font-size: 18px;
}
.day .team-choice p {
  margin-top: 2px;
  font-size: 15px;
  color: var(--ink-soft);
}
.day .team-choice:hover {
  border-color: rgb(0 54 73 / 0.3);
}
.day .team-choice[aria-pressed="true"] {
  border-color: var(--ink);
  background: var(--paper);
  box-shadow: 4px 4px 0 var(--ink);
  transform: translate(-2px, -2px);
}
.day .team-phone-stage {
  position: relative;
  isolation: isolate;
}
.day .team-phone-stage::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 50%;
  left: 50%;
  width: min(560px, 90%);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgb(255 246 196 / 0.95) 0 45%, rgb(255 246 196 / 0) 70%);
  transform: translate(-50%, -50%);
}
.day .phone-shell {
  border: 2px solid var(--ink);
  background: #123c3a;
  box-shadow:
    var(--sticker),
    inset 0 0 0 2px rgb(255 255 255 / 0.1);
}
/* The highlighted choice already names the screen; the caption is only needed when the
   choices and phone are far apart on small screens. */
.day .phone-caption {
  display: none;
  margin-top: 18px;
  font-size: 13px;
  color: var(--ink-soft);
}

/* ---------- Pickups and gifts: 6:32 PM ---------- */

.connected-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(24px, 4vw, 64px);
  align-items: start;
}
.connection {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.day .connection-art {
  display: flex;
  justify-content: center;
  min-height: 0;
  padding: 0;
  background: none;
}
.connection:nth-child(1) .connection-art {
  transform: rotate(-2.5deg);
}
.connection:nth-child(2) {
  margin-top: 72px;
}
.connection:nth-child(2) .connection-art {
  transform: rotate(2deg);
}
.day .guest-phone {
  width: 290px;
  background: #123c3a;
}
.connection-copy {
  position: relative;
  z-index: 1;
  width: min(400px, 100%);
  margin-top: -56px;
  padding: 22px 24px 24px;
  border: 2px solid var(--ink);
  border-radius: 18px;
  background: var(--paper);
  box-shadow: var(--sticker);
}
.connection:nth-child(1) .connection-copy {
  transform: rotate(1.2deg) translateX(-24px);
}
.connection:nth-child(2) .connection-copy {
  /* Overlap less here so the gift card value, which changes with the chosen amount, stays visible. */
  margin-top: -14px;
  transform: rotate(-1deg) translateX(24px);
}
.connection-copy h3 {
  font-family: var(--display);
  font-stretch: 100%;
  font-weight: 800;
  font-size: clamp(24px, 2.2vw, 30px);
  line-height: 1.05;
  letter-spacing: -0.025em;
}
.connection-copy p {
  margin-top: 10px;
  font-size: 16px;
  color: var(--ink-soft);
}
.connected-footnote {
  margin-top: 56px;
  font-size: 14px;
  text-align: center;
  color: rgb(255 255 255 / 0.72);
}
.order-track {
  display: flex;
  gap: 6px;
  margin: 12px 0;
}
.order-track span {
  flex: 1;
  height: 4px;
  border-radius: 4px;
  background: #e0e6dc;
}
.order-track span.done {
  background: #568b6d;
}
.order-options {
  display: flex;
  gap: 6px;
  margin-top: 14px;
}
.gift-options {
  display: flex;
  justify-content: center;
  gap: 9px;
  margin-top: 24px;
}
.native-status-body h4 {
  margin-block: 0;
}

/* ---------- Shift Replay: 10:12 PM ---------- */

.chapter-night .app-panel {
  --app-muted: rgb(255 255 255 / 0.62);
  --app-line: rgb(255 255 255 / 0.12);
  --app-blue: var(--ticket);
  border: 1.5px solid rgb(255 255 255 / 0.16);
  background: linear-gradient(180deg, rgb(255 255 255 / 0.07), rgb(255 255 255 / 0.03));
  color: #fff;
  box-shadow: 0 40px 80px -40px rgb(0 0 0 / 0.6);
}
.chapter-night .app-top {
  background: rgb(255 255 255 / 0.04);
}
.chapter-night .app-top strong {
  color: #fff;
}
.replay-story-body {
  padding: 34px 36px 0;
}
.replay-spotlight {
  display: grid;
}
.replay-chapter {
  grid-area: 1 / 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(200px, 0.6fr);
  align-items: center;
  gap: 40px;
  transition:
    opacity 260ms ease,
    transform 320ms var(--ease-out);
}
.replay-chapter[aria-hidden="true"] {
  visibility: hidden;
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
}
.replay-eyebrow {
  display: block;
  margin-bottom: 12px;
  font-family: var(--display);
  font-stretch: 72%;
  font-weight: 650;
  font-size: 16px;
  color: var(--app-muted);
}
.replay-chapter h3 {
  font-family: var(--display);
  font-stretch: 104%;
  font-weight: 800;
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1.02;
  letter-spacing: -0.03em;
}
.replay-chapter p {
  max-width: 44ch;
  margin-top: 14px;
  font-size: 16px;
  color: rgb(255 255 255 / 0.74);
}
.replay-stat {
  text-align: center;
}
.replay-stat > strong {
  display: block;
  font-family: var(--display);
  font-stretch: 82%;
  font-weight: 850;
  font-size: clamp(64px, 7vw, 104px);
  line-height: 0.95;
  letter-spacing: -0.05em;
  color: var(--ticket);
  text-shadow: 0 0 40px rgb(245 218 54 / 0.35);
  font-variant-numeric: tabular-nums;
}
.replay-stat > strong > span {
  font-size: 0.5em;
  margin-left: 0.06em;
}
.replay-stat > span {
  display: block;
  margin-top: 10px;
  font-size: 14px;
  color: var(--app-muted);
}
.replay-trace {
  margin-top: 32px;
}
.replay-trace-labels {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
  font-size: 13px;
  color: var(--app-muted);
}
.replay-baseline-key {
  display: flex;
  align-items: center;
  gap: 8px;
}
.replay-baseline-key::before {
  content: "";
  width: 20px;
  border-top: 2px dashed rgb(255 255 255 / 0.55);
}
.replay-timeline-chart {
  width: 100%;
  height: 150px;
  overflow: visible;
}
.replay-focus-band {
  fill: rgb(245 218 54 / 0.09);
  transition:
    x 350ms var(--ease-out),
    width 350ms var(--ease-out);
}
.replay-chart-floor {
  stroke: rgb(255 255 255 / 0.18);
}
.replay-bar {
  fill: rgb(255 255 255 / 0.2);
  transition: fill 300ms ease;
}
.replay-bar.is-highlighted {
  fill: var(--ticket);
}
.replay-typical-line {
  fill: none;
  stroke: rgb(255 255 255 / 0.55);
  stroke-width: 1.5;
  stroke-dasharray: 4 4;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}
.replay-close-line {
  stroke: rgb(255 255 255 / 0.4);
  stroke-dasharray: 3 4;
  vector-effect: non-scaling-stroke;
}
.replay-clock-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  font-family: var(--display);
  font-stretch: 75%;
  font-weight: 600;
  font-size: 13px;
  color: var(--app-muted);
}
.replay-service-window {
  height: 4px;
  margin-top: 16px;
  border-radius: 4px;
  background: rgb(255 255 255 / 0.12);
  overflow: hidden;
}
.replay-service-window > span {
  display: block;
  width: 88.71%;
  height: 100%;
  background: var(--teal);
}
.replay-service-labels {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 8px;
  font-size: 13px;
  color: var(--app-muted);
}
.replay-service-labels strong {
  white-space: nowrap;
  margin-left: 6px;
  color: #fff;
  font-weight: 650;
}
.replay-service-labels > :last-child {
  text-align: right;
}
.replay-chapters {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin-top: 24px;
}
.replay-chapters button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 60px;
  padding: 12px 4px;
  border-top: 2px solid var(--app-line);
  color: var(--app-muted);
  font-size: 15px;
  font-weight: 600;
  transition:
    color 200ms ease,
    border-color 200ms ease;
}
.replay-chapters button > span {
  font-family: var(--display);
  font-stretch: 72%;
  font-size: 14px;
  opacity: 0.8;
}
.replay-chapters button[aria-pressed="true"] {
  border-top-color: var(--ticket);
  color: var(--ticket);
}
.replay-chapters button:hover {
  color: #fff;
}
.replay-chapters button:focus-visible {
  outline-offset: -4px;
}

/* ---------- Scroll stories ---------- */

.sticky-scene {
  width: 100%;
}
.scroll-story {
  overflow-anchor: none;
}
.scroll-enhanced .scroll-story {
  padding-block: 0;
  height: calc(var(--scene-height, 800px) + var(--scroll-run, 65vh));
}
/* The rush gets half of this run; see stepShares in home.js. */
.scroll-enhanced #replay {
  --scroll-run: 150vh;
}
.scroll-enhanced #ask {
  --scroll-run: 90vh;
}
.scroll-enhanced #team {
  --scroll-run: 110vh;
}
.scroll-enhanced .sticky-scene {
  position: sticky;
  top: var(--scene-top, 20px);
  padding-block: calc(var(--header-height) * 0.5 + 12px) 28px;
}

/* ---------- Midnight ---------- */

.closing {
  overflow: hidden;
  text-align: center;
  padding-block: clamp(110px, 14vw, 200px) clamp(90px, 10vw, 140px);
}
.night-sky {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1.5px 1.5px at 12% 18%, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 28% 42%, rgb(255 255 255 / 0.8) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 44% 12%, rgb(255 255 255 / 0.9) 50%, transparent 51%),
    radial-gradient(1px 1px at 61% 30%, #fff 50%, transparent 51%),
    radial-gradient(2px 2px at 78% 16%, rgb(255 255 255 / 0.9) 50%, transparent 51%),
    radial-gradient(1px 1px at 88% 48%, rgb(255 255 255 / 0.7) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 7% 62%, rgb(255 255 255 / 0.6) 50%, transparent 51%),
    radial-gradient(1px 1px at 35% 74%, rgb(255 255 255 / 0.5) 50%, transparent 51%),
    radial-gradient(1px 1px at 70% 66%, rgb(255 255 255 / 0.55) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 93% 80%, rgb(255 255 255 / 0.5) 50%, transparent 51%),
    radial-gradient(1px 1px at 52% 54%, rgb(255 255 255 / 0.45) 50%, transparent 51%),
    radial-gradient(1px 1px at 20% 88%, rgb(255 255 255 / 0.4) 50%, transparent 51%);
  pointer-events: none;
}
.closing-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.closing .chapter-time {
  justify-content: center;
}
.closing-mark {
  position: relative;
  width: 132px;
  height: 142px;
  margin: 18px 0 32px;
  filter: drop-shadow(0 0 1.5px #f8f1cf) drop-shadow(0 0 1.5px #f8f1cf);
}
.closing-mark::before {
  content: none;
}
.closing-inner::before {
  content: "";
  position: absolute;
  top: 40px;
  left: 50%;
  width: 260px;
  height: 260px;
  margin-left: -130px;
  border-radius: 50%;
  background: radial-gradient(circle, rgb(248 241 207 / 0.28) 0 35%, rgb(248 241 207 / 0) 70%);
  pointer-events: none;
}
.closing h2 {
  font-size: clamp(46px, 7vw, 108px);
}
.closing-inner > p:not(.chapter-time) {
  max-width: 44ch;
  margin-top: 28px;
  font-size: 19px;
  color: rgb(255 255 255 / 0.74);
}

/* ---------- Footer ---------- */

.footer {
  padding-block: 32px 44px;
  color: rgb(255 255 255 / 0.66);
  font-size: 14px;
}
body.day {
  background: var(--midnight);
}
.footer-top {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 28px;
  border-top: 1px solid rgb(255 255 255 / 0.12);
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  margin-top: 18px;
}
.footer-links a:hover {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* ---------- Narrower screens ---------- */

@media (max-width: 1100px) {
  .chapter-head {
    grid-template-columns: 1fr;
  }
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero h1 {
    font-size: clamp(44px, 11cqi, 104px);
  }
  .hero-stage {
    max-width: 560px;
    width: 100%;
    justify-self: end;
  }
  .hero-sun {
    width: min(460px, 80vw);
  }
  .ask-layout,
  .day .team-layout {
    grid-template-columns: 1fr;
  }
  .ask-printer {
    justify-self: start;
  }
}
@media (max-width: 860px) {
  .today-grid {
    grid-template-columns: 1fr;
  }
  .today-half + .today-half {
    border-left: 0;
    border-top: 1.5px solid var(--app-line);
  }
  .connected-grid {
    grid-template-columns: 1fr;
    gap: 72px;
  }
  .connection:nth-child(2) {
    margin-top: 0;
  }
  .replay-chapter {
    grid-template-columns: 1fr auto;
    gap: 20px;
  }
  .day-index ol {
    height: auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 6px 16px;
    margin: 0;
  }
  .day-index ol::before {
    content: none;
  }
  .day-index li {
    position: static;
  }
  .day-index a,
  .day-index li:last-child a {
    transform: none;
    text-align: left;
    margin: 0;
    padding: 10px 0 10px 26px;
  }
  .day-index a::before,
  .day-index li:last-child a::before {
    top: 14px;
    left: 0;
    right: auto;
  }
}
@media (max-width: 640px) {
  :root {
    --header-height: 64px;
  }
  body {
    font-size: 16px;
  }
  .logo-word {
    display: none;
  }
  .logo-mark {
    width: 36px;
    height: 39px;
  }
  .day-clock {
    padding: 6px 12px;
    font-size: 14px;
    gap: 10px;
  }
  .day-clock-track {
    width: 44px;
  }
  .day-nav-signin {
    min-height: 38px;
    padding: 0 14px;
    font-size: 14px;
  }
  .chapter {
    padding-block: 72px;
  }
  .hero {
    min-height: 0;
    padding-top: calc(var(--header-height) + 28px);
  }
  .hero-stage {
    padding-top: 76px;
  }
  .hero-mascot {
    width: 96px;
    height: 104px;
    margin-bottom: -30px;
  }
  .hero-speech {
    font-size: 15px;
  }
    .morning-card-body {
    padding: 18px;
  }
  .morning-headline {
    flex-direction: column;
    align-items: flex-start;
  }
  .morning-lift {
    text-align: left;
  }
  .chapter-head > p,
  .ask-copy > p,
  .day .team-copy > p {
    font-size: 17px;
  }
  .app-panel {
    border-radius: 20px;
    box-shadow: 5px 5px 0 var(--ink);
  }
  .chapter-night .app-panel {
    box-shadow: none;
  }
  .today-half {
    padding: 24px 20px;
  }
  .briefing-facts strong {
    font-size: 22px;
  }
  /* Ask Chompy and the team app on phones: each scene's choices become one row of chips directly
     above its demo, so the choices and the answer they select are on screen together while the
     scene is pinned. The Ask ticket is tightened to fit; a screen too short for the whole ticket
     fades its bottom (home.js sets is-clipped) rather than pushing the chips off the top. The team
     chips appear only when the scroll scene is pinned; otherwise phones.css keeps its grid. */
  .ask-layout {
    /* minmax(0, ...) lets the chip row scroll instead of widening the page on narrow phones. */
    grid-template-columns: minmax(0, 1fr);
    gap: 4px;
  }
  .question-list,
  .day.scroll-enhanced #team .team-choices {
    display: flex;
    gap: 8px;
    max-width: none;
    margin-top: 22px;
    /* Room for the pressed chip's offset shadow, which the scroll container would otherwise clip. */
    margin-inline: -4px;
    padding: 4px 4px 8px;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .question-list::-webkit-scrollbar,
  .day.scroll-enhanced #team .team-choices::-webkit-scrollbar {
    display: none;
  }
  .question,
  .day.scroll-enhanced #team .team-choice {
    flex: none;
    min-height: 40px;
    padding: 8px 16px;
    border: 2px solid rgb(0 54 73 / 0.22);
    border-radius: 999px;
    background: rgb(255 253 246 / 0.6);
    color: var(--ink);
    font-weight: 650;
    font-size: 15px;
    white-space: nowrap;
  }
  .question::before {
    display: none;
  }
  .question[aria-pressed="true"],
  .day.scroll-enhanced #team .team-choice[aria-pressed="true"] {
    border-color: var(--ink);
    background: var(--ticket);
    box-shadow: 3px 3px 0 var(--ink);
  }
  .question-full,
  .day.scroll-enhanced #team .team-choice > div {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
  }
  .question-short,
  .day.scroll-enhanced #team .team-choice-short {
    display: inline;
  }
  .day.scroll-enhanced #team .team-layout {
    grid-template-columns: minmax(0, 1fr);
  }
  .day.scroll-enhanced #team .team-choices {
    margin-top: 14px;
  }
  .day.scroll-enhanced #team .team-choice {
    min-height: 36px;
    padding: 6px 13px;
    font-size: 14px;
  }
  .day.scroll-enhanced #team .team-choice-short {
    margin: 0;
    font-size: inherit;
    color: inherit;
  }
  /* Longer runs on phones: home.js gives the last step 40% of the run so a flick that reaches the
     final answer stops on it. */
  .day.scroll-enhanced #ask {
    --scroll-run: 150vh;
  }
  .day.scroll-enhanced #team {
    --scroll-run: 160vh;
  }
  .scroll-enhanced #ask .sticky-scene,
  .scroll-enhanced #replay .sticky-scene {
    padding-bottom: 8px;
  }
  .printer-head {
    height: 60px;
    padding-bottom: 8px;
  }
  .printer-mark {
    width: 28px;
    height: 30px;
  }
  .printer-slot {
    bottom: 7px;
  }
  .ticket-feed {
    margin-inline: 14px;
    padding: 0 8px 14px;
    /* Header, chips, printer, and the scene's own margins take the rest of the shortest viewport. */
    max-height: calc(100svh - 204px);
  }
  .ticket-feed.is-clipped {
    -webkit-mask: linear-gradient(#000 calc(100% - 56px), #0000);
    mask: linear-gradient(#000 calc(100% - 56px), #0000);
  }
  .ticket {
    padding: 14px 18px calc(14px + var(--edge));
    font-size: 14px;
    line-height: 1.4;
  }
  .ticket-top {
    padding-bottom: 8px;
    font-size: 13px;
  }
  .ticket-question {
    margin-top: 8px;
    padding: 8px 10px;
    font-size: 15px;
    line-height: 1.35;
  }
  .ticket-answer {
    gap: 8px;
    margin-top: 10px;
  }
  .answer-lead {
    font-size: 19px;
  }
  .quick-metrics > div {
    padding: 8px 0;
  }
  .quick-metrics strong {
    font-size: 24px;
  }
  .quick-metrics span {
    font-size: 12px;
    line-height: 1.3;
  }
  .quick-note {
    padding: 8px 12px;
  }
  .quick-note strong {
    font-size: 14px;
  }
  .quick-note span {
    font-size: 13px;
    line-height: 1.35;
  }
  .quick-window strong {
    font-size: 22px;
  }
  .person-initials {
    width: 36px;
    height: 36px;
    font-size: 13px;
  }
  /* Shift Replay on phones: compact enough that the whole card fits below the header while the scene
     is pinned, instead of pinning its bottom edge and hiding the moment's headline above the screen. */
  .replay-story .app-top {
    min-height: 44px;
  }
  .replay-story-body {
    padding: 16px 18px 0;
  }
  .replay-chapter {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .replay-eyebrow {
    margin-bottom: 6px;
    font-size: 14px;
  }
  .replay-chapter h3 {
    font-size: 25px;
  }
  .replay-chapter h3 br {
    display: none;
  }
  .replay-chapter p {
    margin-top: 8px;
    font-size: 15px;
    line-height: 1.45;
  }
  .replay-stat > strong {
    font-size: 50px;
  }
  .replay-stat > span {
    font-size: 13px;
  }
  .replay-trace {
    margin-top: 16px;
  }
  .replay-trace-labels {
    margin-bottom: 8px;
    font-size: 12px;
  }
  .replay-timeline-chart {
    height: 108px;
  }
  .replay-service-window {
    margin-top: 10px;
  }
  .replay-chapters {
    margin-top: 12px;
  }
  .replay-chapters button {
    min-height: 48px;
    padding-block: 8px;
  }
  /* Short phones (home.js sets short-screen from the stable viewport height): the headline and stat
     carry each moment, so the app bar, explanation, and chart caption give way to keep the card on screen. */
  .short-screen .replay-story .app-top,
  .short-screen .replay-chapter p,
  .short-screen .replay-trace-labels > :first-child {
    display: none;
  }
  .short-screen .replay-trace-labels {
    justify-content: flex-end;
  }
  .short-screen .replay-timeline-chart {
    height: 76px;
  }
  .replay-stat {
    text-align: left;
    display: flex;
    align-items: baseline;
    gap: 12px;
  }
  .replay-stat > span {
    margin: 0;
  }
  .replay-stat > span br {
    display: none;
  }
  .replay-chapters {
    gap: 8px;
  }
  .replay-chapters button {
    flex-direction: column;
    gap: 2px;
    font-size: 13px;
  }
  .connection-copy,
  .connection:nth-child(1) .connection-copy,
  .connection:nth-child(2) .connection-copy {
    transform: none;
  }
  .connected-footnote {
    margin-top: 40px;
  }
  /* Without the scroll scene the team choices sit above the phone, so the caption names its screen.
     The scroll scene's chips already name it. */
  .day .phone-caption {
    display: block;
  }
  .day.scroll-enhanced #team .phone-caption {
    display: none;
  }
  .day.scroll-enhanced #team .team-copy h2 {
    font-size: 38px;
    line-height: 0.96;
  }
  .footer-top {
    flex-direction: column;
  }
  .closing-inner > p br {
    display: none;
  }
  .replay-service-labels {
    font-size: 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-delay: 0ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
  }
  .hero-rotator-line.is-leaving {
    visibility: hidden;
  }
}
