/* StageVis — stagevis.app
   Tokens are lifted verbatim from the app's Theme.swift so the site and the
   app read as one product. Green appears only where something is live;
   red only on REC. */

@font-face { font-family: "Anton"; src: url("fonts/anton-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("fonts/instrument-sans-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("fonts/instrument-sans-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Instrument Sans"; src: url("fonts/instrument-sans-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("fonts/ibm-plex-mono-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("fonts/ibm-plex-mono-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  --bg: #0d0d12;
  --bg-top: #120d1a;
  --surface: #1a1a1f;
  --surface-hi: #232329;
  --border: rgba(255,255,255,.08);
  --border-hi: rgba(255,255,255,.16);
  --text: #ffffff;
  --dim: rgba(255,255,255,.55);
  --faint: rgba(255,255,255,.32);
  --blue: #0ab6ff;
  --purple: #6e3be9;
  --magenta: #e33cd8;
  --live: #2ef88c;
  --rec: #ff454f;
  --grad: linear-gradient(90deg, var(--blue), var(--purple), var(--magenta));
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --body: "Instrument Sans", -apple-system, "Helvetica Neue", sans-serif;
  --display: "Anton", "Arial Narrow", sans-serif;
  --max: 1120px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--magenta); color: #000; }

a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; border-radius: 2px; }

.mono { font-family: var(--mono); font-size: .92em; color: var(--dim); }

/* ---------- HUD (header/nav/viewfinder chrome) ---------- */

.hud {
  position: fixed; inset: 0 0 auto 0; z-index: 40;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 12px 20px;
  font-family: var(--mono); font-size: 11px; letter-spacing: .14em;
  color: var(--dim);
  background: linear-gradient(rgba(13,13,18,.75), rgba(13,13,18,0));
  backdrop-filter: blur(2px);
}
.hud-left { display: flex; align-items: center; gap: 10px; }
.hud-logo { display: block; width: 20px; height: 20px; }
.hud-brand { font-weight: 600; color: var(--text); letter-spacing: .22em; }
.hud-tag { color: var(--live); }
.hud-sep { color: var(--faint); }
.rec-dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--rec);
  box-shadow: 0 0 8px rgba(255,69,79,.8);
  animation: rec-blink 2s steps(1) infinite;
}
@keyframes rec-blink { 0%, 70% { opacity: 1; } 71%, 100% { opacity: .25; } }
@media (prefers-reduced-motion: reduce) { .rec-dot { animation: none; } }

.hud-nav { display: flex; align-items: center; gap: 22px; }
.hud-nav a { color: var(--dim); transition: color .15s; }
.hud-nav a:hover { color: var(--text); }
.hud-cta {
  color: var(--text) !important;
  border: 1px solid var(--border-hi); border-radius: 999px;
  padding: 6px 14px;
}
.hud-cta:hover { border-color: var(--magenta); }
.hud-right { display: flex; gap: 8px; }
@media (max-width: 860px) { .hud-right { display: none; } }
@media (max-width: 560px) { .hud-nav a:not(.hud-cta) { display: none; } }

/* ---------- Hero ---------- */

.hero {
  position: relative; min-height: 100svh;
  display: grid; place-items: center;
  overflow: hidden;
  background: radial-gradient(120% 90% at 50% 0%, var(--bg-top) 0%, var(--bg) 65%);
}
#feed { display: none; }
/* Poster behind the canvas: the wall reads even before play / without JS. */
#program {
  position: absolute; inset: 0; width: 100%; height: 100%;
  background: url("media/demo-poster.jpg") center / cover no-repeat;
}
.scrim {
  position: absolute; inset: 0;
  background:
    linear-gradient(100deg, rgba(13,13,18,.88) 0%, rgba(13,13,18,.55) 45%, rgba(13,13,18,.15) 75%),
    linear-gradient(rgba(13,13,18,.6) 0%, rgba(13,13,18,.05) 30%, rgba(13,13,18,.15) 70%, var(--bg) 98%);
}

/* Viewfinder corner brackets — the logo's own motif */
.bracket {
  position: absolute; width: 34px; height: 34px; z-index: 5;
  border: 2px solid rgba(255,255,255,.34);
}
.bracket.tl { top: 64px;  left: 22px;  border-right: 0; border-bottom: 0; }
.bracket.tr { top: 64px;  right: 22px; border-left: 0;  border-bottom: 0; }
.bracket.bl { bottom: 22px; left: 22px;  border-right: 0; border-top: 0; }
.bracket.br { bottom: 22px; right: 22px; border-left: 0;  border-top: 0; }

.hero-inner {
  position: relative; z-index: 10;
  width: min(var(--max), 92vw);
  padding-top: 84px;
}
@media (min-width: 1101px) { .hero-inner { padding-right: 240px; } }

.hero-brand {
  display: flex; align-items: center; gap: 15px;
  margin-bottom: 28px;
}
.hero-brand img:first-child {
  width: 50px; height: 50px; display: block;
  filter: drop-shadow(0 4px 18px rgba(13,13,18,.7));
}
.hero-wordmark {
  height: 28px; width: auto; display: block;
  filter: drop-shadow(0 2px 12px rgba(13,13,18,.8));
}
/* The brand name is always set in the wordmark's own lettering. */
.wm { height: .66em; width: auto; vertical-align: -.045em; }
.hud-brand .wm, .footer-brand .wm { height: 13px; vertical-align: middle; }
.doc-foot .wm { height: 10px; }

h1 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(56px, min(10vw, 13.5svh), 132px);
  line-height: .94;
  letter-spacing: .005em;
  text-transform: uppercase;
  max-width: 12ch;
  text-shadow: 0 4px 40px rgba(13,13,18,.6);
}

.lede {
  margin-top: 28px;
  max-width: 50ch;
  font-size: clamp(17px, 1.6vw, 20px);
  color: rgba(255,255,255,.72);
  text-shadow: 0 2px 18px rgba(13,13,18,.8);
}

.cta-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 36px; }

.btn-primary {
  position: relative;
  font-family: var(--mono); font-size: 13px; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase;
  color: #000; background: #fff;
  padding: 15px 26px; border-radius: 999px;
  transition: transform .15s ease, box-shadow .15s ease;
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 0 1px rgba(255,255,255,.25), 0 6px 30px rgba(227,60,216,.35), 0 6px 30px rgba(10,182,255,.25);
}
.btn-quiet {
  font-family: var(--mono); font-size: 13px; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--text);
  padding: 15px 26px; border-radius: 999px;
  border: 1px solid var(--border-hi);
  background: rgba(13,13,18,.35);
  transition: border-color .15s;
}
.btn-quiet:hover { border-color: var(--text); }
.btn-soon {
  font-family: var(--mono); font-size: 13px; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase;
  color: var(--faint);
  padding: 15px 26px; border-radius: 999px;
  border: 1px dashed var(--border-hi);
  cursor: default;
}
.wide { display: block; text-align: center; margin-top: auto; }

.fineprint {
  margin-top: 22px;
  font-family: var(--mono); font-size: 11px; letter-spacing: .1em;
  color: var(--faint);
}

/* ---------- Camera tiles (the devices feeding the wall) ---------- */

.cams {
  position: absolute; z-index: 12;
  right: clamp(20px, 3.5vw, 56px); top: 50%;
  transform: translateY(-50%);
  display: flex; flex-direction: column; gap: 13px;
  align-items: flex-end;
}
.cam { position: relative; }
.cam.phone.portrait { width: 112px; }
.cam.phone.landscape { width: 168px; }
.cam.mac { width: 168px; }
.cam.usb { width: 146px; }

.cam canvas {
  display: block; width: 100%;
  border-radius: 14px;
  border: 1px solid var(--border-hi);
  background: #000;
  box-shadow: 0 14px 40px rgba(0,0,0,.5);
}
.cam.phone.portrait canvas { aspect-ratio: 9 / 16; }
.cam.phone.landscape canvas { aspect-ratio: 16 / 9; }
.cam.mac canvas { aspect-ratio: 16 / 10; border-radius: 8px 8px 2px 2px; border-bottom: 0; }
.cam.usb canvas { aspect-ratio: 16 / 9; border-radius: 8px; }

/* MacBook: screen sits on a deck/hinge bar */
.mac-base {
  display: block; height: 6px;
  margin: 0 -6px;
  border-radius: 2px 2px 6px 6px;
  background: linear-gradient(#3a3a41, #232329);
  border: 1px solid var(--border-hi); border-top: 0;
}

.cam-notch {
  position: absolute; top: 8px; left: 50%; transform: translateX(-50%);
  width: 6px; height: 6px; border-radius: 50%;
  background: #000; box-shadow: 0 0 0 2px rgba(255,255,255,.10);
  z-index: 2;
}
.cam-notch.side { top: 50%; left: 10px; transform: translateY(-50%); }

.cam figcaption {
  display: flex; align-items: center; gap: 6px;
  margin-top: 7px; padding: 0 1px;
  font-family: var(--mono); font-size: 9.5px; font-weight: 600;
  letter-spacing: .07em; color: var(--dim);
  white-space: nowrap;
}
.cam-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--faint); flex: none;
  transition: background .3s, box-shadow .3s;
}
.cam-tag {
  margin-left: auto;
  font-size: 8px; font-weight: 400; letter-spacing: .08em;
  color: var(--faint);
  border: 1px solid var(--border); border-radius: 4px;
  padding: 1px 4px;
}

.cam.on-air canvas { outline: 2px solid var(--live); outline-offset: 2px; }
.cam.on-air .cam-dot { background: var(--live); box-shadow: 0 0 9px rgba(46,248,140,.8); }
.cam.on-air figcaption { color: var(--text); }

@media (min-width: 1101px) and (max-height: 800px) {
  .cam.phone.portrait { width: 92px; }
  .cam.phone.landscape { width: 138px; }
  .cam.mac { width: 138px; }
  .cam.usb { width: 120px; }
  .cams { gap: 10px; }
}

@media (max-width: 1100px) {
  .cams {
    position: static; transform: none;
    flex-direction: row; align-items: flex-end;
    justify-content: center; flex-wrap: wrap;
    gap: 14px; padding: 34px 4vw 70px;
  }
  .cam.phone.portrait { width: 84px; }
  .cam.phone.landscape { width: 128px; }
  .cam.mac { width: 128px; }
  .cam.usb { width: 112px; }
  .hero { grid-template-rows: 1fr auto; }
  .hero-inner { padding-top: 96px; }
}

/* Small phones: clear the HUD, keep one clean row of tiles, drop the
   caption tags so nothing crowds or overflows. */
@media (max-width: 560px) {
  .hero-inner { padding-top: 88px; }
  .hero-brand { gap: 11px; margin-bottom: 20px; }
  .hero-brand img:first-child { width: 36px; height: 36px; }
  .hero-wordmark { height: 20px; }
  h1 { font-size: clamp(46px, 13.5vw, 56px); }
  .lede { margin-top: 22px; }
  .cta-row { margin-top: 30px; }
  .cams { gap: 10px; padding: 26px 4vw 56px; }
  .cam.usb { display: none; }
  .cam-tag { display: none; }
  .cam.phone.portrait { width: 72px; }
  .cam.phone.landscape { width: 114px; }
  .cam.mac { width: 114px; }
  .cam figcaption { justify-content: center; }
}

/* ---------- Bands (sections) ---------- */

.band {
  width: min(var(--max), 92vw);
  margin-inline: auto;
  padding-block: clamp(88px, 11vw, 150px) 0;
}
.band:last-of-type { padding-bottom: clamp(88px, 11vw, 150px); }

.eyebrow {
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  letter-spacing: .3em; text-transform: uppercase;
  color: var(--faint);
  margin-bottom: 18px;
}
.eyebrow::before { content: "// "; color: var(--magenta); }

h2 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(34px, 4.6vw, 62px);
  line-height: 1.02;
  letter-spacing: .01em;
  text-transform: uppercase;
  max-width: 22ch;
}

.band-copy { margin-top: 22px; max-width: 58ch; color: var(--dim); }
.text-link { color: var(--text); border-bottom: 1px solid var(--magenta); }
.text-link:hover { color: var(--magenta); }

#integrate { padding-block: clamp(56px, 7vw, 90px) 0; }
#integrate .band-copy { margin-top: 0; }

/* Steps */
.steps {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 18px; margin-top: 44px;
}
@media (max-width: 820px) { .steps { grid-template-columns: 1fr; } }

.step {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 26px 24px 28px;
}
.step::before, .step::after {
  content: ""; position: absolute; width: 14px; height: 14px;
  border: 2px solid transparent; transition: border-color .2s;
}
.step::before { top: -1px; left: -1px; border-right: 0; border-bottom: 0; }
.step::after  { bottom: -1px; right: -1px; border-left: 0; border-top: 0; }
.step:hover::before { border-top-color: var(--blue); border-left-color: var(--blue); }
.step:hover::after  { border-bottom-color: var(--magenta); border-right-color: var(--magenta); }

.step-tag {
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  letter-spacing: .2em; color: var(--faint);
  margin-bottom: 14px;
}
.step-tag.live { color: var(--live); }
.step h3 { font-size: 19px; font-weight: 600; margin-bottom: 10px; }
.step p:last-child { color: var(--dim); font-size: 15.5px; }

/* Pricing */
.price-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 18px; margin-top: 44px;
  max-width: 880px;
}
@media (max-width: 720px) { .price-grid { grid-template-columns: 1fr; } }

.price-card {
  display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 30px 28px;
}
.price-card.featured {
  border: 1px solid transparent;
  background:
    linear-gradient(var(--surface), var(--surface)) padding-box,
    linear-gradient(120deg, var(--blue), var(--purple), var(--magenta)) border-box;
}
.price-tag {
  font-family: var(--mono); font-size: 11px; font-weight: 600;
  letter-spacing: .3em; color: var(--faint);
}
/* Pre-launch marker on the SHOW card. Quiet by design — dim outline chip,
   not --live green (green is reserved for things that are genuinely live). */
.soon-chip {
  display: inline-block; margin-left: 10px; padding: 3px 8px 2px;
  font-size: 9px; letter-spacing: .18em; color: var(--dim);
  border: 1px solid rgba(255,255,255,.22); border-radius: 999px;
  vertical-align: 2px;
}
.price {
  font-family: var(--display); font-size: 56px; text-transform: uppercase;
  margin: 14px 0 6px; line-height: 1;
}
.price-sub {
  font-family: var(--mono); font-size: 11px; letter-spacing: .14em;
  color: var(--faint); margin-left: 12px; text-transform: uppercase;
}
.price-card ul { list-style: none; margin: 18px 0 26px; }
.price-card li {
  color: var(--dim); font-size: 15.5px;
  padding: 7px 0 7px 22px; position: relative;
}
.price-card li::before {
  content: ""; position: absolute; left: 0; top: 15px;
  width: 10px; height: 2px; background: var(--grad);
}

.dl-icon {
  display: block; width: 88px; height: 88px;
  border-radius: 22px;
  margin: 26px 0 20px;
  box-shadow: 0 12px 40px rgba(0,0,0,.5), 0 0 0 1px var(--border);
}

.price-note {
  margin-top: 12px; text-align: center;
  font-family: var(--mono); font-size: 11px; letter-spacing: .08em;
  color: var(--faint);
}

/* FAQ */
.faq { margin-top: 40px; max-width: 760px; border-top: 1px solid var(--border); }
.faq details { border-bottom: 1px solid var(--border); }
.faq summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: baseline; justify-content: space-between; gap: 18px;
  padding: 18px 2px;
  font-weight: 600; font-size: 16.5px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  font-family: var(--mono); font-size: 18px; line-height: 1;
  color: var(--faint);
  transition: transform .2s, color .2s;
}
.faq details[open] summary::after { transform: rotate(45deg); color: var(--magenta); }
.faq details > p { padding: 0 2px 20px; color: var(--dim); max-width: 62ch; }
.faq-more { margin-top: 26px; font-size: 15px; }

/* Footer */
.footer {
  border-top: 1px solid var(--border);
  margin-top: clamp(88px, 11vw, 150px);
  padding: 40px 0 48px;
  width: min(var(--max), 92vw); margin-inline: auto;
  display: flex; flex-wrap: wrap; align-items: center; gap: 22px;
}
.footer-left { display: flex; align-items: center; gap: 10px; }
.footer-brand { font-family: var(--mono); font-size: 12px; font-weight: 600; letter-spacing: .22em; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 18px; font-size: 14px; color: var(--dim); }
.footer-nav a:hover { color: var(--text); }
.footer-note { margin-left: auto; font-family: var(--mono); font-size: 11px; letter-spacing: .1em; color: var(--faint); }
@media (max-width: 720px) { .footer-note { margin-left: 0; } }

/* ---------- Docs pages (the operator's field manual) ---------- */

.hud-tag.dim { color: var(--faint); }

.doc {
  width: min(760px, 92vw); margin-inline: auto;
  padding-top: 128px;
}
.doc h1 {
  font-size: clamp(42px, 7vw, 78px);
  max-width: none;
  text-shadow: none;
}
.doc-lede { margin-top: 18px; color: var(--dim); max-width: 60ch; }

.doc-nav {
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 30px; padding-bottom: 28px;
  border-bottom: 1px solid var(--border);
  font-family: var(--mono); font-size: 10.5px; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase;
}
.doc-nav a {
  color: var(--dim);
  border: 1px solid var(--border); border-radius: 999px;
  padding: 6px 12px;
  transition: color .15s, border-color .15s;
}
.doc-nav a:hover { color: var(--text); border-color: var(--border-hi); }
.doc-nav a[aria-current="page"] { color: var(--text); border-color: var(--magenta); }

.doc h2 { font-size: clamp(26px, 3.4vw, 38px); margin-top: 72px; }
.doc h3 { font-size: 18px; font-weight: 600; margin-top: 40px; }
.doc p { margin-top: 16px; color: var(--dim); }
.doc p strong, .doc li strong { color: var(--text); font-weight: 600; }
.doc ul, .doc ol { margin-top: 16px; padding-left: 24px; color: var(--dim); }
.doc li { margin-top: 9px; }
.doc li::marker { color: var(--faint); }
.doc p a, .doc li a, .doc td a { color: var(--text); border-bottom: 1px solid var(--magenta); }
.doc p a:hover, .doc li a:hover, .doc td a:hover { color: var(--magenta); }

.doc code, .doc kbd {
  font-family: var(--mono); font-size: .86em;
  background: var(--surface-hi);
  border: 1px solid var(--border); border-radius: 5px;
  padding: 1px 6px;
  color: var(--text);
  white-space: nowrap;
}
.doc kbd { border-bottom-width: 2px; }

.table-wrap { overflow-x: auto; margin-top: 20px; }
.doc table { border-collapse: collapse; width: 100%; font-size: 14.5px; }
.doc th {
  font-family: var(--mono); font-size: 10.5px; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--faint); text-align: left;
  padding: 10px 16px 10px 0;
  border-bottom: 1px solid var(--border-hi);
}
.doc td {
  padding: 10px 16px 10px 0;
  border-bottom: 1px solid var(--border);
  color: var(--dim); vertical-align: top;
}
.doc td:first-child { font-family: var(--mono); font-size: .92em; color: var(--text); white-space: nowrap; }

.callout {
  margin-top: 22px; padding: 16px 18px;
  background: var(--surface);
  border: 1px solid var(--border); border-left: 2px solid var(--magenta);
  border-radius: 0 10px 10px 0;
  color: var(--dim); font-size: 15px;
}
.callout code { white-space: normal; }

/* Runbook timeline */
.tblock {
  margin-top: 56px; padding-left: 22px;
  border-left: 1px solid var(--border);
  position: relative;
}
.tblock::before {
  content: ""; position: absolute; left: -4px; top: 5px;
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--magenta);
}
.tmark {
  font-family: var(--mono); font-size: 12px; font-weight: 600;
  letter-spacing: .2em; color: var(--text);
}
.tblock h2 { margin-top: 10px; }

.doc-foot {
  margin-top: 80px; padding-top: 26px;
  border-top: 1px solid var(--border);
  font-family: var(--mono); font-size: 11px; letter-spacing: .1em;
  color: var(--faint);
}
.doc-foot a { color: var(--dim); border-bottom: 1px solid var(--magenta); }
.doc-foot a:hover { color: var(--magenta); }

/* 404 */
.lost {
  min-height: 100svh;
  display: grid; place-content: center;
  width: min(var(--max), 92vw); margin-inline: auto;
  text-align: left;
}
.lost h1 { font-size: clamp(44px, 8vw, 110px); }
.lost .cta-row { margin-top: 30px; }
