/* ============================================================
   Animations — @keyframes, transitions, reveal classes
   ============================================================ */

/* ——— Fade-up ——— */

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fade-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes scale-in {
  from {
    opacity: 0;
    transform: scale(0.85);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ——— Bounce (scroll indicator) ——— */

@keyframes bounce-down {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50%      { transform: translateX(-50%) translateY(8px); }
}

/* ——— Glitch (Hero title) ——— */

@keyframes glitch {
  0% {
    text-shadow: none;
    transform: none;
  }
  20% {
    text-shadow: 4px 0 rgba(255, 69, 0, 0.8), -4px 0 rgba(0, 255, 136, 0.8);
    transform: skewX(1deg);
  }
  40% {
    text-shadow: -4px 0 rgba(255, 69, 0, 0.8), 4px 0 rgba(0, 255, 136, 0.8);
    transform: skewX(-1deg);
  }
  60% {
    text-shadow: 2px 0 rgba(255, 69, 0, 0.6), -2px 0 rgba(0, 255, 136, 0.6);
    transform: skewX(0.5deg);
  }
  80% {
    text-shadow: -2px 0 rgba(255, 69, 0, 0.6), 2px 0 rgba(0, 255, 136, 0.6);
    transform: skewX(-0.5deg);
  }
  100% {
    text-shadow: none;
    transform: none;
  }
}

.hero__title--glitch {
  animation: glitch 0.4s ease;
}

/* ——— Glitch overlay on member cards ——— */

@keyframes glitch-overlay {
  0% {
    opacity: 0;
    transform: translateX(0);
  }
  10% {
    opacity: 1;
    transform: translateX(4px);
  }
  20% {
    transform: translateX(-4px);
  }
  30% {
    transform: translateX(3px);
  }
  40% {
    transform: translateX(-3px);
  }
  50% {
    opacity: 1;
    transform: translateX(1px);
  }
  60% {
    transform: translateX(-1px);
  }
  70% {
    transform: translateX(0);
    opacity: 0.5;
  }
  100% {
    opacity: 0;
    transform: translateX(0);
  }
}

/* ——— Neon pulse ——— */

@keyframes neon-pulse {
  0%, 100% {
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.3),
                0 0 20px rgba(212, 175, 55, 0.1);
  }
  50% {
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.6),
                0 0 40px rgba(212, 175, 55, 0.2),
                0 0 60px rgba(212, 175, 55, 0.1);
  }
}

.btn--pulse {
  animation: neon-pulse 2s ease-in-out infinite;
}

/* ——— Neon pulse red (CTA) ——— */

@keyframes neon-pulse-red {
  0%, 100% {
    box-shadow: 0 0 10px rgba(255, 69, 0, 0.3),
                0 0 20px rgba(255, 69, 0, 0.1);
  }
  50% {
    box-shadow: 0 0 20px rgba(255, 69, 0, 0.6),
                0 0 40px rgba(255, 69, 0, 0.2),
                0 0 60px rgba(255, 69, 0, 0.1);
  }
}

.btn--pulse-red {
  animation: neon-pulse-red 2s ease-in-out infinite;
}

/* ——— Page load sequence ——— */

.hero__content .hero__title {
  animation: fade-up 0.8s ease-out forwards;
}

.hero__content .hero__tagline {
  opacity: 0;
  animation: fade-in 0.8s ease-out 0.3s forwards;
}

.hero__content .btn-group {
  opacity: 0;
  animation: scale-in 0.6s ease-out 0.6s forwards;
}

.header {
  opacity: 0;
  animation: fade-in 0.6s ease-out 0.2s forwards;
}

/* ——— Scroll reveal classes ——— */

.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-right.visible {
  opacity: 1;
  transform: translateX(0);
}

.reveal-scale {
  opacity: 0;
  transform: scale(0.9);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-scale.visible {
  opacity: 1;
  transform: scale(1);
}

/* Stagger animation for member cards */
.member-card.reveal:nth-child(1) { transition-delay: 0.0s; }
.member-card.reveal:nth-child(2) { transition-delay: 0.2s; }
.member-card.reveal:nth-child(3) { transition-delay: 0.4s; }

/* Stagger for social icons */
.social-links a.reveal:nth-child(1) { transition-delay: 0.0s; }
.social-links a.reveal:nth-child(2) { transition-delay: 0.1s; }
.social-links a.reveal:nth-child(3) { transition-delay: 0.2s; }
.social-links a.reveal:nth-child(4) { transition-delay: 0.3s; }
.social-links a.reveal:nth-child(5) { transition-delay: 0.4s; }
.social-links a.reveal:nth-child(6) { transition-delay: 0.5s; }

/* ——— Split reveal for CTA ——— */

@keyframes split-reveal {
  from {
    clip-path: inset(0 100% 0 0);
    opacity: 0;
  }
  to {
    clip-path: inset(0 0 0 0);
    opacity: 1;
  }
}

.cta__title.reveal.visible {
  animation: split-reveal 0.8s ease-out;
  clip-path: inset(0 0 0 0);
}

.cta__title.reveal {
  clip-path: inset(0 100% 0 0);
  opacity: 1;
  transform: none;
  transition: clip-path 0.8s ease;
}

/* ——— Smooth transition for all interactive elements ——— */

a, button, .member-card, .social-links a {
  transition: all 0.3s ease;
}

/* ——— Disable animations on prefers-reduced-motion ——— */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
