.gallery {
    overflow: hidden;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background: black;
}

.galleryContainer {
    display: flex;
    width: 50%;
}

.gallerySlide {
    height: 50vh;
    flex: 1;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    position: relative;
    transition: all 0.5s linear;
    cursor: pointer;
    opacity: 0.7;
}

.gallerySlide h3 {
    position: absolute;
    top: 20px;
    left: 20px;
    color: #fff;
    opacity: 0;
}

.gallerySlide.active {
    flex: 10;
    opacity: 1;
}

.gallerySlide.active h3 {
    opacity: 5;
    transition: opacity 0.3s ease-in 0.5s;
}

@media screen and (max-width: 768px) {
    .galleryContainer {
        flex-flow: column;
        height: 90vh;
        width: 80%;
    }
}