/* =========================
   RESET Y FONDO UNIFORME
========================= */
html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    width: 100%;
    overflow: hidden;
    font-family: Arial, sans-serif;
    background-color: #121212;
    background-image: none;
    color: #fff;
}

/* =========================
   HEADER FIJO
========================= */
header.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
}

/* =========================
   CONTENEDOR DEL IFRAME
========================= */
.content-wrapper {
    position: absolute;
    top: 70px;
    bottom: 0;
    left: 0;
    right: 0;
    overflow: hidden;
}

/* =========================
   IFRAME PRINCIPAL
========================= */
iframe#main-frame {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

:root {
    --player-h: 80px;
    --btn-gap: 10px;
}

/* =========================
   FOOTER: REPRODUCTOR
========================= */
.player-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: var(--player-h);
    background: #1a1a1a;
    border-top: 2px solid #0078d7;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.4);
    z-index: 9999;
    transition: transform 0.35s cubic-bezier(.2,.9,.2,1);
    transform: translateY(0);
    overflow: hidden;
}

.player-footer.hidden {
    transform: translateY(calc(var(--player-h) + 8px));
    pointer-events: none;
}

.player-footer iframe {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

/* =========================
   BOTÓN FLOTANTE
========================= */
.footer-toggle {
    position: fixed;
    right: 15px;
    bottom: calc(var(--player-h) + var(--btn-gap));
    background: #0078d7;
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 18px;
    cursor: pointer;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: bottom 0.35s cubic-bezier(.2,.9,.2,1), transform 0.25s ease;
    box-shadow: 0 6px 18px rgba(0,0,0,0.35);
}

.footer-toggle.attached {
    bottom: calc(var(--btn-gap));
}

/* ❌ ROTACIÓN ELIMINADA PARA NO INVERTIR LA FLECHA */
/* .footer-toggle.attached i {
    transform: rotate(180deg);
} */

.footer-toggle:active {
    transform: scale(0.96);
}

.footer-toggle i {
    transition: transform 0.25s ease;
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 600px) {
    :root {
        --player-h: 72px;
        --btn-gap: 8px;
    }

    .footer-toggle {
        width: 36px;
        height: 36px;
        font-size: 16px;
        right: 10px;
    }
}

/* =========================
   AJUSTE DE CONTENIDO
========================= */
.content-wrapper.with-player {
    padding-bottom: var(--player-h);
}

.content-wrapper.no-player {
    padding-bottom: 0;
}