/* Mobile Touch Enhancement Styles for Training MVP */

/* CSS-only fallback for :active pseudo-class on mobile */
.mobile-btn-active {
  background-color: #374151 !important; /* neutral-700 */
  transform: scale(0.92) !important;
  transition: all 0.1s ease-out !important;
}

/* Alternative approach using CSS custom properties for dynamic feedback */
.btn-enhanced {
  --scale: 1;
  --bg-color: #1f2937; /* neutral-800 */
  transform: scale(var(--scale));
  background-color: var(--bg-color);
  transition: transform 0.15s ease-out, background-color 0.15s ease-out;
}

/* Ripple effect with CSS animations */
@keyframes ripple {
  0% {
    width: 0;
    height: 0;
    opacity: 1;
  }
  100% {
    width: 300px;
    height: 300px;
    opacity: 0;
  }
}

.ripple-effect::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.4);
  transform: translate(-50%, -50%);
  animation: ripple 0.6s ease-out;
}

/* Enhanced input focus states for mobile */
.mobile-input {
  transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-input:focus {
  transform: scale(1.02);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.3);
}

/* Prevent double-tap zoom on buttons */
.no-zoom {
  touch-action: manipulation;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
}

/* Loading state for buttons */
.btn-loading {
  position: relative;
  pointer-events: none;
  opacity: 0.7;
}

.btn-loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 16px;
  height: 16px;
  margin: -8px 0 0 -8px;
  border: 2px solid transparent;
  border-top: 2px solid currentColor;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

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

/* Success animation */
@keyframes success-pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.success-animation {
  animation: success-pulse 0.3s ease-out;
}

/* Improved touch targets for mobile (minimum 44px) */
.touch-target {
  min-height: 44px;
  min-width: 44px;
}
