/* ==========================================================================
   AMHSS Lightbox
   Popup image viewer with previous / next navigation.
   Used on the public Event Photos page and in the admin Event view page.
   ========================================================================== */

.amhss-lb {
    position: fixed;
    inset: 0;
    top: 0; right: 0; bottom: 0; left: 0;
    background: rgba(10, 10, 10, .92);
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity .18s ease;
}

.amhss-lb.is-open {
    display: flex;
    opacity: 1;
}

.amhss-lb-stage {
    margin: 0;
    max-width: 86vw;
    max-height: 84vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.amhss-lb-img {
    max-width: 86vw;
    max-height: 84vh;
    width: auto;
    height: auto;
    display: block;
    border-radius: 4px;
    box-shadow: 0 10px 45px rgba(0, 0, 0, .55);
    user-select: none;
}

.amhss-lb-prev,
.amhss-lb-next,
.amhss-lb-close {
    position: absolute;
    background: rgba(255, 255, 255, .12);
    border: 0;
    color: #fff;
    cursor: pointer;
    line-height: 1;
    transition: background .15s ease;
    z-index: 2;
}

.amhss-lb-prev:hover,
.amhss-lb-next:hover,
.amhss-lb-close:hover {
    background: rgba(255, 255, 255, .28);
}

.amhss-lb-prev,
.amhss-lb-next {
    top: 50%;
    transform: translateY(-50%);
    width: 52px;
    height: 72px;
    font-size: 26px;
    border-radius: 6px;
}

.amhss-lb-prev { left: 20px; }
.amhss-lb-next { right: 20px; }

.amhss-lb-close {
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    font-size: 30px;
    border-radius: 50%;
}

.amhss-lb-counter {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    color: #fff;
    background: rgba(0, 0, 0, .55);
    padding: 7px 16px;
    border-radius: 20px;
    font-size: 14px;
    letter-spacing: .4px;
}

.amhss-lb-caption {
    position: absolute;
    bottom: 62px;
    left: 50%;
    transform: translateX(-50%);
    max-width: 80vw;
    color: #f1f1f1;
    font-size: 14px;
    text-align: center;
    line-height: 1.5;
}

/* one image only - hide the arrows */
.amhss-lb.is-single .amhss-lb-prev,
.amhss-lb.is-single .amhss-lb-next,
.amhss-lb.is-single .amhss-lb-counter {
    display: none;
}

/* stop the page behind from scrolling while the popup is open */
body.amhss-lb-locked {
    overflow: hidden;
}

/* thumbnails */
.amhss-thumb {
    display: block;
    cursor: zoom-in;
    overflow: hidden;
    border-radius: 6px;
}

.amhss-thumb img {
    width: 100%;
    height: 230px;
    object-fit: cover;
    display: block;
    transition: transform .35s ease;
}

.amhss-thumb:hover img {
    transform: scale(1.05);
}

@media (max-width: 767px) {
    .amhss-lb-prev,
    .amhss-lb-next {
        width: 40px;
        height: 58px;
        font-size: 20px;
    }
    .amhss-lb-prev { left: 8px; }
    .amhss-lb-next { right: 8px; }
    .amhss-thumb img { height: 180px; }
}