@charset "UTF-8";
.phase-card{background:rgba(247,250,248,.87);padding:12px 14px;border-radius:9px;backdrop-filter:blur(8px)}
:root{font-family:system-ui,-apple-system,"Segoe UI",sans-serif;color:#172c33;font-size:16px;--ink:#172c33;--accent:#a65430;--line:#d8deda;--panel:rgba(255,255,255,.94)}*{box-sizing:border-box}body{margin:0;overflow:hidden;background:#b9d3e0}button,select,input{font:inherit}button,summary,select{cursor:pointer}button{border:1px solid transparent;background:transparent;color:var(--ink);border-radius:7px;padding:9px 12px;transition:background .15s}button:hover{background:#e9ede9}button:focus-visible,summary:focus-visible,a:focus-visible{outline:3px solid #ac693a;outline-offset:3px}button:disabled{opacity:.45}input[type=range]{accent-color:var(--accent);cursor:pointer}button[aria-pressed=true]{background:#ead9c9}header{position:absolute;top:0;left:0;right:0;padding:20px 28px;display:flex;align-items:center;justify-content:space-between;pointer-events:none}.brand,.header-actions{pointer-events:auto}.brand{display:flex;gap:10px;align-items:center;text-decoration:none;color:var(--ink);font-size:12px;letter-spacing:.2em;line-height:1.6}.brand b{display:block;font-size:14px;font-weight:650;letter-spacing:.1em}.brand-mark{font-size:32px;line-height:1}.header-actions{display:flex;gap:6px;background:var(--panel);border:1px solid #fff8;padding:4px;border-radius:10px;box-shadow:0 4px 25px #1232;font-size:14px}.header-actions #help{font-weight:700;width:36px;border-left:1px solid var(--line)}#workspace{position:relative;width:100vw;height:100dvh;min-height:540px}#scene{width:100%;height:100%;display:block;touch-action:none;outline:none}.phase-card{position:absolute;top:112px;left:28px;width:250px;pointer-events:none}.eyebrow{font-size:12px;letter-spacing:.18em;font-weight:700;color:#78543f}.phase-card h1{font-family:Georgia,serif;font-weight:400;font-size:31px;line-height:1.15;margin:10px 0 12px}.phase-card p{font-size:15px;line-height:1.6;margin:0;color:#3a4f56}.phase-note{font-size:12px;line-height:1.5;border-top:1px solid #778d9666;margin-top:17px;padding-top:12px;max-width:240px}.view-tools{position:absolute;left:28px;bottom:235px;width:215px;background:var(--panel);border:1px solid #fffa;border-radius:10px;box-shadow:0 8px 32px #14293212;padding:6px;font-size:14px}.view-tools>button{width:100%;text-align:left}details{border-top:1px solid var(--line)}summary{padding:11px 12px;list-style:none;display:flex;justify-content:space-between}summary:after{content:'+'}details[open]>summary:after{content:'−'}.view-grid{display:grid;grid-template-columns:1fr 1fr;gap:3px;padding:4px}.view-grid button{font-size:12px;padding:9px 3px;border:1px solid var(--line)}.view-tools label{display:block;padding:5px 10px;font-size:13px}.view-tools input,.view-tools select{display:block;width:100%;margin-top:5px}.view-tools output{float:right;font-size:12px;color:#705342}.view-tools select{padding:5px;border:1px solid var(--line);border-radius:5px;background:white;font-size:12px}.canvas-hint{position:absolute;bottom:210px;left:50%;transform:translateX(-50%);font-size:12px;white-space:nowrap;color:#273a44aa}.canvas-hint span{margin:0 9px}.timeline-panel{position:absolute;bottom:18px;left:28px;right:28px;background:var(--panel);border:1px solid #fffa;box-shadow:0 12px 40px #172c3324;border-radius:13px;padding:10px 20px 14px}.timeline-head{display:flex;align-items:center;gap:20px;min-height:38px}.playback{display:flex;align-items:center;gap:3px}.playback button{font-size:19px;padding:5px 9px}.playback .play{background:var(--ink);color:#fff;width:39px;height:37px;border-radius:50%;font-size:15px}.playback .play:hover{background:#a65430}.speed-label select{border:0;background:transparent;font-size:13px;padding:5px}.timeline-caption{display:flex;align-items:center;gap:12px;font-size:14px;font-weight:650}.timeline-caption span+span{font-size:12px;font-weight:400;color:#697980;border-left:1px solid var(--line);padding-left:12px}.render-status{margin-left:auto;font-size:12px;color:#58696f}#timeline{width:100%;margin:8px 0 11px;height:4px;display:block}.phase-list{display:grid;grid-template-columns:repeat(9,1fr);gap:9px}.phase-button{display:flex;align-items:center;gap:8px;text-align:left;padding:5px;border:1px solid transparent;border-radius:7px;min-width:0}.phase-button img,.phase-button .wood-thumb{width:48px;height:49px;border-radius:4px;object-fit:cover;flex-shrink:0;background:#70503a}.phase-button span{font-size:12px;line-height:1.4}.phase-button strong{display:block;font-weight:650;font-size:14px}.phase-button.active{border-color:#b46d42;background:#f3e6d9}.phase-button.active strong{color:#964923}.wood-thumb{display:flex;align-items:center;justify-content:center;color:#fff;font-family:Georgia,serif;font-size:29px}.phase-button:hover{background:#e5e9e6}#referencePanel{position:absolute;right:28px;top:100px;width:min(360px,29vw);border-radius:10px;overflow:hidden;background:var(--panel);box-shadow:0 10px 35px #172c3333}#referencePanel[hidden]{display:none}.ref-header{display:flex;align-items:center;justify-content:space-between;padding:6px 12px;font-size:12px;letter-spacing:.08em}.ref-header button{font-size:22px;padding:0 7px}#referenceImage{width:100%;max-height:48vh;object-fit:contain;display:block;background:#e3e8e7}#referencePanel p{font-size:12px;line-height:1.5;padding:0 13px 2px;color:#5b6970}#loading{position:absolute;inset:0;z-index:8;display:flex;align-items:center;justify-content:center;flex-direction:column;background:#e9eef0e8;color:var(--ink)}#loading[hidden]{display:none}.loader{width:32px;height:32px;border:2px solid #172c3333;border-top-color:var(--accent);border-radius:50%;animation:spin 1s linear infinite}@keyframes spin{to{transform:rotate(360deg)}}dialog{max-width:540px;border:1px solid #d8deda;border-radius:12px;padding:30px;box-shadow:0 20px 90px #0004;color:var(--ink);max-height:85vh;line-height:1.65}dialog::backdrop{background:#10242f80;backdrop-filter:blur(5px)}dialog h2{font:normal 30px Georgia,serif}.dialog-close{float:right;font-size:24px}dialog p,dialog li{font-size:15px}dialog a{color:var(--accent)}.muted{color:#65737a;font-size:13px!important}.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0)}
@media(max-width:1150px){.phase-button{gap:4px}.phase-button img,.phase-button .wood-thumb{width:34px;height:40px}.phase-button span{font-size:10px}.phase-button strong{font-size:12px}.phase-list{gap:3px}.timeline-panel{padding:10px 12px}.phase-card{width:220px}.phase-card h1{font-size:27px}.canvas-hint{font-size:11px}}
@media(max-width:760px){header{padding:12px}.brand{font-size:10px}.brand b{font-size:11px}.header-actions button{padding:6px 8px}.header-actions button span{display:none}.phase-card{top:80px;left:15px;width:180px}.phase-card h1{font-size:24px;margin:7px 0}.phase-card p{font-size:13px;line-height:1.45}.phase-note{display:none}.view-tools{left:12px;bottom:205px;width:155px;font-size:12px}.view-tools label{font-size:12px}.view-grid{grid-template-columns:1fr}.view-grid button{padding:5px}.timeline-panel{left:8px;right:8px;bottom:8px;padding:8px 10px}.timeline-head{gap:7px;flex-wrap:wrap}.render-status{font-size:10px}.timeline-caption{font-size:12px}.timeline-caption span+span{display:none}.phase-list{overflow-x:auto;display:flex;gap:5px;padding-bottom:2px}.phase-button{flex:0 0 74px;display:block;text-align:center;padding:4px}.phase-button img,.phase-button .wood-thumb{width:60px;height:39px;margin:auto}.phase-button span{font-size:10px;display:block}.phase-button strong{display:inline;font-size:11px;margin-right:3px}.canvas-hint{display:none}#referencePanel{right:12px;top:79px;width:44vw}#referenceImage{max-height:36vh}.ref-header{font-size:10px;padding:5px 7px}.brand-mark{font-size:27px}.view-tools:has(details[open]){max-height:46vh;overflow-y:auto}#referencePanel p{font-size:10px}}
@media(prefers-reduced-motion:reduce){*{transition:none!important}.loader{animation:none}}

@media(max-width:1100px) and (min-width:761px){.phase-card{top:90px;left:28px;width:calc(100% - 300px)}.phase-card h1{font-size:24px;margin:6px 0}.phase-card p{font-size:13px;line-height:1.45;max-width:410px}.phase-note{display:none}.view-tools{right:28px;left:auto;top:93px;bottom:auto;width:195px}.view-tools:has(details[open]){max-height:55vh;overflow-y:auto}.canvas-hint{display:none}}
@media(max-width:760px){.view-tools{right:12px;left:auto;top:85px;bottom:auto;width:145px}.phase-card{width:calc(100% - 185px)}.phase-card h1{font-size:20px}.phase-card p{font-size:12px;line-height:1.35}.phase-list .phase-button span{font-size:12px}.phase-list .phase-button strong{font-size:12px}.phase-list .phase-button{flex-basis:84px}}@media(max-height:620px){body{overflow-y:auto}#workspace{height:620px;min-height:620px}} @media(min-width:761px) and (max-width:1100px){.phase-list{display:flex;overflow-x:auto}.phase-button{flex:0 0 88px}.phase-button span{font-size:12px}.phase-button strong{font-size:13px}.phase-button img,.phase-button .wood-thumb{width:35px;height:44px}}

.view-tools{top:92px;bottom:auto;right:28px;left:auto}.view-tools>#viewControls{border:0}.view-tools #overview{width:100%;text-align:left}.view-tools:has(#viewControls[open]){max-height:60vh;overflow-y:auto}@media(max-width:1100px) and (min-width:761px){.phase-card{top:84px}.phase-card h1{font-size:22px;margin:4px 0}.phase-card p{font-size:12px;max-width:410px}.view-tools{top:92px}}@media(max-width:760px){.view-tools{top:84px;right:12px;width:145px}.view-tools>#viewControls>summary{font-size:12px;padding:9px 7px}}
.ref-selects{display:flex;gap:10px;padding:5px 12px 12px}.ref-selects label{font-size:11px;flex:1}.ref-selects select{width:100%;display:block;margin-top:4px;padding:5px;border:1px solid var(--line);border-radius:5px;background:white;font-size:12px}.ref-selects [hidden]{display:none}#referencePanel{z-index:4;width:min(410px,45vw)}#exportDownload{display:inline-block;padding:10px 15px;background:var(--ink);color:white;text-decoration:none;border-radius:6px}

.view-tools .context-toggle{display:flex;gap:8px;align-items:center;padding:10px;font-size:13px}.view-tools .context-toggle input{width:auto;margin:0;accent-color:var(--accent)}

/* Dated milestones remain readable; details open without covering the whole model. */
.phase-card{pointer-events:auto;max-height:calc(100dvh - 330px);overflow:auto;width:290px}.phase-period{font-size:16px;font-weight:650;line-height:1.5;margin:0 0 10px;color:#78543f}.phase-card p{font-size:15px}.phase-card h1{font-size:28px}.phase-note{font-size:13px}.wall-status{font-size:13px;margin-top:9px;color:#4a5f58}.phase-card #historyToggle{margin-top:9px;padding:6px 9px;font-size:14px;border:1px solid #c6cfc7;background:#fff9}.phase-list{display:flex;overflow-x:auto;gap:6px;padding-bottom:3px}.phase-button{flex:1 0 142px}.phase-button span{font-size:13px}.phase-button small{display:block;font-size:12px;line-height:1.35;color:#705342;margin-top:2px}.phase-button img,.phase-button .wood-thumb{width:38px;height:47px}.timeline-panel{padding-bottom:10px}.canvas-hint{bottom:222px}
#historyDialog{width:min(800px,94vw);max-width:800px}#historyDialog h2{margin:12px 0 6px}#historyDialog p,#historyDialog dd{font-size:16px}#historyDialog h3{font-size:18px;border-top:1px solid var(--line);padding-top:16px}#historySources{display:flex;flex-direction:column;gap:5px;font-size:14px}.source-label{font-weight:650;margin-bottom:5px}#legendList{display:grid;grid-template-columns:minmax(120px,1fr) 2fr;gap:9px 18px}#legendList dt{font-weight:650;font-size:15px}#legendList dd{margin:0}.history-jumps{display:flex;flex-wrap:wrap;gap:6px}.history-jumps button{border:1px solid var(--line);font-size:14px}#historyWallStatus{color:#78543f}
@media(max-width:1100px){.phase-card{width:calc(100% - 285px);max-width:480px;top:85px}.phase-card h1{font-size:24px}.phase-card p{font-size:14px}.phase-list .phase-button{flex:0 0 158px}.timeline-caption{font-size:13px}}@media(max-width:760px){.phase-card{left:12px;width:calc(100% - 180px);max-height:calc(100dvh - 315px)}.phase-card h1{font-size:21px}.phase-card p{font-size:14px}.phase-period{font-size:14px}.phase-list .phase-button{flex:0 0 130px;display:flex;text-align:left}.phase-list .phase-button img{width:30px;height:42px}.phase-list .phase-button strong{display:block}.phase-list .phase-button small{font-size:12px}.timeline-caption{max-width:65vw}.timeline-head{gap:6px}.wall-status{font-size:12px}.phase-card #historyToggle{font-size:13px}#legendList{grid-template-columns:1fr;gap:3px}#legendList dd{margin-bottom:10px}}
@media(max-width:1100px){.phase-card #phaseDescription{display:none}.phase-card{max-width:390px}.phase-card h1{font-size:22px}.phase-card .phase-period{margin-bottom:0}.phase-card #historyToggle{margin-top:6px}.wall-status{margin-top:5px}}

#environmentKey,#mapScale{display:none}.map-view .phase-card{display:none}.map-view #environmentKey{display:flex;flex-direction:column;gap:3px;position:absolute;left:28px;top:94px;padding:10px 13px;background:var(--panel);border-radius:9px;font-size:14px}.map-view #environmentKey span{font-size:12px;color:#5b6c67}.map-view #environmentKey button{font-size:12px;padding:5px 0;text-align:left}.map-view #mapScale{display:block;position:absolute;left:28px;bottom:230px;background:#ffffffce;border-radius:5px;padding:7px 10px;font-size:12px;pointer-events:none}#mapScaleLine{display:block;height:7px;border:2px solid #263c36;border-top:0;margin-top:4px}@media(max-width:760px){.map-view #environmentKey{left:12px;top:84px}.map-view #mapScale{left:14px;bottom:224px}}

.brand .church-name{font-size:12px;letter-spacing:.085em;font-weight:650}.brand .church-name b{font-size:10px;letter-spacing:.12em;font-weight:500;margin-top:3px}@media(max-width:760px){.brand .church-name{font-size:10px;max-width:240px}.brand .church-name b{font-size:9px}}@media(max-width:450px){.brand .church-name{max-width:185px;font-size:9px}.brand{gap:6px}.brand .church-name b{font-size:8px}}

/* Keep the church visible from street level. */
#walkHelp[hidden]{display:none}#walkHelp{position:absolute;bottom:225px;left:50%;transform:translateX(-50%);max-width:calc(100% - 32px);width:max-content;display:flex;align-items:center;gap:12px;padding:10px 14px;background:var(--panel);border-radius:9px;z-index:3;font-size:12px}#walkHelp strong{white-space:nowrap}#walkHelp button{border:1px solid var(--line);border-radius:5px;white-space:nowrap}.walk-view .phase-card,.walk-view .canvas-hint{display:none}.walk-view #scene{cursor:grab}.walk-view #scene:active{cursor:grabbing}.view-tools [data-view="walk"]{font-size:13px;width:100%;text-align:left;padding:10px}.view-tools [data-view="walk"][aria-pressed="true"]{background:#dce7dd}@media(max-width:760px){#walkHelp{flex-wrap:wrap;justify-content:center;gap:5px;bottom:222px;width:calc(100% - 24px);font-size:11px}#walkHelp span{width:100%;text-align:center;order:2}}

.walk-view .brand{background:var(--panel);border-radius:9px;padding:10px 13px}

#planGroundOptions{padding:0 4px 9px}#planGroundOptions[hidden]{display:none}#planGroundNote{display:block;font-size:11px;line-height:1.4;color:#56675f;margin:6px 0}#groundPlanView{width:100%;text-align:left} .view-tools select:disabled,.view-tools input:disabled{opacity:.45}

/* Four equal settings sections and independently selectable overlays. */
[hidden]{display:none!important}
.view-tools{width:258px;max-height:calc(100dvh - 350px);overflow-y:auto;padding:6px;z-index:3}
.view-tools>details:first-child{border-top:0}
.view-tools>details>summary{font-size:14px;font-weight:550;gap:12px;padding:14px 11px}
.section-body{padding:0 4px 9px}.section-body p{font-size:13px;line-height:1.55;padding:0 8px}.control-note{color:#60736b}
.walk-actions{display:grid;gap:8px;padding:0 8px}.view-tools .walk-actions button{width:100%;min-height:42px;margin:0;padding:10px 12px;border:1px solid var(--line);text-align:left;font-size:13px}.view-tools #hideWalkPanels{background:var(--ink);border-color:var(--ink);color:white}.view-tools #hideWalkPanels:hover{background:#29444c}
.view-tools .view-grid{grid-template-columns:1fr 1fr}.view-grid button{font-size:12px;padding:10px 4px}
#overlayPanel{position:absolute;right:28px;top:78px;width:260px;padding:17px;background:var(--panel);border:1px solid white;border-radius:12px;box-shadow:0 12px 40px #172c3340;z-index:6}
#overlayPanel strong{display:block;margin-bottom:9px;font-size:15px}#overlayPanel label{display:flex;gap:9px;align-items:center;padding:10px 0;font-size:14px}#overlayPanel input{accent-color:var(--accent)}
#hideAll{width:100%;margin-top:10px;background:var(--ink);color:white}#overlayPanel small{display:block;line-height:1.5;color:#60736b;margin-top:10px}
#restoreControls{position:absolute;right:20px;bottom:20px;z-index:9;display:flex;gap:8px;align-items:center;border:1px solid #fffa;border-radius:30px;background:var(--panel);box-shadow:0 5px 25px #172c3333;padding:13px 17px;font-size:16px}
#restoreControls span{font-size:13px}.hide-player .timeline-panel,.hide-player .canvas-hint,.hide-legend .phase-card,.hide-legend #environmentKey,.hide-legend #mapScale,.hide-layout .view-tools{display:none!important}
.hide-controls .header-actions,.hide-controls>.phase-card,.hide-controls>.timeline-panel,.hide-controls>.view-tools,.hide-controls>#referencePanel,.hide-controls>#walkHelp,.hide-controls>.canvas-hint,.hide-controls>#mapScale,.hide-controls>#environmentKey,.hide-controls>#overlayPanel{display:none!important}
.hide-player #walkHelp{bottom:24px}.hide-player .phase-card,.hide-player .view-tools{max-height:calc(100dvh - 130px)}
.timeline-head{gap:12px;flex-wrap:wrap}.playback{gap:2px}.playback button{min-width:30px;min-height:36px;padding:5px 7px}
.timeline-caption{flex:1;min-width:180px}.render-status{font-size:11px}.timeline-panel{z-index:3}.timeline-caption #playState{white-space:nowrap}
.phase-card{width:310px;top:96px;max-height:calc(100dvh - 325px);padding:17px 18px;background:rgba(249,251,249,.94);box-shadow:0 6px 25px #172c3314;border:1px solid #ffffff70;border-radius:12px}
.phase-card h1{font-size:26px}.phase-card .phase-period{font-size:14px;margin-bottom:14px}.phase-card #phaseChange{display:none}
#narrativePanel{border-top:1px solid var(--line);padding-top:13px}.story-kicker{font-size:10px;letter-spacing:.13em;color:#7e543b;font-weight:650;margin-bottom:9px}
#narrativeText{display:block;font-family:Georgia,serif;font-size:18px;line-height:1.6;color:#253c40;min-height:142px}
.story-enter{animation:storyEnter .65s ease-out}@keyframes storyEnter{from{opacity:0;transform:translateY(5px)}to{opacity:1;transform:translateY(0)}}
.story-navigation{display:flex;align-items:center;justify-content:space-between;margin:6px 0 10px}.story-navigation button{font-size:18px;padding:4px 10px}.story-navigation span{font-size:11px;color:#667b75}
.source-buttons{display:flex;gap:5px;flex-wrap:wrap;border-top:1px solid var(--line);padding-top:12px}.source-buttons button{border:1px solid #cdd5ce;padding:7px 8px;font-size:11px;background:#fff8}.source-buttons #phaseSources{width:100%;text-align:left}.phase-card #historyToggle{font-size:12px}.phase-card .wall-status{font-size:11px}
@media(max-width:1100px){.phase-card{width:285px;max-width:calc(100% - 320px)}.phase-card h1{font-size:23px}.phase-card #narrativeText{font-size:17px;min-height:135px}.header-actions{gap:1px}.render-status{display:none}}
@media(max-width:760px){header{padding:10px 12px;flex-wrap:wrap;gap:7px}.brand{max-width:calc(100% - 220px)}.brand .church-name{font-size:9px}.header-actions button{padding:7px}.view-tools{top:87px;right:12px;width:210px;max-height:calc(100dvh - 320px)}.view-tools>details>summary{font-size:12px;padding:12px 8px}.phase-card{left:12px;top:87px;width:calc(100% - 245px);max-width:300px;padding:13px;max-height:calc(100dvh - 335px)}.phase-card h1{font-size:21px}.phase-card #narrativeText{font-size:16px;line-height:1.5;min-height:130px}.phase-card .phase-period{font-size:12px;margin-bottom:10px}.source-buttons button{font-size:10px}.timeline-head{gap:5px 10px}.timeline-caption{font-size:12px}.timeline-caption span+span{display:inline}.playback button{min-width:29px;padding:5px}.timeline-panel{padding:8px 10px}.phase-list .phase-button{flex-basis:145px}#overlayPanel{right:12px;top:72px}#referencePanel{right:12px;top:87px;width:min(420px,calc(100% - 24px))}#referenceImage{max-height:45vh}}
@media(max-width:540px){.brand{max-width:calc(100% - 165px)}.brand .church-name{font-size:8px}.brand-mark{display:none}.view-tools{top:81px;width:180px}.view-tools>details>summary{font-size:11px}.phase-card{top:81px;width:calc(100% - 216px);padding:10px;min-width:135px}.phase-card h1{font-size:18px}.phase-card .eyebrow{font-size:9px}.phase-card #narrativeText{font-size:14px}.phase-card .story-kicker{font-size:8px}.phase-card .source-buttons{gap:4px}.source-buttons button{width:100%;text-align:left}.phase-card .wall-status{display:none}.timeline-caption{font-size:11px}.playback button{min-width:27px}.playback .play{width:34px;height:34px}.speed-label select{font-size:12px;padding:4px}.hide-layout .phase-card{width:min(310px,calc(100% - 24px));max-width:none}}
@media(prefers-reduced-motion:reduce){.story-enter{animation:none}}



.brand-logo{display:block;width:48px;height:48px;object-fit:contain;flex-shrink:0;border-radius:50%;background:white}@media(max-width:760px){.brand-logo{width:36px;height:36px}}@media(max-width:540px){.brand-logo{width:30px;height:30px}.brand{gap:7px}}

.film-controls{padding:8px 8px 14px;border-bottom:1px solid var(--line);margin-bottom:8px}.film-controls>label{padding:0;margin:0 0 7px;display:block;font-weight:600}.film-controls select{width:100%}.film-controls p,.film-controls small{display:block;font-size:12px;line-height:1.5;color:#536861;margin:10px 0}.film-controls #playRoute{width:100%;border:1px solid var(--line);background:#e6ede6}
#minimizeLegend{position:sticky;top:0;float:right;margin:-6px -6px 2px 8px;width:30px;height:30px;padding:0;background:#edf2ed;font-size:22px;z-index:1}.phase-card>.eyebrow{padding-right:32px;min-height:24px}
#restoreLegend{position:absolute;top:96px;left:28px;padding:11px 15px;border:1px solid #ffffff70;border-radius:10px;background:var(--panel);box-shadow:0 6px 25px #172c3314;z-index:2;font-size:14px}#restoreLegend span{margin-left:20px}#restoreLegend[hidden]{display:none}
.legend-collapsed .phase-card{display:none!important}.hide-controls #restoreLegend,.hide-legend #restoreLegend,.walk-view #restoreLegend,.map-view #restoreLegend{display:none!important}
@media(max-width:760px){#restoreLegend{top:87px;left:12px;font-size:12px}}
@media(max-width:540px){#restoreLegend{top:81px}#minimizeLegend{width:26px;height:26px}.phase-card>.eyebrow{padding-right:20px}}

#minimizePlayer{position:absolute;right:12px;top:12px;width:30px;height:30px;padding:0;background:#edf2ed;font-size:22px}.timeline-head{padding-right:38px}
#restorePlayer{position:absolute;right:20px;bottom:20px;padding:12px 17px;border:1px solid #ffffff70;border-radius:12px;background:var(--panel);box-shadow:0 6px 25px #172c3314;z-index:4;font-size:14px}#restorePlayer span{margin-left:18px}#restorePlayer[hidden]{display:none}
.player-collapsed .timeline-panel,.player-collapsed .canvas-hint,.hide-controls #restorePlayer,.hide-player #restorePlayer{display:none!important}
.player-collapsed .view-tools{max-height:calc(100dvh - 170px)}.player-collapsed #walkHelp{bottom:80px}.player-collapsed #mapScale{bottom:24px}

#headerTime{font-variant-numeric:tabular-nums}.hide-controls .brand{max-width:100%;pointer-events:none}

.environment-settings{padding:6px 12px 14px}.view-tools .environment-settings label{padding:0;margin:0 0 7px;font-size:12px;font-weight:600}.view-tools .environment-settings select{margin:0;padding:9px 10px;width:100%;font-size:13px}
.environment-options{margin-top:18px}.environment-settings .setting-note{margin:8px 0 0;font-size:11px;line-height:1.5;color:#60736b}.environment-settings [hidden]{display:none!important}
.reference-settings{border-top:1px solid var(--line);margin-top:20px;padding-top:16px}.reference-settings h3{font-size:12px;font-weight:600;margin:0 0 9px}
#environmentPanel #referenceToggle,#groundPlanView{display:block;width:100%;margin:0;padding:10px;text-align:left;border:1px solid var(--line);font-size:13px;background:#ffffff80}#groundPlanView{margin-top:12px;text-align:center}#environmentPanel #referenceToggle[aria-expanded=true]{background:#ead9c9}

#routeShot{padding:8px 10px;border-left:2px solid var(--accent);background:#edf2ed;font-size:11px}#routeShot[hidden]{display:none}

/* Clean capture: Escape restores controls; no recovery button in the recording. */
.recording-route #restoreControls,.recording-route #restoreLegend,.recording-route #restorePlayer{display:none!important}

/* Association identity on loading and the fifth settings section. */
#loading{padding:28px 24px;text-align:center;background:#edf1ef}
.loading-logo{display:block;width:clamp(112px,24vw,160px);height:auto;aspect-ratio:1;object-fit:contain;border-radius:50%;background:white}
.loading-credit{max-width:390px;margin:24px 0 28px;font-size:18px;font-weight:550;line-height:1.6;text-wrap:balance}
#loadingText{font-size:14px;color:#60736b;max-width:440px;overflow-wrap:anywhere}
.contact-body{padding-bottom:14px}.contact-body a{display:block;margin:0 8px;padding:8px 0;color:var(--accent);font-size:13px;line-height:1.5;overflow-wrap:anywhere;text-underline-offset:3px}
.mobile-only,.mobile-sheet-head,.mobile-menu-footer,.mobile-camera-tabs,.mobile-walk-note,.mobile-image-tools{display:none}
.mobile-image-viewport{display:contents}
.view-tools>details:first-of-type{border-top:0}
@media(max-width:760px), (max-width:1000px) and (pointer:coarse){
 body{overflow:hidden}#workspace{position:fixed;inset:0;height:100dvh;min-height:0;--mobile-bar:calc(68px + env(safe-area-inset-bottom,0px))}
 #workspace header{padding:12px 16px;pointer-events:none}.brand{max-width:100%!important;pointer-events:none}.brand .church-name{font-size:10px;max-width:260px}.brand .church-name b{font-size:9px}.brand-logo{width:36px;height:36px}
 #workspace .header-actions,#workspace .canvas-hint,#workspace #restoreLegend,#workspace #restorePlayer,#workspace #walkHelp,#workspace #environmentKey,#workspace #mapScale{display:none!important}
 #workspace #legendCard,#workspace #playerPanel,#workspace .view-tools{display:none!important}
 #mobileBar{display:flex;position:absolute;bottom:0;left:0;right:0;z-index:7;height:var(--mobile-bar);padding:8px 12px calc(8px + env(safe-area-inset-bottom,0px));gap:10px;align-items:center;background:#fafcf9f5;border-top:1px solid #d8deda;box-shadow:0 -4px 25px #172c3312}
 #mobileBar button{min-height:48px}#mobilePlay{width:48px;flex-shrink:0;border-radius:50%;background:var(--ink);color:white;font-size:20px}#mobileTimeline{flex:1;padding:3px 4px;min-width:0;font-size:14px;font-weight:650;font-variant-numeric:tabular-nums}.mobile-bar-caption{display:block;font-size:11px;font-weight:400;margin-top:3px;color:#536861}#mobileMenu{width:58px;font-size:20px;padding:2px}
 #mobileBar [aria-expanded=true]{background:#e7ede5}
 #workspace[data-mobile-panel="timeline"] #playerPanel,#workspace[data-mobile-panel="story"] #legendCard,#workspace[data-mobile-panel="menu"] .view-tools{display:block!important;position:absolute;inset:auto 0 var(--mobile-bar);width:100%;min-width:0;max-width:none;height:min(38dvh,340px);max-height:calc(100dvh - var(--mobile-bar) - 72px)!important;margin:0;padding:0 16px 16px;border-radius:20px 20px 0 0;background:#fafcf9;box-shadow:0 -8px 28px #172c3325;z-index:6;overflow:auto;overscroll-behavior:contain;pointer-events:auto}
 #workspace[data-mobile-expanded="true"] .mobile-sheet{height:calc(100dvh - var(--mobile-bar) - 80px)!important}
 .mobile-sheet-head{position:sticky;top:0;display:flex;align-items:center;justify-content:space-between;background:#fafcf9;z-index:5;min-height:56px;border-bottom:1px solid var(--line);margin:0 -2px 14px;touch-action:none;gap:4px}.mobile-sheet-head:before{content:'';position:absolute;top:5px;left:calc(50% - 18px);width:36px;height:4px;border-radius:4px;background:#c5cec7}.mobile-sheet-head strong{font-size:16px;padding:14px 0 0;flex:1}.mobile-sheet-head button{min-width:44px;min-height:44px;font-size:20px;margin-top:8px;padding:6px}
 #workspace #minimizeLegend,#workspace #minimizePlayer{display:none!important}
 .timeline-head{padding:0;gap:8px}.timeline-caption,.render-status{display:none}.playback{width:100%;justify-content:center;gap:12px}.playback button,.speed-label select{min-height:44px;min-width:44px;font-size:18px}.playback .play{width:44px;height:44px}#timeline{height:28px;margin:10px 0;touch-action:pan-x}.phase-list{display:flex;overflow-x:auto;gap:8px;padding:0 0 8px;scroll-snap-type:x proximity}.phase-list .phase-button{flex:0 0 148px;display:flex;text-align:left;scroll-snap-align:start;min-height:76px}.phase-button img,.phase-button .wood-thumb{width:40px;height:45px;margin:0}.phase-button span{font-size:12px}.phase-button strong{display:block}
 #mobileAboutPhase{display:block;width:100%;min-height:44px;border:1px solid var(--line);font-size:14px;margin-top:8px}
 #workspace #legendCard .eyebrow{font-size:11px;padding:0;min-height:0}#workspace #legendCard h1{font-size:25px;margin:12px 0}#workspace #legendCard .phase-period{font-size:14px}#workspace #legendCard #narrativeText{font-size:18px;min-height:0}.story-navigation button{min-width:44px;min-height:44px}.source-buttons button{width:auto;min-height:44px;font-size:13px}.source-buttons #phaseSources{width:100%}#workspace #legendCard .wall-status{display:block}
 .view-tools>details>summary{font-size:15px;min-height:56px;padding:16px 0}.view-tools label,.view-tools select,.view-tools .environment-settings select{font-size:16px;min-height:44px}.view-tools input[type=range]{height:32px}.view-tools .section-body p,.film-controls p,.film-controls small,.environment-settings .setting-note{font-size:14px}.view-tools .view-grid button{font-size:14px;min-height:48px}.contact-body a{font-size:14px;min-height:44px}.environment-settings{padding:10px 0 18px}.view-tools .walk-actions button{min-height:48px}
 .mobile-menu-footer{display:flex;gap:8px;border-top:1px solid var(--line);padding-top:12px;margin-top:8px}.mobile-menu-footer button{flex:1;min-height:44px;border:1px solid var(--line);font-size:13px}
 .mobile-camera-tabs{display:flex;gap:8px;margin:12px 0}.mobile-camera-tabs button{flex:1;min-height:44px;border:1px solid var(--line);font-size:14px}.view-tools[data-camera-tab="film"] .view-grid,.view-tools[data-camera-tab="film"] #overview,.view-tools[data-camera-tab="views"] .film-controls{display:none}
 .mobile-walk-note{display:block;font-size:14px;line-height:1.5;padding:0 12px}.view-tools .control-note{display:none}
 #mobileWalk{display:none}#workspace.walk-view:not([data-mobile-panel]) #mobileWalk{display:flex;position:absolute;left:18px;right:18px;bottom:calc(var(--mobile-bar) + 20px);align-items:end;justify-content:space-between;z-index:4;pointer-events:none}#mobileWalk>*{pointer-events:auto}#walkPad{width:104px;height:104px;position:relative;border-radius:50%;background:#f9fcf9c9;border:1px solid #ffffff;touch-action:none;user-select:none;display:grid;place-items:center;color:#526760;font-size:60px}#walkThumb{position:absolute;left:32px;top:32px;width:40px;height:40px;background:#172c33b0;border-radius:50%;pointer-events:none}#mobileStopWalk{background:#fafcf9;min-height:48px;box-shadow:0 2px 12px #172c3322;font-size:14px}
 #workspace #referencePanel{inset:0;position:absolute;width:100%;height:100dvh;max-width:none;border-radius:0;z-index:20;display:flex;flex-direction:column;padding:env(safe-area-inset-top,0px) 12px env(safe-area-inset-bottom,0px);overflow:auto;background:#fafcf9}#referencePanel .ref-header{flex-shrink:0;padding:8px 0}#closeRef{min-width:48px;min-height:48px}#referencePanel .ref-selects{flex-shrink:0}#referencePanel select{font-size:16px;min-height:44px}.mobile-image-viewport{flex:1;min-height:180px;overflow:hidden;touch-action:none;display:flex;align-items:center;justify-content:center;background:#e7ece8}.mobile-image-viewport #referenceImage{max-height:100%;height:100%;width:100%;object-fit:contain;transform-origin:center;user-select:none;pointer-events:none}.mobile-image-tools{display:flex;justify-content:center;gap:12px;padding:6px}.mobile-image-tools button{min-height:44px;min-width:48px;border:1px solid var(--line)}#referencePanel p{flex-shrink:0;font-size:12px;margin:8px 0;max-height:18dvh;overflow:auto}
 #workspace.mobile-reference #mobileBar,#workspace.mobile-reference #mobileWalk{display:none!important}
 #workspace.hide-controls #mobileBar,#workspace.hide-controls #mobileWalk,#workspace.hide-controls .mobile-sheet{display:none!important}#restoreControls{bottom:calc(16px + env(safe-area-inset-bottom,0px));min-height:48px}
 dialog{max-width:calc(100vw - 24px);max-height:85dvh;padding:20px}dialog .dialog-close{min-width:44px;min-height:44px}
}
@media(min-width:761px) and (pointer:fine){.mobile-image-viewport{display:contents}.mobile-image-viewport img{transform:none!important}}

/* Recovery stays visible above all panels, including a full-screen mobile reference. */
#loading{position:fixed;z-index:50;overflow:auto;overscroll-behavior:contain}
#loading.load-failed{justify-content:safe center}
#loading.load-failed .loading-logo{width:72px;flex-shrink:0}
#loading.load-failed .loading-credit{font-size:14px;margin:12px 0}
#loading.load-failed #loadingText{color:var(--ink);font-size:16px;line-height:1.5}
#loadingPreview{width:min(280px,70vw);max-height:24dvh;object-fit:contain;border-radius:8px}
#loadingActions{margin-top:14px;max-width:360px}
#loadingActions button{min-height:48px;padding:12px 18px;background:var(--ink);color:white}
#loadingActions p{font-size:13px;line-height:1.5;color:#60736b}
#loading [hidden]{display:none!important}
@media(max-height:500px){#loading.load-failed .loading-credit,#loadingPreview{display:none}}
