/* Variant-specific video presentation. Original homepage styles are unaffected. */
.block-cover .item__media:has(.mks-home-bg-video) { overflow: hidden; position: relative; }
.block-cover .item__media .mks-home-bg-video { z-index:1; display:block; position:absolute; inset:0; width:100%; height:100%; object-fit:cover; opacity:0; transition: opacity .45s ease; }
.block-cover .item__media .mks-home-bg-video.mks-video-ready {opacity:1;}
.block-cover .item__media .mks-home-video-poster { display:block;width:100%;height:100%;object-fit:cover; }
/* The global theme applies 6.25rem margin to every element after .mks-block.
   Neutralize it for the inserted v3 section and handle balanced space here. */
.block-stats + .mks-home-video-section { margin-top: 0 !important; }
.mks-home-video-section { width: 100%; padding: 50px 20px; }
.mks-home-video-container { width:100%; max-width: 1080px; margin-inline:auto; }
.mks-home-video-player { width:100%; position:relative; aspect-ratio:16/9; background:#172320; overflow:hidden; }
.mks-home-video-player iframe { position:absolute; inset:0; width:100%;height:100%;border:0; }
.mks-video-launch { display:flex; justify-content:center;align-items:center; width:100%;height:100%;padding:0;cursor:pointer; background-size:cover;background-position:center;border:0; position:relative; }
.mks-video-launch::before {content:"";position:absolute;inset:0;background:rgba(0,0,0,.20)}
.mks-video-play { position:relative; display:grid;place-items:center; width:76px;height:76px; padding-left:5px; border-radius:100%; font-size:25px; color:white; background:rgba(0,0,0,.65);border:1px solid rgba(255,255,255,.65);transition:transform .2s, background .2s; }
.mks-video-launch:hover .mks-video-play,.mks-video-launch:focus-visible .mks-video-play {transform:scale(1.08);background:rgba(0,0,0,.85)}
.mks-home-video-unset { display:flex;align-items:center;justify-content:center;min-height:240px; padding:24px; background:#e8e8e5;color:#333;text-align:center; }
/* V4: the theme normally fixes the media column at 720px on desktop.
   A 16:9 iframe cannot fill that rectangle without letterboxing or cropping.
   Allow the column to adopt the real 16:9 height instead, so all of the
   original frame remains visible without bars. */
.block-txtmedia__media:has(.mks-home-video-inline) {
    min-width: 0;
    height: auto;
    max-height: none;
    align-self: center;
    display: block;
    overflow: hidden;
}
.block-txtmedia__media .mks-home-video-inline {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
}
.block-txtmedia__media .mks-home-video-inline iframe {
    width: 100%;
    height: 100%;
    inset: 0;
    transform: none;
    max-width: 100%;
    max-height: 100%;
}
/* No double gap between the inserted video and the next text/media block. */
.mks-home-video-section + .block-txtmedia {margin-top:0!important;}
@media(max-width:767px) { .mks-home-video-section {padding:24px 15px;} .mks-video-play {width:58px;height:58px;font-size:20px;} }
@media(prefers-reduced-motion:reduce){.mks-home-bg-video{display:none!important;}.block-cover .item__media .mks-home-video-poster{display:block!important;position:absolute;inset:0;width:100%;height:100%;object-fit:cover;}}

/* Autoplay presentation: YouTube handles the initial startup UI; hover interaction stays disabled. */
.mks-video-autoplay .mks-video-autoplay-host,
.mks-video-autoplay .mks-video-autoplay-host iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}
.mks-video-autoplay .mks-video-autoplay-host iframe {
    pointer-events: none !important;
    user-select: none;
}

/* Transparent interaction shield above the YouTube iframe.  `controls=0` does not
   prevent every YouTube hover overlay; this ensures the embedded player never
   receives pointer hover/click events at all. */
.mks-video-autoplay .mks-video-autoplay-shield {
    position: absolute;
    z-index: 4;
    inset: 0;
    background: transparent;
    pointer-events: auto;
    cursor: default;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
}
@media (prefers-reduced-motion: reduce) {
    .mks-video-autoplay .mks-video-autoplay-host { display: none; }
    }
