/**
 * Teknei Brand Center - Animations & Micro-Interactions
 * Fluid spring easings, video badge pulses, and smooth transitions.
 */

/* Pulsing Status Dot */
@keyframes pulse-dot {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(0, 110, 205, 0.7);
  }
  70% {
    transform: scale(1.15);
    box-shadow: 0 0 0 8px rgba(0, 110, 205, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(0, 110, 205, 0);
  }
}

/* Toast In / Out */
@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes toast-out {
  from {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
  to {
    opacity: 0;
    transform: translateY(15px) scale(0.95);
  }
}

/* Shimmer Loading Effect */
@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }
  100% {
    background-position: 200% 0;
  }
}

.shimmer-bg {
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.08) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  background-size: 200% 100%;
  animation: shimmer 2s infinite ease-in-out;
}

/* Video Badge Pulse */
@keyframes video-dot-glow {
  0%, 100% {
    opacity: 0.6;
    transform: scale(0.9);
  }
  50% {
    opacity: 1;
    transform: scale(1.1);
  }
}

.video-hud-dot {
  animation: video-dot-glow 2s infinite ease-in-out;
}

/* Gentle Float for Badges and Accents */
@keyframes gentle-float {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-4px);
  }
}

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

/* Ambient Floating Lights (Kydeoh-inspired fluid drift) */
@keyframes ambientFloat1 {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  33% {
    transform: translate3d(-60px, 80px, 0) scale(1.12);
  }
  66% {
    transform: translate3d(40px, 120px, 0) scale(0.95);
  }
  100% {
    transform: translate3d(80px, -40px, 0) scale(1.08);
  }
}

@keyframes ambientFloat2 {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  33% {
    transform: translate3d(70px, -60px, 0) scale(1.08);
  }
  66% {
    transform: translate3d(-50px, -90px, 0) scale(1.15);
  }
  100% {
    transform: translate3d(40px, 50px, 0) scale(0.92);
  }
}

@keyframes ambientFloat3 {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
  }
  50% {
    transform: translate3d(-80px, -60px, 0) scale(1.1);
  }
  100% {
    transform: translate3d(60px, 40px, 0) scale(0.96);
  }
}

@keyframes ambientFloat4 {
  0% {
    transform: translate3d(0, 0, 0) scale(1);
    opacity: 0.5;
  }
  50% {
    transform: translate3d(50px, -30px, 0) scale(1.2);
    opacity: 0.8;
  }
  100% {
    transform: translate3d(-40px, 60px, 0) scale(0.9);
    opacity: 0.5;
  }
}

/* Mouse Wheel Scroll Animation */
@keyframes mouseWheelDrift {
  0% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(9px);
  }
}

/* Teknei Coral Button Pulse */
@keyframes coral-glow-pulse {
  0%, 100% {
    box-shadow: 0 0 0 0 rgba(232, 65, 56, 0.4), 0 6px 20px rgba(232, 65, 56, 0.35);
  }
  50% {
    box-shadow: 0 0 0 10px rgba(232, 65, 56, 0), 0 8px 28px rgba(232, 65, 56, 0.55);
  }
}

/* Live Dot Pulse */
@keyframes live-dot-ping {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  }
  70% {
    transform: scale(1.1);
    box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

/* Outline Metric Counter Glow on Reveal */
@keyframes metricGlowReveal {
  0% {
    opacity: 0;
    transform: translateY(14px);
    filter: drop-shadow(0 0 0 transparent);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    filter: drop-shadow(0 0 16px rgba(78, 168, 255, 0.4));
  }
}

/* Logo 3D Levitation & Ground Shadow Breathing */
@keyframes logoLevitate {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-9px);
  }
}

@keyframes shadowLevitateBreathe {
  0%, 100% {
    transform: scale(1);
    opacity: 0.65;
  }
  50% {
    transform: scale(0.68);
    opacity: 0.25;
  }
}

/* Reduced Motion Support */
@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;
  }
  .badge-pulse, .float-badge, .video-hud-dot {
    animation: none !important;
  }
}
