#imageOverlay {
    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;
    z-index: 1000;
}

#overlayContent {
    position: relative;
    max-width: 95vw;
    max-height: 95vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

#overlayImage {
    max-width: 95vw;
    max-height: 95vh;
    object-fit: contain;
    border-radius: 5px;
    transform-origin: center center;
    transition: transform 0.08s ease-out;
    z-index: 1;
}

#closeViewer {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 50px;
    color: white;
    cursor: pointer;
    background: rgba(0, 0, 0, 0.4);
    border: 0;
    width: 50px;
    height: 50px;
    line-height: 35px;
    border-radius: 999px;
    padding-left: 5px;
    padding-bottom: 15px;
    z-index: 2;
}

#toggleZoom {
    position: absolute;
    top: 10px;
    right: 70px;
    font-size: 26px;
    color: white;
    cursor: pointer;
    background: rgba(0, 0, 0, 0.4);
    border: 0;
    width: 44px;
    height: 44px;
    border-radius: 999px;
    padding: 0;
    line-height: 44px;
    z-index: 2;
}

#prevImage,
#nextImage {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    font-size: 40px;
    color: white;
    cursor: pointer;
    user-select: none;
    background: rgba(0, 0, 0, 0.2);
    border: 0;
    width: 50px;
    height: 100px;
    border-radius: 999px;
    padding: 0;
    z-index: 2;
}

#prevImage {
    left: 12px;
}

#nextImage {
    right: 12px;
}

#prevImage:hover,
#nextImage:hover,
#closeViewer:hover,
#toggleZoom:hover {
    color: #ccc;
}