#lightbox{
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.96);
    z-index: 99999;
    display: none;
    overflow-y: auto;
    padding: 70px 10px 20px;
}

#lightbox.active{
    display: block;
}

.close-btn{
    position: fixed;
    top: 15px;
    right: 20px;
    font-size: 40px;
    color: #fff;
    cursor: pointer;
    z-index: 100000;
}

#lightbox-grid{
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px,1fr));
    gap: 8px;
}

#lightbox-grid img{
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
}
/*========================================*/
#image-viewer{
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.97);
    z-index: 100000;
    display: none;
    justify-content: center;
    align-items: center;
}

#image-viewer.active{
    display: flex;
}

#viewer-image{
    max-width: 95%;
    max-height: 95%;
    object-fit: contain;
    transition: transform .3s ease;
    cursor: zoom-in;
}

/* Zoomed state */
#viewer-image.zoomed{
    transform: scale(2);
    cursor: zoom-out;
}

.viewer-close{
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 45px;
    color: #fff;
    cursor: pointer;
}
