/* ============================================================
   03-hero.css — 2-column hero
   Left: copy + CTAs + stats. Right: BIG bear badge.
   ============================================================ */

#hero {
  position: relative;
  background:
    radial-gradient(ellipse at 20% 10%, rgba(21, 97, 45, 0.35) 0%, transparent 55%),
    radial-gradient(ellipse at 85% 90%, rgba(255, 215, 0, 0.10) 0%, transparent 55%),
    linear-gradient(180deg, var(--c-navy-dark) 0%, var(--c-navy) 100%);
  color: var(--c-white);
  padding: var(--s-9) 0 var(--s-8);
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: var(--s-7);
  align-items: center;
}

/* ---- Left: copy ---- */
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 215, 0, 0.12);
  border: 1px solid rgba(255, 215, 0, 0.40);
  color: var(--c-yellow);
  padding: 7px 18px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  margin-bottom: var(--s-4);
}
.hero-eyebrow-dot {
  width: 7px; height: 7px;
  background: var(--c-yellow);
  border-radius: 50%;
  display: block;
  animation: pulse-dot 2s ease infinite;
}
@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.5; transform: scale(0.8); }
}

.hero-copy h1 {
  color: var(--c-white);
  font-size: clamp(2.2rem, 4.6vw, 3.8rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: var(--s-4);
}
.hero-copy h1 em {
  font-style: normal;
  color: var(--c-yellow);
  display: inline-block;
}

.hero-lead {
  font-size: 1.1rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
  max-width: 560px;
  margin-bottom: var(--s-5);
}

.hero-actions {
  display: flex;
  gap: var(--s-3);
  flex-wrap: wrap;
  margin-bottom: var(--s-6);
}

/* ---- Stats strip ---- */
.hero-stats {
  display: flex;
  gap: var(--s-5);
  flex-wrap: wrap;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: var(--s-4);
}
.hero-stat strong {
  display: block;
  font-family: var(--f-display);
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--c-yellow);
  line-height: 1;
  letter-spacing: -0.02em;
}
.hero-stat span {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.65);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 6px;
}

/* ---- Right: BIG bear badge with ring + floating spec labels ---- */
.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

/* Wrap: a fixed square that holds the ring + badge + labels — everything centers around its centre. */
.hero-badge-wrap {
  position: relative;
  width: 100%;
  max-width: 480px;
  aspect-ratio: 1 / 1;
}

/* Soft yellow glow halo behind the wrap (reuses pulse animation) */
.hero-badge-wrap::before {
  content: "";
  position: absolute;
  inset: -8%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 215, 0, 0.20) 0%, transparent 65%);
  filter: blur(20px);
  z-index: 0;
  animation: pulse-halo 6s ease-in-out infinite;
}
@keyframes pulse-halo {
  0%, 100% { opacity: 0.85; transform: scale(1); }
  50%      { opacity: 1;    transform: scale(1.05); }
}

/* Dashed yellow ring — fills the wrap exactly, slowly rotating */
.hero-badge-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px dashed rgba(255, 215, 0, 0.35);
  z-index: 1;
  animation: spin-slow 30s linear infinite;
}
@keyframes spin-slow {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* Honour reduced-motion preference. Vestibular-disorder users get a static ring,
   no pulsing dot, and no halo glow. WCAG 2.1 AA SC 2.3.3. */
@media (prefers-reduced-motion: reduce) {
  .hero-badge-ring,
  .hero-eyebrow-dot,
  .hero-badge-wrap::before {
    animation: none;
  }
}

/* Badge — absolutely centred inside the wrap, slightly smaller so ring shows around it */
.hero-badge {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 92%;
  height: 92%;
  object-fit: contain;
  z-index: 2;
  filter: drop-shadow(0 24px 48px rgba(0, 0, 0, 0.55));
}

/* Floating spec labels — anchored to wrap corners, sit beside the ring */
.hero-float-label {
  position: absolute;
  z-index: 3;
  background: rgba(15, 30, 54, 0.78);
  color: #e2e8f0;
  border: 1px solid rgba(0, 240, 255, 0.18);
  border-radius: var(--radius);
  padding: 12px 16px;
  font-size: 0.85rem;
  font-weight: 700;
  box-shadow: var(--shadow-lg);
  white-space: nowrap;
}
.hero-float-label strong {
  color: var(--c-green);
  display: block;
}
.hero-float-label span {
  display: block;
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--c-muted);
  margin-top: 2px;
}
.hero-float--top    { top: -10px;    right: -70px; }
.hero-float--bottom { bottom: -10px; left:  -70px; }
@media (max-width: 1200px) {
  .hero-float--top    { top: -10px;    right: -20px; }
  .hero-float--bottom { bottom: -10px; left:  -20px; }
}

/* ---- Responsive ---- */
@media (max-width: 960px) {
  #hero { padding: var(--s-8) 0 var(--s-7); }
  .hero-grid { grid-template-columns: 1fr; gap: var(--s-6); text-align: center; }
  .hero-eyebrow,
  .hero-actions,
  .hero-stats { justify-content: center; }
  .hero-lead { margin-left: auto; margin-right: auto; }
  .hero-visual { order: -1; }
  .hero-badge-wrap { max-width: 320px; }
  .hero-float-label { font-size: 0.78rem; padding: 10px 12px; }
  .hero-float--top    { top: -10px; right: 0; }
  .hero-float--bottom { bottom: -10px; left: 0; }
}
@media (max-width: 480px) {
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; justify-content: center; }
  .hero-badge-wrap { max-width: 240px; }
  .hero-float-label { display: none; }
}

/* ============================================================
   CINEMATIC LAYER — shipped 2026-05-20
   Letterbox bars, deeper vignette, one-shot boot beam, slower
   wider orb drift, and a staggered entrance animation. Scoped
   to #hero only so the rest of the page keeps the existing
   reveal animations.
   ============================================================ */

/* ---- Stacking context + safe layering on top of cyber-crt ----
   The cyber-crt overlay sits at z-index 3-4. Letterbox + beam need
   to win over CRT scanlines but stay BELOW the actual hero content
   (which uses .container at z-index 1 via cyber-grid). Container
   is bumped to a higher z-index so it always sits over the overlays. */
#hero { isolation: isolate; }
#hero > .container { z-index: 5; }

/* ---- Colour grade — saturate + punch, hero only ---- */
#hero {
  filter: saturate(1.08) contrast(1.03);
}

/* ---- Deeper radial vignette ---- */
.hero-vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
  background: radial-gradient(
    ellipse at center,
    transparent 30%,
    rgba(0, 0, 0, 0.55) 85%,
    rgba(0, 0, 0, 0.85) 100%
  );
}

/* ---- Letterbox bars (top + bottom) ----
   Pure black with a faint cyan inner edge. scaleY 0 → 1 on load
   from each outer edge. */
.hero-letterbox {
  position: absolute;
  left: 0;
  right: 0;
  height: 36px;
  background: #000;
  pointer-events: none;
  z-index: 6;
  transform: scaleY(0);
}
.hero-letterbox--top {
  top: 0;
  transform-origin: top center;
  border-bottom: 1px solid rgba(0, 240, 255, 0.35);
  box-shadow: 0 0 14px rgba(0, 240, 255, 0.22);
}
.hero-letterbox--bottom {
  bottom: 0;
  transform-origin: bottom center;
  border-top: 1px solid rgba(0, 240, 255, 0.35);
  box-shadow: 0 0 14px rgba(0, 240, 255, 0.22);
}

/* ---- One-shot cyan boot beam — sweeps top → bottom over 1.8s
   on first load, then disappears (animation runs once + forwards). */
.hero-boot-beam {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 3px;
  pointer-events: none;
  z-index: 5;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(0, 240, 255, 0.55) 30%,
    rgba(0, 240, 255, 0.95) 50%,
    rgba(0, 240, 255, 0.55) 70%,
    transparent 100%);
  box-shadow:
    0 0 18px rgba(0, 240, 255, 0.65),
    0 0 48px rgba(0, 240, 255, 0.35);
  opacity: 0;
  transform: translateY(0);
}

/* ---- Slower, wider orb drift — hero-scoped only ----
   Existing .orb still drifts site-wide at 22-32s. Inside #hero we
   slow each preset to 40-50s and widen the keyframe translation so
   they feel like they're sweeping through deep space. */
#hero .orb {
  animation: hero-orb-float 44s ease-in-out infinite;
}
#hero .orb--tr { animation-delay: -12s; animation-duration: 48s; }
#hero .orb--bl { animation-delay: -22s; animation-duration: 50s; }
#hero .orb--br { animation-delay: -6s;  animation-duration: 42s; }
#hero .orb--c  { animation-delay: -18s; animation-duration: 46s; }

@keyframes hero-orb-float {
  0%, 100% { transform: translate(0, 0)            scale(1);   }
  25%      { transform: translate(140px, -90px)    scale(1.10); }
  50%      { transform: translate(-110px, 130px)   scale(0.92); }
  75%      { transform: translate(90px, 70px)      scale(1.06); }
}

/* ============================================================
   STAGGERED CINEMATIC ENTRANCE — first page load
   Hero children fade in IN SEQUENCE with deliberate timing.
   The parent #hero.cinematic-enter sets opacity=0 children, each
   keyframed back to 1 at its scheduled delay.
   ============================================================ */
.cinematic-enter .hero-eyebrow,
.cinematic-enter .hero-copy h1,
.cinematic-enter .hero-lead,
.cinematic-enter .hero-actions,
.cinematic-enter .hero-stats,
.cinematic-enter .hero-visual {
  opacity: 0;
  transform: translateY(12px);
  animation: cinematic-fade-up 0.85s var(--ease-out) forwards;
  will-change: opacity, transform;
}

.cinematic-enter .hero-eyebrow { animation-delay: 0.40s; }
.cinematic-enter .hero-copy h1 { animation-delay: 0.70s; }
.cinematic-enter .hero-lead    { animation-delay: 1.20s; }
.cinematic-enter .hero-actions { animation-delay: 1.60s; }
.cinematic-enter .hero-stats   { animation-delay: 2.00s; }
.cinematic-enter .hero-visual  { animation-delay: 0.90s; } /* bear badge slightly behind H1 */

@keyframes cinematic-fade-up {
  0%   { opacity: 0; transform: translateY(12px); filter: blur(3px); }
  100% { opacity: 1; transform: translateY(0);   filter: blur(0);   }
}

/* Letterbox formation: scaleY 0 → 1 from each edge, finishes at 2.4s */
.cinematic-enter .hero-letterbox--top {
  animation: cinematic-letterbox-top 1.2s var(--ease-out) 1.2s forwards;
}
.cinematic-enter .hero-letterbox--bottom {
  animation: cinematic-letterbox-bottom 1.2s var(--ease-out) 1.2s forwards;
}
@keyframes cinematic-letterbox-top {
  0%   { transform: scaleY(0); }
  100% { transform: scaleY(1); }
}
@keyframes cinematic-letterbox-bottom {
  0%   { transform: scaleY(0); }
  100% { transform: scaleY(1); }
}

/* Boot beam: sweeps top → bottom once on load. Runs 0.0s → 1.8s,
   then opacity drops and stays at 0. */
.cinematic-enter .hero-boot-beam {
  animation: cinematic-boot-beam 1.8s ease-out 0.1s forwards;
}
@keyframes cinematic-boot-beam {
  0%   { opacity: 0;    transform: translateY(0); }
  8%   { opacity: 1; }
  92%  { opacity: 1; }
  100% { opacity: 0;    transform: translateY(calc(100vh - 3px)); }
}

/* ============================================================
   MOBILE — thinner letterbox bars, parallax skipped (JS-side)
   ============================================================ */
@media (max-width: 600px) {
  .hero-letterbox { height: 14px; }
  /* Slightly less aggressive vignette so small screens keep content readable */
  .hero-vignette {
    background: radial-gradient(
      ellipse at center,
      transparent 25%,
      rgba(0, 0, 0, 0.45) 85%,
      rgba(0, 0, 0, 0.75) 100%
    );
  }
}

/* ============================================================
   REDUCED MOTION — entrance + parallax + boot beam all skipped.
   Letterbox stays formed (static) so the cinematic frame still
   reads. Colour grade stays.
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  .cinematic-enter .hero-eyebrow,
  .cinematic-enter .hero-copy h1,
  .cinematic-enter .hero-lead,
  .cinematic-enter .hero-actions,
  .cinematic-enter .hero-stats,
  .cinematic-enter .hero-visual {
    opacity: 1 !important;
    transform: none !important;
    animation: none !important;
    filter: none !important;
  }
  .cinematic-enter .hero-letterbox--top,
  .cinematic-enter .hero-letterbox--bottom {
    transform: scaleY(1) !important;
    animation: none !important;
  }
  .hero-boot-beam { display: none !important; }
  #hero .orb { animation: none !important; }
}

