/* Lightbox thumbnails */
#blog-content img:not(.lightbox-main-img) {
    width: 135px;
    height: 100px;
    object-fit: cover;
    margin: 0 10px 10px 0;
    cursor: pointer;
    display: inline-block;
    vertical-align: top;
    border-radius: 5px;
    transition: filter 200ms ease;
}

#blog-content img:not(.lightbox-main-img):hover {
    filter: brightness(1.2);
}

/* Clearfix for posts to prevent floats from leaking */
#blog-content > div[id^="post-"]::after {
    content: "";
    display: table;
    clear: both;
}

/* Modal styling */
#lightbox-modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.9);
    align-items: center;
    justify-content: center;
}

#lightbox-modal.active {
    display: flex;
}

.lightbox-main-img {
    max-width: 90vw;
    max-height: 90vh;
    object-fit: contain;
}

.lightbox-close {
    position: absolute;
    top: 20px;
    right: 30px;
    color: white;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
}

.lightbox-prev, .lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    font-size: 50px;
    font-weight: bold;
    cursor: pointer;
    user-select: none;
    padding: 20px;
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}
