/* Splash screen critical CSS — loaded synchronously via <link> to prevent FOUC.
   Moved from index.html inline <style> — Vite 6.4 Lightning CSS cannot parse
   inline styles with CSS Fonts Level 5 descriptors or complex @keyframes. */

#splash-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, #faf6f0 0%, #f5ede0 50%, #ede0cc 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  z-index: 9999;
  transition: opacity 0.4s ease-out, transform 0.4s ease-out;
}

#splash-screen.splash-exit {
  opacity: 0;
  transform: scale(1.05);
}

#splash-logo {
  width: 200px;
  height: auto;
  max-width: 80vw;
  animation: splash-bread-rise 2s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

#splash-logo-fallback {
  display: none;
  align-items: center;
  justify-content: center;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: clamp(3rem, 10vw, 4.75rem);
  font-weight: 700;
  letter-spacing: 0.14em;
  line-height: 1;
  color: #371810;
  animation: splash-bread-rise 2s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

#splash-brand {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 0.85rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #8b6f47;
  opacity: 0;
  animation: splash-fade-in 0.8s ease-out 0.5s both;
}

#splash-progress {
  width: 200px;
  max-width: 80vw;
  height: 3px;
  background-color: rgba(185, 141, 82, 0.2);
  border-radius: 2px;
  overflow: hidden;
}

#splash-progress-bar {
  width: 10%;
  height: 100%;
  background: linear-gradient(90deg, #b98d52, #D4552A);
  border-radius: 2px;
  transition: width 0.4s ease-out;
}

@keyframes splash-bread-rise {
  0%   { transform: scaleY(0.7) translateY(12px); opacity: 0; transform-origin: bottom; }
  100% { transform: scaleY(1.0) translateY(0); opacity: 1; transform-origin: bottom; }
}

@keyframes splash-fade-in {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  #splash-logo, #splash-logo-fallback, #splash-brand {
    animation: none;
    opacity: 1;
    transform: none;
  }
}
