/* =========================================================
   Hero voice-over (left column) + pricing console (right column).
   Loaded only when the studio widget renders with data-nr-dialog.
   Driven by hero-dialog.js. Scoped to #nr-root like netroom.css.

   The CONSOLE scene was cut on 2026-08-25: no power-on dim, no quoted
   marketing, no answering lines, no caret inside the studio, no fake input
   caret. The studio is live and typable from the first frame; the only thing
   it prints is the receipt for a run the visitor asked for.

   The LEFT-column voice-over stayed: the caret reveals the H1, strikes the
   boilerplate paragraph and speaks in its place.
   ========================================================= */
#nr-root .studio[data-nr-dialog] {
  /* Phosphor green is the console TEXT voice and nothing else — no caret
     anywhere carries it. Every caret on the page is the brand purple. */
  --dlg-phos: #4bf07a;
}

/* The studio window is a product screen: it stays dark in the light theme too. */
#nr-root[data-theme="light"] .studio[data-nr-dialog] {
  --bg-1: #0d0d10;
  --bg-2: #121216;
  --bg-3: #17171c;
  --line: rgba(255, 255, 255, 0.06);
  --line-2: rgba(255, 255, 255, 0.12);
  --fg: #f2f2f4;
  --fg-dim: #a1a1aa;
  --fg-faint: #6b6b74;
  --fg-mute: #4a4a52;
  --scrim-rgb: 255, 255, 255;
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.45);
}

/* ── Left column: the caret reveals the H1, the boilerplate gets struck and
   the voice-over takes its place ──────────────────────────────────────── */
#nr-root.nr-hero-dialog .hero-copy { position: relative; }
/* The voice-over block makes the copy column taller than the studio card;
   centring would push the card (and its input) below the fold. */
#nr-root.nr-hero-dialog .hero-grid { align-items: start; }
/* The second H1 line is revealed through a clip-path driven by hero-dialog.js
   (measured per character) — the markup and text stay exactly as served.
   NB: hero-dialog.js owns the reveal, and every path through its init()
   (reduced motion, returning visitor, skip) clears the clip. */
#nr-root.nr-hero-dialog .hero-h1 .grad-text {
  display: inline-block; max-width: 100%;
  clip-path: inset(0 100% 0 0);
}
#nr-root .hero-dlg-caret {
  position: absolute; left: 0; top: 0;
  width: 0.5em; height: 0.95em;
  background: var(--g2);
  box-shadow: 0 0 0.5em rgba(139, 92, 246, 0.45);
  visibility: hidden; pointer-events: none;
  will-change: transform;
}
#nr-root .hero-dlg-caret.is-on { visibility: visible; }
#nr-root .hero-dlg-caret.is-blink { animation: nr-dlg-blink 1.06s steps(1, end) infinite; }
#nr-root .hero-dlg-caret.is-out { opacity: 0; transition: opacity 300ms ease-out; }

/* The boilerplate paragraph: struck through, then hidden — it stays in the DOM
   (SEO), the voice-over takes its cell. Both share one grid cell, so nothing
   below ever moves. */
#nr-root .hero-voice { display: grid; max-width: 540px; margin-top: 18px; }
#nr-root .hero-voice > * { grid-area: 1 / 1; }
#nr-root .hero-voice .hero-reassure { margin: 0; align-self: start; }
#nr-root.nr-hero-dialog .hero-voice .hero-reassure.is-struck {
  text-decoration: line-through;
  text-decoration-thickness: 1px;
  opacity: 0.42;
  transition: opacity 320ms ease-in-out;
}
#nr-root.nr-hero-dialog .hero-voice .hero-reassure.is-gone {
  opacity: 0; visibility: hidden;
  transition: opacity 300ms ease-out, visibility 0s 300ms;
}
/* One line at a time; the cell is as tall as the paragraph it replaces, so the
   buttons below never move. */
#nr-root .hero-voice-log {
  align-self: start;
  display: flex; flex-direction: column; gap: 8px;
  min-height: 1.4em;
  font-family: var(--font-mono);
  font-size: clamp(16px, 1.4vw, 18px); line-height: 1.4;
  color: var(--fg);
}
#nr-root .hero-dlg-tx { white-space: pre-wrap; }
#nr-root .hero-dlg-cr {
  display: inline-block;
  width: 0.55em; height: 1.05em;
  vertical-align: -0.18em; margin-left: 0.3ch;
  background: var(--g2);
  box-shadow: 0 0 0.5em rgba(139, 92, 246, 0.45);
}
#nr-root .hero-dlg-cr.is-blink { animation: nr-dlg-blink 1.06s steps(1, end) infinite; }
#nr-root .hero-dlg-cr.is-out { opacity: 0; transition: opacity 300ms ease-out; }

/* FLIP clone for the caret's hop from the H1 into the voice-over slot: it moves
   and scales, it never recolours (both ends are the same purple). */
#nr-root .studio-dlg-fly {
  position: fixed; z-index: 50; pointer-events: none;
  transform-origin: top left;
}
@keyframes nr-dlg-blink {
  0%, 50% { opacity: 1; }
  50.01%, 100% { opacity: 0; }
}

/* ── Console voice (the receipt is all that speaks now) ───────────────── */
#nr-root .studio-dlg-l { color: var(--dlg-phos); }
#nr-root .studio-dlg-pr { opacity: 0.55; margin-right: 0.7ch; }
#nr-root .studio-dlg-tx { white-space: pre-wrap; }
#nr-root .studio-dlg-num { font-variant-numeric: tabular-nums; }

/* Per-answer price on the model chips. Plain CSS on server-rendered markup:
   the price is a fact about the chip, so it is visible on first paint and does
   not depend on JS running at all (it used to fade in as part of the scene). */
#nr-root .studio[data-nr-dialog] .studio-chip-price {
  font-family: var(--font-mono); font-style: normal;
  font-size: 11px; letter-spacing: 0.01em;
  color: var(--a1);
}

/* ── Receipt ──────────────────────────────────────────────────────────── */
#nr-root .studio-dlg-receipt {
  display: flex; flex-direction: column; gap: 12px;
  flex: none;
  padding: 2px 2px 4px;
  font-family: var(--font-mono);
  font-size: 14px; line-height: 1.5;
}
#nr-root .studio-dlg-btns { display: flex; gap: 8px; flex-wrap: wrap; }
#nr-root .studio-dlg-btns .btn {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 250ms ease-out, transform 250ms ease-out;
}
#nr-root .studio-dlg-btns.is-in .btn { opacity: 1; transform: none; }
#nr-root .studio-dlg-btns.is-instant .btn { transition: none; }
/* The receipt carries its own CTAs — the widget's generic sign-up strip steps
   aside from the first run on (hero-dialog.js sets the class on submit). */
#nr-root .studio[data-nr-dialog].has-receipt .studio-cta { display: none; }

/* Screen-reader-only helper next to the prompt. */
#nr-root .studio-dlg-sr {
  position: absolute; width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%);
  white-space: nowrap;
}

/* ── Test controls (only on the staging route) ────────────────────────── */
#nr-root .nr-dlg-debug {
  position: fixed; right: 16px; top: 76px; z-index: 60;
  display: flex; align-items: center; gap: 6px;
  padding: 6px 8px;
  border-radius: 999px;
  background: rgba(13, 13, 16, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 18px 40px -20px rgba(0, 0, 0, 0.7);
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.02em;
  color: #a1a1aa;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
#nr-root .nr-dlg-debug-tag { padding: 0 6px 0 4px; color: #6b6b74; }
#nr-root .nr-dlg-debug button,
#nr-root .nr-dlg-debug a {
  font: inherit; color: inherit;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  padding: 5px 10px;
  cursor: pointer;
  transition: color 150ms ease-out, border-color 150ms ease-out;
}
#nr-root .nr-dlg-debug button:hover,
#nr-root .nr-dlg-debug a:hover { color: #f2f2f4; border-color: rgba(179, 122, 255, 0.6); }
#nr-root .nr-dlg-debug button:focus-visible,
#nr-root .nr-dlg-debug a:focus-visible { outline: 2px solid var(--g1); outline-offset: 2px; }
#nr-root .nr-dlg-debug .is-active { color: #f2f2f4; border-color: var(--g1); }

@media (max-width: 640px) {
  #nr-root .nr-dlg-debug { right: 10px; top: auto; bottom: 10px; }
  #nr-root .hero-voice-log { min-height: calc(2 * 1.4em); }
  /* Phones: the boilerplate is an eight-line wall, and a shared grid cell
     keeps its height after the strike — a paragraph-sized hole above the
     composer. Stack the two instead and let the paragraph fold away
     (max-height ramp shorter than T.hide, so the caret's hop target is
     measured at rest). */
  #nr-root .hero-voice { display: block; }
  #nr-root.nr-hero-dialog .hero-voice .hero-reassure {
    max-height: 14em; overflow: hidden;
    transition: opacity 320ms ease-in-out, max-height 260ms ease-out;
  }
  #nr-root.nr-hero-dialog .hero-voice .hero-reassure.is-gone {
    max-height: 0; opacity: 0; visibility: hidden;
    transition: opacity 240ms ease-out, max-height 260ms ease-out, visibility 0s 260ms;
  }
}

@media (prefers-reduced-motion: reduce) {
  #nr-root .studio-dlg-btns .btn,
  #nr-root .hero-dlg-caret,
  #nr-root .hero-dlg-cr,
  #nr-root.nr-hero-dialog .hero-voice .hero-reassure { transition: none; }
  #nr-root .hero-dlg-cr.is-blink,
  #nr-root .hero-dlg-caret.is-blink { animation: none; }
}
