/* Container background video focus */
:is(.e-con, .e-con > .e-con-inner) > .elementor-background-video-container .elementor-background-video-hosted {
    object-position: var(--fl-video-focus-x, 50%) var(--fl-video-focus-y, 50%);
}

:is(.e-con, .e-con > .e-con-inner) > .elementor-background-video-container .elementor-background-video-embed {
    inset-inline-start: var(--fl-video-focus-x, 50%) !important;
    inset-block-start: var(--fl-video-focus-y, 50%) !important;
}

/* Overlay description */
.elementor-custom-embed-image-overlay:has(.fl-video-overlay-description) {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.elementor-custom-embed-image-overlay .fl-video-overlay-description {
    position: relative;
    z-index: 2;
    margin-top: auto;
    width: 100%;
    color: #fff;
    font-size: 16px;
    line-height: 1.35;
    text-align: left;
    padding: 16px 20px 20px;
    pointer-events: none;
}

.elementor-custom-embed-image-overlay .fl-video-overlay-description::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.55) 100%);
    z-index: -1;
    pointer-events: none;
}

.elementor-custom-embed-image-overlay:has(.fl-video-overlay-description) .elementor-custom-embed-play {
    position: absolute;
    inset: 0;
    margin: auto;
}

.fl-responsive-video__variant .elementor-wrapper {
    width: 100%;
}

.fl-video-fullscreen {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    box-sizing: border-box;
}

.fl-video-fullscreen__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.92);
}

.fl-video-fullscreen__dialog {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 96vw;
    max-height: 96vh;
}

.fl-video-fullscreen--landscape .fl-video-fullscreen__dialog {
    width: min(96vw, 1100px);
}

.fl-video-fullscreen--portrait .fl-video-fullscreen__dialog {
    width: min(92vw, 420px);
}

.fl-video-fullscreen__player {
    position: relative;
    width: 100%;
    background: #000;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
}

.fl-video-fullscreen--landscape .fl-video-fullscreen__player {
    max-height: 96vh;
}

.fl-video-fullscreen--portrait .fl-video-fullscreen__player {
    max-height: min(92vh, 860px);
}

.fl-video-fullscreen__player iframe,
.fl-video-fullscreen__player video {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    background: #000;
}

.fl-video-fullscreen__loader {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #000;
    color: #fff;
    font-size: 14px;
    letter-spacing: 0.02em;
}

.fl-video-fullscreen__loader::after {
    content: "";
    width: 28px;
    height: 28px;
    margin-left: 10px;
    border: 2px solid rgba(255, 255, 255, 0.25);
    border-top-color: #fff;
    border-radius: 50%;
    animation: fl-video-spin 0.8s linear infinite;
}

.fl-video-fullscreen__player.is-ready .fl-video-fullscreen__loader {
    display: none;
}

@keyframes fl-video-spin {
    to {
        transform: rotate(360deg);
    }
}

.fl-video-fullscreen__close {
    position: absolute;
    z-index: 3;
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

.fl-video-fullscreen--landscape .fl-video-fullscreen__close {
    top: -44px;
    right: 0;
}

.fl-video-fullscreen--portrait .fl-video-fullscreen__close {
    top: 12px;
    right: 12px;
    background: rgba(0, 0, 0, 0.45);
}

.fl-video-fullscreen__close:hover {
    background: rgba(0, 0, 0, 0.72);
}
