/* ============================================================
   World map (Editorial Daily) — choropleth + region bars panel.
   ============================================================ */

.map-wrap {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  padding: 12px;
  height: 200px;
}
@media (max-width: 480px) { .map-wrap { height: 170px; } }

.world-map {
  display: block;
  width: 100%;
  height: 100%;
}
.world-map path.country {
  stroke: var(--paper-2);
  stroke-width: 0.4;
  transition: stroke-width 0.15s, opacity 0.15s;
  cursor: default;
  vector-effect: non-scaling-stroke;
}
.world-map path.country:hover {
  stroke: var(--ink);
  stroke-width: 1.2;
  cursor: pointer;
}
.world-map path.country.player-country {
  stroke: var(--ink);
  stroke-width: 1.6;
}

/* Map legend */
.map-legend {
  display: flex;
  align-items: center;
  gap: 0;
  margin-top: 8px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 8.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-mid);
}
.legend-bar {
  flex: 1;
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(to right, var(--c-no), rgba(26,20,16,0.18) 50%, var(--c-yes));
  margin: 0 8px;
}

.map-tooltip {
  position: absolute;
  pointer-events: none;
  background: var(--ink);
  color: var(--paper);
  border-radius: 6px;
  padding: 7px 11px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.12s;
  z-index: 10;
}
.map-tooltip.shown { opacity: 1; }
.map-tooltip .name {
  font-family: 'IBM Plex Sans', sans-serif;
  font-weight: 500;
  margin-bottom: 2px;
  letter-spacing: 0;
}
.map-tooltip .stat { color: rgba(245, 239, 227, 0.7); }
.map-tooltip .stat .y { color: var(--c-yes); font-weight: 600; }
.map-tooltip .stat .n { color: var(--c-no);  font-weight: 600; }

.map-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  font-family: 'Newsreader', Georgia, serif;
  font-style: italic;
  font-size: 16px;
  color: var(--ink-mid);
  text-align: center;
  padding: 0 28px;
}

/* ============ Region bars panel (Option C) ============ */
.map-bars {
  margin-top: 16px;
  padding: 14px 16px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 9.5px;
  letter-spacing: 0.04em;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.bar-row {
  display: grid;
  grid-template-columns: 88px 1fr 30px;
  gap: 10px;
  align-items: center;
}
.bar-name {
  text-transform: lowercase;
  color: var(--ink-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bar-track {
  display: flex;
  height: 8px;
  border-radius: 1px;
  overflow: hidden;
  background: rgba(26, 20, 16, 0.05);
}
.bar-seg--yes { background: var(--c-yes); }
.bar-seg--no  { background: var(--c-no); opacity: 0.85; }
.bar-pct {
  text-align: right;
  font-variant-numeric: tabular-nums;
  color: var(--ink-soft);
}

.bars-empty {
  font-size: 9.5px;
  color: var(--ink-mid);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: center;
  padding: 14px 0;
}
