/* ============================================================
   LA 15 RADIO — Reproductor flotante
   ============================================================ */

.la15fp {
  --la15fp-accent: #FDBB1E;
  --la15fp-dark: #0b1d3a;
  position: fixed;
  bottom: 18px;
  z-index: 999999;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --la15fp-side: 18px;
}

.la15fp--right { right: var(--la15fp-side); }
.la15fp--left  { left: var(--la15fp-side); }

/* ---------- Burbuja minimizada ---------- */
.la15fp-bubble {
  display: none;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  background: linear-gradient(145deg, var(--la15fp-dark), #123a6e);
  box-shadow: 0 8px 24px rgba(0,0,0,0.35), 0 0 0 2px rgba(253,187,30,0.5);
  position: relative;
  padding: 0;
}
.la15fp-bubble-disc {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--la15fp-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  animation: la15fp-spin 6s linear infinite;
  animation-play-state: paused;
}
.la15fp[data-playing="true"] .la15fp-bubble-disc { animation-play-state: running; }
.la15fp-bubble-disc img { width: 100%; height: 100%; object-fit: cover; }
@keyframes la15fp-spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }

.la15fp-bubble-dot {
  position: absolute;
  top: 2px;
  right: 2px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #22c55e;
  border: 2px solid #0b1d3a;
  animation: la15fp-pulse 1.4s infinite;
}
@keyframes la15fp-pulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(34,197,94,0.6); }
  70%     { box-shadow: 0 0 0 7px rgba(34,197,94,0); }
}

.la15fp[data-minimized="true"] .la15fp-bubble { display: flex; }
.la15fp[data-minimized="true"] .la15fp-card { display: none; }

/* ---------- Tarjeta principal ---------- */
.la15fp-card {
  width: 320px;
  max-width: calc(100vw - 2 * var(--la15fp-side));
  border-radius: 18px;
  padding: 14px 16px 12px;
  position: relative;
  color: #fff;
  background: linear-gradient(160deg, rgba(18,58,110,0.92) 0%, rgba(11,29,58,0.96) 70%);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: 0 14px 38px rgba(0,0,0,0.38), 0 0 0 1px rgba(255,255,255,0.06) inset;
  animation: la15fp-rise 0.35s ease;
}
@keyframes la15fp-rise {
  from { opacity: 0; transform: translateY(14px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.la15fp-minimize {
  position: absolute;
  top: 8px;
  right: 10px;
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.55);
  font-size: 13px;
  cursor: pointer;
  line-height: 1;
  padding: 4px;
  border-radius: 50%;
  transition: color .15s, background .15s;
}
.la15fp-minimize:hover { color: #fff; background: rgba(255,255,255,0.12); }

.la15fp-top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.la15fp-logo {
  flex: 0 0 auto;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  overflow: hidden;
  background: var(--la15fp-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 2px rgba(255,255,255,0.08);
}
.la15fp-logo img { width: 100%; height: 100%; object-fit: cover; }
.la15fp-logo-fallback { font-size: 22px; }

.la15fp-info { min-width: 0; flex: 1 1 auto; }

.la15fp-name-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 3px;
}
.la15fp-name {
  color: #fff;
  font-weight: 800;
  font-size: 14.5px;
  text-decoration: none;
  letter-spacing: 0.2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.la15fp-name:hover { color: var(--la15fp-accent); }

.la15fp-live-badge {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.6px;
  color: #ff6b6b;
  background: rgba(255,107,107,0.12);
  border: 1px solid rgba(255,107,107,0.4);
  padding: 2px 6px;
  border-radius: 20px;
}
.la15fp-live-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ff3b3b;
  animation: la15fp-pulse2 1.1s infinite;
}
@keyframes la15fp-pulse2 {
  0%,100% { opacity: 1; }
  50%     { opacity: 0.25; }
}

.la15fp-nowplaying-mask {
  overflow: hidden;
  width: 100%;
}
.la15fp-nowplaying-track {
  font-size: 12px;
  color: rgba(255,255,255,0.78);
  white-space: nowrap;
  display: inline-block;
}
.la15fp-nowplaying-mask.la15fp-scroll .la15fp-nowplaying-track {
  animation: la15fp-marquee 11s linear infinite;
  padding-right: 40px;
}
@keyframes la15fp-marquee {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ---------- Controles ---------- */
.la15fp-controls {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.la15fp-play {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  background: var(--la15fp-accent);
  color: #1a1200;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(253,187,30,0.45);
  transition: transform .15s ease;
}
.la15fp-play:hover { transform: scale(1.06); }
.la15fp-play:active { transform: scale(0.96); }
.la15fp-icon-spinner { animation: la15fp-spin 0.9s linear infinite; }

.la15fp-eq {
  flex: 0 0 auto;
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 20px;
  opacity: 0.35;
}
.la15fp-eq span {
  width: 3px;
  height: 30%;
  border-radius: 2px;
  background: var(--la15fp-accent);
  transition: opacity .2s;
}
.la15fp[data-playing="true"] .la15fp-eq { opacity: 1; }
.la15fp[data-playing="true"] .la15fp-eq span { animation: la15fp-bar 1s ease-in-out infinite; }
.la15fp-eq span:nth-child(1) { animation-delay: -0.9s; }
.la15fp-eq span:nth-child(2) { animation-delay: -0.6s; }
.la15fp-eq span:nth-child(3) { animation-delay: -0.3s; }
.la15fp-eq span:nth-child(4) { animation-delay: -0.75s; }
.la15fp-eq span:nth-child(5) { animation-delay: -0.15s; }
@keyframes la15fp-bar {
  0%, 100% { height: 25%; }
  50%      { height: 100%; }
}

.la15fp-volume {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(255,255,255,0.6);
  min-width: 0;
}
.la15fp-volume-range {
  flex: 1 1 auto;
  width: 100%;
  -webkit-appearance: none;
  appearance: none;
  height: 3px;
  border-radius: 3px;
  background: rgba(255,255,255,0.22);
  outline: none;
}
.la15fp-volume-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--la15fp-accent);
  cursor: pointer;
  box-shadow: 0 0 0 3px rgba(253,187,30,0.2);
}
.la15fp-volume-range::-moz-range-thumb {
  width: 11px;
  height: 11px;
  border: none;
  border-radius: 50%;
  background: var(--la15fp-accent);
  cursor: pointer;
}

.la15fp-status {
  margin-top: 8px;
  font-size: 10.5px;
  color: rgba(255,255,255,0.45);
  min-height: 13px;
}

/* ---------- Responsive (móvil: barra inferior completa) ---------- */
@media (max-width: 560px) {
  .la15fp {
    left: 0;
    right: 0;
    bottom: 0;
    --la15fp-side: 10px;
  }
  .la15fp-card {
    width: 100%;
    max-width: 100%;
    border-radius: 16px 16px 0 0;
    padding: 12px 14px 14px;
  }
  .la15fp-bubble {
    position: fixed;
    bottom: 14px;
  }
  .la15fp--right .la15fp-bubble { right: 14px; }
  .la15fp--left .la15fp-bubble  { left: 14px; }
  .la15fp[data-minimized="true"] .la15fp-bubble { display: flex; }
}

@media (prefers-reduced-motion: reduce) {
  .la15fp-bubble-disc,
  .la15fp-eq span,
  .la15fp-nowplaying-track,
  .la15fp-icon-spinner {
    animation: none !important;
  }
}
