.piwigo-lightbox-open {
    overflow: hidden;
}

.piwigo-lightbox {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    animation: piwigo-lightbox-fade .2s ease forwards;
}

@keyframes piwigo-lightbox-fade {
    to { opacity: 1; }
}

.piwigo-lightbox__backdrop {
    position: absolute;
    inset: 0;
    background: var(--jw-bg, #11110f);
    opacity: .96;
    backdrop-filter: blur(6px);
}

.piwigo-lightbox__frame {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 100%;
    max-height: 100%;
    min-height: 0;
    padding: 24px 96px;
    color: var(--jw-text, #f2f0ea);
}

.piwigo-lightbox__content {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    min-height: 0;
}

.piwigo-lightbox__content img {
    display: block;
    max-width: 100%;
    max-height: 85vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 2px;
    box-shadow: 0 30px 80px rgb(0 0 0 / 55%);
}

.piwigo-lightbox__caption {
    margin-top: 12px;
    text-align: center;
}

.piwigo-lightbox__caption span {
    font-family: var(--jw-serif, Georgia, serif);
    font-style: italic;
    font-size: 17px;
    color: var(--jw-muted, #9d9a91);
}

@media (max-width: 640px) {
    .piwigo-lightbox__caption span {
        font-size: 14px;
    }
}

.piwigo-lightbox__button {
    position: absolute;
    top: -40px;
    right: 0;
    background: transparent;
    border: 1px solid var(--jw-border, rgba(242, 240, 234, .14));
    color: inherit;
    font: inherit;
    padding: 6px 14px;
    cursor: pointer;
}

.piwigo-embed img {
    cursor: zoom-in;
}
