/* One mobile/tablet handle; original control nodes and their row order are retained. */
.viewer-control-rows-clip,.viewer-controls-scrollport,.viewer-section-clip{display:contents}
#viewer-controls-drawer-handlebar{display:none}
#full-view.unified-viewer-drawer #viewer-controls-drawer-handlebar{display:flex;align-items:center;justify-content:center;gap:6px;min-height:32px;flex:none;max-width:100%;box-sizing:border-box;padding:0;margin:0;background:transparent;color:var(--footer-glass-ink)}
#full-view.unified-viewer-drawer #viewer-controls-drawer-handle{position:relative;min-width:100px;min-height:32px;height:32px;flex:0 1 180px;padding:12px 12px 3px;border:1px solid var(--footer-glass-line);border-radius:4px;background:var(--footer-button-glass);color:var(--footer-glass-ink);font:inherit;font-size:11px;line-height:1;touch-action:none;cursor:ns-resize;user-select:none;-webkit-user-select:none}
#viewer-controls-drawer-handle::before{content:'';position:absolute;top:5px;left:calc(50% - 18px);width:36px;height:3px;border-radius:2px;background:currentColor;opacity:.65}
#viewer-controls-drawer-handle:focus-visible{outline:2px solid currentColor;outline-offset:-3px}
#full-view.unified-viewer-drawer .viewer-controls-scrollport[data-drawer-active=true]{display:block;width:100%;max-height:var(--viewer-control-budget,35dvh);overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;scrollbar-width:auto;flex:none;box-sizing:border-box}
#full-view.unified-viewer-drawer .viewer-control-rows-clip[data-drawer-active=true]{display:block;flex:none!important;box-sizing:border-box;width:100%;min-height:0!important;height:var(--viewer-controls-height,auto)!important;max-height:none!important;overflow:hidden!important;overflow:clip!important;padding:0;margin:0;transition:height 220ms cubic-bezier(.2,.7,.2,1)}
#full-view.unified-viewer-drawer .viewer-section-clip{display:block;flex:none;min-height:0!important;height:var(--viewer-section-height,auto);overflow:hidden!important;transition:height 220ms cubic-bezier(.2,.7,.2,1)}
#full-view.unified-viewer-drawer .viewer-section-clip.viewer-section-pulling{transition:none}
html #full-view.unified-viewer-drawer .viewer-section-clip :is(.full-description,#full-prompt-overlay,#full-video-prompt):not([hidden]){position:static!important;display:block!important;box-sizing:border-box;min-height:0!important;max-height:none!important;height:auto!important;width:100%!important;max-width:100%!important;overflow:visible!important;overscroll-behavior:auto;touch-action:pan-y pinch-zoom;user-select:text;-webkit-user-select:text;padding:4px 8px!important;margin:0!important}
html.phone-layout:not(.immersive) #full-view.unified-viewer-drawer #phone-viewer-metadata.phone-prompt-drawer{height:auto!important;max-height:none!important;min-height:0!important;overflow:visible!important;flex:none;padding:0 8px}
#full-view.unified-viewer-drawer #phone-prompt-drawer-handle,#full-view.unified-viewer-drawer #phone-viewer-more{display:none!important}
html.phone-layout #full-view#full-view.unified-viewer-drawer .full-toolbar{display:flex!important;flex-direction:column;box-sizing:border-box;width:100%;min-height:0!important;padding:2px 0!important;margin:0}
#full-view.unified-viewer-drawer .full-toolbar>.wordmark{display:none!important}
html.phone-layout #full-view.unified-viewer-drawer .full-actions{display:flex!important;flex-wrap:wrap!important;gap:4px!important;width:100%!important;max-width:100%!important;box-sizing:border-box;justify-content:center}
html.phone-layout #full-view.unified-viewer-drawer :is(#full-out,#full-in,#full-prompt,#full-download,#full-scale,#full-still-play):not([hidden]){display:inline-flex!important;align-items:center;justify-content:center}
html:not(.phone-layout):not(.immersive) #full-view.unified-viewer-drawer .full-toolbar{min-height:0!important;height:auto!important;padding-block:0!important;border:0}
html:not(.phone-layout):not(.immersive) #full-view.unified-viewer-drawer .full-actions{width:100%!important;max-width:100%!important;flex-wrap:wrap!important;box-sizing:border-box}
html.immersive #full-view.unified-viewer-drawer .immersive-controls{left:var(--viewer-drawer-center,50%)!important;max-width:var(--viewer-drawer-width,calc(100vw - 16px))!important;bottom:calc(42px + env(safe-area-inset-bottom))!important}
html.immersive #full-view.unified-viewer-drawer .immersive-controls .viewer-control-rows-clip[data-drawer-active=true]{display:flex;flex-wrap:wrap;align-content:flex-start;align-items:center;justify-content:center;gap:8px;flex:1 1 100%!important}
html.immersive #full-view.unified-viewer-drawer #viewer-controls-drawer-handlebar.viewer-drawer-fullscreen-handle{position:fixed;z-index:2147483647;bottom:max(4px,env(safe-area-inset-bottom));left:var(--viewer-drawer-center,50%);transform:translateX(-50%);width:max-content;max-width:var(--viewer-drawer-width,calc(100vw - 16px));background:var(--footer-glass);border-radius:5px}
html.immersive #full-view.unified-viewer-drawer .immersive-controls.viewer-controls-empty{display:none!important}
html.immersive #full-view.unified-viewer-drawer .immersive-controls.viewer-drawer-measuring{display:flex!important;visibility:hidden!important}
@media(prefers-reduced-motion:reduce){#full-view.unified-viewer-drawer :is(.viewer-section-clip,.viewer-control-rows-clip){transition:none!important}}

html.phone-layout #full-view#full-view.unified-viewer-drawer .full-actions>:is(button,a):not([hidden]){display:inline-flex!important;align-items:center;justify-content:center}

#full-view.unified-viewer-drawer.viewer-drawer-reflowing :is(.viewer-section-clip,.viewer-control-rows-clip){transition:none!important}

#full-view.unified-viewer-drawer #viewer-controls-drawer-handlebar{padding-inline:max(4px,env(safe-area-inset-left)) max(4px,env(safe-area-inset-right))}
#full-view.unified-viewer-drawer #full-video-layout{grid-template-columns:minmax(0,1fr)!important}
#full-view.unified-viewer-drawer #full-video-stage{grid-column:1!important}

/* Keep the one handle above adjacent artwork/rows; available on every open viewer. */
#full-view.unified-viewer-drawer #viewer-controls-drawer-handlebar{position:relative;z-index:4;pointer-events:auto;flex-shrink:0}

/* Single grabbable divider above prompt; no visible Controls controller. */
#full-view.unified-viewer-drawer #viewer-controls-drawer-handle{min-width:64px;min-height:28px;height:28px;flex:1 1 auto;padding:0!important;border:0!important;background:transparent!important;box-shadow:none!important;border-radius:0}
#full-view.unified-viewer-drawer #viewer-controls-drawer-handle::before{top:calc(50% - 2px);left:calc(50% - 24px);width:48px;height:4px;opacity:1}
html.phone-layout #full-view#full-view.unified-viewer-drawer #viewer-controls-drawer-handle{min-height:32px!important;height:32px!important}
html.phone-layout #full-view#full-view.unified-viewer-drawer .full-actions>:is(#full-in,#full-out){display:none!important}
/* Reuse the existing status box in the active viewer rather than leaving it behind the modal. */
#full-view>.viewer-collection-status{position:fixed!important;left:var(--viewer-counter-left,16px)!important;top:var(--viewer-counter-top,calc(var(--common-height) + 8px))!important;right:auto;bottom:auto;display:flex;flex-direction:column;align-items:flex-start;width:110px;min-width:110px;max-width:110px;gap:2px;z-index:44;isolation:isolate;font-size:11px}
#full-view .viewer-collection-status::before{content:'';position:absolute;inset:-6px -8px;z-index:-1;border:1px solid var(--footer-glass-line);border-radius:6px;background:var(--footer-glass)}
#full-view .viewer-collection-status #match-count{font-size:18px}
html.phone-layout #full-view .viewer-collection-status::before{inset:0;border-radius:5px}
html.phone-layout #full-view .viewer-collection-status.viewer-status-collapsed{display:none!important}

html.phone-layout #full-view .fullscreen-zoom :is([aria-label="Zoom in"],[aria-label="Zoom out"]){display:none!important}

html.phone-layout:not(.immersive) #full-view#full-view.unified-viewer-drawer .full-body{min-height:var(--viewer-drawer-image-min,min(120px,20dvh))!important}
/* Theme remains an original needed tool; only redundant phone zoom/prompt buttons are removed. */
html.phone-layout #full-view#full-view.unified-viewer-drawer #phone-viewer-core #full-theme-toggle{display:inline-flex!important}
html.immersive #full-view.unified-viewer-drawer #viewer-controls-drawer-handlebar.viewer-drawer-fullscreen-handle{bottom:var(--viewer-grip-bottom,max(4px,env(safe-area-inset-bottom)))}

/* Clear single controller; arrows keep independent directions inside the same handle. */
#full-view.unified-viewer-drawer #viewer-controls-drawer-handle{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:32px;height:32px;padding:0 12px!important;border:1px solid var(--footer-glass-line)!important;border-radius:4px;background:var(--footer-button-glass)!important;font-size:11px}
#full-view.unified-viewer-drawer #viewer-controls-drawer-handle::before{display:none}
#viewer-controls-drawer-handle [data-drawer-direction]{display:inline-flex;align-items:center;justify-content:center;align-self:stretch;min-width:28px;font-size:18px;line-height:1}
html.phone-layout #full-view#full-view.unified-viewer-drawer #viewer-controls-drawer-handle{min-height:44px!important;height:44px!important}
@media(any-pointer:coarse){#full-view.unified-viewer-drawer #viewer-controls-drawer-handle{min-height:44px!important;height:44px!important}}

/* Explicit directions share the existing common surface and dimensions. */
#full-view.unified-viewer-drawer #viewer-controls-drawer-handlebar>button{flex:1 1 0;min-width:0;height:44px;min-height:44px;padding:0 8px!important;border:1px solid var(--footer-glass-line)!important;border-radius:4px;background:var(--footer-button-glass)!important;color:var(--footer-glass-ink);font:inherit;font-size:12px;touch-action:none;user-select:none;cursor:ns-resize}
#full-view.unified-viewer-drawer #viewer-controls-drawer-handle{justify-content:center}
html.phone-layout #full-view.unified-viewer-drawer #phone-viewer-core{display:flex!important;flex-wrap:nowrap!important;gap:3px!important;align-items:center;justify-content:center;width:100%;box-sizing:border-box}
html.phone-layout #full-view.unified-viewer-drawer #phone-viewer-core .favorite-access{display:contents!important}
html.phone-layout #full-view.unified-viewer-drawer #phone-viewer-core :is(button,a){flex:1 1 0!important;min-width:0!important;width:auto!important;max-width:44px;height:44px!important;min-height:44px!important;padding:0!important;box-sizing:border-box;font-size:0!important;line-height:0!important}
html.phone-layout #full-view.unified-viewer-drawer #phone-viewer-core [data-phone-caption]::after{font-size:0!important}
html.phone-layout #full-view.unified-viewer-drawer #viewer-extra-tools{display:flex;align-items:center;justify-content:center;gap:4px;width:100%;box-sizing:border-box}
html.phone-layout #full-view.unified-viewer-drawer #viewer-extra-tools>:is(button,a){display:inline-flex!important;align-items:center;justify-content:center;flex:0 1 64px;min-width:40px!important;min-height:44px!important;height:44px!important;padding:0 6px!important;margin:0;box-sizing:border-box;font-size:11px!important;line-height:1.1;text-decoration:none}
html.phone-layout #full-view.unified-viewer-drawer #viewer-extra-tools>#full-prompt{display:inline-flex!important}
html.phone-layout #full-view.unified-viewer-drawer #viewer-extra-tools>#full-scale{display:inline-flex!important}
html.phone-layout #full-view.unified-viewer-drawer .full-actions:empty{display:none!important}
html.phone-layout #full-view.unified-viewer-drawer :is(#phone-viewer-core,#viewer-extra-tools) #full-related-toggle::after{content:"▤"!important;font-size:22px!important;line-height:1!important;display:inline-block!important}
html.phone-layout #full-view.unified-viewer-drawer :is(#phone-viewer-core,#viewer-extra-tools) #full-slideshow::after{content:"▷"!important;font-size:22px!important;line-height:1!important;display:inline-block!important}
html.phone-layout #full-view.unified-viewer-drawer #phone-viewer-core #full-info-toggle::after{content:"ⓘ"!important;font-size:22px!important;line-height:1!important;display:inline-block!important}
html.phone-layout #full-view.unified-viewer-drawer #phone-viewer-core button[aria-label="Exhibitions"]::after{content:"▣"!important;display:inline-block;font-size:22px;line-height:1}
html.phone-layout #full-view.unified-viewer-drawer #viewer-extra-tools #full-fullscreen{font-size:0!important;line-height:0!important}
html.phone-layout #full-view.unified-viewer-drawer #viewer-extra-tools #full-fullscreen::after{content:""!important;display:inline-block!important;width:22px!important;height:22px!important;background:currentColor!important}



/* Fill the existing three rows; keep command order, heights and icon sizes. */
html.phone-layout #full-view#full-view.unified-viewer-drawer #phone-viewer-core :is(button,a){flex:1 1 0!important;min-width:0!important;width:0!important;max-width:none!important}
html.phone-layout #full-view#full-view.unified-viewer-drawer #viewer-extra-tools{gap:3px}
html.phone-layout #full-view#full-view.unified-viewer-drawer #viewer-extra-tools>:is(button,a){flex:1 1 0!important;max-width:none!important;width:0!important}

/* Viewer-only shared-hue slider backing; main-screen slider rules are untouched. */
html[data-theme=light] #full-view #video-transport{background:rgba(255,255,255,.85)!important}
html[data-theme=dark] #full-view #video-transport{background:rgba(40,40,40,.85)!important}
html #full-view #video-transport input[type=range]{background:transparent!important}
html #full-view.unified-viewer-drawer :is(#full-prompt-overlay,#full-video-prompt){-webkit-overflow-scrolling:touch;scrollbar-width:auto;overflow-wrap:anywhere}
html #full-view.unified-viewer-drawer :is(#full-prompt-overlay,#full-video-prompt) p{max-height:none!important;overflow:visible!important;white-space:normal;-webkit-line-clamp:unset!important}
html.phone-layout #full-view#full-view.unified-viewer-drawer #phone-viewer-core #full-fullscreen{font-size:0!important;line-height:0!important}
html.phone-layout #full-view#full-view.unified-viewer-drawer #phone-viewer-core #full-fullscreen::after{content:""!important;display:inline-block!important;width:22px!important;height:22px!important;background:currentColor!important}
html.phone-layout #full-view.unified-viewer-drawer #viewer-extra-tools :is(#full-related-toggle,#full-slideshow){font-size:0!important;line-height:0!important}

/* The prompt moved out of the old footer; undo its legacy decorative hit-testing rule. */
html #full-view#full-view :is(#full-prompt-overlay,#full-video-prompt){pointer-events:auto!important;touch-action:pan-y pinch-zoom!important;cursor:auto}
html #full-view#full-view :is(#full-prompt-overlay,#full-video-prompt) *{pointer-events:auto!important}

/* Download/playback row uses words, with the original action nodes and states. */
html.phone-layout #full-view#full-view.unified-viewer-drawer #viewer-extra-tools>:is(button,a){font-size:11px!important;line-height:1.1!important}
html.phone-layout #full-view#full-view.unified-viewer-drawer #viewer-extra-tools>:is(button,a)::before,html.phone-layout #full-view#full-view.unified-viewer-drawer #viewer-extra-tools>:is(button,a)::after{display:none!important}
html.phone-layout #full-view#full-view.unified-viewer-drawer #viewer-extra-tools #full-slideshow{font-size:0!important}
html.phone-layout #full-view#full-view.unified-viewer-drawer #viewer-extra-tools #full-slideshow::after{display:inline!important;content:"Slides"!important;font-size:11px!important;line-height:1.1!important}
html #full-view#full-view :is(#viewer-extra-tools,.full-actions)>.cvb-refresh-action svg{display:none!important}
html #full-view#full-view :is(#viewer-extra-tools,.full-actions)>.cvb-refresh-action::after{display:inline!important;content:"Reload"!important;font:inherit;font-size:11px!important;line-height:1.1!important}
html:not(.phone-layout) #full-view#full-view .full-actions :is(#full-out,#full-in){font-size:0!important}
html:not(.phone-layout) #full-view#full-view .full-actions :is(#full-out,#full-in)::after{font-size:11px!important;line-height:1.1!important;white-space:normal}
html:not(.phone-layout) #full-view#full-view .full-actions #full-out::after{content:"Zoom Out"}
html:not(.phone-layout) #full-view#full-view .full-actions #full-in::after{content:"Zoom In"}
html.phone-layout #full-view#full-view#full-view.unified-viewer-drawer #viewer-extra-tools>.cvb-refresh-action::after{display:inline!important;content:"Reload"!important;font-size:11px!important;line-height:1.1!important}

/* R129j panel and stage presentation; layout belongs to cvb-footer-owned. */
.viewer-section-clip.cvb-height-panel{height:var(--cvb-panel-height,88px)!important;max-height:none!important;overflow:hidden!important;transition:none!important}
.viewer-section-clip .cvb-panel-scroll :is(.full-description,#full-prompt-overlay,#full-video-prompt):not([hidden]){max-height:none!important;overflow:visible!important;overscroll-behavior:auto;flex:none!important}
.viewer-section-clip[hidden]{display:none!important}
.viewer-control-rows-clip[data-drawer-active=true]{height:auto!important;overflow:visible!important;transition:none!important}
#viewer-controls-pull-grip{grid-column:1/-1}
#viewer-controls-drawer-handlebar>button{cursor:pointer!important;touch-action:manipulation!important}
#viewer-controls-drawer-handle::before{display:none!important}
/* A framed gallery wall rather than a stop symbol; labels/actions remain native. */
html.phone-layout #phone-map-options #navigation-controls#navigation-controls #map-favorites button[aria-label="Exhibitions"]::after,
html.phone-layout #full-view.unified-viewer-drawer #phone-viewer-core button[aria-label="Exhibitions"]::after{content:""!important;display:inline-block!important;width:22px;height:22px;background:currentColor;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cg fill='none' stroke='black' stroke-width='1.4'%3E%3Cpath d='M2 20V4h20v16M2 20h20M5 7h5v7H5zM14 7h5v7h-5zM7 17h10'/%3E%3C/g%3E%3C/svg%3E") center/contain no-repeat}

html #full-view [data-cvb-transport-empty]{display:none!important}
html #full-view.unified-viewer-drawer .viewer-control-rows-clip>#video-transport:not([data-cvb-transport-empty]){position:static!important;display:flex;flex:none;width:100%;box-sizing:border-box;background:var(--footer-glass)!important}

html #full-view .cvb-panel-scroll{border:0!important}
html #full-view .cvb-panel-scroll :is(#full-prompt-overlay,#full-video-prompt){border:0!important}

/* One layout owner: scrolling content followed by measured, non-overlay rail. */
.cvb-footer-owned #viewer-drawer-content{display:flex;flex-direction:column;min-height:0;overflow:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;touch-action:pan-y pinch-zoom}
.cvb-footer-owned #viewer-drawer-content>.viewer-section-clip{flex:none;order:0}
.cvb-footer-owned #viewer-drawer-content>#viewer-section-prompt{order:-2!important}
.cvb-footer-owned #viewer-drawer-content>#viewer-section-metadata{order:-1!important}
.cvb-footer-owned .viewer-controls-scrollport{display:block!important;max-height:none!important;height:auto!important;overflow:visible!important;flex:none!important}
.cvb-footer-owned #viewer-controls-drawer-handlebar{position:static!important;inset:auto!important;transform:none!important;order:0!important;margin-block:0!important}
.cvb-footer-owned [data-cvb-empty-row],.cvb-footer-owned [data-cvb-row-hidden]{display:none!important}
.cvb-footer-owned .viewer-section-clip.cvb-height-panel{display:flex!important;flex-direction:column!important}
.cvb-footer-owned .viewer-section-clip[hidden]{display:none!important}
/* Native scrollbars belong to the constrained content, not the inner text. */
.viewer-section-clip .cvb-panel-scroll{scrollbar-width:auto;scrollbar-gutter:stable}

/* A short landscape uses an outer scrolling drawer; inner fields must chain at their limits. */
@media(max-height:500px) and (orientation:landscape){
 html.phone-layout:not(.immersive) #full-view.unified-viewer-drawer #viewer-drawer-content .cvb-panel-scroll{overscroll-behavior-y:auto!important}
}

/* Only the inner drawer scrolls; focus must not pan the fixed viewer beneath its header. */
html.phone-layout:not(.immersive) #full-view#full-view#full-view.unified-viewer-drawer{overflow:clip!important}

#viewer-information-rail{display:flex;flex-direction:column;flex:none;min-height:0;width:100%;background:var(--footer-glass);overflow:hidden}
#viewer-information-rail>.viewer-section-clip{flex:none}
