#lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(30, 30, 30, 0.82);
    backdrop-filter: blur(6px);
    z-index: 10000;
    justify-content: center;
    align-items: center;
    cursor: pointer;
}

#lightbox.open {
    display: flex;
    animation: lb-in 0.22s ease;
}

@keyframes lb-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

#lightbox .lb-inner {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    animation: lb-pop 0.22s cubic-bezier(0.34,1.56,0.64,1);
    cursor: default;
}

@keyframes lb-pop {
    from { transform: scale(0.7); opacity: 0; }
    to   { transform: scale(1);   opacity: 1; }
}

#lightbox .lb-mat {
    background: var(--frame-bg);
    padding: 14px;
    display: flex;
    border-radius: 10px;
}

#lightbox img {
    display: inline-block;
    max-width: 85vw;
    max-height: 78vh;
    object-fit: contain;
}

/* #lightbox .lb-caption {
    text-align: center;
    font-size: 1.4rem;
    color: #5a4a3a;
    padding-top: 6px;
    width: 25%;
} */

#lightbox .lb-close {
    position: absolute;
    top: -18px;
    right: -18px;
    width: 36px;
    height: 36px;
    background: #1a1a1a;
    color: #fffef5;
    border: none;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.4);
    transition: background 0.15s;
    font-family: sans-serif;
}

#lightbox .lb-close:hover { background: #7a848f; }

/* Arrow nav */
/* .lb-arrow {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(74,50,24,0.7);
    color: #fffef5;
    border: none;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    font-size: 1.4rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
    font-family: sans-serif;
    z-index: 10000;
} */

/* .lb-arrow:hover { background: rgba(122,82,48,0.9); }

#lb-prev { left: 1.5rem; }

#lb-next { right: 1.5rem; } */