.hero {
  position: relative;
  height: 100vh;
  height: 100svh;
  overflow: hidden;
  background: var(--dark);
  color: var(--on-video);
}
.hero__media { position: absolute; inset: 0; }
.hero__poster, .hero__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hero__poster { object-fit: cover; }
.hero__canvas { display: block; }
.hero.is-ready .hero__poster { visibility: hidden; }

/* shadows so text reads on any frame */
.hero__shade { position: absolute; pointer-events: none; }
.hero__shade--top { inset: 0 0 auto 0; height: 22vh; background: linear-gradient(to bottom, rgba(20, 17, 14, 0.62), rgba(20, 17, 14, 0)); }
.hero__shade--bottom { inset: auto 0 0 0; height: 62vh; background: linear-gradient(to top, rgba(20, 17, 14, 0.9), rgba(20, 17, 14, 0.45) 45%, rgba(20, 17, 14, 0)); }
.hero__shade--left { inset: 0 auto 0 0; width: 70vw; background: linear-gradient(to right, rgba(20, 17, 14, 0.7), rgba(20, 17, 14, 0)); opacity: 0; }

/* steps, bottom left */
.hero__steps {
  position: absolute;
  left: var(--gutter);
  right: var(--gutter);
  bottom: calc(var(--s-8) + var(--s-2));
}
.hero-step { position: absolute; left: 0; bottom: 0; max-width: 100%; }
.hero-step--intro { position: relative; }
.hero__brand {
  display: flex;
  flex-wrap: nowrap;
  column-gap: 0.18em;
  font-family: var(--font-brand);
  font-weight: var(--w-brand-hero);
  letter-spacing: var(--track-brand-hero) !important;
  font-size: var(--t-brand);
  line-height: 0.82;
  letter-spacing: -0.02em;
  white-space: nowrap;
  margin-left: -0.04em;
}
.hero__sub {
  margin-top: var(--s-5);
  font-size: clamp(1rem, 0.85rem + 0.5vw, 1.375rem);
  line-height: 1.4;
  color: var(--on-video);
}
.hero-step__label {
  font-family: var(--font-mono);
  font-size: var(--t-small);
  margin-bottom: var(--s-4);
}
.dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: var(--s-2);
  border-radius: 50%;
  background: var(--pepper);
  vertical-align: 0.05em;
}
.hero-step__title {
  font-variation-settings: var(--wide);
  font-weight: 800;
  font-size: var(--t-hero-step);
  line-height: 0.95;
  letter-spacing: -0.01em;
}
.hero-step__title .line > span { white-space: nowrap; }
.hero-step__note { margin-top: var(--s-4); font-size: clamp(1rem, 0.85rem + 0.5vw, 1.25rem); }
.hero-step__cta { margin-top: var(--s-5); }
.hero-step__cta .line { padding: 2px 2px 4px; margin: -2px; }

/* bottom bar */
.hero__bar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--s-4);
  padding: var(--s-4) var(--gutter) var(--s-5);
  font-family: var(--font-mono);
  font-size: var(--t-mono);
  color: var(--on-video-2);
}
.hero__progress { position: absolute; left: 0; right: 0; top: 0; height: 1px; background: var(--rule-dark); }
.hero__progress span { position: absolute; inset: 0; background: var(--pepper); transform-origin: left; transform: scaleX(0); }
.hero__hint { transition: opacity var(--dur-3) var(--ease-out); }
.hero__hint.is-gone { opacity: 0; }
.hero__count { justify-self: end; font-variant-numeric: tabular-nums; }
.hero__count span { color: var(--on-video); }

/* language switch: bottom-right corner of the hero */
.hero__lang {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: var(--s-1);
  font-family: var(--font-mono);
  font-size: var(--t-mono);
  letter-spacing: 0.08em;
  color: var(--on-video-2);
}
.hero__lang button {
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  background: none;
  border: 0;
  padding: 12px 6px;
  margin: -12px 0;
  cursor: pointer;
  opacity: 0.6;
  transition: opacity var(--dur-3) var(--ease-out), color var(--dur-3) var(--ease-out);
}
.hero__lang button:hover { opacity: 1; }
.hero__lang button[aria-pressed="true"] { color: var(--on-video); opacity: 1; }
.hero__lang button:focus-visible { outline: 1px solid var(--on-video); outline-offset: -6px; }

/* before JS takes over: steps 2-4 stay out of view */
.js .hero-step:not(.hero-step--intro) { visibility: hidden; }
.js .hero.is-ready .hero-step { visibility: visible; }

@media (max-width: 47.99rem) {
  .hero__steps { bottom: calc(var(--s-8) + var(--s-1)); }
  /* on a phone the name stacks on two lines, larger */
  .hero__brand { flex-direction: column; font-size: 19vw; line-height: 0.9; }
  .hero-step__title { font-size: clamp(1.9rem, 9vw, 3rem); }
  .hero-step__title .line > span { white-space: normal; }
  .hero__bar { grid-template-columns: 1fr auto; }
  .hero__hint { display: none; }
  .hero__shade--left { width: 100vw; }
}
