#cartelera-player {
    --cp-ms: 1200ms;
    position: fixed;
    top: 0; right: 0; bottom: 0; left: 0;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
    background: #000;
    cursor: none;
    z-index: 999;
}

.cp-capa {
    position: absolute;
    top: 0; right: 0; bottom: 0; left: 0;
    opacity: 0;
    pointer-events: none;
    will-change: opacity, transform;
}
.cp-capa.cp-arriba { z-index: 2; }

.cp-media {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: #000;
}

/* transición: solo la capa entrante anima, encima de la actual */
.cp-capa.cp-entra {
    transition: opacity var(--cp-ms) ease,
                transform var(--cp-ms) cubic-bezier(.22, .61, .36, 1),
                filter var(--cp-ms) ease;
}
.cp-capa[data-fx="fade"]  { opacity: 0; }
.cp-capa[data-fx="corte"] { opacity: 0; }
.cp-capa[data-fx="slide"] { opacity: 1; transform: translateX(100%); }
.cp-capa[data-fx="zoom"]  { opacity: 0; transform: scale(1.18); }
.cp-capa[data-fx="blur"]  { opacity: 0; transform: scale(1.06); filter: blur(24px); }

.cp-capa.cp-visible,
.cp-capa.cp-visible[data-fx] { opacity: 1; transform: none; filter: none; }

/* sin contenido */
#cp-vacio {
    position: absolute;
    top: 0; right: 0; bottom: 0; left: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3;
    color: #fff;
    font: 300 28px/1.4 'Segoe UI', sans-serif;
    text-align: center;
    padding: 0 8vw;
}
#cp-vacio.cp-vacio-on { display: -webkit-flex; display: flex; -webkit-flex-direction: column; flex-direction: column; }
#cp-vacio p { margin: 0; }
.cp-vacio-logo { max-width: 40vw; max-height: 30vh; margin-bottom: 4vh; }

#cartelera-toast {
    position: absolute;
    right: 24px;
    bottom: 24px;
    z-index: 4;
    background: #f8cc25;
    color: #111;
    font: 700 19px/1 'Segoe UI', sans-serif;
    padding: 16px 28px;
    border-radius: 10px;
    box-shadow: 0 6px 16px rgba(0, 0, 0, .4);
    opacity: 0;
    transform: translateX(40px);
    transition: opacity .4s ease, transform .4s ease;
    pointer-events: none;
}
#cartelera-toast.cp-toast-on { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
    #cartelera-player { --cp-ms: 400ms; }
    .cp-capa[data-fx="slide"], .cp-capa[data-fx="zoom"], .cp-capa[data-fx="blur"] { transform: none; filter: none; opacity: 0; }
}

#cp-hint {
    position: absolute;
    left: 50%;
    top: 28px;                /* arriba al centro: el cintillo y los widgets ocupan las esquinas y la parte inferior */
    transform: translateX(-50%);
    z-index: 7;
    background: rgba(0, 0, 0, .72);
    color: #fff;
    font: 600 20px/1 'Segoe UI', sans-serif;
    padding: 14px 26px;
    border-radius: 999px;
}
#cp-hint[hidden] { display: none; }
