/* ===========================
   LOADER.CSS — Olarys Editions
   =========================== */

#loader {
  position: fixed;
  inset: 0;
  background: #17110D;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: opacity 0.8s ease, visibility 0.8s ease;
}

#loader.hide {
  opacity: 0;
  visibility: hidden;
}

/* Arc ornemental */
.loader-arc {
  position: absolute;
  width: 300px;
  height: 300px;
  border: 1px solid rgba(255,204,0,0.12);
  border-radius: 50%;
  animation: arcPulse 3s ease infinite;
}

.loader-arc:nth-child(2) {
  width: 200px;
  height: 200px;
  border-color: rgba(255,163,0,0.12);
  animation-delay: 0.5s;
}

@keyframes arcPulse {
  0%, 100% { transform: scale(1); opacity: 0.4; }
  50%       { transform: scale(1.05); opacity: 0.8; }
}

/* Logo */
.loader-logo {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: clamp(5rem, 16vw, 11rem);
  font-weight: 900;
  color: transparent;
  -webkit-text-stroke: 1px #FFCC00;
  letter-spacing: 8px;
  text-transform: uppercase;
  animation: fillLogo 1.2s ease forwards 0.4s;
  position: relative;
  z-index: 1;
}

@keyframes fillLogo {
  0%   { color: transparent;  -webkit-text-stroke: 1px #FFCC00; }
  100% { color: #FFCC00;      -webkit-text-stroke: 1px #FFCC00; }
}

/* Liseré */
.loader-divider {
  width: 80px;
  height: 1px;
  background: linear-gradient(90deg, transparent, #FFA300, transparent);
  margin: 16px 0;
  position: relative;
  z-index: 1;
}

/* Barre */
.loader-bar-wrap {
  width: 180px;
  height: 1px;
  background: #211913;
  border-radius: 0;
  margin-top: 8px;
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.loader-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #FFA300, #FFCC00);
  animation: loadBar 1.8s cubic-bezier(.4,0,.2,1) forwards 0.3s;
}

@keyframes loadBar {
  0%   { width: 0%;   }
  60%  { width: 75%;  }
  100% { width: 100%; }
}

/* Tag */
.loader-tag {
  margin-top: 20px;
  font-family: 'Barlow', sans-serif;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 6px;
  text-transform: uppercase;
  color: #888888;
  animation: fadeInTag 0.8s ease forwards 0.6s;
  opacity: 0;
  position: relative;
  z-index: 1;
}

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

/* Lignes déco coin */
.loader-lines {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.loader-lines::before,
.loader-lines::after {
  content: '';
  position: absolute;
  background: #FFCC00;
  opacity: 0.04;
}

.loader-lines::before {
  width: 1px; height: 100%; left: 50%;
  animation: lineSlide 2s ease forwards;
}

.loader-lines::after {
  width: 100%; height: 1px; top: 50%;
  animation: lineSlideH 2s ease forwards 0.2s;
}

@keyframes lineSlide  { from { transform: scaleY(0); } to { transform: scaleY(1); } }
@keyframes lineSlideH { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* ===========================
   LOADER — MODE VIDÉO
   =========================== */

#loader video#loader-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;       /* plein écran, ratio conservé */
  z-index: 1;
}

#loader-skip {
  position: absolute;
  bottom: 36px;
  right: 40px;
  z-index: 2;
  background: transparent;
  color: rgba(255,204,0,0.7);
  border: 1px solid rgba(255,204,0,0.3);
  font-family: 'Barlow', sans-serif;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 4px;
  text-transform: uppercase;
  padding: 9px 20px;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, opacity 0.4s ease;
}

#loader-skip:hover {
  color: #FFCC00;
  border-color: #FFCC00;
}
