#gallery1 #links a img {
    width: 100%;
    height: auto;
}

#gallery1 #links a {
    display: block;
    box-sizing: border-box;
    padding-right: 15px;
    padding-bottom: 30px;
    transition: all 0.7s;
    -webkit-filter: grayscale(40%); /* Safari 6.0 - 9.0 */
    filter: grayscale(40%);
    position: relative;
    z-index: 100;
    overflow: hidden;
    border-radius: 5%;
    height: 260px;
    margin-bottom: 30px;
}

#gallery1 #links a:hover {
    transform: scale(1.05);
    -webkit-filter: grayscale(0%); /* Safari 6.0 - 9.0 */
    filter: grayscale(0%);
}

#gallery1 #links a img {
    position: absolute;
    left: 0;
    top: 0;
    z-index: 10;
    min-width: 100%;
    min-height: 100%;
    object-fit: cover;
}

@media only screen and (min-width: 480px) {
    #gallery1 #links a {
        width: 220px;
        height: 220px;
    }

    #gallery1 #links {
        display: flex;
        justify-content: space-between;
        flex-wrap: wrap;
    }
}

@media only screen and (min-width: 768px) {

    #gallery1 #links a {
        float: none;
        width: 220px;
        height: 220px;
        display: flex;
        justify-content: center;
        align-items: center;
        border-radius: 5%;
        background: #eee;
        padding: 0;
        margin-bottom: 30px;
    }

    #gallery1 #links a > img {
        /* width: 200px;
        height: auto; */
        display: block;
        margin: 0;
        padding: 0;
    }

    #gallery1 #links a > img.img-vert {
        width: 120px;
    }
}

@media only screen and (min-width: 1200px) {
    #gallery1 #links a {
        width: 260px;
    }

    #gallery1 #links a > img {
        /* width: 220px; */
    }
}