/* 
   PLATFORM POLISH SYSTEM 
   Unified Animation Language 
*/

:root {
  /* Timing Scale */
  --duration-instant:  80ms;
  --duration-fast:     150ms;
  --duration-normal:   250ms;
  --duration-slow:     400ms;
  --duration-dramatic: 800ms;
  --duration-epic:     1500ms;

  /* Easing Library */
  --ease-out:    cubic-bezier(0.0, 0.0, 0.2, 1);
  --ease-in:     cubic-bezier(0.4, 0.0, 1, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-smooth: cubic-bezier(0.4, 0.0, 0.2, 1);
}

/* Base Interactions */
.interactive-pop {
  transition: transform var(--duration-fast) var(--ease-spring);
}
.interactive-pop:active {
  transform: scale(0.95);
}
.interactive-pop:hover {
  transform: scale(1.02);
}

/* Floating Rewards */
@keyframes float-up-fade {
  0% { transform: translateY(0); opacity: 0; }
  20% { opacity: 1; }
  100% { transform: translateY(-40px); opacity: 0; }
}
.animate-float-reward {
  animation: float-up-fade var(--duration-dramatic) var(--ease-out) forwards;
}

/* Spring Entrances */
@keyframes spring-in {
  0% { transform: scale(0.5); opacity: 0; }
  70% { transform: scale(1.1); }
  100% { transform: scale(1); opacity: 1; }
}
.animate-spring-in {
  animation: spring-in var(--duration-normal) var(--ease-spring) forwards;
}

/* Shake Feedback (Soft Failure) */
@keyframes soft-shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}
.animate-soft-shake {
  animation: soft-shake var(--duration-normal) var(--ease-smooth) 2;
}

/* Shimmer Effect (Ambient Life) */
@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}
.shimmer-sweep {
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
  background-size: 200% 100%;
  animation: shimmer 3s infinite linear;
}

/* Pulse (Attract Attention) */
@keyframes pulse-subtle {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.05); opacity: 0.9; }
}
.animate-pulse-subtle {
  animation: pulse-subtle 2s infinite ease-in-out;
}

/* Pop In (Entrance) */
@keyframes pop-in {
  0% { transform: scale(0.9); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}
.animate-pop-in {
  animation: pop-in var(--duration-normal) var(--ease-spring) forwards;
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
