.rys-bf[hidden] { display: none !important; }
.rys-bf {
    position: fixed; inset: 0; z-index: 999999;
    display: flex; align-items: center; justify-content: center;
    padding: 16px; opacity: 0; transition: opacity .25s ease;
}
.rys-bf.is-visible { opacity: 1; }
.rys-bf-open, .rys-bf-open body { overflow: hidden; }

.rys-bf__backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .75); cursor: pointer; }

.rys-bf__box {
    position: relative; width: 100%; max-width: 560px;
    background: #111; border-radius: 10px; overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, .5);
    transform: translateY(16px) scale(.97); transition: transform .25s ease;
}
.rys-bf.is-visible .rys-bf__box { transform: none; }

.rys-bf__media { display: block; line-height: 0; background: #000; }
.rys-bf__media video {
    display: block; width: 100%; height: auto;
    max-height: calc(100vh - 160px); max-height: calc(100dvh - 160px);
    object-fit: contain; pointer-events: none;
}

/* Selector reforzado + !important: el tema (Hello Elementor) aplica estilos globales a <button>. */
.rys-bf .rys-bf__box button.rys-bf__close {
    position: absolute !important; top: 10px !important; right: 10px !important; left: auto !important; z-index: 3 !important;
    display: flex !important; align-items: center !important; justify-content: center !important;
    width: 40px !important; height: 40px !important; min-width: 0 !important; min-height: 0 !important;
    margin: 0 !important; padding: 0 !important;
    border: 2px solid #fff !important; border-radius: 50% !important;
    background: #ffd000 !important; color: #000 !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .55) !important;
    font-size: 0 !important; line-height: 1 !important; text-transform: none !important;
    cursor: pointer !important; opacity: 1 !important;
    transition: transform .15s ease, background-color .15s ease, color .15s ease !important;
}
.rys-bf .rys-bf__box button.rys-bf__close svg { display: block !important; width: 18px !important; height: 18px !important; }
.rys-bf .rys-bf__box button.rys-bf__close:hover {
    background: #fff !important; color: #000 !important; border-color: #ffd000 !important; transform: scale(1.08);
}
.rys-bf .rys-bf__box button.rys-bf__close:focus { outline: none !important; }
.rys-bf .rys-bf__box button.rys-bf__close:focus-visible { outline: 3px solid #fff !important; outline-offset: 2px !important; }

.rys-bf .rys-bf__box button.rys-bf__play[hidden] { display: none !important; }
.rys-bf .rys-bf__box button.rys-bf__play {
    position: absolute !important; top: 50% !important; left: 50% !important; z-index: 2 !important;
    transform: translate(-50%, -50%) !important;
    display: flex !important; align-items: center !important; justify-content: center !important;
    width: 68px !important; height: 68px !important; margin: 0 !important; padding: 0 0 0 4px !important;
    border: 2px solid #fff !important; border-radius: 50% !important;
    background: #ffd000 !important; color: #000 !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, .55) !important; cursor: pointer !important;
}
.rys-bf .rys-bf__box button.rys-bf__play svg { display: block !important; width: 28px !important; height: 28px !important; }

.rys-bf__footer {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    flex-wrap: wrap; padding: 14px 18px;
}
.rys-bf__title { margin: 0; color: #fff; font-weight: 800; font-size: 18px; letter-spacing: .02em; }
.rys-bf__cta {
    display: inline-block; padding: 10px 22px; border-radius: 4px;
    background: #ffd000; color: #000 !important; font-weight: 800; font-size: 14px;
    letter-spacing: .05em; text-decoration: none !important; transition: background .2s;
}
.rys-bf__cta:hover, .rys-bf__cta:focus-visible { background: #fff; }

@media (max-width: 480px) {
    .rys-bf__footer { justify-content: center; text-align: center; }
    .rys-bf__cta { width: 100%; text-align: center; }
}
@media (prefers-reduced-motion: reduce) {
    .rys-bf, .rys-bf__box { transition: none; }
}
