/* Ultra-Clear Liquid Glass */
.liquid-glass {
  background: rgba(255, 255, 255, 0.42);
  backdrop-filter: blur(28px) saturate(210%) contrast(104%);
  -webkit-backdrop-filter: blur(28px) saturate(210%) contrast(104%);
  border-color: rgba(255, 255, 255, 0.72);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.95),
    inset 0 -1px 0 rgba(79, 90, 232, 0.08),
    0 8px 32px rgba(30, 36, 92, 0.08);
}

.liquid-glass-drawer {
  background: rgba(255, 255, 255, 0.56);
  backdrop-filter: blur(32px) saturate(210%);
  -webkit-backdrop-filter: blur(32px) saturate(210%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 16px 40px rgba(30, 36, 92, 0.14);
}

.liquid-glass-card {
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(20px) saturate(185%);
  -webkit-backdrop-filter: blur(20px) saturate(185%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 6px 24px rgba(30, 36, 92, 0.05);
  transition: transform 260ms cubic-bezier(0.22, 1, 0.36, 1), box-shadow 260ms ease, border-color 200ms ease;
}

.liquid-glass-card:hover {
  transform: translateY(-3px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 1),
    0 14px 34px rgba(79, 90, 232, 0.12);
}

/* Mobile Hamburger */
.hamburger-line {
  transition: transform 220ms cubic-bezier(0.2, 0, 0, 1), opacity 150ms ease-out;
  transform-origin: center;
}
.is-open .line-1 { transform: translateY(6px) rotate(45deg); }
.is-open .line-2 { opacity: 0; }
.is-open .line-3 { transform: translateY(-6px) rotate(-45deg); }

/* Scroll-Based Reveal Animations */
[data-reveal] {
  opacity: 0;
  transform: translate3d(0, 30px, 0);
  transition:
    opacity 900ms cubic-bezier(0.22, 1, 0.36, 1),
    transform 900ms cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

[data-reveal="left"] {
  transform: translate3d(-28px, 0, 0);
}

[data-reveal="right"] {
  transform: translate3d(28px, 0, 0);
}

[data-reveal="scale"] {
  transform: scale(0.95);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

@media (prefers-reduced-motion: reduce) {
  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* Musical Elevator Preloader (Blue & White) */
html.pk-preload-active body {
  overflow: hidden;
}

#pk-preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  background: #ffffff;
  pointer-events: all;
  transition: opacity 750ms ease-out;
}

html.pk-preload-active #pk-preloader {
  display: block;
}

.pk-elevator-door {
  display: none;
}

#pk-preloader.is-opening {
  opacity: 0;
  pointer-events: none;
}

.pk-preloader-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  text-align: center;
  transition: opacity 550ms ease-out, transform 550ms ease-out;
}

#pk-preloader.is-fading .pk-preloader-content {
  opacity: 0;
  transform: translateY(-10px) scale(0.98);
}

.pk-logo-ring {
  padding: 14px 20px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(79, 90, 232, 0.22);
  box-shadow: 0 12px 36px rgba(79, 90, 232, 0.1);
}

.pk-progress-track {
  width: min(320px, 82vw);
  height: 6px;
  border-radius: 999px;
  background: #E2E1F4;
  overflow: hidden;
  position: relative;
}

.pk-progress-fill {
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, #4F5AE8 0%, #1E245C 100%);
  transition: width 160ms ease-out;
}

.pk-notes-stage {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 3;
}

.pk-musical-note {
  position: absolute;
  opacity: 0;
  animation: pkNoteFlyUp 1600ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes pkNoteFlyUp {
  0% {
    opacity: 0;
    transform: translate3d(0, 30px, 0) scale(0.5) rotate(-14deg);
  }
  25% {
    opacity: 0.92;
  }
  100% {
    opacity: 0;
    transform: translate3d(var(--sway, 30px), -220px, 0) scale(1.45) rotate(14deg);
  }
}
