/* Full-screen photo viewer (photo-viewer.js), used on Our Story (1004) and I'm New (1002). */
html.stj-lb-open { overflow: hidden; }
.stj-lightbox { position: fixed; inset: 0; width: 100vw; height: 100vh; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 0; border: 0; background: rgb(12 22 17 / .96); color: #f5eedb; font: 400 14px/1.45 var(--stj-font-sans, Figtree, system-ui, sans-serif); overflow: hidden; }
.stj-lightbox[open] { display: grid; grid-template-rows: minmax(0, 1fr) auto; animation: stj-lb-in .16s ease-out; }
.stj-lightbox::backdrop { background: rgb(12 22 17 / .96); }
@keyframes stj-lb-in { from { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .stj-lightbox[open] { animation: none; } }
.stj-lb-stage { display: flex; min-height: 0; padding: 56px 24px 12px; overflow: hidden; cursor: zoom-in; touch-action: pan-x pan-y pinch-zoom; overscroll-behavior: contain; outline: none; }
.stj-lb-stage img { display: block; margin: auto; max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; user-select: none; -webkit-user-drag: none; box-shadow: 0 18px 50px -20px #000; }
.stj-lightbox.is-zoomed .stj-lb-stage { overflow: auto; cursor: grab; padding: 0; }
.stj-lightbox.is-zoomed .stj-lb-stage img { max-width: none; max-height: none; box-shadow: none; }
.stj-lightbox.is-dragging .stj-lb-stage { cursor: grabbing; }
.stj-lb-close { position: absolute; z-index: 2; top: max(10px, env(safe-area-inset-top)); right: max(12px, env(safe-area-inset-right)); width: 44px; height: 44px; display: grid; place-items: center; padding: 0; border: 0; background: rgb(12 22 17 / .6); color: #f5eedb; font: 300 34px/1 var(--stj-font-sans, Figtree, sans-serif); cursor: pointer; }
.stj-lb-bar { display: flex; align-items: center; justify-content: space-between; gap: 6px 24px; flex-wrap: wrap; padding: 10px max(24px, env(safe-area-inset-right)) max(14px, env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left)); }
.stj-lb-caption { margin: 0; max-width: 70ch; color: #d9d3c2; font-size: 13.5px; }
.stj-lb-actions { display: flex; align-items: center; gap: 4px 20px; }
.stj-lb-zoom, .stj-lb-full { min-height: 44px; display: inline-flex; align-items: center; gap: 6px; padding: 0; border: 0; background: none; color: #f5eedb; font: 600 14px/1 var(--stj-font-sans, Figtree, sans-serif); text-decoration: none; cursor: pointer; }
.stj-lb-full span[aria-hidden] { color: #dcc391; }
.stj-lb-zoom:hover, .stj-lb-full:hover { text-decoration: underline; text-underline-offset: .25em; }
.stj-lightbox :focus-visible { outline: 2px solid #dcc391; outline-offset: 3px; }
@media (max-width: 600px) {
  .stj-lb-stage { padding: 56px 12px 8px; }
  .stj-lb-bar { padding-inline: 16px; }
}
/* While the viewer is open the page behind it is hidden outright (CR, 2026-11-19: flashes while zooming and
   dragging), so the frosted header and menus underneath can't repaint through the dark backdrop. */
html.stj-lb-open #wrapper { visibility: hidden; }
