/* ============================================================
   LRV Sachsen-Anhalt – Instant Splash Screen
   Wird VOR allen anderen Styles geladen.
   body.lrv-loading versteckt alles außer dem Splash.
   ============================================================ */

/* ── Body beim Start verstecken ── */
body.lrv-loading {
  overflow: hidden;
}

body.lrv-loading > *:not(#lrv-splash) {
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* ── Splash Overlay (sofort sichtbar) ── */
#lrv-splash {
  position: fixed;
  inset: 0;
  background: #080b12;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  transition: opacity 0.45s ease;
  will-change: opacity;
}

#lrv-splash.splash-out {
  opacity: 0;
  pointer-events: none;
}

/* ── Logo ── */
.splash-logo-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  margin-bottom: 48px;
  animation: splashFadeUp 0.55s ease both;
}

@keyframes splashFadeUp {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: translateY(0); }
}

.splash-logo-img {
  height: 80px;
  width: auto;
  filter: drop-shadow(0 0 24px rgba(212,32,32,0.5));
  animation: splashPulse 2.4s ease-in-out infinite;
}

@keyframes splashPulse {
  0%,100% { filter: drop-shadow(0 0 24px rgba(212,32,32,0.4)); }
  50%     { filter: drop-shadow(0 0 48px rgba(212,32,32,0.85)); }
}

.splash-title {
  font-family: 'Rajdhani', 'Segoe UI', Arial, sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 3px;
  text-align: center;
  line-height: 1.1;
}

.splash-title span { color: #d42020; }

.splash-subtitle {
  font-size: 10px;
  color: #3a4f72;
  letter-spacing: 4px;
  text-transform: uppercase;
  text-align: center;
  margin-top: -6px;
}

/* ── Fortschritt ── */
.splash-progress-wrap {
  width: 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  animation: splashFadeUp 0.55s 0.12s ease both;
}

.splash-progress-track {
  width: 100%;
  height: 3px;
  background: rgba(255,255,255,0.06);
  border-radius: 2px;
  overflow: hidden;
}

.splash-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #d42020, #ff4444);
  border-radius: 2px;
  width: 0%;
  transition: width 0.4s cubic-bezier(.4,0,.2,1);
  box-shadow: 0 0 8px rgba(212,32,32,0.6);
}

.splash-status {
  font-size: 11px;
  color: #3a4f72;
  letter-spacing: 1.5px;
  text-align: center;
  height: 16px;
  transition: opacity 0.2s;
}

.splash-dots {
  display: flex;
  gap: 6px;
  margin-top: 4px;
}

.splash-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #1e2c46;
  transition: background 0.3s, transform 0.3s;
}

.splash-dot.done   { background: #d42020; transform: scale(1.15); }
.splash-dot.active { background: #ff6060; animation: dotPulse 0.8s ease-in-out infinite; }

@keyframes dotPulse {
  0%,100% { transform: scale(1); opacity: 1; }
  50%     { transform: scale(1.4); opacity: 0.7; }
}

/* ── Footer ── */
.splash-footer {
  position: absolute;
  bottom: 28px;
  font-size: 10px;
  color: #1e2c46;
  letter-spacing: 1px;
}

/* ── Spinner (für aktive Session) ── */
.splash-spinner {
  width: 32px;
  height: 32px;
  border: 2px solid rgba(212,32,32,0.2);
  border-top-color: #d42020;
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
  margin-top: 4px;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ── Bei aktiver Session: Splash sofort verstecken ── */
html.session-active #lrv-splash { display: none !important; }

/* Nur direkte Body-Kinder sichtbar machen (KEINE opacity-Überschreibung!) */
html.session-active body.lrv-loading > *:not(#lrv-splash) {
  visibility: visible !important;
  pointer-events: auto !important;
}

/* Modals explizit unsichtbar halten (ihre eigene opacity:0 darf nicht überschrieben werden) */
html.session-active body.lrv-loading .modal-overlay:not(.open) {
  opacity: 0 !important;
  pointer-events: none !important;
}

html.session-active body.lrv-loading { overflow: auto; }
