body {
    min-height: 100%;
    margin: 20px;
    padding: 0;
}

body * {
    box-sizing: border-box;
}

.cards {
    display: grid;
    flex-wrap: wrap;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    column-gap: 20px;
    row-gap: 20px;
}

.cards>img {
    object-fit: cover;
    height: calc(25vh - 25px);
    width: 100%;
    transition: all 0.5s;
}

.cards>img:hover {
    opacity: 0.7;
    transform: scale(1.1);
}

/* Media Queries */
@media (max-width: 900px) {
    .cards {
        grid-template-columns: 1fr 1fr;
    }

    .cards>img {
        height: 45vh;
    }

    .cards>img:hover {
        opacity: 0.7;
        transform: none;
    }
}

@media (max-width: 550px) {
    .cards {
        grid-template-columns: 1fr;
    }

    cards>img {
        height: 100vh;
    }
}