/* section-video.css */

.video-section__media {
    position: relative;
    padding-bottom: 56.25%;
}

.video-section__media .placeholder {
    width: 100%;
    height: 100%;
    background-color: rgb(var(--color-image-background));
    position: absolute;
    top: 0;
    left: 0;
}

.video-section__media .video-section__cover {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
}

.video-section__media.deferred-media:after {
    content: none;
}

.video-section__media iframe {
    border: 0;
}

.video-section__poster,
.video-section__media iframe,
.video-section__media video {
    position: absolute;
    width: 100%;
    height: 100%;
}

.video-section__title-wrapper {
    margin-bottom: 30px;
}

@media (max-width: 959px) {
    .video-section__title-wrapper {
        margin-bottom: 20px;
    }
}

/* -------- Controls toggle (ONLY hide when setting is OFF) -------- */
video-section[data-show-controls="false"] video::-webkit-media-controls,
video-section[data-show-controls="false"] video::-webkit-media-controls-enclosure,
video-section[data-show-controls="false"] video::-webkit-media-controls-panel {
    display: none !important;
}

/* -------- Full-width click-to-play padding/margin fix -------- */
/* Remove side padding on the section wrapper in full-width mode */
.video-section:not(.page-width) {
    padding-left: 0 !important;
    padding-right: 0 !important;
    max-width: none !important;
    width: 100% !important;
}

/* Force the media to true full-bleed even if parents have gutters */
.video-section:not(.page-width) .video-section__media {
    width: 100vw !important;
    max-width: 100vw !important;
    left: 50%;
    transform: translateX(-50%);
}

/* Keep poster + loaded media aligned (prevents “shift” on click) */
.video-section:not(.page-width) .video-section__poster,
.video-section:not(.page-width) .video-section__media iframe,
.video-section:not(.page-width) .video-section__media video {
    width: 100vw !important;
    max-width: 100vw !important;
    left: 50%;
    transform: translateX(-50%);
}

/* Avoid tiny horizontal scroll from 100vw rounding */
html,
body {
    overflow-x: hidden;
}