/* ============================================================
   Page Loader Styles
   ============================================================ */

#page-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #0b0d1a;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
}

.loader-logo-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.loader-ring {
  position: absolute;
  inset: -14px;
  border-radius: 50%;
  border: 2px solid transparent;
  border-top-color: var(--accent);
  border-right-color: rgba(255,193,7,.25);
  animation: ringSpinFast .9s linear infinite;
}

.loader-ring-2 {
  position: absolute;
  inset: -22px;
  border-radius: 50%;
  border: 1.5px solid transparent;
  border-bottom-color: rgba(255,193,7,.35);
  border-left-color: rgba(255,152,0,.20);
  animation: ringSpinFast 1.6s linear infinite reverse;
}

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

.loader-logo {
  width: 64px;
  height: 64px;
  border-radius: 20px;
  object-fit: cover;
  border: 1px solid rgba(255,193,7,.25);
  animation: logoBreath 2s ease-in-out infinite;
  position: relative;
  z-index: 1;
}

@keyframes logoBreath {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(255,193,7,.0);
  }
  50% {
    transform: scale(1.04);
    box-shadow: 0 0 28px 8px rgba(255,193,7,.18);
  }
}

.loader-wordmark {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 18px;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: rgba(255,255,255,.92);
  margin-top: 28px;
  opacity: 0;
  transform: translateY(8px);
  animation: wordmarkIn .6s .35s var(--ease-out) forwards;
}

@keyframes wordmarkIn {
  to {
    opacity: 1;
    transform: none;
  }
}

.loader-sub {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 10px;
  letter-spacing: .38em;
  text-transform: uppercase;
  color: rgba(255,193,7,.75);
  margin-top: 6px;
  opacity: 0;
  transform: translateY(6px);
  animation: wordmarkIn .5s .55s var(--ease-out) forwards;
}

.loader-progress-wrap {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
}

.loader-progress-track {
  height: 2px;
  background: rgba(255,255,255,.08);
  border-radius: 2px;
  overflow: hidden;
}

.loader-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 2px;
  animation: progressFill 1.1s .2s var(--ease-out) forwards;
}

@keyframes progressFill {
  to {
    width: 100%;
  }
}

#page-loader.exit {
  animation: loaderExit .65s var(--ease-out) forwards;
}

@keyframes loaderExit {
  0% {
    opacity: 1;
    transform: none;
  }
  100% {
    opacity: 0;
    transform: translateY(-12px);
    pointer-events: none;
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  #page-loader {
    display: none !important;
  }
}