:root {
  --bg:        #eef2f8;
  --bg-2:      #f5f7fb;
  --panel:     #ffffff;
  --panel-2:   #f8fafc;
  --line:      #e2e7f0;
  --line-2:    #edf0f6;
  --ink:       #1a2233;
  --ink-dim:   #4a5468;
  --ink-mute:  #7b859a;
  --primary:         #ff6600;
  --primary-600:     #e55a00;
  --primary-soft:    #fff2e8;
  --accent:    #2563eb;
  --green:     #16a34a;
  --yellow:    #d97706;
  --orange:    #ea580c;
  --red:       #dc2626;
  --green-soft:  #dcfce7;
  --yellow-soft: #fef3c7;
  --orange-soft: #ffedd5;
  --red-soft:    #fee2e2;
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.06);
  --shadow:    0 4px 14px rgba(16, 24, 40, 0.08);
  --shadow-lg: 0 10px 24px rgba(16, 24, 40, 0.1);
  --radius:    10px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  font-size: 14px;
}

/* ---------- Topbar ---------- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 18px;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
  height: 54px;
  flex: 0 0 auto;
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand-logo {
  height: 26px;
  width: auto;
  display: block;
}
.brand-divider {
  width: 1px;
  height: 28px;
  background: var(--line);
}
.brand-title { font-weight: 700; font-size: 14px; color: var(--ink); }
.brand-sub { font-size: 11px; color: var(--ink-mute); margin-top: 1px; }

.top-tools { display: flex; align-items: center; gap: 10px; }
.search input {
  background: var(--panel-2);
  border: 1px solid var(--line);
  color: var(--ink);
  padding: 7px 11px;
  border-radius: 7px;
  width: 240px;
  font-size: 12.5px;
  outline: none;
  transition: all 0.15s;
}
.search input::placeholder { color: var(--ink-mute); }
.search input:focus {
  border-color: var(--primary);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(255, 102, 0, 0.1);
}

.btn {
  border: 1px solid transparent;
  padding: 6px 12px;
  border-radius: 7px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
  white-space: nowrap;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-600); }
.btn-ghost { background: var(--panel-2); color: var(--ink-dim); border-color: var(--line); }
.btn-ghost:hover { background: var(--line-2); color: var(--ink); }
.btn-block { width: 100%; }

.user { display: flex; align-items: center; gap: 8px; padding-left: 10px; margin-left: 4px; border-left: 1px solid var(--line); }
.avatar {
  width: 32px; height: 32px;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  color: #fff; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 12px;
}
.user-name { font-size: 12.5px; font-weight: 600; color: var(--ink); line-height: 1.2; }
.user-role { font-size: 10.5px; color: var(--ink-mute); }

/* ---------- KPI strip ---------- */
.kpis {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 10px;
  padding: 10px 18px;
  flex: 0 0 auto;
}
.kpi {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 12px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.kpi::before {
  content: "";
  position: absolute;
  left: 0; top: 10px; bottom: 10px;
  width: 3px; border-radius: 0 3px 3px 0;
  background: var(--accent);
}
.kpi.primary::before { background: var(--primary); }
.kpi.success::before { background: var(--green); }
.kpi.warn::before    { background: var(--yellow); }
.kpi.danger::before  { background: var(--red); }
.kpi .k-label { font-size: 10.5px; color: var(--ink-mute); text-transform: uppercase; letter-spacing: 0.5px; font-weight: 600; }
.kpi .k-value { font-size: 22px; font-weight: 800; margin-top: 2px; letter-spacing: -0.5px; color: var(--ink); line-height: 1.1; }
.kpi .k-delta { font-size: 10.5px; margin-top: 2px; color: var(--ink-mute); }

/* ---------- Layout ---------- */
.layout {
  flex: 1 1 auto;
  min-height: 0;
  display: grid;
  grid-template-columns: 252px 1fr 336px;
  gap: 10px;
  padding: 0 18px 10px;
  overflow: hidden;
}

.sidebar, .details {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow-y: auto;
  padding: 12px;
  box-shadow: var(--shadow-sm);
}
.side-block + .side-block { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.side-title {
  font-size: 11px; text-transform: uppercase; letter-spacing: 0.6px;
  color: var(--ink-mute); font-weight: 700;
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 8px;
}

.filter-group { margin-bottom: 10px; }
.filter-group label {
  display: block; font-size: 11px; color: var(--ink-mute);
  margin-bottom: 4px; font-weight: 600;
}
.filter-group select {
  width: 100%; padding: 7px 9px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
  border-radius: 7px; font-size: 12.5px;
  outline: none;
  cursor: pointer;
}
.filter-group select:focus { border-color: var(--primary); }

.chips { display: flex; flex-wrap: wrap; gap: 5px; }
.chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 9px; border-radius: 999px;
  background: var(--panel-2);
  border: 1px solid var(--line);
  color: var(--ink-dim);
  font-size: 11.5px; cursor: pointer; user-select: none;
  transition: all 0.15s;
  font-family: inherit;
}
.chip:hover { background: var(--line-2); color: var(--ink); }
.chip.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.chip.r-green::before, .chip.r-yellow::before, .chip.r-orange::before, .chip.r-red::before {
  content: ""; width: 7px; height: 7px; border-radius: 50%;
}
.chip.r-green::before  { background: var(--green); }
.chip.r-yellow::before { background: var(--yellow); }
.chip.r-orange::before { background: var(--orange); }
.chip.r-red::before    { background: var(--red); }

.badge {
  display: inline-flex; align-items: center;
  padding: 2px 7px; border-radius: 999px;
  font-size: 10.5px; font-weight: 700;
}
.badge-red { background: var(--red-soft); color: var(--red); }

.critical-list { display: flex; flex-direction: column; gap: 5px; }
.crit-item {
  background: var(--red-soft);
  border: 1px solid #fecaca;
  padding: 7px 9px;
  border-radius: 7px;
  font-size: 11.5px;
  cursor: pointer;
  transition: all 0.15s;
}
.crit-item:hover { background: #fecaca; transform: translateX(2px); }
.crit-item .c-name { font-weight: 600; color: #991b1b; }
.crit-item .c-meta { font-size: 10.5px; color: #b91c1c; margin-top: 1px; }

.modules { list-style: none; padding: 0; margin: 0; }
.modules li {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 8px; border-radius: 6px;
  font-size: 12px; color: var(--ink-dim);
  cursor: pointer;
  transition: all 0.15s;
}
.modules li:hover { background: var(--panel-2); color: var(--ink); }
.mod-icon { font-size: 13px; }

/* ---------- Map ---------- */
.map-wrap {
  display: flex;
  flex-direction: column;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  min-height: 0;
  box-shadow: var(--shadow-sm);
}
.map-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 12px; border-bottom: 1px solid var(--line);
  flex-wrap: wrap; gap: 8px;
  background: var(--panel-2);
}
.crumbs { display: flex; align-items: center; gap: 6px; font-size: 12.5px; }
.crumb { color: var(--ink-mute); cursor: pointer; font-weight: 500; }
.crumb:hover { color: var(--primary); }
.crumb.active { color: var(--ink); font-weight: 600; cursor: default; }
.crumbs .sep { color: var(--ink-mute); }

.map-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.legend { display: flex; align-items: center; gap: 10px; font-size: 11.5px; color: var(--ink-dim); }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; margin-right: 3px; vertical-align: middle; }
.dot.r-green  { background: var(--green); }
.dot.r-yellow { background: var(--yellow); }
.dot.r-orange { background: var(--orange); }
.dot.r-red    { background: var(--red); }

#map {
  flex: 1;
  min-height: 0;
  background: #e9f0f8;
}
.map-footer {
  display: flex; justify-content: space-between; align-items: center;
  padding: 7px 12px;
  border-top: 1px solid var(--line);
  font-size: 11.5px; color: var(--ink-mute);
  background: var(--panel-2);
  flex-wrap: wrap;
  gap: 8px;
}
.shortcuts { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.sc-label { color: var(--ink-mute); font-weight: 600; }
.shortcuts .chip { padding: 2px 8px; font-size: 11px; }

/* Leaflet light theme */
.leaflet-container { background: #e9f0f8; font-family: inherit; }
.leaflet-control-attribution {
  background: rgba(255,255,255,0.85) !important;
  color: #6b7280 !important;
  font-size: 10px !important;
}
.leaflet-control-attribution a { color: var(--accent) !important; }
.leaflet-control-zoom a {
  background: #fff !important;
  color: var(--ink) !important;
  border-color: var(--line) !important;
  box-shadow: var(--shadow-sm);
}
.leaflet-control-zoom a:hover { background: var(--primary-soft) !important; color: var(--primary) !important; }
.leaflet-popup-content-wrapper {
  background: var(--panel);
  color: var(--ink);
  border-radius: 10px;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
}
.leaflet-popup-tip { background: var(--panel); border: 1px solid var(--line); }
.leaflet-tooltip {
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
  font-size: 11.5px;
  box-shadow: var(--shadow);
  border-radius: 6px;
  padding: 5px 8px;
}
.leaflet-tooltip-top:before { border-top-color: var(--line); }

/* Province bubble markers */
.prov-icon { pointer-events: auto; }
.prov-bubble {
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  color: #fff;
  font-weight: 800;
  border: 2.5px solid #fff;
  box-shadow: 0 2px 10px rgba(0,0,0,0.22);
  transition: transform 0.15s ease, box-shadow 0.15s;
  position: relative;
}
.prov-bubble:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 16px rgba(0,0,0,0.3);
  z-index: 1000;
}
.prov-bubble .pb-count { font-size: 12px; line-height: 1; }
.prov-bubble .pb-name {
  position: absolute; top: 100%; left: 50%; transform: translateX(-50%);
  margin-top: 5px;
  background: #fff;
  padding: 2px 7px; border-radius: 5px;
  font-size: 10.5px; white-space: nowrap;
  color: var(--ink);
  border: 1px solid var(--line);
  font-weight: 600;
  box-shadow: var(--shadow-sm);
}

/* Store pin */
.store-pin {
  width: 24px; height: 24px; border-radius: 50% 50% 50% 0;
  transform: rotate(-45deg);
  border: 2px solid #fff;
  box-shadow: 0 3px 8px rgba(0,0,0,0.3);
  display: flex; align-items: center; justify-content: center;
}
.store-pin::after {
  content: ""; width: 7px; height: 7px; background: #fff; border-radius: 50%;
  transform: rotate(45deg);
}

/* Marker cluster */
.marker-cluster-small, .marker-cluster-medium, .marker-cluster-large {
  background: rgba(255,102,0,0.22) !important;
}
.marker-cluster-small div, .marker-cluster-medium div, .marker-cluster-large div {
  background: var(--primary) !important; color: #fff !important; font-weight: 700;
  border: 2px solid #fff;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

/* ---------- Details panel ---------- */
.details-empty {
  text-align: center; padding: 30px 16px;
  color: var(--ink-mute);
}
.empty-illu { font-size: 40px; margin-bottom: 8px; }
.details-empty h3 { color: var(--ink); margin: 4px 0; font-size: 15px; }
.details-empty p { font-size: 12px; margin: 0; line-height: 1.5; }

.store-card { display: flex; flex-direction: column; gap: 10px; }
.store-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 10px;
}
.store-name { font-size: 15px; font-weight: 700; color: var(--ink); line-height: 1.3; }
.store-addr { font-size: 11px; color: var(--ink-mute); margin-top: 3px; line-height: 1.4; }
.risk-pill {
  padding: 4px 10px; border-radius: 999px;
  font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.4px;
  white-space: nowrap;
}
.risk-pill.r-green  { background: var(--green-soft);  color: #15803d; border: 1px solid #bbf7d0; }
.risk-pill.r-yellow { background: var(--yellow-soft); color: #b45309; border: 1px solid #fde68a; }
.risk-pill.r-orange { background: var(--orange-soft); color: #c2410c; border: 1px solid #fed7aa; }
.risk-pill.r-red    { background: var(--red-soft);    color: #b91c1c; border: 1px solid #fecaca; }

.store-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.cell {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 8px 10px;
}
.cell .k { font-size: 10px; color: var(--ink-mute); text-transform: uppercase; letter-spacing: 0.4px; font-weight: 600; }
.cell .v { font-size: 16px; font-weight: 700; margin-top: 1px; color: var(--ink); }

.store-roles { display: flex; flex-direction: column; gap: 5px; }
.role {
  display: flex; justify-content: space-between; align-items: center;
  background: var(--panel-2);
  border: 1px solid var(--line);
  padding: 7px 10px; border-radius: 7px;
  font-size: 12px;
}
.role-k { color: var(--ink-mute); }
.role-v { font-weight: 600; color: var(--ink); }
.role-v.empty { color: var(--red); }

.risk-breakdown {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 9px 11px;
}
.rb-title {
  font-size: 11px; color: var(--ink-mute); text-transform: uppercase; letter-spacing: 0.4px; font-weight: 700;
  display: flex; justify-content: space-between; margin-bottom: 7px; align-items: center;
}
.rb-score { font-size: 12px; color: var(--ink); font-weight: 700; letter-spacing: 0; text-transform: none; }
.rb-bar { margin-bottom: 6px; }
.rb-bar:last-child { margin-bottom: 0; }
.rb-bar-label { display: flex; justify-content: space-between; font-size: 10.5px; color: var(--ink-dim); margin-bottom: 2px; }
.rb-bar-track { height: 5px; background: var(--line-2); border-radius: 3px; overflow: hidden; }
.rb-bar-fill { height: 100%; border-radius: 3px; transition: width 0.3s; }

.store-actions { display: flex; gap: 6px; }
.store-actions .btn { flex: 1; font-size: 12px; padding: 7px 10px; }

/* Documents */
.docs-block {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 10px 11px;
}
.docs-progress {
  height: 5px; background: var(--line-2);
  border-radius: 3px; overflow: hidden; margin: 2px 0 9px;
}
.docs-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #16a34a, #4ade80);
  transition: width 0.3s ease;
}
.docs-list { display: flex; flex-direction: column; gap: 5px; }
.doc-item {
  display: grid;
  grid-template-columns: 26px 1fr auto;
  gap: 9px; align-items: center;
  padding: 7px 9px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 6px;
  transition: all 0.15s;
}
.doc-item:hover { border-color: var(--primary); box-shadow: var(--shadow-sm); }
.doc-item.doc-ok   { border-left: 3px solid var(--green); }
.doc-item.doc-exp  { border-left: 3px solid var(--yellow); }
.doc-item.doc-miss { border-left: 3px solid var(--red); }
.doc-ic {
  width: 24px; height: 24px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 13px;
}
.doc-ok .doc-ic  { background: var(--green-soft);  color: var(--green); }
.doc-exp .doc-ic { background: var(--yellow-soft); color: var(--yellow); }
.doc-miss .doc-ic{ background: var(--red-soft);    color: var(--red); }
.doc-body { min-width: 0; }
.doc-head { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; }
.doc-label { font-size: 11.5px; font-weight: 600; color: var(--ink); }
.doc-status {
  font-size: 9.5px; text-transform: uppercase; letter-spacing: 0.4px; font-weight: 700;
  color: var(--ink-mute);
}
.doc-ok .doc-status   { color: var(--green); }
.doc-exp .doc-status  { color: var(--yellow); }
.doc-miss .doc-status { color: var(--red); }
.doc-meta { font-size: 10px; color: var(--ink-mute); margin-top: 1px; line-height: 1.45; }
.doc-exp-warn { color: var(--yellow); font-weight: 600; }
.doc-btn {
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink-dim);
  padding: 4px 9px;
  border-radius: 5px;
  font-size: 10.5px; font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}
.doc-btn:hover { background: var(--panel-2); color: var(--ink); }
.doc-btn-warn { border-color: #fcd34d; color: var(--yellow); background: var(--yellow-soft); }
.doc-btn-warn:hover { background: #fde68a; }
.doc-btn-primary { background: var(--primary); color: #fff; border-color: var(--primary); }
.doc-btn-primary:hover { background: var(--primary-600); }

/* province panel */
.prov-panel { display: flex; flex-direction: column; gap: 10px; }
.prov-head h3 { margin: 0; font-size: 16px; color: var(--ink); }
.prov-head .p-sub { font-size: 11.5px; color: var(--ink-mute); margin-top: 2px; }
.prov-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.prov-risk-chart {
  display: flex; height: 20px; border-radius: 5px; overflow: hidden;
  border: 1px solid var(--line);
}
.prov-risk-chart span { display: flex; align-items: center; justify-content: center; font-size: 9.5px; color: #fff; font-weight: 700; }

.prov-doc-legend {
  display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px;
  font-size: 10.5px; color: var(--ink-dim);
}
.prov-doc-legend i {
  display: inline-block; width: 7px; height: 7px; border-radius: 50%;
  margin-right: 4px; vertical-align: middle;
}

.prov-store-list {
  max-height: 230px;
  overflow-y: auto;
  display: flex; flex-direction: column; gap: 4px;
}
.ps-item {
  display: flex; align-items: center; justify-content: space-between;
  padding: 7px 9px; border-radius: 6px;
  background: var(--panel-2);
  border: 1px solid var(--line);
  cursor: pointer;
  font-size: 11.5px;
  transition: all 0.15s;
  gap: 8px;
}
.ps-item:hover { background: var(--primary-soft); border-color: var(--primary); }
.ps-name { font-weight: 600; color: var(--ink); }
.ps-meta { font-size: 10.5px; color: var(--ink-mute); margin-top: 1px; }
.ps-badges { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.ps-risk { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; }
.ps-risk.r-green  { background: var(--green); }
.ps-risk.r-yellow { background: var(--yellow); }
.ps-risk.r-orange { background: var(--orange); }
.ps-risk.r-red    { background: var(--red); }

.doc-badge {
  font-size: 9.5px; font-weight: 700;
  padding: 2px 5px; border-radius: 4px;
  letter-spacing: 0.2px;
}
.doc-badge-ok   { background: var(--green-soft);  color: #15803d; }
.doc-badge-warn { background: var(--yellow-soft); color: #b45309; }
.doc-badge-red  { background: var(--red-soft);    color: #b91c1c; }

/* ---------- Footer ---------- */
.bottombar {
  padding: 5px 18px;
  background: var(--panel);
  border-top: 1px solid var(--line);
  font-size: 10.5px; color: var(--ink-mute);
  display: flex; justify-content: space-between;
  flex: 0 0 auto;
}

/* Scrollbars */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #c9d2e1; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #a5b0c4; }

/* Mobile panel toggle */
.mobile-tabs {
  display: none;
  background: var(--panel);
  border-bottom: 1px solid var(--line);
  padding: 6px 10px;
  gap: 4px;
}
.mobile-tabs button {
  flex: 1;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink-dim);
  padding: 7px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}
.mobile-tabs button.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* ================= RESPONSIVE ================= */
@media (max-width: 1500px) {
  .kpis { grid-template-columns: repeat(7, 1fr); gap: 8px; }
  .kpi .k-value { font-size: 20px; }
  .layout { grid-template-columns: 230px 1fr 310px; }
}
@media (max-width: 1280px) {
  .kpis { grid-template-columns: repeat(4, 1fr); }
  .layout { grid-template-columns: 220px 1fr 300px; }
  .search input { width: 180px; }
}
@media (max-width: 1024px) {
  .kpis { grid-template-columns: repeat(3, 1fr); padding: 8px 14px; gap: 8px; }
  .layout { grid-template-columns: 200px 1fr 280px; padding: 0 14px 8px; }
  .topbar { padding: 0 14px; }
  .kpi .k-value { font-size: 18px; }
  .brand-sub { display: none; }
  .user-meta { display: none; }
}
@media (max-width: 820px) {
  body { overflow: auto; }
  .topbar { height: auto; padding: 8px 12px; flex-wrap: wrap; gap: 6px; }
  .top-tools .search { order: 3; width: 100%; }
  .search input { width: 100%; }
  .kpis {
    grid-template-columns: repeat(2, 1fr);
    padding: 8px 12px;
    overflow-x: auto;
  }
  .kpi { padding: 8px 10px; }
  .kpi .k-value { font-size: 16px; }
  .mobile-tabs { display: flex; }
  .layout {
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
    padding: 0 12px 10px;
    gap: 8px;
    overflow: visible;
  }
  .sidebar, .details { display: none; max-height: none; }
  .sidebar.mobile-active, .details.mobile-active { display: block; }
  #map { min-height: 360px; }
  .map-wrap { min-height: 420px; }
  .legend { display: none; }
  .bottombar { flex-direction: column; gap: 2px; text-align: center; padding: 6px 12px; }
  .exportPdf, #exportXls { display: none; }
}
@media (max-width: 520px) {
  .kpis { grid-template-columns: 1fr 1fr; gap: 6px; }
  .brand-text { display: none; }
  #exportPdf, #exportXls { display: none; }
  .map-head { flex-direction: column; align-items: flex-start; }
  .map-actions { width: 100%; justify-content: space-between; }
  .shortcuts { width: 100%; overflow-x: auto; }
}
