/* ================================================================
   EEA Hero Widget — Isolated Styles
   Modes: single image | slider (Swiper)
   ================================================================ */

.eea-hero {
    --eea-hero-navy:    #080872;
    --eea-hero-navy-dk: #050554;
    --eea-hero-gold:    #C7A73E;
    --eea-hero-gold-lt: #d9bd5a;
    --eea-hero-white:   #ffffff;
    --eea-hero-ease:    cubic-bezier(.2, .8, .2, 1);

    position: relative;
    width: 100%;
    overflow: hidden;
    color: var(--eea-hero-white);
    font-family: 'Montserrat', 'Poppins', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
    -webkit-font-smoothing: antialiased;
    isolation: isolate;
    min-height: 86vh;
    background: var(--eea-hero-navy-dk);
}

.eea-hero,
.eea-hero *,
.eea-hero *::before,
.eea-hero *::after {
    box-sizing: border-box;
}

/* ================================================================
   FULL-WIDTH BREAKOUT
   Forces the hero edge-to-edge regardless of parent container padding.
   Targets BOTH the Elementor wrapper (via prefix_class) AND the hero
   element directly (via render-time class) — belt + suspenders.
   ================================================================ */

/* Strip ALL paddings/margins from Elementor's wrappers around the hero */
.eea-hero-fw-yes,
.elementor-widget.eea-hero-fw-yes,
.eea-hero-fw-yes > .elementor-widget-container {
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: visible !important;
}

/* The hero itself escapes any remaining parent constraint */
.eea-hero--fullwidth,
.eea-hero-fw-yes .eea-hero {
    width: 100vw !important;
    max-width: 100vw !important;
    margin-left: calc(50% - 50vw) !important;
    margin-right: calc(50% - 50vw) !important;
}

/* Prevent the parent page from showing a horizontal scrollbar */
body {
    overflow-x: clip;
    overflow-x: hidden; /* fallback */
}

/* Strip overflow/padding from ANY Elementor ancestor wrapping the full-width hero.
   Uses :has() (modern browsers); JS handles fallback for older ones. */
.elementor-section:has(.eea-hero--fullwidth),
.elementor-container:has(.eea-hero--fullwidth),
.elementor-row:has(.eea-hero--fullwidth),
.elementor-column:has(.eea-hero--fullwidth),
.elementor-widget-wrap:has(.eea-hero--fullwidth),
.elementor-column-wrap:has(.eea-hero--fullwidth),
.e-con:has(.eea-hero--fullwidth),
.e-con-inner:has(.eea-hero--fullwidth) {
    overflow: visible !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    max-width: 100% !important;
    width: 100% !important;
}

.eea-hero p {
    margin: 0;
}

/* ================================================================
   SWIPER WRAPPER  (always wraps slides, even in single mode)
   ================================================================ */
.eea-hero__swiper {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: inherit;
    z-index: 1;
}

.eea-hero--single .eea-hero__swiper .swiper-wrapper {
    transform: none !important;
    display: block;
    height: 100%;
}

/* ================================================================
   SLIDE
   ================================================================ */
.eea-hero__slide {
    position: relative;
    width: 100%;
    min-height: inherit;
    overflow: hidden;
    display: flex !important;
    align-items: stretch;
    color: var(--eea-hero-white);
}

.eea-hero__picture {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    display: block;
    overflow: hidden;
}

.eea-hero__bg {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    max-width: none !important;
    object-fit: cover;
    object-position: center center;
    z-index: 0;
    transform-origin: center;
    will-change: transform;
    display: block;
}

.eea-hero__overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(180deg, rgba(8, 8, 114, 0.55) 0%, rgba(5, 5, 84, 0.85) 100%);
    pointer-events: none;
}

.eea-hero__overlay::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(40% 60% at 80% 20%, rgba(199, 167, 62, 0.18), transparent 60%),
        radial-gradient(40% 60% at 20% 80%, rgba(199, 167, 62, 0.10), transparent 65%);
    pointer-events: none;
}

/* ================================================================
   GOLD CORNER ACCENTS  (optional decorative frame)
   ================================================================ */
.eea-hero--corners .eea-hero__slide::before,
.eea-hero--corners .eea-hero__slide::after {
    content: "";
    position: absolute;
    width: 64px;
    height: 64px;
    z-index: 4;
    pointer-events: none;
    opacity: .85;
}

.eea-hero--corners .eea-hero__slide::before {
    top: 32px;
    left: 32px;
    border-top: 2px solid var(--eea-hero-gold);
    border-left: 2px solid var(--eea-hero-gold);
}

.eea-hero--corners .eea-hero__slide::after {
    bottom: 32px;
    right: 32px;
    border-bottom: 2px solid var(--eea-hero-gold);
    border-right: 2px solid var(--eea-hero-gold);
}

/* ================================================================
   KEN BURNS  (slow zoom on background while slide is active)
   ================================================================ */
.eea-hero--kenburns .eea-hero__bg {
    transform: scale(1.02);
    transition: transform 8s linear;
}

.eea-hero--kenburns .swiper-slide-active .eea-hero__bg,
.eea-hero--single.eea-hero--kenburns .eea-hero__bg {
    transform: scale(1.12);
}

/* ================================================================
   INNER LAYOUT
   ================================================================ */
.eea-hero__inner {
    position: relative;
    z-index: 3;
    width: 100%;
    display: flex;
    align-items: center;
    padding: 120px 32px 100px;
    min-height: inherit;
}

.eea-hero__content {
    width: 100%;
    max-width: 840px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.eea-hero__slide--align-left  .eea-hero__content { margin: 0 auto 0 0; text-align: left;  }
.eea-hero__slide--align-right .eea-hero__content { margin: 0 0 0 auto; text-align: right; }
.eea-hero__slide--align-center .eea-hero__content { margin: 0 auto; text-align: center; align-items: center; }
.eea-hero__slide--align-left  .eea-hero__content { align-items: flex-start; }
.eea-hero__slide--align-right .eea-hero__content { align-items: flex-end; }

/* ================================================================
   EYEBROW  (small uppercase line with horizontal rules)
   ================================================================ */
.eea-hero__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 16px;
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 4px;
    text-transform: uppercase;
    color: var(--eea-hero-gold);
}

.eea-hero__eyebrow-line {
    display: inline-block;
    width: 36px;
    height: 1px;
    background: var(--eea-hero-gold);
    opacity: .7;
}

.eea-hero__slide--align-left .eea-hero__eyebrow .eea-hero__eyebrow-line:first-child,
.eea-hero__slide--align-right .eea-hero__eyebrow .eea-hero__eyebrow-line:last-child {
    display: none;
}

/* ================================================================
   HEADINGS
   ================================================================ */
.eea-hero__heading {
    font-family: 'Baskervville', 'GFS Didot', Georgia, serif;
    font-size: clamp(34px, 5.6vw, 64px);
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: 0.5px;
    margin: 0;
    color: var(--eea-hero-white);
    text-shadow: 0 6px 24px rgba(0,0,0,0.18);
}

.eea-hero__heading span {
    color: var(--eea-hero-gold);
    font-style: italic;
    position: relative;
}

.eea-hero__heading span::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -6px;
    height: 3px;
    background: var(--eea-hero-gold);
    border-radius: 3px;
    opacity: .85;
    transform: scaleX(0);
    transform-origin: left center;
    animation: eea-hero-underline 1.2s var(--eea-hero-ease) .8s forwards;
}

@keyframes eea-hero-underline {
    to { transform: scaleX(1); }
}

.eea-hero__sub {
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--eea-hero-white);
    opacity: 0.92;
    margin: 0;
}

.eea-hero__tag {
    font-size: 17px;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.82);
    max-width: 640px;
    margin: 0;
}

.eea-hero__slide--align-center .eea-hero__tag { margin: 0 auto; }
.eea-hero__slide--align-right .eea-hero__tag { margin: 0 0 0 auto; }

/* ================================================================
   BUTTONS
   ================================================================ */
.eea-hero__buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 12px;
}

.eea-hero__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 34px;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 13px;
    letter-spacing: 1.6px;
    text-transform: uppercase;
    border: 2px solid transparent;
    border-radius: 999px;
    cursor: pointer;
    text-decoration: none !important;
    position: relative;
    overflow: hidden;
    isolation: isolate;
    transition: background .3s var(--eea-hero-ease), color .3s var(--eea-hero-ease), border-color .3s var(--eea-hero-ease), transform .3s var(--eea-hero-ease), box-shadow .3s var(--eea-hero-ease);
}

.eea-hero__btn svg {
    width: 14px;
    height: 14px;
    transition: transform .3s var(--eea-hero-ease);
    flex-shrink: 0;
}

.eea-hero__btn:hover {
    transform: translateY(-2px);
}

.eea-hero__btn:hover svg {
    transform: translateX(4px);
}

/* Primary */
.eea-hero__btn--primary {
    background: var(--eea-hero-gold);
    color: var(--eea-hero-navy);
    border-color: var(--eea-hero-gold);
    box-shadow: 0 12px 30px rgba(199, 167, 62, 0.28);
}

.eea-hero__btn--primary:hover {
    background: var(--eea-hero-white);
    color: var(--eea-hero-navy);
    border-color: var(--eea-hero-white);
    box-shadow: 0 16px 36px rgba(255, 255, 255, 0.25);
}

/* Secondary */
.eea-hero__btn--secondary {
    background: transparent;
    color: var(--eea-hero-white);
    border-color: rgba(255,255,255,0.7);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.eea-hero__btn--secondary:hover {
    background: var(--eea-hero-white);
    color: var(--eea-hero-navy);
    border-color: var(--eea-hero-white);
}

/* ================================================================
   ENTRY ANIMATIONS  (staggered fade-in-up per element)
   Default = visible. Animations only run once JS has marked the hero
   as ready (so the content remains visible if scripts never load,
   like in Elementor's editor preview).
   ================================================================ */
.eea-hero__content [data-anim] {
    opacity: 1;
    transform: none;
}

.eea-hero--js-ready .eea-hero__content [data-anim] {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity .8s var(--eea-hero-ease), transform .8s var(--eea-hero-ease);
}

.eea-hero--js-ready.eea-hero--single .eea-hero__content [data-anim],
.eea-hero--js-ready .swiper-slide-active .eea-hero__content [data-anim],
.eea-hero--js-ready .eea-hero__slide.is-active .eea-hero__content [data-anim] {
    opacity: 1;
    transform: translateY(0);
}

.eea-hero__content [data-anim="0"] { transition-delay: .15s; }
.eea-hero__content [data-anim="1"] { transition-delay: .30s; }
.eea-hero__content [data-anim="2"] { transition-delay: .45s; }
.eea-hero__content [data-anim="3"] { transition-delay: .60s; }
.eea-hero__content [data-anim="4"] { transition-delay: .75s; }

/* ================================================================
   ARROWS
   ================================================================ */
.eea-hero__arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.10);
    border: 1.5px solid rgba(255, 255, 255, 0.35);
    color: var(--eea-hero-white);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 5;
    transition: all .3s var(--eea-hero-ease);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    appearance: none;
    -webkit-appearance: none;
}

.eea-hero__arrow svg {
    width: 20px;
    height: 20px;
    transition: transform .3s var(--eea-hero-ease);
}

.eea-hero__arrow--prev { left: 24px; }
.eea-hero__arrow--next { right: 24px; }

.eea-hero__arrow:hover {
    background: var(--eea-hero-gold);
    border-color: var(--eea-hero-gold);
    color: var(--eea-hero-navy);
}

.eea-hero__arrow--prev:hover svg { transform: translateX(-3px); }
.eea-hero__arrow--next:hover svg { transform: translateX(3px); }

.eea-hero__arrow.swiper-button-disabled {
    opacity: 0.35;
    cursor: default;
    pointer-events: none;
}

/* ================================================================
   PAGINATION DOTS
   ================================================================ */
.eea-hero__pagination {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 28px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    z-index: 5;
}

.eea-hero__pagination .swiper-pagination-bullet {
    width: 36px;
    height: 4px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.35);
    opacity: 1;
    margin: 0 !important;
    transition: all .3s var(--eea-hero-ease);
    cursor: pointer;
    border: 0;
    appearance: none;
}

.eea-hero__pagination .swiper-pagination-bullet:hover {
    background: rgba(255, 255, 255, 0.6);
}

.eea-hero__pagination .swiper-pagination-bullet-active {
    background: var(--eea-hero-gold);
    width: 56px;
}

/* ================================================================
   AUTOPLAY PROGRESS BAR
   ================================================================ */
.eea-hero__progress {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: rgba(255, 255, 255, 0.10);
    z-index: 5;
    overflow: hidden;
}

.eea-hero__progress-bar {
    display: block;
    width: 0;
    height: 100%;
    background: var(--eea-hero-gold);
    transition: width 0s linear;
}

.eea-hero__progress-bar.is-running {
    width: 100%;
    transition: width var(--eea-hero-progress-duration, 5500ms) linear;
}

/* ================================================================
   SCROLL INDICATOR
   ================================================================ */
.eea-hero__scroll {
    position: absolute;
    bottom: 60px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    z-index: 4;
    pointer-events: none;
}

.eea-hero__scroll-line {
    width: 1.5px;
    height: 50px;
    background: linear-gradient(to bottom, transparent, var(--eea-hero-gold));
    position: relative;
    overflow: hidden;
}

.eea-hero__scroll-line::after {
    content: "";
    position: absolute;
    top: -50%;
    left: 0;
    width: 100%;
    height: 50%;
    background: var(--eea-hero-gold);
    animation: eea-hero-scroll 2.2s var(--eea-hero-ease) infinite;
}

@keyframes eea-hero-scroll {
    0%   { top: -50%; opacity: 0; }
    30%  { opacity: 1; }
    100% { top: 100%; opacity: 0; }
}

.eea-hero__scroll-text {
    font-family: 'Montserrat', sans-serif;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--eea-hero-gold);
}

/* ================================================================
   ELEMENTOR / THEME OVERRIDE GUARDS
   ================================================================ */
.elementor-page .eea-hero,
.e-con .eea-hero,
.elementor-widget-container .eea-hero {
    color: var(--eea-hero-white) !important;
}

.elementor-page .eea-hero a,
.e-con .eea-hero a {
    text-decoration: none !important;
}

/* ================================================================
   RESPONSIVE
   ================================================================ */
@media (max-width: 1024px) {
    .eea-hero__arrow {
        width: 44px;
        height: 44px;
    }
    .eea-hero__arrow--prev { left: 16px; }
    .eea-hero__arrow--next { right: 16px; }

    .eea-hero--corners .eea-hero__slide::before,
    .eea-hero--corners .eea-hero__slide::after {
        width: 48px;
        height: 48px;
    }
    .eea-hero--corners .eea-hero__slide::before { top: 20px; left: 20px; }
    .eea-hero--corners .eea-hero__slide::after  { bottom: 20px; right: 20px; }
}

@media (max-width: 768px) {
    .eea-hero__inner {
        padding: 80px 20px 80px;
    }
    .eea-hero__heading {
        font-size: clamp(28px, 8vw, 40px);
    }
    .eea-hero__sub {
        font-size: 13px;
        letter-spacing: 1.5px;
    }
    .eea-hero__tag {
        font-size: 15px;
    }
    .eea-hero__buttons {
        width: 100%;
        flex-direction: column;
    }
    .eea-hero__btn {
        width: 100%;
        padding: 14px 24px;
    }
    .eea-hero__arrow {
        width: 38px;
        height: 38px;
        bottom: 20px;
        top: auto;
        transform: none;
    }
    .eea-hero__arrow--prev { left: calc(50% - 54px); }
    .eea-hero__arrow--next { right: calc(50% - 54px); }

    .eea-hero__pagination { bottom: 78px; }

    .eea-hero__scroll { display: none; }

    .eea-hero--corners .eea-hero__slide::before,
    .eea-hero--corners .eea-hero__slide::after {
        width: 36px;
        height: 36px;
    }
    .eea-hero--corners .eea-hero__slide::before { top: 14px; left: 14px; }
    .eea-hero--corners .eea-hero__slide::after  { bottom: 14px; right: 14px; }

    /* Ensure mobile center alignment when slide is set to center */
    .eea-hero__slide--align-center .eea-hero__content {
        align-items: center;
        text-align: center;
    }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .eea-hero,
    .eea-hero *,
    .eea-hero *::before,
    .eea-hero *::after {
        animation: none !important;
        transition: none !important;
    }
    .eea-hero--kenburns .eea-hero__bg {
        transform: none !important;
    }
}
