/* ================================================================
   HERO GASEX v3.1 FINAL
   Tipografía original + Overlay direccional + Botón mejorado
   ================================================================ */

   .wp-block-gasex-home-carousel.hero-gasex {

    --gasex-white: #ffffff;
    --gasex-dark: #1a1a1a;
    --gasex-accent: #0056b3; 
    --transition-smooth: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    --transition-fade: opacity 1.5s ease-in-out; 

    position: relative;
    width: 100%;
    min-height: 60vh;
    display: flex;
    align-items: center;
    overflow: hidden;
    background-color: var(--gasex-dark);
}

/* ================= BASE ================= */

.wp-block-gasex-home-carousel .hero-slider-main {
    position: relative;
    width: 100%;
    height: 100%;
    min-height: 60vh;
}

.wp-block-gasex-home-carousel .hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
    display: flex;
    align-items: center;
    z-index: 1;
    pointer-events: none;
}

.wp-block-gasex-home-carousel .hero-slide.is-active {
    opacity: 1;
    z-index: 2;
    pointer-events: auto;
}

/* ================= IMAGEN ================= */

.wp-block-gasex-home-carousel .hero-imagen-wrapper {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.wp-block-gasex-home-carousel .hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 20s linear;
}

.wp-block-gasex-home-carousel .hero-slide.is-active .hero-img {
    transform: scale(1.1);
}

/* ================= OVERLAY ================= */

.wp-block-gasex-home-carousel .hero-slide::before {
    content: "";
    position: absolute;
    top: 0;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

.wp-block-gasex-home-carousel .hero-slide.pos-left::before {
    left: 0;
    width: 55%;
    background: linear-gradient(
        to right,
        rgba(0,0,0,var(--overlay-strength, 0.6)),
        rgba(0,0,0,0.4),
        rgba(0,0,0,0)
    );
}

.wp-block-gasex-home-carousel .hero-slide.pos-right::before {
    right: 0;
    width: 100%;
    background: linear-gradient(
        to left,
        rgba(0,0,0,var(--overlay-strength, 0.6)),
        rgba(0,0,0,0.4),
        rgba(0,0,0,0)
    );
}

.wp-block-gasex-home-carousel .hero-slide.pos-center::before {
    left: 50%;
    transform: translateX(-50%);
    width: 70%;
    background: rgba(0,0,0,var(--overlay-strength, 0.6));
}

.wp-block-gasex-home-carousel .hero-slide.no-overlay::before {
    display: none !important;
}



/* ================= CONTENIDO ================= */

.wp-block-gasex-home-carousel .hero-contenido-wrapper {
    position: relative;
    z-index: 3;
    width: 100%;
    padding: 60px 0;
    color: var(--gasex-white);
}

.wp-block-gasex-home-carousel .hero-gasex-container {
    width: 100%;
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 25px;
    display: flex;
    flex-direction: column; 
}

.wp-block-gasex-home-carousel .hero-contenido {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.wp-block-gasex-home-carousel .hero-slide.is-active .hero-contenido {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.3s;
}



/* ================= TIPOGRAFÍA ================= */

.wp-block-gasex-home-carousel .hero-title {
    font-family: 'Montserrat', sans-serif;
    font-weight: 800;
    line-height: 1.08;
    margin-bottom: 22px;
    letter-spacing: -0.028em;
    text-shadow: 0 4px 20px rgba(0,0,0,0.5);
    font-size: 2.6rem;
}

.wp-block-gasex-home-carousel .hero-desc {
    font-size: 1.15rem;
    line-height: 1.6;
    margin-bottom: 30px;
    font-weight: 300;
    opacity: 0.9;
    max-width: 560px;
    text-shadow: 0 4px 20px rgba(0,0,0,0.5);
}






/* ================================================================
   ALINEACIÓN POR SLIDE
   ================================================================ */

.hero-slide.pos-left .hero-gasex-container {
    align-items: flex-start;
    text-align: left;
}

.hero-slide.pos-center .hero-gasex-container {
    align-items: center;
    text-align: center;
}

.hero-slide.pos-center .hero-contenido,
.hero-slide.pos-center .hero-desc {
    margin-left: auto;
    margin-right: auto;
}

.hero-slide.pos-right .hero-gasex-container {
    align-items: flex-end;
    text-align: right;
}

.hero-slide.pos-right .hero-desc {
    margin-left: auto;
}




/* ================= NAV ================= */

.wp-block-gasex-home-carousel .hero-gasex-nav {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.wp-block-gasex-home-carousel .nav-indicators {
    display: flex;
    gap: 12px;
}

.wp-block-gasex-home-carousel .nav-dot {
    width: 50px;
    height: 3px;
    background: rgba(255,255,255,0.25);
    border: none;
    cursor: pointer;
}

.wp-block-gasex-home-carousel .nav-dot.is-active {
    background: var(--gasex-white);
    transform: scaleX(1.2);
}


/* ================================================================
   EDITOR FIX
   ================================================================ */

.editor-preview .hero-slide {
    position: relative !important;
    opacity: 1 !important;
    visibility: visible !important;
    display: flex !important;
}

.editor-preview .hero-slider-main {
    height: auto;
    min-height: auto;
}

.block-editor-page .hero-gasex {
    position: relative !important;
    min-height: 450px;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.block-editor-page .hero-imagen-wrapper {
    position: absolute !important;
    inset: 0;
    z-index: 1;
}

.block-editor-page .hero-imagen-wrapper img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
}

.block-editor-page .hero-contenido-wrapper {
    position: relative !important;
    z-index: 3;
    width: 100%;
    min-height: 450px;
    display: flex;
    align-items: center;
}

.block-editor-page .hero-slide {
    position: relative !important;
    width: 100% !important;
    opacity: 1 !important;
    visibility: visible !important;
    display: flex !important;
}

.block-editor-page .hero-gasex-nav,
.block-editor-page .nav-indicators {
    display: none !important;
}

/* ================================================================
   RESPONSIVE
   ================================================================ */

   @media (min-width: 992px) {

    .wp-block-gasex-home-carousel .hero-title {
        font-size: 4.13rem;
    }

    .wp-block-gasex-home-carousel .hero-desc {
        font-size: 1.35rem;
    }
}


/* ================================================================
   MOBILE – SIEMPRE CENTRADO
   ================================================================ */

/* ================================================================
   MOBILE – SIEMPRE CENTRADO + JERARQUÍA AJUSTADA
   ================================================================ */

   @media (max-width: 768px) {

    .wp-block-gasex-home-carousel.hero-gasex,
    .wp-block-gasex-home-carousel .hero-slider-main {
        min-height: 80vh;
    }

    .hero-contenido-wrapper {
        padding: 80px 0 100px;
    }

    /* Centrado forzado */
    .hero-slide .hero-gasex-container {
        align-items: center !important;
        text-align: center !important;
    }

    .hero-slide .hero-contenido {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-slide .hero-desc {
        margin-left: auto !important;
        margin-right: auto !important;
    }

    /* Overlay centrado */
    .hero-slide::before {
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important;
        width: 100% !important;
        background: rgba(0,0,0,var(--overlay-strength,0.6)) !important;
    }

    /* Ajuste de escala móvil */
    .wp-block-gasex-home-carousel .hero-title.size-md {
        font-size: 2.6rem;
    }

    .wp-block-gasex-home-carousel .hero-slide.no-cta .hero-title.size-md {
        font-size: 2.9rem;
    }

    .wp-block-gasex-home-carousel .hero-desc {
        font-size: 1.1rem;
    }

    .wp-block-gasex-home-carousel .hero-slide.no-cta .hero-desc {
        font-size: 1.2rem;
    }

    /* Nav dots — 2 filas en mobile */
    .wp-block-gasex-home-carousel .hero-gasex-nav {
        bottom: 16px;
        width: 100%;
        left: 0;
        transform: none;
    }

    .wp-block-gasex-home-carousel .nav-indicators {
        flex-wrap: wrap;
        justify-content: center;
        gap: 8px;
        padding: 0 20px;
    }

    .wp-block-gasex-home-carousel .nav-dot {
        width: 32px;
    }
}

