/* ============================================================
   Vishwaguru - landing page
   The page runs from night to morning: the data goes in after the
   close, the plan comes out before the 9:15 open. One typeface for
   the page (Schibsted Grotesk). The tour window keeps the terminal's
   own look and face, because it is a piece of the real product.
   ============================================================ */

:root {
  --night: #0B0F14;
  --night-2: #141A22;
  --night-3: #1C2430;
  --on-night: #ECE9E1;
  --on-night-2: #A3ABB5;

  --paper: #EDEBE5;
  --paper-2: #E2DFD7;
  --paper-3: #F6F5F1;
  --ink: #111316;
  --ink-2: #4B5058;

  --field: #12291F;
  --field-2: #19362A;
  --on-field: #E9E8DF;
  --on-field-2: #A9B8AE;

  --sun: #F2B33D;
  --sun-hi: #F7C766;
  --up: #2FA36E;
  --dn: #D9534A;

  --font: 'Schibsted Grotesk', 'Helvetica Neue', Arial, sans-serif;

  --wrap: 1360px;
  --gutter: 20px;
  --bar-h: 64px;
  --ease: cubic-bezier(.22, .8, .24, 1);
  --ease-io: cubic-bezier(.65, 0, .35, 1);
}
@media (min-width: 760px) { :root { --gutter: 32px; } }
@media (min-width: 1200px) { :root { --gutter: 40px; } }

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--bar-h) + 16px);
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 18px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
  font-feature-settings: 'ss01';
}

h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg, canvas { display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }

:focus-visible { outline: 3px solid var(--sun); outline-offset: 3px; }
::selection { background: var(--sun); color: var(--night); }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--sun); color: var(--night); padding: 10px 14px; font-weight: 600;
}
.skip-link:focus { left: 8px; top: 8px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- Fields ---------- */
.night { background: var(--night); color: var(--on-night); }
.paper { background: var(--paper); }
.paper-2 { background: var(--paper-2); }
.ink { background: var(--field); color: var(--on-field); }

.sec { padding: clamp(96px, 13vw, 200px) 0; }

/* ---------- Type ---------- */
.display {
  font-size: clamp(38px, 5.2vw, 76px);
  font-weight: 700;
  line-height: .98;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
.h2 {
  font-size: clamp(32px, 4.2vw, 60px);
  font-weight: 700;
  line-height: 1.02;
  letter-spacing: -0.03em;
  text-wrap: balance;
}
.lede { font-size: clamp(18px, 1.5vw, 21px); line-height: 1.5; max-width: 34em; }
.sec-sub { font-size: clamp(17px, 1.4vw, 20px); line-height: 1.5; max-width: 32em; }
.night .lede, .night .sec-sub { color: var(--on-night-2); }
.ink .sec-sub { color: var(--on-field-2); }

.sec-head.split {
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 24px 64px; align-items: end;
}
@media (max-width: 859px) { .sec-head.split { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 54px; padding: 0 26px; border-radius: 2px;
  font-family: var(--font); font-size: 17px; font-weight: 600; letter-spacing: -0.01em;
  text-decoration: none; border: 2px solid transparent; cursor: pointer; white-space: nowrap;
  transition: background-color .2s, color .2s, border-color .2s, transform .18s var(--ease);
}
.btn:active { transform: scale(.97); }
.btn-sun { background: var(--sun); color: var(--night); }
.btn-sun:hover { background: var(--sun-hi); }
.btn-dark { background: var(--night); color: var(--on-night); }
.btn-dark:hover { background: var(--night-3); }
.btn-line { border-color: currentColor; background: transparent; }
.btn-line:hover { background: var(--on-field); color: var(--field); border-color: var(--on-field); }
.btn:disabled { opacity: .6; cursor: wait; }

/* ---------- Top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50; height: var(--bar-h);
  background: var(--night); color: var(--on-night);
}
.topbar-in { height: 100%; display: flex; align-items: center; gap: 28px; }
.mark { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 19px; letter-spacing: -0.02em; }
.nav { display: flex; gap: 28px; margin-left: auto; }
.nav a {
  position: relative; text-decoration: none; color: var(--on-night-2); font-size: 16px; font-weight: 500;
  padding: 6px 0; transition: color .2s;
}
.nav a::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--sun);
  transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.nav a:hover { color: var(--on-night); }
.nav a:hover::after { transform: scaleX(1); }
.topbar-cta {
  display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border-radius: 2px;
  background: var(--sun); color: var(--night); text-decoration: none; font-weight: 600; font-size: 15px;
  transition: background-color .2s, transform .18s var(--ease);
}
.topbar-cta:hover { background: var(--sun-hi); }
.topbar-cta:active { transform: scale(.96); }
.menu-btn {
  display: none; width: 44px; height: 44px; border: 0; background: transparent; cursor: pointer; position: relative;
}
.menu-btn span {
  position: absolute; left: 11px; right: 11px; height: 2px; background: var(--on-night);
  transition: transform .3s var(--ease), top .3s var(--ease);
}
.menu-btn span:first-child { top: 17px; }
.menu-btn span:last-child { top: 25px; }
.nav-open .menu-btn span:first-child { top: 21px; transform: rotate(45deg); }
.nav-open .menu-btn span:last-child { top: 21px; transform: rotate(-45deg); }

@media (max-width: 859px) {
  .topbar-in { gap: 12px; }
  .topbar-cta { margin-left: auto; }
  .menu-btn { display: block; }
  .nav {
    position: fixed; top: var(--bar-h); left: 0; right: 0; margin: 0;
    flex-direction: column; gap: 0; padding: 8px var(--gutter) 28px;
    background: var(--night);
    opacity: 0; visibility: hidden; transform: translateY(-8px);
    transition: opacity .25s, transform .3s var(--ease), visibility .25s;
  }
  .nav a { font-size: 28px; font-weight: 700; color: var(--on-night); padding: 10px 0; letter-spacing: -0.02em; }
  .nav a::after { display: none; }
  .nav-open .nav { opacity: 1; visibility: visible; transform: none; }
}
@media (max-width: 380px) { .mark span { display: none; } }

/* ============================================================
   Hero + overnight: the pinned stage
   ============================================================ */
.stage { position: relative; }
.stage-grid {
  display: grid; grid-template-columns: minmax(0, 13fr) minmax(0, 11fr);
  gap: 40px; align-items: center;
  padding-top: clamp(40px, 7vw, 96px); padding-bottom: clamp(64px, 8vw, 120px);
}

/* Without the pin (no JS, reduced motion): the beats are a plain column. */
.beats { display: flex; flex-direction: column; gap: 56px; }
.beat-h { font-size: clamp(28px, 3vw, 44px); font-weight: 700; line-height: 1.05; letter-spacing: -0.028em; text-wrap: balance; }
.beat-h .when { color: var(--sun); }
.beat p { margin-top: 20px; font-size: clamp(17px, 1.4vw, 20px); color: var(--on-night-2); max-width: 30em; }
.beat-hero .lede { margin-top: 32px; }
.hero-act { margin-top: 40px; display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.link-on-night {
  color: var(--on-night); font-weight: 600; font-size: 17px; text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 2px no-repeat;
  padding-bottom: 3px; transition: background-size .3s var(--ease), color .2s;
}
.link-on-night:hover { color: var(--sun); background-size: 0 2px; background-position: 100% 100%; }

.globe-col { position: relative; }
.globe-box { position: relative; width: 100%; aspect-ratio: 1; max-height: 78svh; margin: 0 auto; }
#globe { width: 100%; height: 100%; }

.sources { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 16px; color: var(--on-night-2); font-size: 15px; }
.tally { margin-top: 16px; display: flex; align-items: baseline; gap: 12px; color: var(--on-night-2); font-size: 16px; }
.tally strong { color: var(--on-night); font-size: clamp(40px, 4vw, 60px); font-weight: 700; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; line-height: 1; }

.outs {
  margin-top: 24px; background: var(--night-2); padding: 20px 22px; border-radius: 4px;
  display: flex; flex-direction: column; gap: 12px; font-size: 16px;
}
.outs li { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 12px; align-items: baseline; }
.o-k { color: var(--on-night-2); font-size: 14px; }
.o-v { color: var(--on-night); }
.outs b { font-weight: 600; }
.up { color: var(--up); }
.dn { color: var(--dn); }
.outs .o-note { display: block; color: var(--on-night-2); font-size: 13px; margin-top: 4px; }

/* With the pin */
.js .pin.is-pinned { height: 520vh; }
.js .pin.is-pinned .stage { position: sticky; top: var(--bar-h); height: calc(100svh - var(--bar-h)); overflow: hidden; }
.js .pin.is-pinned .stage-grid { height: 100%; padding-top: 0; padding-bottom: 0; }
.js .pin.is-pinned .beats { position: relative; display: block; height: 100%; }
.js .pin.is-pinned .beat {
  position: absolute; left: 0; right: 0; top: 50%;
  opacity: 0; transform: translateY(-50%); will-change: opacity, transform;
}
.js .pin.is-pinned .beat-hero { opacity: 1; }
.js .pin.is-pinned .globe-col { height: 100%; display: grid; place-items: center; }
.js .pin.is-pinned .globe-box { width: min(100%, 72svh); will-change: transform; }
.js .pin.is-pinned .sources { position: absolute; inset: 0; margin: 0; display: block; pointer-events: none; }
.js .pin.is-pinned .sources li {
  position: absolute; white-space: nowrap; font-size: 14px; color: var(--on-night-2);
  opacity: 0; transition: opacity .5s, color .5s;
}
.js .pin.is-pinned .sources li.is-l { transform: translate(-100%, -50%); }
.js .pin.is-pinned .sources li.is-r { transform: translate(0, -50%); }
.js .pin.is-pinned .sources.is-on li { opacity: 1; }
.js .pin.is-pinned .sources li.is-lit { color: var(--sun); }
.js .pin.is-pinned .tally { position: absolute; left: 0; bottom: 4%; margin: 0; flex-direction: column; gap: 2px; opacity: 0; transition: opacity .5s; }
.js .pin.is-pinned .tally.is-on { opacity: 1; }
.js .pin.is-pinned .outs {
  position: absolute; right: 0; top: 50%; width: min(420px, 58%); margin: 0;
  transform: translateY(-50%); pointer-events: none;
}
.js .pin.is-pinned .outs li { opacity: 0; transform: translateX(28px); transition: opacity .55s var(--ease), transform .55s var(--ease); }
.js .pin.is-pinned .outs { opacity: 0; transition: opacity .4s; }
.js .pin.is-pinned .outs.is-on { opacity: 1; }
.js .pin.is-pinned .outs li.is-on { opacity: 1; transform: none; }

@media (max-width: 859px) {
  .stage-grid { grid-template-columns: minmax(0, 1fr); gap: 32px; }
  .js .pin.is-pinned .stage-grid { grid-template-rows: 46% 54%; gap: 0; }
  .js .pin.is-pinned .globe-col { grid-row: 1; padding-top: 12px; }
  .js .pin.is-pinned .beats { grid-row: 2; }
  .js .pin.is-pinned .beat { top: 12px; transform: none; }
  .js .pin.is-pinned .globe-box { width: min(60vw, 38svh); }
  .js .pin.is-pinned .sources li { font-size: 12px; line-height: 1.25; white-space: normal; width: 6.6em; }
  .js .pin.is-pinned .sources li.is-l { text-align: right; }
  .js .pin.is-pinned .tally { left: -4px; bottom: 0; }
  .js .pin.is-pinned .tally strong { font-size: 34px; }
  .js .pin.is-pinned .tally span { font-size: 13px; }
  .js .pin.is-pinned .outs { width: 100%; top: auto; bottom: 0; transform: none; padding: 14px 16px; gap: 8px; font-size: 14px; }
  .outs li { grid-template-columns: 62px minmax(0, 1fr); }
  .beat-hero .lede { margin-top: 20px; }
  .hero-act { margin-top: 28px; }
}

/* ============================================================
   Tour
   ============================================================ */
.tour { margin-top: clamp(48px, 6vw, 88px); }
.tour-note { margin-top: 16px; font-size: 15px; color: var(--ink-2); }

/* ============================================================
   Five steps
   ============================================================ */
.steps { margin-top: clamp(48px, 6vw, 88px); display: flex; flex-direction: column; gap: clamp(20px, 3vw, 40px); }
.step {
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 12px 64px; align-items: baseline;
}
.step-t {
  font-size: clamp(36px, 6.4vw, 104px); font-weight: 800; line-height: .95; letter-spacing: -0.045em;
  color: rgba(17, 19, 22, .16); transition: color .5s var(--ease), transform .6s var(--ease);
  transform-origin: left center;
}
.step-d { font-size: clamp(17px, 1.4vw, 20px); color: var(--ink-2); opacity: .55; transition: opacity .5s; max-width: 28em; }
.step.is-on .step-t { color: var(--ink); }
.step.is-on .step-d { opacity: 1; }
.no-steps .step-t { color: var(--ink); }
.no-steps .step-d { opacity: 1; }
@media (max-width: 859px) { .step { grid-template-columns: minmax(0, 1fr); } }

/* ============================================================
   Why
   ============================================================ */
.why { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 48px 72px; align-items: center; }
.pic-frame { overflow: hidden; background: var(--paper-2); }
.pic-frame img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.1); will-change: transform; }
.why-pic .pic-frame { aspect-ratio: 4 / 3; }
/* A real screen of the app, not a photograph: shown whole at its own shape,
   never cropped or drifted, with a hairline so the dark screen holds its edge
   on paper. */
.pic-frame.screen,
.why-pic .pic-frame.screen,
.status-pic .pic-frame.screen { aspect-ratio: 1456 / 900; background: var(--night); border: 1px solid rgba(17, 19, 22, .18); border-radius: 6px; }
/* iOS Safari paints NOTHING for a composited image (will-change: transform)
   inside an overflow:hidden box with a border-radius: the screen showed as a
   black frame on iPhones (founder, 30 Oct). So the screen frame does not clip,
   the image is not promoted to its own layer, and it carries the corners
   itself. */
.pic-frame.screen { overflow: visible; }
.pic-frame.screen img { transform: none; will-change: auto; object-fit: contain; border-radius: 5px; }
figcaption { margin-top: 12px; font-size: 15px; color: var(--ink-2); }
.reasons { margin-top: 48px; display: flex; flex-direction: column; gap: 28px; }
.reasons dt { font-size: 21px; font-weight: 700; letter-spacing: -0.015em; }
.reasons dd { margin-top: 6px; font-size: 18px; color: var(--ink); }
.figures {
  margin-top: clamp(80px, 10vw, 160px);
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px;
}
.figures p { display: flex; flex-direction: column; gap: 10px; }
.figures strong { font-size: clamp(64px, 10vw, 168px); font-weight: 800; line-height: .85; letter-spacing: -0.05em; font-variant-numeric: tabular-nums; }
.figures span { font-size: 18px; max-width: 14em; }
@media (max-width: 859px) {
  .why { grid-template-columns: minmax(0, 1fr); }
  .reasons { margin-top: 32px; }
  .figures { grid-template-columns: minmax(0, 1fr); gap: 40px; }
}

/* ============================================================
   Plans (on the green field)
   ============================================================ */
.plans { margin-top: clamp(48px, 6vw, 88px); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.plan {
  display: flex; flex-direction: column; background: var(--field-2); padding: 32px 28px 28px; border-radius: 2px;
  transition: transform .35s var(--ease);
}
.plan:hover { transform: translateY(-4px); }
.plan h3 { font-size: 32px; font-weight: 800; letter-spacing: -0.035em; line-height: 1; }
.plan-for { margin-top: 10px; font-size: 18px; }
.plan-price { margin-top: 28px; font-size: 15px; color: var(--on-field-2); }
.plan ul { margin: 16px 0 32px; display: flex; flex-direction: column; gap: 10px; flex: 1; font-size: 16px; line-height: 1.4; }
.plan li { position: relative; padding-left: 18px; }
.plan li::before { content: ''; position: absolute; left: 0; top: .5em; width: 7px; height: 7px; background: var(--sun); }
.plan li.inherit { padding-left: 0; color: var(--on-field-2); }
.plan li.inherit::before { display: none; }
.plan .btn { width: 100%; }
.plan-hi { background: var(--sun); color: var(--night); }
.plan-hi .plan-price, .plan-hi li.inherit { color: rgba(11, 15, 20, .66); }
.plan-hi li::before { background: var(--night); }
@media (max-width: 1099px) { .plans { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 599px) { .plans { grid-template-columns: minmax(0, 1fr); } }

/* ============================================================
   Status
   ============================================================ */
.status { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: 48px 64px; align-items: center; }
.status .sec-sub { margin-top: 24px; }
.state { margin-top: 40px; display: flex; flex-direction: column; gap: 6px; }
.state li { display: flex; align-items: center; gap: 16px; background: var(--paper-3); padding: 14px 18px; font-size: 17px; }
.state b { flex: none; width: 76px; font-size: 14px; font-weight: 600; padding: 3px 0; text-align: center; border-radius: 2px; }
.state .live { background: var(--up); color: #fff; }
.state .wait { background: var(--paper-2); color: var(--ink); }
.status-pic .pic-frame { aspect-ratio: 4 / 3; }
@media (max-width: 859px) { .status { grid-template-columns: minmax(0, 1fr); } }

/* ============================================================
   FAQ
   ============================================================ */
.faq-grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 40px 72px; align-items: start; }
.faq-grid .h2 { position: sticky; top: calc(var(--bar-h) + 32px); }
.faqs { display: flex; flex-direction: column; gap: 6px; }
.faq { background: var(--paper); transition: background-color .25s; }
.faq[open] { background: var(--paper-3); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 22px 24px; font-size: clamp(19px, 1.6vw, 22px); font-weight: 600; letter-spacing: -0.015em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ''; flex: none; width: 14px; height: 14px;
  background:
    linear-gradient(currentColor, currentColor) center / 14px 2px no-repeat,
    linear-gradient(currentColor, currentColor) center / 2px 14px no-repeat;
  transition: transform .3s var(--ease);
}
.faq[open] summary::after { transform: rotate(45deg); }
.faq summary:hover { color: var(--ink-2); }
.faq p { padding: 0 64px 24px 24px; font-size: 18px; }
@media (max-width: 859px) {
  .faq-grid { grid-template-columns: minmax(0, 1fr); }
  .faq-grid .h2 { position: static; }
  .faq summary { padding: 18px; }
  .faq p { padding: 0 18px 20px; }
}

/* ============================================================
   Contact
   ============================================================ */
.contact { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 48px 72px; align-items: start; }
.contact-copy .sec-sub { margin-top: 24px; }
.contact-form { display: flex; flex-direction: column; gap: 20px; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field label { font-size: 16px; font-weight: 500; color: var(--on-night); }
.field .opt { color: var(--on-night-2); font-weight: 400; }
.field input, .field textarea, .field select {
  width: 100%; font: inherit; font-size: 18px; color: var(--on-night);
  background: var(--night-2); border: 0; border-radius: 2px; padding: 16px 18px;
  box-shadow: inset 0 -2px 0 var(--night-3);
  transition: box-shadow .2s, background-color .2s;
}
.field textarea { resize: vertical; min-height: 180px; }
.field select {
  appearance: none; -webkit-appearance: none; cursor: pointer; padding-right: 44px;
  background-image: linear-gradient(45deg, transparent 50%, var(--on-night-2) 50%), linear-gradient(135deg, var(--on-night-2) 50%, transparent 50%);
  background-position: calc(100% - 24px) 50%, calc(100% - 18px) 50%; background-size: 6px 6px; background-repeat: no-repeat;
}
.field select option { color: var(--ink); background: var(--paper); }
.field input:focus, .field textarea:focus, .field select:focus { outline: none; background: var(--night-3); box-shadow: inset 0 -2px 0 var(--sun); }
.form-actions { margin-top: 8px; }
.form-status { font-size: 17px; min-height: 1px; }
.form-status.is-loading { color: var(--on-night-2); }
.form-status.is-success { color: var(--up); }
.form-status.is-error { color: #F08A82; }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 859px) {
  .contact { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 559px) {
  .field-row { grid-template-columns: minmax(0, 1fr); }
  .form-actions .btn { width: 100%; }
}

/* ============================================================
   Footer: the name returns at full width
   ============================================================ */
.foot { background: var(--night); color: var(--on-night); padding: 0 0 calc(40px + env(safe-area-inset-bottom)); overflow: hidden; }
.foot-name {
  font-size: 17.6vw; font-weight: 800; letter-spacing: -0.06em; line-height: .8;
  margin-left: -0.03em; padding-top: 24px; white-space: nowrap;
}
@media (min-width: 1360px) { .foot-name { font-size: 236px; } }
.foot-row { margin-top: 48px; display: flex; justify-content: space-between; align-items: baseline; gap: 20px 40px; flex-wrap: wrap; }
.foot-nav { display: flex; gap: 12px 28px; flex-wrap: wrap; }
.foot-nav a { text-decoration: none; color: var(--on-night); font-size: 16px; }
.foot-nav a:hover { color: var(--sun); }
.foot-fine { font-size: 15px; color: var(--on-night-2); }

/* ============================================================
   Motion. Entrances are added by JS only, so without JS nothing hides.
   ============================================================ */
.js [data-rise] { opacity: 0; transform: translateY(28px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.js [data-rise].is-in { opacity: 1; transform: none; }
.js [data-lines] .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .08em; margin-bottom: -.08em; }
.js [data-lines] .w > i { display: inline-block; font-style: normal; transform: translateY(105%); transition: transform .9s var(--ease); transition-delay: calc(var(--i) * 55ms + 120ms); }
.js [data-lines].is-in .w > i { transform: none; }
.js .beat-hero .lede, .js .beat-hero .hero-act { opacity: 0; transform: translateY(16px); transition: opacity .8s var(--ease) .55s, transform .8s var(--ease) .55s; }
.js .beat-hero.is-in .lede, .js .beat-hero.is-in .hero-act { opacity: 1; transform: none; }
.js .beat-hero.is-in .hero-act { transition-delay: .7s; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: 0s !important; transition-delay: 0s !important; }
  .js [data-rise], .js .beat-hero .lede, .js .beat-hero .hero-act { opacity: 1; transform: none; }
  .js [data-lines] .w > i { transform: none; }
  .pic-frame img { transform: none; }
}

/* ============================================================
   THE TOUR (demo terminal). A piece of the real product, so it keeps
   the terminal's own palette (globals.css --c-* ladder) and its mono
   face. These tokens are scoped to the window.
   ============================================================ */
.demo {
  --bg0: #060809; --bg1: #0A0E11; --bg2: #0E1317; --bg3: #161C22;
  --tx1: #E8EEF4; --tx2: #9AA8B5; --tx3: #5B6873;
  --acc: #5B8DEF; --acc-hi: #7BA4F4; --pos: #2FBF8F; --neg: #E5545E; --warn: #D9A53F;
  --line: rgba(255, 255, 255, 0.07); --line2: rgba(255, 255, 255, 0.13);
  --font-sans: 'Schibsted Grotesk', 'Helvetica Neue', Arial, sans-serif;
  --font-mono: 'IBM Plex Mono', 'SF Mono', Menlo, Consolas, monospace;
  color: var(--tx1);
}
.demo .live-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--pos); flex: none; }
.demo .t-pos { color: var(--pos); } .demo .t-neg { color: var(--neg); } .demo .t-warn { color: var(--warn); }
.demo .t-mut { color: var(--tx3); font-weight: 400; } .demo .t-acc { color: var(--acc-hi); }
.demo {
  position: relative; overflow: hidden;
  border-radius: 6px;
  background: var(--bg1);
  font-family: var(--font-mono); font-size: 12.5px; line-height: 1.45;
  text-align: left;
  -webkit-user-select: none; user-select: none;
}

.demo-chrome {
  display: flex; align-items: center; gap: 12px;
  height: 40px; padding: 0 14px;
  background: var(--bg0); border-bottom: 1px solid var(--line);
}
.chrome-dots { display: flex; gap: 6px; flex: none; }
.chrome-dots i { width: 10px; height: 10px; border-radius: 50%; background: var(--bg3); }
.chrome-dots i:nth-child(1) { background: #3a2427; }
.chrome-dots i:nth-child(2) { background: #3a3324; }
.chrome-dots i:nth-child(3) { background: #1f3a2f; }
.chrome-url {
  flex: 1; min-width: 0; text-align: center;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-size: 11.5px; color: var(--tx2);
  background: var(--bg2); border: 1px solid var(--line); border-radius: 6px;
  padding: 3px 10px; max-width: 420px; margin: 0 auto;
}
.url-host { color: var(--tx3); }
.chrome-badge {
  flex: none; font-size: 10px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--warn); border: 1px solid rgba(217, 165, 63, .4); border-radius: 4px; padding: 2px 6px;
}

.demo-body { display: grid; grid-template-columns: 196px minmax(0, 1fr); }

/* --- tabs --- */
.demo-nav {
  position: relative; display: flex; flex-direction: column; gap: 2px;
  padding: 12px 8px; background: var(--bg0); border-right: 1px solid var(--line);
}
.nav-group {
  font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--tx3);
  padding: 10px 10px 4px;
}
.nav-group:first-child { padding-top: 2px; }
.demo-tab {
  display: flex; align-items: center; gap: 9px; width: 100%;
  padding: 8px 10px; border: 0; border-radius: 6px; background: transparent;
  color: var(--tx2); font-family: var(--font-mono); font-size: 12.5px; text-align: left;
  cursor: pointer; transition: background .2s, color .2s, transform .15s;
}
.demo-tab svg { width: 15px; height: 15px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.demo-tab:hover { color: var(--tx1); background: rgba(255, 255, 255, .03); }
.demo-tab[aria-selected="true"] {
  color: var(--tx1); background: rgba(91, 141, 239, .13);
  box-shadow: inset 2px 0 0 var(--acc);
}
.demo-tab[aria-selected="true"] svg { color: var(--acc-hi); }
.is-pressed { transform: scale(.96); }
.demo-tab.is-pressed { background: rgba(91, 141, 239, .26); }

/* --- stage + scenes --- */
.demo-stage { position: relative; height: 430px; overflow: hidden; background: var(--bg1); }
.scene {
  position: absolute; inset: 0; padding: 18px 20px;
  display: flex; flex-direction: column; gap: 14px;
  opacity: 0; visibility: hidden; transition: opacity .35s, visibility .35s;
}
.scene.is-on { opacity: 1; visibility: visible; }
.scene .a {
  opacity: 0; transform: translateY(8px);
  transition: opacity .5s var(--ease), transform .5s var(--ease), border-color .25s, background .25s, box-shadow .25s;
  transition-delay: calc(var(--d, 0) * 80ms), calc(var(--d, 0) * 80ms), 0s, 0s, 0s;
}
.scene.is-on .a { opacity: 1; transform: none; }

.scene-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.scene-head h3 { font-size: 15px; font-weight: 600; letter-spacing: -.005em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pill {
  display: inline-flex; align-items: center; gap: 6px; flex: none;
  font-size: 11px; color: var(--tx2); padding: 3px 9px;
  border: 1px solid var(--line2); border-radius: 999px; white-space: nowrap;
}
.pill-pos { color: var(--pos); border-color: rgba(47, 191, 143, .45); background: rgba(47, 191, 143, .08); }
.pill-acc { color: var(--acc-hi); border-color: rgba(91, 141, 239, .5); background: rgba(91, 141, 239, .1); }
.k { font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--tx3); }
.v { font-size: 12.5px; color: var(--tx1); margin-top: 2px; }
.v.big { font-size: 17px; font-weight: 600; margin-top: 6px; }
.sub { font-size: 11.5px; color: var(--tx2); margin-top: 4px; }

.is-hot {
  border-color: rgba(91, 141, 239, .75) !important;
  background: rgba(91, 141, 239, .09) !important;
  box-shadow: 0 0 0 3px rgba(91, 141, 239, .14);
}

/* scene 1: regime */
.regime-top { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 22px; align-items: center; }
.gauge { width: 150px; text-align: center; }
.gauge svg { width: 150px; height: auto; overflow: visible; }
.gauge-track { fill: none; stroke: var(--bg3); stroke-width: 9; stroke-linecap: round; }
.gauge-fill {
  fill: none; stroke: var(--pos); stroke-width: 9; stroke-linecap: round;
  stroke-dasharray: 100; stroke-dashoffset: 100;
  transition: stroke-dashoffset 1.3s var(--ease) .3s;
}
.scene.is-on .gauge-fill { stroke-dashoffset: 30; }
.gauge-needle { transform-origin: 60px 62px; transform: rotate(-90deg); transition: transform 1.3s cubic-bezier(.3, 1.35, .5, 1) .3s; }
.scene.is-on .gauge-needle { transform: rotate(36deg); }
.gauge-needle line { stroke: var(--tx1); stroke-width: 2.5; stroke-linecap: round; }
.gauge-needle circle { fill: var(--tx1); }
.gauge-label { display: block; margin-top: 6px; font-size: 10.5px; color: var(--tx3); }

.split-bar { margin-top: 8px; display: flex; height: 10px; border-radius: 5px; overflow: hidden; background: var(--bg3); gap: 2px; }
.split-long, .split-short { display: block; height: 100%; width: 0; transition: width 1s var(--ease) .6s; }
.split-long { background: var(--pos); }
.split-short { background: var(--neg); }
.scene.is-on .split-long { width: 70%; }
.scene.is-on .split-short { width: 30%; }
.split-legend { display: flex; justify-content: space-between; margin-top: 8px; font-size: 12px; }

.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.tile { border: 1px solid var(--line); background: var(--bg2); border-radius: 8px; padding: 9px 11px; }
.spark { width: 100%; height: 18px; margin-top: 6px; }
.spark path {
  fill: none; stroke: var(--acc-hi); stroke-width: 1.5; stroke-linejoin: round; stroke-linecap: round;
  stroke-dasharray: 100; stroke-dashoffset: 100; transition: stroke-dashoffset 1.1s var(--ease);
  transition-delay: calc(var(--d, 0) * 80ms + 250ms);
}
.scene.is-on .spark path { stroke-dashoffset: 0; }

/* scene 2: sectors */
.bars { display: flex; flex-direction: column; gap: 4px; }
.bar {
  display: grid; grid-template-columns: 130px minmax(0, 1fr) 46px; gap: 12px; align-items: center;
  padding: 7px 10px; border: 1px solid transparent; border-radius: 7px;
}
.bar-name { color: var(--tx1); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-track { height: 8px; background: var(--bg3); border-radius: 4px; overflow: hidden; }
.bar-fill {
  display: block; height: 100%; width: 0; border-radius: 4px;
  transition: width .9s var(--ease); transition-delay: calc(var(--d, 0) * 80ms + 200ms);
}
.bar-fill.pos { background: var(--pos); }
.bar-fill.neg { background: var(--neg); }
.scene.is-on .bar-fill { width: var(--w); }
.bar-val { text-align: right; font-variant-numeric: tabular-nums; }
.scene-foot { display: flex; gap: 16px; font-size: 11px; margin-top: auto; }

/* scene 3: screener */
.gates { display: flex; flex-wrap: wrap; gap: 6px; }
.gate {
  font-size: 11px; color: var(--tx3); padding: 4px 10px 4px 8px;
  border: 1px solid var(--line2); border-radius: 999px;
  transition: color .3s, border-color .3s, background .3s;
}
.gate::before { content: '○'; margin-right: 6px; }
.gate.on { color: var(--pos); border-color: rgba(47, 191, 143, .5); background: rgba(47, 191, 143, .08); }
.gate.on::before { content: '✓'; }
.table { border: 1px solid var(--line); border-radius: 8px; overflow: hidden; opacity: 0; transition: opacity .3s; }
.table.show { opacity: 1; }
.tr {
  display: grid; grid-template-columns: 1.15fr 1.25fr .8fr .8fr .8fr; gap: 8px; align-items: center;
  padding: 9px 12px; border-top: 1px solid var(--line); font-variant-numeric: tabular-nums;
  opacity: 0; transform: translateY(6px);
  transition: opacity .4s var(--ease), transform .4s var(--ease), background .2s, box-shadow .2s;
  transition-delay: calc(var(--d, 0) * 110ms), calc(var(--d, 0) * 110ms), 0s, 0s;
}
.tr.th { border-top: 0; background: var(--bg0); font-size: 10.5px; letter-spacing: .05em; text-transform: uppercase; color: var(--tx3); }
.scene.is-on .tr.th, .table.show .tr { opacity: 1; transform: none; }
.tk { font-weight: 600; }
.tr.is-hot { background: rgba(91, 141, 239, .1); box-shadow: inset 2px 0 0 var(--acc); }
.tr.is-pressed { background: rgba(91, 141, 239, .22); }
.case { font-style: normal; font-size: 10.5px; padding: 2px 7px; border-radius: 4px; }
.case.long { color: var(--pos); background: rgba(47, 191, 143, .13); }
.case.short { color: var(--neg); background: rgba(229, 84, 94, .13); }

/* scene 4: story */
.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.card { border: 1px solid var(--line); background: var(--bg2); border-radius: 9px; padding: 12px 14px; min-width: 0; }
.cycle { width: 100%; max-width: 180px; height: auto; margin-top: 8px; overflow: visible; }
.cycle path { fill: none; stroke: var(--tx3); stroke-width: 1.6; }
.cycle-dot { fill: var(--acc-hi); }
.cycle-ring { fill: none; stroke: var(--acc-hi); stroke-width: 1.2; opacity: .5; transform-origin: 26.4px 15.7px; animation: ring 1.8s infinite; }
@keyframes ring { 0% { transform: scale(.6); opacity: .7; } 100% { transform: scale(1.6); opacity: 0; } }
.histo { display: flex; align-items: flex-end; gap: 4px; height: 48px; margin-top: 10px; max-width: 200px; }
.histo i {
  flex: 1; height: var(--h); background: var(--acc); opacity: .75; border-radius: 2px 2px 0 0;
  transform: scaleY(0); transform-origin: bottom; transition: transform .7s var(--ease) .5s;
}
.histo i:nth-child(5) { opacity: 1; background: var(--acc-hi); }
.scene.is-on .histo i { transform: none; }

/* scene 5: concall read */
.claims { display: flex; flex-direction: column; gap: 12px; }
.claim { border-left: 2px solid var(--line2); padding: 2px 0 2px 12px; transition: border-color .3s; }
.claim p { min-height: 1.45em; font-size: 13px; color: var(--tx1); }
.claim p.typing::after { content: '▍'; color: var(--acc-hi); animation: blink .8s steps(1) infinite; margin-left: 1px; }
@keyframes blink { 50% { opacity: 0; } }
.cite {
  display: inline-block; margin-top: 6px; font-size: 10.5px; color: var(--acc-hi);
  border: 1px solid rgba(91, 141, 239, .45); background: rgba(91, 141, 239, .08);
  border-radius: 4px; padding: 1px 7px;
  opacity: 0; transform: translateY(4px); transition: opacity .35s, transform .35s;
}
.claim.done { border-left-color: var(--pos); }
.claim.done .cite { opacity: 1; transform: none; }
.verdict {
  margin-top: auto; border: 1px solid var(--line); background: var(--bg2); border-radius: 8px;
  padding: 10px 14px; display: flex; flex-direction: column; gap: 4px;
  opacity: 0; transform: translateY(8px); transition: opacity .45s var(--ease), transform .45s var(--ease);
}
.verdict.show { opacity: 1; transform: none; }
.note { margin-top: auto; border: 1px solid rgba(91, 141, 239, .3); background: rgba(91, 141, 239, .06); border-radius: 8px; padding: 10px 14px; }

/* scene 6: book */
.checks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 18px; }
.checks { transition: opacity .4s; }
.checks li { position: relative; padding-left: 24px; color: var(--tx3); transition: color .3s; }
.checks li::before {
  content: ''; position: absolute; left: 0; top: 1px; width: 15px; height: 15px;
  border: 1px solid var(--line2); border-radius: 4px; transition: background .25s, border-color .25s;
}
.checks li.ok { color: var(--tx1); }
.checks li.ok::before { background: var(--pos); border-color: var(--pos); }
.checks li.ok::after {
  content: ''; position: absolute; left: 5px; top: 3px; width: 4px; height: 8px;
  border: solid var(--bg0); border-width: 0 2px 2px 0; transform: rotate(45deg);
}
.ticket {
  position: absolute; left: 20px; right: 20px; bottom: 18px;
  border: 1px solid rgba(91, 141, 239, .5); border-radius: 12px;
  background: rgba(14, 19, 23, .97);
  box-shadow: 0 -10px 40px -10px rgba(0, 0, 0, .8), 0 0 0 4px rgba(91, 141, 239, .07);
  padding: 14px 16px;
  transform: translateY(130%); transition: transform .6s cubic-bezier(.2, .9, .25, 1.05);
}
.ticket.show { transform: none; }
.ticket-head { display: flex; align-items: center; gap: 10px; font-size: 14px; }
.ticket-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 12px; }
.ticket-grid dt { font-size: 10px; letter-spacing: .06em; text-transform: uppercase; color: var(--tx3); }
.ticket-grid dd { font-size: 13.5px; font-weight: 600; margin-top: 2px; }
.ticket-btn {
  margin-top: 12px; padding: 7px 14px; border-radius: 7px;
  border: 1px solid var(--line2); background: var(--bg3); color: var(--tx1);
  font-family: var(--font-mono); font-size: 12px; cursor: default;
  transition: background .2s, border-color .2s, transform .15s;
}
.ticket-btn.is-pressed { background: var(--acc); border-color: var(--acc); }

/* --- caption + controls --- */
.demo-caption {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; border-top: 1px solid var(--line); background: var(--bg0);
  min-height: 48px;
}
.cap-step {
  flex: none; font-size: 11px; color: var(--acc-hi);
  border: 1px solid rgba(91, 141, 239, .45); border-radius: 4px; padding: 1px 6px;
}
.cap-text { font-family: var(--font-sans); font-size: 14.5px; color: var(--tx1); }
.demo-caption.swap .cap-step, .demo-caption.swap .cap-text { animation: cap-in .5s var(--ease); }
@keyframes cap-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.demo-controls {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px 12px; background: var(--bg0); border-top: 1px solid var(--line);
}
.ctl-play {
  flex: none; width: 32px; height: 32px; border-radius: 50%;
  border: 1px solid var(--line2); background: var(--bg3); cursor: pointer;
  display: grid; place-items: center;
}
.ctl-play:hover { border-color: var(--acc); }
.ctl-play svg { width: 13px; height: 13px; fill: var(--tx1); grid-area: 1 / 1; }
.ctl-play .i-play { display: none; }
.demo.is-paused .ctl-play .i-play { display: block; }
.demo.is-paused .ctl-play .i-pause { display: none; }
.chapters { flex: 1; min-width: 0; display: flex; gap: 4px; }
.chapter {
  flex: var(--dur, 1) 1 0; min-width: 0; padding: 6px 0; border: 0; background: none; cursor: pointer;
  text-align: left;
}
.ch-track { display: block; height: 4px; border-radius: 2px; background: var(--bg3); overflow: hidden; }
.ch-fill { display: block; height: 100%; width: 0; background: var(--acc); }
.chapter:hover .ch-track { background: #222a33; }
.ch-label {
  display: block; margin-top: 6px; font-family: var(--font-mono); font-size: 10.5px; color: var(--tx3);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.chapter.is-current .ch-label { color: var(--tx1); }
.ctl-time { flex: none; font-size: 11px; color: var(--tx3); font-variant-numeric: tabular-nums; }

/* --- cursor --- */
.demo-cursor {
  position: absolute; left: 0; top: 0; z-index: 6; width: 22px; height: 22px;
  pointer-events: none; opacity: 0;
  transition: transform .85s cubic-bezier(.65, 0, .35, 1), opacity .3s;
  will-change: transform;
}
.demo-cursor.is-visible { opacity: 1; }
.demo-cursor svg {
  width: 22px; height: 22px; fill: #fff; stroke: #0b0f13; stroke-width: 1.3; stroke-linejoin: round;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, .6)); transition: transform .15s;
  transform-origin: 4px 3px;
}
.demo-cursor.is-click svg { transform: scale(.82); }
.ripple {
  position: absolute; left: 4px; top: 3px; width: 34px; height: 34px; margin: -17px 0 0 -17px;
  border-radius: 50%; border: 2px solid var(--acc-hi); opacity: 0; transform: scale(.3);
}
.demo-cursor.is-click .ripple { animation: ripple .55s ease-out; }
@keyframes ripple { 0% { opacity: .9; transform: scale(.3); } 100% { opacity: 0; transform: scale(1.4); } }

/* --- tour on phones and small tablets --- */
@media (max-width: 759px) {
  .demo { border-radius: 12px; font-size: 12px; }
  .chrome-dots { display: none; }
  .chrome-url { text-align: left; }
  .demo-body { grid-template-columns: minmax(0, 1fr); }
  .demo-nav {
    flex-direction: row; gap: 4px; padding: 8px; overflow-x: auto;
    border-right: 0; border-bottom: 1px solid var(--line);
    scrollbar-width: none; -webkit-overflow-scrolling: touch;
  }
  .demo-nav::-webkit-scrollbar { display: none; }
  .nav-group { display: none; }
  .demo-tab { width: auto; flex: none; white-space: nowrap; padding: 7px 10px; font-size: 12px; }
  .demo-tab[aria-selected="true"] { box-shadow: inset 0 -2px 0 var(--acc); }
  .demo-stage { height: 452px; }
  .scene { padding: 14px; gap: 12px; }
  .regime-top { grid-template-columns: 112px minmax(0, 1fr); gap: 14px; }
  .gauge, .gauge svg { width: 112px; }
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
  .tile { padding: 7px 9px; }
  .spark { height: 14px; margin-top: 4px; }
  .bar { grid-template-columns: 102px minmax(0, 1fr) 38px; gap: 8px; padding: 7px 6px; }
  .tr { grid-template-columns: 1.3fr .8fr .9fr .9fr; padding: 9px 10px; }
  .hide-sm { display: none; }
  .cards { gap: 8px; }
  .card { padding: 10px 11px; }
  .v.big { font-size: 15px; }
  .histo { height: 38px; }
  .claim p { font-size: 12.5px; }
  .checks { grid-template-columns: minmax(0, 1fr); gap: 7px; }
  .checks.dim { opacity: .3; }
  .ticket { left: 12px; right: 12px; bottom: 12px; padding: 12px 14px; }
  .ticket-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 12px; }
  .demo-caption { padding: 10px 12px; }
  .demo-caption { min-height: 66px; }
  .cap-text { font-size: 14px; }
  .url-domain { display: none; }
  .demo-controls { padding: 8px 12px 10px; gap: 10px; }
  .ch-label { display: none; }
  .chapter { padding: 10px 0; }
}

@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
