/* About's opening: the microwave (tools/abouthero.mjs says what and why; assets/js/about-hero.js draws it).
   Before the script runs, without it, or with reduced motion, the slogan and the lead stand in the middle of the red. */
.ah { position: relative; height: 100svh; min-height: 620px; background: var(--red); color: #fff; overflow: clip; --focus: #fff;
  -webkit-tap-highlight-color: transparent; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.ah__gl { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.ah__copy { position: absolute; left: 0; right: 0; top: 50%; translate: 0 -50%; padding: 0 var(--pad-r) 0 var(--pad-l); text-align: center; pointer-events: none; }
.ah__copy h1 { margin: 0; font: 800 clamp(3.2rem, 11vw, 9rem)/0.92 var(--head); letter-spacing: -0.02em; text-wrap: balance; }
.ah__copy p { margin: 18px auto 0; max-width: 40ch; font: 600 clamp(1.1rem, 1.7vw, 1.5rem)/1.3 var(--head); text-wrap: balance; }
/* with script on (the head script has set data-lang) and motion allowed, the canvas will draw the slogan: keep the
   static one out of the first frames, and so out of a page transition's view of them, until the canvas is live. If the
   script never takes over, the static slogan shows after a moment. */
@media (prefers-reduced-motion: no-preference) {
  html[data-lang] .ah:not(.is-live) .ah__copy { opacity: 0; animation: ah-wait 0s 2.5s forwards; }
}
@keyframes ah-wait { to { opacity: 1; } }
/* live: the canvas draws the slogan, so the h1 is kept for readers only; the lead waits under the letters until they land */
.ah.is-live { cursor: pointer; }
.ah.is-live .ah__copy { top: var(--lead-y, 50%); translate: none; }
.ah.is-live .ah__copy h1 { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.ah.is-live .ah__copy p { margin-top: 0; opacity: 0; transform: translateY(10px); text-shadow: 0 1px 14px rgba(90, 10, 0, 0.45); }
.ah.is-ready .ah__copy p { opacity: 1; transform: none; transition: opacity 800ms ease, transform 900ms var(--ease-out); }
/* the sound switch only shows once the script can play anything */
.ah__sound { display: none; position: absolute; right: var(--pad-r); bottom: calc(18px + env(safe-area-inset-bottom)); align-items: center; gap: 8px; min-height: 44px; padding: 0 16px;
  border: 2px solid rgba(255, 255, 255, 0.7); border-radius: var(--r-pill); background: rgba(27, 22, 18, 0.18); color: #fff; font: 700 1rem/1 var(--head); cursor: pointer; z-index: 2; }
.ah.is-live .ah__sound { display: inline-flex; }
.ah__sound:hover { border-color: #fff; background: rgba(27, 22, 18, 0.32); }
.ah__sound svg { width: 18px; height: 18px; }
.ah__sound[aria-pressed="false"] .on, .ah__sound[aria-pressed="true"] .off { display: none; }
/* on a phone the switch is just its icon, clear of the microwave */
@media (max-width: 699px) {
  .ah__sound { width: 44px; padding: 0; justify-content: center; }
  .ah__sound span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
}
