.pictures-grid {
    display: grid;
    grid-template-areas:
        "img1 img1"
        "img1 img1" 
        "img2 img2"
        "img3 img4";
    grid-template-columns: repeat(2, 1fr);
    gap: 5px;
}

@media screen and (min-width: 768px) {
    .pictures-grid {
        display: grid;
        grid-template-areas:
            "img1 img1 img1 img1 img2 img2 img2 img2 img2 img2"
            "img1 img1 img1 img1 img3 img3 img3 img4 img4 img4";
        grid-template-columns: repeat(10, 1fr);
    }
}
.pictures-grid a:nth-child(1) { 
    grid-area: img1; 
}
.pictures-grid a:nth-child(2) { 
    grid-area: img2; 
}
.pictures-grid a:nth-child(3) { 
    grid-area: img3; 
}
.pictures-grid a:nth-child(4) { 
    grid-area: img4; 
}

.pictures-grid figure {
    position: relative;

    margin: 0;
    
    width: 100%;
    height: 100%;

    overflow: hidden;
}

.pictures-grid img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* .pictures-grid figcaption {
    position: absolute;
    bottom: 0;
    left: 0;

    background: rgba(0,0,0,0.6);
    color: #fff;

    font-size: 1.6rem;
    padding: 0.3rem 0.5rem;
    width: 100%;
} */

.lightbox {
    position: fixed;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;

    inset: 0;
}

.lightbox[hidden] {
    display: none;
}

.lightbox-overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.8);
}

.lightbox-content {
    position: relative;
    z-index: 1;
    max-width: 90%;
    max-height: 90%;
    text-align: center;
    background: #000;
    padding: 1rem;
    border-radius: 6px;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: 0.5rem;
    right: 1rem;
    font-size: 2rem;
    background: none;
    color: #fff;
    border: none;
    cursor: pointer;
}

#lightbox-caption {
    color: white;
    margin-top: 1rem;
}
.lightbox {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.lightbox.is-open {
    display: flex;
}

.lightbox-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1;
}

.lightbox-content {
    position: relative;
    z-index: 2;
    max-width: 90%;
    max-height: 90%;
    background: black;
    padding: 1rem;
    border-radius: 6px;
    text-align: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: 0.5rem;
    right: 1rem;
    font-size: 2rem;
    background: none;
    color: #fff;
    border: none;
    cursor: pointer;
}

#lightbox-caption {
    color: #fff;
    margin-top: 0.5rem;
}
