.dspace-mask-gallery {
    overflow-x: hidden;
    background-color: #E6F5FA;
    display: flex;
    min-height: auto; 
    height: 100vh; 
    padding: 0;
    margin: 0;
    width: 100%;
    box-sizing: border-box;
}

.image-container {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    max-width: none;
    height: 50vh;
    gap: 10px;
    margin: 0 auto;
    padding: 0 10px;
    position: relative;
    margin-top: 50px;
    box-sizing: border-box;
}

.image-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    position: relative;
    transition: all 0.5s ease;
    overflow: hidden;
}

.image-wrapper:nth-child(1),
.image-wrapper:nth-child(5) {
    width: 22%;
    height: 115%;
}

.image-wrapper:nth-child(2),
.image-wrapper:nth-child(4) {
    width: 20%;
    height: 95%;
}

.image-wrapper:nth-child(3) {
    width: 20%;
    height: 80%;
}

.image-wrapper .masked-image {
    width: 100%;
    height: 100%;
    -webkit-mask-size: 100% 100%;
    mask-size: 100% 100%;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    object-fit: cover;
    transition: opacity 1s ease-in-out;
    cursor: pointer;
    position: absolute;
    opacity: 1;
}

.image-wrapper:hover {
    transform: scale(1.1);
    z-index: 10;
}

.image-wrapper.active {
    transform: scale(1.2);
    z-index: 10;
}

@media (max-width: 768px) {
    .image-container {
        height: 35vh;
        overflow: hidden;
        justify-content: flex-start;
        gap: 20px;
        padding: 0 20px;
        scroll-snap-type: x mandatory;
        scroll-behavior: smooth;
        -webkit-overflow-scrolling: touch;
    }
    
    .image-wrapper {
        flex: 0 0 calc(100% / 3);
        height: 100%;
        scroll-snap-align: center;
        width: auto !important;
    }
    
    .image-wrapper:nth-child(1),
    .image-wrapper:nth-child(5) {
        display: none;
    }
    
    .image-wrapper:nth-child(2),
    .image-wrapper:nth-child(3),
    .image-wrapper:nth-child(4) {
        display: flex;
        height: 100%;
        width: auto;
    }
}

@media (max-width: 480px) {
    .image-container {
        height: 30vh;
        gap: 15px;
    }
    
    .image-wrapper {
        flex: 0 0 calc(100% / 2);
    }
    
    .image-wrapper:nth-child(4) {
        display: none;
    }
}