/* Mascot System Container */
#mascots-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 9999;
  overflow: hidden;
}

/* Individual Mascot Styles */
.mascot-container {
  position: absolute;
  width: 64px;
  height: 64px;
  pointer-events: auto;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  user-select: none;
  will-change: transform;
  transition: transform 0.1s linear;
  /* Smooth micro-movement updates */
}

/* Base Mascot SVG Styling */
.mascot-svg {
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 4px 8px rgba(16, 185, 129, 0.15));
  transition: filter 0.3s ease;
}

.mascot-container:hover .mascot-svg {
  filter: drop-shadow(0 6px 15px rgba(16, 185, 129, 0.45));
}

/* Color Themes matching Cyber Mint & Cyber Orange */
.theme-mint {
  --primary-color: #10b981;
  --secondary-color: #047857;
  --accent-color: #34d399;
}

.theme-orange {
  --primary-color: #f59e0b;
  --secondary-color: #b45309;
  --accent-color: #fbbf24;
}

.theme-cyan {
  --primary-color: #06b6d4;
  --secondary-color: #0e7490;
  --accent-color: #22d3ee;
}

.theme-pink {
  --primary-color: #ec4899;
  --secondary-color: #be185d;
  --accent-color: #f472b6;
}

.theme-purple {
  --primary-color: #8b5cf6;
  --secondary-color: #6d28d9;
  --accent-color: #a78bfa;
}

.theme-red {
  --primary-color: #ef4444;
  --secondary-color: #b91c1c;
  --accent-color: #f87171;
}

/* Eye and Blink Animations */
.mascot-eye-pupil {
  transition: transform 0.05s ease-out;
  fill: #06070b;
}

.mascot-eye-white {
  fill: #ffffff;
}

.mascot-eye {
  transform-origin: center;
  transition: transform 0.1s ease;
}

.blink .mascot-eye {
  animation: blink-anim 0.15s ease-in-out forwards;
}

@keyframes blink-anim {

  0%,
  100% {
    transform: scaleY(1);
  }

  50% {
    transform: scaleY(0.05);
  }
}

/* Specific Secondary Animations */

/* 1. Floating Animation (Jellyfish, Drone, Wisp, Glider) */
.anim-float .mascot-body-group {
  animation: float-bob 3s ease-in-out infinite alternate;
}

@keyframes float-bob {
  0% {
    transform: translateY(-3px);
  }

  100% {
    transform: translateY(3px);
  }
}

/* 2. Propeller Rotation (Drone) */
.anim-spin {
  transform-origin: center;
  animation: spin-propeller 0.1s linear infinite;
}

@keyframes spin-propeller {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

/* 3. Tentacle Wiggle (Jellyfish) */
.tentacle-left {
  transform-origin: 30% 70%;
  animation: tentacle-wiggle-l 2s ease-in-out infinite alternate;
}

.tentacle-mid {
  transform-origin: 50% 75%;
  animation: tentacle-wiggle-m 1.8s ease-in-out infinite alternate;
}

.tentacle-right {
  transform-origin: 70% 70%;
  animation: tentacle-wiggle-r 2.2s ease-in-out infinite alternate;
}

@keyframes tentacle-wiggle-l {
  0% {
    transform: rotate(-5deg);
  }

  100% {
    transform: rotate(8deg);
  }
}

@keyframes tentacle-wiggle-m {
  0% {
    transform: scaleY(0.9) rotate(3deg);
  }

  100% {
    transform: scaleY(1.1) rotate(-3deg);
  }
}

@keyframes tentacle-wiggle-r {
  0% {
    transform: rotate(5deg);
  }

  100% {
    transform: rotate(-8deg);
  }
}

/* 4. Walking Bobbing (Robot) */
.anim-walk .mascot-body-group {
  animation: walk-bob 0.5s ease-in-out infinite alternate;
}

@keyframes walk-bob {
  0% {
    transform: translateY(0px) rotate(-1deg);
  }

  100% {
    transform: translateY(-2px) rotate(1deg);
  }
}

/* Emote Bubble Styling */
.emote-bubble {
  position: absolute;
  bottom: 75px;
  background: rgba(10, 11, 18, 0.95);
  border: 1px solid var(--primary-color);
  color: var(--primary-color);
  font-family: 'Share Tech Mono', 'JetBrains Mono', monospace;
  font-size: 11px;
  padding: 4px 8px;
  border-radius: 6px;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transform: translateY(10px) scale(0.8);
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.15);
  z-index: 10;
}

.emote-bubble::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%) rotate(45deg);
  width: 8px;
  height: 8px;
  background: rgba(10, 11, 18, 0.95);
  border-right: 1px solid var(--primary-color);
  border-bottom: 1px solid var(--primary-color);
}

.emote-bubble.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Scared/Spiked Up Hedgehog Animation */
.spiked-up {
  animation: spike-pulse 0.3s ease-out;
}

@keyframes spike-pulse {
  0% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.15);
  }

  100% {
    transform: scale(1);
  }
}

/* Glider swooping rotation */
.glider-rot {
  transition: transform 0.2s ease-out;
}