/* The company typeface. Ploni ML v2 AAA ships two weights and only two — the
   DS is explicit that 700 has no face and must never be asked for, so
   `font-synthesis` is off below and every heavier declaration in this file was
   normalised to 600. Heebo is the fallback for a machine that fails to load it. */
@font-face {
  font-family: "Space Mono";
  src: url("../public/fonts/space-mono-400-latin.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Space Mono";
  src: url("../public/fonts/space-mono-700-latin.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Ploni ML v2 AAA";
  src: url("../public/fonts/ploni-regular-aaa.woff2") format("woff2"),
       url("../public/fonts/ploni-regular-aaa.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Ploni ML v2 AAA";
  src: url("../public/fonts/ploni-demibold-aaa.woff2") format("woff2"),
       url("../public/fonts/ploni-demibold-aaa.woff") format("woff");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #070807;
  --bg-soft: #0d100e;
  --surface: rgba(19, 23, 20, 0.88);
  --surface-solid: #121512;
  --surface-raised: #181d19;
  --surface-bright: #202620;
  --ink: #f2f5f1;
  --ink-soft: #c4ccc4;
  --muted: #8e998f;
  --faint: #5f6960;
  --line: rgba(225, 238, 226, 0.12);
  --line-strong: rgba(225, 238, 226, 0.2);
  --green: #45ee78;
  --green-deep: #18b856;
  --green-soft: rgba(69, 238, 120, 0.13);
  --blue: #4f8cff;
  --amber: #ffba51;
  --violet: #aa7cff;
  --red: #ff665d;
  --max: 1240px;
  --radius-sm: 12px;
  --radius: 16px;
  --radius-lg: 30px;
  --radius-xl: 42px;
  --font-display: "Ploni ML v2 AAA", "Heebo", system-ui, sans-serif;
  --font-body: "Ploni ML v2 AAA", "Heebo", system-ui, sans-serif;
  --font-mono: "Space Mono", "Ploni ML v2 AAA", "Heebo", ui-monospace, monospace;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--bg);
  /* No face above 600 exists: let the browser pick 600, never fake 700. */
  font-synthesis: none;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--ink);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  background:
    radial-gradient(900px 620px at 92% 5%, rgba(40, 133, 72, 0.12), transparent 70%),
    radial-gradient(760px 520px at 8% 34%, rgba(44, 79, 142, 0.09), transparent 74%),
    var(--bg);
}

html.preload,
html.preload body {
  height: 100%;
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

img {
  display: block;
  max-width: 100%;
}

::selection {
  color: #041008;
  background: var(--green);
}

.skip-link {
  position: fixed;
  top: 12px;
  inset-inline-start: 12px;
  z-index: 1000;
  padding: 10px 14px;
  border-radius: 10px;
  color: #041008;
  background: var(--green);
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.ambient-grid,
.noise,
#scene {
  position: fixed;
  inset: 0;
  pointer-events: none;
}

.ambient-grid {
  z-index: 0;
  opacity: 0.35;
  background-image:
    linear-gradient(rgba(208, 226, 210, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(208, 226, 210, 0.035) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: linear-gradient(to bottom, #000 0%, transparent 78%);
}

.noise {
  z-index: 8;
  opacity: 0.025;
  mix-blend-mode: soft-light;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.82' numOctaves='3' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)' opacity='.8'/></svg>");
}

#scene {
  z-index: 1;
  opacity: 0;
  transition: opacity 1.4s var(--ease);
}

html.ready #scene {
  opacity: 0.68;
}

html.no-3d #scene {
  display: none;
}

main,
.site-footer {
  position: relative;
  z-index: 2;
}

.site-nav {
  position: fixed;
  top: 18px;
  left: 50%;
  z-index: 100;
  width: min(calc(100% - 40px), 1320px);
  min-height: 64px;
  padding: 10px 12px 10px 18px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 18px;
  border: 1px solid transparent;
  border-radius: 22px;
  transform: translateX(-50%);
  transition:
    top 0.3s var(--ease),
    background 0.3s var(--ease),
    border-color 0.3s var(--ease),
    box-shadow 0.3s var(--ease),
    backdrop-filter 0.3s var(--ease),
    translate 0.5s var(--ease);
}

.site-nav.is-scrolled {
  top: 10px;
  border-color: var(--line);
  background: rgba(10, 12, 10, 0.72);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35), inset 0 1px rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(18px) saturate(1.25);
  -webkit-backdrop-filter: blur(18px) saturate(1.25);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  width: max-content;
}

.brand-face,
.entry-face,
.mini-face,
.agent-avatar {
  position: relative;
  display: inline-block;
  flex: 0 0 auto;
  border-radius: 50%;
  background: conic-gradient(from 34deg, transparent 0 72deg, var(--green) 74deg 360deg);
  filter: drop-shadow(0 0 12px rgba(69, 238, 120, 0.25));
}

.brand-face {
  width: 32px;
  height: 32px;
}

.brand-face::after,
.entry-face::after,
.mini-face::after,
.agent-avatar::after {
  content: "";
  position: absolute;
  left: 47%;
  top: 21%;
  width: 10%;
  height: 17%;
  border-radius: 999px;
  background: #effff2;
  box-shadow: 0 0 9px rgba(255, 255, 255, 0.7);
  transform: rotate(-9deg);
}

.brand-face i,
.entry-face i,
.mini-face i,
.agent-avatar i {
  position: absolute;
  inset: 8%;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: inset 8px -8px 16px rgba(0, 0, 0, 0.25), inset -4px 4px 10px rgba(255, 255, 255, 0.16);
}

.brand-face b,
.entry-face b,
.mini-face b,
.agent-avatar b {
  position: absolute;
  left: 32%;
  top: 22%;
  width: 8%;
  height: 16%;
  border-radius: 999px;
  background: #effff2;
  transform: rotate(-9deg);
}

.brand-word {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.035em;
}

.brand-tag {
  margin-inline-start: 2px;
  padding: 4px 7px;
  border: 1px solid rgba(69, 238, 120, 0.2);
  border-radius: 999px;
  color: var(--green);
  background: var(--green-soft);
  font: 700 8px/1 var(--font-mono);
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-links a {
  position: relative;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  transition: color 0.2s ease;
}

.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -8px;
  height: 1px;
  background: var(--green);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.25s var(--ease);
}

.nav-links a:hover,
.nav-links a.is-active {
  color: var(--ink);
}

.nav-links a:hover::after,
.nav-links a.is-active::after {
  transform: scaleX(1);
}

.nav-open {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.045);
  font-size: 12px;
  font-weight: 600;
  transition: all 0.25s var(--ease);
}

.nav-open:hover {
  border-color: rgba(69, 238, 120, 0.45);
  background: var(--green-soft);
  transform: translateY(-2px);
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(69, 238, 120, 0.11), 0 0 14px rgba(69, 238, 120, 0.75);
  animation: status-breathe 2.2s ease-in-out infinite;
}

.section {
  width: min(100%, 1600px);
  margin: 0 auto;
  padding: 130px max(34px, calc((100vw - var(--max)) / 2));
}

.hero {
  position: relative;
  min-height: 100vh;
  padding-top: 132px;
  padding-bottom: 92px;
  display: grid;
  grid-template-columns: minmax(0, 0.88fr) minmax(540px, 1.12fr);
  align-items: center;
  gap: clamp(42px, 5vw, 86px);
}

.hero::before {
  content: "";
  position: absolute;
  width: 520px;
  height: 520px;
  top: 4%;
  inset-inline-start: -230px;
  border-radius: 50%;
  background: rgba(69, 238, 120, 0.04);
  filter: blur(80px);
  pointer-events: none;
}

.hero-copy,
.hero-visual,
.section-heading,
.work-copy,
.work-visual,
.memory-copy,
.memory-visual,
.control-copy,
.control-visual,
.entry-copy,
.entry-window {
  position: relative;
  z-index: 3;
}

.eyebrow,
.section-kicker {
  margin: 0 0 22px;
  color: var(--green);
  font: 700 11px/1.3 var(--font-mono);
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 9px 13px;
  border: 1px solid rgba(69, 238, 120, 0.16);
  border-radius: 999px;
  background: rgba(69, 238, 120, 0.055);
}

.eyebrow-pulse {
  width: 9px;
  height: 9px;
  border: 2px solid var(--green);
  border-radius: 50%;
  box-shadow: 0 0 14px rgba(69, 238, 120, 0.7);
}

.hero-title,
.section h2 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.065em;
}

.hero-title {
  font-size: clamp(68px, 7.7vw, 124px);
  line-height: 0.91;
}

.title-line {
  display: block;
  overflow: hidden;
  padding: 0.04em 0.02em 0.08em;
}

.title-line > span {
  display: block;
  transform: translateY(112%);
  transition: transform 1.1s var(--ease);
}

.title-line.is-in > span {
  transform: translateY(0);
}

.title-line:nth-child(2) > span {
  transition-delay: 0.08s;
}

.title-accent,
.section h2 span {
  color: transparent;
  background: linear-gradient(112deg, #effff2 2%, var(--green) 52%, #86a8ff 104%);
  -webkit-background-clip: text;
  background-clip: text;
}

.hero-lede,
.section-heading > p:last-child,
.work-copy > p,
.memory-copy > p,
.control-copy > p,
.entry-copy > p {
  color: var(--ink-soft);
  font-size: 18px;
  line-height: 28px;
}

.hero-lede {
  max-width: 620px;
  margin: 30px 0 0;
}

.hero-actions,
.entry-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 38px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 54px;
  padding: 0 24px;
  border: 1px solid var(--line);
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.28s var(--ease);
}

.button-primary {
  color: #031108;
  border-color: transparent;
  background: linear-gradient(135deg, #67ff94, #34dc6b 62%, #21bd5c);
  box-shadow: 0 15px 40px rgba(34, 208, 95, 0.16), inset 0 1px rgba(255, 255, 255, 0.45);
}

.button-primary:hover {
  box-shadow: 0 22px 55px rgba(34, 208, 95, 0.27), inset 0 1px rgba(255, 255, 255, 0.55);
  transform: translateY(-3px);
}

.button-ghost {
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.035);
}

.button-ghost:hover {
  color: var(--ink);
  border-color: var(--line-strong);
  background: rgba(255, 255, 255, 0.07);
  transform: translateY(-2px);
}

.button-large {
  min-height: 62px;
  padding: 0 28px;
}

.engine-row {
  margin-top: 30px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--faint);
  font: 400 10px/1.5 var(--font-mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.engine-row b {
  color: var(--muted);
  font-weight: 600;
}

.engine-row i {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--faint);
}

.media-shell {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface-solid);
  box-shadow:
    0 50px 120px rgba(0, 0, 0, 0.48),
    inset 0 1px rgba(255, 255, 255, 0.06);
  transform: perspective(1400px) rotateX(var(--tilt-y, 0deg)) rotateY(var(--tilt-x, 0deg));
  transition: transform 0.25s ease-out;
}

.hero-media {
  min-height: clamp(560px, 68vh, 760px);
  border-radius: var(--radius-xl);
}

.hero-media::before,
.feature-media::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.055);
  pointer-events: none;
}

.media-shell > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-media > img {
  position: absolute;
  inset: 0;
  object-position: 58% 50%;
}

.media-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(6, 8, 6, 0.75), transparent 32%),
    linear-gradient(to top, rgba(6, 8, 6, 0.55), transparent 45%);
}

.live-pill {
  position: absolute;
  top: 24px;
  inset-inline-end: 24px;
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  background: rgba(7, 10, 8, 0.66);
  backdrop-filter: blur(14px);
  color: var(--ink-soft);
  font: 700 9px var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.live-pill strong {
  padding-inline-start: 8px;
  border-inline-start: 1px solid var(--line);
  color: var(--ink);
}

.glass-card {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 15px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 16px;
  background: rgba(10, 13, 10, 0.68);
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.35), inset 0 1px rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(16px) saturate(1.3);
  -webkit-backdrop-filter: blur(16px) saturate(1.3);
}

.glass-card small,
.approval-head small,
.computer-overlay header,
.control-badge small {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font: 700 8px/1.2 var(--font-mono);
  letter-spacing: 0.11em;
}

.glass-card strong,
.control-badge strong {
  display: block;
  font-size: 12px;
}

.handoff-card {
  inset-inline-start: 24px;
  bottom: 30px;
  min-width: 250px;
}

.mini-face {
  width: 36px;
  height: 36px;
}

.handoff-arrow {
  margin-inline-start: auto;
  color: var(--green);
}

.activity-card {
  inset-inline-end: 20px;
  bottom: 120px;
  min-width: 205px;
}

.activity-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  color: #061008;
  background: var(--amber);
  font-weight: 900;
}

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--faint);
  font: 700 8px var(--font-mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transform: translateX(-50%);
}

.scroll-cue i {
  position: relative;
  width: 22px;
  height: 34px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
}

.scroll-cue i::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 7px;
  width: 3px;
  height: 7px;
  border-radius: 999px;
  background: var(--green);
  transform: translateX(-50%);
  animation: scroll-dot 1.8s ease-in-out infinite;
}

.principles {
  position: relative;
  z-index: 3;
  width: min(calc(100% - 68px), var(--max));
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(13, 16, 13, 0.84);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.3);
  backdrop-filter: blur(18px);
}

.principles article {
  min-height: 178px;
  padding: 26px;
  border-inline-end: 1px solid var(--line);
}

.principles article:last-child {
  border-inline-end: 0;
}

.principles article > span,
.flow-number {
  color: var(--green);
  font: 700 9px var(--font-mono);
}

.principles strong {
  display: block;
  margin-top: 28px;
  font-family: var(--font-display);
  font-size: 18px;
}

.principles p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 24px;
}

.crew-section,
.work-section,
.memory-section,
.control-section {
  display: grid;
  grid-template-columns: 0.78fr 1.22fr;
  align-items: center;
  gap: clamp(64px, 8vw, 124px);
}

.section-heading {
  max-width: 520px;
}

.section h2 {
  font-size: clamp(48px, 5.6vw, 84px);
  line-height: 1.01;
}

.section-heading > p:last-child,
.work-copy > p,
.memory-copy > p,
.control-copy > p,
.entry-copy > p {
  max-width: 570px;
  margin: 26px 0 0;
}

.crew-board,
.entry-window {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: rgba(15, 18, 15, 0.92);
  box-shadow: 0 45px 110px rgba(0, 0, 0, 0.44), inset 0 1px rgba(255, 255, 255, 0.05);
  transform: perspective(1400px) rotateX(var(--tilt-y, 0deg)) rotateY(var(--tilt-x, 0deg));
  transition: transform 0.25s ease-out;
}

.crew-board::after {
  content: "";
  position: absolute;
  inset-inline-end: -20%;
  bottom: -50%;
  width: 70%;
  height: 80%;
  border-radius: 50%;
  background: rgba(69, 238, 120, 0.06);
  filter: blur(55px);
  pointer-events: none;
}

.crew-board-head,
.entry-window-bar {
  position: relative;
  z-index: 2;
  min-height: 70px;
  padding: 0 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.018);
}

.crew-board-head > div,
.entry-window-bar {
  gap: 16px;
}

.crew-board-head > div,
.window-dots {
  display: flex;
  align-items: center;
}

.window-dots {
  gap: 6px;
}

.window-dots i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #ff665d;
}

.window-dots i:nth-child(2) {
  background: #ffbd4a;
}

.window-dots i:nth-child(3) {
  background: var(--green);
}

.crew-board-head strong,
.entry-window-bar strong {
  font-size: 14px;
}

.crew-count {
  color: var(--muted);
  font: 400 9px var(--font-mono);
}

.crew-list {
  position: relative;
  z-index: 2;
  padding: 16px;
  display: grid;
  gap: 8px;
}

.agent-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 15px;
  min-height: 92px;
  padding: 16px;
  border: 1px solid transparent;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.026);
  transition: all 0.25s var(--ease);
}

.agent-card:hover,
.agent-card-featured {
  border-color: rgba(69, 238, 120, 0.19);
  background: linear-gradient(90deg, rgba(69, 238, 120, 0.08), rgba(255, 255, 255, 0.025));
  transform: translateX(-5px);
}

.agent-avatar {
  width: 52px;
  height: 52px;
}

.face-blue,
.agent-avatar.face-blue {
  background: conic-gradient(from 34deg, transparent 0 72deg, #5b91ff 74deg 360deg);
  filter: drop-shadow(0 0 12px rgba(79, 140, 255, 0.35));
}

.face-amber,
.agent-avatar.face-amber {
  background: conic-gradient(from 34deg, transparent 0 72deg, #ffba51 74deg 360deg);
  filter: drop-shadow(0 0 12px rgba(255, 186, 81, 0.3));
}

.face-violet,
.agent-avatar.face-violet {
  background: conic-gradient(from 34deg, transparent 0 72deg, #aa7cff 74deg 360deg);
  filter: drop-shadow(0 0 12px rgba(170, 124, 255, 0.3));
}

.agent-info {
  min-width: 0;
}

.agent-info strong {
  display: block;
  font-size: 16px;
}

.agent-info span {
  display: block;
  margin-top: 3px;
  overflow: hidden;
  color: var(--muted);
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.agent-state {
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font: 400 9px var(--font-mono);
}

.agent-state i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--amber);
  box-shadow: 0 0 10px rgba(255, 186, 81, 0.5);
}

.agent-state.live i {
  background: var(--green);
  box-shadow: 0 0 10px rgba(69, 238, 120, 0.6);
}

.agent-engine {
  min-width: 58px;
  padding: 6px 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--faint);
  font: 700 7px var(--font-mono);
  letter-spacing: 0.08em;
  text-align: center;
}

.add-agent {
  position: relative;
  z-index: 2;
  width: calc(100% - 32px);
  min-height: 52px;
  margin: 0 16px 16px;
  border: 1px dashed rgba(69, 238, 120, 0.22);
  border-radius: 15px;
  color: var(--muted);
  background: rgba(69, 238, 120, 0.025);
  cursor: pointer;
  transition: all 0.25s var(--ease);
}

.add-agent span {
  color: var(--green);
}

.add-agent:hover,
.add-agent.demo-success {
  color: var(--ink);
  border-color: rgba(69, 238, 120, 0.45);
  background: rgba(69, 238, 120, 0.08);
}

.work-section {
  grid-template-columns: 0.72fr 1.28fr;
}

.proof-stack {
  margin-top: 36px;
  display: grid;
  gap: 12px;
}

.proof-item {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.025);
}

.proof-item > span {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  color: var(--green);
  background: var(--green-soft);
  font: 700 16px var(--font-mono);
}

.proof-item strong,
.proof-item small {
  display: block;
}

.proof-item strong {
  font-size: 16px;
}

.proof-item small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 14px;
}

.feature-media {
  aspect-ratio: 16 / 10;
  border-radius: var(--radius-lg);
}

.feature-media > img {
  position: absolute;
  inset: 0;
  object-position: center;
}

.computer-overlay {
  position: absolute;
  left: 24px;
  right: 24px;
  bottom: 22px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 15px;
  background: rgba(7, 9, 7, 0.72);
  backdrop-filter: blur(14px);
}

.computer-overlay header {
  min-height: 38px;
  margin: 0;
  padding: 0 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}

.computer-overlay header b {
  color: var(--ink-soft);
  font-size: 9px;
  letter-spacing: 0;
}

.live-label {
  margin-inline-start: auto;
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--green);
}

.live-label i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--green);
}

.computer-feed {
  padding: 10px 13px;
}

.computer-feed p {
  margin: 0;
  padding: 4px 0;
  color: var(--muted);
  font: 400 9px var(--font-mono);
}

.computer-feed p > span:first-child {
  margin-inline-end: 12px;
  color: var(--faint);
}

.computer-feed .current {
  color: var(--green);
}

.flow-section {
  padding-top: 150px;
  padding-bottom: 150px;
}

.flow-heading {
  max-width: 760px;
  margin: 0 auto 70px;
  text-align: center;
}

.flow-line {
  display: grid;
  grid-template-columns: 1fr 80px 1fr 80px 1fr;
  align-items: center;
}

.flow-line article {
  position: relative;
  min-height: 330px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.018));
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.04);
}

.flow-line article::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(circle at 70% 20%, rgba(69, 238, 120, 0.08), transparent 45%);
  pointer-events: none;
}

.flow-icon {
  position: relative;
  width: 68px;
  height: 68px;
  margin: 52px 0 24px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  color: var(--green);
  background: rgba(69, 238, 120, 0.07);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.22);
  font: 700 18px var(--font-mono);
}

.route-icon {
  color: var(--blue);
  background: rgba(79, 140, 255, 0.08);
}

.approve-icon {
  color: var(--amber);
  background: rgba(255, 186, 81, 0.08);
}

.flow-line h3 {
  position: relative;
  margin: 0;
  font-family: var(--font-display);
  font-size: 23px;
  line-height: 32px;
}

.flow-line p {
  position: relative;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 24px;
}

.flow-connector {
  position: relative;
  height: 1px;
  overflow: hidden;
  background: var(--line);
}

.flow-connector i {
  position: absolute;
  top: 0;
  left: -30%;
  width: 35%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--green), transparent);
  animation: signal-run 2.2s linear infinite;
}

.memory-section {
  grid-template-columns: 1.16fr 0.84fr;
}

.memory-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(4, 7, 5, 0.5), transparent 44%);
}

.memory-chips {
  position: absolute;
  left: 22px;
  right: 22px;
  bottom: 20px;
  z-index: 3;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.memory-chips span {
  padding: 8px 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 9px;
  color: var(--ink-soft);
  background: rgba(6, 9, 7, 0.67);
  backdrop-filter: blur(12px);
  font: 700 8px var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.context-list {
  margin-top: 34px;
  display: grid;
}

.context-list > span {
  min-height: 52px;
  display: flex;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 16px;
}

.context-list i {
  color: var(--green);
  font: normal 700 8px var(--font-mono);
}

.control-section {
  grid-template-columns: 0.82fr 1.18fr;
}

.approval-card-demo {
  max-width: 480px;
  margin-top: 38px;
  padding: 16px;
  border: 1px solid rgba(255, 186, 81, 0.24);
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(255, 186, 81, 0.08), rgba(255, 255, 255, 0.025));
}

.approval-head {
  display: flex;
  align-items: center;
  gap: 13px;
}

.approval-symbol {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  color: #211304;
  background: var(--amber);
  font-weight: 900;
}

.approval-head strong {
  display: block;
  font-size: 13px;
}

.approval-card-demo > p {
  margin: 16px 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.approval-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.approval-actions button {
  min-height: 42px;
  border-radius: 11px;
  cursor: pointer;
  font-size: 11px;
  font-weight: 600;
}

.deny-button {
  border: 1px solid var(--line);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
}

.allow-button {
  border: 0;
  color: #211304;
  background: var(--amber);
}

.allow-button.demo-success {
  color: #031108;
  background: var(--green);
}

.control-badge {
  inset-inline-start: 22px;
  bottom: 20px;
}

.control-badge > span {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: #061008;
  background: var(--green);
  font-weight: 900;
}

.entry-section {
  position: relative;
  width: min(calc(100% - 68px), var(--max));
  min-height: 760px;
  margin: 90px auto 40px;
  padding: 80px;
  display: grid;
  grid-template-columns: 0.78fr 1.22fr;
  align-items: center;
  gap: 70px;
  overflow: hidden;
  border: 1px solid rgba(69, 238, 120, 0.18);
  border-radius: 44px;
  background:
    linear-gradient(125deg, rgba(69, 238, 120, 0.08), transparent 45%),
    rgba(13, 16, 13, 0.95);
  box-shadow: 0 50px 140px rgba(0, 0, 0, 0.5), inset 0 1px rgba(255, 255, 255, 0.05);
}

.entry-glow {
  position: absolute;
  inset-inline-start: -180px;
  top: -180px;
  width: 520px;
  height: 520px;
  border-radius: 50%;
  background: rgba(69, 238, 120, 0.12);
  filter: blur(90px);
}

.entry-face {
  width: 74px;
  height: 74px;
  margin-bottom: 28px;
}

.entry-copy h2 {
  font-size: clamp(58px, 6.5vw, 92px);
}

.local-note {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--muted);
  font-size: 11px;
}

.local-note i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
}

.entry-window {
  min-height: 520px;
}

.entry-window-bar {
  min-height: 56px;
  justify-content: flex-start;
}

.entry-window-bar > span:last-child {
  margin-inline-start: auto;
  color: var(--muted);
  font: 700 8px var(--font-mono);
  text-transform: uppercase;
}

.entry-window-body {
  min-height: 464px;
  display: grid;
  grid-template-columns: 180px 1fr;
}

.entry-window-body aside {
  padding: 18px 12px;
  display: flex;
  flex-direction: column;
  gap: 7px;
  border-right: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.018);
}

.entry-window-body aside > b {
  padding: 7px 10px 15px;
  color: var(--muted);
  font: 700 8px var(--font-mono);
  text-transform: uppercase;
}

.entry-window-body aside > span {
  min-height: 44px;
  padding: 0 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: 11px;
  color: var(--muted);
  font-size: 11px;
}

.entry-window-body aside > span.active {
  color: var(--ink);
  background: rgba(69, 238, 120, 0.08);
}

.entry-window-body aside i,
.chat-agent i {
  position: relative;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: conic-gradient(from 34deg, transparent 0 72deg, var(--green) 74deg 360deg);
}

.entry-window-body aside i.face-blue {
  background: conic-gradient(from 34deg, transparent 0 72deg, var(--blue) 74deg 360deg);
}

.entry-window-body aside i.face-amber {
  background: conic-gradient(from 34deg, transparent 0 72deg, var(--amber) 74deg 360deg);
}

.entry-chat {
  padding: 22px;
  display: flex;
  flex-direction: column;
  background: rgba(0, 0, 0, 0.11);
}

.chat-agent {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  align-items: center;
  column-gap: 10px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.chat-agent i {
  grid-row: 1 / 3;
  width: 34px;
  height: 34px;
}

.chat-agent span {
  font-size: 12px;
  font-weight: 600;
}

.chat-agent small {
  color: var(--green);
  font: 700 7px var(--font-mono);
  text-transform: uppercase;
}

.chat-bubble {
  max-width: 84%;
  margin-top: 22px;
  padding: 12px 14px;
  border-radius: 14px;
  font-size: 11px;
  line-height: 1.55;
}

.user-bubble {
  align-self: flex-end;
  color: #041008;
  background: var(--green);
  border-bottom-right-radius: 5px;
}

.bot-bubble {
  color: var(--ink-soft);
  background: var(--surface-bright);
  border-bottom-left-radius: 5px;
}

.typing {
  margin-top: 13px;
  display: flex;
  gap: 4px;
}

.typing i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--muted);
  animation: typing 1.2s ease-in-out infinite;
}

.typing i:nth-child(2) {
  animation-delay: 0.12s;
}

.typing i:nth-child(3) {
  animation-delay: 0.24s;
}

.site-footer {
  width: min(calc(100% - 68px), var(--max));
  min-height: 150px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
  border-top: 1px solid var(--line);
}

.site-footer p {
  color: var(--muted);
  font-size: 12px;
}

.site-footer > div {
  justify-self: end;
  display: flex;
  gap: 20px;
}

.site-footer > div a {
  color: var(--muted);
  font-size: 11px;
  transition: color 0.2s;
}

.site-footer > div a:hover {
  color: var(--green);
}

.page-progress {
  position: fixed;
  inset-inline-end: 8px;
  top: 50%;
  z-index: 90;
  width: 2px;
  height: 140px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  transform: translateY(-50%);
}

.page-progress span {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(to bottom, var(--green), var(--blue));
  transform: scaleY(0);
  transform-origin: top;
}

.app-transition {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 22px;
  visibility: hidden;
  opacity: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 50% 44%, rgba(69, 238, 120, 0.18), transparent 24%),
    #050705;
  clip-path: circle(0% at calc(100% - 92px) 48px);
  pointer-events: none;
  transition:
    clip-path 0.62s var(--ease),
    opacity 0.22s ease,
    visibility 0s linear 0.62s;
}

body.is-leaving .app-transition {
  visibility: visible;
  opacity: 1;
  clip-path: circle(150% at calc(100% - 92px) 48px);
  transition:
    clip-path 0.62s var(--ease),
    opacity 0.16s ease,
    visibility 0s;
}

.transition-face {
  position: relative;
  width: 82px;
  height: 82px;
  border-radius: 50%;
  background: conic-gradient(from 34deg, transparent 0 72deg, var(--green) 74deg 360deg);
  filter: drop-shadow(0 0 32px rgba(69, 238, 120, 0.5));
  transform: scale(0.65) rotate(-22deg);
  transition: transform 0.6s var(--ease);
}

body.is-leaving .transition-face {
  transform: scale(1) rotate(0);
}

.transition-face::before,
.transition-face::after {
  content: "";
  position: absolute;
  top: 22%;
  width: 7px;
  height: 15px;
  border-radius: 999px;
  background: #effff2;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.75);
}

.transition-face::before { left: 31%; }
.transition-face::after { left: 49%; }

.app-transition > span {
  font: 700 10px/1 var(--font-mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.transition-line {
  position: relative;
  width: 160px;
  height: 1px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.12);
}

.transition-line::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, var(--green), transparent);
  transform: translateX(-100%);
  animation: transition-run 0.8s ease-in-out infinite;
}

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition:
    opacity 0.85s var(--ease),
    transform 0.85s var(--ease);
}

.reveal.is-in {
  opacity: 1;
  transform: translateY(0);
}

html.preload .site-nav {
  opacity: 0;
  transform: translate(-50%, -18px);
}

html.ready .site-nav {
  opacity: 1;
  transition:
    opacity 0.8s var(--ease),
    transform 0.8s var(--ease),
    top 0.3s var(--ease),
    background 0.3s var(--ease),
    border-color 0.3s var(--ease),
    box-shadow 0.3s var(--ease),
    translate 0.5s var(--ease);
}

@keyframes status-breathe {
  0%, 100% { transform: scale(0.86); opacity: 0.7; }
  50% { transform: scale(1); opacity: 1; }
}

@keyframes scroll-dot {
  0% { transform: translate(-50%, 0); opacity: 0; }
  35% { opacity: 1; }
  100% { transform: translate(-50%, 14px); opacity: 0; }
}

@keyframes signal-run {
  to { left: 110%; }
}

@keyframes typing {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.45; }
  30% { transform: translateY(-4px); opacity: 1; }
}

@keyframes transition-run {
  to { transform: translateX(100%); }
}

@media (max-width: 1180px) {
  .site-nav {
    grid-template-columns: 1fr auto;
  }

  .nav-links {
    display: none;
  }

  .hero {
    grid-template-columns: 1fr;
    padding-top: 150px;
  }

  .hero-copy {
    max-width: 850px;
  }

  .hero-title {
    font-size: clamp(72px, 11vw, 118px);
  }

  .hero-visual {
    width: min(100%, 980px);
    justify-self: center;
  }

  .crew-section,
  .work-section,
  .memory-section,
  .control-section {
    grid-template-columns: 1fr;
  }

  .crew-section .section-heading,
  .work-copy,
  .memory-copy,
  .control-copy {
    max-width: 760px;
  }

  .work-visual,
  .control-visual {
    order: 2;
  }

  .memory-copy {
    order: -1;
  }

  .flow-line {
    grid-template-columns: 1fr 48px 1fr 48px 1fr;
  }

  .entry-section {
    grid-template-columns: 1fr;
  }

  .entry-copy {
    max-width: 760px;
  }
}

@media (max-width: 880px) {
  .section {
    padding-left: 24px;
    padding-right: 24px;
  }

  .principles {
    width: calc(100% - 48px);
    grid-template-columns: 1fr 1fr;
  }

  .principles article:nth-child(2) {
    border-inline-end: 0;
  }

  .principles article:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .flow-line {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .flow-connector {
    width: 1px;
    height: 38px;
    margin-inline-start: 34px;
  }

  .flow-connector i {
    top: -30%;
    left: 0;
    width: 1px;
    height: 35%;
    background: linear-gradient(to bottom, transparent, var(--green), transparent);
    animation-name: signal-run-y;
  }

  .flow-line article {
    min-height: auto;
  }

  .flow-icon {
    margin-top: 36px;
  }

  .entry-section {
    width: calc(100% - 48px);
    padding: 48px 28px;
    border-radius: 32px;
  }

  .entry-window-body {
    grid-template-columns: 140px 1fr;
  }

  .site-footer {
    width: calc(100% - 48px);
    padding: 36px 0;
    grid-template-columns: 1fr auto;
  }

  .site-footer p {
    display: none;
  }
}

@keyframes signal-run-y {
  to { top: 110%; }
}

@media (max-width: 640px) {
  .site-nav {
    top: 10px;
    width: calc(100% - 20px);
    min-height: 58px;
    padding: 8px 9px 8px 13px;
    border-color: var(--line);
    background: rgba(9, 11, 9, 0.72);
    backdrop-filter: blur(16px);
  }

  .brand-tag,
  .nav-open .status-dot {
    display: none;
  }

  .brand-face {
    width: 28px;
    height: 28px;
  }

  .brand-word {
    font-size: 16px;
  }

  .nav-open {
    min-height: 40px;
    padding: 0 12px;
    font-size: 10px;
  }

  .section {
    padding: 96px 18px;
  }

  .hero {
    min-height: auto;
    padding-top: 120px;
    gap: 42px;
  }

  .hero-title {
    font-size: clamp(52px, 16.2vw, 76px);
    letter-spacing: -0.07em;
  }

  .hero-lede,
  .section-heading > p:last-child,
  .work-copy > p,
  .memory-copy > p,
  .control-copy > p,
  .entry-copy > p {
    font-size: 16px;
  }

  .hero-actions,
  .entry-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .engine-row {
    gap: 8px;
  }

  .hero-media {
    min-height: 500px;
    border-radius: 26px;
  }

  .hero-media > img {
    object-position: 64% 50%;
  }

  .handoff-card {
    inset-inline-start: 12px;
    bottom: 14px;
    min-width: min(245px, calc(100% - 24px));
  }

  .activity-card {
    display: none;
  }

  .live-pill {
    top: 12px;
    inset-inline-end: 12px;
  }

  .scroll-cue {
    display: none;
  }

  .principles {
    width: calc(100% - 36px);
    grid-template-columns: 1fr;
  }

  .principles article {
    min-height: 155px;
    border-inline-end: 0;
    border-bottom: 1px solid var(--line);
  }

  .principles article:last-child {
    border-bottom: 0;
  }

  .section h2 {
    font-size: clamp(43px, 13.5vw, 64px);
  }

  .crew-section,
  .work-section,
  .memory-section,
  .control-section {
    gap: 46px;
  }

  .crew-board-head {
    padding: 0 16px;
  }

  .crew-count {
    display: none;
  }

  .agent-card {
    grid-template-columns: auto minmax(0, 1fr) auto;
    min-height: 84px;
    padding: 12px;
  }

  .agent-avatar {
    width: 44px;
    height: 44px;
  }

  .agent-state {
    display: none;
  }

  .agent-engine {
    min-width: 48px;
    padding: 5px;
    font-size: 6px;
  }

  .agent-info span {
    max-width: 155px;
  }

  .feature-media {
    aspect-ratio: 4 / 5;
  }

  .feature-media > img {
    object-position: center;
  }

  .computer-overlay {
    left: 12px;
    right: 12px;
    bottom: 12px;
  }

  .flow-heading {
    text-align: start;
  }

  .memory-chips {
    left: 12px;
    right: 12px;
    bottom: 12px;
  }

  .approval-actions {
    grid-template-columns: 1fr;
  }

  .entry-section {
    width: calc(100% - 24px);
    min-height: auto;
    margin-top: 60px;
    padding: 54px 18px 18px;
    border-radius: 28px;
  }

  .entry-copy h2 {
    font-size: clamp(48px, 15vw, 70px);
  }

  .entry-window {
    min-height: 480px;
  }

  .entry-window-body {
    min-height: 424px;
    grid-template-columns: 1fr;
  }

  .entry-window-body aside {
    display: none;
  }

  .site-footer {
    width: calc(100% - 36px);
    grid-template-columns: 1fr;
  }

  .site-footer > div {
    justify-self: start;
    flex-wrap: wrap;
  }

  .page-progress {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .media-shell,
  .crew-board,
  .entry-window {
    transform: none !important;
  }
}

/* The inline watchdog adds this only if the main module never starts. */
.js-failed .story-shell {
  height: auto;
}

.js-failed .story-sticky {
  position: relative;
  height: auto;
  overflow: visible;
}

.js-failed .story-backgrounds,
.js-failed .story-vignette,
.js-failed .story-chrome {
  display: none;
}

.js-failed .story-track {
  width: 100%;
  height: auto;
  display: block;
  transform: none !important;
}

.js-failed .story-panel.section {
  width: 100%;
  height: auto;
  min-height: 100vh;
  background: var(--bg);
}

.js-failed .story-panel .reveal {
  opacity: 1;
  transform: none;
}

/* --------------------------------------------------------------------------
   Scroll-driven switchboard

   The page still scrolls naturally from top to bottom, but the central stage is
   pinned. That vertical distance advances a five-screen horizontal story while
   the generated PacoBot worlds crossfade behind it.
   -------------------------------------------------------------------------- */

.story-shell {
  position: relative;
  z-index: 4;
  height: 560vh;
  margin-top: 100px;
}

.story-sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  isolation: isolate;
  background: #060706;
}

.story-backgrounds,
.story-background,
.story-vignette {
  position: absolute;
  inset: 0;
}

.story-backgrounds {
  z-index: 0;
  overflow: hidden;
  background: #060706;
}

.story-background {
  margin: 0;
  opacity: 0;
  transform: scale(1.075);
  transition:
    opacity 0.9s ease,
    transform 1.4s var(--ease),
    filter 1.2s ease;
  filter: saturate(0.8) contrast(1.1) brightness(0.45);
  will-change: opacity, transform;
}

.story-background.is-active {
  opacity: 0.52;
  transform: scale(1.025);
  filter: saturate(0.96) contrast(1.08) brightness(0.52);
}

.story-background img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.story-background[data-story-bg="0"] img {
  object-position: 64% 50%;
}

.story-vignette {
  z-index: 1;
  background:
    linear-gradient(90deg, rgba(4, 5, 4, 0.96) 0%, rgba(4, 5, 4, 0.73) 32%, rgba(4, 5, 4, 0.13) 69%, rgba(4, 5, 4, 0.52) 100%),
    linear-gradient(to bottom, rgba(4, 5, 4, 0.72) 0%, transparent 25%, transparent 72%, rgba(4, 5, 4, 0.9) 100%);
  pointer-events: none;
}

.story-track {
  position: relative;
  z-index: 3;
  width: max-content;
  height: 100%;
  display: flex;
  align-items: stretch;
  will-change: transform;
  transform: translate3d(0, 0, 0);
}

.cinema-letterbox {
  position: absolute;
  inset: 0;
  z-index: 18;
  pointer-events: none;
}

.cinema-letterbox i {
  position: absolute;
  left: 0;
  right: 0;
  height: 6.4vh;
  background: #050605;
}

.cinema-letterbox i:first-child {
  top: 0;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}

.cinema-letterbox i:last-child {
  bottom: 0;
  height: 7.2vh;
  box-shadow: 0 -22px 48px rgba(0, 0, 0, 0.4);
}

.cast-chase {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 20;
  height: 32vh;
  min-height: 176px;
  overflow: hidden;
  pointer-events: none;
}

.cast-track {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.cast-actor {
  position: absolute;
  left: 0;
  bottom: 22px;
  display: block;
  filter: drop-shadow(0 16px 14px rgba(0, 0, 0, 0.42));
  will-change: transform;
}

.cast-actor-body {
  display: block;
  width: 100%;
  height: 100%;
  transform-origin: 50% 100%;
}

.cast-actor::after {
  content: "";
  position: absolute;
  left: 18%;
  right: 18%;
  bottom: 4px;
  height: 10px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.35);
  filter: blur(3px);
  transform-origin: 50% 50%;
  animation: cast-shadow 0.42s ease-in-out infinite;
}

.cast-actor[data-cast-depth="front"] {
  width: 112px;
  height: 112px;
}

.cast-actor[data-cast-depth="mid"] {
  width: 84px;
  height: 84px;
  bottom: 36px;
  opacity: 0.96;
}

.cast-actor[data-cast-depth="back"] {
  width: 64px;
  height: 64px;
  bottom: 52px;
  opacity: 0.9;
}

.cast-actor[data-cast-gait="run"] .cast-actor-body {
  animation: cast-run 0.38s cubic-bezier(0.4, 0.05, 0.2, 1) infinite;
}

.cast-actor[data-cast-gait="hop"] .cast-actor-body {
  animation: cast-hop 0.52s cubic-bezier(0.2, 0.8, 0.2, 1) infinite;
}

.cast-actor[data-cast-gait="bounce"] .cast-actor-body {
  animation: cast-bounce 0.62s ease-in-out infinite;
}

.cast-actor[data-cast-gait="glide"] .cast-actor-body {
  animation: cast-glide 0.9s ease-in-out infinite;
}

.cast-actor:nth-child(1) .cast-actor-body,
.cast-actor:nth-child(1)::after { animation-delay: 0s; }
.cast-actor:nth-child(2) .cast-actor-body,
.cast-actor:nth-child(2)::after { animation-delay: -0.11s; }
.cast-actor:nth-child(3) .cast-actor-body,
.cast-actor:nth-child(3)::after { animation-delay: -0.22s; }
.cast-actor:nth-child(4) .cast-actor-body,
.cast-actor:nth-child(4)::after { animation-delay: -0.07s; }
.cast-actor:nth-child(5) .cast-actor-body,
.cast-actor:nth-child(5)::after { animation-delay: -0.31s; }
.cast-actor:nth-child(6) .cast-actor-body,
.cast-actor:nth-child(6)::after { animation-delay: -0.18s; }
.cast-actor:nth-child(7) .cast-actor-body,
.cast-actor:nth-child(7)::after { animation-delay: -0.4s; }
.cast-actor:nth-child(8) .cast-actor-body,
.cast-actor:nth-child(8)::after { animation-delay: -0.26s; }

@keyframes cast-run {
  0% { transform: translateY(0) rotate(-8deg) scaleX(1.08) scaleY(0.9); }
  22% { transform: translateY(-26px) rotate(-3deg) scaleX(0.94) scaleY(1.08); }
  48% { transform: translateY(0) rotate(6deg) scaleX(1.1) scaleY(0.88); }
  74% { transform: translateY(-18px) rotate(-5deg) scaleX(0.95) scaleY(1.06); }
  100% { transform: translateY(0) rotate(-8deg) scaleX(1.08) scaleY(0.9); }
}

@keyframes cast-hop {
  0%, 12% { transform: translateY(0) rotate(-4deg) scaleX(1.12) scaleY(0.86); }
  38% { transform: translateY(-38px) rotate(8deg) scaleX(0.9) scaleY(1.12); }
  62% { transform: translateY(-8px) rotate(-2deg) scaleX(1.04) scaleY(0.94); }
  100% { transform: translateY(0) rotate(-4deg) scaleX(1.12) scaleY(0.86); }
}

@keyframes cast-bounce {
  0%, 100% { transform: translateY(0) rotate(-6deg) scale(1); }
  40% { transform: translateY(-30px) rotate(7deg) scale(1.06); }
  58% { transform: translateY(-4px) rotate(-2deg) scale(0.96); }
}

@keyframes cast-glide {
  0%, 100% { transform: translateY(0) rotate(-3deg); }
  50% { transform: translateY(-14px) rotate(4deg); }
}

@keyframes cast-shadow {
  0%, 100% { transform: scaleX(1); opacity: 0.4; }
  40% { transform: scaleX(0.45); opacity: 0.18; }
}

.story-panel.section {
  flex: 0 0 100vw;
  width: 100vw;
  max-width: none;
  height: 100%;
  min-height: 0;
  margin: 0;
  padding: 104px max(42px, calc((100vw - var(--max)) / 2)) 168px;
  overflow: hidden;
}

.story-panel .section-heading,
.story-panel .work-copy,
.story-panel .memory-copy,
.story-panel .control-copy {
  text-shadow: 0 12px 35px rgba(0, 0, 0, 0.8);
}

.story-panel .reveal {
  opacity: 0;
  transform: translate3d(86px, 0, 0) scale(0.985);
  transition:
    opacity 0.52s ease,
    transform 0.78s var(--ease);
}

.story-panel .reveal:nth-child(2) {
  transition-delay: 0.08s;
}

.story-panel.is-active .reveal {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

.story-panel:not(.is-active) [data-tilt] {
  --tilt-x: 0deg !important;
  --tilt-y: 0deg !important;
}

.story-panel .crew-board,
.story-panel .media-shell,
.story-panel .approval-card-demo,
.story-panel .flow-line article {
  background-color: rgba(10, 13, 11, 0.76);
  backdrop-filter: blur(18px) saturate(1.15);
  -webkit-backdrop-filter: blur(18px) saturate(1.15);
}

.story-panel .feature-media > img {
  opacity: 0.9;
}

.story-chrome {
  position: absolute;
  inset: 0;
  z-index: 19;
  pointer-events: none;
  color: rgba(214, 226, 216, 0.5);
  font: 700 8px/1 var(--font-mono);
  letter-spacing: 0.16em;
}

.story-index {
  position: absolute;
  inset-inline-start: 24px;
  top: 50%;
  display: grid;
  justify-items: center;
  gap: 10px;
  transform: translateY(-50%);
}

.story-index span:first-child {
  color: var(--green);
}

.story-index i {
  width: 1px;
  height: 72px;
  overflow: hidden;
  background: linear-gradient(to bottom, var(--green) var(--story-progress, 0%), rgba(255, 255, 255, 0.13) var(--story-progress, 0%));
}

.story-direction {
  position: absolute;
  left: 50%;
  top: 9vh;
  display: flex;
  align-items: center;
  gap: 12px;
  transform: translateX(-50%);
}

.story-direction i {
  position: relative;
  width: 74px;
  height: 1px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.15);
}

.story-direction i::after {
  content: "";
  position: absolute;
  left: -25%;
  top: 0;
  width: 28%;
  height: 100%;
  background: linear-gradient(90deg, transparent, var(--green));
  animation: story-signal 1.8s linear infinite;
}

.story-direction b {
  color: rgba(238, 246, 239, 0.78);
  font-weight: 600;
}

.story-dots {
  position: absolute;
  inset-inline-end: 24px;
  top: 50%;
  display: grid;
  gap: 11px;
  transform: translateY(-50%);
}

.story-dots i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.35);
  transition: all 0.3s var(--ease);
}

.story-dots i.is-active {
  height: 22px;
  border-radius: 999px;
  border-color: var(--green);
  background: var(--green);
  box-shadow: 0 0 15px rgba(69, 238, 120, 0.65);
}

.story-panel.flow-section {
  display: grid;
  align-content: center;
  padding-top: 92px;
  padding-bottom: 70px;
}

.story-panel .flow-heading {
  margin-bottom: 38px;
}

.story-panel .flow-line article {
  min-height: 285px;
}

.story-panel .flow-icon {
  margin-top: 34px;
}

@keyframes story-signal {
  to { left: 110%; }
}

@media (max-width: 1180px) {
  .story-panel.section {
    padding-left: 72px;
    padding-right: 72px;
  }

  .story-panel.crew-section,
  .story-panel.work-section,
  .story-panel.memory-section,
  .story-panel.control-section {
    grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
    gap: 46px;
  }

  .story-panel .section h2,
  .story-panel h2 {
    font-size: clamp(43px, 5.3vw, 68px);
  }

  .story-panel .proof-stack {
    margin-top: 24px;
  }

  .story-panel .proof-item {
    padding: 10px;
  }

  .story-panel .feature-media {
    aspect-ratio: 16 / 11;
  }
}

@media (max-width: 820px) {
  .story-shell {
    height: 520vh;
    margin-top: 60px;
  }

  .story-panel.section {
    padding: 88px 30px 58px;
  }

  .story-panel.crew-section,
  .story-panel.work-section,
  .story-panel.memory-section,
  .story-panel.control-section {
    grid-template-columns: 1fr 1fr;
    gap: 26px;
  }

  .story-panel .section-heading > p:last-child,
  .story-panel .work-copy > p,
  .story-panel .memory-copy > p,
  .story-panel .control-copy > p {
    margin-top: 16px;
    font-size: 14px;
    line-height: 1.5;
  }

  .story-panel .section-kicker {
    margin-bottom: 14px;
    font-size: 9px;
  }

  .story-panel .crew-board {
    transform: none;
  }

  .story-panel .agent-card {
    min-height: 68px;
  }

  .story-panel .agent-avatar {
    width: 38px;
    height: 38px;
  }

  .story-panel .agent-info span,
  .story-panel .agent-state {
    display: none;
  }

  .story-panel .proof-item:last-child {
    display: none;
  }

  .story-panel .flow-heading {
    margin: 0 0 24px;
    text-align: start;
  }

  .story-panel .flow-line {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }

  .story-panel .flow-connector {
    display: none;
  }

  .story-panel .flow-line article {
    min-height: 290px;
    padding: 18px;
  }

  .story-panel .flow-icon {
    margin: 34px 0 20px;
  }

  .story-index,
  .story-dots {
    display: none;
  }

  .story-direction {
    bottom: 15px;
  }
}

@media (max-width: 640px) {
  html.ready #scene {
    opacity: 0.38;
  }

  .story-shell {
    height: 540vh;
  }

  .story-panel.section {
    padding: 78px 18px 46px;
  }

  .story-panel.crew-section,
  .story-panel.work-section,
  .story-panel.memory-section,
  .story-panel.control-section {
    grid-template-columns: 1fr;
    align-content: center;
    gap: 20px;
  }

  .story-panel .section-heading,
  .story-panel .work-copy,
  .story-panel .memory-copy,
  .story-panel .control-copy {
    max-width: 100%;
  }

  .story-panel h2,
  .story-panel .section h2 {
    font-size: clamp(38px, 12vw, 52px);
    line-height: 0.98;
  }

  .story-panel .section-heading > p:last-child,
  .story-panel .work-copy > p,
  .story-panel .memory-copy > p,
  .story-panel .control-copy > p {
    display: none;
  }

  .story-panel .crew-board-head {
    min-height: 46px;
  }

  .story-panel .crew-list {
    padding: 8px;
    gap: 5px;
  }

  .story-panel .agent-card {
    min-height: 60px;
    padding: 8px 10px;
  }

  .story-panel .agent-card:nth-child(4) {
    display: none;
  }

  .story-panel .add-agent {
    min-height: 42px;
    margin-bottom: 10px;
  }

  .story-panel .proof-stack {
    grid-template-columns: 1fr 1fr;
    margin-top: 18px;
  }

  .story-panel .proof-item {
    gap: 9px;
  }

  .story-panel .proof-item > span {
    width: 34px;
    height: 34px;
  }

  .story-panel .proof-item small {
    display: none;
  }

  .story-panel .feature-media {
    height: min(34vh, 280px);
    aspect-ratio: auto;
  }

  .story-panel .computer-feed p:nth-child(-n + 2) {
    display: none;
  }

  .story-panel.flow-section {
    align-content: center;
  }

  .story-panel .flow-line {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  .story-panel .flow-line article {
    min-height: 0;
    padding: 12px 14px;
    padding-inline-start: 58px;
  }

  .story-panel .flow-number {
    position: absolute;
    inset-inline-end: 12px;
    top: 12px;
  }

  .story-panel .flow-icon {
    position: absolute;
    inset-inline-start: 12px;
    top: 50%;
    width: 34px;
    height: 34px;
    margin: 0;
    border-radius: 10px;
    transform: translateY(-50%);
  }

  .story-panel .flow-line h3 {
    font-size: 13px;
  }

  .story-panel .flow-line p {
    margin-top: 4px;
    font-size: 10px;
    line-height: 1.4;
  }

  .story-panel.memory-section .memory-visual {
    order: 2;
  }

  .story-panel .context-list {
    display: none;
  }

  .story-panel .approval-card-demo {
    margin-top: 18px;
    padding: 13px;
  }

  .story-panel .approval-card-demo > p {
    display: none;
  }

  .story-panel.control-section .control-visual {
    display: none;
  }

  .story-background img {
    object-position: 62% center;
  }

  .story-vignette {
    background:
      linear-gradient(to right, rgba(4, 5, 4, 0.92), rgba(4, 5, 4, 0.48)),
      linear-gradient(to bottom, rgba(4, 5, 4, 0.75), transparent 40%, rgba(4, 5, 4, 0.88));
  }

  .story-direction span {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .story-shell {
    height: auto;
  }

  .story-sticky {
    position: relative;
    height: auto;
    overflow: visible;
  }

  .story-backgrounds,
  .story-vignette,
  .story-chrome {
    display: none;
  }

  .story-track {
    width: 100%;
    height: auto;
    display: block;
    transform: none !important;
  }

  .story-panel.section {
    width: 100%;
    height: auto;
    min-height: 100vh;
    background: var(--bg);
  }

  .story-panel .reveal {
    opacity: 1;
    transform: none;
  }
}

/* ========================================================================== 
   PacoBot journey refinement — real cast, GSAP stage, gaze hero, workspace
   ========================================================================== */

[data-lucide],
.lucide {
  width: 1em;
  height: 1em;
  display: block;
  fill: none;
  stroke: currentColor;
}

/* Source-derived PacoBot cast --------------------------------------------- */

.paco-vector {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 8px 13px rgba(0, 0, 0, 0.36));
}

.paco-vector-glint,
.paco-vector-shade,
.paco-vector-brow,
.paco-vector-lip,
.paco-vector-rim,
.paco-vector-wake,
.paco-vector-stems {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.paco-vector-glint {
  stroke: rgba(255, 255, 255, 0.44);
  stroke-width: 6;
}

.paco-vector-shade {
  stroke: rgba(0, 0, 0, 0.3);
  stroke-width: 10;
}

.paco-vector-brow {
  stroke: rgba(0, 0, 0, 0.44);
  stroke-width: 7;
}

.paco-vector-lip {
  stroke: rgba(255, 255, 255, 0.72);
  stroke-width: 7;
}

.paco-vector-cheek {
  fill: rgba(255, 214, 224, 0.36);
}

.paco-vector-bow path,
.paco-vector-bow circle {
  stroke: rgba(0, 0, 0, 0.26);
  stroke-width: 3;
}

.paco-vector-jaw {
  transform-origin: 114.2705px 114.2705px;
  transform-box: view-box;
}

.paco-vector-jaw-top {
  animation: paco-jaw-top 0.74s ease-in-out infinite;
}

.paco-vector-jaw-bottom {
  animation: paco-jaw-bottom 0.74s ease-in-out infinite;
}

.paco-vector-float {
  animation: paco-cast-float 1.35s ease-in-out infinite alternate;
}

.paco-vector-pinky { animation-duration: 1.6s; }
.paco-vector-inky { animation-duration: 1.15s; }
.paco-vector-clyde { animation-duration: 1.95s; }
.paco-vector-eyes { animation-duration: 0.95s; }

.paco-vector-frame-b {
  opacity: 0;
  animation: paco-hem-frame 0.44s steps(1, end) infinite;
}

.paco-vector-rim {
  stroke: rgba(225, 240, 255, 0.48);
  stroke-width: 4;
}

.paco-vector-wake {
  stroke: rgba(119, 166, 255, 0.58);
  stroke-width: 5;
}

.paco-vector-stems {
  stroke: #37bd76;
  stroke-width: 9;
}

.paco-vector-pulse {
  transform-origin: 120px 140px;
  animation: paco-cherry-pulse 1.15s ease-in-out infinite alternate;
}

.paco-vector-sparks {
  opacity: 0.76;
  animation: paco-spark 0.85s ease-out infinite;
}

@keyframes paco-jaw-top {
  0%, 100% { transform: rotate(-5deg); }
  50% { transform: rotate(-20deg); }
}

@keyframes paco-jaw-bottom {
  0%, 100% { transform: rotate(5deg); }
  50% { transform: rotate(20deg); }
}

@keyframes paco-cast-float {
  to { transform: translate3d(4px, -7px, 0); }
}

@keyframes paco-hem-frame {
  50% { opacity: 1; }
}

@keyframes paco-cherry-pulse {
  to { transform: scale(1.055); }
}

@keyframes paco-spark {
  to { opacity: 0; transform: translateX(14px); }
}

.agent-avatar[data-paco-character] {
  border-radius: 0;
  background: none;
  filter: none;
}

.agent-avatar[data-paco-character]::after {
  display: none;
}

/* First-screen gaze rig ---------------------------------------------------- */

.hero-media {
  isolation: isolate;
  background: #020504;
}

.hero-parallax-rig,
.hero-gaze-rig {
  position: absolute;
  inset: -3%;
}

.hero-parallax-rig {
  z-index: 0;
}

.hero-gaze-rig {
  overflow: hidden;
  transform: scale(1.025);
  transform-origin: 50% 50%;
}

.hero-scene-base,
.hero-head-canvas,
.hero-mouth-canvas,
.hero-gaze-eyes {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
  pointer-events: none;
}

.hero-scene-base {
  z-index: 0;
}

.hero-head-canvas {
  z-index: 1;
  -webkit-mask-image: radial-gradient(ellipse 31% 48% at 69% 48%, #000 76%, rgba(0, 0, 0, 0.92) 88%, transparent 100%);
  mask-image: radial-gradient(ellipse 31% 48% at 69% 48%, #000 76%, rgba(0, 0, 0, 0.92) 88%, transparent 100%);
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  will-change: contents;
}

.hero-mouth-canvas {
  z-index: 2;
  opacity: 0;
  -webkit-mask-image: radial-gradient(ellipse 31% 26% at 67% 68%, #000 54%, rgba(0, 0, 0, 0.9) 72%, transparent 100%);
  mask-image: radial-gradient(ellipse 31% 26% at 67% 68%, #000 54%, rgba(0, 0, 0, 0.9) 72%, transparent 100%);
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  transition: opacity 0.38s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: contents, opacity;
}

.hero-frame-sources {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.hero-follow-light {
  position: absolute;
  z-index: 3;
  left: 55%;
  top: 8%;
  width: 44%;
  aspect-ratio: 1;
  border-radius: 50%;
  opacity: 0.3;
  pointer-events: none;
  mix-blend-mode: screen;
  background: radial-gradient(circle, rgba(98, 255, 208, 0.26), rgba(29, 211, 255, 0.08) 34%, transparent 70%);
  filter: blur(22px);
  clip-path: ellipse(72% 76% at 50% 50%);
  will-change: transform;
}

.hero-gaze-eyes {
  z-index: 4;
  pointer-events: none;
  will-change: transform;
}

.hero-eye-lens {
  transform-box: fill-box;
  transform-origin: center;
  will-change: transform;
}

.hero-media .media-shade {
  z-index: 5;
  background:
    linear-gradient(90deg, rgba(2, 5, 4, 0.78), transparent 36%),
    linear-gradient(to top, rgba(2, 5, 4, 0.66), transparent 46%);
}

.hero-media .live-pill,
.hero-media .glass-card {
  z-index: 6;
}

/* Mascot runway ----------------------------------------------------------- */

.mascot-runway {
  position: relative;
  z-index: 5;
  width: min(calc(100% - 68px), var(--max));
  height: 214px;
  margin: 82px auto 0;
  overflow: hidden;
  border: 1px solid rgba(159, 255, 189, 0.13);
  border-radius: 28px;
  background:
    radial-gradient(460px 170px at 72% 50%, rgba(69, 238, 120, 0.09), transparent 70%),
    linear-gradient(110deg, rgba(10, 14, 11, 0.98), rgba(5, 8, 6, 0.92));
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.04), 0 30px 90px rgba(0, 0, 0, 0.3);
}

.mascot-runway::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.26;
  background-image:
    linear-gradient(rgba(214, 239, 220, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(214, 239, 220, 0.055) 1px, transparent 1px);
  background-size: 38px 38px;
  mask-image: linear-gradient(90deg, #000, transparent 44%);
}

.runway-copy {
  position: absolute;
  z-index: 4;
  inset-inline-start: 28px;
  top: 50%;
  width: 280px;
  transform: translateY(-50%);
}

.runway-copy span {
  display: block;
  margin-bottom: 10px;
  color: var(--green);
  font: 700 8px/1 var(--font-mono);
  letter-spacing: 0.15em;
}

.runway-copy strong {
  display: block;
  max-width: 250px;
  font-family: var(--font-display);
  font-size: 22px;
  line-height: 1.15;
  letter-spacing: -0.035em;
}

.runway-viewport {
  position: absolute;
  z-index: 2;
  inset: 0;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent 22%, #000 35%, #000 92%, transparent);
}

.runway-track-line {
  position: absolute;
  left: 24%;
  right: 0;
  top: 67%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(69, 238, 120, 0.42), rgba(93, 184, 255, 0.3), transparent);
  box-shadow: 0 0 18px rgba(69, 238, 120, 0.2);
}

.runway-track-line::after {
  content: "";
  position: absolute;
  inset: -3px auto auto 45%;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #baffcd;
  box-shadow: 0 0 16px var(--green);
}

.mascot-pack {
  position: absolute;
  left: 0;
  top: 62px;
  width: max-content;
  display: flex;
  align-items: flex-end;
  gap: 13px;
  will-change: transform;
}

.mascot-pack-two {
  top: 80px;
}

.runway-mascot {
  display: block;
  width: 76px;
  height: 76px;
  flex: 0 0 auto;
  transform-origin: 50% 100%;
}

.runway-mascot:nth-child(2n) {
  width: 68px;
  height: 68px;
}

/* GSAP owns the pin when available; the original sticky/manual choreography
   below remains the no-network fallback. */
.gsap-story .story-shell {
  height: auto;
}

html.gsap-story {
  scroll-behavior: auto;
}

.gsap-story .story-sticky {
  position: relative;
  top: auto;
}

/* Better proof and journey icons ----------------------------------------- */

.proof-item > .proof-mascot,
.proof-item > .proof-mascot-pair {
  flex: 0 0 46px;
  width: 46px;
  height: 46px;
  padding: 4px;
  border-radius: 14px;
  background: rgba(69, 238, 120, 0.075);
}

.proof-mascot-pair {
  position: relative;
  display: block !important;
}

.proof-mascot-pair > i {
  position: absolute;
  display: block;
  width: 30px;
  height: 30px;
}

.proof-mascot-pair > i:first-child {
  left: 1px;
  top: 4px;
}

.proof-mascot-pair > i:last-child {
  right: 1px;
  bottom: 3px;
}

.flow-icon .lucide {
  width: 25px;
  height: 25px;
}

/* Cute Paco cursor -------------------------------------------------------- */

.cur-halo,
.cur-body,
.cur-core,
.cur-trail {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 10000;
  pointer-events: none;
}

.cur-halo {
  width: 48px;
  height: 48px;
  border: 1px solid rgba(141, 255, 176, 0.58);
  border-radius: 50%;
  box-shadow: 0 0 26px rgba(69, 238, 120, 0.2), inset 0 0 18px rgba(69, 238, 120, 0.08);
  opacity: 0.28;
}

.cur-body {
  width: 30px;
  height: 30px;
  transform-origin: 50% 50%;
  will-change: transform;
}

.cur-mascot {
  display: block;
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 4px 9px rgba(35, 255, 105, 0.45));
}

.cur-core {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #f5fff8;
  box-shadow: 0 0 11px rgba(164, 255, 193, 0.9);
}

.cur-trail {
  inset: 0;
  width: 100vw;
  height: 100vh;
}

@media (hover: hover) and (pointer: fine) {
  html.has-custom-cursor body,
  html.has-custom-cursor a,
  html.has-custom-cursor button {
    cursor: none;
  }

  html.has-custom-cursor input {
    cursor: text;
  }
}

/* Entry portal and accurate PacoBot workspace ---------------------------- */

.entry-section {
  width: min(calc(100% - 40px), 1440px);
  min-height: 860px;
  padding: 58px;
  grid-template-columns: minmax(300px, 0.62fr) minmax(670px, 1.38fr);
  gap: 46px;
  border-color: rgba(111, 255, 156, 0.17);
  background: #070707;
}

.entry-portal-scene {
  position: absolute;
  z-index: 0;
  inset: 0;
  margin: 0;
  opacity: 0.3;
  pointer-events: none;
  mask-image: linear-gradient(90deg, rgba(0, 0, 0, 0.72), transparent 54%, rgba(0, 0, 0, 0.48));
}

.entry-portal-scene::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(7, 7, 7, 0.98) 0%, rgba(7, 7, 7, 0.63) 38%, rgba(7, 7, 7, 0.25) 72%, rgba(7, 7, 7, 0.7) 100%),
    linear-gradient(to bottom, rgba(7, 7, 7, 0.6), transparent 45%, rgba(7, 7, 7, 0.88));
}

.entry-portal-scene img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.entry-copy,
.workspace-shell {
  z-index: 2;
}

.workspace-shell.entry-window {
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  min-height: 650px;
  overflow: hidden;
  border: 1px solid #333;
  border-radius: 22px;
  color: #fcfcfc;
  background: #070707;
  box-shadow: 0 55px 130px rgba(0, 0, 0, 0.64), inset 0 1px rgba(255, 255, 255, 0.045);
  font-family: Inter, var(--font-body);
}

.workspace-shell button,
.workspace-shell input {
  border: 0;
  color: inherit;
  background: none;
  outline: none;
}

.workspace-shell button {
  cursor: pointer;
}

.workspace-sidebar {
  min-width: 0;
  display: flex;
  flex-direction: column;
  border-inline-end: 1px solid #2a2a2a;
  background: #111;
}

.workspace-osbar {
  min-height: 52px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.workspace-osbar .window-dots i {
  width: 8px;
  height: 8px;
}

.workspace-osbar > button,
.workspace-tools button,
.workspace-composer > button {
  display: grid;
  place-items: center;
  border: 1px solid #333;
  color: rgba(252, 252, 252, 0.62);
  background: #191919;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.workspace-osbar > button {
  width: 28px;
  height: 28px;
  border-radius: 8px;
}

.workspace-osbar > button:hover,
.workspace-tools button:hover,
.workspace-composer > button:hover {
  color: #fcfcfc;
  border-color: #4a4a4a;
  background: #262626;
}

.workspace-tabs {
  margin: 0 12px 10px;
  padding: 3px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid #2c2c2c;
  border-radius: 10px;
  background: #191919;
}

.workspace-tabs button {
  min-height: 30px;
  border-radius: 7px;
  color: rgba(252, 252, 252, 0.54);
  font-size: 10px;
  font-weight: 600;
}

.workspace-tabs button.is-active {
  color: #fcfcfc;
  background: #2f2f2f;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
}

.workspace-search {
  min-height: 36px;
  margin: 0 12px 10px;
  padding: 0 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #2f2f2f;
  border-radius: 10px;
  color: rgba(252, 252, 252, 0.38);
  background: #191919;
}

.workspace-search .lucide {
  width: 13px;
  height: 13px;
}

.workspace-search input {
  width: 100%;
  min-width: 0;
  color: #fcfcfc;
  font-size: 10px;
}

.workspace-search input::placeholder {
  color: rgba(252, 252, 252, 0.34);
}

.workspace-agent-list {
  min-height: 0;
  padding: 2px 8px 12px;
  display: grid;
  align-content: start;
  gap: 3px;
  overflow: auto;
}

.workspace-agent-row {
  width: 100%;
  min-height: 58px;
  padding: 7px 8px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  border-radius: 10px !important;
  text-align: start;
  transition: background 0.18s ease;
}

.workspace-agent-row:hover,
.workspace-agent-row.is-active {
  background: #262626;
}

.workspace-agent-row.is-active {
  box-shadow: inset 2px 0 #1084fe;
}

.workspace-agent-avatar,
.workspace-header-avatar,
.message-agent-avatar,
.workspace-mini-avatar,
.workspace-handoff > span {
  display: block;
}

.workspace-agent-avatar {
  width: 36px;
  height: 36px;
}

.workspace-agent-copy {
  min-width: 0;
}

.workspace-agent-copy strong,
.workspace-agent-copy small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-agent-copy strong {
  font-size: 10px;
  font-weight: 600;
}

.workspace-agent-copy small {
  margin-top: 4px;
  color: rgba(252, 252, 252, 0.44);
  font-size: 8px;
}

.workspace-agent-meta {
  align-self: stretch;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: space-between;
}

.workspace-agent-meta small {
  color: rgba(252, 252, 252, 0.34);
  font-size: 7px;
}

.workspace-agent-meta i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #1084fe;
  box-shadow: 0 0 8px rgba(16, 132, 254, 0.55);
}

.workspace-sidebar-footer {
  margin-top: auto;
  padding: 8px;
  border-top: 1px solid #292929;
  display: grid;
  gap: 2px;
}

.workspace-sidebar-footer button {
  width: 100%;
  min-height: 36px;
  padding: 0 8px;
  display: grid;
  grid-template-columns: 20px 1fr auto;
  align-items: center;
  gap: 7px;
  border-radius: 8px !important;
  color: rgba(252, 252, 252, 0.55);
  text-align: start;
  font-size: 9px;
}

.workspace-sidebar-footer button:hover,
.workspace-sidebar-footer button.is-current {
  color: #fcfcfc;
  background: #262626;
}

.workspace-sidebar-footer .lucide {
  width: 14px;
  height: 14px;
}

.workspace-sidebar-footer b {
  min-width: 18px;
  padding: 3px 5px;
  border-radius: 999px;
  color: #a8d5ff;
  background: rgba(16, 132, 254, 0.14);
  font-size: 7px;
  text-align: center;
}

.workspace-mini-avatar {
  width: 20px;
  height: 20px;
}

.workspace-chat {
  min-width: 0;
  min-height: 0;
  display: grid;
  grid-template-rows: 64px minmax(0, 1fr) auto;
  background: #070707;
}

.workspace-chat-header {
  padding: 0 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid #2b2b2b;
  background: rgba(17, 17, 17, 0.92);
}

.workspace-header-avatar {
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
}

.workspace-chat-title {
  min-width: 80px;
}

.workspace-chat-title strong,
.workspace-chat-title small {
  display: block;
}

.workspace-chat-title strong {
  font-size: 11px;
}

.workspace-chat-title small {
  margin-top: 3px;
  color: rgba(252, 252, 252, 0.42);
  font-size: 7px;
}

.workspace-chat-title small i {
  display: inline-block;
  width: 5px;
  height: 5px;
  margin-inline-end: 4px;
  border-radius: 50%;
  background: #38d591;
  box-shadow: 0 0 7px rgba(56, 213, 145, 0.55);
}

.workspace-model {
  min-height: 28px;
  margin-inline-start: auto;
  padding: 0 9px !important;
  display: flex;
  align-items: center;
  gap: 6px;
  border: 1px solid #333 !important;
  border-radius: 8px !important;
  color: rgba(252, 252, 252, 0.62) !important;
  background: #191919 !important;
  font-size: 8px;
}

.workspace-model .lucide {
  width: 10px;
  height: 10px;
}

.workspace-tools {
  display: flex;
  gap: 5px;
}

.workspace-tools button {
  width: 30px;
  height: 30px;
  border-radius: 8px;
}

.workspace-tools .lucide {
  width: 13px;
  height: 13px;
}

.workspace-thread {
  min-height: 0;
  padding: 20px 22px 14px;
  display: flex;
  flex-direction: column;
  overflow: auto;
  background:
    radial-gradient(420px 260px at 70% 18%, rgba(16, 132, 254, 0.045), transparent 68%),
    #070707;
}

.workspace-thread-day {
  align-self: center;
  margin-bottom: 24px;
  color: rgba(252, 252, 252, 0.3);
  font-size: 7px;
}

.workspace-message {
  max-width: 78%;
  font-size: 10px;
  line-height: 1.55;
}

.workspace-message-user {
  align-self: flex-end;
  padding: 10px 12px;
  border: 1px solid #383838;
  border-radius: 13px 13px 4px 13px;
  color: rgba(252, 252, 252, 0.84);
  background: #262626;
}

.workspace-message-user.is-new {
  margin-top: 10px;
  animation: workspace-message-in 0.36s var(--ease) both;
}

.workspace-message-agent {
  max-width: 88%;
  margin-top: 20px;
  display: grid;
  grid-template-columns: 32px minmax(0, 1fr);
  gap: 10px;
}

.message-agent-avatar {
  width: 30px;
  height: 30px;
}

.workspace-message-agent small {
  color: rgba(252, 252, 252, 0.36);
  font-size: 7px;
}

.workspace-message-agent p {
  margin: 6px 0 0;
  color: rgba(252, 252, 252, 0.76);
}

.workspace-handoff {
  margin-top: 10px;
  padding: 9px;
  display: grid;
  grid-template-columns: 24px 12px 24px minmax(0, 1fr) auto;
  align-items: center;
  gap: 5px;
  border: 1px solid #303030;
  border-radius: 10px;
  background: #111;
}

.workspace-handoff > span {
  width: 24px;
  height: 24px;
}

.workspace-handoff .lucide {
  width: 10px;
  height: 10px;
  color: rgba(252, 252, 252, 0.3);
}

.workspace-handoff strong {
  font-size: 8px;
  font-weight: 650;
}

.workspace-handoff > small {
  color: #38d591;
  font-size: 6px;
  white-space: nowrap;
}

.workspace-status {
  margin-top: auto;
  padding-top: 16px;
  display: flex;
  align-items: center;
  gap: 7px;
  color: rgba(252, 252, 252, 0.32);
  font-size: 7px;
}

.workspace-status i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #38d591;
  animation: status-pulse 1.5s ease-in-out infinite;
}

.workspace-composer {
  min-height: 56px;
  margin: 0 16px 16px;
  padding: 7px 8px;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) 30px;
  align-items: center;
  gap: 6px;
  border: 1px solid #333;
  border-radius: 14px;
  background: #191919;
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.26);
}

.workspace-composer > button {
  width: 30px;
  height: 30px;
  border-radius: 9px;
}

.workspace-composer > button:first-child {
  border-color: transparent;
  background: transparent;
}

.workspace-composer .lucide {
  width: 13px;
  height: 13px;
}

.workspace-composer input {
  min-width: 0;
  font-size: 10px;
}

.workspace-composer input::placeholder {
  color: rgba(252, 252, 252, 0.32);
}

.workspace-send {
  color: #061a10 !important;
  border-color: #38d591 !important;
  background: #38d591 !important;
}

@keyframes workspace-message-in {
  from { opacity: 0; transform: translate3d(18px, 8px, 0); }
}

/* Responsive journey ------------------------------------------------------ */

@media (max-width: 1180px) {
  .entry-section {
    grid-template-columns: 1fr;
    padding: 52px;
  }

  .entry-copy {
    max-width: 720px;
  }

  .workspace-shell.entry-window {
    width: 100%;
  }
}

@media (max-width: 880px) {
  .mascot-runway {
    width: calc(100% - 48px);
    height: 190px;
  }

  .runway-copy {
    inset-inline-start: 20px;
    width: 220px;
  }

  .runway-copy strong {
    font-size: 18px;
  }

  .runway-mascot {
    width: 62px;
    height: 62px;
  }

  .entry-section {
    width: calc(100% - 48px);
    padding: 42px 28px;
  }

  .workspace-shell.entry-window {
    grid-template-columns: 210px minmax(0, 1fr);
  }
}

@media (max-width: 640px) {
  .cast-chase {
    height: 20vh;
    min-height: 112px;
  }

  .cast-actor[data-cast-depth="front"] {
    width: 72px;
    height: 72px;
  }

  .cast-actor[data-cast-depth="mid"] {
    width: 58px;
    height: 58px;
  }

  .cast-actor[data-cast-depth="back"] {
    width: 46px;
    height: 46px;
  }

  .story-panel.section {
    padding-bottom: 132px;
  }

  .hero-media {
    min-height: 480px;
  }

  .hero-gaze-rig {
    transform-origin: 67% 46%;
  }

  .mascot-runway {
    width: calc(100% - 28px);
    height: 176px;
    margin-top: 46px;
    border-radius: 22px;
  }

  .runway-copy {
    top: 18px;
    width: calc(100% - 36px);
    transform: none;
  }

  .runway-copy strong {
    max-width: none;
    font-size: 15px;
  }

  .mascot-pack {
    top: 83px;
  }

  .mascot-pack-two {
    top: 91px;
  }

  .runway-mascot {
    width: 53px;
    height: 53px;
  }

  .entry-section {
    width: calc(100% - 24px);
    min-height: 0;
    padding: 34px 14px 14px;
    border-radius: 26px;
  }

  .entry-copy {
    padding: 0 8px;
  }

  .workspace-shell.entry-window {
    grid-template-columns: 86px minmax(0, 1fr);
    min-height: 560px;
    border-radius: 17px;
  }

  .workspace-sidebar {
    overflow: hidden;
  }

  .workspace-tabs,
  .workspace-search,
  .workspace-agent-copy,
  .workspace-agent-meta,
  .workspace-sidebar-footer span,
  .workspace-sidebar-footer b,
  .workspace-model,
  .workspace-tools button:nth-child(-n + 2) {
    display: none;
  }

  .workspace-osbar {
    justify-content: center;
  }

  .workspace-osbar > button {
    display: none;
  }

  .workspace-agent-row {
    grid-template-columns: 1fr;
    place-items: center;
    min-height: 58px;
    padding: 6px;
  }

  .workspace-agent-avatar {
    width: 40px;
    height: 40px;
  }

  .workspace-sidebar-footer button {
    grid-template-columns: 1fr;
    place-items: center;
  }

  .workspace-chat-header {
    padding: 0 10px;
    gap: 7px;
  }

  .workspace-header-avatar {
    width: 32px;
    height: 32px;
  }

  .workspace-thread {
    padding: 16px 12px 10px;
  }

  .workspace-message {
    max-width: 92%;
  }

  .workspace-message-agent {
    max-width: 100%;
  }

  .workspace-handoff {
    grid-template-columns: 22px 10px 22px minmax(0, 1fr);
  }

  .workspace-handoff > small {
    display: none;
  }

  .workspace-composer {
    margin: 0 9px 9px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .paco-vector-jaw,
  .paco-vector-float,
  .paco-vector-frame-b,
  .paco-vector-pulse,
  .paco-vector-sparks,
  .workspace-status i,
  .cast-actor,
  .cast-actor-body,
  .cast-actor::after {
    animation: none !important;
  }

  .cinema-letterbox {
    display: none;
  }

  .hero-gaze-rig,
  .hero-gaze-eyes {
    transform: none !important;
  }

  .mascot-pack {
    position: relative;
    left: 32%;
    top: 72px;
    display: inline-flex;
    margin-right: 14px;
    transform: none !important;
  }

  .mascot-pack-two {
    display: none;
  }
}


/* ---------------------------------------------------------------------------
   Motion upgrade (2026-08-27): Lenis smooth scroll, cinematic intro,
   word-split hero title, capability marquee, magnetic buttons, panel drift
   parallax, and direction-aware nav.
--------------------------------------------------------------------------- */

/* Lenis owns the scroll loop while it is active. */
html.lenis,
html.lenis body {
  height: auto;
}

html.lenis-smooth {
  scroll-behavior: auto !important;
}

.lenis.lenis-stopped {
  overflow: hidden;
}

/* Cinematic intro overlay. Only rendered when JS adds .intro-active, so the
   no-GSAP / no-JS paths never see it. */
.intro {
  position: fixed;
  inset: 0;
  z-index: 900;
  display: none;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(720px 480px at 50% 42%, rgba(69, 238, 120, 0.08), transparent 70%),
    #060706;
  will-change: transform;
}

html.intro-active .intro {
  display: flex;
}

html.intro-active,
html.intro-active body {
  overflow: hidden;
}

html.intro-active .site-nav {
  opacity: 0;
  transform: translate(-50%, -18px);
}

.intro-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.intro-face {
  display: block;
  width: 96px;
  height: 96px;
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, 0.45));
  animation: intro-bob 1.15s ease-in-out infinite;
}

.intro-face svg {
  width: 100%;
  height: 100%;
}

.intro-word {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.03em;
}

.intro-line {
  width: 184px;
  height: 2px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
}

.intro-line i {
  display: block;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, var(--green), #86a8ff);
  transform: scaleX(0);
  transform-origin: left;
}

.intro-count {
  color: var(--muted);
  font: 700 10px/1 var(--font-mono);
  letter-spacing: 0.24em;
}

.intro-tag {
  position: absolute;
  left: 50%;
  bottom: 36px;
  color: var(--faint);
  font: 700 9px/1 var(--font-mono);
  letter-spacing: 0.24em;
  text-transform: uppercase;
  transform: translateX(-50%);
}

@keyframes intro-bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}

/* Word-split hero title. Masks clip each word while GSAP raises it. Without
   JS the words render inline and the line-level CSS reveal still runs. */
.word-mask {
  display: inline-block;
  overflow: hidden;
  padding: 0.05em 0.03em 0.12em;
  margin: -0.05em -0.03em -0.12em;
  vertical-align: bottom;
}

.word {
  display: inline-block;
  will-change: transform;
}

/* Capability marquee. */
.marquee-strip {
  position: relative;
  z-index: 3;
  margin: 104px 0 0;
  padding: 20px 0;
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(10, 12, 10, 0.4);
  mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 9%, #000 91%, transparent);
}

.marquee-track {
  display: flex;
  width: max-content;
  animation: marquee-slide 38s linear infinite;
  will-change: transform;
}

.marquee-strip:hover .marquee-track {
  animation-play-state: paused;
}

.marquee-group {
  display: flex;
  align-items: center;
  gap: 46px;
  padding-inline-end: 46px;
}

.marquee-group span {
  white-space: nowrap;
  color: var(--faint);
  font: 700 12px/1 var(--font-mono);
  letter-spacing: 0.17em;
  text-transform: uppercase;
  transition: color 0.25s ease;
}

.marquee-group span:hover {
  color: var(--ink);
}

.marquee-group i {
  display: block;
  width: 26px;
  height: 26px;
  flex: 0 0 auto;
}

.marquee-group i svg {
  width: 100%;
  height: 100%;
}

@keyframes marquee-slide {
  to { transform: translateX(-50%); }
}

/* Magnetic buttons: quickTo owns the transform, so transitions keep only the
   color/shadow properties. */
.button.is-magnetic,
.nav-open.is-magnetic {
  transition-property: color, background, background-color, border-color, box-shadow, opacity;
  will-change: transform;
}

/* Direction-aware nav hide. `translate` composes with the existing
   transform: translateX(-50%) centering; the transition itself lives on the
   base .site-nav and html.ready .site-nav rules above. */
.site-nav.is-hidden {
  translate: 0 calc(-100% - 30px);
}

/* The "SCROLL LEFT → RIGHT" hint is only useful before the visitor engages
   with the story; afterwards it would overlap the flow cards, so it bows out. */
.story-direction {
  transition: opacity 0.45s var(--ease), translate 0.45s var(--ease);
}

.story-shell.story-engaged .story-direction {
  opacity: 0;
  translate: 0 8px;
}

/* Story panel depth drift (driven by --drift from JS). `translate` stays
   clear of the transform-based reveal/tilt systems. */
.story-panel {
  --drift: 0;
}

.story-panel .section-heading,
.story-panel .flow-heading,
.story-panel .work-copy,
.story-panel .memory-copy,
.story-panel .control-copy {
  translate: calc(var(--drift) * 56px) 0;
}

.story-panel .crew-board,
.story-panel .work-visual,
.story-panel .memory-visual,
.story-panel .control-visual,
.story-panel .flow-line {
  translate: calc(var(--drift) * -40px) 0;
}

@media (prefers-reduced-motion: reduce) {
  .marquee-track {
    animation: none;
  }

  .marquee-strip {
    mask-image: none;
    -webkit-mask-image: none;
  }

  .story-panel .section-heading,
  .story-panel .flow-heading,
  .story-panel .work-copy,
  .story-panel .memory-copy,
  .story-panel .control-copy,
  .story-panel .crew-board,
  .story-panel .work-visual,
  .story-panel .memory-visual,
  .story-panel .control-visual,
  .story-panel .flow-line {
    translate: none;
  }
}

@media (max-width: 640px) {
  .intro-face {
    width: 72px;
    height: 72px;
  }

  .marquee-strip {
    margin-top: 72px;
  }
}

/* ==========================================================================
   Language switch + Hebrew / RTL
   --------------------------------------------------------------------------
   Direction lives on <html>. Everything above this block was written with
   logical properties where a side had meaning, so most of the mirror is free;
   what remains here is the part logical properties cannot express — transforms,
   the direction the pinned story travels, and the deliberate exceptions.
   ========================================================================== */

.nav-actions {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  gap: 2px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
}

.lang-switch button {
  min-width: 34px;
  min-height: 30px;
  padding: 0 8px;
  border: 0;
  border-radius: 9px;
  color: var(--muted);
  background: transparent;
  font: 700 11px/1 var(--font-body);
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: color 0.2s var(--ease), background 0.2s var(--ease);
}

.lang-switch button:hover {
  color: var(--ink);
}

.lang-switch button.is-active {
  color: #041008;
  background: var(--green);
}

@media (max-width: 640px) {
  .lang-switch button {
    min-width: 30px;
    padding: 0 6px;
    font-size: 10px;
  }
}

/* Hebrew typography. Manrope and DM Sans carry no Hebrew glyphs, so the
   Hebrew faces go in FRONT of them: Latin words inside a Hebrew sentence
   still fall through to the original stack, per character. */
/* The mono label style leans on wide tracking, which Hebrew — no ascenders to
   separate, no uppercase — reads as broken-apart rather than as a label. */
html[lang="he"] :is(
    .eyebrow,
    .section-kicker,
    .brand-tag,
    .crew-count,
    .agent-engine,
    .agent-state,
    .live-pill,
    .glass-card small,
    .computer-overlay header,
    .computer-feed,
    .control-badge small,
    .approval-head small,
    .story-index,
    .story-direction,
    .runway-copy span,
    .marquee-group span,
    .local-note,
    .scroll-cue,
    .memory-chips span,
    .context-list i,
    .intro-tag,
    .engine-row
  ) {
  letter-spacing: 0.015em;
}

html[lang="he"] .hero-title,
html[lang="he"] .section h2,
html[lang="he"] .entry-copy h2 {
  letter-spacing: -0.01em;
}

/* -- the exception: the header keeps its arrangement in both languages ----- */
[dir="rtl"] .site-nav {
  direction: ltr;
}

/* Each label picks its own base direction from its own first letter. `direction`
   would have done the same thing and also reversed the flex order inside the
   button, moving the status dot and the arrow to the wrong ends. */
[dir="rtl"] .site-nav .nav-links a,
[dir="rtl"] .site-nav .brand-tag,
[dir="rtl"] .site-nav .nav-open > span:not(.status-dot):not(.nav-open-arrow) {
  unicode-bidi: plaintext;
}

/* -- pinned story ---------------------------------------------------------
   The track itself is mirrored by `direction`: its inline start is the right
   edge, so panel 01 is the first thing on screen and the rest wait off-stage
   to the LEFT. main.js flips the sign of the travel to match. */
[dir="rtl"] .story-vignette {
  transform: scaleX(-1);
}

[dir="rtl"] .story-background[data-story-bg="0"] img {
  object-position: 36% 50%;
}

/* -- the cast runs the other way, and faces it ----------------------------
   One flip on the container mirrors both the travel and the characters, so
   the travel maths in mascots.js stays the single description of the motion. */
[dir="rtl"] .cast-track,
[dir="rtl"] .runway-viewport {
  transform: scaleX(-1);
}

[dir="rtl"] .marquee-track {
  animation-direction: reverse;
}

/* -- arrows that mean "forward" ------------------------------------------- */
[dir="rtl"] .cta-arrow,
[dir="rtl"] .handoff-arrow svg,
[dir="rtl"] .workspace-handoff svg {
  display: inline-block;
  transform: scaleX(-1);
}

/* -- workspace preview ----------------------------------------------------
   Mirrored like the rest, with two deliberate holds: your own message stays
   on the right of the thread and send stays on the right of the composer. */
[dir="rtl"] .workspace-agent-row.is-active {
  box-shadow: inset -2px 0 #1084fe;
}

[dir="rtl"] .workspace-message-user {
  align-self: flex-start;
  border-radius: 13px 13px 4px 13px;
}

[dir="rtl"] .workspace-composer > button:first-child {
  grid-column: 3;
}

[dir="rtl"] .workspace-send {
  grid-column: 1;
}
