/* Animations & Keyframes */

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

@keyframes popIn {
  0% { transform: scale(0.6); opacity: 0; }
  70% { transform: scale(1.08); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

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

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

@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 12px rgba(124, 77, 255, 0.4); }
  50% { box-shadow: 0 0 28px rgba(255, 64, 129, 0.8); }
}

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

@keyframes cardRevealSparkle {
  0% { transform: scale(0.8) rotate(-5deg); opacity: 0; }
  50% { transform: scale(1.08) rotate(3deg); opacity: 1; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

.animate-pop {
  animation: popIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.animate-reveal {
  animation: cardRevealSparkle 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.animate-bounce {
  animation: bounceSlow 2.5s infinite ease-in-out;
}

.animate-glow {
  animation: pulseGlow 2s infinite ease-in-out;
}

/* Rarity Color Themes */
.card-rarity-common {
  background: linear-gradient(135deg, #F8FAFC, #E2E8F0) !important;
  border: 2px solid #94A3B8 !important;
}

.card-rarity-rare {
  background: linear-gradient(135deg, #E0F2FE, #BAE6FD) !important;
  border: 2px solid #38BDF8 !important;
  box-shadow: 0 0 16px rgba(56, 189, 248, 0.25) !important;
}

.card-rarity-super_rare {
  background: linear-gradient(135deg, #F3E8FF, #E9D5FF) !important;
  border: 2px solid #C084FC !important;
  box-shadow: 0 0 20px rgba(192, 132, 252, 0.35) !important;
}

.card-rarity-epic {
  background: linear-gradient(135deg, #FEF3C7, #FDE68A) !important;
  border: 2px solid #FBBF24 !important;
  box-shadow: 0 0 24px rgba(251, 191, 36, 0.45) !important;
}

.card-rarity-legendary {
  background: linear-gradient(135deg, #FFE4E6, #FECDD3, #F3E8FF) !important;
  border: 2px solid #FB7185 !important;
  animation: pulseGlow 1.5s infinite ease-in-out !important;
}

/* Level Up & Particle Keyframes */
@keyframes levelUpPopup {
  0% { transform: scale(0.4) rotate(-10deg); opacity: 0; }
  60% { transform: scale(1.12) rotate(3deg); opacity: 1; }
  100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

@keyframes lightRaysRotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

@keyframes pulseParticle {
  0%, 100% { transform: scale(1); opacity: 0.4; }
  50% { transform: scale(1.3); opacity: 0.9; }
}

.animate-levelup {
  animation: levelUpPopup 0.6s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.char-svg {
  width: 100%;
  height: 100%;
  max-width: 120px;
  max-height: 120px;
  filter: drop-shadow(0 4px 10px rgba(0, 0, 0, 0.15));
}

.char-svg-lg {
  max-width: 160px;
  max-height: 160px;
  filter: drop-shadow(0 8px 20px rgba(0, 0, 0, 0.25));
}

.char-svg-silhouette {
  filter: brightness(0.12) grayscale(1) opacity(0.65);
}

