/* Opera Lightbox */
.opera-lightbox {
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(0,0,0,0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    cursor: zoom-out;
}

.opera-lightbox.active {
    opacity: 1;
    visibility: visible;
}

.opera-lightbox-img {
    max-width: 94vw;
    max-height: 90vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 4px;
    cursor: default;
    transform: scale(0.9);
    opacity: 0;
    transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94), opacity 0.35s ease;
}

.opera-lightbox.active .opera-lightbox-img {
    transform: scale(1);
    opacity: 1;
}

.opera-lightbox-close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    width: 44px;
    height: 44px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
}

.opera-lightbox-close svg {
    stroke: #fff;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.opera-lightbox-close:hover svg {
    opacity: 1;
}

.opera-lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    background: rgba(255,255,255,0.1);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    z-index: 10;
}

.opera-lightbox-nav:hover {
    background: rgba(255,255,255,0.25);
}

.opera-lightbox-nav svg {
    stroke: #fff;
}

.opera-lightbox-prev {
    left: 1rem;
}

.opera-lightbox-next {
    right: 1rem;
}

.opera-lightbox-counter {
    position: absolute;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,0.6);
    font-size: 0.85rem;
    font-family: 'Work Sans', sans-serif;
}

/* Hide nav when only 1 image */
.opera-lightbox-nav.hidden,
.opera-lightbox-counter.hidden {
    display: none;
}

@media (max-width: 600px) {
    .opera-lightbox-nav {
        width: 40px;
        height: 40px;
    }
    .opera-lightbox-prev { left: 0.5rem; }
    .opera-lightbox-next { right: 0.5rem; }
}
