/* GuideDistrict atlas: task-led controls, restrained overlays, readable second screen. */
.map-page{--atlas-accent:var(--teal)}
.map-page .map-app{grid-template-columns:366px minmax(0,1fr)}
.map-page .sidebar-top{padding:18px 20px 12px}
.map-page .sidebar-top h1{font-size:28px;letter-spacing:-.015em;margin:10px 0 4px}
.atlas-intro{font-size:12px;color:var(--muted);margin:0 0 16px}
.map-page .map-search{min-height:46px;border-color:var(--line);background:var(--bg)}
.map-page .map-summary{font-size:11px;margin-top:10px}
.map-page .overview-controls{padding:9px 20px;display:flex;justify-content:space-between;gap:8px;border-top:1px solid var(--line);background:var(--bg)}
.map-page .overview-controls>p{display:none}
.map-page .main-mode-badge{font-size:10px;letter-spacing:.04em;color:var(--text)}
.map-page .overview-mode{font-size:10px;margin:0;color:var(--muted)}
.map-page .map-tabs{grid-template-columns:repeat(4,1fr);padding:0 12px;gap:0}
.map-page .map-tabs button{min-height:48px;font-size:12px;font-weight:650}
.map-page .map-tabs button[aria-pressed=true]{border-bottom-color:var(--rose);color:var(--text);background:transparent}
.map-page .filter-scroll{padding:0 14px 22px}
.intent-switch{display:flex;gap:5px;margin:17px 0 18px;flex-wrap:wrap}
.intent-switch button{border:1px solid var(--line);border-radius:7px;background:transparent;font-size:10px;padding:8px 10px;min-height:40px;color:var(--muted)}
.intent-switch button[aria-pressed=true]{background:var(--raised);color:var(--text);border-color:var(--rose)}
.atlas-section-title{display:flex;align-items:center;justify-content:space-between;gap:8px;margin:0 3px 10px}
.atlas-section-title strong{font-size:12px;font-weight:600}.atlas-section-title .clear-filters{font-size:10px;min-height:30px;padding:0}
.map-page .region-picker{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;padding:0;margin:0 0 12px}
.map-page .region-choice{min-width:0;position:relative;border:1px solid var(--line);padding:0;border-radius:7px;background:var(--raised);overflow:hidden;min-height:79px;display:block}
.map-page .region-choice img{display:block;width:100%;height:78px;object-fit:cover;opacity:.82}
.map-page .region-choice::after{content:'';position:absolute;inset:0;background:linear-gradient(0deg,#10101de8,transparent 90%);pointer-events:none}
.map-page .region-choice span{position:absolute;bottom:7px;left:7px;right:5px;color:#fff4ea;z-index:1;font-size:11px;line-height:1.1;text-shadow:0 1px 8px #000;font-weight:650}
.map-page .region-choice:hover img{opacity:1}.map-page .region-choice[aria-pressed=true]{border-color:var(--rose)}
.map-page .map-region-info{padding:10px 12px;margin:0 0 8px;border:1px solid var(--line);border-radius:8px}
.map-page .map-region-info p{font-size:10px;margin-bottom:7px}
.map-page .explore-options{padding:4px 3px;gap:4px}.map-page .explore-options label{font-size:11px}.map-page #next-unchecked{font-size:10px;padding:6px}
.map-page .list-heading{font-size:11px;padding:6px 3px;min-height:37px}.atlas-sort{display:flex;justify-content:flex-end;margin:0 0 7px}
.map-page .atlas-sort select{margin:0;border:0;max-width:100%;width:auto;min-height:35px;padding:4px 8px;font-size:10px;background:transparent}
.map-page .place-row{min-height:69px;padding:12px 8px;border-radius:0}.map-page .place-row strong{font-size:13px;font-weight:600}.map-page .place-row small{font-size:10px;line-height:1.5}
.map-page .place-row.selected{border-left:2px solid var(--rose)}.map-page .pin-dot{width:28px;height:28px;border-radius:8px;font-size:14px}
.atlas-add-results{width:100%;border:1px dashed var(--line);background:transparent;border-radius:7px;min-height:42px;font-size:11px;color:var(--teal);margin:16px 0 3px}
.atlas-filter-group{border:1px solid var(--line);border-radius:10px;padding:14px 12px;margin:5px 4px 16px}
.atlas-filter-group label{display:block;font-size:12px;margin-top:13px}.atlas-filter-group>label:first-child{margin-top:0}
.atlas-filter-group small{font-size:10px;line-height:1.7;display:block;margin:8px 0 0}
.map-page .atlas-filter-group select{margin-top:6px;font-size:12px;min-height:44px;padding:10px 7px}
.atlas-upcoming{margin:14px 5px;padding:12px;border-top:1px solid var(--line);color:var(--muted);font-size:11px}.atlas-upcoming summary{cursor:pointer;min-height:32px}.atlas-upcoming p{margin:8px 0 0;line-height:1.7}
.map-page .panel-heading{padding:18px 5px 8px}.map-page .panel-heading h2{font-size:25px;margin:0 0 9px}.map-page .panel-heading p{font-size:12px}
.atlas-progress{margin-bottom:25px}.atlas-progress>h3{font-size:17px}.atlas-progress>p{font-size:11px;color:var(--muted);line-height:1.7}
.atlas-progress-row{display:flex;gap:9px;border-bottom:1px solid var(--line);padding:9px 0}
.atlas-progress-row>button:first-child{border:0;background:none;flex:1;text-align:left;display:grid;grid-template-columns:1fr auto;gap:8px;padding:5px 0;font-size:11px;color:var(--text)}
.atlas-progress-row strong{font-size:10px;font-variant-numeric:tabular-nums;color:var(--muted)}
.atlas-progress-row progress{grid-column:1/-1;width:100%;height:4px;border:0;border-radius:4px;appearance:none;background:var(--raised);color:var(--rose)}
.atlas-progress-row progress::-webkit-progress-bar{background:var(--raised);border-radius:4px}.atlas-progress-row progress::-webkit-progress-value{background:var(--rose);border-radius:4px}.atlas-progress-row progress::-moz-progress-bar{background:var(--rose)}
.atlas-next{border:1px solid var(--line);background:none;border-radius:7px;min-width:40px;font-size:18px;color:var(--teal)}
.atlas-waiting{padding:16px;border:1px solid var(--line);border-radius:10px;margin-top:18px;background:var(--bg)}.atlas-waiting strong{font-size:13px}.atlas-waiting p{font-size:11px;color:var(--muted);line-height:1.7;margin:7px 0 0}
.atlas-collection{display:grid;text-align:left;gap:7px;padding:12px;border:1px solid var(--line);border-radius:8px;background:var(--bg);width:100%;font-size:12px;margin:10px 0}.atlas-collection small{font-size:10px}
.atlas-route-actions{margin:15px 6px}.atlas-route-actions p{font-size:10px;line-height:1.7;color:var(--muted);margin:9px 0}.atlas-route-actions .button{font-size:11px}.map-page #route-held{padding:9px;border:1px solid var(--line);border-radius:8px}
.map-page .compact-footer{padding:9px 20px 12px}.map-page .compact-footer span{font-size:10px;margin-top:4px}
.atlas-context{position:absolute;top:20px;left:20px;z-index:420;display:flex;gap:10px;align-items:center;background:#181627f5;border:1px solid #fff3;border-radius:10px;padding:12px 15px;box-shadow:0 3px 20px #0002;color:#fff4ea;font-size:13px}
.atlas-context-dot{width:6px;height:6px;border-radius:50%;background:#ff9dc6}.atlas-context-count,#atlas-context-count{font-size:10px;color:#c9c2d5;padding-left:10px;border-left:1px solid #fff3}
.map-page .map-notice{top:auto;bottom:26px;left:auto;right:14px;padding:8px 11px;max-width:290px;font-size:9px;border-radius:8px;background:#181627ed}.map-page .map-notice strong{font-size:10px}
.map-page .map-notice span{font-size:9px}.map-page .map-simple-button{left:20px;right:auto;top:78px;font-size:10px;background:#181627f0;border-color:#fff3;border-radius:7px;color:#fff4ea;min-height:37px}
.map-page .map-controls{top:20px;right:16px;gap:7px}.map-page .map-controls button{background:#181627f5;border-color:#fff4;color:#fff4ea;border-radius:8px;width:42px;min-height:42px;box-shadow:0 2px 12px #0002}
.map-page .map-bottom{bottom:27px;left:18px}.map-page .map-bottom .button{background:#181627f5;border-color:#fff4;color:#fff4ea;border-radius:8px}
.atlas-legend{position:absolute;right:69px;top:20px;z-index:470;width:260px;padding:18px;background:#211d33f8;color:#fff4ea;border:1px solid #ffffff40;border-radius:12px;box-shadow:0 10px 40px #0004}
.atlas-legend>strong{font-size:17px}.atlas-legend p{display:flex;align-items:center;gap:12px;font-size:11px;margin:15px 0}.atlas-legend b{font-size:11px;min-width:45px;text-align:center;color:#ffafd1}.atlas-legend small{font-size:10px;line-height:1.7;display:block;color:#c9c2d5}
.map-page .details-panel{padding:25px;width:364px;border-radius:12px;right:16px;top:16px;bottom:24px;box-shadow:0 16px 70px #0005}.map-page .details-panel h2{font-size:30px}.map-page .detail-status{line-height:1.5;padding:8px 10px;font-size:10px;border:1px solid var(--line);background:var(--bg)}
.atlas-detail-media{margin:14px -25px 6px}.atlas-detail-media figure{margin:0 0 12px}.atlas-detail-media img{width:100%;display:block;object-fit:cover;max-height:230px}.atlas-detail-media figcaption{font-size:9px;color:var(--muted);padding:6px 25px}
.atlas-detail-content section{margin:17px 0}.atlas-detail-content h3{font-size:18px;margin-bottom:9px}.atlas-detail-content p,.atlas-detail-content li{font-size:12px;line-height:1.8;color:var(--muted)}.atlas-detail-content ul,.atlas-detail-content ol{padding-left:20px}.atlas-guide{width:100%;font-size:12px!important;margin:7px 0}
.atlas-nearby{margin:25px 0 8px;border-top:1px solid var(--line);padding-top:18px}.atlas-nearby h3{font-size:21px;margin-bottom:8px}.atlas-nearby>small{font-size:10px;line-height:1.7;display:block;margin-bottom:12px}
#nearby-list button{display:flex;align-items:center;gap:10px;text-align:left;width:100%;border:0;border-bottom:1px solid var(--line);background:none;padding:12px 0;min-height:65px}#nearby-list strong{font-size:12px;display:block;line-height:1.5}#nearby-list small{font-size:10px;display:block}#nearby-list button>span:nth-child(2){flex:1}#nearby-list button>span:last-child{color:var(--muted)}
#detail-evidence a{display:block;margin:9px 0}#detail-evidence p{font-size:11px}#map-report-form textarea{min-height:110px;max-height:250px;width:100%;background:var(--bg);color:var(--text);border:1px solid var(--line);border-radius:8px;padding:10px;font-size:16px;resize:vertical}
.map-page .major-map-label{background:#181627eb;border-color:#eee3;color:#fff4ea;border-radius:6px;font-size:11px;box-shadow:0 2px 7px #0003}.map-page .major-map-label.region-label{font-family:Barlow,system-ui,sans-serif;letter-spacing:.05em;font-size:18px;background:#171324ee;border-color:#ffb2d377;color:#fff0e4;padding:5px 10px}.map-page .overview-map-dot{background:#fff1e2;border:2px solid #171324}.map-page .place-marker{background:#211d33}.map-page .cluster-marker{background:#211d33;border-color:#ffb2d3;color:#fff4ea}.map-page .route-marker{background:#211d33}
@media(min-width:761px) and (max-width:1100px){.map-page .map-app{grid-template-columns:320px minmax(0,1fr)}.map-page .sidebar-top{padding:17px 16px 11px}.map-page .details-panel{width:310px}.atlas-context{max-width:calc(100% - 90px);padding:10px}.atlas-context #atlas-context-count{display:none}.map-page .map-notice{max-width:210px}.intent-switch button{font-size:10px;padding:7px 8px}}
@media(max-width:760px){
 .map-page .map-app{display:block;height:calc(100dvh - 64px)}.map-page .map-sidebar{width:min(390px,calc(100vw - 18px));z-index:700}.map-page .sidebar-top{padding:18px 18px 10px}.map-page .sidebar-top h1{font-size:26px}.atlas-intro{margin-bottom:11px;font-size:11px}.map-page .map-search{font-size:16px}.map-page .map-tabs button{font-size:11px;min-height:46px}.map-page .filter-scroll{padding:0 13px 20px}.map-page .overview-controls{padding:8px 18px}.map-page .region-picker{gap:6px}.map-page .region-choice img{height:74px}.map-page .region-choice span{font-size:10px}
 .atlas-context{display:none}.map-page .map-mobile-search{left:12px;right:65px;top:12px;width:auto;border-radius:9px;background:#181627f5;border-color:#fff4;color:#fff4ea;min-height:45px;font-size:12px;padding:12px}.map-page .map-simple-button{left:12px;top:67px;font-size:10px;min-height:36px}.map-page .map-controls{top:12px;right:10px;gap:6px}.map-page .map-controls button{width:42px;height:42px}.map-page .map-controls #mute-map{display:none}
 .map-page .map-notice{left:12px;right:auto;bottom:84px;max-width:230px;padding:7px 10px;font-size:9px}.map-page .map-notice strong{font-size:10px}.map-page .map-notice>span{display:none}.map-page .map-bottom{bottom:max(27px,env(safe-area-inset-bottom));left:10px;right:10px;gap:5px}.map-page .map-bottom .button{padding:10px;min-height:47px;font-size:11px}.map-page .map-bottom #mobile-filters{flex:1}.map-page .map-bottom #view-route{font-size:10px}.atlas-legend{top:60px;right:62px;width:min(260px,calc(100% - 80px));max-height:65dvh;overflow:auto}
 .map-page .details-panel{width:auto;left:8px;right:8px;top:auto;bottom:24px;max-height:58dvh;padding:24px;border-radius:16px}.map-page .details-panel::before{content:'';position:absolute;top:8px;left:calc(50% - 18px);height:3px;width:36px;background:var(--line);border-radius:3px}.map-page .details-panel h2{font-size:27px}.map-page.has-place .map-simple-button,.map-page.has-place .map-notice{display:none}.map-page.has-place .map-controls #share-view,.map-page.has-place .map-controls #map-legend-toggle{display:none}.atlas-detail-media{margin-left:-24px;margin-right:-24px}.map-page .compact-footer{padding:7px 18px 10px}.map-page .compact-footer span{font-size:9px}.map-page .map-attribution{max-width:100%;font-size:8px}.atlas-filter-group select{font-size:13px!important}.map-page dialog{max-height:85dvh;overflow:auto}
}
@media(prefers-reduced-motion:reduce){.map-page *{scroll-behavior:auto!important;transition:none!important}}

@media(min-width:761px){.map-page .map-bottom .mobile-only{display:none}}
@media(max-width:760px){.map-page .map-sidebar{height:94%;width:100%;top:auto;bottom:0;border-radius:18px 18px 0 0}.map-page .map-sidebar .atlas-intro{display:none}.map-page .map-sidebar .sidebar-top{padding:14px 18px 10px}.map-page .map-sidebar .sidebar-top h1{font-size:24px;margin:4px 30px 14px 0}.map-page .map-sidebar .map-summary{font-size:10px;margin-top:8px}.map-page .map-sidebar .panel-heading h2{font-size:23px}.map-page .map-sidebar .overview-controls{padding:7px 18px}.map-page .map-sidebar .compact-footer{padding:5px 18px 9px}.map-page .map-sidebar .sidebar-close{top:9px;right:7px}}

@media(max-width:760px){.map-page .map-sidebar{transition:none}.map-page .drawer-shade{touch-action:none}}
/* Keep focus/virtual-keyboard scrolling inside the drawer, never on the document. */
html:has(body.map-page){height:100%;overflow:hidden}
body.map-page{position:fixed;inset:0;width:100%;height:100dvh;overflow:hidden;overscroll-behavior:none}
