.gallery-main-section {
    display: flex;
    flex-direction: row;
    box-shadow: 0px 10px 30px 10px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    height: 90vh;
}

.gallery-img {
    will-change: flex, filter;
    flex: 1;
    background-size: cover;
    background-repeat: no-repeat;
    filter: brightness(0.8);
    transition: flex 0.5s ease, filter 0.7s ease;
    text-align: center;
    display: grid;
    justify-items: center;
    align-content: center;
    padding: 5px;
}

.gallery-img p {
    opacity: 0;
    color: #fff;
    transition: opacity 0.8s ease;
    filter: brightness(1.5);
    background: rgba(0, 0, 0, 0.3);
    /* Fondo semi-transparente */
    backdrop-filter: brightness(0.5) blur(2px);
    /* Desenfoca el fondo detrás del elemento */
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    /* Bordes redondeados opcionales */
    margin: 0;
    padding: 10px;
    width: 70%;
}

.gallery-img:first-of-type {
    background-image: url('/images/gallery-section/img6.jpg');
}

.gallery-img:nth-of-type(2) {
    background-image: url('/images/gallery-section/img12.jpg');
}

.gallery-img:nth-of-type(3) {
    background-image: url('/images/gallery-section/img9.jpg');
}

.gallery-img:nth-of-type(4) {
    background-image: url('/images/gallery-section/img4.jpg');
}

.gallery-img:nth-of-type(5) {
    background-image: url('/images/gallery-section/img5.jpg');
}

.gallery-img:nth-of-type(6) {
    background-image: url('/images/gallery-section/img2.jpg');
}

.gallery-img:nth-of-type(7) {
    background-image: url('/images/gallery-section/img13.jpg');
}


.gallery-img:hover p {
    opacity: 1;
}

.gallery-main-section:has(.gallery-img:hover) .gallery-img {
    filter: brightness(0.4);
}

.gallery-main-section:has(.gallery-img:hover) .gallery-img:hover {
    flex: 4;
    box-shadow: -20px 0px 30px -10px rgba(0, 0, 0, 0.7), 20px 0px 30px -10px rgba(0, 0, 0, 0.7);
    z-index: 2;
    filter: brightness(0.9);
}

/* Responsive Tablets */
@media(641px <= width <= 1023px) {
    .gallery-main-section {
        flex-direction: column;
        height: 200vh;
    }
}

/* Responsive Smarthphones */
@media(320px <=width <=640px) {
    .gallery-main-section {
        flex-direction: column;
        height: 200vh;
    }

    .gallery-img {
        width: 100%;
        flex: 1;
    }

    /*
    .gallery-img:hover{
        flex: calc(80%);
    }*/
    .gallery-img p {
        font-size: 18px;
    }

    .gallery-main-section:has(.gallery-img:hover) .gallery-img:hover {
        flex: 2;
    }
}

@media(320px <=width <=640px) and (orientation: landscape) {
    .gallery-main-section {
        height: 10vh;
    }

    .gallery-img {
        width: 100%;
        flex: calc(20%);
    }
}