/* DUSTHAVEN / COMMAND CENTER – presentation layer. Simulation and storage remain unchanged. */
:root{--cc:#090c12;--cc-panel:#10151e;--cc-border:#303847;--cc-muted:#9aa5b4;--cc-gold:#edbc73;--cc-pink:#ff318e}
body.page-dusthaven{background:#07090e;color:#f1f3f7}
body.page-dusthaven>.site-header,body.page-dusthaven>.site-footer,body.page-dusthaven>.reading-bar{display:none!important}
body.page-dusthaven #conteudo{padding:0!important;min-height:100svh}
.page-dusthaven .dh-hero{padding:0!important}
.page-dusthaven .dh-command-container{max-width:none;width:100%;margin:0 auto;padding:26px clamp(12px,2.3vw,42px) 50px}
.dh-command-pageintro{display:flex;flex-direction:column;gap:8px;max-width:1650px;margin:0 auto 22px}
.dh-command-pageintro>div{display:flex;align-items:center;gap:16px;flex-wrap:wrap}
.dh-command-back{font-size:11px;letter-spacing:.13em;font-weight:850;text-decoration:none!important;color:#c6c8d3!important;transition:color .2s}
.dh-command-back:hover{color:var(--cc-pink)!important}
.dh-command-pagebadge{font-size:10px;letter-spacing:.16em;font-weight:850;color:#d0aa7b;border:1px solid #493729;padding:5px 10px;border-radius:4px;background:#1f1917}
.dh-command-pageintro h1{font-size:clamp(28px,3.3vw,52px);margin:2px 0 0;letter-spacing:-.06em;line-height:1; font-weight:950}
.dh-command-pageintro h1 em{font-style:normal;color:var(--cc-pink)}
.dh-command-pageintro p{color:#adb6c5;margin:0;font-size:14px;max-width:980px;line-height:1.55}
.dh-command-shell{--command-rail:88px;--command-panel:385px;display:flex;flex-direction:column;position:relative;min-height:690px;height:min(860px,calc(100vh - 173px));height:min(860px,calc(100dvh - 173px));max-width:1800px;margin:auto;background:linear-gradient(145deg,#121825,#0a0d13);border:1px solid #3c4552;border-radius:14px;overflow:hidden;box-shadow:0 25px 90px #000b,0 0 0 1px #ffffff05}
.dh-command-shell:fullscreen,.dh-command-shell.dh-shell-expanded{position:fixed!important;inset:0!important;width:100vw!important;height:100vh!important;height:100dvh!important;max-width:none!important;margin:0!important;border-radius:0!important;border:0!important;z-index:100000!important}
.dh-command-shell:focus{outline:none}
.dh-command-topbar{height:64px;flex:0 0 64px;min-height:0;background:linear-gradient(180deg,#1d2532,#121824);border-bottom:1px solid #343e4c;display:flex;align-items:center;gap:15px;padding:0 16px;position:relative;z-index:3}
.dh-command-logo{width:38px;height:38px;background:#f93291;color:#160913;font-size:22px;font-weight:900;display:grid;place-items:center;clip-path:polygon(22% 0,78% 0,100% 22%,100% 78%,78% 100%,22% 100%,0 78%,0 22%);flex:0 0 38px}
.dh-command-identity{display:flex;flex-direction:column;gap:2px;min-width:155px}
.dh-command-identity strong{font-size:17px;letter-spacing:.12em;line-height:1;color:#fff;font-weight:950}
.dh-command-identity small{font-size:9px;color:#8d9aaf;letter-spacing:.10em;font-weight:800;white-space:nowrap}
.dh-command-identity small span{color:#ff318e}
.dh-command-pill{border:1px solid #305a4a;background:#10352733;border-radius:4px;padding:9px 11px;font-size:10px;letter-spacing:.1em;font-weight:850;color:#b0f6d5;white-space:nowrap}
.dh-command-pill i,.dh-live-dot{display:inline-block;width:7px;height:7px;border-radius:50%;background:#63dba6;box-shadow:0 0 8px #63dba6}
.dh-command-clock{display:flex;align-items:center;justify-content:flex-end;flex:1;min-width:0}
.dh-command-clock .dh-stage-hud{gap:6px}
.dh-command-clock .dh-tag{font-size:10px;letter-spacing:.07em;border-radius:5px;padding:8px 9px;white-space:nowrap;background:#070b12;border-color:#394556}
.dh-command-clock .dh-tag i{width:6px;height:6px}
.dh-command-icon{background:#121926;border:1px solid #344253;border-radius:6px;color:#dce6f1;cursor:pointer;font-size:19px;line-height:1;padding:9px 10px;display:flex;align-items:center;gap:9px;flex-shrink:0;min-height:38px}
.dh-command-icon span{font-size:9px;letter-spacing:.09em;font-weight:900}
.dh-command-icon:hover,.dh-command-icon:focus-visible{background:#253145;border-color:#ff318e;outline:none}
.dh-command-ribbon{flex-shrink:0;background:#090e17;border-bottom:1px solid #293344;position:relative;z-index:2}
.dh-command-ribbon .dh-stats{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:0;margin:0!important;padding:0!important}
.dh-command-ribbon .dh-stat{border:0;border-right:1px solid #293344;border-radius:0;background:transparent;box-shadow:none;padding:11px 13px 10px!important;min-width:0}
.dh-command-ribbon .dh-stat:last-child{border-right:0}
.dh-command-ribbon .dh-stat small{font-size:9px;margin:0 0 5px;letter-spacing:.11em;color:#93a2b8;white-space:nowrap}
.dh-command-ribbon .dh-stat strong{font:900 clamp(14px,1.25vw,21px)/1.13 system-ui;color:#fafafa;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.dh-command-ribbon .dh-stat:nth-child(2) strong,.dh-command-ribbon .dh-stat:nth-child(4) strong{color:#f5ce9c}
.dh-command-ribbon .dh-stat span{font-size:10px!important;line-height:1.2;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;color:#9eabbc}
.dh-command-workspace{display:grid;grid-template-columns:var(--command-rail) minmax(0,1fr) var(--command-panel);flex:1;min-height:0;overflow:hidden;position:relative}
.dh-command-shell.is-panel-closed{--command-panel:0px}
.dh-command-rail{display:flex;flex-direction:column;align-items:stretch;gap:0;overflow-y:auto;overflow-x:hidden;background:#101622;border-right:1px solid #34404f;z-index:2;min-height:0;scrollbar-width:thin;scrollbar-color:#48566d transparent}
.dh-command-rail-head{padding:12px 7px;text-align:center;font-weight:900;color:#77859b;font-size:8px;letter-spacing:.14em;border-bottom:1px solid #2f3b4b;display:flex;flex-direction:column;align-items:center;gap:4px}
.dh-command-rail-head i{font-style:normal;font-size:19px;color:#edbc73}
.dh-command-tab{display:flex;align-items:center;flex-direction:column;gap:6px;background:transparent;color:#98a6b8;border:0;border-bottom:1px solid #202a39;border-left:3px solid transparent;padding:12px 5px 11px;font:800 9px/1.15 system-ui;letter-spacing:.01em;cursor:pointer;transition:color .16s,background .16s;flex-shrink:0;min-height:65px;width:100%}
.dh-command-tab-icon{font-size:22px;line-height:1;color:#9ba9be;font-weight:650}
.dh-command-tab-label{text-align:center}
.dh-command-tab:hover,.dh-command-tab:focus-visible{background:#202a3b;color:#fff;outline:0}
.dh-command-tab.is-active{background:linear-gradient(90deg,#50263c,#242332);border-left-color:var(--cc-pink);color:#fff}
.dh-command-tab.is-active .dh-command-tab-icon{color:#ff82b9}
.dh-command-mapbox{display:flex;min-width:0;min-height:0;flex-direction:column;position:relative;background:#161b21}
.dh-command-mapbox .dh-stage{background:transparent!important;padding:0!important;border:0!important;box-shadow:none!important;border-radius:0!important;min-height:0;flex:1;display:flex;flex-direction:column;overflow:hidden;position:relative}
.dh-command-mapbox .dh-stage-canvas{padding:0!important;border:0!important;border-radius:0!important;min-height:0;flex:1;display:flex;position:relative;overflow:hidden}
.dh-command-mapbox #dhCanvas{width:100%!important;height:100%!important;max-height:none!important;display:block!important;object-fit:fill;touch-action:none;cursor:grab;background:#a77244}
.dh-command-mapbox .dh-map-actions{z-index:3}
.dh-command-mapfooter{position:absolute;left:16px;bottom:12px;right:16px;display:flex;align-items:end;justify-content:space-between;gap:10px;pointer-events:none;z-index:2}
.dh-command-mapfooter .dh-rebuild-status{margin:0!important;max-width:min(370px,60%);padding:9px 12px;background:#0a1018d9!important;border:1px solid #485364;border-radius:7px;box-shadow:0 12px 27px #0006;backdrop-filter:blur(6px);pointer-events:none}
.dh-command-mapfooter .dh-rebuild-status small{font-size:8px}
.dh-command-mapfooter .dh-rebuild-status strong{font-size:12px}
.dh-command-mapfooter .dh-rebuild-status p{font-size:10px;line-height:1.2;margin:2px 0 0}
.dh-command-mapfooter .dh-map-status{background:#0a1018c9;padding:8px 12px;margin:0!important;max-width:45%;border:1px solid #364251;border-radius:7px;font-size:10px;color:#d1d7df}
.dh-command-turnstrip{display:flex;align-items:center;gap:10px;min-height:67px;flex:0 0 auto;padding:10px 13px;background:linear-gradient(180deg,#171f2d,#0f1622);border-top:1px solid #354252;position:relative;z-index:3}
.dh-command-turnstrip .dh-actions{margin:0!important;padding:0!important;display:flex!important;flex-wrap:wrap;align-items:center;gap:7px}
.dh-command-turnstrip .dh-btn{padding:10px 13px;font-size:10px;border-radius:5px;letter-spacing:.055em;box-shadow:none;min-height:39px}
.dh-command-turnstrip .dh-btn.primary{background:#f82a89;color:#1a0812}
.dh-command-turnstrip .dh-btn.gold{background:#e9b26d;color:#16110a}
.dh-command-turnstrip .dh-btn.subtle{border-color:#405169;background:#1c2a3b}
.dh-command-hint{display:flex;align-items:center;gap:7px;margin-left:auto;font-size:9px;letter-spacing:.09em;color:#8293a8;white-space:nowrap}
.dh-command-hint strong{color:#a5f0ca;font-weight:900}
.dh-command-drawer{min-height:0;min-width:0;display:flex;flex-direction:column;background:#101722;border-left:1px solid #344355;overflow:hidden;z-index:5}
.dh-command-shell.is-panel-closed .dh-command-drawer{display:none}
.dh-command-drawer-head{height:75px;flex:0 0 75px;background:#1b2432;border-bottom:1px solid #364658;display:flex;align-items:center;justify-content:space-between;padding:11px 17px;gap:10px}
.dh-command-drawer-head span{display:block;font-size:9px;color:#ebb975;font-weight:850;letter-spacing:.15em}
.dh-command-drawer-head h2{font-size:20px;margin:4px 0 0;letter-spacing:-.035em;line-height:1}
.dh-command-drawer-head button{cursor:pointer;border:1px solid #47546a;background:#131b28;color:#d1d9e4;border-radius:6px;font-size:16px;width:33px;height:33px}
.dh-command-drawer-head button:hover{background:#3f2841}
.dh-command-drawer-scroll{flex:1;overflow:auto;overscroll-behavior:contain;padding:13px 13px 25px;scrollbar-color:#48566d transparent;scrollbar-width:thin;min-height:0}
.dh-command-pane[hidden]{display:none!important}
.dh-command-pane{display:flex;flex-direction:column;gap:12px;min-height:min-content}
.dh-command-pane-intro{margin:0 2px 3px!important;font-size:12px!important;line-height:1.5;color:#abb5c5!important}
.dh-command-pane .dh-panel,.dh-command-pane .dh-chart-wrap,.dh-command-pane .dh-population-panel,.dh-command-pane .dh-slots{margin:0!important;box-shadow:none!important;border:1px solid #334053!important;background:linear-gradient(150deg,#171e2a,#131b26)!important;border-radius:9px!important;padding:15px!important;min-width:0;width:100%}
.dh-command-pane .dh-panel h3,.dh-command-pane .dh-chart-wrap h3{font-size:15px!important;margin:0 0 10px!important;color:#f3f4f7}
.dh-command-pane .dh-panel p,.dh-command-pane .dh-chart-wrap p{font-size:12px!important;line-height:1.55;color:#aeb8c7}
.dh-command-pane .dh-policy-row label,.dh-command-pane .dh-civic-row h4{font-size:12px!important}
.dh-command-pane .dh-policy-row label small{font-size:10px!important;line-height:1.35}
.dh-command-pane input[type=range]{accent-color:#ff318e}
.dh-command-pane select,.dh-command-pane input,.dh-command-pane button{max-width:100%}
.dh-command-pane .dh-choice-grid{grid-template-columns:1fr 1fr}
.dh-command-pane .dh-choice-grid button{font-size:11px;padding:10px}
.dh-command-pane .dh-graph-picker{display:grid;grid-template-columns:1fr 1fr;gap:4px}
.dh-command-pane .dh-graph-picker button{padding:7px 5px;font-size:10px}
.dh-command-pane #dhChart{width:100%;height:auto;border-radius:5px}
.dh-command-pane .dh-chart-head{align-items:start}
.dh-command-pane .dh-slots{display:flex!important;flex-direction:column;align-items:stretch;gap:10px}
.dh-command-pane .dh-slot-buttons{display:flex;width:100%}
.dh-command-pane .dh-slot-buttons button{flex:1}
.dh-command-pane .dh-population-head{display:block;margin-bottom:15px}
.dh-command-pane .dh-population-head h2{font-size:17px;margin:5px 0}
.dh-command-pane .dh-social-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px}
.dh-command-pane .dh-social-stat{min-width:0;padding:11px;border:1px solid #334053;border-radius:7px;background:#0f1620}
.dh-command-pane .dh-social-stat small{font-size:9px}
.dh-command-pane .dh-social-stat strong{font-size:15px}
.dh-command-pane .dh-social-stat span{font-size:10px}
.dh-command-pane .dh-civic-grid{grid-template-columns:1fr}
.dh-command-pane .dh-justice-law,.dh-command-pane .dh-policy-row{min-width:0}
.dh-command-flags{display:flex;gap:5px;flex-wrap:wrap;font-size:9px;letter-spacing:.05em;font-weight:800;color:#aeb9cb}
.dh-command-flags>span{display:flex;align-items:center;gap:5px;border:1px solid #313f52;border-radius:3px;padding:5px}
.dh-command-flags i{width:6px;height:6px;border-radius:50%;background:#a4e6bd}.dh-command-flags .dh-flag-pink{background:#ff318e}.dh-command-flags .dh-flag-gold{background:#edbc73}
.dh-command-shade{display:none}
.dh-command-mapbox #dhIntroOverlay.dh-cinema-overlay{z-index:100!important}
.dh-command-shell .dh-profile-modal{z-index:110!important}
/* constrained full-screen dialogs even when the fullscreen element isn't <body> */
.dh-command-shell:fullscreen .dh-event-overlay{position:absolute!important}
.dh-command-shell:fullscreen #dhIntroOverlay.dh-cinema-overlay{position:fixed!important}
.dh-command-shell:fullscreen .dh-profile-modal{position:absolute!important}
.dh-command-shell:fullscreen .dh-ending-overlay{position:absolute!important}
@media(min-width:1500px){.dh-command-shell{--command-panel:425px;--command-rail:96px;height:min(935px,calc(100dvh - 171px))}.dh-command-ribbon .dh-stat{padding:13px 17px!important}.dh-command-drawer-scroll{padding:15px}}
@media(max-width:1250px){.dh-command-shell{--command-panel:350px;--command-rail:76px}.dh-command-ribbon .dh-stat small{font-size:8px}.dh-command-ribbon .dh-stat strong{font-size:16px}.dh-command-logo{display:none}.dh-command-pill{display:none}.dh-command-tab{min-height:61px}.dh-command-turnstrip .dh-btn{padding:9px 10px}.dh-command-hint span:last-child{display:none}}
@media(max-width:920px){.dh-command-container{padding:16px 10px 28px!important}.dh-command-shell{height:calc(100dvh - 134px);min-height:540px;--command-rail:0px;--command-panel:0px}.dh-command-topbar{height:57px;flex-basis:57px;padding:0 10px}.dh-command-rail{position:absolute;z-index:7;left:0;right:0;bottom:0;top:auto;height:63px;display:flex;flex-direction:row;align-items:stretch;border-right:none;border-top:1px solid #415164;overflow:auto hidden}.dh-command-rail-head{display:none}.dh-command-tab{min-height:0;min-width:74px;width:74px;padding:8px 6px;border-bottom:0;border-left:0;border-top:3px solid transparent;font-size:9px}.dh-command-tab.is-active{border-left:0;border-top-color:#ff318e}.dh-command-tab-icon{font-size:18px}.dh-command-workspace{grid-template-columns:1fr; padding-bottom:63px}.dh-command-mapbox{grid-column:1;grid-row:1}.dh-command-drawer{position:absolute;right:0;top:0;bottom:63px;width:min(440px,94vw);z-index:10;box-shadow:-25px 0 50px #000b;border-left:1px solid #556273}.dh-command-shade{display:block!important;position:absolute;inset:0 0 63px 0;background:#0008;border:none;z-index:8;cursor:pointer}.dh-command-shell.is-panel-closed .dh-command-shade{display:none!important}.dh-command-shell.is-panel-closed .dh-command-drawer{display:none!important}.dh-command-clock .dh-tag:last-child{display:none}.dh-command-hint{display:none}}
@media(max-width:650px){.dh-command-pageintro{margin-bottom:12px}.dh-command-pageintro h1{font-size:clamp(24px,6vw,34px)}.dh-command-pageintro p{font-size:12px}.dh-command-pagebadge{font-size:8px}.dh-command-shell{height:calc(100dvh - 138px);min-height:450px}.dh-command-identity strong{font-size:13px}.dh-command-identity small{font-size:7px}.dh-command-clock .dh-tag{font-size:8px;padding:6px 7px}.dh-command-icon{padding:8px;font-size:18px}.dh-command-icon span{display:none}.dh-command-ribbon{overflow:auto;scrollbar-width:none}.dh-command-ribbon .dh-stats{display:flex!important;min-width:680px}.dh-command-ribbon .dh-stat{flex:0 0 114px;padding:9px 11px!important}.dh-command-ribbon .dh-stat strong{font-size:15px}.dh-command-ribbon .dh-stat span{font-size:9px!important}.dh-command-turnstrip{padding:7px 8px;min-height:53px}.dh-command-turnstrip .dh-actions{gap:5px;flex-wrap:nowrap;max-width:100%;overflow-x:auto;scrollbar-width:thin}.dh-command-turnstrip .dh-btn{font-size:9px;padding:8px 10px;white-space:nowrap;min-height:35px}.dh-command-mapfooter{left:6px;right:6px;bottom:6px}.dh-command-mapfooter .dh-rebuild-status{padding:5px 7px;max-width:75%}.dh-command-mapfooter .dh-rebuild-status strong{font-size:10px}.dh-command-mapfooter .dh-rebuild-status p{display:none}.dh-command-mapfooter .dh-map-status{display:none}.dh-command-pageintro>div{gap:8px}.dh-command-pane .dh-civic-grid{grid-template-columns:1fr}}
/* support focus and reduced motion */
.dh-command-tab:focus-visible,.dh-command-turnstrip button:focus-visible,.dh-command-drawer button:focus-visible{outline:2px solid #ffb4d8;outline-offset:-2px}
@media(prefers-reduced-motion:reduce){.dh-command-tab,.dh-command-icon{transition:none}}
/* Integrated soundtrack: prevent the previous fixed player from covering commands or mobile tabs. */
.dh-command-turnstrip #audioPlayer.audio-player{position:relative!important;left:auto!important;right:auto!important;bottom:auto!important;top:auto!important;z-index:2;max-width:none!important;width:auto!important;min-width:114px;padding:5px 8px!important;gap:7px!important;box-shadow:none!important;border-color:#435065!important;background:#0b1220!important;clip-path:none!important;border-radius:6px!important;margin-left:auto;flex-shrink:0}
.dh-command-turnstrip #audioPlayer.audio-player::after{display:none}
.dh-command-turnstrip #audioPlayer .audio-badge{width:22px;height:30px;font-size:10px;border-radius:4px}
.dh-command-turnstrip #audioPlayer .audio-meta{display:none}
.dh-command-turnstrip #audioPlayer .audio-controls{gap:4px}
.dh-command-turnstrip #audioPlayer .audio-btn{min-width:31px;width:31px;height:31px;font-size:15px;padding:0;border-radius:5px}
.dh-command-turnstrip #audioPlayer .audio-progress{height:2px}
.dh-command-turnstrip #audioPlayer .audio-boot{left:auto;right:0;bottom:calc(100% + 10px);width:220px;clip-path:none!important}
.dh-command-turnstrip .dh-command-hint{margin-left:auto}
@media(max-width:1250px){.dh-command-turnstrip .dh-command-hint{display:none}.dh-command-turnstrip #audioPlayer.audio-player{margin-left:auto}}
@media(max-width:650px){.dh-command-turnstrip .dh-actions{flex:1;min-width:0}.dh-command-turnstrip #audioPlayer.audio-player{min-width:75px;padding:5px!important;gap:3px!important}.dh-command-turnstrip #audioPlayer .audio-badge{display:none}.dh-command-turnstrip #audioPlayer .audio-btn{width:30px;min-width:30px;height:30px}}
/* Compact save controls; keep slot selection above import/export on narrow screens. */
.dh-command-pane .dh-slot-buttons{order:0!important}
.dh-command-pane .dh-slots>button{order:1!important}
.dh-command-pane .dh-slots>input{order:2!important}
@media(max-width:650px){.dh-command-identity{min-width:0;flex:1}.dh-command-identity small{font-size:7px;max-width:115px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dh-command-clock{flex:0 0 auto}.dh-command-topbar{gap:7px}}
