/* ==========================================================================
   COMPOSANT PARTAGÉ : LIGHTBOX (Bare-Metal)
   ========================================================================== */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease-in-out, visibility 0.2s ease-in-out;
}
.lightbox.is-active {
    opacity: 1;
    visibility: visible;
}
.lightbox-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
}
.lightbox-content {
    position: relative;
    z-index: 10001;
    max-width: 90%;
    max-height: 90%;
}
.lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    display: block;
    border: 2px solid var(--border-color, #ffffff);
    border-radius: var(--radius-sm, 4px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}
.lb-btn.symbol {
    font-size: 40px !important;
    width: 1em !important;
    height: 1em !important;
}
.lb-btn {
    position: absolute;
    background: rgba(255, 255, 255, 0.3);
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 1.5em;
    height: 1.5em;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background 0.2s;
}
.lb-btn:hover { font-weight: bold; }
.lb-close { top: -20px; right: -20px; background: var(--error-color, #dc3545); }
.lb-prev { left: -50px; top: 50%; transform: translateY(-50%); }
.lb-next { right: -50px; top: 50%; transform: translateY(-50%); }

@media (max-width: 599px) {
    .lb-prev { left: 10px; }
    .lb-next { right: 10px; }
    .lb-close { top: 10px; right: 10px; }
}

.lightbox-content {
    position: relative;
    z-index: 10001;
    max-width: 90%;
    max-height: 90%;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.lightbox-content img {
    max-width: 100%;
    max-height: 80vh;
    display: block;
    border: 2px solid var(--border-color, #ffffff);
    border-radius: var(--radius-sm, 4px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.5);
}
.lb-caption {
    margin-top: 10px;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    max-width: 100%;
    padding: 6px 14px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: var(--radius-sm, 4px);
    word-break: break-word;
}
.lb-caption:empty {
    display: none;
}