:root{color-scheme:dark;--bg:#071511;--panel:#0b1b18;--panel2:#10231e;--line:#243b32;--text:#edf4e9;--muted:#9aaea3;--green:#a5e976;--blue:#7ad7ee;--violet:#c3b0ff;--red:#ff786f;--amber:#ffcb6c;--shadow:0 14px 40px #0006;font-family:Inter,"Segoe UI",system-ui,-apple-system,sans-serif}
*{box-sizing:border-box}
body{margin:0;background:radial-gradient(ellipse at 15% 0,#183227 0,transparent 40%),var(--bg);color:var(--text);font-size:14px}
button,input{font:inherit}
button,a,input{-webkit-tap-highlight-color:transparent}
button{cursor:pointer;color:inherit}
a{color:var(--green)}
button{border:0;background:transparent}
button:disabled{opacity:.4;cursor:not-allowed}
button:focus-visible,a:focus-visible,input:focus-visible,[tabindex]:focus-visible{outline:2px solid var(--green);outline-offset:4px}
svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}
.paw{fill:currentColor;stroke:none}
.svg-defs{position:absolute;width:0;height:0;overflow:hidden}
.topbar{min-height:82px;padding:15px 25px;display:flex;align-items:center;gap:24px;border-bottom:1px solid var(--line);background:#061714e8}
.brand{display:flex;gap:12px;align-items:center;text-decoration:none;white-space:nowrap;color:var(--text)}
.brand>.paw{width:39px;height:42px;color:var(--green);filter:drop-shadow(0 0 10px #a5e97626)}
.brand strong{font-size:30px;letter-spacing:-1.1px;line-height:1;display:block;font-weight:850}
.brand strong span{color:var(--green)}
.brand small{font-size:10px;letter-spacing:.04em;color:var(--muted);display:block;margin-top:6px}
.topbar nav{display:flex;align-items:center;gap:7px}
.nav-btn{display:flex;align-items:center;gap:8px;padding:12px 15px;white-space:nowrap;border-radius:7px;font-size:12px;color:#b7c9bf;border:1px solid transparent}
.nav-btn.active{background:#a5e9760c;border-color:#a5e97661;color:var(--green)}
.nav-btn:hover{background:#ffffff08}
.search{display:flex;align-items:center;gap:9px;border:1px solid var(--line);background:#081915;border-radius:7px;padding:10px 12px;flex:1;margin-left:auto;max-width:290px;color:var(--muted)}
.search input{background:none;border:0;outline:0;min-width:0;width:100%;color:var(--text);font-size:12px}
.search input::placeholder{color:#849b8e}
.search svg{width:17px;height:17px}
kbd{font:11px monospace;padding:1px 5px;border:1px solid var(--line);border-radius:3px}
.connection{display:flex;align-items:center;gap:10px;white-space:nowrap}
.connection b{font-size:12px;color:var(--green);font-weight:600}
.connection small{display:block;font-size:10px;color:var(--muted);margin-top:5px}
.status-dot{display:inline-block;width:7px;height:7px;border-radius:50%;background:var(--green);box-shadow:0 0 10px #a5e97650;flex-shrink:0}
.status-dot.offline{background:var(--red);box-shadow:none}
.icon-button{width:34px;height:34px;border:1px solid var(--line);border-radius:7px;display:inline-flex;align-items:center;justify-content:center;color:var(--muted);font-weight:700;flex-shrink:0}
.icon-button:hover{color:var(--text);border-color:#567058}
.green{color:var(--green)}
.blue{color:var(--blue)}
.violet{color:var(--violet)}
.red{color:var(--red)!important}
.amber{color:var(--amber)!important}
.amber-bg{background:var(--amber);box-shadow:0 0 9px #ffcb6c50}
.metrics{display:flex;align-items:center;padding:18px 26px;gap:24px;border-bottom:1px solid var(--line);background:#091d17a0}
.metric{display:flex;align-items:center;gap:14px;flex:1;padding-right:18px;border-right:1px solid var(--line);min-width:0}
.metric-icon{width:26px;height:26px;stroke-width:1.8}
.metric div>span{display:block;font-size:10px;color:var(--muted);margin-bottom:3px}
.metric strong{font-size:27px;font-variant-numeric:tabular-nums;letter-spacing:-.6px;line-height:1.2}
.mini-bars{display:flex;align-items:flex-end;gap:3px;height:25px;margin-left:auto}
.mini-bars i{width:3px;background:var(--green);opacity:.5;height:40%}
.mini-bars i:nth-child(2n){height:70%;opacity:.7}
.mini-bars i:nth-child(3n){height:100%;opacity:.9}
.clock{white-space:nowrap}
.clock small{display:block;color:var(--muted);font-size:10px}
.clock time{font-size:24px;font-variant-numeric:tabular-nums;letter-spacing:1px}
.workspace{display:grid;grid-template-columns:minmax(0,1fr) 305px;gap:15px;padding:15px 20px 0;max-width:2160px;margin:0 auto}
.map-column{min-width:0}
.map-toolbar{display:flex;align-items:center;justify-content:space-between;padding:1px 0 13px;gap:10px}
.map-toolbar>div{display:flex;align-items:center;gap:9px}
h1{font-size:13px;margin:0;font-weight:550}
.mode-badge{font:9px/1.3 ui-monospace,monospace;border:1px solid #7796644d;color:var(--green);letter-spacing:.08em;padding:3px 6px;border-radius:4px}
.map-actions button{color:var(--muted);font-size:11px;padding:7px 8px;border-radius:5px}
.map-actions button:hover{background:#ffffff09;color:var(--text)}
.map-actions .icon-button{height:27px;width:29px;padding:4px}
.map-actions [aria-pressed=true]{color:var(--green)}
.map-viewport{position:relative;aspect-ratio:1672/941;overflow:hidden;isolation:isolate;background:#163324;border:1px solid #496b43;border-radius:10px;box-shadow:var(--shadow);touch-action:pan-y}
.map-scene{position:absolute;inset:0;transform-origin:50% 50%;will-change:transform}
.map-art{display:block;width:100%;height:100%;pointer-events:none;user-select:none}
.route-layer,.bot-layer,.habitats{position:absolute;inset:0;width:100%;height:100%}
.route-layer{pointer-events:none;transition:opacity .25s}
.route-layer.hide-routes{opacity:0}
.route-line{fill:none;stroke-width:3;stroke-linecap:round;stroke-dasharray:5 12;opacity:.8;filter:drop-shadow(0 1px 2px #102917);animation:flow 22s linear infinite}
.route-line.perimeter{stroke-width:4}
.route-line.route-dim{opacity:.12}
.bot-layer,.habitats{pointer-events:none}
.habitats{z-index:1200}
.habitat{position:absolute;pointer-events:auto;transform:translate(-50%,-50%);display:flex;align-items:center;gap:6px;max-width:170px;padding:5px 9px;font-size:11px;line-height:1.3;border:1px solid #d6edc56e;border-radius:20px;background:#092119e8;color:var(--text);box-shadow:0 3px 10px #0008;transition:border-color .2s,opacity .2s;backdrop-filter:blur(7px);white-space:nowrap}
.habitat b{color:var(--green)}
.habitat:hover{border-color:var(--green);z-index:5}
.habitat.selected{outline:2px solid var(--green)}
.habitat .hab-dot{width:6px;height:6px;border-radius:50%;background:var(--hab-color)}
.bot-marker{width:32px;height:32px;position:absolute;left:0;top:0;transform:translate(-50%,-90%);pointer-events:auto;display:grid;place-items:center;border-radius:10px;background:#fffffff2;border:2px solid var(--agent-color,var(--green));box-shadow:0 0 0 3px #081a1740,0 4px 10px #0007;color:#14271c;font-size:12px;font-weight:850;padding:5px;transition:opacity .2s;will-change:left,top}
.bot-marker:after{content:"";position:absolute;bottom:-5px;left:12px;width:6px;height:6px;background:var(--agent-color,var(--green));transform:rotate(45deg)}
.bot-marker img{height:100%;width:100%;object-fit:contain;pointer-events:none}
.bot-marker svg{width:20px;height:20px;pointer-events:none;stroke-width:2}
.bot-marker:hover,.bot-marker.focused{z-index:3000!important;box-shadow:0 0 0 4px #fff9,0 5px 14px #000a}
.bot-marker.external{border-radius:7px;background:#241c11;color:var(--amber)}
.bot-marker.external::after{background:var(--amber)}
.bot-marker.in-trap{background:#331916;color:#ffb1a9}
.bot-marker.resident{transform-origin:50% 90%;transform:translate(-50%,-90%) scale(.82)}
.bot-marker.idle{opacity:.62;filter:saturate(.55)}
.bot-marker.ping::before{content:"";position:absolute;inset:-7px;border-radius:14px;border:2px solid var(--agent-color,var(--green));animation:marker-ping 1.6s ease-out 2;pointer-events:none}
@keyframes marker-ping{from{transform:scale(.8);opacity:.95}to{transform:scale(1.7);opacity:0}}
.bot-marker.visitor{pointer-events:none;border-radius:50%;background:#e4f1ff;border-color:#8fc3ff;--agent-color:#8fc3ff;color:#16324f;transition:opacity .2s}
.bot-marker.visitor.me{background:#fff4c2;border-color:#ffd23f;--agent-color:#ffd23f;color:#3d2e00;box-shadow:0 0 0 4px #ffd23f55,0 4px 12px #000a}
.bot-marker .visitor-label{position:absolute;left:50%;top:calc(100% + 7px);transform:translateX(-50%);padding:0 6px;border-radius:7px;background:#ffd23f;color:#2b2000;font-size:10px;line-height:15px;font-weight:850;white-space:nowrap;box-shadow:0 2px 6px #0008}
.bot-marker.fade{opacity:.15}
@media (prefers-reduced-motion:reduce){.bot-marker.ping::before{animation:none;opacity:0}}
.perimeter-label{position:absolute;bottom:.6%;left:21.5%;display:grid;grid-template-columns:8px auto;gap:2px 7px;align-items:center;padding:7px 10px;border:1px solid #ffcb6c65;border-radius:5px;background:#211c10ef;box-shadow:0 3px 12px #0008;color:var(--amber);pointer-events:none}
.perimeter-label b{font-size:10px;letter-spacing:.1em}
.perimeter-label small{font-size:8px;grid-column:2;color:#dbc99f}
.zoom-controls{position:absolute;bottom:14px;right:14px;display:flex;align-items:center;background:#061914ef;border:1px solid #6989606e;border-radius:7px;padding:3px;box-shadow:var(--shadow)}
.zoom-controls button{font-size:20px;height:29px;min-width:30px;border-radius:4px}
.zoom-controls button:hover{background:#a5e97619}
.zoom-controls #zoom-reset{font:11px ui-monospace,monospace;min-width:48px}
.legend{display:flex;align-items:center;flex-wrap:wrap;gap:5px;padding:13px 0 9px}
.legend button{display:flex;align-items:center;gap:7px;font-size:10px;color:var(--muted);border:1px solid transparent;border-radius:5px;padding:6px 8px}
.legend button:hover{background:#ffffff05}
.legend button.active{background:#a5e9760b;color:var(--text);border-color:#a5e97644}
.legend .swatch{display:block;width:16px;height:0;border-top:2px dashed var(--swatch-color)}
.map-footnote{display:flex;justify-content:space-between;gap:15px;color:#789080;font-size:10px;padding:0 2px 14px;line-height:1.5}
.sidebar{display:flex;flex-direction:column;gap:12px;min-width:0}
.journal-panel,.threat-panel,.analytics{background:linear-gradient(135deg,#11251eaf,#0a1914f5);border:1px solid var(--line);border-radius:9px;padding:15px}
.section-heading{display:flex;align-items:center;justify-content:space-between;gap:8px}
.section-heading h2{font-size:14px;letter-spacing:-.15px;margin:0;font-weight:650;display:flex;align-items:center;gap:7px}
.section-heading h2 svg{width:18px;height:18px}
.section-heading>span{font-size:10px;color:var(--muted)}
.journal-live{display:flex;gap:6px;align-items:center;font-size:9px!important;white-space:nowrap}
.journal-live .status-dot{width:5px;height:5px}
.journal-hint{font-size:9px;color:#829b8c;margin:7px 0 10px}
.feed{height:260px;overflow:auto;scrollbar-width:thin;scrollbar-color:#2c4a36 transparent}
.feed-event{display:flex;width:100%;gap:10px;align-items:center;text-align:left;padding:10px 0;border-top:1px solid #ffffff08;position:relative}
.feed-event:hover{background:#a5e97606}
.brand-badge{width:29px;height:29px;display:grid;place-items:center;background:#f3f4e8;border-radius:9px;flex-shrink:0;color:#163426;padding:5px;font-size:10px;font-weight:800}
.brand-badge img{width:100%;height:100%;object-fit:contain}
.brand-badge svg{width:18px;height:18px}
.feed-event.external .brand-badge{background:#ffcb6c12;color:var(--amber)}
.feed-event.trap .brand-badge{background:#ff786f13;color:var(--red)}
.event-copy{flex:1;min-width:0}
.event-copy b{font-size:11px;font-weight:600;display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.event-copy small{display:block;font-size:9px;color:#9ab09f;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:4px}
.feed-event time{font:9px ui-monospace,monospace;color:#799183;align-self:flex-start;padding-top:3px}
.text-button{font-size:10px;color:#a3b7a9;white-space:nowrap;padding:0}
.text-button:hover{color:var(--green)}
.threat-metrics{display:flex;justify-content:space-between;align-items:center;margin-top:12px}
.threat-metrics strong{font-size:33px;line-height:1;font-weight:650;letter-spacing:-1px}
.threat-metrics small{display:block;font-size:9px;margin-top:4px;color:var(--muted)}
.trap-depth{text-align:right}
.trap-depth>span{font:26px ui-monospace,monospace;color:var(--red)}
.depth-track{display:flex;gap:3px;align-items:flex-end;height:23px;margin-top:13px}
.depth-track i{height:9px;flex:1;background:#ff786f1c;border-radius:1px}
.depth-track i.lit{background:#f87962}
.threat-panel p{font-size:9px;color:#8da795;line-height:1.6;margin:10px 0 0}
.outside-stats{display:flex;gap:10px;margin:12px 0 9px}
.outside-stats>div{flex:1}
.outside-stats strong{display:block;font-size:24px;line-height:1;color:var(--amber);font-weight:600}
.outside-stats small{display:block;font-size:9px;color:var(--muted);line-height:1.4;margin-top:5px}
.path-row{display:flex;justify-content:space-between;gap:8px;font-size:10px;padding:5px 0}
.path-row code{white-space:nowrap;text-overflow:ellipsis;overflow:hidden;color:#c0cdbf}
.path-row b{color:var(--amber);font-weight:500}
.empty-message{padding:20px 7px;color:#99af9e;font-size:12px;line-height:1.6}
.map-empty{position:absolute;top:42%;left:50%;transform:translate(-50%,-50%);width:min(80%,420px);background:#061811ef;backdrop-filter:blur(10px);border:1px solid #81a86d;border-radius:10px;padding:24px;text-align:center;font-size:18px;box-shadow:var(--shadow)}
.map-empty small{font-size:12px;display:block;color:var(--muted);line-height:1.6;margin-top:10px}
.map-empty a{font-size:12px;display:inline-block;margin-top:15px}
.analytics{margin-top:10px}
.analytics .muted{font-size:11px;line-height:1.6}
.hour-chart{display:flex;align-items:flex-end;gap:6px;height:120px;margin:22px 0 15px;border-bottom:1px solid var(--line)}
.hour-bar{flex:1;background:linear-gradient(0deg,#447b42,var(--green));border-radius:3px 3px 0 0;min-height:2px;opacity:.85}
.hour-bar:hover{opacity:1}
.population{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
.population>div{padding:10px;background:#07150f;border:1px solid var(--line);border-radius:5px;font-size:11px}
.population b{display:block;font-size:20px;margin-top:5px;color:var(--green)}
.muted{color:var(--muted)}
footer{padding:16px 24px;display:flex;align-items:center;justify-content:space-between;gap:20px;color:#789683;font-size:10px;border-top:1px solid #20382a;margin-top:12px}
footer>span{display:flex;align-items:center;gap:10px}
footer b{color:#a8bda7;font-size:12px}
footer svg{width:17px;height:17px}
.honeypot,.skip-link{position:absolute;left:-10000px;top:0;width:1px;height:1px;overflow:hidden}
.skip-link:focus{left:10px;top:10px;width:auto;height:auto;background:var(--bg);padding:10px;z-index:100}
.notice{position:fixed;left:50%;bottom:25px;transform:translateX(-50%);padding:12px 18px;border:1px solid var(--line);background:#152b20;border-radius:7px;z-index:80;max-width:90vw;font-size:12px;box-shadow:var(--shadow);opacity:0;pointer-events:none;transition:opacity .2s}
.notice.show{opacity:1}
dialog{background:#0e2319;border:1px solid #506c43;border-radius:14px;color:var(--text);padding:23px;max-width:520px;width:calc(100% - 32px);box-shadow:0 25px 100px #000b}
dialog::backdrop{background:#00100cc2;backdrop-filter:blur(5px)}
.dialog-top{display:flex;justify-content:space-between;align-items:center}
.eyebrow{color:var(--green);letter-spacing:.15em;font-size:10px}
.dialog-top button{border:0}
dialog h2{font-size:23px;margin:14px 0}
dialog p{font-size:13px;color:#bdcfbd;line-height:1.65}
dialog dl{display:grid;grid-template-columns:110px 1fr;gap:10px;font-size:12px}
dialog dt{color:var(--muted)}
dialog dd{margin:0;overflow-wrap:anywhere}
.noscript{padding:20px}
.paused .route-line{animation-play-state:paused}
.map-column:fullscreen{background:var(--bg);padding:15px;display:flex;flex-direction:column;justify-content:center;overflow:auto}
.map-column:fullscreen .map-viewport{width:min(100%,calc((100vh - 115px)*1.776));margin:0 auto}
.journal-focus .journal-panel{border-color:#84a565}
.journal-focus .feed{height:450px}
.map-viewport.zoomed{cursor:grab;touch-action:none}
.map-viewport.dragging{cursor:grabbing}
#notice:empty{display:none}
[hidden]{display:none!important}
@keyframes flow{to{stroke-dashoffset:-340}
}
.orange{color:#ff9e73!important}
.map-tagline{font-size:10px;color:var(--muted);margin-left:6px}
.bot-marker .marker-flag{position:absolute;left:50%;top:-14px;transform:translateX(-50%);width:20px;height:15px;object-fit:cover;border-radius:2px;box-shadow:0 0 0 1px #0006,0 2px 5px #0009;pointer-events:none;background:#fff}
.bot-marker .marker-flag.flag-ru{width:28px;height:28px;top:-27px;border-radius:50%;box-shadow:0 0 0 2px #fff,0 2px 6px #000a}
.flag{display:inline-block;width:16px;height:12px;object-fit:cover;border-radius:2px;vertical-align:-1px;margin-right:6px;box-shadow:0 0 0 1px #0006;background:#fff}
.flag.flag-ru{width:18px;height:18px;border-radius:50%;vertical-align:-4px}
.explainer{margin:0 0 12px;border:1px solid var(--line);border-radius:8px;background:#0b1b18c0}
.explainer summary{cursor:pointer;padding:10px 14px;font-size:12px;font-weight:650;color:var(--green)}
.explainer-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px 22px;padding:0 14px 12px}
.explainer dl{margin:0}
.explainer dt{font-size:11px;font-weight:650;color:var(--text);margin-top:8px}
.explainer dd{margin:2px 0 0;font-size:10px;line-height:1.5;color:var(--muted)}
.countries-heading{margin-top:18px}
.countries .flag{margin-right:8px}
footer .attribution a{color:inherit}
@media(min-width:1700px){body{font-size:15px}
.workspace{grid-template-columns:minmax(0,1fr) 335px}
.feed{height:330px}
.brand small{font-size:11px}
.nav-btn{font-size:13px}
.habitat{font-size:12px}
.bot-marker{width:36px;height:36px}
.feed-event{padding:12px 0}
.event-copy b{font-size:12px}
.event-copy small{font-size:10px}
.threat-panel p{font-size:10px}
}
@media(max-width:1250px){.topbar{gap:15px;padding:13px 20px}
.brand strong{font-size:26px}
.brand small{font-size:9px}
.brand>.paw{width:30px}
.nav-btn{padding:10px;font-size:11px}
.nav-btn svg{display:none}
.connection small{display:none}
.connection b{font-size:10px}
.search{max-width:200px}
.topbar>.icon-button{display:none}
.workspace{grid-template-columns:minmax(0,1fr) 270px;gap:12px;padding:12px 15px 0}
.metrics{gap:15px;padding:14px 20px}
.metric{gap:9px;padding-right:12px}
.metric strong{font-size:24px}
.mini-bars{display:none}
.metric-icon{width:22px}
.metric div>span{font-size:9px}
.clock{display:none}
.feed{height:210px}
.journal-panel,.threat-panel{padding:12px}
.habitat{font-size:9px;padding:4px 6px;gap:4px}
.bot-marker{width:28px;height:28px;padding:4px}
.bot-marker:after{left:9px}
.perimeter-label{padding:5px 7px}
.perimeter-label small{display:none}
.perimeter-label b{font-size:8px}
.map-footnote{font-size:9px}
.legend button{font-size:9px;padding:5px}
.legend{gap:3px}
.sidebar .section-heading h2{font-size:12px}
.threat-metrics strong{font-size:27px}
footer .footer-slogan{display:none}
}
@media(max-width:980px){.topbar{flex-wrap:wrap;gap:10px 20px}
.topbar nav{order:4;width:100%;justify-content:center}
.search{max-width:none;min-width:120px}
.connection{margin-left:auto}
.workspace{grid-template-columns:1fr}
.sidebar{display:grid;grid-template-columns:1.25fr 1fr 1fr;gap:10px}
.feed{height:210px}
.metrics{gap:8px}
.metric{padding-right:6px}
.metric-icon{display:none}
.metric strong{font-size:22px}
.map-footnote{padding-bottom:5px}
.bot-marker{width:31px;height:31px}
.habitat{font-size:10px}
.perimeter-label b{font-size:9px}
.zoom-controls{bottom:8px;right:8px}
.sidebar .section-heading{flex-wrap:wrap}
.map-toolbar{padding-top:4px}
.outside-stats{flex-direction:column}
.journal-focus .feed{height:400px}
}
@media(max-width:620px){.topbar{padding:14px 14px 8px;gap:14px}
.brand strong{font-size:26px}
.brand small{font-size:8px}
.brand>.paw{width:31px}
.search{order:3;width:100%;flex:auto;padding:10px}
.connection{max-width:118px;white-space:normal}
.connection b{font-size:10px;line-height:1.4}
.topbar nav{order:4;gap:0;justify-content:space-between}
.nav-btn{font-size:11px;padding:9px 10px}
.metrics{display:grid;grid-template-columns:repeat(3,1fr);padding:13px 14px;gap:13px 9px}
.metric{border:0}
.metric strong{font-size:25px}
.metric div>span{font-size:8px}
.metric:nth-child(n+4){grid-column:auto}
.workspace{padding:12px 10px 0;gap:12px}
.map-toolbar{flex-wrap:wrap}
.map-toolbar>div{gap:6px}
.map-toolbar h1{font-size:12px}
.map-actions{margin-left:auto}
.map-actions button{font-size:10px;padding:6px}
.map-viewport{aspect-ratio:1.14}
.map-scene{width:150%;height:auto;aspect-ratio:1672/941;top:50%;left:50%;margin-left:-75%;margin-top:0;translate:0 -50%}
.map-art{height:auto}
.zoom-controls button{min-width:27px;height:26px}
.zoom-controls #zoom-reset{min-width:40px}
.bot-marker{width:25px;height:25px;padding:3px;border-width:1px}
.bot-marker svg{width:17px;height:17px}
.bot-marker:after{left:9px;width:4px;height:4px;bottom:-3px}
.habitat{font-size:8px;padding:3px 5px}
.habitat .hab-dot{display:none}
.perimeter-label{display:none}
.legend{gap:2px;padding:9px 0}
.legend button{font-size:9px}
.map-footnote{display:block;font-size:9px}
.map-footnote>span{display:block;margin-bottom:4px}
.sidebar{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.journal-panel{grid-column:span 2}
.feed{height:230px}
.outside-stats{flex-direction:row}
.outside-stats small{font-size:8px}
.outside-stats strong{font-size:22px}
.sidebar .section-heading h2{font-size:12px}
.threat-panel .text-button{font-size:9px}
.threat-panel p{font-size:9px}
.event-copy b{font-size:12px}
.event-copy small{font-size:10px}
.feed-event{padding:10px 2px}
.journal-hint{font-size:10px}
.feed-event time{font-size:10px}
.section-heading h2{font-size:14px!important}
.map-empty{font-size:14px;padding:14px}
.map-empty small,.map-empty a{font-size:10px}
.population{grid-template-columns:1fr 1fr}
.analytics .section-heading{display:block}
.analytics .section-heading>span{display:block;margin-top:8px}
footer{padding:14px 12px;margin-top:15px;gap:12px;flex-wrap:wrap;font-size:9px}
footer>span span{font-size:9px}
footer .text-button{font-size:9px}
.map-column:fullscreen .map-scene{width:100%;margin:0;left:0;top:0;translate:none}
.map-column:fullscreen .map-viewport{aspect-ratio:1672/941}
.map-column:fullscreen .map-actions{margin-left:0}
}
@media(prefers-reduced-motion:reduce){*,*:before,*:after{animation:none!important;transition:none!important;scroll-behavior:auto!important}
}
@media(max-width:1250px){.map-tagline{display:none}
.explainer-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:620px){.explainer-grid{grid-template-columns:1fr}
.bot-marker .marker-flag{width:16px;height:12px;top:-11px}
.bot-marker .marker-flag.flag-ru{width:22px;height:22px;top:-21px}
}

/* Sidebar wrapper only matters in the fit-to-window layout. */
.sidebar-body{display:contents}

/* Legend dialog */
dialog.guide{max-width:900px}
.guide h2{margin-bottom:4px}
.guide .explainer-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:4px 26px;padding:0}
.guide dl{display:block;margin:0}
.guide dt{font-size:12px;font-weight:650;color:var(--text);margin-top:12px}
.guide dd{margin:3px 0 0;font-size:11px;line-height:1.55;color:var(--muted)}
@media(max-width:820px){.guide .explainer-grid{grid-template-columns:1fr 1fr}}
@media(max-width:560px){.guide .explainer-grid{grid-template-columns:1fr}}

/* Desktop: the whole dashboard fits the browser window, no page scroll.
   Body becomes a grid: the map column spans the full height between header and footer,
   metrics sit above the sidebar, and the sidebar takes whatever width the map leaves. */
@media(min-width:981px) and (min-height:560px){
  body{height:100vh;height:100dvh;overflow:hidden;display:grid;column-gap:14px;
    grid-template-rows:auto auto minmax(0,1fr) auto;
    grid-template-columns:minmax(0,1fr) clamp(350px,calc(100vw - 34px - var(--stage-h,620px)*1672/941),560px)}
  .topbar{grid-column:1/-1;grid-row:1;min-height:0;padding-top:8px;padding-bottom:8px}
  .workspace{display:contents}
  footer{grid-column:1/-1;grid-row:4;margin-top:0;padding:6px 20px}
  footer .map-footnote{display:flex;gap:18px;padding:0;font-size:10px;min-width:0}
  footer .map-footnote>span{white-space:nowrap}
  .metrics{grid-column:2;grid-row:2;display:grid;grid-template-columns:repeat(auto-fit,minmax(148px,1fr));gap:8px;padding:10px 20px 0 0;border:0;background:none}
  .metric{container-type:inline-size;border:1px solid var(--line);border-radius:8px;padding:7px 10px;gap:9px;background:linear-gradient(135deg,#11251eaf,#0a1914f5)}
  .metric>div{min-width:0}
  .metric div>span{font-size:9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .metric strong{font-size:21px}
  .metric-icon{width:19px;height:19px}
  .mini-bars,.clock{display:none}
  .map-column{grid-column:1;grid-row:2/4;display:flex;flex-direction:column;min-height:0;padding:8px 0 8px 20px;container-type:inline-size}
  .map-toolbar,.legend{flex:none}
  .map-toolbar{padding:0 0 6px;flex-wrap:nowrap;min-width:0}
  .map-toolbar>div{min-width:0}
  .map-toolbar h1,.mode-badge,.map-actions button{white-space:nowrap}
  .map-actions{flex:none}
  .map-tagline{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  @container (max-width:980px){.map-tagline{display:none}.legend button{padding:4px 5px}}
  .legend{padding:6px 0 0}
  .map-stage{flex:1;min-height:0;container-type:size;display:grid;place-items:center}
  .map-viewport,.map-column:fullscreen .map-viewport{width:min(100cqw,calc(100cqh*1672/941));margin:0}
  .sidebar{grid-column:2;grid-row:3;display:block;min-height:0;overflow-y:auto;padding:10px 20px 8px 0;container-type:inline-size;scrollbar-width:thin;scrollbar-color:#2c4a36 transparent}
  .sidebar-body{display:flex;flex-direction:column;gap:10px;height:100%;min-height:min-content}
  .journal-panel{flex:1 0 200px;display:flex;flex-direction:column;min-height:200px}
  .feed,.journal-focus .feed{flex:1;height:auto;min-height:90px}
  .threat-panel{flex:none}
  .journal-focus .threat-panel{display:none}
  .stats-focus .map-stage,.stats-focus .legend,.stats-focus .map-tagline{display:none}
  .stats-focus .population{grid-template-columns:repeat(auto-fill,minmax(125px,1fr));gap:8px}
  .stats-focus .population>div{padding:8px 10px}
  .stats-focus .population b{font-size:18px;margin-top:3px}
  .stats-focus .hour-chart{height:clamp(60px,14vh,120px);margin:14px 0 12px}
  .stats-focus .countries-heading{margin:14px 0 8px}
  .stats-focus .analytics{flex:1;min-height:0;overflow-y:auto;margin-top:0}
  /* Tile or sidebar at its narrowest: drop decoration before text gets cut. */
  @container (max-width:135px){.metric-icon{display:none}.metric strong{font-size:18px}.metric div>span{margin-bottom:1px}}
  @container (max-width:399px){
    .trap-panel p,.depth-track{display:none}
    .path-row:nth-child(n+4){display:none}
    .journal-panel{flex-basis:150px;min-height:150px}
    .sidebar-body{gap:8px}
  }
  @container (min-width:400px){
    .sidebar-body{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);grid-template-rows:minmax(200px,1fr) auto}
    .journal-panel{grid-column:span 2;min-height:0}
    .journal-focus .journal-panel{grid-row:span 2}
  }
}
@media(min-width:981px) and (min-height:560px) and (max-height:760px){
  .topbar{padding-top:5px;padding-bottom:5px}
  .brand strong{font-size:24px}.brand small{display:none}.brand>.paw{width:30px;height:32px}
  .nav-btn{padding-top:8px;padding-bottom:8px}.search{padding-top:7px;padding-bottom:7px}
  .metrics{padding-top:8px;gap:6px}
  .metric{padding:5px 9px}
  .metric strong{font-size:18px}.metric-icon{width:17px;height:17px}
  footer{padding-top:4px;padding-bottom:4px}
  .sidebar{padding-top:8px}
  .journal-hint{display:none}
  .journal-panel,.threat-panel{padding:10px 12px}
  .threat-metrics{margin-top:8px}.threat-metrics strong{font-size:26px}.trap-depth>span{font-size:22px}
  .outside-stats{margin:8px 0 5px}.outside-stats strong{font-size:21px}
  .path-row{padding:3px 0}.path-row:nth-child(n+4){display:none}
  .threat-panel p{margin-top:7px}
  .depth-track{margin-top:8px}
}

/* Zoom buttons: top-right column keeps the bottom-right "trap" chip readable on small maps. */
@media(min-width:981px){
  .zoom-controls,.map-column .zoom-controls{top:10px;right:10px;bottom:auto;flex-direction:column;padding:2px}
  .zoom-controls button{width:100%}
}

/* Map notes live in the footer. */
.map-footnote{min-width:0}
footer .map-footnote{display:flex;gap:16px;flex-wrap:wrap;color:#789080;padding:0;justify-content:center}
