/* ==========================================================================
   GEMALA ANGKINAN - Animations & Transitions
   “Gema Budaya, Karya Masa Kini”
   ========================================================================== */

/* Gold Shimmer Text Animation */
@keyframes goldShimmer {
  0% {
    background-position: -200% center;
  }
  100% {
    background-position: 200% center;
  }
}

.gold-shimmer-text {
  background: linear-gradient(
    90deg,
    #B38024 0%,
    #ECC870 25%,
    #FFF4B8 50%,
    #ECC870 75%,
    #B38024 100%
  );
  background-size: 200% auto;
  color: transparent;
  -webkit-background-clip: text;
  background-clip: text;
  animation: goldShimmer 8s linear infinite;
}

/* Float subtle animation for badges */
@keyframes softFloat {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-6px);
  }
}

.animate-float {
  animation: softFloat 4s ease-in-out infinite;
}

/* Subtle Golden Pulse for Accents */
@keyframes goldPulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(197, 155, 39, 0.4);
  }
  50% {
    box-shadow: 0 0 0 10px rgba(197, 155, 39, 0);
  }
}

.gold-pulse {
  animation: goldPulse 3s infinite;
}

/* Scroll Reveal Classes (Driven by IntersectionObserver in JS) */
.reveal-fade-up {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.reveal-fade-left {
  opacity: 0;
  transform: translateX(-32px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.reveal-fade-right {
  opacity: 0;
  transform: translateX(32px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.reveal-zoom {
  opacity: 0;
  transform: scale(0.94);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.is-revealed {
  opacity: 1 !important;
  transform: translate(0, 0) scale(1) !important;
}

/* Stagger Delays for child cards */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }
.delay-5 { transition-delay: 0.5s; }

/* Lightbox Dialog Transitions */
dialog#lightboxDialog {
  opacity: 0;
  transform: scale(0.92);
  transition: opacity 0.35s ease, transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), overlay 0.35s allow-discrete, display 0.35s allow-discrete;
}

dialog#lightboxDialog[open] {
  opacity: 1;
  transform: scale(1);
}

@starting-style {
  dialog#lightboxDialog[open] {
    opacity: 0;
    transform: scale(0.92);
  }
}

dialog#lightboxDialog::backdrop {
  background: rgba(26, 12, 6, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  transition: opacity 0.35s ease;
}

dialog#lightboxDialog[open]::backdrop {
  opacity: 1;
}

@starting-style {
  dialog#lightboxDialog[open]::backdrop {
    opacity: 0;
  }
}

/* Rotating Palembang Emblem Background */
@keyframes spinSlow {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

.spin-slow {
  animation: spinSlow 90s linear infinite;
}

/* Smooth Arrow Bounce */
@keyframes arrowBounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(8px);
  }
  60% {
    transform: translateY(4px);
  }
}

.bounce-arrow {
  animation: arrowBounce 2.5s infinite;
}
