/* ==========================================================================
   HERO STAGE — SCROLL-CONTROLLED 50-FRAME INTRO -> HERO -> BLACKOUT + PANEL
   ========================================================================== */

.hero-pin-wrap {
  position: relative;
  width: 100%;
  background-color: var(--color-bg-pure);
}

.hero-section {
  position: relative;
  width: 100%;
  height: 100vh;
  height: 100svh;
  min-height: 540px;
  overflow: hidden;
  background-color: var(--color-bg-pure);
}

.hero-grain {
  position: absolute;
  inset: 0;
  z-index: var(--z-grain);
  pointer-events: none;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)' opacity='0.85'/%3E%3C/svg%3E");
}

/* LAYER 1 — Pure Black Background */
.hero-bg-layer {
  position: absolute;
  inset: 0;
  z-index: var(--z-bg);
  pointer-events: none;
  opacity: 0;
  will-change: opacity;
}

.hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

/* LAYER 2 — Athletic Bold Italic Display Typography Behind Rahul */
.hero-typography-layer {
  position: absolute;
  inset: 0;
  z-index: var(--z-type);
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding-top: clamp(138px, 18.5svh, 206px);
}

.hero-name-lockup {
  width: fit-content;
  max-width: 94vw;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-reveal-mask {
  overflow: hidden;
  padding: 0.06em 0.16em 0.08em 0.08em;
  margin: -0.06em -0.16em -0.08em -0.08em;
}

.hero-lastname-wrap {
  width: 100%;
  display: flex;
  justify-content: center;
}

.hero-lastname {
  font-family: var(--font-hero-display);
  font-size: clamp(4.2rem, 18.8vw, 18.2rem);
  font-weight: 900;
  font-style: italic;
  letter-spacing: 0.08em;
  line-height: 0.9;
  text-transform: uppercase;
  text-align: center;
  text-indent: 0.08em;
  white-space: nowrap;
  user-select: none;
  color: var(--color-accent);
  padding: 0 0.08em 0 0.04em;
  will-change: transform, opacity;
}

/* LAYER 2.5 — Scroll-Controlled 50-Frame Head-Raise Canvas */
.hero-canvas-layer {
  position: absolute;
  inset: 0;
  z-index: var(--z-canvas);
  pointer-events: none;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  will-change: opacity;
}

.hero-sequence-frame {
  position: relative;
  height: var(--hero-stage-h);
  aspect-ratio: 16 / 9;
  max-width: none;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  overflow: hidden;
}

.hero-sequence-canvas {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center bottom;
  display: block;
}

/* LAYER 3 — Transparent Final Character Portrait */
.hero-character-layer {
  position: absolute;
  inset: 0;
  z-index: var(--z-character);
  pointer-events: none;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.hero-character {
  position: relative;
  height: calc(var(--hero-stage-h) * var(--char-scale-ratio));
  width: auto;
  max-width: none;
  bottom: var(--char-bottom-offset);
  object-fit: contain;
  opacity: 0;
  will-change: opacity;
}

/* LAYER 4 — Editorial Interface & Redesigned Buttons */
.hero-ui-layer {
  position: absolute;
  inset: 0;
  z-index: var(--z-ui);
  pointer-events: none;
}

body.is-hero-intro .hero-typography-layer,
body.is-hero-intro .hero-ui-layer {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

.skip-intro-btn {
  position: absolute;
  right: max(var(--hero-side-gutter), env(safe-area-inset-right));
  bottom: max(clamp(20px, 4svh, 38px), env(safe-area-inset-bottom));
  z-index: 65;
  pointer-events: auto;
  min-height: 44px;
  min-width: 44px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 3px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background-color: rgba(10, 10, 10, 0.84);
  color: rgba(244, 244, 242, 0.9);
  font-size: 0.76rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: border-color var(--transition-fast) ease, color var(--transition-fast) ease;
}

.skip-intro-btn:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

body.is-preloading .skip-intro-btn,
body:not(.is-hero-intro) .skip-intro-btn {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.hero-intro-prompt {
  position: absolute;
  left: 50%;
  bottom: max(clamp(18px, 3.6svh, 34px), env(safe-area-inset-bottom));
  transform: translateX(-50%);
  z-index: 64;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  will-change: transform, opacity;
}

.hero-intro-prompt-label {
  font-family: var(--font-sans);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(244, 244, 242, 0.72);
  white-space: nowrap;
}

.hero-intro-prompt-line {
  width: 1.5px;
  height: 26px;
  background: linear-gradient(to bottom, var(--color-accent), rgba(182, 255, 0, 0.08));
  animation: scrollHairline 2s ease-in-out infinite;
}

body.is-preloading .hero-intro-prompt,
body:not(.is-hero-intro) .hero-intro-prompt {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

.hero-editorial-block {
  position: absolute;
  left: var(--hero-side-gutter);
  bottom: clamp(50px, 9svh, 92px);
  max-width: 360px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
}

.hero-role-label {
  font-family: var(--font-sans);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-accent);
}

.hero-tagline-sub {
  font-size: 0.95rem;
  font-weight: 400;
  line-height: 1.6;
  color: rgba(244, 244, 242, 0.84);
}

.hero-cta-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  padding-top: 6px;
  pointer-events: auto;
}

/* Redesigned Proportional Athletic Rectangular Buttons */
.btn-hero-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 12px 22px;
  border-radius: 3px;
  border: 1px solid var(--color-accent);
  background-color: var(--color-accent);
  color: #050505;
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap;
  transition:
    background-color var(--transition-fast) ease,
    border-color var(--transition-fast) ease,
    transform var(--transition-fast) var(--ease-cinematic);
}

.btn-hero-primary svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  transition: transform var(--transition-fast) var(--ease-cinematic);
}

.btn-hero-primary:hover {
  background-color: #c6ff33;
  border-color: #c6ff33;
  transform: translateY(-1px);
}

.btn-hero-primary:hover svg {
  transform: translateX(4px);
}

.btn-hero-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 12px 22px;
  border-radius: 3px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  background-color: rgba(5, 5, 5, 0.72);
  color: #f4f4f2;
  font-family: var(--font-sans);
  font-size: 0.86rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  white-space: nowrap;
  transition:
    border-color var(--transition-fast) ease,
    color var(--transition-fast) ease,
    background-color var(--transition-fast) ease;
}

.btn-hero-secondary:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
  background-color: rgba(14, 14, 14, 0.9);
}

/* Minimal Scroll Indicator */
.scroll-indicator {
  position: absolute;
  left: 50%;
  bottom: clamp(16px, 3svh, 28px);
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
}

.scroll-indicator-line {
  width: 1.5px;
  height: 32px;
  background: linear-gradient(to bottom, rgba(244, 244, 242, 0.9), rgba(244, 244, 242, 0.14));
  animation: scrollHairline 2s ease-in-out infinite;
}

@keyframes scrollHairline {
  0%, 100% {
    transform: scaleY(0.75);
    opacity: 0.55;
  }
  50% {
    transform: scaleY(1);
    opacity: 1;
  }
}

/* LAYER 5A — Pure Blackout Overlay */
.hero-blackout-overlay {
  position: absolute;
  inset: 0;
  z-index: 62;
  background-color: #000000;
  opacity: 0;
  pointer-events: none;
  will-change: opacity;
}

/* LAYER 5B — Rising Centered Rectangular Panel -> Full-Screen About Preview */
.about-transition-stage {
  position: absolute;
  inset: 0;
  z-index: 64;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  overflow: hidden;
}

.about-transition-card {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  background-color: #000000;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 20px;
  opacity: 0;
  transform-origin: center center;
  will-change: transform, opacity, border-radius;
}

.about-transition-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 15%;
  display: block;
}

.about-transition-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(8, 8, 8, 0.94) 6%,
    rgba(8, 8, 8, 0.56) 46%,
    rgba(8, 8, 8, 0.25) 100%
  );
  opacity: 0;
  will-change: opacity;
}

.about-transition-caption {
  position: absolute;
  left: clamp(24px, 5vw, 64px);
  right: clamp(24px, 5vw, 64px);
  bottom: clamp(44px, 8svh, 88px);
  max-width: 1320px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
  opacity: 0;
  will-change: transform, opacity;
}

.about-transition-caption .section-kicker {
  margin-bottom: 4px;
}

.about-transition-title {
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 4.6vw, 4rem);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.02em;
  color: #f4f4f2;
  text-transform: uppercase;
}

.about-transition-title .accent {
  color: var(--color-accent);
}

@media (prefers-reduced-motion: reduce) {
  .hero-grain,
  .scroll-indicator-line,
  .hero-intro-prompt-line,
  .hero-intro-prompt,
  .hero-blackout-overlay,
  .about-transition-stage {
    animation: none;
    display: none !important;
  }
}
