/* Gallery enhancement on the restored warm layout (version 17). */
.image-frame{position:relative;min-width:0}
.research>.image-frame>.project-image{aspect-ratio:1.45}
.expand-view{position:absolute;top:12px;right:12px;z-index:3;width:44px;height:44px;display:grid;place-items:center;border:1px solid var(--brass);background:rgba(245,240,232,.94);color:#78603b;cursor:pointer;border-radius:0}
.expand-view svg,.viewer button svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.3;stroke-linecap:round;stroke-linejoin:round}
.expand-view:hover{background:#e5d5c8}.expand-view:focus-visible,.viewer button:focus-visible{outline:2px solid var(--brass);outline-offset:4px}
html.viewer-open{overflow:hidden}
.viewer{position:fixed;inset:0;width:100%;max-width:none;height:100%;height:100dvh;max-height:none;margin:0;padding:24px 4%;border:0;background:#f5f0e8;color:#39332f;overscroll-behavior:contain}
.viewer[open]{display:grid;grid-template-rows:auto minmax(0,1fr) auto;gap:18px}
.viewer::backdrop{background:#343c32}
.viewer-head{display:flex;align-items:center;justify-content:space-between;gap:20px;border-bottom:1px solid #a38c62;padding-bottom:12px}
.viewer-title{font:400 clamp(24px,3vw,38px)/1.2 'Cormorant Garamond',Georgia,serif}
.viewer button{min-width:44px;min-height:44px;border:1px solid #a38c6266;background:transparent;color:#78603b;display:inline-grid;place-items:center;cursor:pointer;flex-shrink:0}
.viewer button:hover{background:#e5d5c8}
.viewer-stage{min-height:0;min-width:0;position:relative;display:grid;place-items:center;touch-action:pan-y pinch-zoom}
.viewer-stage img{width:100%;height:100%;min-height:0;object-fit:contain;filter:none;pointer-events:none}
.viewer-caption{display:grid;grid-template-columns:1fr auto;align-items:center;gap:16px;border-top:1px solid #a38c62;padding-top:14px}
.viewer-caption p{font-size:12px;line-height:1.6;margin:0}.viewer-count{font-size:11px;color:#756140;letter-spacing:.14em;font-variant-numeric:tabular-nums}
.viewer-nav{display:flex;gap:10px}.viewer-nav[hidden]{display:none}
.viewer-status{position:absolute;bottom:10px;left:50%;transform:translateX(-50%);background:var(--paper);padding:8px 14px;font-size:12px;max-width:90%;text-align:center}
.viewer-status:empty{display:none}
@media(max-width:620px){.viewer{padding:16px 6% max(20px,env(safe-area-inset-bottom));gap:12px}.viewer-title{font-size:26px}.viewer-caption p{font-size:11px}.expand-view{top:9px;right:9px}.viewer-caption{gap:10px}.viewer-nav{gap:6px}}
@media(prefers-reduced-motion:no-preference){.quiet-arrival{animation:quiet-arrival .65s ease-out both}.viewer-stage.is-arriving img{animation:gallery-arrival .28s ease-out both}@keyframes quiet-arrival{from{opacity:.45;transform:translateY(12px)}to{opacity:1;transform:none}}@keyframes gallery-arrival{from{opacity:.5}to{opacity:1}}}
