/* =========================================================
   OFFRAMP HERO BANNER v0.1.4
   Scoped front-end styles. No global Elementor/WooCommerce selectors.
   ========================================================= */

.offramp-hero-banner {
    position: relative;
    width: 100%;
    max-width: 100%;
    height: clamp(620px, 53vw, 860px);
    margin: 0;
    padding: 0;
    overflow: hidden;
    background: #000;
    isolation: isolate;
    touch-action: pan-y;
}

.offramp-hero-banner__slides {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.offramp-hero-banner__slide {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .8s ease, visibility .8s ease;
    z-index: 1;
}

.offramp-hero-banner__slide.is-active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    z-index: 2;
}

/*
 * Strong selector + !important protects Cover behavior from theme/Elementor
 * rules such as img { height:auto; }.
 */
.offramp-hero-banner img.offramp-hero-banner__media,
.offramp-hero-banner video.offramp-hero-banner__media {
    position: absolute !important;
    inset: 0 !important;
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    min-width: 100% !important;
    min-height: 100% !important;
    max-width: none !important;
    max-height: none !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    object-fit: cover !important;
    object-position: var(--offramp-focus-x, 50%) var(--offramp-focus-y, 50%) !important;
    background: #000;
}

/*
 * Video slides use an explicit poster image layer behind the <video> element.
 * Browsers do not reliably repaint the native video poster after a video has
 * already played once and is later rewound during carousel navigation. The
 * explicit poster therefore remains the guaranteed loading/fallback visual on
 * first load and every manual/automatic return to the video slide.
 */
.offramp-hero-banner__poster,
.offramp-hero-banner__image {
    z-index: 1;
}

.offramp-hero-banner__video {
    z-index: 2;
    opacity: 0;
    transition: opacity .18s ease;
}

/* Reveal the video only after the browser confirms real playback. */
.offramp-hero-banner__video.is-playing {
    opacity: 1;
}

.offramp-hero-banner__shade {
    position: absolute;
    inset: 0;
    z-index: 3;
    pointer-events: none;
    background: linear-gradient(
        to bottom,
        rgba(0, 0, 0, .10) 0%,
        rgba(0, 0, 0, .035) 42%,
        rgba(0, 0, 0, .16) 100%
    );
}

.offramp-hero-banner__content {
    position: absolute;
    left: 50%;
    top: 56%;
    transform: translate(-50%, -50%);
    z-index: 5;
    width: min(900px, 82%);
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #fff;
    text-align: center;
    pointer-events: none;
}

.offramp-hero-banner__title {
    margin: 0;
    color: #fff;
    font-size: clamp(42px, 4.3vw, 82px);
    line-height: .95;
    font-weight: 600;
    letter-spacing: -.035em;
    text-transform: none;
    text-shadow:
        0 2px 8px rgba(0, 0, 0, .62),
        0 5px 24px rgba(0, 0, 0, .48),
        0 0 2px rgba(0, 0, 0, .30);
}

.offramp-hero-banner__subtitle {
    margin-top: 18px;
    color: #fff;
    font-size: clamp(19px, 2vw, 34px);
    line-height: 1.15;
    font-weight: 400;
    letter-spacing: -.015em;
    text-shadow:
        0 2px 8px rgba(0, 0, 0, .66),
        0 4px 20px rgba(0, 0, 0, .46),
        0 0 2px rgba(0, 0, 0, .28);
}

.offramp-hero-banner__subtitle.is-italic {
    font-style: italic;
    font-weight: 300;
}

.offramp-hero-banner__button {
    pointer-events: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 150px;
    height: 44px;
    margin-top: 28px;
    padding: 0 28px;
    border: 1px solid rgba(255, 255, 255, .90);
    border-radius: 0;
    background: rgba(0, 0, 0, .18);
    color: #fff !important;
    font-size: 13px;
    line-height: 1;
    font-weight: 600;
    letter-spacing: .12em;
    text-decoration: none !important;
    text-shadow: 0 2px 7px rgba(0, 0, 0, .55);
    transition: background .22s ease, color .22s ease, border-color .22s ease;
}

.offramp-hero-banner__button:hover,
.offramp-hero-banner__button:focus {
    background: #fff;
    color: #000 !important;
    border-color: #fff;
    text-decoration: none !important;
    text-shadow: none;
}

/* Keep the existing square frame; replace the old arrow glyph with a flat SVG chevron. */
.offramp-hero-banner__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, .55);
    border-radius: 0;
    background: rgba(0, 0, 0, .15);
    color: #fff;
    cursor: pointer;
    transition: background .2s ease, border-color .2s ease;
}

.offramp-hero-banner__arrow svg {
    display: block;
    width: 24px;
    height: 24px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.55;
    stroke-linecap: square;
    stroke-linejoin: miter;
}

.offramp-hero-banner__arrow:hover,
.offramp-hero-banner__arrow:focus {
    background: rgba(0, 0, 0, .46);
    border-color: rgba(255, 255, 255, .95);
    outline: none;
}

.offramp-hero-banner__arrow--prev {
    left: 20px;
}

.offramp-hero-banner__arrow--next {
    right: 20px;
}

.offramp-hero-banner__dots {
    position: absolute;
    left: 50%;
    bottom: 18px;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 8px;
}

.offramp-hero-banner__dot {
    display: block;
    width: 7px;
    height: 7px;
    margin: 0;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, .9);
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
    transition: background .2s ease, transform .2s ease;
}

.offramp-hero-banner__dot.is-active {
    background: #fff;
    transform: scale(1.12);
}

@media (max-width: 1024px) {
    .offramp-hero-banner {
        height: clamp(540px, 68vw, 700px);
    }

    .offramp-hero-banner__content {
        top: 57%;
        width: 86%;
    }

    .offramp-hero-banner__title {
        font-size: clamp(38px, 6vw, 62px);
    }

    .offramp-hero-banner__subtitle {
        font-size: clamp(18px, 2.8vw, 28px);
    }
}

@media (max-width: 767px) {
    .offramp-hero-banner {
        height: clamp(500px, 74vh, 690px);
    }

    .offramp-hero-banner img.offramp-hero-banner__media,
    .offramp-hero-banner video.offramp-hero-banner__media {
        width: 100% !important;
        height: 100% !important;
        max-width: none !important;
        max-height: none !important;
        object-fit: cover !important;
        object-position: var(--offramp-focus-mobile-x, 50%) var(--offramp-focus-mobile-y, 50%) !important;
    }

    .offramp-hero-banner__content {
        top: 56%;
        width: 86%;
    }

    .offramp-hero-banner__title {
        font-size: clamp(34px, 10.5vw, 50px);
        line-height: .98;
    }

    .offramp-hero-banner__subtitle {
        margin-top: 15px;
        max-width: 92%;
        font-size: clamp(17px, 5vw, 23px);
        line-height: 1.18;
    }

    .offramp-hero-banner__button {
        min-width: 136px;
        height: 42px;
        margin-top: 22px;
        padding: 0 22px;
        font-size: 12px;
    }

    .offramp-hero-banner__arrow {
        display: none;
    }

    .offramp-hero-banner__dots {
        bottom: 15px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .offramp-hero-banner__slide,
    .offramp-hero-banner__video {
        transition: none;
    }
}
