/* ============================================================
   ANIMATIONS
   ============================================================ */

/* ── Keyframes ──────────────────────────────────────────────── */
@keyframes floatUpDown {
  0%, 100% { transform: translateY(0px); }
  50%       { transform: translateY(-10px); }
}

@keyframes floatRotate {
  0%, 100% { transform: translateY(0px) rotate(0deg); }
  50%       { transform: translateY(-8px) rotate(3deg); }
}

@keyframes typingBounce {
  0%, 80%, 100% { transform: scale(0.8); opacity: 0.5; }
  40%           { transform: scale(1.2); opacity: 1; }
}

@keyframes waveAnimation {
  0%, 100% { height: 6px;  }
  25%       { height: 28px; }
  50%       { height: 14px; }
  75%       { height: 36px; }
}

@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 20px var(--purple-glow); }
  50%       { box-shadow: 0 0 40px var(--purple-glow), 0 0 80px rgba(124,58,237,0.2); }
}

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

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

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

@keyframes slideInDown {
  from { opacity: 0; transform: translateY(-20px); }
  to   { opacity: 1; transform: translateY(0); }
}

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

@keyframes shimmer {
  from { background-position: -200% 0; }
  to   { background-position: 200% 0; }
}

@keyframes particleDrift {
  0%   { transform: translateY(0)    opacity(0); }
  10%  { opacity: 1; }
  90%  { opacity: 1; }
  100% { transform: translateY(-80px); opacity: 0; }
}

@keyframes borderGlow {
  0%, 100% { border-color: rgba(124,58,237,0.3); }
  50%       { border-color: rgba(236,72,153,0.5); }
}

@keyframes gradientShift {
  0%   { background-position: 0% 50%; }
  50%  { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes textReveal {
  from { clip-path: inset(0 100% 0 0); }
  to   { clip-path: inset(0 0% 0 0); }
}

@keyframes scanLine {
  from { top: -2px; }
  to   { top: 100%; }
}

@keyframes onlinePulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50%       { transform: scale(1.4); opacity: 0.7; }
}

/* ── Animate on Scroll (AOS-lite) ───────────────────────────── */
.animate-fade-up {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.animate-fade-left {
  opacity: 0;
  transform: translateX(-28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.animate-fade-right {
  opacity: 0;
  transform: translateX(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.animate-scale {
  opacity: 0;
  transform: scale(0.92);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-fade-up.visible,
.animate-fade-left.visible,
.animate-fade-right.visible,
.animate-scale.visible {
  opacity: 1;
  transform: none;
}

.delay-100 { transition-delay: 0.1s; }
.delay-200 { transition-delay: 0.2s; }
.delay-300 { transition-delay: 0.3s; }
.delay-400 { transition-delay: 0.4s; }
.delay-500 { transition-delay: 0.5s; }
.delay-600 { transition-delay: 0.6s; }

/* ── Persistent Animations ──────────────────────────────────── */
.pulse-glow { animation: pulseGlow 3s ease-in-out infinite; }

.float { animation: floatUpDown 5s ease-in-out infinite; }
.float-slow { animation: floatUpDown 7s ease-in-out infinite; }
.float-delay { animation: floatUpDown 5s ease-in-out infinite; animation-delay: 1.5s; }

.border-animate { animation: borderGlow 3s ease-in-out infinite; }

.gradient-animate {
  background-size: 200% 200%;
  animation: gradientShift 4s ease infinite;
}

/* ── Skeleton Loading ───────────────────────────────────────── */
.skeleton {
  background: linear-gradient(
    90deg,
    rgba(124,58,237,0.08) 25%,
    rgba(192,132,252,0.12) 50%,
    rgba(124,58,237,0.08) 75%
  );
  background-size: 200% 100%;
  animation: shimmer 1.8s infinite;
  border-radius: var(--radius-sm);
}

/* ── Particle Canvas ────────────────────────────────────────── */
#particles-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  opacity: 0.35;
}

/* ── Hero specific ──────────────────────────────────────────── */
.hero-title { animation: fadeInUp 0.9s ease forwards; }
.hero-subtitle { animation: fadeInUp 0.9s 0.15s ease forwards; opacity: 0; }
.hero-cta { animation: fadeInUp 0.9s 0.3s ease forwards; opacity: 0; }
.hero-trust { animation: fadeInUp 0.9s 0.45s ease forwards; opacity: 0; }
.hero-visual { animation: scaleIn 1s 0.2s ease forwards; opacity: 0; }

/* ── Scan line effect for mockups ───────────────────────────── */
.scan-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  border-radius: inherit;
  z-index: 3;
}

.scan-overlay::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(124,58,237,0.5), transparent);
  animation: scanLine 4s linear infinite;
}

/* ── Online status pulse ────────────────────────────────────── */
.online-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  animation: onlinePulse 2s ease-in-out infinite;
  box-shadow: 0 0 8px #22c55e;
}

/* ── Neon text glow ─────────────────────────────────────────── */
.neon-text {
  color: var(--purple-light);
  text-shadow: 0 0 20px rgba(192,132,252,0.7), 0 0 40px rgba(192,132,252,0.3);
}

/* ── Image hover zoom ───────────────────────────────────────── */
.zoom-hover {
  overflow: hidden;
}
.zoom-hover img,
.zoom-hover .inner {
  transition: transform 0.5s ease;
}
.zoom-hover:hover img,
.zoom-hover:hover .inner {
  transform: scale(1.06);
}

/* ── Noise overlay ──────────────────────────────────────────── */
.noise-overlay {
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  opacity: 0.4;
  pointer-events: none;
  z-index: 1;
}
