/* ==========================================================================
   Accounting System Pro 2027 — product tour
   TSSHCO · Thinking Robots · self-contained, no external assets
   ========================================================================== */

/* ---------- Tokens ---------- */
:root {
  --navy-950: #050910;
  --navy-900: #0b1220;
  --navy-800: #0f1a2e;
  --navy-700: #16233c;
  --ink: #eef3fb;
  --ink-2: #c8d4e6;
  --muted: #9aabc4;
  --muted-2: #7f90a9;
  --line: rgba(148, 163, 184, .14);
  --line-2: rgba(148, 163, 184, .24);
  --indigo: #6366f1;
  --indigo-soft: #a5b4fc;
  --cyan: #22d3ee;
  --cyan-soft: #67e8f9;
  --emerald: #34d399;
  --amber: #fbbf24;
  --rose: #fb7185;
  --glass: linear-gradient(180deg, rgba(22, 36, 60, .82), rgba(10, 18, 32, .94));
  --glass-2: linear-gradient(180deg, rgba(18, 30, 52, .7), rgba(9, 16, 29, .86));
  --radius: 14px;
  --radius-sm: 9px;
  --font: ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --font-fa: "Vazirmatn", "Vazir", "IRANSansX", "IRANSans", "Noto Naskh Arabic", "Segoe UI", Tahoma, sans-serif;
  --mono: ui-monospace, "SFMono-Regular", "Cascadia Mono", "Cascadia Code", Consolas, "Liberation Mono", monospace;
  --ease: cubic-bezier(.22, .7, .2, 1);
  --dur: 7000ms;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body { margin: 0; padding: 0; }
body {
  min-height: 100svh;
  overflow-x: clip;
  font-family: var(--font);
  color: var(--ink);
  background:
    radial-gradient(70% 55% at 82% -10%, rgba(79, 70, 229, .22), transparent 68%),
    radial-gradient(55% 45% at -5% 108%, rgba(34, 211, 238, .12), transparent 70%),
    linear-gradient(180deg, #080e19 0%, #070c16 55%, #050910 100%);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(148, 163, 184, .045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, .045) 1px, transparent 1px);
  background-size: 72px 72px;
  -webkit-mask-image: radial-gradient(90% 70% at 50% 30%, #000 10%, transparent 78%);
  mask-image: radial-gradient(90% 70% at 50% 30%, #000 10%, transparent 78%);
  opacity: .7;
}
h1, h2, h3, p, ul, ol, li, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
img, svg { display: block; max-width: 100%; }
button, a { font: inherit; color: inherit; }
button { cursor: pointer; }
a { text-decoration: none; }
.nb { white-space: nowrap; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; letter-spacing: -.01em; }
.muted { color: var(--muted-2); }
.nil { color: rgba(148, 163, 184, .45) !important; }
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  clip: rect(0 0 0 0); clip-path: inset(50%);
  overflow: hidden; white-space: nowrap;
}
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 1em; height: 1em; display: inline-block; flex: none; }
.icon--xs { width: .82em; height: .82em; }
.icon--sm { width: 1.05em; height: 1.05em; }

/* ---------- Page chrome ---------- */
.page {
  position: relative;
  z-index: 1;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: clamp(10px, 1.6vw, 20px) clamp(10px, 2.4vw, 36px) clamp(10px, 1.4vw, 18px);
}
.topbar {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 2px 2px 0;
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); }
.brand-mark {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: linear-gradient(145deg, #a5b4fc, #22d3ee 70%);
  box-shadow: 0 8px 24px -10px rgba(99, 102, 241, .9), inset 0 1px 0 rgba(255, 255, 255, .4);
}
.brand-mark svg { width: 24px; height: 24px; }
.brand-type { display: flex; flex-direction: column; line-height: 1; }
.wordmark { font-size: 13px; font-weight: 800; letter-spacing: .2em; }
.brand-sub { font-size: 9px; letter-spacing: .18em; text-transform: uppercase; color: var(--muted-2); margin-top: 4px; }
.topbar-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}
.meta-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 10px rgba(34, 211, 238, .8); }
.meta-sep { color: rgba(148, 163, 184, .4); }
.topbar-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 11.5px;
  letter-spacing: .08em;
  color: var(--ink-2);
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 26, 46, .4);
  transition: border-color .25s ease, color .25s ease, background-color .25s ease;
}
.topbar-link:hover { color: #fff; border-color: rgba(103, 232, 249, .4); background: rgba(34, 211, 238, .08); }
.topbar-link .icon { color: var(--cyan-soft); }

/* ---------- Player ---------- */
.player {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(12px, 2.4vh, 28px) 0 clamp(8px, 1.8vh, 20px);
}
.player-shell {
  width: min(1280px, 100%, calc((100svh - 228px) * 1.7778));
  margin: 0 auto;
}

/* ---------- Stage ---------- */
.stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  container-type: inline-size;
  container-name: stage;
  overflow: hidden;
  isolation: isolate;
  border-radius: clamp(12px, 1.5vw, 22px);
  border: 1px solid rgba(148, 163, 184, .18);
  background:
    radial-gradient(120% 95% at 88% 0%, rgba(99, 102, 241, .26), transparent 56%),
    radial-gradient(85% 70% at 0% 100%, rgba(34, 211, 238, .13), transparent 62%),
    linear-gradient(160deg, #0d1729 0%, #0b1220 46%, #080e1a 100%);
  box-shadow:
    0 40px 100px -50px rgba(0, 0, 0, .95),
    0 2px 0 rgba(255, 255, 255, .03) inset,
    0 0 0 1px rgba(255, 255, 255, .02);
}
.stage::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(148, 163, 184, .06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, .06) 1px, transparent 1px);
  background-size: clamp(26px, 4.4cqw, 58px) clamp(26px, 4.4cqw, 58px);
  -webkit-mask-image: radial-gradient(130% 105% at 50% -5%, #000 25%, transparent 80%);
  mask-image: radial-gradient(130% 105% at 50% -5%, #000 25%, transparent 80%);
  opacity: .75;
}
.stage::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(8, 14, 26, 0) 55%, rgba(5, 9, 16, .45));
}
.aurora { position: absolute; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.aurora::before,
.aurora::after {
  content: "";
  position: absolute;
  width: 70%;
  height: 90%;
  border-radius: 50%;
  opacity: .5;
  will-change: transform;
}
.aurora::before {
  left: -18%;
  top: -40%;
  background: radial-gradient(closest-side, rgba(99, 102, 241, .22), transparent 72%);
  animation: drift-a 26s ease-in-out infinite alternate;
}
.aurora::after {
  right: -22%;
  bottom: -48%;
  background: radial-gradient(closest-side, rgba(34, 211, 238, .16), transparent 72%);
  animation: drift-b 32s ease-in-out infinite alternate;
}
@keyframes drift-a { from { transform: translate3d(-2%, -2%, 0) scale(1); } to { transform: translate3d(6%, 5%, 0) scale(1.12); } }
@keyframes drift-b { from { transform: translate3d(3%, 3%, 0) scale(1.05); } to { transform: translate3d(-5%, -4%, 0) scale(.94); } }
.stage.is-paused .aurora::before,
.stage.is-paused .aurora::after,
.stage.is-paused .ledger-scan,
.stage.is-paused .float,
.stage.is-paused .pulse-dot::after,
.stage.is-paused .pulse-now,
.stage.is-paused .flow-track::after { animation-play-state: paused; }

/* ---------- Progress ---------- */
.progress {
  position: absolute;
  inset: 0 0 auto;
  z-index: 8;
  display: flex;
  gap: 3px;
  padding: 0;
  pointer-events: none;
}
.progress .seg { flex: 1; height: 3px; background: rgba(148, 163, 184, .13); overflow: hidden; }
.progress .seg:first-child { border-top-left-radius: 2px; }
.progress .seg:last-child { border-top-right-radius: 2px; }
.progress .seg i {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: left center;
  background: linear-gradient(90deg, #818cf8, #22d3ee);
  will-change: transform;
}

/* ---------- Scenes ---------- */
.scenes { position: absolute; inset: 0; z-index: 2; }
.scene {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  padding: clamp(14px, 3.4cqw, 42px) clamp(16px, 4.2cqw, 52px) clamp(14px, 2.6cqw, 30px);
  gap: clamp(8px, 1.6cqw, 18px);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate3d(0, 10px, 0);
  transition:
    opacity .55s ease,
    transform .72s var(--ease),
    visibility 0s linear .72s;
  z-index: 1;
  min-height: 0;
}
.scene.is-active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: none;
  transition-delay: 0s;
  z-index: 3;
}
/* Deep links (?scene=N) should not cross-fade through scene 1 on first paint. */
.stage.is-booting .scene { transition: none !important; }
.scene-no {
  position: absolute;
  top: clamp(10px, 1.6cqw, 20px);
  right: clamp(14px, 2.6cqw, 30px);
  z-index: 4;
  font-family: var(--mono);
  font-size: clamp(8px, 1.05cqw, 11px);
  letter-spacing: .18em;
  color: rgba(154, 171, 196, .55);
}

/* Stagger utility */
.anim {
  opacity: 0;
  transform: translate3d(0, 14px, 0);
  transition:
    opacity .5s ease,
    transform .72s var(--ease);
  transition-delay: calc(var(--i, 0) * 55ms + 120ms);
}
.scene.is-active .anim { opacity: 1; transform: none; }
.scene:not(.is-active) .anim { transition-delay: 0s; transition-duration: .22s; }

/* ---------- Layout primitives ---------- */
.split {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  align-items: center;
  gap: clamp(16px, 3.8cqw, 50px);
  min-height: 0;
}
.split--hero { grid-template-columns: minmax(0, 1.02fr) minmax(0, .98fr); }
.split--copy-wide { grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr); }
.split--license { grid-template-columns: minmax(0, .94fr) minmax(0, 1.06fr); }
.copy { display: flex; flex-direction: column; gap: clamp(7px, 1.15cqw, 14px); min-width: 0; }
.visual { min-width: 0; min-height: 0; position: relative; }
.scene-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: clamp(12px, 3cqw, 40px);
  flex: none;
}
.scene-head--tight { align-items: flex-start; }
.head-copy { display: flex; flex-direction: column; gap: clamp(6px, 1cqw, 11px); min-width: 0; flex: 0 1 auto; }
.head-lede { max-width: 40ch; flex: 0 1 44%; padding-bottom: 2px; }
.head-stat {
  display: flex;
  align-items: center;
  gap: clamp(6px, 1.2cqw, 12px);
  align-self: center;
  color: var(--muted);
  font-size: clamp(8px, 1cqw, 11px);
  line-height: 1.35;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.head-stat .big {
  font-size: clamp(30px, 5.4cqw, 66px);
  font-weight: 800;
  letter-spacing: -.05em;
  line-height: .9;
  background: linear-gradient(135deg, #c7d2fe, #67e8f9);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- Typography ---------- */
.eyebrow {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: clamp(7.5px, 1.02cqw, 11px);
  font-weight: 600;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--cyan-soft);
  white-space: nowrap;
}
.eyebrow-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 12px rgba(34, 211, 238, .9); flex: none; }
.hero-title {
  font-size: clamp(24px, 5.15cqw, 67px);
  line-height: 1.01;
  letter-spacing: -.035em;
  font-weight: 780;
  color: #f5f8ff;
}
.grad {
  background: linear-gradient(100deg, #c7d2fe 4%, #a5b4fc 37%, #67e8f9 92%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.h2 {
  font-size: clamp(19px, 3.55cqw, 47px);
  line-height: 1.06;
  letter-spacing: -.028em;
  font-weight: 720;
  color: #f2f7ff;
  text-wrap: balance;
}
.tagline {
  font-size: clamp(11px, 1.78cqw, 24px);
  line-height: 1.32;
  font-weight: 500;
  color: #dbe6f7;
  letter-spacing: -.012em;
}
.lede {
  font-size: clamp(10px, 1.36cqw, 17.5px);
  line-height: 1.55;
  color: var(--ink-2);
  max-width: 48ch;
}
.scene-caption { display: none; }
.chips { display: flex; flex-wrap: wrap; gap: clamp(5px, .8cqw, 9px); }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: clamp(3px, .45cqw, 5px) clamp(7px, .85cqw, 10px);
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 26, 46, .5);
  font-size: clamp(7.5px, .96cqw, 11.5px);
  letter-spacing: .045em;
  color: var(--ink-2);
  white-space: nowrap;
}
.chip .icon { color: var(--cyan-soft); }
.chip--mono { font-family: var(--mono); letter-spacing: 0; color: var(--muted); }
.chips--tight { gap: 6px; }

/* checks / feature lists */
.checks { display: flex; flex-direction: column; gap: clamp(5px, .85cqw, 10px); }
.checks li {
  display: flex;
  align-items: center;
  gap: clamp(6px, .8cqw, 9px);
  font-size: clamp(8.5px, 1.06cqw, 13px);
  line-height: 1.35;
  color: var(--ink-2);
}
.checks .icon { color: var(--emerald); }
.checks--icons .icon { color: var(--cyan-soft); }
.checks--tight li { font-size: clamp(8px, .98cqw, 12px); }

/* ---------- Shared panel ---------- */
.panel {
  position: relative;
  background: var(--glass);
  border: 1px solid var(--line);
  border-radius: clamp(8px, 1.15cqw, 14px);
  box-shadow:
    0 24px 50px -34px rgba(0, 0, 0, .95),
    inset 0 1px 0 rgba(255, 255, 255, .045);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  overflow: hidden;
}
.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: clamp(7px, 1cqw, 12px) clamp(9px, 1.2cqw, 15px);
  border-bottom: 1px solid var(--line);
  font-size: clamp(8px, 1cqw, 12px);
  color: var(--ink-2);
}
.ph-left { display: inline-flex; align-items: center; gap: 7px; min-width: 0; white-space: nowrap; }
.ph-left .mono { font-size: .9em; }
.dot { width: 6px; height: 6px; border-radius: 50%; flex: none; }
.dot--cyan { background: var(--cyan); box-shadow: 0 0 10px rgba(34, 211, 238, .8); }
.dot--indigo { background: var(--indigo-soft); box-shadow: 0 0 10px rgba(165, 180, 252, .7); }
.pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 7px;
  border-radius: 999px;
  border: 1px solid var(--line-2);
  background: rgba(148, 163, 184, .07);
  font-size: clamp(6.5px, .78cqw, 9px);
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
  flex: none;
}
.pill--ok { color: #6ee7b7; border-color: rgba(52, 211, 153, .3); background: rgba(16, 185, 129, .1); }
.pill--warn { color: #fcd34d; border-color: rgba(251, 191, 36, .3); background: rgba(251, 191, 36, .09); }
.pill .icon { width: .85em; height: .85em; }
.sample-note {
  margin-top: 6px;
  font-size: clamp(6px, .72cqw, 8.5px);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(154, 171, 196, .5);
  text-align: right;
}

/* ==========================================================================
   SCENE 1 · Brand
   ========================================================================== */
.scene--brand .visual--brand {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
}
.watermark {
  position: absolute;
  right: -2%;
  top: -12%;
  font-size: clamp(120px, 26cqw, 340px);
  font-weight: 800;
  letter-spacing: -.06em;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(148, 163, 184, .085);
  z-index: 0;
  pointer-events: none;
  user-select: none;
}
.brand-stack {
  position: relative;
  z-index: 2;
  width: min(100%, 560px);
  display: flex;
  flex-direction: column;
  gap: clamp(7px, 1.05cqw, 13px);
}
.ledger {
  position: relative;
  z-index: 2;
  width: 100%;
  transform: rotate(-.6deg);
  transition: transform .8s var(--ease);
}
.scene.is-active .ledger { transform: rotate(-.6deg) translateY(-4px); }
.ledger-rows { padding: clamp(2px, .5cqw, 6px) 0; }
.lrow {
  display: grid;
  grid-template-columns: clamp(22px, 2.5cqw, 32px) 1fr auto;
  align-items: center;
  gap: clamp(6px, .8cqw, 10px);
  padding: clamp(7px, .95cqw, 13px) clamp(9px, 1.2cqw, 15px);
  border-bottom: 1px dashed rgba(148, 163, 184, .1);
  font-size: clamp(7.5px, .92cqw, 11.5px);
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity .5s ease, transform .6s var(--ease);
  transition-delay: calc(var(--i, 0) * 55ms + 160ms);
}
.is-active .lrow { opacity: 1; transform: none; }
.lrow:last-child { border-bottom: 0; }
.lcode { font-family: var(--mono); color: var(--muted-2); font-size: .9em; }
.lname { color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lamt { font-family: var(--mono); color: #e6eeff; font-variant-numeric: tabular-nums; }
.ledger-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: clamp(7px, 1cqw, 12px) clamp(9px, 1.2cqw, 15px);
  border-top: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(52, 211, 153, .07), rgba(34, 211, 238, .04));
}
.lf-label { font-size: clamp(7px, .85cqw, 10.5px); letter-spacing: .1em; text-transform: uppercase; color: #6ee7b7; }
.lf-sum { font-size: clamp(9px, 1.15cqw, 14px); color: #d7fbe9; }
.brand-kpis {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid var(--line);
  border-radius: clamp(7px, .95cqw, 12px);
  background: rgba(10, 18, 32, .58);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  overflow: hidden;
}
.brand-kpis div {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: clamp(6px, .8cqw, 11px) clamp(8px, 1.1cqw, 14px);
  border-left: 1px solid var(--line);
  min-width: 0;
}
.brand-kpis div:first-child { border-left: 0; }
.brand-kpis span {
  font-size: clamp(5.5px, .66cqw, 8px);
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--muted-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.brand-kpis b {
  font-family: var(--mono);
  font-size: clamp(8px, 1.02cqw, 12.5px);
  font-weight: 500;
  color: #e8f1ff;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.ledger-scan {
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 38%;
  background: linear-gradient(180deg, transparent, rgba(34, 211, 238, .07) 55%, rgba(34, 211, 238, .16) 88%, transparent);
  transform: translateY(-120%);
  animation: scan 6.5s cubic-bezier(.4, 0, .4, 1) infinite;
  pointer-events: none;
  mix-blend-mode: screen;
}
@keyframes scan {
  0%, 12% { transform: translateY(-120%); opacity: 0; }
  24% { opacity: 1; }
  62% { opacity: .9; }
  78%, 100% { transform: translateY(320%); opacity: 0; }
}
.float {
  position: absolute;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: clamp(6px, .8cqw, 10px) clamp(8px, 1cqw, 13px);
  border: 1px solid rgba(148, 163, 184, .2);
  border-radius: clamp(7px, .9cqw, 11px);
  background: rgba(11, 20, 36, .86);
  box-shadow: 0 18px 38px -22px rgba(0, 0, 0, .9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  font-size: clamp(7px, .85cqw, 10.5px);
  line-height: 1.3;
  animation: bob 7s ease-in-out infinite alternate;
}
.float b { display: block; font-weight: 600; color: #eaf2ff; font-size: 1.05em; }
.float em { display: block; font-style: normal; color: var(--muted-2); font-size: .9em; }
.float--sync { left: clamp(-52px, -3.8cqw, -18px); bottom: clamp(-56px, -3.8cqw, -18px); animation-delay: -2s; }
.float--date { right: clamp(-30px, -1.6cqw, -8px); top: clamp(-58px, -3.8cqw, -18px); animation-delay: -4s; }
.float--date .icon { color: var(--cyan-soft); width: 15px; height: 15px; }
.float--date b { font-family: var(--mono); font-size: 1em; }
@keyframes bob { from { transform: translateY(0); } to { transform: translateY(-7px); } }
.pulse-dot { position: relative; width: 7px; height: 7px; border-radius: 50%; background: var(--emerald); flex: none; }
.pulse-dot::after {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 1px solid rgba(52, 211, 153, .6);
  animation: ping 2.6s ease-out infinite;
}
.pulse-dot--emerald { background: var(--emerald); }
@keyframes ping {
  0% { transform: scale(.7); opacity: .9; }
  70%, 100% { transform: scale(2.1); opacity: 0; }
}

/* ==========================================================================
   SCENE 2 · Industry profiles
   ========================================================================== */
.profiles {
  flex: 1;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  grid-auto-rows: minmax(0, 1fr);
  gap: clamp(5px, .9cqw, 11px);
  min-height: 0;
}
.prof {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(4px, .55cqw, 7px);
  padding: clamp(7px, 1cqw, 13px) clamp(8px, 1.1cqw, 15px);
  border: 1px solid var(--line);
  border-radius: clamp(7px, .95cqw, 12px);
  background: linear-gradient(155deg, rgba(27, 43, 70, .64), rgba(10, 18, 32, .72));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .035);
  overflow: hidden;
  min-width: 0;
  transition: border-color .3s ease, background-color .3s ease, transform .35s var(--ease);
}
.prof::after {
  content: "";
  position: absolute;
  inset: auto auto 0 0;
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, var(--a, transparent), transparent 70%);
  opacity: .55;
}
.prof .icon { width: clamp(15px, 1.75cqw, 23px); height: clamp(15px, 1.75cqw, 23px); color: var(--a, var(--indigo-soft)); }
.prof > span { font-size: clamp(8px, 1.02cqw, 12.5px); line-height: 1.2; color: #e3ecfa; font-weight: 500; }
.prof[data-accent="indigo"] { --a: #a5b4fc; --a-bg: rgba(99, 102, 241, .12); }
.prof[data-accent="cyan"] { --a: #67e8f9; --a-bg: rgba(34, 211, 238, .1); }
.prof[data-accent="emerald"] { --a: #6ee7b7; --a-bg: rgba(52, 211, 153, .1); }
.prof[data-accent="amber"] { --a: #fcd34d; --a-bg: rgba(251, 191, 36, .1); }
.prof[data-accent="slate"] { --a: #cbd5e1; --a-bg: rgba(148, 163, 184, .1); }
.prof:hover { border-color: rgba(148, 163, 184, .32); background: linear-gradient(155deg, rgba(35, 54, 86, .7), rgba(12, 21, 38, .8)); transform: translateY(-2px); }
.prof--feature {
  border-color: rgba(251, 191, 36, .4);
  background: linear-gradient(155deg, rgba(62, 49, 18, .5), rgba(16, 24, 38, .82));
}
.prof--feature::after { background: linear-gradient(90deg, rgba(251, 191, 36, .9), transparent 75%); opacity: .9; }
.prof--note {
  justify-content: center;
  align-items: flex-start;
  border-style: dashed;
  background: rgba(15, 26, 46, .3);
  color: var(--muted-2);
}
.prof--note .icon { color: rgba(148, 163, 184, .55); }
.prof--note > span { color: var(--muted-2); font-size: clamp(7px, .9cqw, 11px); }

/* ==========================================================================
   SCENE 3 · Double-entry
   ========================================================================== */
.visual--ledger { display: flex; flex-direction: column; gap: clamp(7px, 1.1cqw, 13px); justify-content: center; }
.jpanel { width: 100%; }
.jt { padding: 0 clamp(8px, 1.1cqw, 14px); }
.jt-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(52px, 6.4cqw, 86px) clamp(52px, 6.4cqw, 86px);
  gap: 6px;
  align-items: center;
  padding: clamp(5px, .72cqw, 9px) 0;
  border-bottom: 1px dashed rgba(148, 163, 184, .1);
  font-size: clamp(7.5px, .94cqw, 12px);
  font-variant-numeric: tabular-nums;
}
.jt-row:last-child { border-bottom: 0; }
.jt-row > span:nth-child(2), .jt-row > span:nth-child(3) { text-align: right; font-family: var(--mono); color: #dfe8f8; }
.jt-row--head {
  border-bottom: 1px solid var(--line);
  font-size: clamp(6px, .72cqw, 8.5px);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted-2);
}
.jt-row--head > span:nth-child(2), .jt-row--head > span:nth-child(3) { font-family: var(--font); color: var(--muted-2); }
.acct { display: flex; align-items: center; gap: 7px; min-width: 0; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.acct b { font-family: var(--mono); font-weight: 500; color: var(--muted-2); font-size: .88em; }
.acct em { font-style: normal; color: var(--muted-2); font-size: .82em; }
.jt-foot {
  display: flex;
  align-items: center;
  gap: clamp(5px, .8cqw, 10px);
  padding: clamp(6px, .85cqw, 11px) clamp(8px, 1.1cqw, 14px);
  border-top: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(52, 211, 153, .09), rgba(34, 211, 238, .04));
  font-size: clamp(7px, .86cqw, 10.5px);
  color: var(--ink-2);
  white-space: nowrap;
}
.jt-foot b { font-family: var(--mono); color: #eafff7; font-weight: 500; }
.jt-foot .eq { color: var(--emerald); font-weight: 700; }
.jt-foot .pill { margin-left: auto; }
.mini-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(7px, 1.1cqw, 13px); }
.mini { padding: clamp(7px, 1cqw, 12px) clamp(9px, 1.15cqw, 14px); }
.mini-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: clamp(7px, .84cqw, 10px);
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted);
  padding-bottom: clamp(4px, .55cqw, 7px);
  border-bottom: 1px solid var(--line);
  margin-bottom: clamp(3px, .45cqw, 6px);
}
.mini-head .mono { font-size: .9em; color: var(--muted-2); }
.tb-row, .pl-row, .tb-total {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 6px;
  align-items: center;
  font-size: clamp(7px, .84cqw, 10.5px);
  padding: clamp(2px, .32cqw, 4px) 0;
  color: var(--ink-2);
}
.tb-row, .tb-total { grid-template-columns: minmax(0, 1fr) clamp(38px, 4.3cqw, 60px) clamp(38px, 4.3cqw, 60px); gap: clamp(6px, .9cqw, 12px); }
.tb-row span:nth-child(2), .tb-row span:nth-child(3) { font-family: var(--mono); text-align: right; color: #dbe6f7; }
.tb-total { border-top: 1px solid var(--line-2); margin-top: 3px; padding-top: 5px; color: var(--muted); }
.tb-total b { font-family: var(--mono); font-weight: 500; color: #eafff7; text-align: right; }
.pl-row { grid-template-columns: minmax(0, 1fr) auto auto; }
.pl-row b { font-family: var(--mono); font-weight: 500; color: #eafff7; text-align: right; }
.pl-row em { font-style: normal; font-size: .85em; color: var(--emerald); font-family: var(--mono); }
.bar { margin-top: 5px; height: 3px; background: rgba(148, 163, 184, .16); border-radius: 2px; overflow: hidden; }
.bar i { display: block; height: 100%; width: var(--w, 50%); border-radius: 2px; background: linear-gradient(90deg, #34d399, #22d3ee); transform-origin: left; }
.mini-foot { margin-top: clamp(4px, .55cqw, 7px); font-size: clamp(6px, .72cqw, 8.5px); color: var(--muted-2); line-height: 1.35; }

/* ==========================================================================
   SCENE 4 · Bilingual
   ========================================================================== */
.visual--bilingual { display: flex; flex-direction: column; gap: clamp(8px, 1.4cqw, 16px); justify-content: center; }
.bilingual { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: clamp(6px, 1.1cqw, 14px); }
.inv { padding: clamp(9px, 1.2cqw, 15px); display: flex; flex-direction: column; gap: clamp(4px, .6cqw, 8px); min-width: 0; }
.inv-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.inv-kicker { font-size: clamp(7.5px, .92cqw, 11px); font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--cyan-soft); }
.inv--fa .inv-kicker { letter-spacing: .04em; font-size: clamp(8.5px, 1.05cqw, 13px); }
.inv-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: clamp(7px, .85cqw, 10.5px);
  color: var(--muted);
  padding-bottom: clamp(4px, .55cqw, 7px);
  border-bottom: 1px solid var(--line);
}
.inv-rows { display: flex; flex-direction: column; gap: 2px; }
.inv-row { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; font-size: clamp(7px, .86cqw, 10.5px); color: var(--ink-2); padding: 2px 0; }
.inv-row b { font-family: var(--mono); font-weight: 500; color: #e7effc; white-space: nowrap; }
.inv-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-top: clamp(2px, .3cqw, 4px);
  padding-top: clamp(4px, .6cqw, 8px);
  border-top: 1px solid var(--line-2);
  font-size: clamp(8px, .95cqw, 11.5px);
  color: var(--ink-2);
}
.inv-total b { font-family: var(--mono); font-weight: 600; font-size: clamp(11px, 1.35cqw, 17px); color: #fff; white-space: nowrap; }
.inv-foot { display: flex; justify-content: space-between; gap: 8px; font-size: clamp(6px, .72cqw, 8.5px); color: var(--muted-2); letter-spacing: .06em; text-transform: uppercase; }
.inv--fa { font-family: var(--font-fa); text-align: right; border-color: rgba(52, 211, 153, .2); }
.inv--fa .inv-row b, .inv--fa .inv-total b { font-family: var(--font-fa); }
.inv--fa .inv-row span { letter-spacing: 0; }
.mirror {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  color: var(--cyan-soft);
  padding: 0 2px;
}
.mirror .icon { width: clamp(13px, 1.5cqw, 19px); height: clamp(13px, 1.5cqw, 19px); }
.mirror span { font-size: clamp(5.5px, .66cqw, 8px); letter-spacing: .1em; text-transform: uppercase; color: var(--muted-2); white-space: nowrap; }
.dates {
  display: flex;
  align-items: center;
  gap: clamp(6px, 1.2cqw, 14px);
  flex-wrap: wrap;
  font-size: clamp(7px, .85cqw, 10.5px);
  color: var(--ink-2);
  padding: clamp(6px, .9cqw, 11px) clamp(9px, 1.2cqw, 15px);
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 26, 46, .45);
}
.dates-label { color: var(--muted-2); font-size: .9em; letter-spacing: .04em; }
.date-chip { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.date-chip .icon { color: var(--cyan-soft); }
.date-chip b { font-family: var(--mono); font-weight: 500; color: #eaf2ff; }
.date-eq { color: var(--emerald); font-weight: 700; }
.lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: clamp(7px, .85cqw, 10.5px);
  color: var(--muted-2);
  letter-spacing: .06em;
}
.lang-on { padding: 2px 7px; border: 1px solid var(--line); border-radius: 6px; color: var(--ink-2); background: rgba(99, 102, 241, .1); }
.lang-on--fa { font-family: var(--font-fa); font-size: 1.15em; line-height: 1.2; padding: 1px 8px; background: rgba(52, 211, 153, .09); }
.lang-arrow { color: var(--cyan-soft); }
.lang-note { color: var(--muted-2); }

/* ==========================================================================
   SCENE 5 · Operations
   ========================================================================== */
.scene--ops .scene-head { align-items: flex-start; }
.flow {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: clamp(8px, 1.5cqw, 22px);
  min-height: 0;
  padding-top: clamp(2px, .6cqw, 8px);
}
.flow-band {
  --np: clamp(7px, 1.15cqw, 14px);
  --ico: clamp(21px, 2.8cqw, 36px);
  --gap: clamp(5px, .9cqw, 12px);
  position: relative;
  width: 100%;
}
.flow-track {
  position: absolute;
  left: 6%;
  right: 6%;
  top: calc(var(--np) + var(--ico) / 2);
  height: 1px;
  background: rgba(148, 163, 184, .18);
  z-index: 0;
  overflow: visible;
}
.flow-track i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, rgba(129, 140, 248, .7), rgba(34, 211, 238, .8));
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 1.9s var(--ease) .55s;
}
.is-active .flow-track i { transform: scaleX(1); }
.flow-track::after {
  content: "";
  position: absolute;
  top: -2px;
  left: 0;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--cyan-soft);
  box-shadow: 0 0 12px rgba(34, 211, 238, .9);
  animation: flow-dot 6s linear infinite;
  opacity: 0;
}
.is-active .flow-track::after { opacity: .85; }
@keyframes flow-dot {
  0% { transform: translateX(0); opacity: 0; }
  8% { opacity: .9; }
  88% { opacity: .9; }
  100% { transform: translateX(calc(88cqw - 8px)); opacity: 0; }
}
.flow-nodes {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: var(--gap);
  width: 100%;
}
.node {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: clamp(3px, .42cqw, 6px);
  height: clamp(96px, 13.6cqw, 174px);
  padding: var(--np);
  border: 1px solid var(--line);
  border-radius: clamp(7px, .95cqw, 12px);
  background: linear-gradient(165deg, rgba(24, 39, 64, .92), rgba(10, 18, 32, .94));
  box-shadow: 0 16px 34px -26px rgba(0, 0, 0, .9);
  min-width: 0;
}
.node::after {
  content: "";
  position: absolute;
  right: calc(var(--gap) / -2 - 2.5px);
  top: calc(var(--np) + var(--ico) / 2 - 2.5px);
  width: 5px;
  height: 5px;
  border-top: 1px solid rgba(103, 232, 249, .55);
  border-right: 1px solid rgba(103, 232, 249, .55);
  transform: rotate(45deg);
  z-index: 3;
}
.node:last-child::after { display: none; }
.node-no {
  position: absolute;
  top: clamp(4px, .5cqw, 7px);
  right: clamp(5px, .65cqw, 9px);
  font-family: var(--mono);
  font-size: clamp(5.5px, .64cqw, 8px);
  color: rgba(154, 171, 196, .45);
}
.node-ico {
  width: var(--ico);
  height: var(--ico);
  display: grid;
  place-items: center;
  border-radius: clamp(5px, .7cqw, 9px);
  border: 1px solid rgba(34, 211, 238, .18);
  background: rgba(34, 211, 238, .07);
  color: var(--cyan-soft);
}
.node-ico .icon { width: 56%; height: 56%; }
.node b { font-size: clamp(7.5px, .98cqw, 12.5px); font-weight: 600; color: #eef4ff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.node em { font-style: normal; font-size: clamp(6px, .74cqw, 9.5px); color: var(--muted-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.node-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: auto;
  padding-top: clamp(4px, .55cqw, 8px);
  border-top: 1px solid rgba(148, 163, 184, .1);
  font-size: clamp(5.8px, .7cqw, 9px);
  color: var(--muted-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.node-tag i { width: 4px; height: 4px; border-radius: 50%; background: var(--emerald); flex: none; }
.trace {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: clamp(5px, .9cqw, 12px);
  font-size: clamp(6.5px, .78cqw, 10px);
  color: var(--muted-2);
}
.trace-label { display: inline-flex; align-items: center; gap: 5px; color: var(--ink-2); letter-spacing: .02em; }
.trace-label .icon { color: var(--cyan-soft); }
.trace-step {
  padding: 2px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(15, 26, 46, .5);
  white-space: nowrap;
}
.trace-step::before { content: "✓"; color: var(--emerald); margin-right: 4px; }
.optimizer {
  flex: none;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(8px, 1.4cqw, 18px);
  padding: clamp(7px, 1cqw, 13px) clamp(9px, 1.3cqw, 16px);
  background: linear-gradient(100deg, rgba(41, 34, 16, .38), rgba(13, 22, 38, .86) 42%, rgba(13, 22, 38, .9));
  border-color: rgba(251, 191, 36, .22);
}
.opt-art { width: clamp(84px, 10.5cqw, 138px); flex: none; }
.opt-art svg { width: 100%; height: auto; }
.opt-title { display: flex; align-items: center; gap: 7px; font-size: clamp(8px, 1cqw, 12px); font-weight: 600; color: #ffe9b0; letter-spacing: .02em; }
.opt-body p { margin-top: 3px; font-size: clamp(6.5px, .8cqw, 10px); line-height: 1.4; color: var(--muted); max-width: 54ch; }
.opt-stats { display: flex; gap: clamp(8px, 1.5cqw, 20px); }
.opt-stats div { display: flex; flex-direction: column; gap: 1px; text-align: right; }
.opt-stats b { font-family: var(--mono); font-size: clamp(10px, 1.25cqw, 16px); font-weight: 500; color: #fff; font-variant-numeric: tabular-nums; white-space: nowrap; }
.opt-stats .unit { font-size: .65em; color: var(--muted); margin-left: 1px; }
.opt-stats span { font-size: clamp(5.5px, .68cqw, 8.5px); text-transform: uppercase; letter-spacing: .08em; color: var(--muted-2); white-space: nowrap; }

/* ==========================================================================
   SCENE 6 · Departments
   ========================================================================== */
.visual--depts { display: flex; flex-direction: column; justify-content: center; height: 100%; }
.dept-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(5px, .85cqw, 11px); }
.dept {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: clamp(3px, .45cqw, 6px);
  padding: clamp(8px, 1.2cqw, 16px);
  min-height: clamp(92px, 13.2cqw, 168px);
  border: 1px solid var(--line);
  border-radius: clamp(7px, .95cqw, 12px);
  background: linear-gradient(160deg, rgba(24, 39, 64, .66), rgba(10, 18, 32, .8));
  min-width: 0;
  overflow: hidden;
}
.dept::before {
  content: "";
  position: absolute;
  left: 0; top: 14%;
  width: 2px; height: 72%;
  border-radius: 2px;
  background: var(--a);
  opacity: .55;
}
.dept-ico { display: grid; place-items: center; width: clamp(20px, 2.3cqw, 30px); height: clamp(20px, 2.3cqw, 30px); color: var(--a); }
.dept-ico .icon { width: 100%; height: 100%; }
.dept b { font-size: clamp(8px, 1.02cqw, 13px); font-weight: 600; color: #edf3ff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dept-metric { font-size: clamp(6.5px, .8cqw, 10px); color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dept[data-accent="indigo"] { --a: #a5b4fc; }
.dept[data-accent="cyan"] { --a: #67e8f9; }
.dept[data-accent="emerald"] { --a: #6ee7b7; }
.dept[data-accent="amber"] { --a: #fcd34d; }
.spark { display: flex; align-items: flex-end; gap: 2px; height: clamp(14px, 2.1cqw, 30px); margin-top: auto; }
.spark i { flex: 1; height: var(--h); background: linear-gradient(180deg, var(--a), rgba(148, 163, 184, .12)); border-radius: 1px; opacity: .75; }
.dept-bar { display: block; height: 2px; background: rgba(148, 163, 184, .16); border-radius: 2px; margin-top: auto; overflow: hidden; }
.dept-bar i { display: block; height: 100%; width: var(--w); background: var(--a); opacity: .7; border-radius: 2px; }
.dept-note { display: flex; align-items: center; gap: 9px; font-size: clamp(7px, .85cqw, 10.5px); line-height: 1.35; }
.dept-note b { display: block; color: var(--ink-2); font-weight: 600; }
.dept-note em { font-style: normal; color: var(--muted-2); font-size: .92em; }

/* ==========================================================================
   SCENE 7 · Analytics
   ========================================================================== */
.visual--dash { display: flex; flex-direction: column; justify-content: center; height: 100%; }
.dash { width: 100%; height: 100%; display: flex; flex-direction: column; padding-bottom: clamp(6px, .8cqw, 10px); }
.kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(5px, .8cqw, 10px); padding: clamp(7px, 1cqw, 12px) clamp(9px, 1.2cqw, 15px); }
.kpi {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: clamp(6px, .85cqw, 11px) clamp(7px, .95cqw, 12px);
  border: 1px solid var(--line);
  border-radius: clamp(6px, .8cqw, 9px);
  background: rgba(148, 163, 184, .045);
}
.kpi-label { font-size: clamp(5.8px, .7cqw, 8.5px); text-transform: uppercase; letter-spacing: .1em; color: var(--muted-2); white-space: nowrap; }
.kpi b { font-size: clamp(11px, 1.5cqw, 19px); font-weight: 600; color: #fff; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.kpi em { font-style: normal; font-size: clamp(5.8px, .7cqw, 8.5px); color: var(--emerald); white-space: nowrap; }
.kpi em.flat { color: var(--muted); }
.chart { padding: 0 clamp(9px, 1.2cqw, 15px); flex: 1; display: flex; flex-direction: column; min-height: 0; }
.chart-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: clamp(4px, .6cqw, 7px) 0;
  font-size: clamp(7px, .84cqw, 10px);
  color: var(--ink-2);
  letter-spacing: .03em;
}
.legend { display: inline-flex; align-items: center; gap: 5px; font-size: .92em; color: var(--muted-2); }
.legend i { width: 10px; height: 2px; border-radius: 2px; display: inline-block; }
.legend-actual { background: linear-gradient(90deg, #818cf8, #22d3ee); }
.legend-forecast { background: repeating-linear-gradient(90deg, #67e8f9 0 3px, transparent 3px 5px); }
.chart-svg { width: 100%; height: 100%; flex: 1; min-height: 0; overflow: visible; }
.chart-svg .line { stroke-dasharray: 1000; stroke-dashoffset: 0; }
.scene.is-active .chart-svg .area { animation: fade-in .9s ease .45s both; }
.scene.is-active .chart-svg .line { animation: draw 1.5s var(--ease) .2s both; }
@keyframes draw { from { stroke-dashoffset: 900; } to { stroke-dashoffset: 0; } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
.forecast { opacity: 0; }
.scene.is-active .forecast { animation: fade-in .7s ease 1.35s both; }
.pulse-now { opacity: 0; transform-box: fill-box; transform-origin: center; }
.scene.is-active .pulse-now { animation: pulse-ring 2.8s ease-out 1.4s infinite; }
@keyframes pulse-ring {
  0% { opacity: .8; transform: scale(1); }
  70%, 100% { opacity: 0; transform: scale(2.4); }
}
.scenarios {
  display: flex;
  align-items: center;
  gap: clamp(5px, .8cqw, 10px);
  flex-wrap: wrap;
  padding: clamp(5px, .7cqw, 9px) clamp(9px, 1.2cqw, 15px) 0;
}
.scenario-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: clamp(6px, .74cqw, 9px);
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--cyan-soft);
}
.scenario {
  font-size: clamp(6.5px, .8cqw, 10px);
  color: var(--muted);
  padding: 3px 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(34, 211, 238, .045);
  white-space: nowrap;
}
.scenario b { color: #d7fbe9; font-weight: 500; font-family: var(--mono); }

/* ==========================================================================
   SCENE 8 · Anywhere
   ========================================================================== */
.feats { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(6px, 1.05cqw, 13px); }
.feat { display: flex; align-items: flex-start; gap: clamp(5px, .7cqw, 8px); min-width: 0; }
.feat-ico {
  width: clamp(18px, 2.1cqw, 27px);
  height: clamp(18px, 2.1cqw, 27px);
  display: grid;
  place-items: center;
  flex: none;
  border: 1px solid rgba(34, 211, 238, .18);
  border-radius: clamp(5px, .65cqw, 8px);
  background: rgba(34, 211, 238, .06);
  color: var(--cyan-soft);
}
.feat-ico .icon { width: 58%; height: 58%; }
.feat b { display: block; font-size: clamp(7.5px, .92cqw, 11.5px); color: #eaf2ff; font-weight: 600; line-height: 1.25; }
.feat em { display: block; font-style: normal; font-size: clamp(6px, .74cqw, 9px); color: var(--muted-2); line-height: 1.35; margin-top: 2px; }
.platforms { display: flex; flex-wrap: wrap; gap: clamp(5px, .7cqw, 9px); }
.platform {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: clamp(3px, .42cqw, 5px) clamp(7px, .85cqw, 10px);
  border: 1px solid var(--line);
  border-radius: 7px;
  background: rgba(15, 26, 46, .48);
  font-size: clamp(7px, .82cqw, 10.5px);
  color: var(--ink-2);
}
.platform .icon { color: var(--muted); }

.devices { position: relative; width: 100%; height: 100%; min-height: 0; }
.visual--devices { height: 100%; min-height: clamp(240px, 34cqw, 460px); }
.device { position: absolute; }
.device--desktop { left: 0; top: 24%; width: 59%; }
.screen {
  border: 1px solid rgba(148, 163, 184, .3);
  border-radius: clamp(6px, .9cqw, 11px);
  background: linear-gradient(165deg, #17243c, #0b1424);
  box-shadow: 0 26px 50px -28px rgba(0, 0, 0, .95), inset 0 1px 0 rgba(255, 255, 255, .06);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  display: flex;
  flex-direction: column;
}
.screen-bar {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: clamp(3px, .45cqw, 6px) clamp(5px, .7cqw, 9px);
  border-bottom: 1px solid var(--line);
  background: rgba(8, 14, 26, .6);
}
.screen-bar i { width: 4px; height: 4px; border-radius: 50%; background: rgba(148, 163, 184, .35); }
.screen-title { margin-left: auto; font-size: clamp(4.5px, .55cqw, 7px); letter-spacing: .08em; text-transform: uppercase; color: var(--muted-2); }
.screen-body { display: grid; grid-template-columns: 18% 1fr; flex: 1; min-height: 0; }
.screen-side { border-right: 1px solid var(--line); padding: clamp(4px, .55cqw, 8px) clamp(3px, .45cqw, 6px); display: flex; flex-direction: column; gap: clamp(3px, .45cqw, 6px); background: rgba(9, 16, 28, .5); }
.screen-side i { display: block; height: clamp(3px, .42cqw, 6px); border-radius: 2px; background: rgba(148, 163, 184, .18); }
.screen-side i:first-child { background: rgba(34, 211, 238, .45); width: 80%; }
.screen-main { padding: clamp(5px, .7cqw, 10px); display: flex; flex-direction: column; gap: clamp(4px, .55cqw, 7px); min-height: 0; }
.screen-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(3px, .4cqw, 5px); }
.screen-kpis span { height: clamp(10px, 1.4cqw, 18px); border-radius: 3px; border: 1px solid var(--line); background: rgba(148, 163, 184, .07); }
.screen-chart { flex: 1; min-height: 0; border: 1px solid var(--line); border-radius: 3px; background: rgba(34, 211, 238, .03); padding: 3px; }
.screen-chart svg { width: 100%; height: 100%; }
.screen-rows { display: flex; flex-direction: column; gap: 3px; }
.screen-rows span { height: 3px; border-radius: 2px; background: rgba(148, 163, 184, .16); }
.screen-rows span:nth-child(2) { width: 84%; }
.screen-rows span:nth-child(3) { width: 66%; }
.stand {
  width: 22%;
  height: clamp(12px, 1.8cqw, 24px);
  margin: 0 auto;
  background: linear-gradient(180deg, rgba(148, 163, 184, .22), rgba(148, 163, 184, .04));
  clip-path: polygon(38% 0, 62% 0, 70% 78%, 88% 88%, 88% 100%, 12% 100%, 12% 88%, 30% 78%);
}
.device--tablet { right: 0; top: 3%; width: 29%; }
.tablet-screen {
  border: 1px solid rgba(148, 163, 184, .28);
  border-radius: clamp(7px, .95cqw, 12px);
  background: linear-gradient(165deg, #16233b, #0a1322);
  padding: clamp(5px, .7cqw, 9px);
  aspect-ratio: 3 / 4;
  display: flex;
  flex-direction: column;
  gap: clamp(4px, .55cqw, 7px);
  box-shadow: 0 24px 44px -26px rgba(0, 0, 0, .95);
}
.tablet-head { height: clamp(4px, .55cqw, 7px); width: 55%; border-radius: 3px; background: rgba(34, 211, 238, .4); }
.tablet-grid { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: clamp(3px, .45cqw, 6px); }
.tablet-grid span { border: 1px solid var(--line); border-radius: 4px; background: rgba(148, 163, 184, .06); }
.tablet-grid span:nth-child(2) { background: rgba(99, 102, 241, .16); }
.device--phone { right: 6%; bottom: 5%; width: 17%; }
.phone-screen {
  position: relative;
  border: 1.5px solid rgba(148, 163, 184, .4);
  border-radius: clamp(8px, 1.15cqw, 14px);
  background: linear-gradient(170deg, #16233b, #0a1322);
  aspect-ratio: 9 / 19;
  padding: clamp(7px, 1cqw, 12px) clamp(4px, .55cqw, 7px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(3px, .42cqw, 5px);
  box-shadow: 0 26px 46px -24px rgba(0, 0, 0, .95), inset 0 1px 0 rgba(255, 255, 255, .08);
}
.phone-notch {
  position: absolute;
  top: 4%;
  left: 50%;
  transform: translateX(-50%);
  width: 30%;
  height: clamp(5px, .7cqw, 9px);
  border-radius: 999px;
  background: rgba(5, 9, 16, .9);
  z-index: 2;
}
.phone-screen {
  position: relative;
}
.phone-head { margin-top: 10%; font-size: clamp(4.5px, .58cqw, 7px); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.otp { display: flex; gap: 2px; width: 100%; justify-content: center; }
.otp span {
  flex: 1;
  max-width: 12px;
  display: grid;
  place-items: center;
  aspect-ratio: 1 / 1.25;
  border: 1px solid rgba(148, 163, 184, .3);
  border-radius: 2px;
  font-family: var(--mono);
  font-size: clamp(5px, .62cqw, 7.5px);
  color: var(--cyan-soft);
  background: rgba(148, 163, 184, .06);
}
.otp span.otp-focus { border-color: var(--cyan); box-shadow: 0 0 0 1px rgba(34, 211, 238, .25); background: rgba(34, 211, 238, .12); }
.phone-note { font-size: clamp(4px, .52cqw, 6.5px); line-height: 1.5; text-align: center; color: var(--muted-2); }
.phone-note b { color: var(--ink-2); font-family: var(--mono); }
.phone-btn { margin-top: auto; width: 80%; height: clamp(6px, .8cqw, 10px); border-radius: 3px; background: linear-gradient(90deg, #818cf8, #22d3ee); opacity: .85; }
.float--offline { left: 1%; top: 1%; }
.float--offline .icon { color: var(--amber); width: 14px; height: 14px; }
.float--synced { left: 34%; bottom: 4%; animation-delay: -3s; }
.device, .float--offline, .float--synced { z-index: 2; }

/* ==========================================================================
   SCENE 9 · License + CTA
   ========================================================================== */
.copy--cta { gap: clamp(8px, 1.15cqw, 13px); }
.cta-block { margin-top: clamp(2px, .5cqw, 6px); display: flex; flex-direction: column; gap: clamp(7px, 1cqw, 12px); }
.price-row { display: flex; align-items: center; gap: clamp(10px, 1.8cqw, 22px); flex-wrap: wrap; }
.price { display: flex; align-items: baseline; gap: 4px; color: #f2f7ff; }
.price-from { font-size: clamp(7px, .85cqw, 10.5px); text-transform: uppercase; letter-spacing: .14em; color: var(--muted); align-self: center; margin-right: 2px; }
.price-amount { font-size: clamp(22px, 3.4cqw, 44px); font-weight: 750; letter-spacing: -.04em; line-height: 1; background: linear-gradient(100deg, #fff, #a5f3fc); -webkit-background-clip: text; background-clip: text; color: transparent; }
.price-once { font-size: clamp(7px, .9cqw, 11px); color: var(--muted); }
.price-note { font-size: clamp(6.5px, .8cqw, 10px); line-height: 1.4; color: var(--muted); }
.cta-row { display: flex; align-items: center; gap: clamp(6px, .8cqw, 10px); flex-wrap: wrap; }
.btn-cta, .btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: clamp(7px, .95cqw, 12px) clamp(12px, 1.5cqw, 20px);
  border-radius: 8px;
  font-size: clamp(8px, 1cqw, 12.5px);
  font-weight: 650;
  letter-spacing: .01em;
  min-height: clamp(30px, 3.4cqw, 42px);
  transition: transform .25s var(--ease), box-shadow .25s ease, background-color .25s ease, border-color .25s ease;
  white-space: nowrap;
}
.btn-cta {
  color: #041018;
  background: linear-gradient(100deg, #a5b4fc, #67e8f9 90%);
  box-shadow: 0 12px 28px -14px rgba(34, 211, 238, .6), inset 0 1px 0 rgba(255, 255, 255, .5);
}
.btn-cta:hover { transform: translateY(-1px); box-shadow: 0 16px 34px -12px rgba(34, 211, 238, .7); }
.btn-ghost { color: var(--ink-2); border: 1px solid var(--line-2); background: rgba(15, 26, 46, .4); }
.btn-ghost:hover { border-color: rgba(103, 232, 249, .45); color: #fff; background: rgba(34, 211, 238, .07); }
.visual--license { position: relative; display: flex; flex-direction: column; justify-content: center; }
.license {
  width: 100%;
  max-width: 600px;
  margin-left: auto;
  padding: clamp(10px, 1.45cqw, 19px);
}
.lic-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding-bottom: clamp(6px, .85cqw, 11px); border-bottom: 1px solid var(--line); }
.lic-brand { font-size: clamp(8px, .95cqw, 11.5px); font-weight: 800; letter-spacing: .16em; color: #e8effb; }
.lic-brand em { font-style: normal; font-weight: 500; letter-spacing: .1em; color: var(--muted-2); font-size: .82em; text-transform: uppercase; margin-left: 4px; }
.lic-token {
  margin: clamp(6px, .8cqw, 10px) 0;
  padding: clamp(5px, .7cqw, 9px) clamp(6px, .8cqw, 10px);
  border: 1px dashed rgba(148, 163, 184, .22);
  border-radius: 5px;
  background: rgba(5, 9, 16, .45);
  color: var(--muted);
  font-size: clamp(6px, .72cqw, 9px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  direction: ltr;
  text-align: left;
}
.lic-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(6px, .95cqw, 12px) clamp(10px, 1.6cqw, 20px); }
.lic-grid div { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.lic-grid span { font-size: clamp(5.5px, .68cqw, 8px); text-transform: uppercase; letter-spacing: .1em; color: var(--muted-2); }
.lic-grid b { font-size: clamp(7px, .84cqw, 10.5px); font-weight: 500; color: #dfe9f8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.proof { display: flex; align-items: center; gap: clamp(3px, .6cqw, 7px); margin-top: clamp(9px, 1.35cqw, 16px); }
.proof-step { display: flex; flex-direction: column; align-items: center; gap: 3px; text-align: center; flex: 1; min-width: 0; }
.proof-step i {
  width: clamp(16px, 2cqw, 24px);
  height: clamp(16px, 2cqw, 24px);
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(52, 211, 153, .1);
  border: 1px solid rgba(52, 211, 153, .35);
  color: #6ee7b7;
}
.proof-step i .icon { width: 55%; height: 55%; }
.proof-step b { display: block; font-size: clamp(5.8px, .7cqw, 8.5px); font-weight: 600; color: #e6eefc; white-space: nowrap; }
.proof-step span { display: block; font-size: clamp(5.2px, .62cqw, 7.5px); color: var(--muted-2); white-space: nowrap; }
.proof-line { flex: 1; height: 1px; background: rgba(52, 211, 153, .3); margin-bottom: clamp(14px, 1.7cqw, 22px); }
.lic-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: clamp(7px, .9cqw, 11px);
  padding-top: clamp(5px, .65cqw, 8px);
  border-top: 1px solid var(--line);
  font-size: clamp(5.5px, .68cqw, 8px);
  color: var(--muted-2);
}
.lic-foot .mono { letter-spacing: 0; }
.seal {
  position: relative;
  flex: none;
  display: block;
  margin: clamp(-26px, -2cqw, -12px) clamp(2px, .8cqw, 12px) 0 auto;
  width: clamp(62px, 7.4cqw, 94px);
  height: clamp(62px, 7.4cqw, 94px);
  transform: rotate(-9deg);
  filter: drop-shadow(0 14px 24px rgba(0, 0, 0, .6));
}

/* ---------- Stage brand ---------- */
.stage-brand {
  position: absolute;
  right: clamp(10px, 1.8cqw, 20px);
  bottom: clamp(7px, 1.1cqw, 13px);
  z-index: 7;
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: clamp(6px, .72cqw, 9px);
  letter-spacing: .24em;
  font-weight: 700;
  color: rgba(200, 212, 230, .6);
  pointer-events: none;
}
.sb-mark { width: clamp(9px, 1.1cqw, 13px); height: clamp(9px, 1.1cqw, 13px); color: rgba(103, 232, 249, .65); }
.sb-mark svg { width: 100%; height: 100%; }

/* ---------- HUD ---------- */
.hud {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 14px;
  padding: clamp(10px, 1.6vh, 16px) 2px 0;
}
.transport { display: flex; align-items: center; gap: 7px; justify-self: start; }
.ctl {
  width: clamp(34px, 3vw, 42px);
  height: clamp(34px, 3vw, 42px);
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: rgba(15, 26, 46, .55);
  color: var(--ink-2);
  transition: color .2s ease, border-color .2s ease, background-color .2s ease, transform .2s var(--ease);
}
.ctl .icon { width: 17px; height: 17px; }
.ctl:hover { color: #fff; border-color: rgba(103, 232, 249, .45); background: rgba(34, 211, 238, .08); }
.ctl:active { transform: scale(.96); }
.ctl--play {
  width: clamp(42px, 3.6vw, 50px);
  height: clamp(42px, 3.6vw, 50px);
  border: 0;
  color: #051019;
  background: linear-gradient(145deg, #c7d2fe, #67e8f9);
  box-shadow: 0 10px 26px -12px rgba(103, 232, 249, .8), inset 0 1px 0 rgba(255, 255, 255, .55);
}
.ctl--play:hover { color: #051019; background: linear-gradient(145deg, #dbe3ff, #8df0fb); }
.ctl--play .icon { width: 18px; height: 18px; }
.ico-play { display: none; }
.hud.is-paused .ico-pause { display: none; }
.hud.is-paused .ico-play { display: block; }
.counter {
  display: flex;
  align-items: baseline;
  gap: 3px;
  margin-left: 6px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: .08em;
  color: var(--muted-2);
}
.counter b { color: var(--ink); font-weight: 500; font-size: 13px; }
.counter span:first-of-type { color: rgba(148, 163, 184, .45); }
.dots { display: flex; align-items: center; justify-content: center; gap: clamp(2px, .5vw, 6px); justify-self: center; }
.dot {
  width: clamp(20px, 2vw, 26px);
  height: 30px;
  padding: 0;
  border: 0;
  background: none;
  display: grid;
  place-items: center;
  border-radius: 999px;
}
.dot i {
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: rgba(148, 163, 184, .3);
  transition: width .35s var(--ease), background-color .3s ease, box-shadow .3s ease;
}
.dot:hover i { background: rgba(148, 163, 184, .6); }
.dot.is-active i { width: 22px; background: linear-gradient(90deg, #818cf8, #22d3ee); box-shadow: 0 0 12px rgba(34, 211, 238, .35); }
.hint {
  justify-self: end;
  font-size: 10.5px;
  color: var(--muted-2);
  letter-spacing: .03em;
  white-space: nowrap;
}
.hint kbd {
  display: inline-grid;
  place-items: center;
  min-width: 19px;
  height: 19px;
  padding: 0 4px;
  margin-right: 2px;
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 4px;
  background: rgba(148, 163, 184, .06);
  font-family: var(--font);
  font-size: 10px;
  color: var(--ink-2);
}
.hint span { color: rgba(148, 163, 184, .35); margin: 0 3px; }

.chapters { display: none; }

/* ---------- Footer ---------- */
.footer {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: clamp(8px, 1.4vh, 14px) 2px 0;
  border-top: 1px solid rgba(148, 163, 184, .08);
  font-size: 10.5px;
  color: var(--muted-2);
  flex-wrap: wrap;
}
.footer-left { letter-spacing: .08em; text-transform: uppercase; font-size: 9.5px; }
.footer-left span { color: rgba(148, 163, 184, .35); margin: 0 4px; }
.footer-legal { color: var(--muted); letter-spacing: .01em; }

/* Chrome-off (embed mode) */
body.chrome-off .topbar,
body.chrome-off .hud,
body.chrome-off .footer { display: none !important; }
body.chrome-off .player { padding: 0; }
body.chrome-off .player-shell { width: min(1280px, 100%, calc(100svh * 1.7778)); }

/* ==========================================================================
   Responsive tiers (stage container)
   ========================================================================== */
@container stage (max-width: 1080px) {
  .scene { gap: 10px; }
  .split { gap: clamp(14px, 3cqw, 34px); }
  .float--sync { left: -4px; }
  .float--date { right: -2px; }
  .head-lede { flex-basis: 40%; }
}

@container stage (max-width: 900px) {
  .scene { padding: 22px 28px 22px; }
  .split { grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); }
  .checks { gap: 5px; }
  .head-stat { display: none; }
  .profiles { gap: 6px; }
  .prof span { font-size: 9.5px; }
  .dept-metric { display: none; }
  .dept { gap: 4px; }
  .opt-body p { display: none; }
  .optimizer { grid-template-columns: auto 1fr auto; }
  .opt-title { font-size: 9px; }
  .float { font-size: 8px; padding: 5px 7px; }
  .float--sync { left: 0; bottom: 0; }
  .dates-label { display: none; }
  .lang-note { display: none; }
}

/* Stacked layout for narrow stages (small tablets / phones) */
@container stage (max-width: 780px) {
  .scene { padding: 16px 18px 16px; gap: 8px; }
  .scene-no { top: 8px; right: 12px; font-size: 8px; }
  .split, .split--hero, .split--copy-wide, .split--license {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr);
    gap: 8px;
    align-items: stretch;
    align-content: stretch;
  }
  .copy { gap: 5px; }
  .lede {
    font-size: 10px;
    line-height: 1.45;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .checks, .feats, .lang-toggle, .dept-note, .chips--tight { display: none; }
  .chips { gap: 4px; }
  .chip { font-size: 7.5px; padding: 2px 6px; }
  .h2 { font-size: clamp(18px, 3.4cqw, 27px); }
  .hero-title { font-size: clamp(20px, 4.6cqw, 34px); }
  .tagline { font-size: 10px; }
  .eyebrow { font-size: 7px; letter-spacing: .18em; }
  .visual { height: 100%; }
  .scene-head { flex: none; }
  .scene-head .head-lede { display: none; }

  /* brand */
  .visual--brand { min-height: 80px; }
  .ledger { width: min(100%, 420px); }
  .float--date { display: none; }
  .float--sync { left: auto; right: 0; bottom: -2px; }
  .ledger-rows .lrow:nth-child(n+4) { display: none; }

  /* profiles */
  .profiles { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; }
  .prof { padding: 5px 7px; flex-direction: row; align-items: center; gap: 5px; }
  .prof > span { font-size: 8px; }
  .prof .icon { width: 13px; height: 13px; }
  .prof:nth-child(n+13) { display: none; }
  .prof--note { display: none; }

  /* ledger scene */
  .visual--ledger { justify-content: flex-start; gap: 6px; }
  .mini-grid { display: none; }
  .jpanel { width: 100%; }

  /* bilingual */
  .bilingual { grid-template-columns: 1fr 1fr; gap: 6px; }
  .mirror { display: none; }
  .inv { padding: 7px; gap: 3px; }
  .inv-kicker { font-size: 8px; }
  .inv-meta, .inv-row, .inv-foot { font-size: 7px; }
  .inv-total { font-size: 7.5px; }
  .inv-total b { font-size: 10px; }
  .dates { padding: 4px 8px; font-size: 7px; gap: 6px; }
  .date-chip b { font-size: .95em; }
  .date-eq { display: none; }

  /* operations */
  .scene--ops .scene-head { gap: 6px; }
  .flow { flex: 1; justify-content: flex-start; gap: 6px; }
  .flow-nodes { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
  .node { padding: 6px; height: auto; min-height: 0; }
  .node:nth-child(n+4) { display: none; }
  .node em { display: none; }
  .node-tag { display: none; }
  .node::after { display: none; }
  .flow-track { display: none; }
  .trace { display: none; }
  .optimizer { grid-template-columns: auto 1fr; padding: 6px 8px; gap: 8px; }
  .opt-art { width: 54px; }
  .opt-stats { display: none; }
  .opt-title { font-size: 8px; }
  .opt-body p { display: block; font-size: 6.5px; }

  /* departments */
  .visual--depts { height: auto; }
  .dept-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
  .dept { padding: 6px 7px; min-height: 0; }
  .dept:nth-child(n+7) { display: none; }
  .dept b { font-size: 8px; }
  .dept-ico { width: 15px; height: 15px; }
  .spark { display: none; }

  /* analytics */
  .kpis { padding: 6px 8px; gap: 4px; }
  .kpi { padding: 5px 6px; }
  .kpi b { font-size: 12px; }
  .kpi em { display: none; }
  .chart { padding: 0 8px; }
  .chart-svg .axis text { font-size: 10px; }
  .scenarios { display: none; }

  /* anywhere */
  .split--copy-wide .visual--devices { min-height: 94px; }
  .device--desktop { top: 26%; width: 54%; }
  .device--tablet { width: 27%; }
  .device--phone { width: 15%; right: 4%; }
  .float--offline { top: 0; left: 0; }
  .float--synced { left: auto; right: 22%; bottom: -2px; }
  .platforms { gap: 4px; }
  .platform { font-size: 7px; padding: 2px 5px; }

  /* license */
  .license { max-width: none; }
  .proof { margin-top: 6px; }
  .proof-step span { display: none; }
  .lic-token { display: none; }
  .cta-row { gap: 6px; }
  .btn-cta, .btn-ghost { min-height: 28px; padding: 5px 10px; font-size: 8.5px; }
  .price-note { display: none; }
  .seal { width: 54px; height: 54px; margin-top: -10px; margin-right: 4px; }
  .stage-brand { display: none; }
}

/* Phones — compact poster mode */
@container stage (max-width: 560px) {
  .scene { padding: 9px 11px 9px; gap: 4px; }
  .scene-no { display: none; }
  .split { gap: 4px; }
  .copy { gap: 3px; }
  .h2 { font-size: 17px; line-height: 1.1; }
  .hero-title { font-size: 25px; }
  .tagline { font-size: 9px; line-height: 1.3; }
  .eyebrow { font-size: 6px; gap: 4px; letter-spacing: .16em; }
  .lede, .checks, .feats, .lang-toggle, .dates, .dept-note, .chips, .platforms { display: none; }
  .scene-caption {
    display: block;
    font-size: 7px;
    line-height: 1.35;
    color: var(--ink-2);
    max-width: 100%;
  }
  .sample-note, .head-stat { display: none; }
  .panel-head { padding: 3px 5px; font-size: 6.5px; gap: 4px; }
  .pill { font-size: 5px; padding: 1px 3px; }
  .pill .icon { display: none; }

  /* 01 · brand: type only */
  .scene--brand .visual--brand { display: none; }
  .split--hero { grid-template-rows: 1fr; align-content: center; }
  .scene--brand .copy { justify-content: center; gap: 4px; }
  .scene--brand .tagline { display: block; font-size: 9.5px; }
  .scene--brand .chips { display: flex; }
  .chip { font-size: 5.5px; padding: 1px 4px; }
  .scene--brand .scene-caption { display: none; }

  /* 02 · profiles: 9 trades + one-ledger tile */
  .profiles { grid-template-columns: repeat(5, minmax(0, 1fr)); grid-auto-rows: minmax(0, 1fr); gap: 3px; }
  .prof { flex-direction: column; align-items: flex-start; justify-content: center; gap: 2px; padding: 3px 4px; border-radius: 5px; }
  .prof:nth-child(n+11) { display: none; }
  .prof--note { display: none !important; }
  .prof .icon { width: 10px; height: 10px; }
  .prof > span { font-size: 5.2px; line-height: 1.1; }
  .prof:nth-child(9) { grid-column: auto; }
  .prof:nth-child(9) > span { font-size: 5.2px; }

  /* 03 · journal only, larger rows */
  .visual--ledger { height: 100%; justify-content: flex-start; gap: 4px; }
  .mini-grid { display: none; }
  .jt { padding: 0 6px; }
  .jt-row { grid-template-columns: minmax(0, 1fr) 44px 44px; font-size: 7.5px; padding: 5px 0; gap: 3px; }
  .jt-row--head { display: none; }
  .jt-row > span:nth-child(2), .jt-row > span:nth-child(3) { font-size: 7.5px; }
  .acct { gap: 3px; }
  .acct em { display: none; }
  .jt-foot { font-size: 6.5px; padding: 5px 6px; gap: 3px; }
  .jt-foot .pill { display: none; }

  /* 04 · bilingual: one RTL invoice */
  .bilingual { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .inv--en, .mirror, .dates { display: none; }
  .inv { width: 100%; padding: 7px 9px; gap: 4px; }
  .inv--fa .inv-kicker { font-size: 10px; }
  .inv-meta { font-size: 7.5px; }
  .inv-row { font-size: 7.5px; }
  .inv-total { font-size: 7.5px; }
  .inv-total b { font-size: 12px; }
  .inv-foot { font-size: 6px; }
  .lang-toggle, .lang-note { display: none; }

  /* 05 · six steps in two rows + optimizer strip */
  .scene--ops .scene-head { gap: 4px; }
  .flow { flex: 1; justify-content: flex-start; gap: 4px; min-height: 0; }
  .flow-band { flex: 1; min-height: 0; }
  .flow-nodes { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: 1fr 1fr; height: 100%; gap: 3px; }
  .node { height: auto; min-height: 0; flex-direction: row; align-items: center; gap: 3px; padding: 4px 5px; }
  .node:nth-child(n+4) { display: flex; }
  .node-no, .node em, .node-tag, .node::after { display: none; }
  .node b { font-size: 6px; white-space: normal; line-height: 1.15; }
  .node-ico { width: 12px; height: 12px; border-radius: 2px; }
  .node-ico .icon { width: 70%; height: 70%; }
  .flow-track, .trace { display: none; }
  .optimizer { display: flex; align-items: center; gap: 4px; padding: 3px 6px; }
  .opt-art, .opt-body p { display: none; }
  .opt-title { font-size: 6px; gap: 3px; }
  .opt-stats { display: flex; margin-left: auto; gap: 6px; }
  .opt-stats b { font-size: 6.5px; }
  .opt-stats span { font-size: 4px; letter-spacing: .02em; }

  /* 06 · all nine departments, 3 x 3 */
  .visual--depts { height: 100%; }
  .dept-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(3, 1fr); gap: 3px; height: 100%; }
  .dept { flex-direction: row; align-items: center; gap: 3px; padding: 3px 4px; min-height: 0; }
  .dept:nth-child(n+7) { display: flex; }
  .dept-ico { width: 11px; height: 11px; }
  .dept b { font-size: 6px; }
  .dept-metric, .spark, .dept-bar { display: none; }

  /* 07 · dashboard */
  .dash { padding-bottom: 2px; }
  .kpis { padding: 3px 4px; gap: 3px; }
  .kpi { padding: 3px 4px; border-radius: 4px; }
  .kpi-label { font-size: 4.6px; }
  .kpi b { font-size: 8.5px; }
  .kpi em { display: none; }
  .chart { padding: 0 4px; }
  .chart-head { font-size: 5.5px; padding: 2px 0; }
  .legend { display: none; }
  .chart-svg .axis text { font-size: 13px; }
  .scenarios { display: none; }

  /* 08 · features + platforms, no device mock */
  .scene--anywhere .visual--devices { display: none; }
  .scene--anywhere .split { grid-template-rows: 1fr; align-content: center; }
  .scene--anywhere .copy { justify-content: center; }
  .scene--anywhere .feats { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin-top: 2px; }
  .feat { gap: 4px; align-items: center; }
  .feat-ico { width: 13px; height: 13px; }
  .feat b { font-size: 6.5px; }
  .feat em { display: none; }
  .scene--anywhere .platforms { display: flex; flex-wrap: wrap; gap: 3px; }
  .platform { font-size: 6px; padding: 2px 4px; gap: 3px; }
  .platform .icon { width: 8px; height: 8px; }

  /* 09 · pricing call to action */
  .visual--license, .seal { display: none; }
  .split--license { grid-template-rows: 1fr; align-content: center; }
  .copy--cta { justify-content: center; gap: 4px; }
  .price-amount { font-size: 26px; }
  .price-from { font-size: 6px; }
  .price-once { font-size: 6.5px; }
  .price-note { display: none; }
  .btn-cta, .btn-ghost { font-size: 8px; min-height: 26px; padding: 4px 9px; }
  .cta-block { gap: 5px; margin-top: 1px; }
  .price-row { gap: 8px; }
}

/* Very small stages (embedded thumbnails, 320 px phones) */
@container stage (max-width: 400px) {
  .scene { padding: 7px 9px; }
  .h2 { font-size: 15.5px; }
  .hero-title { font-size: 22px; }
  .scene-caption { font-size: 6.5px; }
  .kpi b { font-size: 8px; }
  .prof > span { font-size: 4.9px; }
  .jt-row { font-size: 6.5px; }
  .jt-foot { font-size: 5.5px; }
}

/* ==========================================================================
   Page-level responsive (outside the stage)
   ========================================================================== */
@media (max-width: 760px) {
  .topbar-meta { display: none; }
  .topbar-link { font-size: 10px; padding: 6px 10px; }
  .wordmark { font-size: 12px; }
  .brand-sub { font-size: 8px; }
  .hud { grid-template-columns: 1fr; justify-items: center; gap: 2px; padding-top: 8px; }
  .transport { justify-self: center; }
  .dots { order: 2; }
  .hint { display: none; }
  .counter { display: none; }
  .footer { justify-content: center; text-align: center; gap: 4px; font-size: 9px; }
  .footer-left { font-size: 8px; }
  .player-shell { width: 100%; }
}
@media (max-width: 560px) {
  .player { align-items: flex-start; padding-top: 10px; padding-bottom: 6px; }
  .chapters {
    display: grid;
    gap: 2px;
    width: 100%;
    margin: clamp(8px, 2.4vw, 14px) 0 0;
  }
  .chapter {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    min-height: 34px;
    padding: 7px 10px;
    border: 1px solid rgba(148, 163, 184, .1);
    border-radius: 8px;
    background: rgba(15, 26, 46, .38);
    color: var(--muted-2);
    text-align: left;
    transition: border-color .2s ease, background-color .2s ease, color .2s ease;
  }
  .chapter .ch-num {
    font-family: var(--mono);
    font-size: 9px;
    letter-spacing: .08em;
    color: var(--muted-2);
  }
  .chapter .ch-title {
    font-size: 11.5px;
    letter-spacing: .01em;
    color: var(--ink-2);
  }
  .chapter .ch-arrow {
    width: 11px;
    height: 11px;
    margin-left: auto;
    opacity: .25;
  }
  .chapter:hover { border-color: rgba(148, 163, 184, .28); }
  .chapter.is-active {
    border-color: rgba(103, 232, 249, .34);
    background: rgba(34, 211, 238, .07);
  }
  .chapter.is-active .ch-num,
  .chapter.is-active .ch-title { color: #fff; }
  .chapter.is-active .ch-arrow { opacity: .75; color: var(--cyan-soft); }
  .chapter:focus-visible { outline: 2px solid var(--cyan-soft); outline-offset: 2px; }
}
@media (max-width: 400px) {
  .page { padding: 8px 8px 10px; }
  .brand-mark { width: 27px; height: 27px; }
  .brand-mark svg { width: 20px; height: 20px; }
  .topbar-link { display: none; }
  .hud { padding-top: 6px; }
  .dot { width: 24px; height: 26px; }
  .dot.is-active i { width: 16px; }
  .ctl { width: 34px; height: 34px; }
  .ctl--play { width: 42px; height: 42px; }
}
@media (max-height: 520px) and (min-width: 761px) {
  .player { padding: 8px 0; }
  .player-shell { width: min(1280px, 100%, calc((100svh - 150px) * 1.7778)); }
  .footer { display: none; }
}

/* ==========================================================================
   Motion preferences
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  .anim, .lrow { opacity: 1 !important; transform: none !important; }
  .scene { transform: none !important; }
  .ledger, .scene.is-active .ledger { transform: none !important; }
  .chart-svg .line { stroke-dashoffset: 0 !important; }
  .chart-svg .area, .forecast, .pulse-now { opacity: 1 !important; }
  .flow-track i { transform: scaleX(1) !important; }
  .flow-track::after, .ledger-scan { display: none !important; }
  .aurora::before, .aurora::after, .float { animation: none !important; }
}
html[data-motion="off"] *, html[data-motion="off"] *::before, html[data-motion="off"] *::after {
  animation-duration: .001ms !important;
  animation-iteration-count: 1 !important;
  transition-duration: .001ms !important;
}
html[data-motion="off"] .anim,
html[data-motion="off"] .lrow { opacity: 1 !important; transform: none !important; }
html[data-motion="off"] .scene { transform: none !important; }
html[data-motion="off"] .ledger,
html[data-motion="off"] .scene.is-active .ledger { transform: none !important; }
html[data-motion="off"] .flow-track i { transform: scaleX(1) !important; }
html[data-motion="off"] .flow-track::after,
html[data-motion="off"] .ledger-scan { display: none !important; }
html[data-motion="off"] .aurora::before,
html[data-motion="off"] .aurora::after,
html[data-motion="off"] .float { animation: none !important; }

/* ---- Compact-mode refinements (phones) ---- */
@container stage (max-width: 560px) {
  .scene--bilingual .dates { display: flex; flex-wrap: nowrap; padding: 3px 6px; gap: 5px; font-size: 6px; margin-top: 3px; }
  .scene--bilingual .dates-label { display: none; }
  .scene--bilingual .date-eq { display: inline; }
  .scene--bilingual .date-chip b { font-size: 6px; }
  .scene--anywhere .feat b { font-size: 7px; }
  .scene--anywhere .platform { font-size: 6.5px; }
  .scene--license .checks { display: grid; grid-template-columns: 1fr 1fr; gap: 2px 8px; }
  .scene--license .checks li { font-size: 6px; gap: 3px; line-height: 1.3; }
  .scene--license .checks .icon { width: 6px; height: 6px; }
  .scene--ops .opt-stats div:nth-child(2) { display: none; }
}
