/* ============================================================
   ANIMATIONS.CSS — Keyframes & Scroll Animation Classes
   ============================================================ */

/* ── Keyframes ─────────────────────────────────────────────── */

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

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

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

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

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

@keyframes floatOrb {
  0%, 100% { transform: translateY(0) scale(1); }
  50%       { transform: translateY(-24px) scale(1.04); }
}

@keyframes marqueeScroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

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

@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.4); }
  50%       { box-shadow: 0 0 0 16px rgba(37, 99, 235, 0); }
}

/* ── Scroll-triggered base states ──────────────────────────── */

.animate-fade-up {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.animate-fade-in {
  opacity: 0;
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.animate-slide-left {
  opacity: 0;
  transform: translateX(60px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.animate-slide-right {
  opacity: 0;
  transform: translateX(-60px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

/* ── Visible state (added by IntersectionObserver) ─────────── */

.animate-fade-up.visible,
.animate-fade-in.visible,
.animate-slide-left.visible,
.animate-slide-right.visible {
  opacity: 1;
  transform: translate(0, 0);
}

/* ── Staggered children delays ─────────────────────────────── */

.stagger-children > *:nth-child(1) { transition-delay: 0s; }
.stagger-children > *:nth-child(2) { transition-delay: 0.1s; }
.stagger-children > *:nth-child(3) { transition-delay: 0.2s; }
.stagger-children > *:nth-child(4) { transition-delay: 0.3s; }
.stagger-children > *:nth-child(5) { transition-delay: 0.4s; }
.stagger-children > *:nth-child(6) { transition-delay: 0.5s; }

/* ── Hero entrance animations ──────────────────────────────── */

.hero-label   { animation: heroFadeUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.2s both; }
.hero-title   { animation: heroFadeUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.4s both; }
.hero-sub     { animation: heroFadeUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.6s both; }
.hero-buttons { animation: heroFadeUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.8s both; }
.hero-stats   { animation: heroFadeUp 0.8s cubic-bezier(0.22, 1, 0.36, 1) 1.0s both; }

/* ── Product panel fade-up ──────────────────────────────────── */

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

.product-panel.panel-active {
  animation: panelFadeUp 0.4s ease both;
}

/* ── Floating device mockup ─────────────────────────────────── */

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

/* ── Gradient orbs ──────────────────────────────────────────── */

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  pointer-events: none;
  animation: floatOrb 8s ease-in-out infinite;
}
