/* ==========================================================================
   BODYWORKS MASTER LTD - ANIMATIONS & DYNAMIC FX
   ========================================================================== */

/* Road Speed Lines & Cyber Glow */
@keyframes speedLines {
  0% { transform: translateY(-100%); opacity: 0; }
  50% { opacity: 1; }
  100% { transform: translateY(100%); opacity: 0; }
}

@keyframes roadMove {
  0% { background-position: 0 0; }
  100% { background-position: 0 1000px; }
}

@keyframes nitroGlow {
  0%, 100% {
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.4), inset 0 0 15px rgba(6, 182, 212, 0.2);
    border-color: rgba(6, 182, 212, 0.8);
  }
  50% {
    box-shadow: 0 0 45px rgba(6, 182, 212, 0.85), inset 0 0 25px rgba(6, 182, 212, 0.5);
    border-color: #38bdf8;
  }
}

@keyframes exhaustFlame {
  0% { transform: scaleY(0.8) scaleX(0.9); opacity: 0.7; }
  50% { transform: scaleY(1.4) scaleX(1.1); opacity: 1; filter: drop-shadow(0 0 12px #ef4444); }
  100% { transform: scaleY(0.9) scaleX(0.85); opacity: 0.75; }
}

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

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

.floating-element {
  animation: floatGentle 4s ease-in-out infinite;
}

/* Modal and Backdrop Animations */
@keyframes modalFadeIn {
  from { opacity: 0; transform: scale(0.92) translateY(20px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

@keyframes backdropFadeIn {
  from { opacity: 0; backdrop-filter: blur(0px); }
  to { opacity: 1; backdrop-filter: blur(10px); }
}

.modal-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(4, 6, 10, 0.82);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
  padding: 1.5rem;
}

.modal-backdrop.active {
  opacity: 1;
  pointer-events: auto;
  animation: backdropFadeIn 0.3s forwards;
}

.modal-box {
  background: #111622;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-lg);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 2rem;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.9), 0 0 30px rgba(245, 158, 11, 0.2);
  position: relative;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.modal-backdrop.active .modal-box {
  animation: modalFadeIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.modal-close-btn {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  cursor: pointer;
  transition: var(--transition-fast);
}

.modal-close-btn:hover {
  background: var(--accent-racing-red);
  transform: rotate(90deg);
}

/* Toast Notifications */
.toast-container {
  position: fixed;
  bottom: 2rem;
  left: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  z-index: 1050;
  pointer-events: none;
}

.toast {
  background: #151c2c;
  border-left: 4px solid var(--accent-gold);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  color: #fff;
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 280px;
  max-width: 400px;
  pointer-events: auto;
  animation: toastIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.toast.success { border-color: var(--accent-green); }
.toast.info { border-color: var(--accent-cyan); }
.toast.warning { border-color: var(--accent-gold); }

@keyframes toastIn {
  from { transform: translateX(-100%) scale(0.9); opacity: 0; }
  to { transform: translateX(0) scale(1); opacity: 1; }
}

@keyframes toastOut {
  from { transform: translateX(0) scale(1); opacity: 1; }
  to { transform: translateX(-100%) scale(0.9); opacity: 0; }
}

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

.shimmer {
  background: linear-gradient(90deg, rgba(255,255,255,0.03) 25%, rgba(255,255,255,0.08) 50%, rgba(255,255,255,0.03) 75%);
  background-size: 200% 100%;
  animation: shimmer 2s infinite;
}
