/* ==========================================================================
   Cabañas Amor.es - Floating Background Audio Player
   ========================================================================== */

.amores-audio-container {
  position: fixed;
  bottom: 24px;
  left: 24px;
  z-index: 99990;
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: 'Poppins', sans-serif;
  user-select: none;
  -webkit-user-select: none;
}

/* Floating Audio Trigger Button */
.amores-audio-btn {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f35525 0%, #d63d0e 100%);
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(243, 85, 37, 0.45);
  transition: transform 0.25s cubic-bezier(0.25, 0.8, 0.25, 1),
              box-shadow 0.25s cubic-bezier(0.25, 0.8, 0.25, 1),
              background 0.3s ease;
  position: relative;
  outline: none;
  padding: 0;
}

.amores-audio-btn:hover {
  transform: scale(1.08);
  box-shadow: 0 8px 26px rgba(243, 85, 37, 0.65);
}

.amores-audio-btn:active {
  transform: scale(0.94);
}

.amores-audio-btn i {
  font-size: 18px;
  color: #ffffff;
  transition: transform 0.2s ease;
}

/* Equalizer Animated Bars */
.amores-equalizer {
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 3px;
  height: 20px;
  width: 22px;
}

.amores-eq-bar {
  width: 3.5px;
  background-color: #ffffff;
  border-radius: 3px;
  height: 5px;
  transition: height 0.2s ease;
}

/* Equalizer movement when playing */
.amores-audio-playing .amores-eq-bar:nth-child(1) {
  animation: amoresEqBounce 0.9s ease-in-out infinite alternate;
}

.amores-audio-playing .amores-eq-bar:nth-child(2) {
  animation: amoresEqBounce 1.2s ease-in-out infinite alternate 0.2s;
}

.amores-audio-playing .amores-eq-bar:nth-child(3) {
  animation: amoresEqBounce 0.8s ease-in-out infinite alternate 0.4s;
}

.amores-audio-playing .amores-eq-bar:nth-child(4) {
  animation: amoresEqBounce 1.1s ease-in-out infinite alternate 0.1s;
}

@keyframes amoresEqBounce {
  0% {
    height: 4px;
  }
  100% {
    height: 18px;
  }
}

/* Attention pulse when autoplay is blocked by browser policy */
.amores-audio-attention .amores-audio-btn {
  animation: amoresPulse 2s infinite;
}

@keyframes amoresPulse {
  0% {
    box-shadow: 0 0 0 0 rgba(243, 85, 37, 0.7);
  }
  70% {
    box-shadow: 0 0 0 16px rgba(243, 85, 37, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(243, 85, 37, 0);
  }
}

/* Interactive Info Badge / Tooltip */
.amores-audio-badge {
  background: rgba(24, 24, 24, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #ffffff;
  padding: 8px 16px;
  border-radius: 24px;
  font-size: 13px;
  font-weight: 500;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  display: flex;
  align-items: center;
  gap: 8px;
  opacity: 0;
  transform: translateX(-12px);
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(0.25, 0.8, 0.25, 1),
              transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  white-space: nowrap;
}

.amores-audio-badge.visible,
.amores-audio-container:hover .amores-audio-badge {
  opacity: 1;
  transform: translateX(0);
}

.amores-audio-badge .badge-icon {
  color: #f35525;
  font-size: 14px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .amores-audio-container {
    bottom: 20px;
    left: 18px;
  }

  .amores-audio-btn {
    width: 48px;
    height: 48px;
  }

  .amores-audio-badge {
    padding: 6px 12px;
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  /* On very narrow screens, keep only the floating button visible unless hovered */
  .amores-audio-badge {
    position: absolute;
    bottom: 58px;
    left: 0;
    transform: translateY(6px);
  }

  .amores-audio-badge.visible,
  .amores-audio-container:hover .amores-audio-badge {
    transform: translateY(0);
  }
}
