:root {
    --player-primary-color: #9333ea;
    --player-primary-color-hover: #a855f7;
    --player-secondry-color: #ffffff;
    --shadow-color: rgba(228, 211, 233, 0.551); /* default fallback */
}
#vidstack-plyr {
    position: relative;
}
.custom-player {
    aspect-ratio: 16/9;
    position: relative; /* anchor absolute gesture layers */
    font-family: "Plus Jakarta Sans", sans-serif;
}
.custom-center-play,
.custom-controls {
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* Show on hover */
.main-player:hover .custom-center-play,
.main-player:hover .custom-controls {
    opacity: 1;
}

/* Show when paused (added via JS class) */
.player-paused .custom-center-play,
.player-paused .custom-controls {
    opacity: 1 !important;
    pointer-events: auto;
}

.player-custom-svg {
    fill: var(--player-secondry-color);
    width: 22px !important;
    height: 22px !important;
}

.player-custom-svg path {
    fill: var(--player-secondry-color);
}

/* Force visibility for dev */
media-caption-button,
media-settings-menu,
media-menu-button {
    display: inline-flex !important;
    visibility: visible !important;
    opacity: 1 !important;
}

/* Center Play Button */
.custom-center-play {
    position: absolute;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
    pointer-events: none;
}

.customer-logo {
    position: absolute;
    top: 16px;
}

.customer-logo.top-right {
    right: 16px !important;
}

.customer-logo.top-left {
    left: 16px !important;
}

.customer-logo.bottom-left {
    bottom: 70px;
    top: auto !important;
    left: 16px !important;
}

.customer-logo.bottom-right {
    bottom: 70px;
    top: auto !important;
    right: 16px !important;
}

.customer-logo img {
    /* width: 100px;
    max-height: 25px; */
    /* width: min(var(--logo-size, 128px), 35%); */

    width: auto;
    max-height: 1.8em;
}

.center-play-button {
    pointer-events: all;
    width: 4rem;
    height: 4rem;
    border-radius: 50%;
    background-color: var(--player-primary-color);
    color: var(--player-secondry-color);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background 0.3s;
}
.center-play-button .player-custom-svg {
    width: 35px !important;
    height: 35px !important;
}

.center-play-button:hover {
    background-color: color-mix(
        in srgb,
        var(--player-primary-color) 50%,
        transparent
    );
    border-radius: 50% !important;
}

/* Bottom Controls Bar */
.custom-controls {
    position: absolute;
    bottom: 20px;
    /* width: 96%;
    right: 2%; */
    width: auto;
    /* width: 95%; */
    margin: auto;
    left: 0 !important;
    right: 0 !important;
    background-color: var(--player-primary-color);
    color: var(--player-secondry-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0px 16px;
    border-radius: 14px;
    gap: 0;
    z-index: 10;
    font-family: sans-serif;
    /* height: auto; */
    height: 40px;
    align-content: center;
    left: 2.5% !important;
    right: 2.5% !important;
}

.mobile .custom-controls {
    padding: 5px 16px;
}

/* .squarespace-damask .mobile .custom-controls {
    padding: 0 !important;
} */

/* Clip only horizontal overflow so off-screen panel doesn't peek,
     but keep vertical visible for the volume slider. */
.custom-controls {
    overflow-x: initial;
    overflow-y: visible;
}
@supports (overflow: clip) {
    .custom-controls {
        overflow-x: visible;
    }
}
/* :where(media-time-slider [part~="track-progress"]) {
    background-color: var(--player-secondry-color);
} */
.left-controls,
.right-controls {
    display: flex;
    align-items: center;
    /* gap: 12px; */
    /* justify-content: center; */
    justify-content: flex-end;
}

media-time-slider {
    flex-grow: 1;
    max-width: 100%;
    height: auto;
}

.time-display {
    font-size: 14px;
    font-weight: 600 !important;
    color: var(--player-secondry-color);
}

.skippz-logo-button {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    height: 28px;
    width: 70px;
    display: flex;
    align-items: center;
    /* new */
    /* margin-left: 5px; */
}

.skippz-logo-button svg {
    width: 115px;
    height: auto;
    fill: var(--player-secondry-color);
}

/* Optional: Add focus outline styling */
media-player [data-focus] {
    box-shadow: 0 0 0 3px var(--player-primary-color);
}

.custom-player-icons {
    width: 20px;
    height: 20px;
    max-width: unset;
}

/* 1) Make the container a positioning context */
.volume-control {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 2) Absolutely position the slider above (or beside) the button */
.volume-slider-wrapper {
    position: absolute;
    bottom: 100%;
    left: 0%;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.15s ease-in-out;
    height: 110px;
    border-radius: 8px;
    background: #0000009e !important;
    padding-top: 15px;
    padding-bottom: 20px;
    display: flex;
    justify-content: center;
    width: 38px;
}

/* 3) On hover over the container, show the slider */
/* .volume-control:hover .volume-slider-wrapper,
.volume-slider-wrapper :hover {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
} */

.volume-control:has(media-mute-button[data-hover]) .volume-slider-wrapper,
.volume-slider-wrapper:hover {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
}

/* Only show volume slider on hover when media-menu is NOT open */
.right-controls:has(media-menu[data-open]) .volume-slider-wrapper {
    opacity: 0;
    visibility: hidden;
}

/* 4) (Optional) style the track/thumb if you like */
.volume-slider-wrapper {
    --media-range-track-height: 4px;
    --media-range-thumb-size: 1.2rem;
    --media-range-track-background: rgba(255, 255, 255, 0.3);
    --media-range-thumb-background: #fff;
}

.right-controls-wrapper {
    display: flex;
    /* grid-template-columns: 1fr 1fr 1fr 1fr 1fr 2fr; */
    align-items: center;
    justify-content: flex-end;
    align-content: center;
    gap: 2px;
    padding-left: 10px;
}
/* Ensure controls stack above bar background */
.right-controls {
    position: relative;
    z-index: 15;
}
.main-controllers {
    position: relative;
    z-index: 15;
    /* new */
    margin-right: 5px;
}
/* Settings dropdown should appear on top */
.custom-controls [data-media-menu-items] {
    z-index: 30;
}
/* Volume popover above controls */
.volume-slider-wrapper {
    z-index: 20;
}
.custom-controls-on-pause {
    position: absolute;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
    opacity: 0;
    transform: scale(0.95);
    transform-origin: center;
    transition:
        opacity 300ms ease,
        transform 300ms ease;
    z-index: 10;
}

/* Show when paused or ended */
media-player[data-paused] .custom-controls-on-pause,
media-player[data-ended] .custom-controls-on-pause {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
}

/* Optional: hide again when playing */
media-player:not([data-can-play]) .custom-controls-on-pause,
media-player:not([data-can-load]) .custom-controls-on-pause,
media-player:not([data-duration-loaded]) .custom-controls-on-pause,
media-player:not([data-can-seek]) .custom-controls-on-pause,
media-player:not([data-duration-loaded]) .custom-controls-on-pause,
media-player[data-ended] .custom-controls-on-pause,
media-player[data-playing] .custom-controls-on-pause {
    opacity: 0;
    transform: scale(0.95);
    pointer-events: none;
}

media-gesture[action="toggle:paused"],
media-gesture[action="toggle:fullscreen"] {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 8; /* above video, below controls */
    pointer-events: auto;
    touch-action: manipulation;
}

media-gesture[action="seek:-10"] {
    position: absolute;
    top: 0;
    left: 0;
    width: 25%;
    height: 100%;
    z-index: 8;
    pointer-events: auto;
    touch-action: manipulation;
}

media-gesture[action="seek:10"] {
    position: absolute;
    top: 0;
    right: 0;
    width: 25%;
    height: 100%;
    z-index: 8;
    pointer-events: auto;
    touch-action: manipulation;
}
[role="button"]:hover {
    border-radius: 10px;
    padding: 0px !important;
}
#media-menu-1 {
    background: #0000009e !important;
}
:where(media-menu:not([data-submenu]) > [data-media-menu-items]) {
    background-color: #0000009e !important;
}
:where(media-player [data-media-slider] [part="thumb"]) {
    opacity: 1 !important;
    background-color: var(--player-secondry-color) !important;
    border-radius: 50%;
    width: 14px;
    height: 14px;
    box-shadow: unset;
    /* box-shadow: 0 0 0 2px #ffffff66; */
    transition: box-shadow 0.3s ease;
}
.plyr-time {
    display: flex;
    align-items: center;
    gap: 4px;
}
.main-controllers {
    display: flex;
    width: 100%;
    align-items: center;
    /* padding-right: 35px; */
    gap: 5px;
}
/* Hide by default (on all devices) */
.mobile-switch-01,
.mobile-switch-02 {
    position: relative;
    display: none;
    cursor: pointer;
    pointer-events: auto;
}

:where(media-menu:not([data-submenu]) > [data-media-menu-items]) {
    /* right: 0; */
    right: -30px;
}

/* default captions offset */
.custom-player media-captions {
    bottom: 50px !important;
    transition: opacity 0.3s ease;
}
.custom-player media-captions::part(captions) {
    bottom: 50px !important;
    transition: opacity 0.3s ease;
}

/* override when controls are hidden */
.custom-player.controls-hidden media-captions,
.custom-player.controls-hidden media-captions::part(captions) {
    bottom: 0 !important;
    transition: opacity 0.5s ease;
}

:where(
    media-menu[data-submenu] > [data-media-menu-button][aria-expanded="true"]
) {
    background-color: transparent;
}
:where(media-player [data-media-button]) {
    width: 30px;
    height: 30px;
}

.custom-controls.hide {
    opacity: 0 !important;
    pointer-events: none;
}

/* controller bra hide when player not ready */
media-player:not([data-can-play]) .custom-controls,
media-player:not([data-can-seek]) .custom-controls,
media-player:not([data-duration-loaded]) .custom-controls,
media-player:not([data-can-load]) .custom-controls {
    opacity: 0 !important;
    pointer-events: none;
}

/* mobile styles */

.mobile .center-play-button {
    width: 4rem;
    height: 4rem;
}
/* .mobile .custom-controls {
    height: 40px;
    bottom: 10px;
    left: 2%;
} */
.mobile .player-custom-svg {
    width: 22px !important;
    height: 22px !important;
}
.mobile .center-play-button .player-custom-svg {
    width: 35px !important;
    height: 35px !important;
}
.mobile .skippz-logo-button img {
    width: 60px !important;
    height: auto !important;
}

/* .mobile .custom-controls {
    overflow: hidden;
} */

.mobile .volume-slider-wrapper {
    height: 90px;
    padding-top: 5px;
    width: 30px;
}
.mobile .main-controllers {
    margin-top: -5px;
}

.squarespace-damask .mobile .main-controllers,
.squarespace-damask .mobile .right-controls {
    width: 95%;
}

.mobile .main-controllers,
.mobile .right-controls {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    /* both panels are side by side in “logical” space */
    transform: translateX(0);
    transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform;
    backface-visibility: hidden;
    padding: 0px 15px;
    /* padding-right: 30px; */
}

/* by default right-controls sits off to the right */
.mobile .right-controls {
    transform: translateX(100%);
}

/* when we add .show-right on the parent… */
.mobile .custom-controls.show-right .main-controllers {
    transform: translateX(-100%);
}
.mobile .custom-controls.show-right .right-controls {
    transform: translateX(0);
    gap: 10px;
    /* margin-top: 3px; */
}

.mobile .right-controls-wrapper {
    gap: 5px !important;
    /* new */
    padding: 0 !important;
    /* margin-top: 2px; */
    /* gap: 15px; */
}

.right-controls-wrapper {
    /* new */
    padding: 0 !important;
}

/* keep your toggle buttons where they are */
.mobile .mobile-switch-01 {
    align-items: center;
    display: block;
    margin-top: 0; /* align with bar vertically */
    align-self: center;
    margin-left: 10px;
}
.mobile-switch-02 {
    /* margin-top: 5px; */
    /* display: none; */
    align-self: center;
}
/* Make sure toggles are always clickable */
.mobile-switch-01,
.mobile-switch-02 {
    /* position: relative; */
    z-index: 25;
    /* pointer-events: auto; */
}

.mobile media-time-slider {
    height: 48px;
}

.mobile .skippz-logo-button {
    display: none;
}
media-tooltip {
    display: none !important;
}

/* video poster play */
.poster-video-overlay {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none; /* controls still clickable */
    z-index: 2; /* above image poster, below your custom controls */
}

media-player[data-started] .poster-video-overlay {
    display: none !important;
}

/* Compact, right-aligned controls bar: shrink to fit visible controls */
.custom-controls.align-right {
    /* shrink to content width and stick to bottom-right */
    width: max-content !important;
    max-width: calc(100% - 32px);
    margin: 0 !important;
    left: auto !important;
    right: 2.5% !important;
    justify-content: flex-end; /* only right controls remain */
}

/* Hide the main controllers (timeline, play, etc.) in compact mode */
.custom-controls.align-right .main-controllers {
    display: none !important;
}

/* Ensure right-controls don't expand to full width on mobile rules */
.custom-player .custom-controls.align-right .right-controls {
    position: relative !important;
    width: auto !important;
    transform: none !important;
}

/* If .show-right was set from mobile toggle logic, neutralize it */
.custom-player.mobile .custom-controls.align-right.show-right .right-controls,
.custom-player.mobile .custom-controls.align-right .right-controls {
    transform: none !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    /* new */
    padding: 0 !important;
}

/* Hide mobile panel toggles in compact mode */
.custom-controls.align-right .mobile-switch-01,
.custom-controls.align-right .mobile-switch-02 {
    display: none;
}

.mobile-switch-toggle-img-wrapper {
    display: flex;
    /* width: 50px; */
    justify-content: flex-end;
    align-items: center; /* vertically center icons */
    height: 30px; /* inner bar height: 40px - 10px vertical padding */
    line-height: 0; /* remove inline-image baseline gap */
    /* gap: 5px; */
}

.mobile-switch-toggle-img-wrapper img {
    width: 18px;
    height: 18px;
    display: block;
}
.mobile-switch-toggle-img-wrapper svg {
    display: block;
}

:where(media-time-slider [part~="track-progress"]) {
    background-color: var(--player-secondry-color);
    opacity: 0.5;
}

:where(media-time-slider [part~="track"]) {
    background-color: var(--player-secondry-color);
    opacity: 0.25;
}
:where(media-time-slider [part~="track-fill"]) {
    background-color: var(--player-secondry-color);
}

/* --- Mobile slide + fade behavior: hide as soon as slide starts --- */
.custom-player.mobile .main-controllers,
.custom-player.mobile .right-controls {
    /* Fade-only for smoother perf on mobiles */
    transition: opacity 180ms ease-out;
    will-change: opacity;
    backface-visibility: hidden;
}

/* Default: left/main is visible, right is off-screen and hidden */
.custom-player.mobile .main-controllers {
    opacity: 1;
    pointer-events: auto;
}
.custom-player.mobile .right-controls {
    opacity: 0;
    pointer-events: none;
}

/* When sliding to the right panel, start fading left immediately */
.custom-player.mobile .custom-controls.show-right .main-controllers {
    opacity: 0;
    pointer-events: none;
}
.custom-player.mobile .custom-controls.show-right .right-controls {
    opacity: 1;
    pointer-events: auto;
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
    .custom-player.mobile .main-controllers,
    .custom-player.mobile .right-controls {
        transition: none;
    }
}

/* --- Fade-only mode on mobile: remove slide transforms --- */
.custom-player.mobile .main-controllers,
.custom-player.mobile .right-controls {
    transform: none !important;
}

.mobile :where(media-player [data-media-slider] [slot="preview"]) {
    bottom: calc(100% + var(--media-slider-preview-gap, 2px));
}

.custom-media-player-icons {
    -webkit-tap-highlight-color: transparent;
    /* display: inline-flex; */
    justify-content: center;
    align-items: center;
    user-select: none;
    border-radius: var(--media-button-border-radius, 2px);
    margin: 0;
    padding: 7px 4.5px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    /* width: 20px;
    height: 20px; */
}
.custom-media-player-icons:hover {
    background: var(--media-button-hover-bg, rgb(255 255 255 / 0.2));
}

@supports (-webkit-touch-callout: none) {
    /* iOS-specific styles */
    .media-quality-menu-button,
    .volume-slider-wrapper {
        display: block !important;
    }
}

/* desktop only — hide on mobile if you like */
@media (min-width: 768px) {
    .custom-controls {
        opacity: 1;
        transition:
            opacity 0.25s cubic-bezier(0.22, 1, 0.36, 1),
            visibility 0.25s cubic-bezier(0.22, 1, 0.36, 1);
    }

    /* .custom-controls.hide {
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
    } */
}

@media only screen and (max-width: 768px) {
    :where(media-menu[data-popup] > [data-media-menu-items]) {
        top: 22vh;
    }
    .center-play-button {
        width: 4rem;
        height: 4rem;
    }
    .custom-controls {
        height: 40px;
        bottom: 20px;
        left: 2%;
    }
    .player-custom-svg {
        width: 22px !important;
        height: 22px !important;
    }
    .center-play-button .player-custom-svg {
        width: 35px !important;
        height: 35px !important;
    }
    .skippz-logo-button img {
        width: 60px !important;
        height: auto !important;
    }
    /* .custom-controls {
        overflow: hidden;
    } */

    /* .main-controllers {
        margin-top: -5px;
    } */

    /* .main-controllers,
    .right-controls {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        transform: translateX(0);
        transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
        will-change: transform;
        backface-visibility: hidden;
        padding: 0px 10px;
    } */

    /* .right-controls {
        transform: translateX(100%);
    } */

    /* .custom-controls.show-right .main-controllers {
        transform: translateX(-100%);
    }
    .custom-controls.show-right .right-controls {
        transform: translateX(0);
        gap: 10px;
        margin-top: 3px;
    } */

    .right-controls-wrapper {
        gap: 5px !important;
    }

    /* .mobile-switch-01 {
        display: block;
        padding-right: 10px;
    } */
    /* .mobile-switch-02 {
        display: none;
    } */

    media-time-slider {
        height: 48px;
    }

    /* .skippz-logo-button {
        display: none;
    } */
    .mobile-switch-toggle-img-wrapper {
        gap: 0 !important;
    }

    /* .mobile-switch-02 {
        padding-bottom: 3px;
    } */

    .customer-logo img {
        /* width: 75px; */
        transform: scale(0.6);
        width: auto;
        max-height: 25px;
    }

    /* .customer-logo.bottom-right {
     right: 0px !important;
    }

    .customer-logo.bottom-left {
    left: 0px !important;
    }

    .customer-logo.top-right {
    right: 0px !important;
    }

    .customer-logo.top-left {
        left: 0px !important;
    } */

    .customer-logo.top-left img {
        transform-origin: top left;
    }
    .customer-logo.top-right img {
        transform-origin: top right;
    }
    .customer-logo.bottom-left img {
        transform-origin: bottom left;
    }
    .customer-logo.bottom-right img {
        transform-origin: bottom right;
    }

    /* .cta-button-wrapper.position-bottom-left , .cta-button-wrapper.position-bottom-right , .cta-button-wrapper.position-bottom-middle {
        height: 10% !important;
    } */

    .video-form-trigger-wrapper.position-center-right,
    .video-form-trigger-wrapper.position-center-left {
        height: 30% !important;
    }

    .video-form-trigger-wrapper.position-center-right,
    .video-form-trigger-wrapper.position-center-left {
        bottom: 45% !important;
    }
}
/* Show only on mobile devices (less than 768px) */
/* 1st: from 901px up to 1024px */
/* @media only screen and (min-width: 500px) and (max-width: 700px) {
    .custom-controls {
        bottom: 30px;
    }
} */

/* 2nd: from 776px up to 900px */
/* @media only screen and (min-width: 701px) and (max-width: 900px) {
    .custom-controls {
        bottom: 40px;
    }
} */

media-player.custom-player[data-picture-in-picture] .custom-controls,
media-player.custom-player[data-picture-in-picture] .custom-center-play {
    display: none !important;
}

/* Optional: ensure they show when not in PiP (adjust if your defaults differ) */
media-player.custom-player:not([data-picture-in-picture]) .custom-controls {
    display: flex;
}
media-player.custom-player:not([data-picture-in-picture]) .custom-center-play {
    display: flex;
}

/* Fallback: hide when inner video is in PiP (browsers supporting :picture-in-picture + :has) */
media-player.custom-player:has(video:picture-in-picture) .custom-controls,
media-player.custom-player:has(video:picture-in-picture) .custom-center-play {
    display: none !important;
}

.my-toggle-buttons {
    /* background-color: red !important; */
    gap: 2px !important;
    border-bottom: 1px solid hsla(0, 0%, 100%, 0.1);
    padding-bottom: 10px;
    margin-left: 1.5em;
}
.my-toggle-buttons label {
    border: none;
    box-shadow: unset;
    background: transparent !important;
    font-size: 1em;
}

.my-toggle-buttons label span {
    color: rgba(var(--gray-500), var(--tw-text-opacity, 1)) !important;
    font-size: 1em !important;
    padding: 0.2rem;
}

/* Active state: tune the custom color so Filament's bg-custom-600 applies */
.my-toggle-buttons #embedSection-on:checked + label {
    /* background-color: hsla(0, 0%, 100%, 0.05) !important; */
    color: rgba(var(--primary-400), var(--tw-text-opacity, 1)) !important;
    --tw-bg-opacity: 1 !important;
    background-color: rgba(var(--gray-50), var(--tw-bg-opacity, 1)) !important;
    /* border: 1px solid #f68e8e0d; */
}

.my-toggle-buttons #embedSection-on:checked + label span {
    color: rgba(var(--primary-600), var(--tw-text-opacity, 1)) !important;
}

.my-toggle-buttons #embedSection-on + label:hover {
    /* background-color: hsla(0, 0%, 100%, 0.05) !important; */
    color: rgba(var(--gray-700), var(--tw-text-opacity, 1)) !important;
    --tw-bg-opacity: 1 !important;
    background-color: rgba(var(--gray-50), var(--tw-bg-opacity, 1)) !important;
}

.my-toggle-buttons #embedSection-lightbox:checked + label {
    /* background-color: hsla(0, 0%, 100%, 0.05) !important; */
    color: rgba(var(--primary-400), var(--tw-text-opacity, 1)) !important;
    --tw-bg-opacity: 1 !important;
    background-color: rgba(var(--gray-50), var(--tw-bg-opacity, 1)) !important;
}

.my-toggle-buttons #embedSection-lightbox + label:hover {
    /* background-color: hsla(0, 0%, 100%, 0.05) !important; */
    color: rgba(var(--gray-700), var(--tw-text-opacity, 1)) !important;
    --tw-bg-opacity: 1 !important;
    background-color: rgba(var(--gray-50), var(--tw-bg-opacity, 1)) !important;
}

.my-toggle-buttons #embedSection-lightbox:checked + label span {
    color: rgba(var(--primary-600), var(--tw-text-opacity, 1)) !important;
}

.dark .my-toggle-buttons #embedSection-on:checked + label,
.dark .my-toggle-buttons #embedSection-lightbox:checked + label {
    background-color: hsla(0, 0%, 100%, 0.05) !important;
}

.dark .my-toggle-buttons #embedSection-on:checked + label span,
.dark .my-toggle-buttons #embedSection-lightbox:checked + label span {
    color: rgba(var(--primary-400), var(--tw-text-opacity, 1)) !important;
}

.dark .my-toggle-buttons #embedSection-on + label:hover,
.dark .my-toggle-buttons #embedSection-lightbox + label:hover {
    background-color: hsla(0, 0%, 100%, 0.05) !important;
}

.dark .my-toggle-buttons #embedSection-on:not(:checked) + label:hover span,
.dark
    .my-toggle-buttons
    #embedSection-lightbox:not(:checked)
    + label:hover
    span {
    color: rgb(228, 228, 231) !important;
}
/* Add this to your existing player.css file */

/* Enable Vidstack's default buffering indicator */
.custom-player media-buffering-indicator {
    position: absolute;
    inset: 0;
    z-index: 20;
    display: none; /* Hidden by default */
    align-items: center;
    justify-content: center;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s ease;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    margin: auto;
}

/* Show ONLY during buffering, waiting, or quality changes (not on initial load) */
.custom-player[data-started][data-buffering] media-buffering-indicator,
.custom-player[data-started][data-waiting] media-buffering-indicator,
.custom-player[data-quality-changing] media-buffering-indicator {
    display: flex !important;
    opacity: 1 !important;
}

/* Optional: Add backdrop for better visibility */
.custom-player[data-started][data-buffering] media-buffering-indicator::before,
.custom-player[data-started][data-waiting] media-buffering-indicator::before,
.custom-player[data-quality-changing] media-buffering-indicator::before {
    content: "";
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(2px);
}

/* Style the default Vidstack spinner */
.custom-player media-buffering-indicator [slot="buffering"] {
    width: 64px;
    height: 64px;
    border: 4px solid rgba(255, 255, 255, 0.2);
    border-top-color: var(--player-secondry-color, #fff);
    border-radius: 50%;
    animation: vidstack-spin 0.8s linear infinite;
    position: relative;
    z-index: 1;
}

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

/* Remove or update your existing custom buffering indicator */
.buffering-indicator {
    display: none !important; /* Hide custom indicator in favor of Vidstack's */
}

/* Show buffering indicator while media is not ready, or buffering. */
.custom-player:is(:not([data-can-play]), [data-waiting], :not([data-can-load]))
    media-buffering-indicator {
    display: flex !important;
    opacity: 1;
}

/* Ensure loader shows during quality switching */
.custom-player[data-quality-changing] media-buffering-indicator {
    display: flex !important;
    opacity: 1 !important;
}

/* Show loader during seeking as well (only after video has started) */
.custom-player[data-started][data-seeking] media-buffering-indicator {
    display: flex;
    opacity: 1;
}

/* Don't show loader on initial load or before playback starts */
.custom-player:not([data-started]) media-buffering-indicator {
    display: none !important;
    opacity: 0 !important;
}

media-buffering-indicator shadow-root {
    display: none !important;
}

/* Form Overlay Container */
.video-form-overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10001;
    border-radius: 1rem;
    top: 0 !important;

    /* NewChanges */

    -webkit-overflow-scrolling: touch; /* iOS momentum scrolling */
    touch-action: pan-y; /* Allow vertical scrolling */
}

/* Content Box */
.video-form-content {
    width: 100%;
    height: 100%;
    padding: 20px 55px;
    border-radius: 1rem;
    animation: slideIn 0.3s ease-out;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-content: center;
    flex-wrap: nowrap;
    max-width: 850px;
    overflow-y: scroll;
    scrollbar-width: none;
    -ms-overflow-style: none;

    /* NewChanges */

    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
    overscroll-behavior: contain; /* Prevent scroll chaining */
}

/* NewChanges */
.video-form-input,
.video-form-input:focus {
    touch-action: auto !important; /* Allow all touch interactions on inputs */
    -webkit-user-select: text !important;
    user-select: text !important;
}

/* Ensure form is above gestures on mobile */
.mobile-device .video-form-overlay {
    z-index: 10000 !important;
    position: fixed !important; /* Use fixed instead of absolute for better mobile behavior */
}

/* Disable gestures entirely when form is visible */
media-player[data-form-active] media-gesture {
    display: none !important;
    pointer-events: none !important;
    touch-action: none !important;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Title */
.video-form-title {
    color: white;
    font-size: 28px;
    font-weight: 600;
    text-align: center;
    line-height: 1.3;
    margin: 0px 0px 20px;
}

/* Form Fields Container */
.video-form-fields {
    margin-bottom: 12px;
}

/* Field Row */
.video-form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

/* Individual Field Wrapper */
.video-form-field {
    flex: 1;
    min-width: 0; /* Prevents flex item overflow */
}

/* Label */
.video-form-label {
    color: white;
    font-size: 14px;
    margin-bottom: 8px;
    display: block;
    font-weight: 500;
}

/* Input Field */
.video-form-input {
    width: 100%;
    padding: 6px 10px;
    border: none;
    background: white;
    color: #2d3748;
    font-size: 14px !important;
    box-sizing: border-box;
    outline: none;
    transition: box-shadow 0.2s ease;
    font-family: inherit;
    line-height: 1.5rem;
    padding: 0.5rem 0.75rem;
}

.video-form-input:focus {
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.3);
}

.video-form-input::placeholder {
    color: #a0aec0;
}

.video-form-input.error {
    border: 2px solid #ef4444 !important;
    animation: shake 0.3s ease;
}

/* Contact Number Input */
.iti {
    display: flex !important;
}

.iti__selected-dial-code {
    color: #2d3748 !important;
    font-size: 14px !important;
}

.iti__country-name {
    color: #999 !important;
}

@keyframes shake {
    0%,
    100% {
        transform: translateX(0);
    }
    25% {
        transform: translateX(-5px);
    }
    75% {
        transform: translateX(5px);
    }
}

/* Submit Button */
.video-form-submit {
    width: 100%;
    padding: 10px;
    border: none;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 10px;
    transition:
        opacity 0.2s ease,
        transform 0.1s ease;
    font-family: inherit;
    font-weight: 400;
}

.video-form-submit:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.video-form-submit:active {
    transform: translateY(0);
}

/* Skip Button */
.video-form-skip {
    display: block;
    width: 100%;
    text-align: center;
    background: transparent;
    border: none;
    color: white;
    font-size: 14px !important;
    font-weight: 600;
    margin-top: 20px;
    transition: opacity 0.2s ease;
    font-weight: inherit;
}

.video-form-skip:hover {
    opacity: 0.7;
}

/* Bottom Content */
.video-form-bottom {
    color: white;
    font-size: 13px;
    text-align: center;
    line-height: 1.5;
    margin-top: 10px;
    margin-bottom: 10px;
}

/* Trigger Button Wrapper with Positions */
.video-form-trigger-wrapper {
    position: absolute;
    z-index: 1001;
}

/* Position Classes */
.video-form-trigger-wrapper.position-top-left {
    top: 20px;
    left: 20px;
}

.video-form-trigger-wrapper.position-top-middle {
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
}

.video-form-trigger-wrapper.position-top-right {
    top: 20px;
    right: 20px;
}

.video-form-trigger-wrapper.position-bottom-left {
    bottom: 70px;
    left: 20px;
}

.video-form-trigger-wrapper.position-bottom-middle {
    bottom: 70px;
    left: 50%;
    transform: translateX(-50%);
}

.video-form-trigger-wrapper.position-bottom-right {
    bottom: 70px;
    right: 20px;
}
.video-form-trigger-wrapper.position-center-left {
    bottom: auto;
    left: 20px;
}

.video-form-trigger-wrapper.position-center-right {
    bottom: auto;
    right: 20px;
}

html body .video-form-trigger-button.size-small {
    font-size: 14px !important;
}

html body .video-form-trigger-button.size-medium {
    font-size: 16px !important;
}

html body .video-form-trigger-button.size-large {
    font-size: 18px !important;
}

/* .video-form-trigger-wrapper.position-middle-center {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
} */

/* Trigger Button (appears before form) */
.video-form-trigger-button {
    padding: 10px 15px;
    border: none;
    /* font-size: 16px; */
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
    white-space: nowrap;
    -moz-animation: pulse1 2s infinite;
    -webkit-animation: pulse1 2s infinite;
    animation: pulse1 2s infinite;
    width: auto !important;
    height: auto !important;
}

.video-form-trigger-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(0, 0, 0, 0.3);
}

.video-form-trigger-button:active {
    transform: translateY(0);
}

@keyframes pulse1 {
    0% {
        box-shadow: 0 0 10px rgba(228, 211, 233, 0.551);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(88, 120, 243, 0);
    }
    100% {
        box-shadow: 0 0 0 50px rgba(88, 120, 243, 0);
    }
}

/* Responsive adjustments for button positions */
@media (max-width: 768px) {
    .video-form-trigger-wrapper.position-top-left,
    .video-form-trigger-wrapper.position-top-right {
        top: 10px;
    }

    .video-form-trigger-wrapper.position-top-left {
        left: 10px;
    }

    .video-form-trigger-wrapper.position-top-right {
        right: 10px;
    }

    .video-form-trigger-button {
        padding: 12px 24px;
        font-size: 16px;
    }

    html body .video-form-trigger-button.size-small {
        padding: 8px 16px;
    }

    html body .video-form-trigger-button.size-medium {
        padding: 10px 20px;
    }

    html body .video-form-trigger-button.size-large {
        padding: 12px 24px;
    }
}

/* CTA overlay styles end here */
/* CTA Overlay Base */
.video-cta-overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    border-radius: 1rem;
    top: 0 !important;

    /* NewChanges */

    -webkit-overflow-scrolling: touch; /* iOS momentum scrolling */
    touch-action: pan-y; /* Allow vertical scrolling */
}

/* CTA Content Wrapper */
.video-cta-content {
    padding: 20px 55px;

    width: 100%;
    border-radius: 1rem;
    animation: slideIn 0.3s ease-out;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-content: center;
    align-items: center;
    flex-wrap: nowrap;
    max-width: 850px;
    overflow: hidden;

    max-width: 100%;
    max-height: 100%;
    height: 100%;
    /* height: -webkit-fill-available; */

    -webkit-overflow-scrolling: touch;
    touch-action: pan-y;
    overscroll-behavior: contain; /* Prevent scroll chaining */
}

/* Image CTA */
.cta-image-wrapper {
    padding: 20px;
}

.cta-image-wrapper .cta-link {
    height: 100%;
    display: flex;
    align-content: center;
    justify-content: center;
    flex-wrap: wrap;
}

.video-cta-image {
    /* object-fit: contain; */
    cursor: pointer;
    transition: transform 0.3s ease;
    border-radius: 8px;
    width: auto;
    height: auto;
    max-height: 90%;
    max-width: 90%;
}

.video-cta-image:hover {
    transform: scale(1.05);
}

/* Button CTA */
.cta-button-wrapper {
    display: flex;
    position: absolute;
    pointer-events: auto;
    z-index: 1001;
    justify-content: flex-start;
    width: auto;
    height: auto;
    padding: 20px 0px;
    top: 0;
    overflow: visible; /* override the base style */
}

.cta-button-wrapper.position-top-right {
    right: 20px;
}

/* .cta-button-wrapper.position-top-middle {
    left: 50%;
    transform: translateX(-50%);
} */

.cta-button-wrapper.position-top-left {
    left: 20px;
}

.cta-button-wrapper.position-bottom-right {
    top: auto;
    bottom: 70px;
    right: 20px;
    padding: 0;
}

.cta-button-wrapper.position-bottom-left {
    top: auto;
    bottom: 70px;
    left: 20px;
    padding: 0;
}

.cta-button-wrapper.position-bottom-middle {
    top: auto;
    bottom: 70px;
    /* right: 20px; */
    padding: 0;
}

.cta-button-wrapper.position-center-left {
    top: auto;
    bottom: auto;
    left: 20px;
}

.cta-button-wrapper.position-center-right {
    top: auto;
    bottom: auto;
    right: 20px;
}

.video-cta-button {
    padding: 10px 15px;
    border: none;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
    text-decoration: none;
    white-space: nowrap;
    -moz-animation: pulse1 2s infinite;
    -webkit-animation: pulse1 2s infinite;
    animation: pulse1 2s infinite;
    height: auto !important;
    width: auto !important;
}

html body .video-cta-button.size-small {
    font-size: 14px !important;
    width: auto;
    height: auto;
}

html body .video-cta-button.size-medium {
    font-size: 16px !important;
}

html body .video-cta-button.size-large {
    font-size: 18px !important;
}

.video-cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 30px rgba(0, 0, 0, 0.3);
}

/* Text CTA */
.cta-text-wrapper {
    padding: 20px;
}

.video-cta-text {
    /* font-size: 32px !important; */
    font-size: 26px !important;
    font-weight: 500;
    text-decoration: none;
    text-align: center;
    transition: opacity 0.3s ease;
    cursor: pointer;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.video-cta-text:hover {
    opacity: 0.8;
}

/* Skip Button */
.video-cta-skip {
    position: absolute;
    bottom: 20px;
    right: 20px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    font-size: 14px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.video-cta-skip:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Disable player interactions when CTA is active */
media-player[data-cta-active] media-gesture {
    pointer-events: none !important;
}

/* mobile */

.mobile-device .video-form-field {
    margin-bottom: 8px;
}
.mobile-device .video-form-overlay {
    height: 100%;
    overflow: hidden;
}

.mobile-device .video-form-content {
    padding: 25px 15px;
    width: 90%;
    height: 100%;
    overflow-y: scroll;
    margin-top: 12px;
    justify-content: flex-start;
}

.mobile-device .video-form-title {
    font-size: 24px;
    margin-bottom: 15px;
}

.mobile-device .video-form-input {
    padding: 8px 14px;
}

.mobile-device .video-form-submit {
    padding: 9px;
    font-size: 15px;
    margin-bottom: 0;
}
.mobile-device .video-form-fields {
    margin-top: 10px;
}
.mobile-device .video-form-bottom {
    padding-bottom: 50px;
}

.mobile-device .video-form-row {
    flex-direction: column;
    gap: 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .video-form-content {
        padding: 30px 20px;
        width: 95%;
        height: 100%;
        overflow-y: scroll;
        margin-top: 55px !important;
        justify-content: flex-start;
    }

    .video-form-title {
        font-size: 24px;
        margin-bottom: 25px;
    }

    .video-form-row {
        flex-direction: column;
        gap: 0;
    }

    .video-form-field {
        margin-bottom: 15px;
    }

    .video-form-input {
        font-size: 16px; /* Prevents zoom on iOS */
    }
}

@media (max-width: 480px) {
    .video-form-field {
        margin-bottom: 8px;
    }
    .video-form-overlay {
        height: 100%;
        overflow: hidden;
    }

    .video-form-content {
        padding: 25px 15px;
        width: 85%;
        height: 100%;
        overflow-y: scroll;
        margin-top: 55px !important;
        justify-content: flex-start;
    }

    .video-form-title {
        font-size: 18px;
        margin-bottom: 15px;
    }

    .video-form-input {
        padding: 8px 14px;
    }

    .video-form-submit {
        padding: 9px;
        font-size: 15px;
        margin-bottom: 0;
    }
    .video-form-fields {
        margin-top: 10px;
    }
    .video-form-bottom {
        padding-bottom: 50px;
    }

    /* comment because issue in click ski-930 */
    /* .video-cta-content {
        height: 100%;
    } */

    .video-cta-image {
        max-width: 95%;
        max-height: 95%;
    }
    .cta-button-wrapper.position-top-left {
        padding: 10px 0px !important;
        left: 10px !important;
    }
    .cta-button-wrapper.position-top-right {
        padding: 10px 0px !important;
        right: 10px !important;
    }

    /* .cta-button-wrapper.position-bottom-left , .cta-button-wrapper.position-bottom-right , .cta-button-wrapper.position-bottom-middle {
        height: 10% !important;
    } */

    .video-form-trigger-wrapper.position-center-right,
    .video-form-trigger-wrapper.position-center-left {
        height: 30% !important;
    }

    .cta-button-wrapper.position-center-right.position-center-right,
    .cta-button-wrapper.position-center-right.position-center-left {
        bottom: -45% !important;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .video-cta-image {
        max-width: 95%;
        max-height: 95%;
    }

    /* .video-cta-button {
        padding: 12px 24px;
        font-size: 16px;
    } */

    html body .video-cta-button.size-small {
        padding: 8px 16px;
        width: auto;
        height: auto;
    }

    html body .video-cta-button.size-medium {
        padding: 10px 20px;
    }

    html body .video-cta-button.size-large {
        padding: 12px 24px;
    }

    .video-cta-text {
        font-size: 24px;
    }

    .cta-button-wrapper.position-top-right,
    .cta-button-wrapper.position-left {
        padding: 10px;
    }
}

/* Thank You Message - Inside Player */
.video-form-thankyou {
    position: absolute;
    top: 20px;
    right: 0;
    background: #ffffffcc;
    color: #404040;
    padding: 8px 12px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
    font-weight: 600;
    z-index: 10000;
    max-width: 400px;
    animation: slideInFromRight 0.4s ease-out forwards;
    overflow: hidden;
    z-index: 10000000000;
}

.video-form-thankyou-icon {
    width: 20px;
    height: 20px;
    fill: #404040;
}

/* Slide in from right */
@keyframes slideInFromRight {
    from {
        right: 0px;
        opacity: 0;
    }
    to {
        right: 20px;
        opacity: 1;
    }
}

/* Fade out and slide back to right */
.video-form-thankyou.fade-out {
    animation: slideOutToRight 0.4s ease-out forwards;
}

@keyframes slideOutToRight {
    from {
        right: 20px;
        opacity: 1;
    }
    to {
        right: -400px;
        opacity: 0;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .video-form-thankyou {
        top: 10px;
        max-width: calc(100% - 40px);
    }

    @keyframes slideInFromRight {
        from {
            right: -100%;
            opacity: 0;
        }
        to {
            right: 10px;
            opacity: 1;
        }
    }

    @keyframes slideOutToRight {
        from {
            right: 10px;
            opacity: 1;
        }
        to {
            right: -100%;
            opacity: 0;
        }
    }
}

.marketing-video-player .custom-controls,
.marketing-video-player.custom-controls.hide {
    opacity: 1 !important;
    display: flex !important;
    margin-bottom: -65px !important;
    width: 100% !important;
    left: 0 !important;
    pointer-events: all !important;
    max-width: unset !important;
}

.marketing-video-player {
    padding-bottom: 24px;
}

:where(media-player[aspect-ratio] media-outlet > shadow-root > *) {
    margin: 0 !important;
    max-width: unset !important;
    display: inline-block !important;
}

:where(media-poster [part="img"]) {
    margin: 0 !important;
}
