/* ==========================================================================
   LexiBand — Custom Styles, Micro-Animations & Mobile Compact Utilities
   ========================================================================== */

/* Waveform animation during audio playback */
@keyframes eqBar {
  0%, 100% { transform: scaleY(0.28); }
  50% { transform: scaleY(1); }
}

.eq-bar {
  transform-origin: center;
  transition: transform 0.2s ease;
}

.is-speaking .eq-bar:nth-child(1) { animation: eqBar 0.6s ease-in-out infinite 0.00s; }
.is-speaking .eq-bar:nth-child(2) { animation: eqBar 0.6s ease-in-out infinite 0.12s; }
.is-speaking .eq-bar:nth-child(3) { animation: eqBar 0.6s ease-in-out infinite 0.24s; }
.is-speaking .eq-bar:nth-child(4) { animation: eqBar 0.6s ease-in-out infinite 0.36s; }
.is-speaking .eq-bar:nth-child(5) { animation: eqBar 0.6s ease-in-out infinite 0.18s; }

/* Tactile feedback micro-animations */
@keyframes gentleShake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

.animate-shake {
  animation: gentleShake 0.36s cubic-bezier(.36,.07,.19,.97) both;
}

@keyframes hitGlow {
  0% { box-shadow: 0 0 0 0 rgba(5, 150, 105, 0.35); }
  70% { box-shadow: 0 0 0 10px rgba(5, 150, 105, 0); }
  100% { box-shadow: 0 0 0 0 rgba(5, 150, 105, 0); }
}

.animate-hit {
  animation: hitGlow 0.55s ease-out;
}

/* Hide scrollbars on horizontal mobile pill strips while preserving touch scroll */
.no-scrollbar::-webkit-scrollbar {
  display: none;
}
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

/* Subtle custom scrollbars for desktop tables & sidebars */
::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.32);
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(148, 163, 184, 0.55);
}

/* Prevent iOS tap highlight flicker & improve touch responsiveness */
button, select, input, label {
  -webkit-tap-highlight-color: transparent;
}

/* Safe-area support for mobile bottom bar */
.pb-safe {
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
