body {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 100vh;
}

#wrapper {
    align-items: center;
    justify-content: center;
}


main {
    flex: 1;
    display: flex;
    flex-direction: column;
    max-width: var(--page-width);
    width: 100%;
    padding: 20px;
}

article {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-gap: 20px;
}

article a {
    text-decoration: none;
    color: white;
}

section {
    position: relative;
}

section .background,
section .background div {
    flex: 1;
    background-color: black;
    height: 280px;
    width: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

section .background div {
    opacity: 1;
}

section:hover .background {
    opacity: var(--opacity-2);
}


article section h3 {
    position: absolute;
    width: 100%;
    text-align: center;
    font-size: 1.7rem;
    font-weight: 400;
    margin: 0;
    padding: 0 10px;
    opacity: 0;
    color: white;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

article section:hover h3 {
    opacity: 1;
}

@media screen and (max-width: 850px) {
    article {
        grid-template-columns: repeat(2, 1fr);
    }

    section .background,
    section .background div {
        height: 200px;
    }
}

@media screen and (max-width: 550px) {
    main {
        padding: 0 15px;
    }

    article {
        grid-template-columns: repeat(1, 1fr);
        grid-gap: 15px;
    }

    h1 {
        margin: 10px 0;
    }
}