/* Rundown / Astra opening v2. Load after program.css and astra.css.
   One real field, one real light fixture. No video, invented hardware or mark effects. */
body.astra-v2 { --opening-cream: var(--rd-cream, #F5F1E8); }
body.astra-v2 .lights {
  --opening-scene-scale: 1; --opening-scene-y: 0px;
  --opening-copy-y: 0px; --opening-copy-opacity: 1; --opening-composition-lift: -28px;
  height: 100svh; min-height: 620px; isolation: isolate;
  background: var(--rd-forest-3); scroll-margin-top: 0;
}
body.astra-v2 .lights-scene { position: absolute; inset: 0; overflow: hidden;
  transform: translate3d(0,var(--opening-scene-y),0) scale(var(--opening-scene-scale));
  transform-origin: 50% 45%; pointer-events: none; }
body.astra-v2 .lights-art { animation: none; object-position: 24% 42%;
  filter: saturate(.72) brightness(.64) contrast(1.06); }
body.astra-v2 .lights-grade { opacity: 1; background:
  linear-gradient(180deg,rgba(8,58,45,.40),rgba(8,58,45,.12) 30%,rgba(8,58,45,.18) 53%,rgba(8,58,45,.88) 100%); }
body.astra-v2 .lights-blackout { background: var(--rd-forest-3); opacity: 0; animation: none; }
body.astra-v2 .lights-bloom { animation: none; }
body.astra-v2 .lb-1 { background: radial-gradient(26% 23% at var(--pole-x) var(--pole-y),rgba(245,241,232,.68),rgba(245,241,232,.26) 27%,rgba(244,196,48,.08) 52%,transparent 76%); }
body.astra-v2 .lb-2 { background: radial-gradient(72% 58% at var(--pole-x) 0%,rgba(245,241,232,.11),transparent 72%); }
body.astra-v2 .lb-3 { background: radial-gradient(75% 37% at 45% 100%,rgba(245,241,232,.12),transparent 72%); }
body.astra-v2 .lb-4 { background: radial-gradient(48% 55% at calc(var(--pole-x) + 12%) 55%,rgba(245,241,232,.11),transparent 76%); }
body.astra-v2 .lights-inner {
  inset: 5% 0 150px; gap: 0; z-index: 2; padding: 0 6%;
  transform: translate3d(0,calc(var(--opening-copy-y) + var(--opening-composition-lift)),0); opacity: var(--opening-copy-opacity);
}
body.astra-v2 .lights-lockup { position: relative; z-index: 1; animation: none; }
body.astra-v2 .lights-lockup img { width: clamp(260px,31vw,450px); height: auto; }
/* The original full lockup is unchanged, including its own generous clear space. */
body.astra-v2 .lights-rule { animation: none; width: 64px; height: 3px; margin: 3px 0 22px; border-radius: 0; box-shadow: none; }
body.astra-v2 .lights-tagline {
  color: var(--opening-cream); font-family: var(--rd-display,'Bebas Neue',sans-serif);
  font-size: clamp(58px,6.6vw,104px); line-height: .90; letter-spacing: -.018em;
  font-weight: 400; margin: 0; animation: none;
}
body.astra-v2 .lights-tagline span { display: block; }
body.astra-v2 .lights-line { animation: none; color: var(--opening-cream); margin-top: 23px;
  font-size: 11px; line-height: 1.5; letter-spacing: .10em; max-width: 42ch; }
body.astra-v2 .lights-bottom {
  position: absolute; z-index: 4; left: max(5%,env(safe-area-inset-left));
  right: max(5%,env(safe-area-inset-right)); bottom: max(35px,calc(env(safe-area-inset-bottom) + 18px));
  display: flex; align-items: flex-end; justify-content: space-between; gap: 24px;
}
body.astra-v2 .lights-ctas {
  position: static; transform: none; width: auto; display: flex; flex-wrap: wrap;
  gap: 20px; align-items: center; opacity: 1; animation: none !important;
}
body.astra-v2 .lights-action { display: flex; flex-direction: column; gap: 10px; }
body.astra-v2 .lights-action .btn { min-height: 52px; display: flex; align-items: center;
  justify-content: center; font-size: 22px; letter-spacing: .025em; padding: 15px 28px 13px;
  box-shadow: inset 0 -2px 0 rgba(8,58,45,.35); }
body.astra-v2 .lights-action small { color: var(--opening-cream); font: 11px/1.5 var(--rd-body,Inter,sans-serif); text-align: center; }
body.astra-v2 .lights-store { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
body.astra-v2 .lights-store small { color: var(--opening-cream); font: 11px/1.4 var(--rd-body,Inter,sans-serif); }
body.astra-v2 .lights-store .app-store-link { min-height: 44px; }
body.astra-v2 .lights-cue {
  position: static; display: flex; align-items: center; gap: 13px; flex: none;
  padding: 10px 0; min-height: 44px; color: var(--opening-cream); animation: none;
  font: 700 11px/1.4 var(--rd-body,Inter,sans-serif); letter-spacing: .08em;
}
body.astra-v2 .lights-cue .cue-arrow { display: inline-grid; place-items: center;
  width: 34px; height: 34px; border: 1px solid rgba(245,241,232,.55); border-radius: 50%;
  font-size: 19px; animation: none; transition: transform .25s ease; }
body.astra-v2 .lights-cue:hover .cue-arrow { transform: translateY(4px); }
body.astra-v2 .lights :focus-visible { outline-color: var(--rd-gold); }
/* The natural scroll takes the page from lit field to cream. This short seam is
   a continuation of the page, not a pinned spacer or a fake loading bar. */
body.astra-v2 .lights-seam { position: absolute; left: 0; right: 0; bottom: 0; height: 5px;
  background: var(--opening-cream); z-index: 5; pointer-events: none; }
body.astra-v2 .a-nav { position: sticky; top: 0; }

@media (prefers-reduced-motion: no-preference) {
  body.astra-v2.opening-motion:not(.opening-resolved) .lights-scene { animation: opening-camera 2400ms cubic-bezier(.18,.66,.3,1) both; }
  body.astra-v2.opening-motion:not(.opening-resolved) .lights-blackout { animation: opening-illumination 1550ms linear both; }
  body.astra-v2.opening-motion:not(.opening-resolved) .lb-1 { animation: opening-bank 900ms cubic-bezier(.2,.7,.2,1) 160ms both; }
  body.astra-v2.opening-motion:not(.opening-resolved) .lb-2 { animation: opening-ambient 1100ms ease-out 270ms both; }
  body.astra-v2.opening-motion:not(.opening-resolved) .lb-4 { animation: opening-ambient 1150ms ease-out 420ms both; }
  body.astra-v2.opening-motion:not(.opening-resolved) .lb-3 { animation: opening-ambient 1150ms ease-out 580ms both; }
  body.astra-v2.opening-motion:not(.opening-resolved) .lights-lockup { animation: opening-mark 1700ms cubic-bezier(.2,.7,.2,1) 200ms both; }
  body.astra-v2.opening-motion:not(.opening-resolved) .lights-rule { animation: opening-rule 600ms cubic-bezier(.2,.8,.2,1) 1350ms both; }
  body.astra-v2.opening-motion:not(.opening-resolved) .lights-tagline span { animation: opening-title 800ms cubic-bezier(.16,.8,.2,1) 1480ms both; }
  body.astra-v2.opening-motion:not(.opening-resolved) .lights-tagline span + span { animation-delay: 1600ms; }
  body.astra-v2.opening-motion:not(.opening-resolved) .lights-line { animation: opening-title 500ms ease-out 1750ms both; }
  @keyframes opening-camera { from { transform: translate3d(0,8px,0) scale(1.055); } to { transform: translate3d(0,0,0) scale(1); } }
  /* One strike, then a continuous settling exposure. No repeated flashes. */
  @keyframes opening-illumination { 0%,10% { opacity: .96; } 16% { opacity: .68; } 45% { opacity: .36; } 100% { opacity: 0; } }
  @keyframes opening-bank { 0% { opacity: 0; } 8% { opacity: 1; } 24% { opacity: .82; } 100% { opacity: 1; } }
  @keyframes opening-ambient { from { opacity: 0; } to { opacity: 1; } }
  /* The mark owns the first beat at the scale of the original opening. It
     holds long enough to read, then yields space to the locked tagline. */
  @keyframes opening-mark {
    0% { opacity: 0; transform: translateY(52px) scale(1.60); }
    16%,34% { opacity: 1; transform: translateY(52px) scale(1.60); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
  }
  @keyframes opening-rule { from { transform: scaleX(0); } to { transform: scaleX(1); } }
  @keyframes opening-title { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: none; } }
}
@media (min-aspect-ratio:4/3) {
  body.astra-v2 .lights-art { object-position:24% 20%; }
}
@media (min-aspect-ratio:16/9) {
  body.astra-v2 .lights-art { object-position:24% 12%; }
}
@media (max-width:760px) {
  body.astra-v2 .lights { min-height: 590px; }
  body.astra-v2 .lights-inner { inset: 0 0 150px; padding-inline: 6%; }
  body.astra-v2 .lights-lockup img { width: clamp(248px,72vw,340px); }
  body.astra-v2 .lights-rule { margin: 0 0 21px; width: 48px; }
  body.astra-v2 .lights-tagline { font-size: clamp(54px,14.5vw,82px); }
  body.astra-v2 .lights-line { font-size: 11px; letter-spacing: .045em; white-space: normal; margin-top: 18px; max-width: 30ch; }
  body.astra-v2 .lights-bottom { flex-direction: column; align-items: stretch; gap: 12px;
    bottom: max(17px,calc(env(safe-area-inset-bottom) + 10px)); }
  body.astra-v2 .lights-ctas { width: 100%; flex-direction: row; flex-wrap: nowrap; align-items: flex-start; gap: 16px; }
  body.astra-v2 .lights-action { flex: 1; min-width: 0; gap: 7px; }
  body.astra-v2 .lights-action .btn { width: 100%; padding-inline: 12px; font-size: 20px; white-space: nowrap; }
  body.astra-v2 .lights-store { flex: none; gap: 7px; }
  body.astra-v2 .lights-store .app-store-link { height: 52px; }
  body.astra-v2 .lights-store small { font-size: 10px; }
  body.astra-v2 .lights-cue { align-self: center; gap: 9px; padding: 0; min-height: 38px; font-size: 10px; }
  body.astra-v2 .lights-cue .cue-arrow { width: 26px; height: 26px; font-size: 16px; }
}
@media (max-width:380px) {
  body.astra-v2 .lights-store .app-store-badge { width: 108px; height: 36px; }
  body.astra-v2 .lights-store .app-store-link { min-width: 108px; }
  body.astra-v2 .lights-ctas { gap: 10px; }
  body.astra-v2 .lights-action .btn { font-size: 18px; padding-inline: 8px; }
}
@media (max-height:740px) and (orientation:portrait) {
  body.astra-v2 .lights-inner { inset: -12px 0 145px; }
  body.astra-v2 .lights-lockup img { width: min(64vw,282px); }
  body.astra-v2 .lights-tagline { font-size: clamp(50px,13vw,65px); }
  body.astra-v2 .lights-rule { margin-bottom: 15px; }
  body.astra-v2 .lights-line { margin-top: 14px; }
}
@media (max-height:520px) and (orientation:landscape) {
  body.astra-v2 .lights { min-height: 390px; --opening-composition-lift: 0px; }
  body.astra-v2 .lights-inner { inset: 10px 0 90px; display: flex; align-items: center; justify-content: center; gap: 30px; }
  body.astra-v2 .lights-lockup img { width: 190px; }
  body.astra-v2 .lights-rule,body.astra-v2 .lights-line { display: none; }
  body.astra-v2 .lights-tagline { font-size: clamp(48px,6.4vw,75px); }
  body.astra-v2 .lights-bottom { flex-direction: row; align-items: flex-end; bottom: 20px; }
  body.astra-v2 .lights-ctas { width: auto; }
  body.astra-v2 .lights-action .btn { min-height: 44px; font-size: 20px; }
  body.astra-v2 .lights-cue { align-self: auto; }
}
@media (prefers-reduced-motion:reduce) {
  body.astra-v2 .lights-scene { transform: none !important; }
  body.astra-v2 .lights-inner { transform: translateY(var(--opening-composition-lift)) !important; opacity: 1 !important; }
  body.astra-v2 .lights *,body.astra-v2 .lights *::before,body.astra-v2 .lights *::after { animation: none !important; transition: none !important; }
  body.astra-v2 .lights-blackout { opacity: 0 !important; }
}
