/* ================================
   ANIMATED BACKGROUNDS & PARTICLES
   ================================ */

/* Floating Particles Background */
.animated-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  max-width: 100vw;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.particle {
  position: absolute;
  background: radial-gradient(circle, rgba(245, 166, 35, 0.8), transparent);
  border-radius: 50%;
  animation: float-particle linear infinite;
  opacity: 0;
}

@keyframes float-particle {
  0% {
    transform: translateY(100vh) scale(0);
    opacity: 0;
  }
  10% {
    opacity: 0.6;
  }
  90% {
    opacity: 0.6;
  }
  100% {
    transform: translateY(-100vh) scale(1.5);
    opacity: 0;
  }
}

/* Generate 20 particles with varying sizes and speeds */
.particle:nth-child(1) { width: 4px; height: 4px; left: 10%; animation-duration: 15s; animation-delay: 0s; }
.particle:nth-child(2) { width: 6px; height: 6px; left: 20%; animation-duration: 18s; animation-delay: 2s; }
.particle:nth-child(3) { width: 3px; height: 3px; left: 30%; animation-duration: 12s; animation-delay: 4s; }
.particle:nth-child(4) { width: 5px; height: 5px; left: 40%; animation-duration: 20s; animation-delay: 1s; }
.particle:nth-child(5) { width: 7px; height: 7px; left: 50%; animation-duration: 16s; animation-delay: 3s; }
.particle:nth-child(6) { width: 4px; height: 4px; left: 60%; animation-duration: 14s; animation-delay: 5s; }
.particle:nth-child(7) { width: 6px; height: 6px; left: 70%; animation-duration: 19s; animation-delay: 0s; }
.particle:nth-child(8) { width: 5px; height: 5px; left: 80%; animation-duration: 17s; animation-delay: 2s; }
.particle:nth-child(9) { width: 3px; height: 3px; left: 90%; animation-duration: 13s; animation-delay: 4s; }
.particle:nth-child(10) { width: 6px; height: 6px; left: 15%; animation-duration: 21s; animation-delay: 1s; }
.particle:nth-child(11) { width: 4px; height: 4px; left: 25%; animation-duration: 15s; animation-delay: 3s; }
.particle:nth-child(12) { width: 5px; height: 5px; left: 35%; animation-duration: 18s; animation-delay: 0s; }
.particle:nth-child(13) { width: 7px; height: 7px; left: 45%; animation-duration: 16s; animation-delay: 2s; }
.particle:nth-child(14) { width: 3px; height: 3px; left: 55%; animation-duration: 14s; animation-delay: 4s; }
.particle:nth-child(15) { width: 6px; height: 6px; left: 65%; animation-duration: 20s; animation-delay: 1s; }
.particle:nth-child(16) { width: 4px; height: 4px; left: 75%; animation-duration: 17s; animation-delay: 3s; }
.particle:nth-child(17) { width: 5px; height: 5px; left: 85%; animation-duration: 19s; animation-delay: 0s; }
.particle:nth-child(18) { width: 6px; height: 6px; left: 95%; animation-duration: 15s; animation-delay: 2s; }
.particle:nth-child(19) { width: 4px; height: 4px; left: 12%; animation-duration: 22s; animation-delay: 5s; }
.particle:nth-child(20) { width: 7px; height: 7px; left: 88%; animation-duration: 18s; animation-delay: 1s; }

/* Animated Gradient Overlay */
.gradient-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  max-width: 100vw;
  pointer-events: none;
  z-index: 0;
  background: 
    radial-gradient(circle at 20% 50%, rgba(245, 166, 35, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(245, 166, 35, 0.06) 0%, transparent 40%);
  animation: gradient-shift 20s ease-in-out infinite;
  opacity: 0.5;
}

@keyframes gradient-shift {
  0%, 100% {
    opacity: 0.6;
  }
  50% {
    opacity: 0.85;
  }
}

/* Floating Geometric Shapes */
.floating-shapes {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  max-width: 100vw;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.shape {
  position: absolute;
  opacity: 0.03;
  animation: float-shape linear infinite;
}

.shape-circle {
  border-radius: 50%;
  border: 2px solid var(--color-accent);
}

.shape-square {
  border: 2px solid var(--color-accent);
  transform: rotate(45deg);
}

.shape-triangle {
  width: 0;
  height: 0;
  border-left: 30px solid transparent;
  border-right: 30px solid transparent;
  border-bottom: 60px solid var(--color-accent);
}

@keyframes float-shape {
  0% {
    transform: translateY(100vh) rotate(0deg);
    opacity: 0;
  }
  10% {
    opacity: 0.03;
  }
  90% {
    opacity: 0.03;
  }
  100% {
    transform: translateY(-100vh) rotate(360deg);
    opacity: 0;
  }
}

.shape:nth-child(1) { 
  width: 60px; 
  height: 60px; 
  left: 5%; 
  animation-duration: 25s; 
  animation-delay: 0s; 
}

.shape:nth-child(2) { 
  width: 40px; 
  height: 40px; 
  left: 15%; 
  animation-duration: 30s; 
  animation-delay: 5s; 
}

.shape:nth-child(3) { 
  width: 80px; 
  height: 80px; 
  left: 85%; 
  animation-duration: 35s; 
  animation-delay: 10s; 
}

.shape:nth-child(4) { 
  width: 50px; 
  height: 50px; 
  left: 65%; 
  animation-duration: 28s; 
  animation-delay: 3s; 
}

.shape:nth-child(5) { 
  left: 45%; 
  animation-duration: 32s; 
  animation-delay: 7s; 
}

/* Pulsing Glow Effect */
.glow-pulse {
  position: relative;
}

.glow-pulse::before {
  content: '';
  position: absolute;
  inset: -20px;
  background: radial-gradient(circle, rgba(245, 166, 35, 0.3), transparent 70%);
  opacity: 0;
  animation: pulse-glow 3s ease-in-out infinite;
  border-radius: inherit;
  z-index: -1;
}

@keyframes pulse-glow {
  0%, 100% {
    opacity: 0;
    transform: scale(0.9);
  }
  50% {
    opacity: 1;
    transform: scale(1.1);
  }
}

/* Liquid Morphing Background */
.liquid-bg {
  position: absolute;
  inset: 0;
  background: 
    radial-gradient(circle at 30% 30%, rgba(245, 166, 35, 0.1) 0%, transparent 50%),
    radial-gradient(circle at 70% 70%, rgba(245, 166, 35, 0.08) 0%, transparent 50%);
  filter: blur(60px);
  animation: liquid-morph 15s ease-in-out infinite;
}

@keyframes liquid-morph {
  0%, 100% {
    transform: scale(1) rotate(0deg);
  }
  25% {
    transform: scale(1.2) rotate(90deg);
  }
  50% {
    transform: scale(0.9) rotate(180deg);
  }
  75% {
    transform: scale(1.1) rotate(270deg);
  }
}

/* Shimmer Effect */
.shimmer {
  position: relative;
  overflow: hidden;
}

.shimmer::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    45deg,
    transparent 30%,
    rgba(255, 255, 255, 0.1) 50%,
    transparent 70%
  );
  animation: shimmer-slide 3s infinite;
}

@keyframes shimmer-slide {
  0% {
    transform: translateX(-100%) translateY(-100%) rotate(45deg);
  }
  100% {
    transform: translateX(100%) translateY(100%) rotate(45deg);
  }
}

/* Glitch Effect (subtle) */
@keyframes glitch {
  0%, 100% {
    transform: translate(0);
  }
  20% {
    transform: translate(-2px, 2px);
  }
  40% {
    transform: translate(-2px, -2px);
  }
  60% {
    transform: translate(2px, 2px);
  }
  80% {
    transform: translate(2px, -2px);
  }
}

.glitch-effect {
  animation: glitch 0.3s infinite;
  animation-timing-function: steps(2, end);
}

/* Scroll-triggered Wave Animation */
.wave-line {
  position: relative;
}

.wave-line::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, 
    var(--color-accent) 0%, 
    transparent 50%, 
    var(--color-accent) 100%
  );
  animation: wave-flow 2s linear infinite;
}

@keyframes wave-flow {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

/* Glassmorphism Enhanced - only adds blur and border, NO background override */
.glass-enhanced {
  backdrop-filter: blur(12px) saturate(150%);
  -webkit-backdrop-filter: blur(12px) saturate(150%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 
    0 8px 32px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

/* 3D Card Tilt Effect */
.card-3d {
  transform-style: preserve-3d;
  transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

.card-3d:hover {
  transform: rotateX(5deg) rotateY(5deg) translateZ(10px);
}

.card-3d::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.1) 0%, transparent 100%);
  opacity: 0;
  transition: opacity 0.3s;
  border-radius: inherit;
}

.card-3d:hover::before {
  opacity: 1;
}

/* Magnetic Hover Effect */
@keyframes magnetic-pull {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

.magnetic:hover {
  animation: magnetic-pull 0.6s ease-in-out;
}

/* Neon Glow Text */
.neon-text {
  text-shadow: 
    0 0 5px rgba(245, 166, 35, 0.8),
    0 0 10px rgba(245, 166, 35, 0.6),
    0 0 20px rgba(245, 166, 35, 0.4),
    0 0 40px rgba(245, 166, 35, 0.2);
  animation: neon-flicker 3s infinite alternate;
}

@keyframes neon-flicker {
  0%, 100% {
    text-shadow: 
      0 0 5px rgba(245, 166, 35, 0.8),
      0 0 10px rgba(245, 166, 35, 0.6),
      0 0 20px rgba(245, 166, 35, 0.4);
  }
  50% {
    text-shadow: 
      0 0 2px rgba(245, 166, 35, 0.9),
      0 0 5px rgba(245, 166, 35, 0.7),
      0 0 10px rgba(245, 166, 35, 0.5),
      0 0 20px rgba(245, 166, 35, 0.3);
  }
}
