/* =============================================
   AC MUSIC GLOBAL - ANIMATIONS
   ============================================= */

/* ============ KEYFRAMES ============ */
@keyframes pulse-dot {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: 0.6; }
}

@keyframes float-glow {
  0%, 100% { transform: translateY(0) scale(1); opacity: 0.6; }
  50% { transform: translateY(-20px) scale(1.1); opacity: 1; }
}

@keyframes scroll-line {
  0%, 100% { opacity: 0; transform: scaleY(0); transform-origin: top; }
  20% { opacity: 1; transform: scaleY(1); transform-origin: top; }
  80% { opacity: 1; transform: scaleY(1); transform-origin: bottom; }
  100% { opacity: 0; transform: scaleY(0); transform-origin: bottom; }
}

@keyframes glitch {
  0%, 100% { clip-path: inset(0 0 0 0); transform: translate(0); }
  5% { clip-path: inset(20% 0 60% 0); transform: translate(-3px, 2px); }
  10% { clip-path: inset(60% 0 20% 0); transform: translate(3px, -2px); }
  15% { clip-path: inset(40% 0 40% 0); transform: translate(-2px, 1px); }
  20% { clip-path: inset(0 0 0 0); transform: translate(0); }
}

@keyframes glitch-2 {
  0%, 100% { clip-path: inset(0 0 0 0); transform: translate(0); color: transparent; -webkit-text-stroke: 2px var(--accent-orange); }
  5% { clip-path: inset(30% 0 50% 0); transform: translate(3px, -2px); color: var(--accent-cyan); -webkit-text-stroke: 0; }
  10% { clip-path: inset(50% 0 30% 0); transform: translate(-3px, 2px); color: transparent; -webkit-text-stroke: 2px var(--accent-orange); }
  15% { clip-path: inset(0 0 0 0); transform: translate(0); }
}

@keyframes wave {
  0%, 100% { transform: scaleY(0.4); }
  50% { transform: scaleY(1); }
}

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

@keyframes neon-flicker {
  0%, 19%, 21%, 23%, 25%, 54%, 56%, 100% {
    text-shadow:
      0 0 4px #fff,
      0 0 11px #fff,
      0 0 19px #fff,
      0 0 40px var(--accent-orange),
      0 0 80px var(--accent-orange),
      0 0 90px var(--accent-orange);
    opacity: 1;
  }
  20%, 24%, 55% {
    text-shadow: none;
    opacity: 0.85;
  }
}

@keyframes slide-up {
  from { opacity: 0; transform: translateY(60px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes slide-in-left {
  from { opacity: 0; transform: translateX(-60px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes slide-in-right {
  from { opacity: 0; transform: translateX(60px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes scale-in {
  from { opacity: 0; transform: scale(0.8); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes particle-float {
  0% { transform: translateY(100vh) scale(0); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateY(-100px) scale(1); opacity: 0; }
}

@keyframes gradient-shift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

@keyframes shine {
  from { left: -100%; }
  to { left: 200%; }
}

@keyframes bounce-in {
  0% { transform: scale(0.3); opacity: 0; }
  50% { transform: scale(1.05); opacity: 1; }
  70% { transform: scale(0.9); }
  100% { transform: scale(1); }
}

@keyframes countdown {
  from { stroke-dashoffset: 0; }
  to { stroke-dashoffset: 283; }
}

@keyframes typing {
  from { width: 0; }
  to { width: 100%; }
}

@keyframes blink {
  50% { border-color: transparent; }
}

/* ============ HERO ANIMATIONS ============ */
.hero-text {
  animation: slide-in-left 1s ease 0.2s both;
}

.hero-visual {
  animation: slide-in-right 1s ease 0.4s both;
}

.hero-title .line-1 { animation: slide-up 0.8s ease 0.3s both; }
.hero-title .line-2 { animation: slide-up 0.8s ease 0.5s both; }
.hero-title .line-3 { animation: slide-up 0.8s ease 0.7s both; }

.hero-subtitle { animation: slide-up 0.8s ease 0.9s both; }
.hero-desc { animation: slide-up 0.8s ease 1.1s both; }
.hero-cta { animation: slide-up 0.8s ease 1.3s both; }
.hero-socials { animation: slide-up 0.8s ease 1.5s both; }

/* Glitch effect on hero title */
.glitch {
  position: relative;
}

.glitch::before,
.glitch::after {
  content: attr(data-text);
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
}

.glitch::before {
  color: var(--accent-cyan);
  animation: glitch 8s infinite;
  animation-delay: 1s;
  opacity: 0.7;
}

.glitch::after {
  color: var(--accent-red);
  animation: glitch 8s infinite reverse;
  animation-delay: 2s;
  opacity: 0.7;
}

/* ============ AUDIO WAVE ANIMATION ============ */
.audio-wave {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 30px;
}

.audio-wave .bar {
  width: 3px;
  background: linear-gradient(to top, var(--accent-orange), var(--accent-red));
  border-radius: 2px;
  animation: wave 1.2s ease-in-out infinite;
}

.audio-wave .bar:nth-child(1) { height: 40%; animation-delay: 0s; }
.audio-wave .bar:nth-child(2) { height: 70%; animation-delay: 0.1s; }
.audio-wave .bar:nth-child(3) { height: 100%; animation-delay: 0.2s; }
.audio-wave .bar:nth-child(4) { height: 60%; animation-delay: 0.3s; }
.audio-wave .bar:nth-child(5) { height: 80%; animation-delay: 0.4s; }
.audio-wave .bar:nth-child(6) { height: 45%; animation-delay: 0.5s; }
.audio-wave .bar:nth-child(7) { height: 90%; animation-delay: 0.15s; }
.audio-wave .bar:nth-child(8) { height: 55%; animation-delay: 0.25s; }

/* ============ LOADING SCREEN ============ */
.loading-screen {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-screen.hidden {
  opacity: 0;
  visibility: hidden;
}

.loading-logo {
  font-family: var(--font-display);
  font-size: 3.5rem;
  letter-spacing: 8px;
  text-transform: uppercase;
  animation: neon-flicker 3s infinite;
}

.loading-logo span { color: var(--accent-orange); }

.loading-bar {
  width: 200px;
  height: 2px;
  background: rgba(255,255,255,0.1);
  border-radius: 2px;
  overflow: hidden;
}

.loading-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-orange), var(--accent-red));
  border-radius: 2px;
  animation: loading-progress 2s ease-in-out forwards;
}

@keyframes loading-progress {
  from { width: 0%; }
  to { width: 100%; }
}

.loading-percent {
  font-family: var(--font-display);
  font-size: 1.2rem;
  letter-spacing: 4px;
  color: var(--accent-orange);
}

/* ============ NAV MOBILE MENU ============ */
.mobile-menu {
  position: fixed;
  inset: 0;
  background: rgba(5, 5, 8, 0.98);
  backdrop-filter: blur(30px);
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 90px 24px 50px;
  gap: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s ease;
  overflow-y: auto;
}

.mobile-menu.open {
  opacity: 1;
  visibility: visible;
}

.mobile-menu-close {
  position: absolute;
  top: 24px; right: 24px;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.5rem;
  cursor: pointer;
  width: 44px; height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid var(--border-glass);
}

.mobile-menu a {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 5vw, 2.2rem);
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--text-secondary);
  text-decoration: none;
  transition: var(--transition);
  animation: slide-up 0.5s ease both;
}

.mobile-menu a:hover { color: var(--accent-orange); }

/* ============ TOAST NOTIFICATIONS ============ */
.toast-container {
  position: fixed;
  top: 24px; right: 24px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.toast {
  background: var(--bg-secondary);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 280px;
  max-width: 360px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.5);
  animation: slide-in-right 0.4s ease;
  backdrop-filter: blur(20px);
}

.toast.success { border-color: rgba(0, 212, 100, 0.3); }
.toast.error { border-color: rgba(255, 50, 50, 0.3); }
.toast.info { border-color: var(--border-accent); }

.toast-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
}

.toast.success .toast-icon { color: #00d464; }
.toast.error .toast-icon { color: #ff3232; }
.toast.info .toast-icon { color: var(--accent-orange); }

.toast-text {
  font-size: 0.88rem;
  color: var(--text-primary);
  line-height: 1.4;
}

/* ============ HOVER EFFECTS ============ */
.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}

.hover-glow:hover {
  box-shadow: 0 0 30px rgba(255, 107, 53, 0.4);
}

/* ============ GRADIENT TEXT ANIMATION ============ */
.gradient-text-animated {
  background: linear-gradient(270deg, var(--accent-orange), var(--accent-red), var(--accent-purple), var(--accent-cyan));
  background-size: 400% 400%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradient-shift 4s ease infinite;
}

/* ============ SPINNER ============ */
.spinner {
  width: 40px; height: 40px;
  border: 3px solid var(--border-glass);
  border-top-color: var(--accent-orange);
  border-radius: 50%;
  animation: rotate 0.8s linear infinite;
}

/* ============ SCROLL REVEAL — FIX SECCIONES ============ */
/* IMPORTANTE: Sin estos estilos las secciones con class="reveal" quedan ocultas */
.reveal,
.reveal-left,
.reveal-right {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-left {
  transform: translateX(-50px);
}

.reveal-right {
  transform: translateX(50px);
}

.reveal.visible,
.reveal-left.visible,
.reveal-right.visible {
  opacity: 1;
  transform: translateY(0) translateX(0);
}

/* Delays para animaciones escalonadas */
.reveal.delay-1, .reveal-left.delay-1, .reveal-right.delay-1 { transition-delay: 0.1s; }
.reveal.delay-2, .reveal-left.delay-2, .reveal-right.delay-2 { transition-delay: 0.2s; }
.reveal.delay-3, .reveal-left.delay-3, .reveal-right.delay-3 { transition-delay: 0.3s; }
.reveal.delay-4, .reveal-left.delay-4, .reveal-right.delay-4 { transition-delay: 0.4s; }
.reveal.delay-5, .reveal-left.delay-5, .reveal-right.delay-5 { transition-delay: 0.5s; }

