/* animations.css - Keyframes, transitions, scroll animations */

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 6px 20px rgba(230, 57, 70, 0.35);
  }
  50% {
    transform: scale(1.04);
    box-shadow: 0 10px 32px rgba(230, 57, 70, 0.5);
  }
}

@keyframes float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes slideInDown {
  from {
    transform: translateY(-100%);
  }
  to {
    transform: translateY(0);
  }
}

.btn-primary--pulse {
  animation: pulse 2.4s ease-in-out infinite;
}

.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

.animate-on-scroll.from-left {
  transform: translateX(-30px);
}

.animate-on-scroll.from-left.visible {
  transform: translateX(0);
}

.animate-on-scroll.from-right {
  transform: translateX(30px);
}

.animate-on-scroll.from-right.visible {
  transform: translateX(0);
}

.animate-on-scroll.scale {
  transform: scale(0.92);
}

.animate-on-scroll.scale.visible {
  transform: scale(1);
}

.stagger-1 { transition-delay: 0.05s; }
.stagger-2 { transition-delay: 0.12s; }
.stagger-3 { transition-delay: 0.19s; }
.stagger-4 { transition-delay: 0.26s; }
.stagger-5 { transition-delay: 0.33s; }
.stagger-6 { transition-delay: 0.4s; }

/* Hero intro animations */
.hero__title {
  animation: fadeInUp 0.9s ease forwards;
}

.hero__subtitle {
  animation: fadeInUp 0.9s ease 0.18s forwards;
  opacity: 0;
}

.hero__features {
  animation: fadeInUp 0.9s ease 0.36s forwards;
  opacity: 0;
}

.hero__cta {
  animation: fadeInUp 0.9s ease 0.54s forwards;
  opacity: 0;
  animation-fill-mode: forwards;
}

.hero__cta.btn-primary--pulse {
  animation: fadeInUp 0.9s ease 0.54s forwards, pulse 2.4s ease-in-out 1.4s infinite;
}

.stats__item {
  animation: scaleIn 0.6s ease forwards;
}

.floating-btn--whatsapp {
  animation: float 3s ease-in-out infinite;
}

.floating-btn--telegram {
  animation: float 3s ease-in-out 1.5s infinite;
}

/* Respect 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;
  }
}
