#tour-controls{position:fixed;z-index:25;left:50%;transform:translateX(-50%);bottom:max(12px,env(safe-area-inset-bottom));width:min(620px,calc(100vw - 24px - env(safe-area-inset-left) - env(safe-area-inset-right)));max-height:34dvh;overflow:auto;padding:12px 16px;border:1px solid #b59c68;border-radius:14px;background:#142f25f5;color:#eee7d9;overscroll-behavior:contain}#tour-controls p{margin:4px 0;line-height:1.4;font-size:13px}#tour-controls select{width:100%;margin:6px 0}#tour-controls .actions{gap:6px;flex-wrap:wrap}#tour-controls button{min-height:44px}#tour-controls small{color:#d0bc91}#tour-controls .check{margin:6px 0;font-size:13px}.tour-active #visitor-footer{display:none}.tour-active #touch-controls{bottom:calc(35dvh + 12px)}
#tour-editor{position:fixed;left:max(12px,env(safe-area-inset-left));top:max(12px,env(safe-area-inset-top));z-index:28;width:min(340px,calc(100vw - 26px));max-height:calc(100dvh - 32px - env(safe-area-inset-bottom));overflow:auto;padding:16px;background:#17352af5;color:#f0ebdd;border:1px solid #bba16d;border-radius:14px;overscroll-behavior:contain}#tour-editor h2{font:22px Georgia;margin:0}#tour-editor h3{font-size:15px}#tour-editor label{display:block;margin:8px 0;font-size:13px}#tour-editor input,#tour-editor select,#tour-editor textarea{width:100%;min-height:44px;background:#f7f2e8;color:#18362b;border:1px solid #a39678;border-radius:8px;padding:8px}#tour-editor button{min-height:44px;margin:3px 0}#tour-editor .actions{flex-wrap:wrap}#tour-editor ol{padding-left:24px}#tour-editor li button{width:100%;text-align:left}.tour-authoring #return-editor{display:none}#visitor-tours article{border-bottom:1px solid #97845b;padding:8px 0}.surface-dialog{width:min(900px,calc(100vw - 24px));max-height:calc(100dvh - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom));overflow:auto}.surface-map{display:block;width:100%;height:min(48dvh,440px);background:#d3ccba;border-radius:8px;touch-action:none;cursor:move}.surface-dialog .actions{flex-wrap:wrap}.surface-dialog [data-warning]{white-space:pre-wrap;color:#874f24;font-size:13px}.surface-dialog button{min-height:44px}.surface-dialog [data-grid]{width:20px;height:20px;min-height:0}.surface-dialog svg image{image-rendering:auto}
@media(pointer:coarse){input,textarea,select{font-size:16px}button,.action-link{min-height:44px}#media-view{touch-action:none}#media-view canvas{touch-action:none}.surface-dialog label{font-size:14px}#touch-controls{left:max(16px,env(safe-area-inset-left));right:max(16px,env(safe-area-inset-right))}}
@media(max-width:600px){#tour-controls{padding:9px 12px}#tour-controls .actions button{flex:1}#tour-controls p{max-height:54px;overflow:auto}#tour-editor{width:min(310px,calc(100vw - 24px));max-height:65dvh}.surface-dialog .field-grid{grid-template-columns:1fr 1fr}.viewer-layout{grid-template-columns:1fr!important}#exhibit-viewer{max-height:calc(100dvh - env(safe-area-inset-top) - env(safe-area-inset-bottom) - 16px)}#media-view{min-height:38dvh}#exhibit-viewer article{max-height:28dvh;overflow:auto}}
@media(max-height:500px) and (orientation:landscape){#tour-controls{left:auto;right:max(8px,env(safe-area-inset-right));transform:none;width:min(330px,44vw);max-height:60dvh}.tour-active #touch-controls{bottom:calc(14px + env(safe-area-inset-bottom));right:47vw}#tour-editor{max-height:calc(100dvh - 24px);width:300px}#exhibit-viewer .viewer-layout{grid-template-columns:1.6fr 1fr!important}#media-view{min-height:60dvh}}

#tour-editor.tour-editor-folded > :not(.visitor-panel-heading):not(.tour-capture){display:none!important}.tour-capture{display:flex;flex-wrap:wrap;gap:6px}
