/* ==========================================================================
   HERO
   The canvas (drawn by js/hero.js) paints the moving symbols and the headline.
   Without JavaScript, or with reduced motion, the plain HTML text is shown.
   ========================================================================== */

.hero {
  position: relative;
  display: grid;
  place-items: center;
  min-height: calc(100vh - var(--header-h));
  min-height: calc(100svh - var(--header-h));
  overflow: hidden;
  text-align: center;
  touch-action: pan-y;       /* vertical swipes still scroll the page */
}

.hero__canvas {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.hero__copy {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: var(--space-5);
  padding-block: var(--space-8);
}

.hero__kicker {
  font-family: var(--font-display);
  font-size: var(--step-1);
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.hero__title {
  max-width: none;
  font-size: clamp(2.75rem, 1.2rem + 6.4vw, 6.5rem);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -0.025em;
}
@media (min-width: 810px) {
  .hero__line { display: block; }   /* two clean lines on tablet and desktop */
}

.hero__sub {
  max-width: none;
  font-size: var(--step-0);
  color: var(--color-muted);
}

/* Live mode: the canvas draws the text, so the HTML copy stays invisible
   (it remains in the page for screen readers and search engines). */
.hero.is-live .hero__canvas { z-index: 2; }
.hero.is-live .hero__copy { opacity: 0; }

/* Replay button */
.hero__replay {
  position: absolute;
  left: 50%;
  bottom: var(--space-6);
  z-index: 3;
  display: inline-flex;
  align-items: center;
  height: 44px;
  padding: 0 13px;
  border: 1px solid var(--color-line);
  border-radius: 999px;
  background: var(--color-surface);
  color: var(--color-accent);
  font: 500 var(--step--1) / 1 var(--font-body);
  cursor: pointer;
  transform: translateX(-50%);
  animation: hero-replay-in 800ms var(--ease-out) 2.5s both;
  transition: border-color var(--dur-base) var(--ease-out), background var(--dur-base) var(--ease-out);
}
.hero__replay[hidden] { display: none; }
.hero__replay svg {
  width: 18px;
  height: 18px;
  flex: none;
  transition: transform 600ms var(--ease-out);
}
.hero__replay-label {
  max-width: 0;
  margin-left: 0;
  overflow: hidden;
  opacity: 0;
  white-space: nowrap;
  transition: max-width var(--dur-base) var(--ease-out), margin var(--dur-base) var(--ease-out), opacity var(--dur-base) var(--ease-out);
}
.hero__replay:hover,
.hero__replay:focus-visible { border-color: var(--color-accent); }
.hero__replay:hover svg,
.hero__replay:focus-visible svg { transform: rotate(-360deg); }
.hero__replay:hover .hero__replay-label,
.hero__replay:focus-visible .hero__replay-label { max-width: 8rem; margin-left: var(--space-2); opacity: 1; }
.hero__replay:active { background: var(--color-accent-soft); }

@keyframes hero-replay-in {
  from { opacity: 0; transform: translate(-50%, 8px); }
  to   { opacity: 1; transform: translate(-50%, 0); }
}

.cs-hero__images .cs-figure {
  width: 100vw;
  margin-left: 50%;
  transform: translateX(-50%);
}
.cs-hero__images .cs-figure video {
  display: block;
  width: 100%;
  height: auto;
}