:root {
  color-scheme: dark;
  --bg: #06121b;
  --panel: #0b202d;
  --panel-2: #102b3a;
  --line: rgba(255,255,255,.12);
  --text: #f4fbff;
  --muted: #9bb2c0;
  --accent: #59c7f0;
  --accent-2: #7ee2b8;
  --danger: #ff6b6b;
  --topbar-h: 64px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html, body { width: 100%; height: 100%; margin: 0; overflow: hidden; background: var(--bg); color: var(--text); }
button, input { font: inherit; }
button { color: inherit; }
.app-shell { width: 100%; height: 100%; display: grid; grid-template-rows: var(--topbar-h) minmax(0,1fr); background: var(--bg); }
.topbar { display:flex; align-items:center; justify-content:space-between; padding:0 16px; background:#071a26; border-bottom:1px solid var(--line); z-index:50; }
.brand { display:flex; gap:11px; align-items:center; min-width:0; }
.brand-icon { width:40px; height:40px; display:grid; place-items:center; border-radius:12px; background:rgba(89,199,240,.14); font-size:22px; }
.brand strong, .brand span { display:block; }
.brand strong { font-size:16px; }
.brand span { margin-top:2px; color:var(--muted); font-size:12px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:min(55vw,560px); }
.top-actions { display:flex; gap:8px; }
.button, .icon-button { border:1px solid var(--line); border-radius:9px; min-height:38px; padding:0 13px; cursor:pointer; background:var(--panel-2); }
.button:hover, .icon-button:hover { filter:brightness(1.12); }
.button.primary { border-color:transparent; background:var(--accent); color:#03202b; font-weight:700; }
.button.secondary { background:rgba(255,255,255,.06); }
.icon-button { min-width:38px; padding:0; }
.workspace { min-height:0; display:grid; grid-template-columns:290px minmax(0,1fr); position:relative; }
.sidebar { background:rgba(7,26,38,.98); border-right:1px solid var(--line); z-index:35; min-height:0; }
.sidebar-scroll { height:100%; overflow:auto; padding:16px; scrollbar-width:thin; }
.search-box > span { display:block; font-size:12px; color:var(--muted); text-transform:uppercase; letter-spacing:.06em; margin-bottom:7px; }
.search-control { display:flex; border:1px solid var(--line); background:#061722; border-radius:10px; overflow:hidden; }
.search-control:focus-within { border-color:var(--accent); box-shadow:0 0 0 2px rgba(89,199,240,.16); }
.search-control input { min-width:0; width:100%; border:0; outline:0; color:var(--text); background:transparent; padding:11px 12px; }
.search-control button { width:38px; border:0; background:transparent; cursor:pointer; color:var(--muted); font-size:20px; }
.search-results { margin-top:8px; border:1px solid var(--line); background:#071a26; border-radius:10px; overflow:hidden; max-height:260px; overflow-y:auto; }
.search-result { width:100%; display:flex; align-items:center; gap:9px; padding:9px 10px; border:0; border-bottom:1px solid rgba(255,255,255,.07); background:transparent; text-align:left; cursor:pointer; }
.search-result:last-child { border-bottom:0; }
.search-result:hover { background:rgba(89,199,240,.1); }
.search-result .result-icon { width:28px; height:28px; border-radius:50%; display:grid; place-items:center; background:var(--panel-2); flex:0 0 auto; }
.search-result strong, .search-result small { display:block; }
.search-result small { color:var(--muted); margin-top:2px; }
.panel-section { padding:17px 0; border-bottom:1px solid var(--line); }
.compact-section { padding:14px 0; }
.section-title { display:flex; align-items:center; justify-content:space-between; gap:8px; margin-bottom:10px; }
.section-title h2 { font-size:13px; text-transform:uppercase; letter-spacing:.05em; margin:0; }
.text-button { border:0; background:transparent; color:var(--accent); cursor:pointer; padding:2px 0; font-size:12px; }
.segmented { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:6px; }
.segmented button { min-height:36px; border:1px solid var(--line); background:rgba(255,255,255,.04); border-radius:8px; cursor:pointer; }
.segmented button.active { background:var(--accent); color:#03202b; border-color:transparent; font-weight:700; }
.filter-list { display:grid; gap:5px; }
.filter-row { display:flex; align-items:center; gap:10px; min-height:38px; padding:6px 8px; border-radius:8px; cursor:pointer; }
.filter-row:hover { background:rgba(255,255,255,.05); }
.filter-row input { accent-color:var(--accent); width:17px; height:17px; }
.filter-icon { width:26px; height:26px; border-radius:50%; display:grid; place-items:center; background:var(--marker-color); color:white; font-size:14px; flex:0 0 auto; }
.filter-label { flex:1; font-size:14px; }
.filter-count { color:var(--muted); font-size:12px; }
.switch-row { display:flex; align-items:center; justify-content:space-between; gap:12px; cursor:pointer; }
.switch-row strong, .switch-row small { display:block; }
.switch-row small { color:var(--muted); margin-top:3px; }
.switch-row input { width:38px; height:20px; accent-color:var(--accent); }
.coverage-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:6px; }
.coverage-card { background:rgba(255,255,255,.05); border:1px solid rgba(255,255,255,.07); border-radius:8px; padding:8px; }
.coverage-card strong { display:block; font-size:17px; }
.coverage-card small { color:var(--muted); }
.coverage p { color:var(--muted); line-height:1.45; font-size:12px; margin:10px 0 0; }
.map-viewport { position:relative; min-width:0; min-height:0; overflow:hidden; background:#07141c; touch-action:none; cursor:grab; }
.map-viewport.dragging { cursor:grabbing; }
.map-scene { position:absolute; width:8192px; height:8192px; left:0; top:0; transform-origin:0 0; will-change:transform; background:#0b2734; }
.map-scene > img { position:absolute; inset:0; width:8192px; height:8192px; object-fit:contain; user-select:none; pointer-events:none; }
.marker-layer { position:absolute; inset:0; }
.map-marker { position:absolute; width:34px; height:34px; border:2px solid rgba(255,255,255,.95); border-radius:50%; display:grid; place-items:center; background:var(--marker-color); color:#fff; cursor:pointer; transform:translate(-50%,-50%) scale(var(--inv-zoom,1)); transform-origin:center; box-shadow:0 3px 9px rgba(0,0,0,.5); user-select:none; }
.map-marker:hover, .map-marker.active { z-index:20; box-shadow:0 0 0 5px rgba(255,255,255,.22),0 5px 14px rgba(0,0,0,.65); }
.map-marker img { width:100%; height:100%; border-radius:50%; object-fit:cover; background:#132f3d; }
.map-marker .glyph { font-size:17px; line-height:1; }
.map-marker.found { opacity:.38; filter:grayscale(.65); }
.map-marker.cluster { width:42px; height:42px; font-weight:800; background:#123d52; }
.map-marker.cluster span { font-size:12px; }
.map-controls { position:absolute; left:50%; bottom:16px; transform:translateX(-50%); z-index:25; display:flex; align-items:center; overflow:hidden; border:1px solid var(--line); background:rgba(5,20,29,.9); border-radius:12px; backdrop-filter:blur(8px); }
.map-controls button { width:42px; height:40px; border:0; background:transparent; cursor:pointer; font-size:22px; }
.map-controls button:hover { background:rgba(255,255,255,.08); }
.map-controls span { min-width:62px; text-align:center; font-size:12px; color:var(--muted); }
.coordinate-readout, .result-count { position:absolute; bottom:17px; z-index:24; background:rgba(5,20,29,.88); border:1px solid var(--line); border-radius:9px; padding:8px 10px; font-size:12px; color:var(--muted); backdrop-filter:blur(8px); pointer-events:none; }
.coordinate-readout { right:16px; }
.result-count { left:16px; }
.loading-overlay { position:absolute; inset:0; z-index:60; background:#07141c; display:flex; flex-direction:column; align-items:center; justify-content:center; gap:14px; }
.loading-overlay.hidden { opacity:0; pointer-events:none; transition:opacity .25s; }
.spinner { width:34px; height:34px; border-radius:50%; border:3px solid rgba(255,255,255,.15); border-top-color:var(--accent); animation:spin .8s linear infinite; }
@keyframes spin { to { transform:rotate(360deg); } }
.details { position:absolute; right:14px; top:14px; bottom:14px; width:min(340px,calc(100% - 28px)); z-index:40; background:rgba(7,26,38,.96); border:1px solid var(--line); border-radius:14px; padding:18px; overflow:auto; backdrop-filter:blur(10px); box-shadow:0 12px 36px rgba(0,0,0,.36); }
.close-details { position:absolute; top:8px; right:8px; width:34px; height:34px; border:0; border-radius:8px; background:rgba(255,255,255,.06); cursor:pointer; font-size:20px; }
.detail-image-wrap { height:170px; display:grid; place-items:center; margin:8px 0 14px; }
.detail-image-wrap img { max-width:100%; max-height:100%; object-fit:contain; }
.type-badge { display:inline-flex; padding:5px 8px; border-radius:999px; background:rgba(89,199,240,.16); color:var(--accent); font-size:12px; font-weight:700; }
.details h2 { margin:9px 32px 3px 0; font-size:22px; }
.detail-subtitle { margin:0 0 16px; color:var(--muted); }
.detail-list { margin:0; display:grid; gap:1px; border-top:1px solid var(--line); border-bottom:1px solid var(--line); padding:8px 0; }
.detail-list > div { display:flex; justify-content:space-between; gap:15px; padding:7px 0; }
.detail-list dt { color:var(--muted); }
.detail-list dd { margin:0; text-align:right; font-weight:600; }
.detail-description { line-height:1.55; color:#d9e8ef; }
.detail-actions { display:grid; gap:8px; margin-top:16px; }
.toast { position:fixed; left:50%; bottom:24px; transform:translate(-50%,18px); z-index:100; max-width:min(90vw,520px); padding:10px 14px; background:#071a26; border:1px solid var(--line); border-radius:10px; opacity:0; pointer-events:none; transition:.2s; }
.toast.show { opacity:1; transform:translate(-50%,0); }
.mobile-only { display:none; }
@media (max-width: 900px) {
  .mobile-only { display:inline-grid; place-items:center; }
  .workspace { grid-template-columns:minmax(0,1fr); }
  .sidebar { position:absolute; left:0; top:0; bottom:0; width:min(310px,86vw); transform:translateX(-102%); transition:transform .2s; box-shadow:12px 0 28px rgba(0,0,0,.35); }
  .sidebar.open { transform:translateX(0); }
  .details { top:10px; right:10px; bottom:10px; }
  .result-count { display:none; }
  .coordinate-readout { right:10px; bottom:68px; }
}
@media (max-width: 560px) {
  :root { --topbar-h:56px; }
  .topbar { padding:0 10px; }
  .brand-icon { width:36px; height:36px; }
  .top-actions .button { display:none; }
  .details { width:calc(100% - 16px); right:8px; top:auto; bottom:8px; max-height:68%; }
  .map-controls { bottom:10px; }
  .coordinate-readout { bottom:60px; }
}
