.container:has(> article) {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1em;
}

article h3 {
    white-space: nowrap;
}

article img {
    width: 100%;
    height: 10em;
    object-fit: cover;
    pointer-events: none;
}

img .large {
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    pointer-events: none;
}

/* Header */
.header {
    background-color: var(--black);
    box-shadow: 1px 1px 5px 0px var(--gray);
    position: relative;
    top: 0;
    width: 100%;
}

/* variables*/
:root {
    --white: #f9f9f9;
    --black: #ff7a7a;
    --gray: #ff5d5d;
}

/* Reset */

header a {
    text-decoration: none;
}

header ul {
    list-style: none;
}

main {
    padding: 0 1em;
}

/* Logo */
.logo {
    display: inline-block;
    font-size: 60px;
    margin-left: 10px;
}

/* Nav menu */
.nav {
    width: 100%;
    height: 100%;
    position: fixed;
    background-color: var(--black);
    overflow: hidden;
}

.menu a {
    display: block;
    padding: 30px 20px;
    color: var(--white);
}

.menu a:hover {
    background-color: var(--gray);
}

.nav {
    max-height: 0;
    transition: max-height .5s ease-out;
}

/* Menu Icon */
/* Style label tag */
.hamb {
    cursor: pointer;
    float: right;
    padding: 40px 20px;
}

/* Style span tag */
.hamb-line {
    background: var(--white);
    display: block;
    height: 2px;
    position: relative;
    width: 24px;

}

.hamb-line::before,
.hamb-line::after {
    background: var(--white);
    content: '';
    display: block;
    height: 100%;
    position: absolute;
    transition: all .2s ease-out;
    width: 100%;
}

.hamb-line::before {
    top: 5px;
}

.hamb-line::after {
    top: -5px;
}

/* Hide checkbox */
.side-menu {
    display: none;
}

/* Toggle menu icon */
.side-menu:checked~nav {
    max-height: 100%;
}

.side-menu:checked~.hamb .hamb-line {
    background: transparent;
}

.side-menu:checked~.hamb .hamb-line::before {
    transform: rotate(-45deg);
    top: 0;
}

.side-menu:checked~.hamb .hamb-line::after {
    transform: rotate(45deg);
    top: 0;
}

/* Responsiveness */
@media (min-width: 768px) {
    .nav {
        max-height: none;
        top: 0;
        position: relative;
        float: right;
        width: fit-content;
        background-color: transparent;
    }

    .menu li {
        float: left;
    }

    .menu a:hover {
        background-color: transparent;
        color: var(--gray);

    }

    .hamb {
        display: none;
    }
}