/* ── Emma Video Intro Layer ──────────────────────────────── */

/* Scroll lock — applied to body while video is active */
body.intro-active {
  overflow: hidden;
}

/* ── Full-viewport fixed layer ── */
#video-intro {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: #151719;
  overflow: hidden;
  /* will be transitioned out on scroll */
  will-change: transform, opacity;
}

/* The video itself — cover entire viewport */
#intro-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  /* subtle de-saturate on load — full colour once playing */
  filter: brightness(0.9) contrast(1.04);
}

/* Dark vignette edges — frames the video like a cinema */
#video-intro::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 88% 70% at 50% 50%, transparent 40%, rgba(21, 23, 25,0.72) 100%);
  z-index: 2;
  pointer-events: none;
}

/* Brand stamp bottom-left */
.intro-brand {
  position: absolute;
  bottom: 48px;
  left: 52px;
  z-index: 4;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.intro-brand-logo {
  height: 28px;
  filter: brightness(0) invert(1);
  opacity: 0.85;
}

.intro-brand-tag {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: rgba(244,244,244,0.4);
}

/* Scroll cue — centered bottom */
.intro-scroll-cue {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  pointer-events: none;
  user-select: none;
  animation: introCuePulse 2.2s ease-in-out infinite;
}

.intro-scroll-cue-text {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: rgba(244,244,244,0.55);
}

.intro-scroll-cue-chevron {
  display: flex;
  flex-direction: column;
  gap: 3px;
  align-items: center;
}

.intro-scroll-cue-chevron span {
  display: block;
  width: 12px;
  height: 1px;
  background: rgba(232, 5, 5,0.9);
  transform-origin: center;
}

.intro-scroll-cue-chevron span:first-child {
  transform: rotate(45deg) translateX(3px);
}

.intro-scroll-cue-chevron span:last-child {
  transform: rotate(-45deg) translateX(-3px);
}

/* Red accent line top */
.intro-top-line {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(to right, transparent, var(--emma-red) 40%, var(--emma-gold) 60%, transparent);
  z-index: 4;
  transform-origin: left;
  transform: scaleX(0);
  animation: introLineIn 1.2s 0.4s cubic-bezier(0.22,1,0.36,1) forwards;
}

/* Skip button — top right */
.intro-skip {
  position: absolute;
  top: 28px;
  right: 52px;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(244,244,244,0.4);
  cursor: pointer;
  border: none;
  background: none;
  padding: 8px 0;
  transition: color 0.2s;
  opacity: 0;
  animation: introFadeEl 0.6s 1.4s ease forwards;
}

.intro-skip:hover { color: rgba(244,244,244,0.85); }

.intro-skip svg { opacity: 0.5; transition: opacity 0.2s; }
.intro-skip:hover svg { opacity: 1; }

/* ── Keyframes ── */
@keyframes introCuePulse {
  0%, 100% { opacity: 0.4; transform: translateX(-50%) translateY(0); }
  50%       { opacity: 1;   transform: translateX(-50%) translateY(5px); }
}

@keyframes introLineIn {
  to { transform: scaleX(1); }
}

@keyframes introFadeEl {
  to { opacity: 1; }
}

/* ── Exit animation — added via JS ── */
#video-intro.intro-exit {
  pointer-events: none;
}

/* Reduced motion: skip straight to hero */
@media (prefers-reduced-motion: reduce) {
  #video-intro {
    display: none !important;
  }
  body.intro-active {
    overflow: auto !important;
  }
}

/* Mobile adjustments */
@media (max-width: 768px) {
  .intro-brand { left: 24px; bottom: 80px; }
  .intro-skip  { right: 24px; }
}
