.elementor-534 .elementor-element.elementor-element-21b8cf3{--display:flex;--min-height:500px;--gap:0px 0px;--row-gap:0px;--column-gap:0px;--overflow:hidden;--margin-top:0px;--margin-bottom:0px;--margin-left:0px;--margin-right:0px;--padding-top:0px;--padding-bottom:0px;--padding-left:0px;--padding-right:0px;}.elementor-534 .elementor-element.elementor-element-89c9413{border-radius:20px 20px 20px 20px;--image-border-radius:0px;--image-transition-duration:800ms;--content-text-align:center;--content-justify-content:center;--content-padding:20px;}.elementor-534 .elementor-element.elementor-element-89c9413 .e-gallery-image{filter:brightness( 100% ) contrast( 100% ) saturate( 100% ) blur( 0px ) hue-rotate( 0deg );}@media(max-width:1024px){.elementor-534 .elementor-element.elementor-element-21b8cf3{--min-height:320px;}}@media(max-width:767px){.elementor-534 .elementor-element.elementor-element-21b8cf3{--content-width:100%;--min-height:280px;--margin-top:0px;--margin-bottom:30px;--margin-left:0px;--margin-right:0px;--padding-top:0%;--padding-bottom:0%;--padding-left:0%;--padding-right:0%;}.elementor-534 .elementor-element.elementor-element-89c9413{border-radius:15px 15px 0px 0px;--content-padding:0px;}}/* Start custom CSS for gallery, class: .elementor-element-89c9413 */.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(n+5),
.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(n+6),
.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(n+7),
.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(n+8),
.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(n+9),
.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(n+10){ 
    display:none; 
}

.elementor-534 .elementor-element.elementor-element-89c9413,
.elementor-534 .elementor-element.elementor-element-89c9413 .e-con-inner{
    overflow: hidden !important;;
    height: auto !important; 
    min-height: 100%;
}

/* Configuración de la Grilla Mobile (1 arriba, 3 abajo) */
.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container {
    display: grid;
    /* Definimos 3 columnas iguales */
    grid-template-columns: 1fr 1fr 1fr; 
    /* Definimos explícitamente las alturas de las filas: 200px la primera, 120px la segunda */
    gap: 12px;
    height: auto !important;
}

/* Imagen 1: Ocupa todo el ancho de la primera fila */
.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(1) {
    grid-area: 1 / 1 / 2 / 4; /* Fila 1, columna 1 a 4 */
    height: 100% !important;
    min-height: 200px !important;
}

/* Imagen 2: Abajo Izquierda */
.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(2) {
    grid-area: 2 / 1 / 3 / 2;
    height: 100% !important;
    min-height: 100% !important;
    max-height: 70px !important;
}

/* Imagen 3: Abajo Centro */
.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(3) {
    grid-area: 2 / 2 / 3 / 3;
    height: 100% !important;
    min-height: 100% !important;
    max-height: 70px !important;
}

/* Imagen 4: Abajo Derecha (Faltaba definir su posición exacta) */
.elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(4) {
    grid-area: 2 / 3 / 3 / 4;
    height: 100% !important;
    min-height: 100% !important;
    max-height: 70px !important;
}


@media(min-width:768px){
    .elementor-534 .elementor-element.elementor-element-89c9413,
    .elementor-534 .elementor-element.elementor-element-89c9413 .e-con-inner{
        max-height: 450px !important; /* Restauramos tu restricción en desktop */
    }
    
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container.e-gallery-container {
        display: grid;
        grid-template-columns: repeat(5, 1fr);
        grid-template-rows: repeat(2, 1fr);
        grid-column-gap: 15px;
        grid-row-gap: 15px;
        max-height: 500px;
    }
    
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(1){
      grid-area: 1 / 1 / 3 / 4;
        min-height: 500px;
    }
    
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(2){
       grid-area: 1 / 4 / 2 / 6;
       max-height: 250px !important;
    }
    
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(3){
        grid-area: 2 / 4 / 3 / 5;
        max-height: 200px;
    }
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(4){
        grid-area: 2 / 5 / 3 / 6; 
        max-height: 200px;
    }
}

/* Ajustes intermedios que tenías (Tablets) */
@media (min-width: 768px) and (max-width: 1025px) {
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(1){
        max-height: 265px !important;
    }
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(2){
        max-height: 160px !important;
     }
}

@media (min-width: 1025px) and (max-width: 1366px) {
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(1){
        max-height: 390px !important;
    }
}

@media (min-width: 1367px){
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container .e-gallery-item:nth-child(2){
        min-height: 296px !important;
     }
}

/* Fix para animaciones en mobile */
@media (max-width: 767px){
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery-item,
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery-item img {
        opacity: 1 !important;
        transform: none !important;
        animation: none !important;
    }
    
    .elementor-534 .elementor-element.elementor-element-89c9413 .elementor-gallery__container.e-gallery-container {
            grid-template-rows: auto auto !important
    }
}/* End custom CSS */