:root{color-scheme:light;--bg:#f6f8fb;--paper:#fff;--stroke:#e3e8ef;--subtle:#f5f8fb;--ink:#1b2940;--muted:#748299;--green:#15a75a;--amber:#e6a528;--red:#e3655e;--blue:#2b75cf;--shadow:0 6px 30px #102a4512}*{box-sizing:border-box}html,body{margin:0;background:var(--bg);color:var(--ink);font-family:'Be Vietnam Pro',-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;font-size:13px}button,input,select{font:inherit}button{cursor:pointer}button:disabled{opacity:.5;cursor:not-allowed}[hidden]{display:none!important}.app{min-height:850px;height:100dvh;display:flex;flex-direction:column}.topbar{min-height:65px;background:#fff;border-bottom:1px solid var(--stroke);display:flex;justify-content:space-between;align-items:center;padding:0 24px;gap:15px;z-index:500}.brand{display:flex;align-items:center;gap:9px}.brand-icon{font-size:31px;font-weight:700;color:var(--green);display:grid;place-items:center;background:#edfff5;border-radius:12px;width:40px;height:40px}.brand-copy{display:flex;flex-direction:column;gap:4px}.brand-copy strong{font-size:19px;letter-spacing:-.65px;font-weight:800;white-space:nowrap}.brand-copy strong span{color:var(--green)}.brand-copy small{font-size:8px;color:#8295a7;letter-spacing:1.4px;font-weight:800}.topbar-middle{font-size:10px;font-weight:700;color:#65788b;letter-spacing:.2px}.topbar-slash{margin:0 11px;color:#c4cdd7}.live-dot,.map-pill-dot{display:inline-block;width:8px;height:8px;background:#22c27c;border-radius:50%;margin-right:6px}.version{border:1px solid #dce6ed;padding:7px 9px;border-radius:8px;font-size:9px;color:#728397;font-weight:800}.workspace{flex:1;display:flex;min-height:0}.sidebar{position:relative;z-index:350;background:#fff;border-right:1px solid var(--stroke);flex:0 0 318px;padding:22px 20px;overflow-y:auto;scrollbar-color:#d0d7df transparent;scrollbar-width:thin}.sidebar-title{margin-bottom:20px}.eyebrow{font-size:10px;letter-spacing:1.05px;color:#119c61;font-weight:800;margin-bottom:8px}.sidebar-title h1{font-size:22px;line-height:1.4;letter-spacing:-.6px;margin:0 0 6px;font-weight:800}.sidebar-title h1 span{color:#118b53}.sidebar-title p{margin:0;color:#7a8999;font-size:11px;line-height:1.8}.form-section{margin-bottom:17px;position:relative}label{font-weight:750;color:#36465b;font-size:11px;display:block;margin-bottom:8px}.required{color:#d75e66}input[type=text],select{width:100%;height:40px;border:1px solid #dce4ea;border-radius:9px;outline:none;color:#314155;background:#fff;padding:0 11px;font-size:11px}input[type=text]:focus,select:focus{border-color:#23b478;box-shadow:0 0 0 3px #1fb77e16}input::placeholder{color:#aab5c0}.field-caption{font-size:10px;color:#8491a2;line-height:1.6;margin-top:5px;display:block}.extra-option{margin-top:8px}.extra-option summary{font-size:10px;color:#168c5b;cursor:pointer;font-weight:650}.extra-option input{margin-top:10px}.extra-option p{font-size:10px;line-height:1.7;color:#697f91;margin-top:7px}.section-divider{height:1px;background:#edf0f4;margin:13px 0 17px}.location-search{display:flex;gap:7px}.location-search input{flex:1;min-width:0}.icon-btn{width:41px;border:1px solid #cff0e1;background:#eafbf3;border-radius:9px;color:#169b63;font-size:26px;line-height:1}.quick-locations{display:flex;flex-wrap:wrap;gap:5px;margin-top:10px}.quick-locations button{font-size:9px;color:#6e8194;background:#f4f7fa;border:1px solid #e4ebf0;border-radius:20px;padding:7px 9px;font-weight:700}.quick-locations button:hover,.quick-locations button.active{background:#e5f8ee;border-color:#a8e5c3;color:#128950}.location-results{position:absolute;top:73px;left:0;right:0;background:#fff;border:1px solid #d7e2ec;box-shadow:var(--shadow);z-index:900;border-radius:9px;max-height:220px;overflow:auto}.location-results button{display:block;text-align:left;width:100%;background:#fff;border:0;border-bottom:1px solid #f0f3f6;padding:11px}.location-results button:hover{background:#f2fbf6}.location-results strong{display:block;font-size:11px}.location-results small{display:block;color:#7990a1;margin-top:5px}.location-error{font-size:11px;color:#7e8998;padding:12px}.center-coordinate{margin-top:14px;background:#f4faf7;border:1px solid #e0f1e8;border-radius:11px;display:flex;align-items:center;gap:9px;padding:11px}.center-icon{font-size:25px;color:#189c65}.center-coordinate div{display:flex;flex-direction:column;gap:3px;flex:1}.center-coordinate div small{color:#7b9487;font-size:9px;font-weight:800;letter-spacing:.8px}.center-coordinate div strong{font-size:11px;color:#2a5042}.center-coordinate div span{font-size:9px;color:#839b90}.center-coordinate button{border:0;background:#dff1e7;border-radius:8px;color:#207452;font-size:18px;height:30px;width:30px}.label-row{display:flex;align-items:center;justify-content:space-between}.label-row small{font-size:9px;color:#199960;font-weight:800}.two-inputs{display:flex;gap:8px;margin-bottom:14px}.two-inputs select{flex:1;min-width:0}.grid-controls input[type=range]{width:100%;accent-color:#16aa68}.grid-controls label b{float:right;color:#0d9c61}.range-ends{display:flex;justify-content:space-between;color:#9aa6b2;font-size:9px}.grid-help{font-size:10px;color:#8291a1;line-height:1.5;margin:10px 0 0}.mode-toggle{display:flex;gap:7px}.mode-toggle button{background:#f5f8fa;border:1px solid #e2e7ef;padding:10px 6px;border-radius:9px;flex:1;font-size:10px;color:#6c7b8d;font-weight:800}.mode-toggle button.selected{background:#e8f7ef;border-color:#8bdeb1;color:#128951}.mode-disclaimer{font-size:10px;color:#8493a1;line-height:1.7;margin:9px 0 0}.mode-disclaimer strong{color:#667b8f}.scan-btn{width:100%;background:#16a165;color:white;font-size:12px;font-weight:800;border:0;padding:13px 13px;border-radius:11px;display:flex;align-items:center;justify-content:space-between;gap:12px;box-shadow:0 6px 16px #18986032}.scan-btn:hover{background:#138a59}.scan-caption{color:#8a98a6;margin-top:9px;font-size:10px;text-align:center;line-height:1.5}.progress-track{height:7px;border-radius:20px;background:#e1ecf1;overflow:hidden;margin:11px 0}.progress-fill{width:0;height:100%;background:#1fc27a;transition:width .25s}.sidebar-footer{font-size:9px;color:#9aa8b5;line-height:1.6;margin-top:23px;padding:18px 0;border-top:1px solid #edf0f3}.map-area{position:relative;flex:1;min-width:0;overflow:hidden;background:#e5eceb}.map-area #map{height:100%;width:100%;z-index:0}.leaflet-container{font:inherit!important;background:#e9f0eb}.leaflet-control-attribution{font-size:9px!important}.map-top-left{position:absolute;top:20px;left:23px;z-index:200;pointer-events:none}.map-pill{background:#fffffff0;border:1px solid #e0e8ee;box-shadow:var(--shadow);border-radius:10px;padding:10px 13px;display:inline-block;color:#35526a;font-size:11px}.map-pill b{font-size:10px}.map-top-caption{font-size:9px;font-weight:800;letter-spacing:.8px;color:#586e7b;padding:9px 8px;text-shadow:0 1px #fff}.map-top-right{position:absolute;right:386px;top:23px;z-index:200}.mode-tag{background:#fff;border:1px solid #dde8ef;border-radius:20px;padding:8px 11px;color:#137e5b;font-size:9px;font-weight:800;white-space:nowrap;box-shadow:var(--shadow)}.real-tag{color:#276dc4}.map-actions{position:absolute;top:95px;left:22px;display:flex;gap:8px;z-index:300}.map-actions button{min-height:37px;padding:7px 12px;background:#fff;border:1px solid #e0e8ec;box-shadow:var(--shadow);border-radius:9px;color:#37536a;font-weight:750;font-size:11px}.map-actions button[aria-pressed=true]{border-color:#57c59e;color:#0b8859;background:#e8f9ef}.map-bottom-hint{position:absolute;bottom:20px;left:25px;z-index:200;background:#ffffffd9;border:1px solid #dde8e9;padding:10px;border-radius:9px;color:#758995;font-size:10px}.insights{position:absolute;z-index:400;top:13px;bottom:13px;right:14px;width:358px;display:flex;flex-direction:column;overflow:hidden;border-radius:16px;background:#fff;box-shadow:0 10px 35px #163b4c24;border:1px solid #e1eaf0}.insights-header{padding:18px 18px 6px;display:flex;justify-content:space-between;align-items:center;gap:8px}.insights-header h2{font-size:16px;margin:3px 0 5px;max-width:250px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.report-location{font-size:10px;color:#8093a4}.report-icon{font-size:23px;border-radius:11px;background:#edf8f1;padding:8px;color:#15ad6c}.stats-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;padding:12px 14px}.stat-card{border:1px solid #e9eef2;border-radius:10px;background:#fbfcfe;padding:11px 12px;display:flex;flex-direction:column;gap:5px;min-height:87px}.stat-card span{font-size:9px;color:#7e91a2;font-weight:800;letter-spacing:.4px}.stat-card strong{font-size:20px;color:#1f3953;line-height:1.2}.stat-card small{font-size:9px;color:#91a0ad}.stat-card.accent{background:#edfff5;border-color:#d4f4e3}.stat-card.accent strong{color:#0da66b}.coverage-title{display:flex;justify-content:space-between;align-items:center;padding:3px 17px 7px}.coverage-title strong{font-size:11px}.coverage-title span{font-size:9px;color:#8ca0b0}.coverage-bars{display:flex;height:9px;overflow:hidden;border-radius:10px;margin:0 17px;background:#eef1f4}.coverage-bars .seg{height:100%;width:0;transition:width .2s}.seg.green,.legend-dot.green{background:#17b367}.seg.amber,.legend-dot.amber{background:#e8b142}.seg.red,.legend-dot.red{background:#df6566}.seg.gray,.legend-dot.gray{background:#cbd5df}.legend{display:flex;gap:12px;padding:10px 18px 14px;border-bottom:1px solid #edf1f4;font-size:10px;color:#74899b;justify-content:space-between}.legend span{white-space:nowrap}.legend-dot{display:inline-block;width:9px;height:9px;border-radius:50%;margin-right:3px}.results-tabs{display:flex;padding:8px 13px 0;gap:4px;border-bottom:1px solid #e6edf1}.results-tabs button{border:0;background:none;padding:11px 9px;font-size:10px;font-weight:800;color:#8694a1;white-space:nowrap}.results-tabs button.selected{color:#128d58;border-bottom:2px solid #13a66c}.tab-panel{min-height:0;flex:1;overflow:auto;padding-bottom:10px;scrollbar-width:thin;scrollbar-color:#d9e3e8 transparent}.points-heading{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:12px 17px}.points-heading strong{font-size:11px}.points-heading small{font-size:10px;color:#8495a2}.points-heading button{border:1px solid #dce7ed;color:#46718a;background:#fff;border-radius:7px;padding:6px 8px;font-size:10px;font-weight:800;margin-left:4px}.points-heading button:hover{background:#eaf7f0;color:#108859}.point-list,.competitor-list,.history-list{padding:0 11px 12px}.point-row,.competitor-row,.history-row{width:100%;display:flex;align-items:center;gap:10px;min-height:51px;border:1px solid transparent;border-bottom-color:#edf1f4;background:#fff;text-align:left;padding:8px 5px}.point-row:hover,.point-row.selected,.competitor-row:hover,.history-row:hover{background:#f1faf5;border-radius:8px;border-color:#d9f3e5}.point-index{width:30px;height:30px;display:grid;place-items:center;background:#f1f5f8;color:#7990a3;border-radius:9px;font-weight:800;font-size:10px;flex-shrink:0}.point-row-main,.comp-main{display:flex;flex-direction:column;gap:4px;min-width:0;flex:1}.point-row-main strong,.comp-main strong{font-size:11px;color:#31465a;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.point-row-main small,.comp-main small{color:#9aa8b3;font-size:9px}.rank-tiny{padding:6px 9px;border-radius:8px;background:#f0f2f5;color:#9aacbb;font-weight:800;font-size:11px}.rank-tiny.good{background:#e2faed;color:#11a666}.rank-tiny.medium{background:#fff5d8;color:#aa7c0b}.rank-tiny.bad{background:#fff0ee;color:#d25055}.rank-tiny.disabled{background:#e9edf1;color:#a8b4bf}.panel-help{font-size:11px;color:#8597a5;line-height:1.75;padding:8px 17px}.competitor-row .point-index{background:#ecf4f9}.competitor-row .comp-main{padding:0;min-width:0}.competitor-row .comp-main small{line-height:1.6}.competitor-row .comp-status{font-size:9px;background:#f2faf6;padding:4px 7px;border-radius:6px;color:#418260;flex:0 0 auto}.competitor-row.me{border-left:3px solid #17ab70;background:#f0fbf5}.history-row{gap:7px;align-items:flex-start;flex-direction:column;padding:12px}.history-row b{font-size:11px}.history-row small{font-size:9px;color:#899bac}.history-row em{font-size:10px;color:#16905f;font-style:normal}.compare-label{margin:5px 17px}.tab-panel select{width:calc(100% - 34px);margin:0 17px}.compare-results{padding:12px 13px}.compare-headline{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-bottom:10px}.compare-headline .stat-card strong{font-size:18px}.compare-grids{display:grid;grid-template-columns:1fr 1fr;gap:10px}.mini-card{border:1px solid #e3eaf0;border-radius:12px;padding:7px;background:#f8fafc}.mini-title{font-size:10px;font-weight:750;color:#35506a;margin:4px 5px}.mini-sub{color:#899caf;font-size:9px;margin:3px 5px}.mini-map{position:relative;height:155px;background:linear-gradient(0deg,#edf2ef,#f5f9f4);border-radius:8px;overflow:hidden}.mini-dot{position:absolute;transform:translate(-50%,-50%);display:flex;align-items:center;justify-content:center;width:24px;height:24px;font-size:9px;font-weight:800;color:#fff;background:#17aa64;border:2px solid white;border-radius:50%;box-shadow:0 1px 4px #00221925}.mini-dot.medium{background:#f0b93c;color:#563f00}.mini-dot.bad{background:#df626b}.mini-dot.none,.mini-dot.disabled{background:#a9b6c3}.results-footnote{flex-shrink:0;padding:9px 16px;background:#f6f9fa;border-top:1px solid #e8edf1;font-size:9px;color:#8797a5;line-height:1.6}.rank-marker{background:transparent;border:0}.rank-pin{width:48px;height:48px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-weight:800;font-size:17px;color:white;background:#17a853;border:5px solid #b5f1c7;box-shadow:0 2px 9px #225c404c;transition:transform .15s}.rank-pin.good{background:#11a953;border-color:#97eeb5}.rank-pin.medium{background:#e1a81e;border-color:#ffe5a3;color:#fff}.rank-pin.bad{background:#e46567;border-color:#ffced0}.rank-pin.none{background:#8999a9;border-color:#dce5ed}.rank-pin.pending{background:#c1ced8;border-color:#f0f3f6;color:#7c8b98}.rank-pin.loading{background:#2d86d4;border-color:#c0ddf4}.rank-pin.disabled{background:#d2dbe2;border-color:#eef1f4;color:#acb6c0;opacity:.7}.rank-marker:hover .rank-pin{transform:scale(1.12)}.selected-marker .rank-pin{outline:4px solid #2b7fdb;outline-offset:2px}.competitor-marker{background:#fff;color:#2d67ad;border:2px solid #5797d6;border-radius:50%;display:grid;place-items:center;font-size:12px;font-weight:850;box-shadow:0 2px 9px #18385655}.center-pin{background:#fff;border:3px solid #17b873;border-radius:50%;height:19px;width:19px;box-shadow:0 0 0 7px #28c88b23}.leaflet-popup-content-wrapper{border-radius:12px!important;box-shadow:0 5px 20px #1e395537!important}.leaflet-popup-content{font:inherit;min-width:220px;color:#31465c}.pop-eyebrow{font-size:9px;color:#17915d;font-weight:800;letter-spacing:1px}.pop-title{font-size:14px;font-weight:800;margin:9px 0}.pop-detail{line-height:1.9;font-size:10px;color:#688091}.toast{position:fixed;z-index:1200;left:50%;bottom:26px;transform:translate(-50%,15px);opacity:0;pointer-events:none;border-radius:11px;background:#234b47;color:white;padding:12px 18px;max-width:90vw;font-size:11px;box-shadow:0 10px 25px #234b4735;transition:.25s}.toast.show{transform:translate(-50%,0);opacity:1}@media(max-width:1190px){.sidebar{flex-basis:284px;padding:19px 16px}.insights{width:326px}.map-top-right{right:350px}.map-actions{top:88px}.map-bottom-hint{max-width:225px}}@media(max-width:850px){.topbar-middle{display:none}.app{height:auto;min-height:100vh}.workspace{display:block}.sidebar{height:auto;width:100%;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 17px;overflow:visible}.sidebar-title,.section-divider,.sidebar-footer{grid-column:1/-1}.sidebar-title{margin:0}.sidebar-title h1{font-size:20px}.sidebar .form-section{margin:0}.sidebar .scan-btn,.sidebar .scan-caption,.sidebar .progress-track{grid-column:1/-1}.map-area{height:930px}.insights{width:330px;top:10px;bottom:10px;right:10px}.map-top-right{right:352px}.map-actions{left:15px}.map-bottom-hint{display:none}}@media(max-width:620px){.topbar{padding:10px 14px;min-height:60px}.version{font-size:8px}.brand-copy strong{font-size:17px}.sidebar{display:block;padding:17px}.sidebar-title,.sidebar .form-section{margin-bottom:15px}.map-area{height:auto;display:flex;flex-direction:column;overflow:visible}.map-area #map{height:520px;flex:none}.insights{position:relative;top:auto;right:auto;bottom:auto;width:auto;height:690px;margin:10px;border-radius:13px}.map-top-left{top:10px;left:10px}.map-top-right{top:15px;right:10px}.map-pill{padding:8px}.map-top-caption{font-size:8px}.map-actions{top:67px;left:10px}.map-actions button{padding:8px}.map-bottom-hint{display:none}.leaflet-control-zoom{display:none}}@media print{.topbar,.sidebar,.map-actions,.map-top-right,.map-bottom-hint,.results-tabs,.results-footnote{display:none!important}.app{height:auto}.workspace{display:block}.map-area{height:750px}.insights{position:absolute;right:10px;top:10px;bottom:10px;width:330px}}

/* v1.4 competitor explorer: same one SERP scan, multiple business grid views */
.topbar-right{display:flex;gap:10px;align-items:center}.theme-btn{background:#f3f6fa;border:1px solid #dce5ed;border-radius:9px;color:#34556c;padding:9px 11px;font-size:10px;font-weight:750}
.early-stop{display:flex;gap:8px;align-items:flex-start;line-height:1.6;margin:10px 0 4px;font-size:10px;color:#567183;font-weight:600}.early-stop input{width:15px;height:15px;accent-color:#12a366;flex:none}
.tracked-business{padding:13px 17px;display:flex;align-items:center;justify-content:space-between;gap:8px;background:#f2fbf7;border-bottom:1px solid #e0eee8}.tracked-business>div{display:flex;flex-direction:column;gap:4px;min-width:0}.tracked-business span{font-size:9px;color:#2d9871;font-weight:850;letter-spacing:.55px}.tracked-business strong{font-size:13px;color:#1d4b3e;line-height:1.35;overflow:hidden;text-overflow:ellipsis}.tracked-business small{font-size:10px;color:#68827b;line-height:1.4}.tracked-business button{border:1px solid #99d6b6;background:#fff;border-radius:8px;padding:9px 10px;white-space:nowrap;font-size:10px;font-weight:800;color:#188659}
.results-tabs{display:flex;overflow-x:auto;scrollbar-width:thin}.results-tabs button{flex:1 0 auto;padding-left:9px;padding-right:9px;font-size:10px}.target-chip{display:block;margin-top:7px;max-width:265px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;background:#fff;color:#1f6347;border:1px solid #c4e8d3;border-radius:8px;padding:7px 9px;font-size:9px;font-weight:800}
.explore-search{width:100%;height:37px;margin:8px 0 11px;padding:0 11px;border:1px solid #dce4e9;border-radius:9px;background:#fff;color:#274356;font-size:11px}.explore-head{display:flex;justify-content:space-between;color:#5b6e83;font-size:10px;padding:4px 0 9px}.explore-head strong{color:#1f4660}.explore-list{display:flex;flex-direction:column;gap:7px;max-height:none}.explore-row{width:100%;display:flex;gap:9px;align-items:center;text-align:left;padding:10px 8px;border:1px solid #e1e9eb;border-radius:11px;background:#fff;color:#293c4a}.explore-row:hover,.explore-row.current{border-color:#32a675;background:#ebfaf2}.explore-row.own{border-left:4px solid #12a26b}.explore-badge{background:#e9f5ef;color:#14865b;flex:none;min-width:28px;height:28px;border-radius:50%;display:grid;place-items:center;font-weight:800;font-size:11px}.explore-main{display:flex;flex:1;flex-direction:column;gap:3px;min-width:0}.explore-main strong{font-size:11px;line-height:1.45;overflow-wrap:anywhere}.explore-main small{font-size:9px;color:#79899a;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.explore-sub{font-size:9px;color:#21855f}.explore-metrics{flex:none;min-width:48px;text-align:right;display:flex;flex-direction:column;gap:3px;color:#26925f}.explore-metrics b{font-size:13px}.explore-metrics small{font-size:9px;color:#708399}.selected-comp{background:#e6f9ee!important;outline:2px solid #33b879}.insights{overflow:hidden}.tab-panel{overflow-y:auto}
body.theme-dark{--bg:#090e29;--paper:#141c3c;--stroke:#2d365d;--ink:#f0f5ff;--muted:#9eabca;background:#090e29;color:#e2eafa}body.theme-dark .topbar,body.theme-dark .sidebar,body.theme-dark .insights{background:#111936;color:#eef5ff;border-color:#2e3b5c}body.theme-dark .sidebar-title p,body.theme-dark label,body.theme-dark .field-caption,body.theme-dark .panel-help{color:#a6b5d5}body.theme-dark input[type=text],body.theme-dark select,body.theme-dark .explore-search{color:#e8f0ff;background:#202b4e;border-color:#3b4c75}body.theme-dark .explore-row,body.theme-dark .tracked-business,body.theme-dark .theme-btn{background:#1b294b;border-color:#3c4d74;color:#e3edff}body.theme-dark .tracked-business strong,body.theme-dark .explore-main strong,body.theme-dark .explore-head strong{color:#edf6ff}body.theme-dark .explore-row.current{background:#183f43;border-color:#28aa7b}body.theme-dark .map-pill,body.theme-dark .map-top-caption{color:#f5fafc}body.theme-dark .version{color:#9fb4d0}body.theme-dark .stat-card{background:#202d51;color:#ebf3ff;border-color:#37466c}body.theme-dark .stat-card strong{color:#f3fbff}body.theme-dark .results-tabs{background:#1d2a4b}body.theme-dark .results-tabs button{color:#b9c9e6}body.theme-dark .results-tabs button.selected{color:#34df92}body.theme-dark .point-row,body.theme-dark .competitor-row,body.theme-dark .history-row{color:#eaf2ff;border-color:#3a486c;background:#1a2647}body.theme-dark .results-footnote{color:#b2c3df}body.theme-dark .explore-sub{color:#74dcb1}body.theme-dark .tracked-business span{color:#67deb0}
@media(max-width:620px){.theme-btn{font-size:9px;padding:7px}.target-chip{max-width:160px}.explore-list{max-height:460px}}

.rank-pin.unknown{background:#7868b6;border-color:#cec5f4}
.business-profile{padding:12px;margin:6px 0 13px;border:1px solid #bde5cf;border-radius:12px;background:#f1fbf5;color:#2b5042}.profile-title{display:flex;justify-content:space-between;gap:8px;align-items:flex-start;margin-bottom:9px}.profile-title strong{font-size:12px;line-height:1.5}.profile-title button{width:25px;height:25px;border:none;border-radius:8px;background:#dceee4;color:#2d6b50;font-size:18px}.profile-details{display:grid;grid-template-columns:77px minmax(0,1fr);gap:7px;font-size:10px;line-height:1.5}.profile-details span{color:#648579}.profile-details b{font-weight:600;overflow-wrap:anywhere}.business-profile a{font-size:10px;color:#16895a;display:inline-block;margin-top:10px;font-weight:750}body.theme-dark .business-profile{background:#21344a;color:#e2f8eb;border-color:#3b6e5e}

.export-competitors{border:1px solid #b6dccc;border-radius:8px;background:#f0f9f4;color:#18835c;padding:7px 9px;font-size:9px;font-weight:800}body.theme-dark .export-competitors{background:#17394b;color:#74dcb1}

/* v1.5 reliability diagnostics: prevent misleading 0% on failed requests */
.api-health{border:1px solid #bcdad2;border-radius:10px;background:#f4fbf8;padding:10px 11px;margin:8px 0 9px;display:flex;flex-direction:column;gap:7px}.api-health small{font-size:10px;line-height:1.5;color:#617787}.api-test-btn{width:100%;background:#fff;color:#147955;border:1px solid #a7d6c0;border-radius:8px;padding:8px 10px;font-size:11px;font-weight:750;cursor:pointer}.api-test-btn:hover{background:#e4f7ed}.scan-issue:not([hidden]){display:block;margin:8px 0;padding:10px 12px;background:#fff0f0;color:#aa2828;border:1px solid #e8b4b4;border-radius:9px;line-height:1.5;font-size:11px;overflow-wrap:anywhere}.point-row-error{color:#ae3c40!important;line-height:1.35!important;white-space:normal!important;word-break:break-word;max-height:70px;overflow-y:auto}.rank-tiny.error{background:#fbe3e4;color:#af3036}.rank-pin.error{background:#ad6670!important;color:#fff;border-color:#f5a7b5!important}body.theme-dark .api-health{background:#1c3440;border-color:#366e61}body.theme-dark .api-health small{color:#abc4bd}body.theme-dark .api-test-btn{background:#224a42;color:#b6fce0;border-color:#33816b}body.theme-dark .scan-issue:not([hidden]){background:#421d27;color:#ffc6d0;border-color:#994e59}body.theme-dark .point-row-error{color:#ffacb6!important}
.api-health[hidden],.scan-issue[hidden]{display:none!important}

/* v1.6 – rank pins are always above basemap and map lines. */
.leaflet-pane.leaflet-georankrankPins-pane {z-index:660 !important;}
.leaflet-pane.leaflet-georankrankCenter-pane {z-index:640 !important;}
.leaflet-pane.leaflet-georankrankCompetitors-pane {z-index:620 !important;}
.leaflet-pane.leaflet-georankrankLines-pane {z-index:420 !important;pointer-events:none;}
.rank-marker {width:52px !important;height:52px !important;background:transparent !important;border:0 !important;overflow:visible !important;}
.rank-marker .rank-pin {width:52px;height:52px;display:flex !important;align-items:center;justify-content:center;border-radius:50%;font-size:21px !important;font-weight:900;line-height:1;color:#fff;border:4px solid #dbf8e6;outline:2px solid #138c55;outline-offset:-6px;text-shadow:0 1px 2px rgba(0,0,0,.26);box-shadow:0 3px 0 rgba(5,75,46,.13),0 5px 15px rgba(0,51,40,.31),0 0 0 3px rgba(255,255,255,.82) !important;transition:transform .15s ease;position:relative;}
.rank-marker .rank-pin.good{background:#08a941;border-color:#b3f3c7;outline-color:#158a51;}
.rank-marker .rank-pin.medium{background:#f1ad26;border-color:#fff3c9;outline-color:#b37608;}
.rank-marker .rank-pin.bad{background:#e45b61;border-color:#ffd2d6;outline-color:#b63844;}
.rank-marker .rank-pin.none{background:#748698;border-color:#e5ebf2;outline-color:#657585;}
.rank-marker .rank-pin.pending{background:#b7c6d3;border-color:#f1f5f9;outline-color:#9daab7;color:#233b4b;text-shadow:none;}
.rank-marker .rank-pin.loading{background:#257ed0;border-color:#d6eafa;outline-color:#1764a0;}
.rank-marker .rank-pin.error{background:#a94455;border-color:#ffd3d9;outline-color:#8d3040;color:#fff;}
.rank-marker .rank-pin.unknown{background:#7867b1;border-color:#e4ddff;outline-color:#635394;}
.rank-marker .rank-pin.disabled{background:#c7d0d9;border-color:#f4f6f9;outline-color:#afbac5;opacity:.8;}
.selected-marker .rank-pin{box-shadow:0 0 0 5px #2784f0,0 5px 16px #08365b60!important;}
.map-area #map{isolation:isolate;}
.map-tile-error:not([hidden]){position:absolute;left:15px;bottom:72px;z-index:350;width:min(355px,calc(100% - 30px));background:#fff;border:1px solid #e5b3a2;border-radius:12px;box-shadow:0 9px 25px #1e3c5730;padding:12px 14px;color:#8c3e28;font-size:11px;line-height:1.6;}
.map-tile-error button{margin-top:7px;display:block;background:#eaf6ef;border:1px solid #a5ddbd;border-radius:7px;color:#127744;font-weight:750;padding:7px 10px;}
/* Dark style filters ONLY OSM tiles: markers and text remain brightly readable. */
body.theme-dark .leaflet-tile-pane{filter:invert(1) hue-rotate(195deg) saturate(.58) brightness(.72) contrast(1.22);}
body.theme-dark .leaflet-container{background:#17273b;}
body.theme-dark .leaflet-control-attribution{background:#fff!important;color:#2b3848!important;}
body.theme-dark .map-tile-error{background:#271e33;color:#ffe3d6;border-color:#704556;}
.leaflet-bottom.leaflet-left .leaflet-control-attribution{margin-bottom:3px;margin-left:8px;border-radius:3px;}
@media(max-width:620px){.rank-marker,.rank-marker .rank-pin{width:45px!important;height:45px!important;font-size:18px!important}.map-tile-error:not([hidden]){bottom:auto;top:125px;left:10px;width:min(300px,calc(100% - 20px));}}

/* v1.7: don't hide rank pins on broken network tile backgrounds */
.leaflet-pane.leaflet-georankrankPins-pane{z-index:660!important;visibility:visible!important;opacity:1!important}
.leaflet-pane.leaflet-georankrankCenter-pane{z-index:640!important}
.leaflet-tile-pane{z-index:200!important}
.leaflet-marker-pane{z-index:600!important}
.leaflet-div-icon.rank-marker{background:transparent!important}
.rank-pin{min-width:48px;min-height:48px;opacity:1!important}
.map-tile-error{z-index:850!important;pointer-events:auto;}
/* v1.8 map view + rank bubbles */
.map-actions{display:flex;flex-wrap:wrap;max-width:370px;gap:7px}.map-actions button{white-space:nowrap}.map-actions button[aria-pressed=true]{border-color:#23a96c!important;background:#e5fff0!important;color:#0c7d49!important}
.rank-marker .rank-pin{font-size:23px!important;font-family:system-ui,-apple-system,'Segoe UI',sans-serif;font-weight:950!important;letter-spacing:-.65px;font-variant-numeric:tabular-nums;isolation:isolate}
.rank-marker .rank-pin.rank-first{background:#00a734!important;border:4px solid #b6f8b6!important;outline:2px solid #0fba50;outline-offset:0;box-shadow:0 0 0 3px #21bc50,0 4px 16px #003b2570,0 0 0 5px #fcfffbcc!important}
.rank-marker .rank-pin.rank-first:before{content:'';position:absolute;inset:-9px;border-radius:50%;z-index:-1;background:repeating-conic-gradient(#17bd49 0deg 12deg,#36dc62 12deg 20deg);clip-path:circle(49%);opacity:.82}
.rank-marker .rank-pin.medium{color:#3f3007!important;text-shadow:none!important}.rank-marker .rank-pin.bad{color:white!important}.rank-marker .rank-pin.pending{opacity:.93!important}
.leaflet-pane.leaflet-georankrankHeat-pane{z-index:390!important;pointer-events:none}.map-area #map{background:#eef5ed}
body.theme-dark .map-area #map{background:#13253a}
.map-focus .sidebar{display:none!important}.map-focus .map-area{flex:1 1 auto!important;width:100%!important}.map-focus .insights{width:385px}.map-focus .map-top-right{right:411px}
/* v1.8 per-coordinate ranking list */
.point-location-banner{margin:9px 13px 0;border-radius:11px;border:1px solid #d7ebdf;background:#f0faf4;padding:11px 13px;display:flex;flex-direction:column;gap:5px;color:#205e45}
.point-location-banner span{font-size:9px;letter-spacing:.35px;font-weight:800;text-transform:uppercase;color:#648476}.point-location-banner strong{font-size:12px;font-weight:800;letter-spacing:.2px;font-variant-numeric:tabular-nums}.point-location-banner a{font-size:9px;font-weight:750;color:#126f4b;text-decoration:underline;text-underline-offset:3px}.result-list-hint{font-size:9px;color:#5f798e;padding:0 13px 12px;line-height:1.6}
.comp-row-wrap{position:relative;display:flex;align-items:stretch;gap:5px;border-bottom:1px solid #ecf0f4}.comp-row-wrap:hover{background:#f0faf6}.comp-row-wrap .competitor-row{flex:1;min-width:0;border-bottom:0;min-height:69px;gap:9px;padding:8px 3px}
.comp-row-wrap .competitor-row .comp-main strong{font-size:11px;line-height:1.45;white-space:normal;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.comp-row-wrap .competitor-row .comp-main small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#78909d;font-size:9px}
.comp-extra{display:block;color:#cd8c19;font-size:9px;line-height:1.5}.comp-view{display:block;font-size:9px;font-weight:750;color:#168456;white-space:nowrap;padding:4px 5px;border-radius:6px;background:#ebf9f0}.comp-maps-link{align-self:flex-end;margin:0 5px 8px 0;font-size:9px;color:#2779b9;white-space:nowrap;text-decoration:none}.comp-maps-link:hover{text-decoration:underline}
.comp-row-wrap .point-index{border-radius:50%;width:32px;height:32px;font-size:13px;font-variant-numeric:tabular-nums}.rank-index-1{background:#dbf9e6!important;color:#0f9b4d!important}.rank-index-2{background:#fff0bf!important;color:#8e6800!important}.rank-index-3,.rank-index-4{background:#f2f4f8!important;color:#45627a!important}
.comp-row-wrap .comp-status{display:none!important}.comp-row-wrap .competitor-row.me{border-left:3px solid #17ab70!important}.comp-row-wrap .competitor-row.selected-comp{border-radius:9px;outline:2px solid #20ab62!important;outline-offset:-2px}

body.theme-dark .point-location-banner{background:#1d3c38;color:#e6fff1;border-color:#3e6f5d}.theme-dark .point-location-banner a,.theme-dark .point-location-banner span{color:#91eac2}.theme-dark .result-list-hint{color:#b5cdd0}.theme-dark .comp-extra{color:#f9b94c}.theme-dark .comp-row-wrap{border-color:#3b4d6b}.theme-dark .comp-row-wrap:hover{background:#143e38}.theme-dark .comp-view{background:#174c3d;color:#9af8c9}.theme-dark .comp-maps-link{color:#8acaff}
@media(max-width:1000px){.map-focus .insights{width:345px}.map-focus .map-top-right{right:370px}.map-actions{max-width:300px}}
@media(max-width:850px){.map-focus .sidebar{display:none}.map-focus .map-area{height:1000px}.map-focus .insights{width:340px}.map-actions{max-width:330px}}
@media(max-width:620px){.map-focus .map-area{height:auto}.map-focus .insights{width:auto}.map-actions{max-width:calc(100% - 20px)}.map-actions button{font-size:9px;padding:7px}.comp-view{display:none}.comp-row-wrap .comp-maps-link{max-width:61px;white-space:normal;font-size:8px}.rank-marker .rank-pin{font-size:19px!important}.map-top-right{right:10px}}

/* GeoRank dashboard design system: compact, map-first, and readable in both themes. */
:root{
	color-scheme:light;
	--bg:#f8fafc;
	--paper:#fff;
	--stroke:#dbe3ec;
	--subtle:#eef2f7;
	--ink:#1e293b;
	--muted:#475569;
	--green:#15803d;
	--amber:#d97706;
	--red:#dc2626;
	--blue:#1e40af;
	--shadow:0 10px 28px rgba(15,23,42,.12);
	--focus-ring:0 0 0 3px rgba(30,64,175,.22);
}
html,body{background:var(--bg);color:var(--ink);font-family:'Be Vietnam Pro',sans-serif;font-size:13px}
button,input,select{font-family:inherit}
.app{height:100dvh;min-height:680px;background:var(--bg)}
.topbar{min-height:62px;padding:0 18px;background:var(--paper);border-color:var(--stroke)}
.brand-icon{width:36px;height:36px;border-radius:9px;background:#e8f4ec;color:var(--green)}
.brand-copy strong{font-size:17px;letter-spacing:0}
.brand-copy small{letter-spacing:1px}
.topbar-middle{font-size:11px;color:var(--muted)}
.version{border-color:var(--stroke);border-radius:6px;color:var(--muted)}
.workspace{min-height:0}
.sidebar{flex:0 0 300px;padding:18px 17px;background:var(--paper);border-color:var(--stroke)}
.sidebar-title{margin-bottom:17px}
.eyebrow{color:var(--blue);font-size:10px;letter-spacing:.7px}
.sidebar-title h1{font-size:21px;line-height:1.35;letter-spacing:0}
.sidebar-title h1 span{color:var(--blue)}
.sidebar-title p,.panel-help,.field-caption{color:var(--muted);font-size:11px;line-height:1.6}
.form-section{margin-bottom:14px}
label{color:#334155;font-size:11px}
input[type=text],select{height:40px;border:1px solid #cbd5e1;border-radius:7px;background:#fff;color:#1e293b;font-size:12px;outline:none}
input[type=text]:focus,select:focus{border-color:var(--blue);box-shadow:var(--focus-ring)}
.location-search .icon-btn,.center-coordinate,.api-health{border-radius:7px}
.quick-locations button{border-radius:5px}
.mode-toggle{gap:5px}
.mode-toggle button{min-height:40px;padding:8px;border-radius:6px;background:#f1f5f9;border-color:#dbe3ec;color:#475569;font-size:11px}
.mode-toggle button.selected{background:#e8efff;border-color:#8ca9ed;color:#1e40af}
.grid-help{color:var(--muted);font-size:10px;line-height:1.5}
.api-health{background:#f0f7f2;border-color:#cfe2d4}
.api-health small{color:#475569;line-height:1.5}
.api-test-btn{min-height:38px;border-radius:6px;background:#fff;border-color:#b8d2bf;color:#166534}
.scan-btn{min-height:46px;padding:12px 14px;border-radius:7px;background:#1e40af;box-shadow:0 4px 12px rgba(30,64,175,.18)}
.scan-btn:hover{background:#1d3690}
.scan-caption{color:var(--muted)}
.sidebar-footer{border-color:var(--stroke)}
.map-area{background:#e8edf2}
.map-area #map{position:relative;overflow:hidden}
.map-area #map{background:#edf1f3}
.map-top-left{top:15px;left:16px}
.map-pill{border-radius:6px;box-shadow:0 2px 8px rgba(15,23,42,.1)}
.map-top-caption{color:#334155;font-size:10px;letter-spacing:.5px}
.map-top-right{right:370px;top:17px}
.mode-tag,.target-chip{border-radius:5px}
.map-actions{top:78px;left:16px;max-width:calc(100% - 390px);gap:6px}
.map-actions button{min-height:40px;padding:8px 10px;border:1px solid #d5dee8;border-radius:6px;color:#334155;font-size:11px;box-shadow:0 2px 8px rgba(15,23,42,.1)}
.map-actions button[aria-pressed=true]{background:#e8efff!important;border-color:#7395e5!important;color:#1e40af!important}
.map-bottom-hint{left:16px;bottom:15px;border-radius:5px}
.insights{top:12px;right:12px;bottom:12px;width:346px;border:1px solid var(--stroke);border-radius:9px;background:var(--paper);box-shadow:0 8px 24px rgba(15,23,42,.14)}
.insights-header{padding:14px 15px 4px}
.insights-header h2{color:#1e293b;font-size:16px;letter-spacing:0}
.report-location{color:var(--muted)}
.report-icon{color:var(--blue)}
.stats-grid{gap:7px;padding:10px 12px}
.stat-card{min-height:78px;padding:9px 10px;border:1px solid #e2e8f0;border-radius:6px;background:#f8fafc}
.stat-card span{color:#475569;font-size:9px;letter-spacing:.35px}
.stat-card strong{color:#1e293b;font-size:21px;font-variant-numeric:tabular-nums}
.stat-card small{color:#475569;font-size:10px}
.stat-card.accent{background:#eef4ff;border-color:#c9d7f5}
.stat-card.accent strong{color:#1e40af}
.coverage-title,.legend,.tracked-business{border-color:var(--stroke)}
.coverage-title{color:#334155}
.legend{color:#475569}
.results-tabs{padding:5px 9px 0;gap:1px;background:#f8fafc;border-color:var(--stroke)}
.results-tabs button{min-height:40px;padding:9px 8px;color:#475569;font-size:10px}
.results-tabs button.selected{color:#1e40af;border-color:#1e40af}
.results-tabs button:focus-visible{position:relative;z-index:1}
.tab-panel{scrollbar-color:#cbd5e1 transparent}
.panel-help{padding-left:12px;padding-right:12px}
.tracked-business{background:#f1f5f9;border-radius:0;padding:11px 13px}
.tracked-business span{color:#475569}
.tracked-business strong{color:#1e293b}
.tracked-business small{color:#475569}
.explore-search{border-radius:6px;color:#1e293b}
.explore-head{color:#475569}
.explore-row,.point-row,.competitor-row,.history-row{border-color:#e2e8f0;border-radius:6px;background:#fff;color:#1e293b}
.explore-row{padding:9px 8px}
.explore-row:hover,.explore-row.current,.point-row:hover,.competitor-row:hover,.history-row:hover{border-color:#8ca9ed;background:#f1f5ff}
.explore-row.current{box-shadow:inset 3px 0 #1e40af}
.explore-main strong,.explore-head strong{color:#1e293b}
.explore-main small,.explore-metrics small{color:#475569}
.explore-metrics{color:#1e40af}
.point-location-banner{border-radius:6px;background:#f1f5f9;border-color:#dbe3ec;color:#1e293b}
.point-location-banner span,.point-location-banner a{color:#1e40af}
.result-list-hint{color:#475569}
.comp-row-wrap{border-color:#e2e8f0}
.comp-row-wrap:hover{background:#f8fafc}
.comp-extra{color:#475569}
.comp-view{color:#1e40af;background:#eef4ff}
.comp-maps-link{color:#1e40af}
.business-profile{border-radius:6px;background:#f1f5f9;color:#1e293b}
.export-competitors{border-radius:5px;background:#eef4ff;border-color:#c9d7f5;color:#1e40af}
.rank-index-1,.rank-index-2,.rank-index-3,.rank-index-4{font-family:'Fira Code',monospace;font-variant-numeric:tabular-nums}
.rank-index-1{background:#dcfce7!important;color:#166534!important}
.rank-index-2{background:#fef3c7!important;color:#854d0e!important}
.rank-index-3,.rank-index-4{background:#fee2e2!important;color:#991b1b!important}
.rank-marker .rank-pin{font-family:'Fira Code',monospace!important;font-size:20px!important;font-weight:700!important;letter-spacing:0!important;border-width:3px!important;outline-width:2px!important;box-shadow:0 3px 10px rgba(15,23,42,.28),0 0 0 3px rgba(255,255,255,.92)!important}
.rank-marker .rank-pin.good{background:#15803d!important;border-color:#dcfce7!important;outline-color:#166534!important;color:#fff!important}
.rank-marker .rank-pin.medium{background:#facc15!important;border-color:#fef3c7!important;outline-color:#a16207!important;color:#422006!important}
.rank-marker .rank-pin.bad{background:#dc2626!important;border-color:#fee2e2!important;outline-color:#991b1b!important;color:#fff!important}
.rank-marker .rank-pin.none,.rank-marker .rank-pin.disabled{background:#64748b!important;border-color:#e2e8f0!important;outline-color:#475569!important;color:#fff!important}
.rank-marker .rank-pin.pending{background:#e2e8f0!important;border-color:#fff!important;outline-color:#94a3b8!important;color:#334155!important}
.rank-marker .rank-pin.loading{background:#1e40af!important;border-color:#dbeafe!important;outline-color:#1e3a8a!important;color:#fff!important}
.rank-marker .rank-pin.error{background:#7f1d1d!important;border-color:#fee2e2!important;outline-color:#7f1d1d!important;color:#fff!important}
.rank-marker .rank-pin.unknown{background:#475569!important;border-color:#e2e8f0!important;outline-color:#334155!important;color:#fff!important}
.rank-marker .rank-pin.rank-first:before{display:none}
.selected-marker .rank-pin{box-shadow:0 0 0 4px #1e40af,0 4px 14px rgba(15,23,42,.35)!important}
.map-tile-error:not([hidden]){border-radius:7px}
.theme-btn{min-height:38px;padding:8px 11px;border:1px solid var(--stroke);border-radius:6px;background:#f1f5f9;color:#334155;font-size:11px}
button,a,input,select{transition:background-color .16s ease,border-color .16s ease,color .16s ease,box-shadow .16s ease}
:focus-visible{outline:3px solid #2563eb!important;outline-offset:2px!important;box-shadow:var(--focus-ring)}
button:disabled{opacity:.55}
body.theme-dark{color-scheme:dark;--bg:#0f172a;--paper:#172235;--stroke:#334155;--subtle:#1e293b;--ink:#f1f5f9;--muted:#cbd5e1;--shadow:0 10px 28px rgba(0,0,0,.32);--focus-ring:0 0 0 3px rgba(96,165,250,.32);background:var(--bg);color:var(--ink)}
body.theme-dark .topbar,body.theme-dark .sidebar,body.theme-dark .insights{background:var(--paper);color:var(--ink);border-color:var(--stroke)}
body.theme-dark .brand-icon{background:#173b2a;color:#4ade80}
body.theme-dark .topbar-middle,body.theme-dark .version,body.theme-dark .sidebar-title p,body.theme-dark label,body.theme-dark .field-caption,body.theme-dark .panel-help,body.theme-dark .grid-help{color:#cbd5e1}
body.theme-dark .sidebar-title h1,body.theme-dark .insights-header h2,body.theme-dark .stat-card strong,body.theme-dark .tracked-business strong,body.theme-dark .explore-main strong,body.theme-dark .explore-head strong{color:#f1f5f9}
body.theme-dark input[type=text],body.theme-dark select,body.theme-dark .explore-search{background:#0f172a;color:#f1f5f9;border-color:#475569}
body.theme-dark .mode-toggle button,body.theme-dark .theme-btn,body.theme-dark .results-tabs,body.theme-dark .tracked-business{background:#1e293b;border-color:#334155;color:#e2e8f0}
body.theme-dark .mode-toggle button.selected,body.theme-dark .results-tabs button.selected{background:#1e3a5f;color:#bfdbfe;border-color:#60a5fa}
body.theme-dark .stat-card,body.theme-dark .explore-row,body.theme-dark .point-row,body.theme-dark .competitor-row,body.theme-dark .history-row{background:#1e293b;color:#f1f5f9;border-color:#334155}
body.theme-dark .stat-card span,body.theme-dark .stat-card small,body.theme-dark .explore-main small,body.theme-dark .explore-metrics small,body.theme-dark .tracked-business small,body.theme-dark .tracked-business span,body.theme-dark .legend,body.theme-dark .coverage-title{color:#cbd5e1}
body.theme-dark .stat-card.accent,body.theme-dark .point-location-banner,body.theme-dark .business-profile{background:#1e293b;border-color:#475569;color:#f1f5f9}
body.theme-dark .point-location-banner span,body.theme-dark .point-location-banner a,body.theme-dark .comp-view,body.theme-dark .comp-maps-link{color:#93c5fd}
body.theme-dark .comp-view,body.theme-dark .export-competitors{background:#1e3a5f;border-color:#365b91}
body.theme-dark .explore-row:hover,body.theme-dark .explore-row.current,body.theme-dark .point-row:hover,body.theme-dark .competitor-row:hover,body.theme-dark .history-row:hover{background:#253754;border-color:#60a5fa}
body.theme-dark .rank-marker .rank-pin.good{background:#15803d!important}
body.theme-dark .rank-marker .rank-pin.medium{background:#facc15!important;color:#422006!important}
body.theme-dark .rank-marker .rank-pin.bad{background:#dc2626!important}
body.theme-dark .api-health{background:#1b3325;border-color:#365b40}
body.theme-dark .api-health small{color:#d1fae5}
body.theme-dark .api-test-btn{background:#1e293b;color:#bbf7d0;border-color:#365b40}
body.theme-dark .scan-issue:not([hidden]){background:#451a1a;color:#fecaca;border-color:#991b1b}
body.theme-dark .map-area #map{background:#1e293b}
body.theme-dark .leaflet-tile-pane{filter:invert(1) hue-rotate(195deg) saturate(.58) brightness(.72) contrast(1.22)}
body.theme-dark .leaflet-container{background:#1e293b}
body.theme-dark .leaflet-control-attribution{background:#fff!important;color:#334155!important}
body.theme-dark .map-tile-error{background:#271e33;color:#ffe3d6;border-color:#704556}
@media(max-width:1100px){
	.sidebar{flex-basis:270px;padding:16px 14px}
	.insights{width:325px}
	.map-top-right{right:346px}
	.map-actions{max-width:calc(100% - 350px)}
}
@media(max-width:850px){
	.app{height:auto;min-height:100dvh}
	.workspace{display:block}
	.sidebar{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:7px 14px;width:100%;height:auto;padding:15px 16px}
	.sidebar-title,.section-divider,.sidebar-footer{grid-column:1/-1}
	.sidebar-title{margin:0 0 6px}
	.sidebar .form-section{margin:0 0 7px}
	.sidebar .scan-btn,.sidebar .scan-caption,.sidebar .progress-track,.api-health,.scan-issue{grid-column:1/-1}
	.map-area{height:760px}
	.insights{width:320px;top:10px;right:10px;bottom:10px}
	.map-top-right{right:337px;top:13px}
	.map-actions{top:72px;max-width:calc(100% - 340px)}
}
@media(max-width:620px){
	.app{min-height:100dvh}
	.topbar{min-height:56px;padding:0 10px;gap:6px}
	.brand{gap:7px}
	.brand-icon{width:32px;height:32px;font-size:25px}
	.brand-copy strong{font-size:15px}
	.brand-copy small,.topbar-middle,.version{display:none}
	.topbar-right{margin-left:auto}
	.theme-btn{min-height:36px;font-size:10px}
	.sidebar{display:block;padding:14px 13px}
	.sidebar .form-section{margin-bottom:13px}
	.sidebar-title{margin-bottom:15px}
	.sidebar-title h1{font-size:19px}
	.sidebar .section-divider{margin:12px 0}
	.map-area{height:auto;display:flex;flex-direction:column;overflow:visible}
	.map-area #map{height:min(62svh,560px);min-height:390px;flex:none}
	.map-top-left{top:9px;left:9px;max-width:55%}
	.map-top-right{top:9px;right:8px;max-width:42%}
	.map-pill{max-width:100%;font-size:10px}
	.target-chip{max-width:100%;font-size:8px}
	.map-top-caption{font-size:8px;padding:6px 4px}
	.map-actions{top:67px;left:9px;right:9px;max-width:none;gap:5px}
	.map-actions button{min-height:38px;padding:7px 8px;font-size:10px}
	.map-bottom-hint{display:none}
	.insights{position:relative;inset:auto;width:auto;height:auto;min-height:600px;max-height:none;margin:0;border-radius:0;border-left:0;border-right:0;box-shadow:none}
	.insights-header{padding:14px 14px 5px}
	.stats-grid{padding:8px 10px;gap:6px}
	.stat-card{min-height:72px}
	.results-tabs{position:sticky;top:0;z-index:3;overflow-x:auto;scrollbar-width:thin;padding:4px 7px 0}
	.results-tabs button{flex:0 0 auto;min-width:65px;padding:9px 8px}
	.tab-panel{min-height:360px;max-height:none;padding-bottom:18px}
	.explore-list{max-height:58svh;overflow:auto}
	.map-focus .sidebar{display:none!important}
	.map-focus .map-area{height:auto}
	.map-focus .map-area #map{height:70svh}
	.map-focus .insights{width:auto;height:auto}
	.map-focus .map-top-right{right:8px}
	.map-tile-error:not([hidden]){top:115px;left:9px;width:min(300px,calc(100% - 18px))}
	.rank-marker,.rank-marker .rank-pin{width:46px!important;height:46px!important}
	.rank-marker .rank-pin{font-size:18px!important}
	.comp-view{display:block}
	.comp-row-wrap .comp-maps-link{max-width:none;white-space:nowrap;font-size:9px}
}
@media(prefers-reduced-motion:reduce){
	*,*::before,*::after{scroll-behavior:auto!important;animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}
}

/* Coverage, map layer controls, and touch-first result drawer. */
.coverage-bars{background:#e2e8f0}
.coverage-bars .seg.unknown,.legend-dot.unknown{background:#2563eb}
.coverage-bars .seg.error,.legend-dot.error{background:#7f1d1d}
.coverage-bars .seg.pending,.legend-dot.pending{background:#cbd5e1}
.coverage-bars .seg.pending{background-image:repeating-linear-gradient(135deg,transparent 0 3px,#f8fafc 3px 5px)}
.mini-dot.error{background:#7f1d1d}
.mini-dot.unknown{background:#2563eb}
.mini-dot.pending{background:#cbd5e1;color:#334155}
.rank-marker.dense,.rank-marker.dense .rank-pin{width:42px!important;height:42px!important}
.rank-marker.dense .rank-pin{font-size:17px!important}
.rank-marker.compact,.rank-marker.compact .rank-pin{width:36px!important;height:36px!important}
.rank-marker.compact .rank-pin{font-size:14px!important;border-width:2px!important}
.rank-marker.dense .rank-pin,.rank-marker.compact .rank-pin{min-width:0!important;min-height:0!important}
.competitor-marker.tracked{border:3px solid #15803d;background:#dcfce7;color:#14532d;box-shadow:0 0 0 4px rgba(21,128,61,.2),0 2px 8px rgba(15,23,42,.35)}
.legend{flex-wrap:wrap;justify-content:flex-start;gap:6px 10px;padding-bottom:10px}
.legend span{font-size:9px}
.identity-warning:not([hidden]){display:block;margin-top:7px;padding:8px 9px;border:1px solid #f1c979;border-radius:6px;background:#fffbeb;color:#854d0e;font-size:10px;line-height:1.5}
.map-actions button{min-width:40px}
.drawer-toggle{display:none!important}
.map-tile-error:not([hidden]){z-index:320!important;pointer-events:none}
.map-tile-error button{pointer-events:auto}
@media(max-width:1100px){.map-actions{flex-wrap:wrap}}
@media(max-width:620px){
	.map-area{position:relative;display:block;height:min(82svh,780px);min-height:460px;overflow:hidden}
	.map-area #map{height:100%;min-height:0}
	.map-actions{top:65px;left:8px;right:8px;max-width:none;display:flex;flex-wrap:wrap;gap:5px}
	.map-actions button{min-height:42px;padding:7px 8px;font-size:10px}
	.map-tile-error:not([hidden]){top:auto;bottom:92px;left:8px;width:min(355px,calc(100% - 16px));z-index:420!important}
	.map-actions .drawer-toggle{display:inline-flex!important;align-items:center;justify-content:center;background:#1e40af;color:#fff;border-color:#1e40af}
	.insights{position:absolute;top:auto;left:8px;right:8px;bottom:8px;width:auto;height:76px;min-height:0;max-height:calc(100% - 110px);margin:0;border-radius:11px;transition:height .22s ease;z-index:450}
	.insights:not(.drawer-open)>:not(.insights-header){display:none}
	.insights.drawer-open{height:min(62svh,570px);min-height:400px;max-height:calc(100% - 110px)}
	.insights-header{min-height:68px;padding:9px 12px;flex-shrink:0}
	.insights-header h2{max-width:min(54vw,250px);font-size:14px}
	.report-icon{font-size:18px;padding:6px}
	.stats-grid{flex-shrink:0;padding:6px 9px;gap:5px}
	.stat-card{min-height:64px;padding:7px 8px;gap:3px}
	.stat-card strong{font-size:18px}
	.coverage-title{padding:3px 11px 6px}
	.coverage-bars{margin:0 11px}
	.legend{padding:7px 11px 9px;gap:5px 8px}
	.tracked-business{flex-shrink:0;padding:8px 11px}
	.results-tabs{position:sticky;top:0;z-index:4;flex-shrink:0;overflow-x:auto;scrollbar-width:thin;padding:3px 6px 0}
	.results-tabs button{min-height:42px;flex:0 0 auto;min-width:62px;padding:8px 7px}
	.tab-panel{min-height:0;max-height:none;flex:1;overscroll-behavior:contain}
	.results-footnote{flex-shrink:0}
	.explore-list{max-height:32svh;overflow:auto;overscroll-behavior:contain}
	.map-bottom-hint{display:none}
	.map-focus .sidebar{display:none!important}
	.map-focus .map-area{height:min(94svh,900px);min-height:500px}
	.map-focus .map-area #map{height:100%}
	.map-focus .insights{width:auto}
	.map-focus .map-top-right{right:8px}
	body.theme-dark .identity-warning:not([hidden]){background:#3a2a12;border-color:#78551f;color:#fde68a}
}
