.gallery-switch { display:flex; align-items:center; margin-left:auto; order:4; }
.filters #result-count { margin-left:0; }
.gallery-switch[hidden] { display:none; }
.gallery-switch>span { font-size:1rem; color:var(--muted); }
.gallery-3d[hidden],#collection-view[hidden] { display:none; }
.exhibition-toolbar { display:flex; align-items:center; justify-content:space-between; gap:15px; margin-bottom:18px; }
.exhibition-toolbar h2 { font-size:1.5rem; margin:7px 0 0; font-weight:700; }
.exhibition-toolbar .button { font-size:1rem; }
.exhibition-stage { position:relative; height:min(68vh,680px); min-height:420px; overflow:hidden; background:#eae6de; }
#exhibition-view,#exhibition-view canvas { display:block; width:100%; height:100%; }
#exhibition-view { touch-action:none; cursor:grab; }
#exhibition-view:active { cursor:grabbing; }
#exhibition-view:focus-visible { outline:3px solid #a47d54; outline-offset:-3px; }
.exhibition-map { position:absolute; top:16px; right:16px; width:min(24rem,calc(100% - 2rem)); padding:12px; background:#fffffff2; box-shadow:0 3px 20px #46351b12; border-radius:6px; }
.exhibition-map summary { font:1rem var(--font-label); cursor:pointer; color:#6d5741; }
.exhibition-map-grid { position:relative; display:grid; grid-template-columns:repeat(3,1fr); grid-template-rows:repeat(3,minmax(4.5rem,auto)); gap:3px; margin-top:10px; }
.exhibition-map-grid button { background:#eee8de; border:0; border-radius:2px; font-size:1rem; line-height:1.35; padding:4px; color:#554637; cursor:pointer; }
.exhibition-map-grid button[aria-current="location"] { background:#cba982; color:#241d17; }
.exhibition-map-grid button:hover { background:#e4c6a2; }
.exhibition-map-grid svg { position:absolute; width:100%; height:100%; inset:0; pointer-events:none; overflow:visible; }
.exhibition-status { position:absolute; bottom:17px; right:16px; max-width:29%; margin:0; padding:9px 14px; background:#fffffff0; font-size:1rem; text-align:center; border-radius:4px; pointer-events:none; }
.exhibition-status:empty { display:none; }
.exhibition-hud { position:absolute; left:16px; bottom:16px; padding:12px 18px; border:1px solid #ffffff90; border-radius:8px; color:#584632; background:#ffffffe8; box-shadow:0 4px 20px #46351b0c; }
.hud-desktop { display:flex; align-items:center; gap:24px; }
.hud-action { display:flex; align-items:center; gap:10px; font-size:1rem; }
.hud-action>span:last-child { max-width:8em; line-height:1.5; }
.hud-wasd { display:grid; grid-template-columns:repeat(3,2em); gap:3px; }
.hud-wasd kbd:first-child { grid-column:2; }
.hud-wasd kbd:nth-child(2) { grid-column:1; }
.exhibition-hud kbd { display:inline-flex; align-items:center; justify-content:center; width:2em; height:2em; border:1px solid #cfc5b6; border-bottom-width:3px; border-radius:4px; background:#fffefa; font:1rem var(--font-label); }
.exhibition-hud kbd.is-pressed { background:#cba982; color:#30251b; border-color:#a88965; transform:translateY(1px); }
.hud-turn { display:flex; gap:3px; }
.hud-mouse-icon .icon { width:26px; height:32px; stroke-width:1.4; }
.hud-touch { display:none; }
.exhibition-controls { display:grid; grid-template-columns:repeat(3,36px); gap:4px; }
.exhibition-controls button { border:0; background:#fffffff0; color:#584632; border-radius:4px; min-height:38px; cursor:pointer; touch-action:none; }
.exhibition-controls button:last-child { grid-column:2; }
.exhibition-bottom { display:flex; justify-content:space-between; align-items:center; gap:12px; margin:14px 0; }
.exhibition-bottom:has(.exhibition-pages:empty) { display:none; }
.exhibition-bottom p { color:var(--muted); font-size:1rem; margin:0; }
.exhibition-pages { display:flex; gap:8px; align-items:center; white-space:nowrap; font-size:1rem; }
.exhibition-pages button { display:inline-flex; align-items:center; justify-content:center; background:white; border:1px solid var(--line); padding:6px 10px; cursor:pointer; }
.exhibition-pages button .icon { display:block; margin:0; }
.exhibition-art-list { display:flex; flex-wrap:wrap; gap:8px; padding-top:8px; }
.exhibition-art-list button { background:#f6f3ed; border:0; padding:9px 12px; font-size:1rem; color:#5a4835; cursor:pointer; text-align:left; }
@media(min-width:601px) and (max-width:1000px) {
 .exhibition-status { top:16px; left:16px; right:auto; bottom:auto; max-width:30%; }
}
@media(max-width:600px) {
 .gallery-switch { margin-left:auto; }
 .filters { gap:16px 12px; }
 .gallery-switch .button { font-size:1rem; padding:10px 12px; }
 .exhibition-toolbar .eyebrow { font-size:1rem; }
 .exhibition-toolbar h2 { font-size:1.375rem; }
 .exhibition-toolbar .button { padding:9px 11px; font-size:1rem; }
 .exhibition-stage { height:62vh; min-height:410px; }
 .exhibition-map { width:calc(100% - 20px); top:10px; right:10px; }
 .exhibition-map-grid { grid-template-rows:repeat(3,minmax(4.5rem,auto)); }
 .exhibition-status { bottom:auto; top:53px; right:10px; max-width:55%; font-size:1rem; }
 .exhibition-stage:has(.exhibition-map[open]) .exhibition-status { visibility:hidden; }
 .exhibition-hud { left:10px; right:10px; bottom:10px; padding:10px 12px; }
 .hud-desktop { display:none; }
 .hud-touch { display:flex; gap:15px; align-items:center; }
 .hud-touch>span { font-size:1rem; line-height:1.8; }
 .exhibition-bottom { align-items:flex-start; flex-direction:column; }
}
@media(pointer:coarse) and (min-width:601px) {
 .hud-desktop { display:none; }
 .hud-touch { display:flex; gap:16px; align-items:center; font-size:1rem; line-height:1.8; }
}

.exhibition-toolbar,.hud-desktop,.hud-touch,.exhibition-pages { flex-wrap:wrap; }
.exhibition-actions { display:flex; flex-wrap:wrap; gap:.75em; }
.gallery-fullscreen-control { position:absolute; top:.75rem; left:.75rem; z-index:4; display:grid; place-items:center; width:2.75rem; height:2.75rem; padding:0; border:1px solid var(--line); border-radius:4px; color:var(--ink); background:#fffffff2; cursor:pointer; }
.gallery-fullscreen-control .icon { width:1.375rem; height:1.375rem; }
.gallery-fullscreen-control:hover { color:var(--accent); border-color:var(--accent); }
.gallery-3d:fullscreen,.gallery-3d.gallery-expanded { display:flex; flex-direction:column; gap:.75rem; width:100%; height:100dvh; padding:1rem; background:var(--paper); overflow:auto; }
.gallery-3d.gallery-expanded { position:fixed; inset:0; z-index:30; }
.gallery-fullscreen-open { overflow:hidden; }
.gallery-3d:fullscreen .exhibition-toolbar,.gallery-expanded .exhibition-toolbar { flex-shrink:0; margin-bottom:0; }
.gallery-3d:fullscreen .exhibition-stage,.gallery-expanded .exhibition-stage { flex:1 0 12rem; min-height:12rem; height:auto; }
.gallery-3d:fullscreen .exhibition-art-list,.gallery-expanded .exhibition-art-list,
.gallery-3d:fullscreen .exhibition-bottom,.gallery-expanded .exhibition-bottom { display:none; }
@media(min-width:601px) and (max-width:1000px) { .exhibition-status { top:4rem; } }
.exhibition-map-grid button { overflow-wrap:anywhere; }
.exhibition-hud { max-width:calc(100% - 2rem); }
.hud-desktop { gap:1em; }
.exhibition-pages { white-space:normal; }
.exhibition-pages button,.exhibition-art-list button { padding:.5em .75em; }
@media(max-width:600px) { .exhibition-stage { min-height:36rem; } .hud-touch>span { flex:1 1 8rem; } .exhibition-status { max-width:calc(100% - 20px); } }
