/* ============================================
   FESTA CORTESE — INTRO SPLASH (v2)
   30 metų jubiliejus · 2026.10.18
   Šv. Kotrynos bažnyčia, Vilnius
   ============================================ */

.intro-splash {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0e1513;
  cursor: pointer;
  overflow: hidden;
  transition: opacity 700ms ease;
}

.intro-splash.is-leaving {
  opacity: 0;
  pointer-events: none;
}

/* Lock body scroll while splash is up */
body.intro-locked {
  overflow: hidden;
}

/* === BLURRED BACKDROP LAYER ===
   Same affiche image, blurred and zoomed, fills the entire viewport.
   Creates depth and a true fullscreen feel without cropping the real image. */
.intro-splash__backdrop {
  position: absolute;
  inset: -5%;
  width: 110%;
  height: 110%;
  background-image: url("../images/splash-desktop.webp");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: blur(40px) brightness(0.45) saturate(1.1);
  opacity: 0;
  transform: scale(1.1);
  transition: opacity 1200ms ease, transform 6000ms ease-out;
}

.intro-splash.is-ready .intro-splash__backdrop {
  opacity: 1;
  transform: scale(1);
}

/* === SHARP FOREGROUND IMAGE === */
.intro-splash__image {
  position: relative;
  max-width: 100vw;
  max-height: 100vh;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  transform: scale(1.04);
  opacity: 0;
  transition: transform 6000ms ease-out, opacity 900ms ease 200ms;
  filter: drop-shadow(0 30px 80px rgba(0, 0, 0, 0.7));
  user-select: none;
  -webkit-user-drag: none;
  z-index: 1;
}

.intro-splash.is-ready .intro-splash__image {
  transform: scale(1);
  opacity: 1;
}

.intro-splash.is-leaving .intro-splash__image {
  transition: transform 700ms ease-in, opacity 700ms ease;
  transform: scale(1.02);
  opacity: 0;
}

/* === HINT TEXT === */
.intro-splash__hint {
  position: absolute;
  bottom: 5vh;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.6);
  font-family: "Inter", "Helvetica Neue", Arial, sans-serif;
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 300;
  opacity: 0;
  transition: opacity 800ms ease 1500ms;
  pointer-events: none;
  white-space: nowrap;
  z-index: 2;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.6);
}

.intro-splash.is-ready .intro-splash__hint {
  opacity: 1;
}

.intro-splash.is-leaving .intro-splash__hint {
  opacity: 0;
  transition: opacity 300ms ease;
}

/* === MOBILE === */
@media (max-width: 768px) {
  .intro-splash__backdrop {
    background-image: url("../images/splash-mobile.webp");
    filter: blur(30px) brightness(0.5) saturate(1.1);
  }

  .intro-splash__image {
    max-width: 100vw;
    max-height: 100vh;
    filter: drop-shadow(0 15px 40px rgba(0, 0, 0, 0.6));
  }

  .intro-splash__hint {
    bottom: 3.5vh;
    font-size: 0.7rem;
    letter-spacing: 0.16em;
    padding: 0 1rem;
    text-align: center;
    white-space: normal;
  }
}

@media (max-width: 380px) {
  .intro-splash__hint {
    font-size: 0.65rem;
    letter-spacing: 0.14em;
  }
}

/* Landscape phones */
@media (max-height: 500px) and (orientation: landscape) {
  .intro-splash__hint {
    bottom: 2.5vh;
    font-size: 0.68rem;
  }
}

/* Reduced motion — calm everything down */
@media (prefers-reduced-motion: reduce) {
  .intro-splash,
  .intro-splash__image,
  .intro-splash__backdrop,
  .intro-splash__hint {
    transition-duration: 200ms !important;
  }

  .intro-splash__image {
    transform: scale(1) !important;
  }

  .intro-splash__backdrop {
    transform: scale(1) !important;
  }
}

/* Print */
@media print {
  .intro-splash {
    display: none !important;
  }
}
