/* ═════════════════════════════════════════════════════════════
   LIGHTBOX – gehört zu js/lightbox.js
   ═════════════════════════════════════════════════════════════ */
.lbx {
    position: fixed; inset: 0; z-index: 100000;
    display: flex; align-items: center; justify-content: center;
    padding: 56px 70px 24px;
    background: rgba(5, 6, 10, 0.96);
    color: #f5f7ff; font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
}
.lbx[hidden] { display: none; }
html.lbx-offen { overflow: hidden; }

.lbx-figur { margin: 0; display: flex; flex-direction: column; align-items: center; max-width: 100%; max-height: 100%; }
.lbx-rahmen { position: relative; line-height: 0; }
.lbx-bild {
    display: block; max-width: calc(100vw - 140px); max-height: calc(100vh - 140px); max-height: calc(100dvh - 140px);
    border-radius: 4px; transition: opacity .25s;
}
.lbx-rahmen.lbx-laedt .lbx-bild { opacity: .25; }
/* Wasserzeichen auf dem Bild */
.lbx-rahmen::after {
    content: attr(data-wz);
    position: absolute; right: 18px; bottom: 16px;
    font-size: 18px; font-weight: 600; line-height: 1.2;
    color: rgba(255, 255, 255, 0.75); text-shadow: 0 0 6px rgba(0, 0, 0, 0.7);
    pointer-events: none;
}
.lbx figcaption {
    display: flex; gap: 16px; justify-content: space-between; align-items: baseline;
    width: 100%; padding-top: 12px; font-size: .95rem; line-height: 1.4;
}
.lbx-text { white-space: pre-line; }
.lbx-zaehler { color: #9aa0b5; font-size: .85rem; white-space: nowrap; margin-left: auto; }

.lbx-zu, .lbx-nav {
    position: fixed; z-index: 1;
    width: 48px; height: 48px; padding: 0; border-radius: 50%;
    border: 1px solid rgba(245, 247, 255, 0.18); background: rgba(245, 247, 255, 0.08);
    color: #f5f7ff; font-size: 30px; line-height: 1; cursor: pointer;
}
.lbx-zu:hover, .lbx-nav:hover { background: rgba(245, 247, 255, 0.2); }
.lbx-zu:focus-visible, .lbx-nav:focus-visible { outline: 2px solid #8fb4ff; outline-offset: 2px; }
.lbx-zu { top: 14px; right: 16px; }
.lbx-nav { top: 50%; transform: translateY(-50%); }
.lbx-zurueck { left: 12px; }
.lbx-vor { right: 12px; }
.lbx-nav[hidden] { display: none; }

@media (max-width: 700px) {
    .lbx { padding: 64px 8px 80px; }
    .lbx-bild { max-width: calc(100vw - 16px); max-height: calc(100dvh - 170px); }
    .lbx-nav { top: auto; bottom: 14px; transform: none; }
    .lbx-zurueck { left: 16px; }
    .lbx-vor { right: 16px; }
    .lbx figcaption { padding: 10px 6px 0; }
    .lbx-rahmen::after { right: 10px; bottom: 8px; font-size: 13px; }
}
