.gallery-lightbox { box-sizing: border-box; position: fixed; inset: 0; width: 100%; max-width: none; height: 100%; height: 100dvh; max-height: none; margin: 0; padding: 0; border: 0; background: rgba(5, 14, 27, .97); color: #fff; overflow: hidden; }
.gallery-lightbox::backdrop { background: #050e1b; }
.gallery-lightbox[open] { display: grid; grid-template-columns: 76px minmax(0, 1fr) 76px; grid-template-rows: 76px minmax(0, 1fr) 64px; }
.lightbox-toolbar { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; padding: 12px 24px; gap: 16px; }
#lightbox-counter { font-size: 14px; font-variant-numeric: tabular-nums; color: #d2dfeb; }
.lightbox-actions { display: flex; gap: 12px; }
.gallery-lightbox button { display: inline-flex; align-items: center; justify-content: center; min-width: 48px; min-height: 48px; border: 1px solid #566372; border-radius: 999px; background: #1a2939; color: white; cursor: pointer; font: inherit; }
.gallery-lightbox button:hover { background: #0b706e; }
.gallery-lightbox button:focus-visible { outline: 3px solid #5be1d1; outline-offset: 4px; }
#lightbox-close { font-size: 32px; }
#lightbox-zoom { padding: 0 18px; font-size: 14px; }
.lightbox-prev, .lightbox-next { align-self: center; justify-self: center; width: 48px; font-size: 36px !important; }
.lightbox-stage { position: relative; min-width: 0; min-height: 0; display: flex; align-items: center; justify-content: center; overflow: auto; overscroll-behavior: contain; touch-action: pan-y pinch-zoom; }
#lightbox-image { display: block; width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 6px; cursor: zoom-in; }
.lightbox-stage.is-zoomed { display: block; touch-action: auto; }
.lightbox-stage.is-zoomed #lightbox-image { width: 200%; max-width: none; max-height: none; cursor: zoom-out; }
#lightbox-image[hidden], #lightbox-status[hidden] { display: none; }
#lightbox-status { text-align: center; color: #d2dfeb; }
#lightbox-caption { grid-column: 1 / -1; margin: 0; padding: 16px 20px; align-self: center; text-align: center; font-size: 14px; color: #d2dfeb; }
@media (max-width: 600px) {
  .gallery-lightbox[open] { grid-template-columns: 52px minmax(0, 1fr) 52px; grid-template-rows: 72px minmax(0, 1fr) 76px; }
  .lightbox-toolbar { padding: 12px; }
  .lightbox-prev, .lightbox-next { min-width: 44px !important; width: 44px; }
  #lightbox-caption { font-size: 12px; }
}
