/* Schedulix / Editorial product cinema */
:root {
  color-scheme: light;
  --paper: #f4f2ea;
  --surface: #fbfaf6;
  --ink: #171d1b;
  --muted: #626c65;
  --teal: #087f73;
  --mint: #b7f5d1;
  --line: #d8dcd2;
  --soft-mint: #e2ebe0;
  --soft-violet: #e9e5f3;
  --glass: rgba(250, 249, 244, .91);
  --display: 'Space Grotesk', sans-serif;
  --body: 'Inter', sans-serif;
  --mono: 'Courier New', monospace;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #171d1b;
  --surface: #202924;
  --ink: #f4f2ea;
  --muted: #afbcb1;
  --teal: #9ee4c0;
  --line: #3c4840;
  --soft-mint: #283e33;
  --soft-violet: #343041;
  --glass: rgba(30, 38, 33, .94);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-padding-top: 110px;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: #b7f5d1;
  color: #171d1b;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

button {
  color: inherit;
  cursor: pointer;
}

button,
a,
summary {
  -webkit-tap-highlight-color: transparent;
}

button {
  border: 0;
  background: none;
}

button:disabled {
  cursor: default;
}

button,
a,
input,
summary,
[tabindex] {
  outline-offset: 5px;
}

:focus-visible {
  outline: 3px solid var(--teal);
}

[hidden] {
  display: none !important;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

svg {
  display: block;
}

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

h1,
h2,
h3 {
  font-family: var(--display);
  font-weight: 500;
  line-height: 1.08;
  letter-spacing: -.055em;
}

h2 {
  font-size: clamp(42px, 5.2vw, 76px);
}

h3 {
  font-size: 32px;
}

p {
  color: var(--muted);
}

em {
  font-style: normal;
}

.icon {
  width: 21px;
  height: 21px;
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.svg-defs {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.container {
  width: min(1280px, calc(100% - 112px));
  margin-inline: auto;
}

.section-space {
  padding-block: 110px;
}

.accent {
  color: var(--teal);
}

.eyebrow,
.chapter,
.edition,
.phone-label,
.art-caption,
.art-coordinate,
.scroll-cue,
.hero-index,
.schedule-topline,
.preview-footnote,
.publish-label {
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .075em;
  line-height: 1.6;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.status-dot {
  display: inline-block;
  flex: 0 0 6px;
  width: 6px;
  height: 6px;
  background: currentColor;
  color: var(--teal);
  border-radius: 50%;
}

.button {
  min-height: 52px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 24px;
  background: var(--ink);
  color: var(--paper);
  border: 1px solid var(--ink);
  padding: 14px 23px;
  border-radius: 7px;
  font-size: 15px;
  font-weight: 500;
  transition: background .2s, color .2s;
}

.button:hover {
  background: var(--teal);
  border-color: var(--teal);
  color: var(--paper);
}

.button .icon,
.text-link .icon,
.role-link .icon {
  transition: transform .2s ease;
}

.button:hover .icon,
.text-link:hover .icon {
  transform: translate(3px, -2px);
}

.button-small {
  min-height: 42px;
  font-size: 14px;
  padding: 10px 16px;
  gap: 14px;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  font-size: 14px;
  font-weight: 600;
  padding-block: 12px;
}

.text-link:hover {
  color: var(--teal);
}

.icon-button {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  flex-shrink: 0;
}

.icon-button:hover {
  background: var(--soft-mint);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  transform: translateY(-200%);
  padding: 12px 20px;
  z-index: 200;
  background: var(--ink);
  color: var(--paper);
}

.skip-link:focus {
  transform: none;
}

/* A light, quiet navigation shell. */
.nav {
  position: fixed;
  z-index: 50;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  width: min(1304px, calc(100% - 80px));
  min-height: 70px;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  border: 1px solid var(--line);
  background: var(--glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 14px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--display);
  font-size: 23px;
  font-weight: 600;
  letter-spacing: -.06em;
  white-space: nowrap;
}

.brand-dot {
  font: 12px var(--body);
  align-self: flex-start;
  margin: 5px 0 0 -5px;
}

.brand-mark {
  width: 27px;
  height: 27px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3px;
  transform: rotate(-8deg);
}

.brand-mark i {
  background: var(--teal);
  border-radius: 3px;
}

.brand-mark i:nth-child(2) {
  border-radius: 3px 9px 3px 3px;
  opacity: .7;
}

.brand-mark i:nth-child(3) {
  opacity: .7;
}

.nav-links {
  display: flex;
  gap: 28px;
  font-size: 13px;
  font-weight: 500;
}

.nav-links a {
  padding-block: 8px;
}

.nav-links a:hover {
  color: var(--teal);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.nav-toggle {
  display: none;
}

/* Cinematic scroll-travel opener. A 600vh section pins a 100vh sticky stage;
   depth plates rush past the camera toward a glowing portal as you scroll.
   The stage is intentionally dark in both themes (a title sequence), then fades into the ivory hero. */
.travel {
  position: relative;
  height: auto;
  background: #070d0b;
  isolation: isolate;
}

.travel-stage {
  position: relative;
  min-height: 600px;
  height: 100svh;
  overflow: hidden;
  background: radial-gradient(120% 92% at 50% 44%, #16342b 0%, #0d1e19 42%, #070d0b 100%);
}

.travel.is-travel-active {
  height: 200vh;
}

.travel.is-travel-active .travel-stage {
  position: sticky;
  top: 0;
}

.anchor-alias {
  display: block;
  position: absolute;
}

.travel-plates {
  position: absolute;
  inset: 0;
}

/* GSAP owns each plate's transform (yPercent, scale, pointer x/y). Layout centering
   therefore uses left/right + auto margins, never transform, so the two never collide.
   Rotations stay in CSS transform; GSAP parses and preserves them. */
.plate {
  position: absolute;
}

/* Farthest plate: the destination light the camera travels toward. */
.plate-portal {
  left: 0;
  right: 0;
  top: 44%;
  width: 66vmin;
  height: 66vmin;
  margin: -33vmin auto 0;
  z-index: 6;
}

.portal-glow,
.portal-ring,
.portal-core {
  position: absolute;
  inset: 0;
  border-radius: 50%;
}

.portal-glow {
  background: radial-gradient(circle, rgba(158, 228, 192, .28) 0%, rgba(8, 127, 115, .16) 38%, transparent 68%);
  filter: blur(14px);
}

.portal-ring {
  background: radial-gradient(circle, transparent 40%, rgba(183, 245, 209, .55) 51%, rgba(8, 127, 115, .4) 60%, transparent 72%);
  filter: blur(3px);
}

.portal-core {
  background: radial-gradient(circle, rgba(248, 250, 246, .92) 0%, rgba(183, 245, 209, .62) 20%, rgba(8, 127, 115, .14) 44%, transparent 68%);
}

/* A faint timetable grid gives the far field structure and depth. */
.plate-grid {
  left: 0;
  right: 0;
  top: 46%;
  width: 150vmin;
  height: 120vmin;
  margin: -60vmin auto 0;
  z-index: 7;
  opacity: .5;
  background-image: repeating-linear-gradient(to right, rgba(183, 245, 209, .16) 0 1px, transparent 1px 12.5%), repeating-linear-gradient(to bottom, rgba(183, 245, 209, .12) 0 1px, transparent 1px 16.66%);
  -webkit-mask-image: radial-gradient(circle at 50% 46%, #000 8%, transparent 62%);
  mask-image: radial-gradient(circle at 50% 46%, #000 8%, transparent 62%);
}

/* Atmospheric fog blobs: near and far haze, blurred, pointer-inert. */
.plate-fog {
  border-radius: 50%;
  filter: blur(38px);
}

.plate-fog-far {
  left: 40%;
  top: 22%;
  width: 46vmin;
  height: 46vmin;
  z-index: 8;
  background: radial-gradient(circle, rgba(8, 127, 115, .34), transparent 70%);
}

.plate-fog-near {
  right: 10%;
  bottom: -10%;
  width: 62vmin;
  height: 62vmin;
  z-index: 13;
  background: radial-gradient(circle, rgba(23, 52, 43, .6), transparent 72%);
}

/* 3-phone side-by-side row anchored to the right half of the hero stage. */
.travel-phones {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 60%;
  z-index: 10;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 20px;
  padding-bottom: 6vh;
  padding-right: 4vw;
}

.travel-phone-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  flex-shrink: 0;
}

.travel-phone-label {
  font-family: var(--mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .1em;
  color: #8fa396;
}

.travel-device {
  border-color: #2b332e !important;
}

/* Side phones: smaller, tilted, appear behind centre phone */
.travel-phone-a .device {
  width: 130px;
  transform: rotate(-6deg) translateY(22px);
  box-shadow: 0 40px 90px -34px #000, 0 0 60px -26px rgba(183, 245, 209, .3), inset 0 0 0 2px #6d746e;
}

.travel-phone-b .device {
  width: 130px;
  transform: rotate(6deg) translateY(22px);
  box-shadow: 0 40px 90px -34px #000, 0 0 60px -26px rgba(183, 245, 209, .3), inset 0 0 0 2px #6d746e;
}

/* Centre phone: larger, upright, most prominent */
.travel-phone-center .device {
  width: 178px;
  transform: translateY(-28px);
  box-shadow: 0 60px 130px -40px #000, 0 0 100px -28px rgba(183, 245, 209, .55), inset 0 0 0 2px #6d746e;
}

.travel-phone-center .travel-phone-label {
  color: var(--mint);
  font-size: 11px;
}

/* Mobile: show all 3 phones in a centred row at the bottom of the stage.
   This block must come AFTER the base .travel-overlay / .travel-headline rules
   so the overrides cascade correctly. Block is repeated below base styles. */

/* Editorial overlay: kicker, bottom-left headline, bottom-right thumbnails. */
.travel-overlay {
  position: absolute;
  inset: 0;
  z-index: 20;
  pointer-events: none;
  padding: 118px clamp(20px, 5vw, 68px) clamp(28px, 5vh, 54px);
}

.travel-kicker {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .09em;
  color: #9fb5a7;
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.travel-kicker .status-dot {
  color: var(--mint);
}

.travel-headline {
  position: absolute;
  left: clamp(20px, 5vw, 68px);
  bottom: clamp(28px, 6vh, 60px);
  max-width: min(680px, 78%);
}

.travel-title {
  font-family: var(--display);
  font-size: clamp(52px, 8.4vw, 124px);
  line-height: .96;
  letter-spacing: -.06em;
  color: #f4f2ea;
  margin-bottom: 20px;
}

.travel-title span {
  display: block;
  white-space: nowrap;
}

.travel-title .accent {
  color: var(--mint);
}

.travel-sub {
  color: #b6c6ba;
  font-size: clamp(12px, 1.15vw, 14px);
  line-height: 1.8;
  max-width: 420px;
}

.travel-cue {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 26px;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .08em;
  color: #9fb5a7;
}

.travel-cue-pill {
  width: 30px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid #3c4a41;
  border-radius: 18px;
  font-size: 17px;
  color: var(--mint);
}

.travel-thumbs {
  position: absolute;
  right: clamp(20px, 5vw, 68px);
  bottom: clamp(28px, 6vh, 60px);
  display: flex;
  gap: 14px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.travel-thumbs li {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: .07em;
  color: #8fa396;
}

.travel-thumb {
  width: 46px;
  height: 92px;
  display: block;
  padding: 3px;
  border: 1px solid #3c4a41;
  border-radius: 9px;
  background: #0f1a16;
  overflow: hidden;
}

.travel-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
  border-radius: 6px;
}

/* Finishing layers sit above everything and never intercept the pointer. */
.travel-grain {
  position: absolute;
  inset: 0;
  z-index: 30;
  pointer-events: none;
  opacity: .05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}

.travel-vignette {
  position: absolute;
  inset: 0;
  z-index: 29;
  pointer-events: none;
  background: radial-gradient(115% 88% at 50% 44%, transparent 42%, rgba(4, 8, 7, .62) 100%);
}

.travel-fade {
  position: absolute;
  inset: 0;
  z-index: 31;
  pointer-events: none;
  background: var(--paper);
  opacity: 0;
}

@media (max-width: 1000px) {

  /* Pin is gated off below the desktop breakpoint: the stage becomes a static,
     single-screen composed frame (no tall scroll-travel). */
  .travel {
    height: auto;
  }

  .travel-stage {
    position: relative;
    top: auto;
    height: 100svh;
    min-height: 540px;
  }

  .travel-overlay {
    padding-top: 96px;
  }

  /* overridden at 760px */
  /* Reduce plate count on small screens: drop the two busiest mid/near layers. */
  .plate-fog-near,
  .plate-shard-a {
    display: none;
  }

  /* Hide DBMS shard on mobile — it lands in the wrong spot. */
  .plate-shard-b {
    display: none;
  }

  .plate-portal {
    width: 78vmin;
    height: 78vmin;
  }

  .plate-device-a {
    width: 150px;
    left: 45%;
    top: 18%;
  }

  .plate-device-b {
    width: 132px;
    right: 4%;
    top: 25%;
  }

  .plate-device-c {
    width: 184px;
    top: 38%;
    right: 22%;
    left: auto;
  }

  .travel-headline {
    max-width: 88%;
  }

  .travel-thumbs {
    display: none;
  }

  .travel-title {
    font-size: clamp(42px, 12.5vw, 74px);
  }

  .travel-cue {
    margin-top: 18px;
  }
}

@media (max-width: 400px) {
  .plate-device-a {
    width: 104px;
  }

  .plate-device-b {
    width: 92px;
  }

  .plate-device-c {
    width: 128px;
  }

  .travel-sub {
    font-size: 13px;
    /* small phone — keep readable */
  }
}

/* Mobile travel section: all overrides must come after the base rules above */
@media (max-width: 760px) {
  .travel-phones {
    position: absolute;
    right: 0;
    left: 0;
    bottom: 0;
    top: auto;
    width: 100%;
    padding: 0 0 32px;
    gap: 10px;
    align-items: flex-end;
    justify-content: center;
    overflow: hidden;
  }

  .travel-phone-a .device {
    width: 100px;
    transform: rotate(-5deg) translateY(18px);
  }

  .travel-phone-b .device {
    width: 100px;
    transform: rotate(5deg) translateY(18px);
  }

  /* Remove upward shift on center phone — it was covering the FACULTY label */
  .travel-phone-center .device {
    width: 140px;
    transform: translateY(0);
  }

  /* Flip label to appear BELOW the phone so it's never covered */
  .travel-phone-wrap {
    flex-direction: column-reverse;
  }

  .travel-phone-label {
    font-size: 9px;
  }

  /* Hide kicker — it overlaps the title */
  .travel-kicker {
    display: none;
  }

  /* Overlay — flex column so the headline flows below the navbar naturally */
  .travel-overlay {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 90px 20px 0 !important;
    pointer-events: none;
  }

  /* Reset headline out of absolute positioning into normal flow */
  .travel-headline {
    position: static !important;
    left: auto !important;
    bottom: auto !important;
    max-width: 100%;
    margin: 0;
  }

  .travel-title {
    font-size: clamp(34px, 9.5vw, 56px) !important;
    text-shadow: 0 4px 30px rgba(0, 0, 0, 0.9), 0 2px 8px rgba(0, 0, 0, 0.9);
  }

  .travel-sub {
    font-size: 13px !important;
    max-width: 100%;
    color: #fff !important;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.9), 0 1px 4px rgba(0, 0, 0, 0.9);
    margin-top: 10px;
  }

  .travel-cue {
    display: none !important;
  }

  .travel-thumbs {
    display: none !important;
  }
}

/* Opening composition: type, tangible product, and space to breathe. */
.hero {
  padding-top: 148px;
}

.hero-topline {
  display: flex;
  justify-content: space-between;
  gap: 30px;
  align-items: center;
}

.hero-topline .eyebrow {
  font-size: 11px;
}

.edition {
  color: var(--muted);
  font-size: 11px;
}

.hero-layout {
  display: grid;
  grid-template-columns: 1.06fr 1fr;
  align-items: center;
  min-height: 602px;
  gap: 8px;
}

.hero-copy {
  z-index: 2;
  padding-bottom: 20px;
}

.hero h1 {
  font-size: clamp(76px, 8.55vw, 124px);
  line-height: .98;
  letter-spacing: -.077em;
  margin: 12px 0 28px;
  font-weight: 500;
}

.hero-line {
  display: block;
  white-space: nowrap;
}

.period {
  color: var(--ink);
}

.hero-description {
  font-size: 17px;
  max-width: 430px;
  line-height: 1.85;
}

.hero-description em {
  color: var(--ink);
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 27px;
  margin-top: 28px;
}

.hero-note {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 43px;
}

.hero-note p {
  font-size: 15px;
  line-height: 1.7;
}

.hero-note strong {
  font-weight: 500;
  color: var(--ink);
}

.note-line {
  height: 33px;
  width: 2px;
  background: var(--teal);
}

.hero-art {
  position: relative;
  min-width: 0;
  height: 580px;
  isolation: isolate;
}

.hero-art::before {
  content: '';
  position: absolute;
  inset: 70px 0 40px;
  z-index: -1;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 25% 20%;
  mask-image: radial-gradient(ellipse, #000, transparent 70%);
}

.art-coordinate {
  position: absolute;
  left: 9px;
  top: 60px;
  color: var(--muted);
  font-size: 10px;
}

.hero-phone {
  position: absolute;
}

.hero-phone-admin {
  width: 255px;
  right: 45px;
  top: 28px;
  transform: rotate(8deg);
  z-index: 2;
}

.hero-phone-student {
  width: 191px;
  left: 35px;
  top: 167px;
  transform: rotate(-9deg);
  z-index: 3;
}

.device {
  background: #fbfcfd;
  border-radius: 30px;
  border: 5px solid #303833;
  padding: 7px;
  box-shadow: 0 30px 50px -20px rgba(19, 37, 25, .35), inset 0 0 0 2px #8d938e;
  overflow: hidden;
  position: relative;
}

.device img {
  border-radius: 17px;
  width: 100%;
  background: #f8f9fc;
}

.device-camera {
  position: absolute;
  top: 10px;
  left: 50%;
  width: 7px;
  height: 7px;
  background: #29322e;
  border: 1px solid #56675d;
  border-radius: 50%;
  transform: translateX(-50%);
}

.phone-label {
  display: block;
  margin-top: 15px;
  text-align: center;
  font-size: 10px;
  color: var(--muted);
}

.sync-ticket {
  position: absolute;
  z-index: 5;
  right: 0;
  bottom: 49px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  box-shadow: 0 14px 30px -16px rgba(23, 29, 27, .25);
  transform: rotate(-3deg);
}

.ticket-icon {
  width: 33px;
  height: 33px;
  background: var(--soft-mint);
  color: var(--teal);
  display: grid;
  place-items: center;
  border-radius: 50%;
}

.sync-ticket strong {
  display: block;
  font-size: 12px;
  font-weight: 600;
}

.sync-ticket div>span {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-top: 3px;
}

.ticket-spark {
  color: var(--teal);
  font-size: 30px;
  margin-left: 16px;
}

.art-caption {
  position: absolute;
  bottom: 8px;
  left: 61px;
  font-size: 10px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 12px;
}

.tiny-cross {
  font-size: 20px;
  font-weight: 400;
}

.hero-bottom {
  padding: 20px 0 28px;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}

.scroll-cue {
  display: inline-flex;
  gap: 13px;
  align-items: center;
  font-size: 10px;
}

.scroll-cue>span {
  width: 29px;
  height: 39px;
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  border-radius: 18px;
  font-size: 18px;
}

.hero-bottom p {
  font-size: 12px;
  line-height: 1.8;
  text-align: center;
}

.hero-bottom strong {
  font-weight: 500;
  color: var(--ink);
}

.hero-index {
  color: var(--muted);
}

.capabilities {
  display: flex;
  justify-content: space-between;
  padding-block: 34px;
  gap: 24px;
}

.capabilities>span {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
}

.capabilities .icon {
  width: 17px;
  height: 17px;
  color: var(--teal);
}

.balance-mark,
.connected-mark {
  font-size: 28px;
  color: var(--teal);
  line-height: 1;
}

/* Hero ambient motion / Cinematic loops that reuse the existing art. Every rule is
   decorative-only, and both prefers-reduced-motion and [data-motion="paused"] (see the
   global overrides at the end of this file) disable all of it, so the layout stays intact. */
.hero-phone .device {
  isolation: isolate;
}

/* Scene 02 — The Reality. A constraint graph of real entities, not decorative cards.
   Links draw on scroll; the whole web converges inward to hand off to the Engine Room.
   Final state is visible by CSS default, so reduced-motion / no-JS shows the full graph. */
.reality {
  padding-block: 96px 44px;
}

.reality-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 44px;
  margin-block: 42px 8px;
}

.reality-head h2 {
  font-size: clamp(40px, 5vw, 72px);
}

.reality-head p {
  max-width: 370px;
  font-size: 16px;
  line-height: 1.9;
  padding-bottom: 6px;
}

.prob-sol-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  margin: 60px 0;
}

.prob-card,
.sol-card {
  padding: 48px;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.prob-card {
  background: #fdf5f5;
  border: 1px solid #f3dada;
}

:root[data-theme="dark"] .prob-card {
  background: #2a2020;
  border-color: #3f2a2a;
}

.sol-card {
  background: var(--soft-mint);
  border: 1px solid rgba(8, 127, 115, .15);
}

.prob-eyebrow {
  color: #d04b4b;
}

.sol-eyebrow {
  color: var(--teal);
}

.prob-title {
  font-size: 34px;
  font-weight: 500;
  font-family: var(--display);
  letter-spacing: -.02em;
  line-height: 1.1;
}

.sol-title {
  font-size: 34px;
  font-weight: 500;
  font-family: var(--display);
  letter-spacing: -.02em;
  line-height: 1.1;
}

.prob-highlight {
  color: #d04b4b;
}

.prob-list,
.sol-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.prob-list li,
.sol-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 16px;
  opacity: .85;
  line-height: 1.5;
}

.prob-list .icon {
  color: #d04b4b;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-top: 3px;
}

.sol-list .icon {
  color: var(--teal);
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  margin-top: 3px;
}

@media (max-width: 800px) {
  .prob-sol-grid {
    grid-template-columns: 1fr;
  }

  .prob-card,
  .sol-card {
    padding: 32px 24px;
  }

  .prob-title,
  .sol-title {
    font-size: 28px;
  }
}

.reality-legend span {
  display: flex;
  align-items: center;
  gap: 9px;
}

.lg {
  width: 20px;
  height: 2px;
  border-radius: 2px;
  display: inline-block;
}

.lg--teaches {
  background: var(--teal);
}

.lg--room {
  background: #c0a268;
}

.lg--division {
  background: var(--muted);
}

.reality-anchor {
  display: flex;
  align-items: center;
  gap: 15px;
  margin: 34px 0 0;
}

.reality-anchor img {
  width: 62px;
  border-radius: 9px;
  border: 1px solid var(--line);
}

.reality-anchor figcaption {
  font: 12px var(--mono);
  color: var(--muted);
  letter-spacing: .04em;
}

@media (max-width: 1000px) {
  .reality {
    padding-block: 70px 34px;
  }

  .reality-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    margin-block: 30px 4px;
  }

  .reality-web {
    height: clamp(360px, 84vw, 460px);
  }

  .token {
    padding: 7px 10px;
  }

  .token strong {
    font-size: 13px;
  }

  .token small {
    font-size: 7.5px;
  }

  .reality-anchor img {
    width: 54px;
  }
}

@media (max-width: 560px) {

  /* Tokens sit at 12%/88% of the web; clip (not scroll) any extreme-edge overflow. */
  .reality {
    overflow-x: clip;
  }

  .reality-web {
    height: clamp(330px, 102vw, 420px);
  }

  .token {
    padding: 6px 8px;
    border-radius: 6px;
  }

  .token strong {
    font-size: 12px;
  }

  .token small {
    font-size: 9px;
    letter-spacing: 0;
  }

  .period-ruler {
    font-size: 7.5px;
  }

  .reality-legend {
    gap: 16px;
    font-size: 12px;
  }
}

/* The only pinned chapter. Its ancestors never receive transforms. */
.story {
  background: #18231e;
  color: #f4f2ea;
  position: relative;
  overflow-x: clip;
}

.story-inner {
  padding-block: 108px 48px;
  min-height: 0;
}

.story::before,
.story::after {
  content: '';
  display: block;
  height: 72px;
  pointer-events: none;
}

.story::before {
  background: linear-gradient(var(--paper), #18231e);
}

.story::after {
  background: linear-gradient(#18231e, var(--paper));
}

.chapter {
  display: flex;
  justify-content: space-between;
  gap: 28px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
  font-size: 11px;
}

.chapter-end {
  color: var(--muted);
  text-align: right;
}

.chapter-dark {
  border-color: #3c4a41;
  color: #aec3b5;
}

.chapter-dark .chapter-end {
  color: #aec3b5;
}

.story-layout {
  display: grid;
  grid-template-columns: .8fr 1.35fr;
  gap: 58px;
  align-items: center;
  padding-top: 28px;
}

.story-copy h2 {
  font-size: clamp(42px, 4.7vw, 67px);
}

.story-copy h2 em {
  color: #b7f5d1;
}

.story-copy>p {
  color: #b2c0b6;
  margin-top: 22px;
  font-size: 16px;
  line-height: 1.9;
}

.story-steps {
  list-style: none;
  margin: 32px 0 0;
  padding: 0;
}

.story-steps li {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  margin-top: 20px;
  transition: opacity .25s;
}

.story-steps li>span {
  font: 12px var(--mono);
  color: #b7f5d1;
  padding-top: 5px;
}

.story-steps h3 {
  font-size: 21px;
  letter-spacing: -.025em;
}

.story-steps p {
  color: #b2c0b6;
  font-size: 15px;
  margin-top: 6px;
}

.story.is-animated .story-steps li:not(.is-current) {
  opacity: .43;
}

.schedule-scene {
  position: relative;
  min-width: 0;
}

.schedule-topline {
  display: flex;
  justify-content: space-between;
  color: #b2c0b6;
  font-size: 10px;
  margin-bottom: 18px;
}

.schedule-topline .status-dot {
  color: #b7f5d1;
  margin-right: 5px;
}

.schedule-board {
  padding: 25px;
  border: 1px solid #536457;
  border-radius: 12px;
  background: #25342b;
  position: relative;
}

.board-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.board-header .eyebrow {
  font-size: 11px;
  color: #b2c0b6;
}

.board-header h3 {
  font-size: 24px;
  letter-spacing: -.04em;
  margin-top: 6px;
}

.board-header>.icon {
  color: #b7f5d1;
}

.schedule-grid {
  display: grid;
  grid-template-columns: auto repeat(3, minmax(0, 1fr));
  gap: 6px;
  position: relative;
}

.break-band {
  grid-column: 1 / -1;
  grid-row: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 4px;
  background: #314c3c;
  color: #b7f5d1;
  border-radius: 4px;
  font: 10px var(--mono);
}

.break-band small {
  font-size: 10px;
}

.story.is-animated:not(.is-verified) .break-band,
.story.is-replay:not(.is-verified) .break-band {
  opacity: .25;
}

.lesson {
  position: relative;
}

.lesson.is-rule-target::after {
  content: '';
  position: absolute;
  inset: -2px;
  border: 2px solid #b7f5d1;
  border-radius: 6px;
  pointer-events: none;
}

.story.is-constrained .lesson.is-rule-target {
  opacity: 1;
}

.grid-div {
  font: 12px var(--mono);
  font-weight: 600;
  color: #b7f5d1;
  text-align: center;
  padding: 0 2px 6px;
}

.grid-slot {
  font: 11px var(--mono);
  color: #b2c0b6;
  display: flex;
  flex-direction: column;
  justify-content: center;
  line-height: 1.5;
  padding-right: 6px;
  white-space: nowrap;
}

.lesson {
  min-width: 0;
  padding: 10px 8px;
  color: #26362d;
  border-radius: 5px;
  box-shadow: 0 2px 2px #10211818;
  transition: opacity .35s ease;
}

.lesson.mint {
  background: #c1dbc8;
}

.lesson.lilac {
  background: #d4cfe3;
}

.lesson.sand {
  background: #e8dfb9;
}

.lesson.free {
  background: transparent;
  border: 1px dashed #536457;
  box-shadow: none;
  color: #8fa396;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
}

.lesson strong {
  display: block;
  font-size: 14px;
  margin: 0 0 3px;
  font-weight: 600;
}

.lesson small {
  font-size: 11px;
  display: block;
}

.board-footer {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-top: 22px;
  color: #b2c0b6;
  font-size: 12px;
}

.board-footer i {
  display: inline-block;
  width: 4px;
  height: 4px;
  background: #b7f5d1;
  border-radius: 50%;
  vertical-align: middle;
  margin-right: 3px;
}

.conflict-flag,
.resolve-flag {
  position: absolute;
  right: -12px;
  border-radius: 6px;
  padding: 12px 16px;
  font-size: 12px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity .3s, visibility .3s, transform .3s;
  pointer-events: none;
  z-index: 4;
}

.conflict-flag {
  top: 36%;
  border: 1px solid #e8b2a0;
  background: #f8d4bd;
  color: #633726;
}

.conflict-flag-b {
  top: auto;
  bottom: 22%;
}

.resolve-flag {
  top: 36%;
  border: 1px solid #9fd8b4;
  background: #cdeed7;
  color: #1d4a30;
}

.resolve-flag-b {
  top: auto;
  bottom: 22%;
}

.story.is-clashing .conflict-flag {
  opacity: 1;
  visibility: visible;
  transform: none;
}

/* During the solve each pair's conflict flag holds until that pair resolves, then
   cross-fades to its resolve flag. Pairs clear independently (Room 208 first). */
.story.is-solving:not(.is-resolved-a) .conflict-flag:not(.conflict-flag-b) {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.story.is-solving:not(.is-resolved-b) .conflict-flag-b {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.story.is-resolved-a .resolve-flag:not(.resolve-flag-b) {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.story.is-resolved-b .resolve-flag-b {
  opacity: 1;
  visibility: visible;
  transform: none;
}

/* Clash/resolve rings are real elements, not animated box-shadow, so the pinned,
   scrubbed Engine Room never repaints shadows mid-scroll. Hidden by default; the
   master timeline reveals them through beat classes (deterministic + reversible). */
.lesson.clash {
  position: relative;
}

.lesson__ring {
  position: absolute;
  inset: -3px;
  border: 3px solid transparent;
  border-radius: 8px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .28s ease, border-color .28s ease;
}

.story.is-clashing .lesson.clash .lesson__ring,
.story.is-solving .lesson.clash .lesson__ring {
  opacity: 1;
  border-color: #e07a5f;
}

.story.is-resolved-a .lesson.clash-a1 .lesson__ring,
.story.is-resolved-a .lesson.clash-a2 .lesson__ring {
  opacity: 1;
  border-color: #58b98a;
}

.story.is-resolved-b .lesson.clash-b1 .lesson__ring,
.story.is-resolved-b .lesson.clash-b2 .lesson__ring {
  opacity: 1;
  border-color: #58b98a;
}

.lesson .v-clash {
  display: none;
}

.story.is-clashing .v-clash {
  display: block;
}

.story.is-clashing .v-fix {
  display: none;
}

.story.is-solving:not(.is-resolved-a) .clash-a2 .v-clash {
  display: block;
}

.story.is-solving:not(.is-resolved-a) .clash-a2 .v-fix {
  display: none;
}

.story.is-solving:not(.is-resolved-b) .clash-b2 .v-clash {
  display: block;
}

.story.is-solving:not(.is-resolved-b) .clash-b2 .v-fix {
  display: none;
}

/* Engine Room live readout: conflict counter + solver phase. Absolutely placed in the
   board's top-right corner (the decorative grid icon gave up that spot) so it adds no
   layout height to the pinned scene. Hidden until the desktop scrub owns the scene. */
.solver-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 38px;
  margin: -12px 0 16px;
}

.conflict-counter {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
}

.counter-value {
  font: 700 26px/1 var(--display);
  color: #e07a5f;
  min-width: 1ch;
  text-align: right;
  transition: color .3s ease;
}

.counter-value.is-clear {
  color: #58b98a;
}

.counter-label {
  font: 11px var(--mono);
  letter-spacing: .08em;
  color: #b2c0b6;
}

.solver-phase {
  font: 11px var(--mono);
  letter-spacing: .06em;
  color: #b7f5d1;
  text-align: right;
  max-width: 150px;
}

.solver-phase:empty {
  display: none;
}

/* Clash connectors: absolutely-positioned grid-area overlays bridging each double-booked
   pair (grid-row / grid-column are 1-based lines). Abspos keeps them out of auto-flow so
   the lessons never shift; the node lands exactly on the seam between the two cells. */
.clash-link {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 6;
  opacity: 0;
  transition: opacity .3s ease;
}

.clash-link::before {
  content: '';
  position: absolute;
  left: calc(50% - 24px);
  right: calc(50% - 24px);
  top: 50%;
  height: 2px;
  margin-top: -1px;
  background: #e07a5f;
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: center;
  transition: transform .45s cubic-bezier(.4, 0, .2, 1);
}

.clash-link__node {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 20px;
  height: 20px;
  margin: -10px 0 0 -10px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #e07a5f;
  color: #2a1206;
  font: 700 14px/1 var(--display);
  box-shadow: 0 0 0 3px #25342b;
}

.clash-link--a {
  grid-row: 4;
  grid-column: 2 / 4;
}

.clash-link--b {
  grid-row: 6;
  grid-column: 3 / 5;
}

.story.is-solving.is-room-freed .clash-a2 .room-before {
  display: none;
}

.story.is-solving.is-room-freed .clash-a2 .room-after {
  display: block;
}

.story.is-clashing .clash-link,
.story.is-solving .clash-link {
  opacity: 1;
}

.story.is-clashing .clash-link::before,
.story.is-solving .clash-link::before {
  transform: scaleX(1);
}

.story.is-resolved-a .clash-link--a {
  opacity: 0;
}

.story.is-resolved-b .clash-link--b {
  opacity: 0;
}

/* Scene 05 — the six engine constraints, applied in order. The rail overlays the
   board's lower third (absolute: no added height, and it never covers the two clash
   rows). Non-conflict lessons dim so the rules visibly "act on" the week. */
.story.is-constrained .lesson:not(.clash):not(.is-rule-target) {
  opacity: .4;
}

.constraint-rail {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid #536457;
}

.rule-detail {
  grid-column: 1 / -1;
  min-height: 30px;
  font: 12px/1.5 var(--body);
  color: #b2c0b6;
  margin-top: 4px;
}

.story.is-animated .constraint-rail .rule {
  opacity: .55;
}

.story .rule,
.story.is-animated .rule.is-on {
  opacity: 1;
}

.story .rule.is-active {
  border-color: #b7f5d1;
  background: #365240;
}

.story.is-constrained .rule.is-on {
  opacity: 1;
}

.story.is-constrained .constraint-rail {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.rail-label {
  grid-column: 1 / -1;
  font: 10px var(--mono);
  letter-spacing: .1em;
  color: #8fa396;
  margin-bottom: 1px;
}

.rule {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px;
  border: 1px solid #37463d;
  border-radius: 6px;
  background: #21302a;
  opacity: .45;
  transition: opacity .3s ease, border-color .3s ease, background .3s ease;
}

.rule-mark {
  flex: 0 0 6px;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #536457;
  transition: background .3s ease;
}

.rule-name {
  font: 11px var(--mono);
  letter-spacing: .01em;
  color: #c3d0c7;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rule-check {
  width: 12px;
  height: 12px;
  margin-left: auto;
  flex: 0 0 12px;
  color: #58b98a;
  opacity: 0;
  transform: scale(.5);
  transition: opacity .3s ease, transform .3s ease;
}

.rule.is-on {
  opacity: 1;
  border-color: #58b98a55;
  background: #25362c;
}

.rule.is-on .rule-mark {
  background: #58b98a;
}

.rule.is-on .rule-check {
  opacity: 1;
  transform: scale(1);
}

/* Scene 06 — Solve. The engine scans the week, clears each conflict in order,
   allocates the recess break, then stamps the verified result. Every state is
   class-driven (is-solving / is-resolved-a / is-resolved-b / is-verified) so the
   desktop scrub and the mobile tap-to-play replay share one path, and reduced-motion
   or Pause snaps straight to the final resolved frame. */
.solver-sweep {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 42px;
  z-index: 3;
  pointer-events: none;
  opacity: 0;
  border-radius: 4px;
  background: linear-gradient(180deg, transparent 0%, #58b98a22 38%, #b7f5d1 50%, #58b98a22 62%, transparent 100%);
}

.lesson.free .v-break {
  display: none;
}

.story.is-resolved-b .break-slot {
  border-style: solid;
  border-color: #58b98a66;
  background: #2f4a3a;
  color: #b7f5d1;
}

.story.is-resolved-b .break-slot small:first-of-type {
  display: none;
}

.story.is-resolved-b .break-slot .v-break {
  display: block;
}

.quality-stamp {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 12px;
  margin-top: 12px;
  border-top: 1px solid #536457;
}

.story.is-animated:not(.is-verified) .quality-stamp,
.story.is-replay:not(.is-verified) .quality-stamp {
  opacity: 0;
}

.story.is-verified .quality-stamp {
  opacity: 1;
}

.stamp-seal {
  display: grid;
  place-items: center;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #58b98a;
  color: #14251b;
}

.stamp-seal .icon {
  width: 18px;
  height: 18px;
}

.stamp-text {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.stamp-text strong {
  font: 700 14px/1 var(--display);
  letter-spacing: -.01em;
  color: #eaf6ee;
}

.stamp-text small {
  font: 10px var(--mono);
  letter-spacing: .04em;
  color: #9fd8b4;
}

/* Touch / narrow replay: the pinned desktop scrub is unavailable, so a tap plays the
   same before -> after solve once. Hidden unless the engine marks the scene replayable. */
.solve-replay {
  display: none;
}

.story.is-replay .solve-replay {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.solve-run {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 20px;
  border: 1px solid #58b98a;
  border-radius: 30px;
  background: #2f4a3a;
  color: #d6f5e2;
  font: 600 14px/1 var(--display);
  letter-spacing: .01em;
  cursor: pointer;
  transition: background .25s ease, transform .15s ease, opacity .25s ease;
}

.solve-run:hover {
  background: #386149;
}

.solve-run:active {
  transform: scale(.97);
}

.solve-run .status-dot {
  color: #b7f5d1;
}

.solve-run[disabled] {
  opacity: .5;
  cursor: default;
}

.solve-verdict {
  font: 11px var(--mono);
  letter-spacing: .05em;
  color: #9fd8b4;
  text-align: center;
}

.solve-verdict:empty {
  display: none;
}

/* In the tap-to-play replay the flags sit fully inside the scene (no -12px overhang)
   so the conflicted "before" board can't overflow a narrow viewport. */
.story.is-replay .conflict-flag,
.story.is-replay .resolve-flag {
  right: 0;
  padding: 9px 12px;
  font-size: 11px;
  max-width: 76%;
}

.publish-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 25px;
  gap: 12px;
}

.publish-label {
  font-size: 10px;
  color: #b7f5d1;
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.publish-label .icon {
  width: 15px;
  height: 15px;
}

.role-stamps {
  display: flex;
  gap: 6px;
}

.role-stamps span {
  border: 1px solid #617569;
  border-radius: 30px;
  font-size: 10px;
  padding: 5px 12px;
  color: #d1ddd4;
}

.scene-caption {
  font-size: 13px;
  color: #b2c0b6;
  text-align: center;
  margin-top: 25px;
}

/* Scene 07: actual Monday allocations against an explicitly illustrative limit. */
.faculty-layout {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 28px;
  align-items: start;
}

.workload-panel,
.workload-proof {
  margin: 0;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
}

.workload-panel {
  padding: 32px;
}

.workload-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.workload-heading .eyebrow,
.workload-proof .eyebrow {
  font-size: 11px;
  color: var(--muted);
}

.workload-heading h3 {
  font-size: 30px;
  margin-top: 12px;
}

.workload-chip {
  flex-shrink: 0;
  font: 12px var(--mono);
  color: var(--teal);
  background: var(--soft-mint);
  border-radius: 30px;
  padding: 9px 11px;
}

.workload-key {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-block: 32px 12px;
  font: 12px var(--mono);
  color: var(--muted);
}

.workload-rows {
  list-style: none;
  margin: 0;
  padding: 0;
}

.workload-row {
  display: grid;
  grid-template-columns: 55px minmax(0, 1fr) 48px;
  gap: 12px;
  align-items: center;
  padding-block: 22px;
  border-top: 1px solid var(--line);
}

.workload-initials {
  font: 600 15px var(--mono);
}

.workload-track {
  height: 20px;
  position: relative;
  background: var(--soft-mint);
  border-radius: 3px;
}

.workload-fill {
  display: block;
  height: 100%;
  width: var(--load);
  background: var(--teal);
  border-radius: inherit;
  transform-origin: left center;
}

.workload-limit {
  position: absolute;
  left: 80%;
  top: -9px;
  bottom: -9px;
  border-left: 2px dashed var(--ink);
}

.workload-count {
  text-align: right;
  font: 13px var(--mono);
  color: var(--muted);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.workload-count b {
  font-size: 19px;
  color: var(--ink);
}

.workload-scale {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  margin: 8px 60px 0 67px;
  position: relative;
  font: 11px var(--mono);
  color: var(--muted);
}

.workload-scale span {
  width: 0;
  white-space: nowrap;
}

.workload-scale span:last-child {
  transform: translateX(-100%);
  width: auto;
  position: absolute;
  left: 100%;
}

.workload-note {
  font-size: 13px;
  line-height: 1.8;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}

.workload-proof {
  padding: 28px;
  background: var(--soft-violet);
  display: grid;
  grid-template-columns: 1fr 150px;
  gap: 24px;
  overflow: hidden;
}

.workload-proof h3 {
  font-size: 32px;
  margin-block: 15px;
}

.workload-proof p {
  font-size: 14px;
  line-height: 1.8;
}

.workload-proof .text-link {
  font-size: 14px;
  margin-top: 14px;
}

.workload-proof img {
  width: 150px;
  border: 4px solid var(--surface);
  border-radius: 13px;
}

.workload-proof figcaption {
  grid-column: 1 / -1;
  font-size: 12px;
  color: var(--muted);
}

@media (max-width: 1150px) {
  .faculty-layout {
    grid-template-columns: 1fr;
  }

  .workload-proof {
    grid-template-columns: 1fr 220px;
  }

  .workload-proof img {
    width: 220px;
  }

  .workload-proof-copy {
    max-width: 380px;
    align-self: center;
  }
}

/* Issue 3 fix: faculty name overlaps bar on mobile — switch to 2-row stacked grid */
@media (max-width: 760px) {
  .workload-row {
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    gap: 5px 8px;
    padding-block: 14px;
  }

  .workload-initials {
    grid-column: 1 / 2;
    grid-row: 1;
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .workload-count {
    grid-column: 2 / 3;
    grid-row: 1;
    font-size: 12px;
    align-self: center;
  }

  .workload-count b {
    font-size: 16px;
  }

  .workload-track {
    grid-column: 1 / -1;
    grid-row: 2;
    height: 16px;
  }

  .workload-scale {
    margin-inline: 0;
  }
}

@media (max-width: 600px) {

  .workload-panel,
  .workload-proof {
    padding: 22px 16px;
  }

  .workload-heading {
    flex-direction: column;
  }

  .workload-heading h3 {
    font-size: 28px;
  }

  .workload-scale span:last-child {
    font-size: 0;
  }

  .workload-scale span:last-child::after {
    content: '5';
    font-size: 11px;
  }

  .workload-proof {
    grid-template-columns: 1fr;
  }

  .workload-proof img {
    justify-self: center;
  }
}

/* Three capabilities, three different compositions. */
.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 44px;
  margin-block: 46px 52px;
}

.section-heading>p {
  max-width: 360px;
  font-size: 16px;
  line-height: 1.9;
  padding-bottom: 5px;
}

/* Rooms repeat the board's allocations, with occupancy distinct from health scores. */
.rooms-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 36px;
}

.room-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.room-tile {
  padding: 24px 20px 20px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  min-width: 0;
}

.room-tile--lab {
  background: var(--soft-mint);
}

.room-type {
  font: 11px var(--mono);
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 7px;
}

.room-type .icon {
  width: 13px;
  height: 13px;
}

.room-tile h3 {
  font-size: 29px;
  margin: 25px 0 10px;
  letter-spacing: -.04em;
}

.room-tile p {
  font-size: 12px;
  min-height: 34px;
}

.room-resolved {
  display: block;
  color: var(--teal);
}

.room-meter {
  background: var(--line);
  height: 5px;
  margin-block: 22px 12px;
  border-radius: 4px;
  overflow: hidden;
}

.room-meter span,
.health-track i {
  display: block;
  height: 100%;
  width: var(--fill);
  background: var(--teal);
  transform-origin: left;
  border-radius: inherit;
}

.room-reading {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 6px;
}

.room-reading strong {
  font: 500 22px var(--display);
  font-variant-numeric: tabular-nums;
}

.room-reading>span {
  font: 11px var(--mono);
  color: var(--muted);
}

.rooms-summary {
  padding: 30px 0 20px 28px;
  border-left: 1px solid var(--line);
  align-self: center;
}

.rooms-summary .eyebrow {
  font-size: 11px;
  color: var(--muted);
}

.rooms-total {
  font: 500 clamp(64px, 7vw, 100px)/1.2 var(--display);
  letter-spacing: -.07em;
  color: var(--teal);
  margin-top: 18px;
}

.rooms-total small {
  font-size: .45em;
}

.rooms-summary h3 {
  font-size: 27px;
  margin-bottom: 15px;
}

.rooms-summary p {
  font-size: 15px;
  line-height: 1.9;
  margin-bottom: 22px;
}

.room-match {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
  font-size: 13px;
}

.room-match .icon {
  width: 16px;
  height: 16px;
  margin-left: auto;
}

.rooms-summary .text-link {
  margin-top: 20px;
  font-size: 14px;
}

.data-note {
  font-size: 13px;
  line-height: 1.8;
  color: var(--muted);
  margin-top: 24px;
  max-width: 880px;
}

/* Three perspectives: static by default, one cross-fading device on fine pointers. */
.perspectives {
  background: var(--soft-mint);
  position: relative;
}

.perspectives-inner {
  padding-block: 105px 48px;
}

.perspectives-layout {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 70px;
  align-items: center;
  margin-top: 35px;
}

.perspective-copy>p {
  max-width: 450px;
  font-size: 14px;
  margin-top: 20px;
}

.perspective-steps {
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
}

.perspective-steps li {
  display: flex;
  gap: 16px;
  padding: 15px 0;
  border-top: 1px solid var(--line);
}

.perspective-node {
  flex: 0 0 26px;
  font: 12px var(--mono);
  padding-top: 5px;
  color: var(--teal);
}

.perspective-steps h3 {
  font-size: 22px;
  letter-spacing: -.03em;
}

.perspective-steps p {
  font-size: 14px;
  margin-top: 6px;
}

.perspective-steps .text-link {
  font-size: 13px;
  padding-block: 8px;
}

.perspective-visual {
  margin: 0;
  min-width: 0;
  text-align: center;
}

.perspective-device {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  border: 0;
  background: none;
  box-shadow: none;
  padding: 0;
  border-radius: 0;
  overflow: visible;
}

.perspective-layer {
  min-width: 0;
}

.perspective-layer img {
  width: 100%;
  border-radius: 14px;
  border: 3px solid #303833;
}

.perspective-device .device-camera {
  display: none;
}

.perspective-visual figcaption {
  font: 11px/1.8 var(--mono);
  color: var(--muted);
  margin-top: 24px;
}

.publish-pulse {
  width: 290px;
  max-width: 100%;
  margin: 20px auto 0;
  fill: var(--teal);
}

.publish-pulse path {
  fill: none;
  stroke: var(--teal);
  stroke-width: 1.5;
}

.publish-pulse .pulse-track {
  stroke: var(--line);
}

.pulse-line {
  stroke-dasharray: 1;
  stroke-dashoffset: 0;
}

.pulse-labels {
  display: flex;
  justify-content: space-between;
  max-width: 290px;
  margin: 0 auto;
  font: 10px var(--mono);
  color: var(--muted);
}

.perspectives.is-role-animated .perspective-device {
  display: block;
  width: min(255px, 28vh);
  margin: 0 auto;
  aspect-ratio: 960 / 2080;
  border: 5px solid #303833;
  border-radius: 28px;
  padding: 7px;
  background: #fbfcfd;
  box-shadow: 0 25px 50px -25px #13251966;
  overflow: hidden;
}

.is-role-animated .perspective-layer {
  position: absolute;
  inset: 7px;
}

.is-role-animated .perspective-layer img {
  border: 0;
  height: 100%;
  object-fit: contain;
  object-position: top;
}

.is-role-animated .perspective-device .device-camera {
  display: block;
}

.is-role-animated .perspective-steps li:not(.is-current) {
  opacity: .5;
}

.is-role-animated .perspective-steps li.is-current .perspective-node {
  font-weight: 700;
}

.perspective-mobile-note {
  display: none;
  font-size: 14px;
}

.perspective-mobile-note a {
  display: block;
  color: var(--teal);
  text-decoration: underline;
  margin-top: 8px;
}

/* Report-derived figures, with their actual source alongside. */
.analytics-source {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  font: 11px var(--mono);
  color: var(--teal);
}

.analytics-source>span:last-child {
  margin-left: auto;
  color: var(--muted);
}

.kpi-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 24px 0 38px;
  border-block: 1px solid var(--line);
}

.kpi-tile {
  padding: 28px;
  border-right: 1px solid var(--line);
}

.kpi-tile:last-child {
  border: 0;
}

.kpi-tile dt {
  font: 12px var(--mono);
  color: var(--muted);
}

.kpi-tile dd {
  font: 500 clamp(38px, 4.6vw, 64px)/1.1 var(--display);
  margin: 16px 0 0;
  letter-spacing: -.05em;
  font-variant-numeric: tabular-nums;
}

.kpi-tile dd small {
  font-size: .55em;
}

.analytics-layout {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 60px;
  align-items: center;
}

.analytics-charts {
  display: grid;
  gap: 22px;
  min-width: 0;
}

.health-chart,
.teaching-chart {
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 28px;
  min-width: 0;
}

.analytics-charts .eyebrow {
  font-size: 11px;
  color: var(--muted);
}

.analytics-charts h3 {
  font-size: 27px;
  margin: 10px 0 18px;
}

.health-grade {
  display: inline-flex;
  gap: 18px;
  align-items: center;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--soft-mint);
  color: var(--teal);
  font-size: 13px;
}

.health-grade strong {
  font: 14px var(--mono);
}

.health-rows {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
}

.health-rows li {
  display: grid;
  grid-template-columns: 135px minmax(0, 1fr) 30px;
  gap: 15px;
  align-items: center;
  margin-top: 16px;
  font-size: 14px;
}

.health-rows b {
  font: 13px var(--mono);
  text-align: right;
}

.health-track {
  height: 7px;
  background: var(--line);
  border-radius: 5px;
}

.teaching-chart figcaption>p {
  font-size: 13px;
}

.teaching-chart svg {
  margin-top: 20px;
  width: 100%;
  height: auto;
}

.chart-grid {
  fill: none;
  stroke: var(--line);
  stroke-width: 1;
}

.chart-bar {
  fill: none;
  stroke: var(--teal);
  stroke-width: 14;
  transform-box: fill-box;
  transform-origin: center bottom;
}

.chart-bar--b {
  stroke: #9b82b8;
}

.chart-labels {
  font: 12px var(--mono);
  fill: var(--muted);
  text-anchor: middle;
}

.chart-legend {
  display: flex;
  justify-content: center;
  gap: 22px;
  font: 12px var(--mono);
  color: var(--muted);
}

.chart-legend span {
  display: flex;
  gap: 8px;
  align-items: center;
}

.chart-legend i {
  display: block;
  width: 8px;
  height: 8px;
  background: var(--teal);
  border-radius: 2px;
}

.chart-legend span:last-child i {
  background: #9b82b8;
}

.analytics-proof {
  margin: 0;
  text-align: center;
  min-width: 0;
}

.analytics-proof .device {
  width: min(300px, 90%);
  margin: 0 auto;
}

.analytics-proof figcaption {
  font: 12px/1.9 var(--mono);
  color: var(--muted);
  margin-top: 26px;
}

.analytics-proof .text-link {
  margin-top: 10px;
  font-size: 14px;
}

.export-note {
  display: block;
  font: 11px var(--mono);
  color: var(--muted);
  margin-top: 12px;
}

.cta-recap {
  display: flex;
  gap: 12px 24px;
  flex-wrap: wrap;
  padding-bottom: 24px;
  border-bottom: 1px solid #173a2940;
  font: 12px var(--mono);
}

.cta-recap span:not(:last-child)::after {
  content: '→';
  margin-left: 24px;
  opacity: .65;
}

.cta-product {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  margin-block: 25px 40px;
}

.cta-product p {
  font: 24px/1.4 var(--display);
  color: #365947;
  letter-spacing: -.035em;
}

.cta-product strong {
  font-weight: 500;
  color: #173a29;
}

.cta-devices {
  display: flex;
  gap: 10px;
}

.cta-devices img {
  width: 48px;
  height: 100px;
  object-fit: cover;
  border: 3px solid #173a29;
  border-radius: 9px;
}

/* Real, legible screens; the gallery never advances on its own. */
.preview-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
  padding-top: 55px;
}

.preview-copy {
  padding-left: 45px;
}

.preview-copy>.eyebrow {
  color: var(--muted);
  margin-bottom: 20px;
}

.preview-copy h2 {
  font-size: clamp(58px, 6vw, 88px);
}

.preview-copy>p {
  font-size: 15px;
  line-height: 1.85;
  margin-top: 24px;
  max-width: 320px;
}

.preview-tabs {
  display: inline-flex;
  padding: 5px;
  margin-top: 32px;
  border: 1px solid var(--line);
  border-radius: 30px;
  gap: 4px;
}

.preview-tabs button {
  padding: 10px 19px;
  border-radius: 30px;
  font-size: 13px;
}

.preview-tabs button[aria-selected="true"] {
  background: var(--ink);
  color: var(--paper);
}

.preview-copy .preview-description {
  font-size: 15px;
  min-height: 76px;
  max-width: 330px;
}

.preview-footnote {
  display: block;
  font-size: 12px;
  margin-top: 34px;
  color: var(--muted);
  line-height: 2;
}

.gallery-panel {
  position: relative;
  isolation: isolate;
}

.gallery-backdrop {
  position: absolute;
  width: 430px;
  height: 430px;
  max-width: 100%;
  border: 1px solid var(--line);
  border-radius: 50%;
  left: 50%;
  top: 80px;
  transform: translateX(-50%);
  display: grid;
  place-items: center;
  z-index: -1;
}

.gallery-backdrop::before {
  content: '';
  position: absolute;
  inset: 30px;
  border: 1px solid var(--line);
  border-radius: 50%;
}

.gallery-backdrop span {
  font: 380px/.9 var(--display);
  color: var(--soft-mint);
  transform: rotate(-20deg);
}

.gallery-device-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.gallery-device {
  width: 280px;
  aspect-ratio: 960 / 2080;
}

.gallery-device img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: top;
}

.expand-button {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 11px;
  margin: 20px auto 10px;
  min-height: 36px;
}

.expand-button .icon {
  width: 14px;
  height: 14px;
}

.expand-button:hover {
  color: var(--teal);
}

.gallery-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 320px;
  margin: 10px auto 0;
  gap: 20px;
}

.gallery-controls .icon-button {
  border: 1px solid var(--line);
}

.gallery-meta {
  display: flex;
  flex-direction: column;
  text-align: center;
  min-width: 0;
}

.gallery-meta span {
  font: 11px var(--mono);
  color: var(--muted);
}

.gallery-meta strong {
  font-size: 12px;
  font-weight: 500;
  margin-top: 5px;
}

.flip {
  transform: rotate(180deg);
}

.gallery-error {
  text-align: center;
  max-width: 280px;
  margin: 20px auto;
  font-size: 14px;
}

.faq {
  display: grid;
  grid-template-columns: .8fr 1.2fr;
  gap: 80px;
  border-top: 1px solid var(--line);
}

.faq-intro>.eyebrow {
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 23px;
}

.faq-intro>p {
  margin-top: 25px;
  font-size: 15px;
}

.faq-intro .text-link {
  color: var(--ink);
}

.faq-list {
  padding-top: 7px;
}

details {
  border-bottom: 1px solid var(--line);
}

summary {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 18px;
  cursor: pointer;
  padding: 24px 0;
  font-size: 16px;
  font-weight: 500;
}

summary::-webkit-details-marker {
  display: none;
}

summary>span {
  font: 11px var(--mono);
  color: var(--muted);
}

summary i {
  margin-left: auto;
  font: normal 23px var(--display);
  color: var(--teal);
}

details[open] summary i {
  transform: rotate(45deg);
}

details>p {
  padding: 0 28px 25px;
  font-size: 15px;
  line-height: 1.85;
}

.cta-section {
  background: #b7f5d1;
  color: #173a29;
  padding: 58px 0 35px;
}

.cta-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cta-top .eyebrow {
  font-size: 11px;
}

.cta-top .status-dot {
  color: #087f73;
}

.cta-flower {
  font-size: 70px;
  line-height: 1;
  color: #087f73;
}

.cta-inner h2 {
  font-size: clamp(64px, 9.5vw, 140px);
  letter-spacing: -.07em;
  line-height: .98;
  margin-block: 15px 45px;
}

.cta-inner h2 em {
  color: #08735f;
}

.cta-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 40px;
}

.cta-bottom p {
  color: #365947;
  font-size: 16px;
  line-height: 1.9;
}

.cta-actions {
  display: flex;
  align-items: center;
  gap: 24px;
}

.cta-actions .button {
  background: #173a29;
  border-color: #173a29;
  color: #f4f2ea;
}

.cta-actions .button:hover {
  background: #285c42;
}

.cta-actions .text-link:hover {
  color: #173a29;
  text-decoration: underline;
}

.cta-section :focus-visible {
  outline-color: #173a29;
}

.cta-micro {
  display: flex;
  gap: 18px;
  align-items: center;
  font-size: 14px;
  margin-top: 45px;
  border-top: 1px solid #173a2933;
  padding-top: 22px;
}

.cta-micro span {
  font-size: 14px;
  opacity: .6;
}

.footer {
  padding-top: 48px;
}

.footer-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
}

.footer-top>p {
  margin-right: auto;
  margin-left: 20px;
  font-size: 15px;
}

.footer-top nav {
  display: flex;
  gap: 25px;
  font-size: 15px;
}

.footer-top nav a:hover {
  color: var(--teal);
}

.footer-wordmark {
  font: 500 clamp(90px, 17vw, 246px)/1.1 var(--display);
  letter-spacing: -.09em;
  color: var(--ink);
  position: relative;
  margin-block: 35px;
}

.footer-wordmark>span {
  font: 20px var(--body);
  letter-spacing: 0;
  vertical-align: top;
  display: inline-block;
  margin-top: 23px;
}

.footer-bottom {
  border-top: 1px solid var(--line);
  padding-block: 23px 100px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  font-size: 14px;
  color: var(--muted);
}

.footer-bottom>div {
  display: flex;
  align-items: center;
  gap: 28px;
}

.motion-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  font-size: 11px;
}

.motion-toggle:hover {
  color: var(--teal);
}

/* Utility interfaces keep their own scrolling and keyboard behavior. */
.utility-controls {
  position: fixed;
  right: 22px;
  bottom: 20px;
  z-index: 40;
  display: flex;
  gap: 8px;
}

.guide-launch {
  display: flex;
  gap: 8px;
  align-items: center;
  background: var(--ink);
  color: var(--paper);
  border: 1px solid var(--muted);
  border-radius: 30px;
  font-size: 12px;
  padding: 10px 15px;
  box-shadow: 0 4px 15px #17251d15;
}

.guide-launch>span {
  color: var(--teal);
  font-size: 22px;
  line-height: 1;
}

.guide-launch:hover {
  background: var(--teal);
  color: var(--paper);
}

.guide-launch:hover>span {
  color: inherit;
}

.back-top {
  background: var(--surface);
  border: 1px solid var(--line);
}

.back-top .icon {
  transform: rotate(-90deg);
}

.guide-panel {
  position: fixed;
  z-index: 70;
  bottom: 80px;
  right: 22px;
  width: 360px;
  max-width: calc(100% - 32px);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 15px;
  box-shadow: 0 20px 60px #0003;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.guide-header {
  padding: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  flex-shrink: 0;
}

.guide-header h2 {
  font-size: 20px;
  letter-spacing: -.04em;
}

.guide-header p {
  font-size: 11px;
  margin-top: 4px;
}

.guide-body {
  padding: 16px;
  height: 230px;
  max-height: 35svh;
  overflow-y: auto;
  overscroll-behavior: contain;
  flex: 1 1 auto;
}

.guide-message {
  background: var(--soft-mint);
  border-radius: 8px;
  padding: 12px;
  color: var(--ink);
  font-size: 13px;
  margin-bottom: 12px;
  overflow-wrap: anywhere;
}

.guide-message a {
  text-decoration: underline;
}

.guide-message.user {
  background: var(--paper);
  margin-left: 24px;
  border: 1px solid var(--line);
}

.guide-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  padding: 0 16px 13px;
  flex-shrink: 0;
}

.guide-chips button {
  border: 1px solid var(--line);
  padding: 8px;
  border-radius: 30px;
  font-size: 11px;
}

.guide-chips button:hover {
  background: var(--soft-mint);
}

.guide-form {
  display: flex;
  padding: 8px 12px;
  border-top: 1px solid var(--line);
  flex-shrink: 0;
  align-items: center;
  gap: 4px;
}

.guide-form input {
  min-width: 0;
  flex: 1;
  background: transparent;
  border: 0;
  color: var(--ink);
  padding: 8px;
  font-size: 14px;
}

.screen-dialog {
  border: 1px solid var(--line);
  padding: 20px;
  background: var(--paper);
  color: var(--ink);
  border-radius: 14px;
  width: min(610px, calc(100% - 24px));
  max-height: 92svh;
  overscroll-behavior: contain;
}

.screen-dialog::backdrop {
  background: #101a15c9;
  backdrop-filter: blur(5px);
}

.dialog-top {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
}

.dialog-top .eyebrow {
  font-size: 10px;
  color: var(--muted);
}

.dialog-top h2 {
  font-size: 23px;
  margin-top: 5px;
  letter-spacing: -.04em;
}

.dialog-image img {
  width: 100%;
  border-radius: 8px;
}

.screen-dialog>p {
  font-size: 12px;
  padding-top: 15px;
}

html.modal-open {
  overflow: hidden;
}

@media (min-width: 1500px) {
  .hero-layout {
    min-height: 670px;
  }

  .hero-art {
    transform: scale(1.06);
    transform-origin: center;
  }
}

@media (max-width: 1200px) {
  .container {
    width: calc(100% - 80px);
  }

  .nav-links {
    gap: 17px;
  }

  .nav {
    gap: 18px;
    padding-inline: 16px;
  }

  .nav-actions {
    gap: 4px;
  }

  .hero-layout {
    grid-template-columns: 1.05fr 1fr;
    min-height: 565px;
  }

  .hero h1 {
    font-size: 8.4vw;
  }

  .hero-art {
    height: 520px;
  }

  .hero-phone-admin {
    width: 222px;
    right: 16px;
  }

  .hero-phone-student {
    width: 165px;
    left: 12px;
    top: 172px;
  }

  .sync-ticket {
    right: -5px;
    bottom: 27px;
  }

  .art-caption {
    bottom: 1px;
    left: 15px;
  }

  .hero-description {
    max-width: 315px;
    font-size: 15px;
  }

  .hero-actions {
    gap: 16px;
  }

  .hero-actions .button {
    padding-inline: 17px;
  }

  .hero-actions .text-link {
    font-size: 12px;
    gap: 8px;
  }

  .story-layout {
    gap: 30px;
    grid-template-columns: .78fr 1.22fr;
  }

  .schedule-board {
    padding: 18px;
  }

  .lesson {
    padding: 9px 5px;
  }

  .lesson strong {
    font-size: 12px;
  }

  .feature-copy {
    padding: 30px;
  }

  .resource-visual img {
    width: 210px;
    right: 15px;
  }

  .resource-tags {
    left: 25px;
  }

  .role-card {
    padding-inline: 22px;
  }

  .cta-actions {
    gap: 15px;
  }
}

@media (max-width: 1000px) {
  .nav-links {
    gap: 15px;
    font-size: 12px;
  }

  .nav-links a:last-child {
    display: none;
  }

  .brand {
    font-size: 21px;
  }

  .nav {
    width: calc(100% - 48px);
  }

  .container {
    width: calc(100% - 64px);
  }

  .hero-topline .edition {
    display: none;
  }

  .hero-layout {
    min-height: 545px;
  }

  .hero-phone-admin {
    width: 195px;
    right: 8px;
    top: 40px;
  }

  .hero-phone-student {
    width: 151px;
    left: 0;
    top: 170px;
  }

  .hero-art {
    height: 475px;
  }

  .sync-ticket {
    padding: 12px;
    right: 0;
    bottom: 20px;
    gap: 8px;
  }

  .ticket-spark {
    display: none;
  }

  .art-coordinate {
    top: 50px;
  }

  .hero h1 {
    font-size: 8.6vw;
  }

  .hero-note {
    margin-top: 25px;
  }

  .hero-actions {
    flex-wrap: wrap;
    gap: 5px 15px;
  }

  .hero-description {
    max-width: 280px;
  }

  .story-inner {
    min-height: 0;
    padding-block: 40px 55px;
  }

  .story-layout {
    grid-template-columns: 1fr;
    gap: 35px;
    padding-top: 40px;
  }

  .story-copy {
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: 35px;
    align-items: end;
  }

  .story-copy h2 {
    font-size: 56px;
  }

  .story-copy>p {
    margin: 0;
  }

  .story-steps {
    grid-column: 1 / -1;
    display: flex;
    justify-content: space-between;
    gap: 18px;
    margin-top: 22px;
  }

  .story-steps li {
    gap: 10px;
    flex: 1;
  }

  .story-steps p {
    font-size: 11px;
  }

  .schedule-scene {
    width: min(630px, 100%);
    margin: 10px auto 0;
  }

  .lesson strong {
    font-size: 12px;
  }

  .chapter-end {
    display: none;
  }

  .section-space {
    padding-block: 75px;
  }

  .section-heading>p {
    max-width: 260px;
  }

  .feature-copy h3 {
    font-size: 31px;
  }

  .resource-visual img {
    right: -15px;
    top: 25px;
  }

  .resource-tags {
    top: 12px;
  }

  .feature-reports .feature-copy {
    padding: 32px;
  }

  .role-grid {
    gap: 12px;
  }

  .role-card {
    padding: 20px 17px 0;
  }

  .role-card h3 {
    font-size: 27px;
  }

  .role-card>p {
    font-size: 12px;
  }

  .role-head {
    margin-bottom: 20px;
  }

  .role-head .eyebrow {
    font-size: 8px;
  }

  .role-device {
    height: 220px;
    border-width: 4px;
    padding: 4px;
  }

  .preview-copy {
    padding-left: 0;
  }

  .preview-layout {
    gap: 25px;
  }

  .preview-tabs button {
    padding: 9px 15px;
  }

  .gallery-backdrop {
    width: 350px;
    height: 350px;
  }

  .gallery-backdrop span {
    font-size: 300px;
  }

  .faq {
    gap: 40px;
  }

  .cta-bottom {
    align-items: flex-start;
  }

  .cta-actions {
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
  }

  .footer-top>p {
    margin-left: 0;
  }

  .footer-top nav {
    gap: 15px;
  }
}

@media (max-width: 760px) {
  html {
    scroll-padding-top: 90px;
  }

  .container {
    width: calc(100% - 40px);
  }

  .nav {
    top: 12px;
    width: calc(100% - 24px);
    min-height: 62px;
    padding: 9px 13px;
    border-radius: 12px;
    flex-wrap: wrap;
    gap: 8px;
  }

  .brand {
    font-size: 22px;
  }

  .brand-mark {
    width: 23px;
    height: 23px;
  }

  .nav-actions {
    margin-left: auto;
  }

  .nav-actions .button {
    font-size: 12px;
    min-height: 38px;
    padding: 8px 11px;
    gap: 8px;
  }

  .nav-actions .button .icon {
    width: 15px;
    height: 15px;
  }

  .theme-toggle {
    width: 33px;
    height: 36px;
  }

  .theme-toggle .icon {
    width: 17px;
    height: 17px;
  }

  .nav-toggle {
    display: flex;
    flex-direction: column;
    gap: 5px;
    width: 34px;
  }

  .nav-toggle span {
    width: 17px;
    height: 1px;
    background: var(--ink);
    transition: transform .2s;
  }

  .nav-toggle[aria-expanded="true"] span:first-child {
    transform: translateY(3px) rotate(45deg);
  }

  .nav-toggle[aria-expanded="true"] span:last-child {
    transform: translateY(-3px) rotate(-45deg);
  }

  .nav-links {
    order: 3;
    width: 100%;
    justify-content: center;
    gap: 25px;
  }

  .nav-links a:last-child {
    display: block;
  }

  .interactive .nav-links {
    display: none;
  }

  .interactive .nav-links.is-open {
    display: flex;
    flex-direction: column;
    gap: 0;
    border-top: 1px solid var(--line);
    padding: 10px;
  }

  .nav-links.is-open a {
    padding: 13px 5px;
    font-size: 14px;
  }

  .hero {
    padding-top: 133px;
  }

  .interactive .hero {
    padding-top: 111px;
  }

  .hero-topline .eyebrow {
    font-size: 9px;
    letter-spacing: .045em;
  }

  .hero-layout {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .hero-copy {
    padding: 26px 0 0;
  }

  .hero h1 {
    font-size: clamp(66px, 13.6vw, 98px);
    margin-block: 0 25px;
  }

  .hero-description {
    font-size: 16px;
    max-width: 390px;
  }

  .hero-actions {
    gap: 20px;
    margin-top: 23px;
  }

  .hero-actions .text-link {
    font-size: 13px;
    gap: 10px;
  }

  .hero-note {
    display: none;
  }

  .hero-art {
    height: 550px;
    width: min(470px, 100%);
    margin: 18px auto 0;
  }

  .hero-phone-admin {
    width: 230px;
    right: 45px;
    top: 35px;
    transform: rotate(4deg) !important;
  }

  .hero-phone-student {
    width: 180px;
    left: 26px;
    top: 182px;
    transform: rotate(-4deg) !important;
  }

  /* Labels hidden on mobile — phones overlap them when rotated */
  .art-caption,
  .phone-label {
    display: none !important;
  }

  .art-coordinate {
    top: 45px;
    left: 15px;
  }

  .sync-ticket {
    bottom: 22px;
    right: 8px;
  }

  .art-caption {
    bottom: 0;
    font-size: 9px;
  }

  .hero-bottom {
    padding-block: 22px;
  }

  .hero-bottom p {
    display: none;
  }

  .scroll-cue {
    font-size: 9px;
  }

  .hero-index {
    font-size: 10px;
  }

  .capabilities {
    padding-block: 25px;
    flex-wrap: wrap;
    gap: 18px 25px;
    justify-content: flex-start;
  }

  .capabilities>span {
    font-size: 11px;
    gap: 8px;
  }

  .capabilities>span:last-child {
    display: flex;
  }

  .capabilities .icon {
    width: 14px;
    height: 14px;
  }

  .balance-mark,
  .connected-mark {
    font-size: 20px;
  }

  .chapter {
    font-size: 10px;
    padding-top: 16px;
  }

  .story-copy {
    display: block;
  }

  .story-copy h2 {
    font-size: 53px;
  }

  .story-copy>p {
    margin-top: 20px;
  }

  .story-steps {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 15px;
  }

  .story-steps li {
    gap: 14px;
  }

  .story-steps p {
    font-size: 15px;
  }

  .schedule-board {
    padding: 15px;
  }

  .board-header h3 {
    font-size: 22px;
  }

  .schedule-grid {
    gap: 5px;
  }

  .lesson {
    padding: 9px 5px;
  }

  .lesson strong {
    font-size: 12px;
    margin-top: 0;
  }

  .lesson small {
    font-size: 10px;
  }

  .grid-slot {
    font-size: 10px;
  }

  .grid-div {
    font-size: 11px;
  }

  .board-footer {
    font-size: 11px;
  }

  .publish-label {
    font-size: 9px;
  }

  .role-stamps span {
    font-size: 9px;
    padding: 4px 9px;
  }

  .scene-caption {
    font-size: 12px;
  }

  .schedule-topline {
    font-size: 9px;
  }

  .section-space {
    padding-block: 64px;
  }

  .section-heading {
    flex-direction: column;
    align-items: flex-start;
    gap: 23px;
    margin-block: 35px;
  }

  h2 {
    font-size: clamp(43px, 9vw, 60px);
  }

  .section-heading>p {
    font-size: 15px;
    max-width: 340px;
  }

  .feature-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .feature-copy {
    padding: 28px;
  }

  .feature-copy h3 {
    font-size: 34px;
  }

  .feature-primary {
    min-height: 530px;
  }

  .resource-visual img {
    right: 24px;
    width: 230px;
    top: -6px;
  }

  .resource-tags {
    top: 40px;
    left: 25px;
  }

  .feature-adapt .feature-copy p {
    max-width: 290px;
  }

  .edit-visual {
    height: 275px;
  }

  .feature-reports {
    grid-template-columns: 1fr;
  }

  .report-visual {
    min-height: 295px;
  }

  .report-visual img {
    top: -165px;
    width: 390px;
  }

  .feature-reports .feature-copy {
    padding: 30px;
  }

  .feature-reports h3 {
    font-size: 34px;
  }

  .role-grid {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .role-card {
    margin-top: 0;
    padding: 28px 28px 0;
  }

  .role-head .eyebrow {
    font-size: 10px;
  }

  .role-card h3 {
    font-size: 35px;
  }

  .role-card>p {
    font-size: 15px;
  }

  .role-device {
    width: 245px;
    height: 310px;
  }

  .role-link {
    font-size: 14px;
  }

  .preview-layout {
    grid-template-columns: 1fr;
    gap: 30px;
    padding-top: 35px;
  }

  .preview-copy h2 {
    font-size: 64px;
  }

  .preview-copy>.eyebrow {
    font-size: 10px;
  }

  .preview-copy .preview-description {
    min-height: 0;
  }

  .preview-footnote {
    margin-top: 20px;
  }

  .gallery-device {
    width: 260px;
  }

  .gallery-backdrop {
    width: 330px;
    height: 330px;
  }

  .gallery-controls {
    max-width: 310px;
  }

  .faq {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .faq-intro>p {
    margin-top: 20px;
  }

  summary {
    font-size: 15px;
    gap: 12px;
    padding: 22px 0;
  }

  details>p {
    padding-inline: 23px 12px;
  }

  .cta-section {
    padding-top: 35px;
  }

  .cta-top .eyebrow {
    font-size: 9px;
  }

  .cta-flower {
    font-size: 45px;
  }

  .cta-inner h2 {
    font-size: clamp(52px, 11vw, 82px);
    margin-block: 22px 28px;
  }

  .cta-bottom {
    flex-direction: column;
    gap: 25px;
  }

  .cta-actions {
    flex-direction: row;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
  }

  .cta-actions .button {
    font-size: 13px;
    padding-inline: 16px;
    gap: 12px;
  }

  .cta-actions .text-link {
    font-size: 12px;
    gap: 6px;
  }

  .cta-micro {
    font-size: 13px;
    gap: 10px;
    margin-top: 30px;
  }

  /* Issue 5 fix: mobile footer — stack into neat columns */
  .footer-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .footer-top>p {
    margin-left: 0;
    font-size: 14px;
  }

  .footer-top nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px 20px;
    width: 100%;
    font-size: 14px;
  }

  .footer-wordmark {
    font-size: 17.5vw;
    margin-block: 20px 16px;
  }

  .footer-wordmark>span {
    font-size: 13px;
    margin-top: 10px;
  }

  .footer-bottom {
    align-items: flex-start;
    flex-direction: column;
    font-size: 13px;
    gap: 10px;
    padding-bottom: 90px;
  }

  .footer-bottom>div {
    width: 100%;
    justify-content: space-between;
  }

  .utility-controls {
    right: 12px;
    bottom: 12px;
  }

  /* Issue 6 fix: guide chat panel on mobile — full width, above utility bar */
  .guide-panel {
    left: 12px;
    right: 12px;
    bottom: 68px;
    width: auto;
    max-width: none;
    max-height: min(80svh, 500px);
  }

  .guide-body {
    height: 140px;
    max-height: 28svh;
  }

  .guide-header {
    padding: 14px 16px;
  }

  .guide-header h2 {
    font-size: 17px;
  }

  .guide-chips {
    padding: 0 12px 10px;
  }

  .guide-chips button {
    font-size: 10px;
    padding: 7px 10px;
  }

  .guide-form input {
    font-size: 16px;
    /* prevents iOS auto-zoom on focus */
  }

  .screen-dialog {
    padding: 15px;
  }
}

@media (max-width: 400px) {
  .container {
    width: calc(100% - 32px);
  }

  .nav {
    padding-inline: 10px;
    gap: 5px;
  }

  .nav .brand {
    font-size: 19px;
    gap: 7px;
  }

  .nav .brand-dot {
    display: none;
  }

  .nav-actions {
    gap: 1px;
  }

  .nav-actions .button {
    font-size: 11px;
    padding-inline: 8px;
  }

  .nav-actions .button .icon {
    display: none;
  }

  .hero h1 {
    font-size: 15vw;
  }

  .hero-topline .eyebrow {
    font-size: 8px;
  }

  .hero-description {
    font-size: 14px;
  }

  .hero-actions {
    gap: 15px;
  }

  .hero-actions .button {
    font-size: 13px;
    gap: 12px;
  }

  .hero-actions .text-link {
    font-size: 12px;
    gap: 5px;
  }

  .hero-art {
    height: 550px;
    margin-top: 12px;
  }

  .hero-phone-admin {
    width: 195px;
    right: 22px;
    top: 35px;
    transform: rotate(4deg) !important;
  }

  .hero-phone-student {
    width: 145px;
    left: 9px;
    top: 179px;
    transform: rotate(-4deg) !important;
  }

  .capabilities {
    gap: 16px;
  }

  .capabilities>span {
    font-size: 10px;
  }

  .story-copy h2 {
    font-size: 46px;
  }

  .schedule-board {
    padding: 12px;
  }

  .schedule-grid {
    gap: 4px;
  }

  .lesson {
    padding-inline: 3px;
  }

  .lesson strong {
    font-size: 11px;
  }

  .board-footer {
    gap: 4px;
    font-size: 10px;
  }

  .board-footer i {
    width: 3px;
    height: 3px;
    margin-right: 2px;
  }

  .publish-line {
    flex-wrap: wrap;
  }

  .publish-label {
    font-size: 8px;
  }

  .role-stamps span {
    padding: 4px 7px;
    font-size: 8px;
  }

  .resource-visual img {
    right: -6px;
  }

  .resource-tags {
    left: 20px;
  }

  .feature-copy {
    padding-inline: 23px;
  }

  .feature-copy h3 {
    font-size: 31px;
  }

  .gallery-device {
    width: 245px;
  }

  .cta-inner h2 {
    font-size: 12vw;
  }

  .cta-micro {
    font-size: 12px;
    gap: 7px;
  }
}

@media (max-width: 340px) {
  .hero-art {
    height: 510px;
  }

  .hero-phone-admin {
    width: 178px;
    right: 8px;
    transform: rotate(4deg) !important;
  }

  .hero-phone-student {
    width: 137px;
    left: 3px;
    top: 154px;
    transform: rotate(-4deg) !important;
  }

  .hero-actions {
    gap: 10px;
  }

  .hero-actions .text-link {
    font-size: 11px;
  }

  .footer-top>p {
    margin-left: 0;
  }
}

@media (min-width: 1001px) and (min-height: 720px) and (pointer: fine) {
  .story.is-animated .story-inner {
    padding-block: 105px 24px;
  }

  .story.is-animated .story-layout {
    padding-top: 18px;
  }

  .story.is-animated .schedule-topline {
    margin-bottom: 8px;
  }

  .story.is-animated .schedule-board {
    padding: 14px 18px;
  }

  .story.is-animated .board-header {
    margin-bottom: 16px;
  }

  .story.is-animated .board-header h3 {
    font-size: 20px;
  }

  .story.is-animated .lesson {
    padding-block: 5px;
  }

  .story.is-animated .lesson.free {
    min-height: 36px;
  }

  .story.is-animated .lesson strong {
    font-size: 12px;
  }

  .story.is-animated .lesson small {
    font-size: 10px;
    line-height: 1.45;
  }

  .story.is-animated .board-footer {
    margin-top: 12px;
  }

  .story.is-animated .constraint-rail {
    margin-top: 10px;
    padding-top: 8px;
  }

  .story.is-animated .quality-stamp {
    margin-top: 6px;
    padding-top: 7px;
  }

  .story.is-animated .stamp-seal {
    width: 24px;
    height: 24px;
    flex-basis: 24px;
  }

  .story.is-animated .publish-line {
    margin-top: 12px;
  }

  .story.is-animated .scene-caption {
    margin-top: 10px;
  }

  .is-role-animated .perspective-copy h2 {
    font-size: clamp(44px, 4.6vw, 66px);
  }

  .is-role-animated .perspective-steps li {
    padding-block: 10px;
  }
}

@media (max-width: 1100px) {
  .rooms-layout {
    grid-template-columns: 1fr;
  }

  .rooms-summary {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding: 24px 0 0;
  }

  .rooms-summary p {
    max-width: 520px;
  }

  .room-match {
    max-width: 370px;
  }

  .analytics-layout {
    gap: 30px;
  }

  .perspectives-layout {
    gap: 32px;
  }
}

@media (max-width: 1000px),
(pointer: coarse),
(max-height: 719px) {
  .perspectives-layout {
    display: block;
    margin-top: 28px;
  }

  .perspective-copy>p,
  .perspective-steps,
  .perspective-visual {
    display: none;
  }

  .perspective-mobile-note {
    display: block;
    margin-top: 20px;
  }

  .perspectives-inner {
    padding-block: 48px;
  }

  .nav {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }

  .plate-fog,
  .travel-grain {
    display: none;
  }
}

@media (max-width: 760px) {

  .plate-device-a,
  .plate-device-b,
  .plate-shard {
    display: none;
  }

  .plate-device-c {
    display: none;
  }

  /* phones handled by .travel-phones mobile rules above */
  .travel-stage {
    min-height: 680px;
  }

  /* travel-headline, travel-title, travel-sub: see the .travel-phones mobile block above */
  .travel-kicker {
    font-size: 9px;
    max-width: 200px;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.85), 0 1px 4px rgba(0, 0, 0, 0.85);
  }

  .room-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .room-tile {
    padding: 20px 14px;
  }

  .room-type {
    font-size: 10px;
  }

  .room-reading {
    flex-wrap: wrap;
  }

  .kpi-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .kpi-tile {
    padding: 24px 16px;
    border-bottom: 1px solid var(--line);
  }

  .kpi-tile:nth-child(2n) {
    border-right: 0;
  }

  .kpi-tile:nth-last-child(-n+2) {
    border-bottom: 0;
  }

  .analytics-source>span:last-child {
    margin-left: 0;
  }

  .analytics-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .health-chart,
  .teaching-chart {
    padding: 22px 16px;
  }

  .health-rows li {
    grid-template-columns: 105px minmax(0, 1fr) 24px;
    gap: 8px;
    font-size: 12px;
  }

  .analytics-charts h3 {
    font-size: 25px;
  }

  .analytics-proof .device {
    width: 250px;
  }

  .cta-product {
    align-items: flex-start;
    flex-direction: column;
  }

  .cta-recap {
    gap: 10px 14px;
    font-size: 11px;
  }

  .cta-recap span:not(:last-child)::after {
    margin-left: 14px;
  }

  .solver-phase {
    font-size: 10px;
    max-width: 115px;
  }

  .counter-label {
    font-size: 10px;
  }

  .constraint-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .lesson strong {
    overflow-wrap: anywhere;
  }

  .token small {
    white-space: normal;
    font-size: 9px;
  }

  .token {
    max-width: 24%;
    white-space: normal;
  }
}

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0s !important;
    animation: none !important;
  }

  /* No scroll-travel under reduced motion: show the composed arrival frame statically. */
  .travel {
    height: auto;
  }

  .travel-stage {
    position: relative;
    top: auto;
  }
}

html[data-motion="paused"] .travel {
  height: auto;
}

html[data-motion="paused"] .travel-stage {
  position: relative;
  top: auto;
}

html[data-motion="paused"] *,
html[data-motion="paused"] *::before,
html[data-motion="paused"] *::after {
  scroll-behavior: auto !important;
  transition-duration: 0s !important;
  animation: none !important;
}