#photo-gallery{width:min(1080px,calc(100% - 40px));max-height:94vh;max-height:94dvh;padding:0;border:1px solid var(--line);overflow:auto;background:var(--paper);box-shadow:0 30px 120px #001c2690}
#photo-gallery::backdrop{background:#092d2deb;backdrop-filter:blur(8px)}
.gallery-header{position:relative;padding:23px 76px 18px 28px}
#photo-gallery .gallery-kicker{font-size:12px;letter-spacing:.15em;color:var(--rust);margin:0 0 8px}
#photo-gallery h2{font-size:clamp(26px,3vw,40px);line-height:1.15;margin:0 0 8px}
#photo-gallery #gallery-intro{font-size:14px;line-height:1.5;color:var(--muted);margin:0}
#photo-gallery .gallery-close{top:18px;right:18px;width:44px;height:44px;border:1px solid var(--line);background:var(--paper);font-family:var(--body);font-size:28px;z-index:2}
.gallery-stage{height:clamp(220px,55vh,660px);height:clamp(220px,55dvh,660px);position:relative;background:#0b2728;display:flex;align-items:center;justify-content:center;overflow:hidden}
#gallery-photo{display:block;width:100%;height:100%;object-fit:contain;transition:opacity .18s ease}
.gallery-arrow{position:absolute;top:calc(50% - 24px);width:48px;height:48px;display:grid;place-items:center;background:var(--paper);color:var(--ink);border:1px solid #ffffff50;font-size:36px;line-height:1;box-shadow:0 3px 15px #0003;z-index:2}
.gallery-prev{left:16px}.gallery-next{right:16px}
.gallery-arrow:hover{background:var(--lime)}
#photo-gallery #gallery-load,#gallery-error{position:absolute;inset:0;display:grid;align-content:center;justify-items:center;color:var(--paper);font-size:16px;margin:0;padding:20px 65px;text-align:center}
#gallery-error p{margin:0 0 12px}#gallery-retry{font-size:14px;border-bottom:1px solid;min-height:44px;color:var(--lime)}
.gallery-meta{display:flex;justify-content:space-between;align-items:baseline;gap:20px;padding:15px 28px 9px}
#photo-gallery #gallery-caption{font-size:16px;line-height:1.5;margin:0}
#gallery-count{font-size:14px;font-variant-numeric:tabular-nums;white-space:nowrap;color:var(--muted)}
.gallery-thumbs{display:flex;gap:10px;overflow-x:auto;padding:5px 28px 18px;scrollbar-width:thin;scrollbar-color:var(--muted) var(--paper)}
.gallery-thumbs button{flex:0 0 64px;height:76px;padding:3px;border:1px solid transparent;opacity:.6;transition:opacity .18s}
.gallery-thumbs img{width:100%;height:100%;object-fit:cover}
.gallery-thumbs button[aria-pressed=true]{border-color:var(--ink);opacity:1;background:var(--lime)}
.gallery-thumbs button:hover{opacity:1}
#photo-gallery button:focus-visible{outline:3px solid var(--gold);outline-offset:2px}
@media(max-width:600px){#photo-gallery{width:calc(100% - 16px);max-height:96dvh}.gallery-header{padding:19px 62px 15px 18px}#photo-gallery .gallery-kicker{font-size:11px;letter-spacing:.08em}#photo-gallery .gallery-close{right:12px;top:16px}.gallery-stage{height:52vh;height:52dvh;min-height:200px}.gallery-meta{padding:13px 18px 7px;gap:12px}#photo-gallery #gallery-caption{font-size:14px}.gallery-thumbs{padding:5px 18px 14px;gap:8px}.gallery-thumbs button{height:64px;flex-basis:54px}.gallery-arrow{width:44px;height:44px;top:calc(50% - 22px)}.gallery-prev{left:7px}.gallery-next{right:7px}}
@media(prefers-reduced-motion:reduce){#gallery-photo,.gallery-thumbs button{transition:none}}
