
/* Basic styling for the gallery */
.gallery {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    /* padding: 20px; */
    width: 80%;
    margin: auto;
    padding: 10px 0 30px;
}

.gallery img {
    margin: 10px;
    cursor: pointer;
    width: 18rem;
    height: 12rem;
    border-radius: 10px;
    /* border: #830000 2px solid; */
    object-fit: cover;
}

/* Lightbox styles */
#lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    overflow: hidden;
    flex-direction: column;
    z-index: 2;
}

#main-img-container {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 80%;
    max-height: 60vh;
    /* background: rgba(0, 0, 0, 0.2);
    background-size: cover; */
}

#lightbox img:not(.thumbnail) {
    max-width: 80%;
    height: 60vh;
    box-shadow: 0 0 25px rgba(0, 0, 0, 0.8);
    border-radius: 10px;
}

#close-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 24px;
    color: #fff;
    cursor: pointer;
    z-index: 2;
}

#prev-btn {
    border-radius: 10px 0 0 10px;

    svg {
        float: right;
        margin-right: 20px;
    }
}

#next-btn {
    border-radius: 0 10px 10px 0;

    svg {
        float: left;
        margin-left: 20px;
    }
}

.lightbox-nav-button {
    border: none;
    height: 100%;
    width: 100%;
    min-width: 100px;
    background: rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: background 0.3s, filter 0.3s, box-shadow 0.3s;
    /* transition: filter 0.3s; */
    box-shadow: 0 0 25px rgba(0, 0, 0, 0.2);
}

.lightbox-nav-button:hover {
    background: rgba(0, 0, 0, 0.3);
    filter: brightness(1.5);
    box-shadow: 0 0 25px rgba(0, 0, 0, 0.5);
}

/* Styles for thumbnails */
#thumbnail-container {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
}

.thumbnail {
    width: 100%;
    height: 100%;
    cursor: pointer;
    object-fit: cover;

}

.thumbnail-div {
    width: 100px;
    height: 60px;
    background: #888;
    overflow: hidden;
    margin-top: 40px;
    margin-left: 5px;
    margin-right: 5px;
    border: 2px solid #fff;
    transition: opacity 0.3s;
    box-shadow: 0 0 25px rgba(0, 0, 0, 0.8);
    border-radius: 10px;
}

.thumbnail-div:hover,
.thumbnail-div.active-thumbnail {
    opacity: 0.7;
    border: 2px solid #b65a5a;
}


@media only screen and (max-width: 1200px) {
    .gallery {
        width: 90%;
    }
}

@media only screen and (max-width: 1000px) {
    .gallery {
        width: 95%;
    }

    #lightbox img:not(.thumbnail) {
        max-height: 60vh;
        height: auto;
    }
}

@media only screen and (max-width: 700px) {
    .gallery img {
        /* max-width: 80vw; */
        /* max-height: 60vw; */
        max-width: 40vw;
        max-height: 30vw;
        width: 40vw;
        height: 30vw;
    }
}

@media only screen and (max-width: 650px) {
    /* #thumbnail-container {
        max-width: 360px;
    } */
    .thumbnail-div {
        width: 25%;
    }

    .thumbnail-div img {
        aspect-ratio: 5/3;
    }
}

@media only screen and (max-height: 700px) {
    #lightbox img:not(.thumbnail) {
        max-height: 50vh;
    }
}