/* =========================================================
   PRELOADER — full-screen logo video
========================================================= */
html.preloader-active,
body.preloader-active {
  overflow: hidden !important;
  height: 100%;
}

#preloader {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  opacity: 1;
  visibility: visible;
  transition:
    opacity 0.9s cubic-bezier(0.22, 1, 0.36, 1),
    visibility 0.9s;
}

#preloader.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preloader-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  background: #000;
}

@media (min-width: 768px) {
  .preloader-video {
    object-fit: contain;
    max-width: min(92vw, 960px);
    max-height: 92vh;
    margin: auto;
    border-radius: 12px;
    box-shadow: 0 0 120px rgba(124, 58, 237, 0.25);
  }
}

.preloader-vignette {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse 70% 60% at 50% 50%, transparent 30%, rgba(0, 0, 0, 0.65) 100%);
}

.preloader-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.5s;
  z-index: 2;
}

.preloader-fallback.visible {
  opacity: 1;
  visibility: visible;
}

.preloader-fallback img {
  width: min(220px, 55vw);
  filter: drop-shadow(0 0 50px rgba(168, 85, 247, 0.45));
  animation: preloaderLogoIn 1s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.preloader-fallback-text {
  font-size: 0.65rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.35);
  font-family: var(--font-mono, monospace);
}

#preloader.needs-tap::after {
  content: "Tap to start";
  position: absolute;
  bottom: 12%;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  z-index: 3;
  animation: preloaderPulse 2s ease-in-out infinite;
}

@keyframes preloaderLogoIn {
  from {
    opacity: 0;
    transform: scale(0.85);
    filter: blur(8px);
  }
  to {
    opacity: 1;
    transform: scale(1);
    filter: blur(0);
  }
}

@keyframes preloaderPulse {
  0%,
  100% {
    opacity: 0.4;
  }
  50% {
    opacity: 1;
  }
}

/* =========================================================
   NAV — top fixed, bigger logo
========================================================= */
nav#navbar {
  top: 0 !important;
}

body.has-announce nav#navbar {
  top: 42px !important;
}

.nav-brand img {
  height: 52px !important;
  max-height: 52px !important;
}

@media (min-width: 768px) {
  .nav-brand img {
    height: 58px !important;
    max-height: 58px !important;
  }
}

.hero-logo {
  max-width: min(92vw, 520px) !important;
}

.hero-logo-wrap {
  margin-bottom: 24px;
}

/* =========================================================
   FOOTER — clean
========================================================= */
footer.site-footer {
  padding: 48px 5vw 40px;
  background: #000;
  border-top: none;
}

.footer-inner {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

.footer-brand-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.footer-logo-sm {
  width: 64px;
  height: auto;
  object-fit: contain;
  opacity: 0.9;
}

.footer-tagline {
  font-family: var(--font-display, "Unbounded", sans-serif);
  font-size: clamp(1.5rem, 5vw, 2.25rem);
  letter-spacing: 0.06em;
  background: linear-gradient(135deg, #fff, #c084fc);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.footer-school-name {
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.35);
  margin-top: 8px;
}

.footer-social-row {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-top: 32px;
}

.footer-social-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.03);
  color: #e2e8f0;
  text-decoration: none;
  transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.footer-social-btn svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.footer-social-btn:hover {
  border-color: rgba(168, 85, 247, 0.5);
  background: rgba(124, 58, 237, 0.2);
  color: #c084fc;
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(124, 58, 237, 0.25);
}

.footer-legal {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.3);
  letter-spacing: 0.05em;
}

/* Scroll reveal boost */
.reveal {
  transition:
    opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
