/* =========================================================
   REPRODUCTOR CALI VIVA — barra flotante estilo FC
   ========================================================= */
:root {
    --mu-verde: #00b14f;
    --mu-verde-2: #00d861;
    --mu-fondo: rgba(10, 14, 20, .92);
    --mu-panel: #0d131c;
    --mu-borde: rgba(255, 255, 255, .1);
    --mu-texto: #ffffff;
    --mu-texto-2: #9aa5b1;
}

/* ---------- Barra pequeña ---------- */
.mu-barra {
    position: fixed;
    left: 20px;
    bottom: 20px;
    z-index: 1500;
    display: flex;
    align-items: center;
    gap: 12px;
    width: 360px;
    max-width: calc(100vw - 40px);
    padding: 8px 10px 12px 8px;
    border-radius: 16px;
    background: var(--mu-fondo);
    border: 1px solid var(--mu-borde);
    border-left: 3px solid var(--mu-verde);
    box-shadow: 0 14px 40px rgba(0, 0, 0, .45);
    backdrop-filter: blur(14px);
    color: var(--mu-texto);
    cursor: pointer;
    overflow: hidden;
    transform: translateY(0);
    transition: transform .4s cubic-bezier(.25, .8, .25, 1), opacity .3s ease;
    animation: mu-entrar .6s cubic-bezier(.25, .8, .25, 1) both;
}

@keyframes mu-entrar {
    from { transform: translateY(140%); opacity: 0; }
    to   { transform: translateY(0); opacity: 1; }
}

.mu-barra:hover { border-color: rgba(0, 177, 79, .45); }

/* Se esconde mientras un modal está abierto */
body.modal-abierto .mu-barra {
    transform: translateY(160%);
    opacity: 0;
    pointer-events: none;
}

.mu-portada {
    position: relative;
    flex-shrink: 0;
    width: 46px;
    height: 46px;
    border-radius: 10px;
    overflow: hidden;
    background: linear-gradient(135deg, #00b14f, #0b5d34);
    display: grid;
    place-items: center;
    font-size: 20px;
}

.mu-portada img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mu-info {
    flex: 1;
    min-width: 0;
}

.mu-etiqueta {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 2px;
    color: var(--mu-verde-2);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

/* Barritas de ecualizador */
.mu-eq {
    display: inline-flex;
    align-items: flex-end;
    gap: 2px;
    height: 10px;
}

.mu-eq span {
    width: 2px;
    height: 3px;
    border-radius: 2px;
    background: var(--mu-verde-2);
}

.sonando .mu-eq span { animation: mu-eq .9s ease-in-out infinite; }
.sonando .mu-eq span:nth-child(2) { animation-delay: .2s; }
.sonando .mu-eq span:nth-child(3) { animation-delay: .4s; }

@keyframes mu-eq {
    0%, 100% { height: 3px; }
    50% { height: 10px; }
}

.mu-titulo,
.mu-artista {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mu-titulo {
    font-size: 14px;
    font-weight: 800;
}

.mu-artista {
    color: var(--mu-texto-2);
    font-size: 12px;
}

.mu-controles {
    display: flex;
    align-items: center;
    gap: 2px;
    flex-shrink: 0;
}

.mu-btn {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--mu-texto);
    cursor: pointer;
    transition: background .2s, color .2s;
}

.mu-btn:hover { background: rgba(255, 255, 255, .08); color: var(--mu-verde-2); }
.mu-btn svg { width: 18px; height: 18px; fill: currentColor; }

.mu-btn.mu-play {
    width: 40px;
    height: 40px;
    background: var(--mu-verde);
    color: #fff;
}

.mu-btn.mu-play:hover { background: var(--mu-verde-2); color: #fff; }

/* Línea de progreso abajo */
.mu-progreso {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: rgba(255, 255, 255, .08);
}

.mu-progreso span {
    display: block;
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, var(--mu-verde), var(--mu-verde-2));
    transition: width .5s linear;
}

/* ---------- Panel lateral derecho ---------- */
.mu-fondo-panel {
    position: fixed;
    inset: 0;
    z-index: 1600;
    background: rgba(0, 0, 0, .45);
    opacity: 0;
    visibility: hidden;
    transition: opacity .35s ease, visibility .35s ease;
}

.mu-panel {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1700;
    display: flex;
    flex-direction: column;
    width: 380px;
    max-width: 100vw;
    background: var(--mu-panel);
    border-left: 1px solid var(--mu-borde);
    box-shadow: -20px 0 60px rgba(0, 0, 0, .5);
    color: var(--mu-texto);
    transform: translateX(105%);
    transition: transform .45s cubic-bezier(.25, .8, .25, 1);
}

.mu-abierto .mu-panel { transform: translateX(0); }
.mu-abierto .mu-fondo-panel { opacity: 1; visibility: visible; }

.mu-panel-cabecera {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 20px 14px;
}

.mu-panel-cabecera h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 900;
}

.mu-panel-cabecera small {
    display: block;
    color: var(--mu-verde-2);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.mu-cerrar {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    padding: 0 0 3px;
    border: 1px solid var(--mu-borde);
    border-radius: 50%;
    background: rgba(255, 255, 255, .05);
    color: #fff;
    font-family: Arial, sans-serif;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
}

.mu-cerrar:hover { background: var(--mu-verde); }

.mu-panel-cuerpo {
    flex: 1;
    overflow-y: auto;
    padding: 0 20px 24px;
    scrollbar-width: thin;
    scrollbar-color: #2a3647 transparent;
}

/* Reproductor oficial de Spotify dentro del panel */
.mu-spotify {
    margin-bottom: 18px;
    border-radius: 14px;
    overflow: hidden;
    background: #000;
}

.mu-spotify iframe {
    display: block;
    width: 100%;
    border: 0;
}

.mu-subtitulo {
    margin: 4px 0 10px;
    color: var(--mu-texto-2);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.mu-lista {
    margin: 0;
    padding: 0;
    list-style: none;
}

.mu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 9px 10px;
    margin-bottom: 4px;
    border: 1px solid transparent;
    border-radius: 12px;
    background: transparent;
    color: var(--mu-texto);
    text-align: left;
    cursor: pointer;
    transition: background .2s, border-color .2s;
}

.mu-item:hover { background: rgba(255, 255, 255, .05); }

.mu-item.actual {
    background: rgba(0, 177, 79, .12);
    border-color: rgba(0, 177, 79, .35);
}

.mu-item .mu-portada {
    width: 42px;
    height: 42px;
    font-size: 16px;
}

.mu-item .mu-num {
    width: 18px;
    flex-shrink: 0;
    color: var(--mu-texto-2);
    font-size: 12px;
    font-weight: 700;
    text-align: center;
}

.mu-item.actual .mu-num { color: var(--mu-verde-2); }

.mu-item .mu-info strong {
    display: block;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mu-item .mu-info small {
    display: block;
    color: var(--mu-texto-2);
    font-size: 12px;
}

.mu-nota {
    margin: 16px 0 0;
    color: #6b7785;
    font-size: 11px;
    line-height: 1.5;
}

/* ---------- Celular ---------- */
@media (max-width: 760px) {
    .mu-barra {
        left: 10px;
        right: 10px;
        bottom: 10px;
        width: auto;
        max-width: none;
    }

    .mu-panel { width: 100vw; }
}