/* Plansza IV — Mapa sądów */

.map-legend {
  position: absolute; left: 24px; top: 20px; z-index: 5; max-width: 340px;
}
.map-legend .legend-title { font-size: var(--t-xs); color: var(--ink-faint); margin-bottom: 6px; }
.map-legend .legend span { cursor: pointer; padding: 2px 0; }
.map-legend .legend span:hover { color: var(--paper); }
.map-legend .legend span[aria-pressed="true"] { color: var(--brass); }

.controls { align-items: flex-end; }
.year-note {
  flex-basis: 100%; font-family: var(--serif); font-size: var(--t-sm); color: var(--ink-muted);
  min-height: 1.4em; margin-top: -6px;
}
.controls .seg { margin-bottom: 6px; }
#play { min-width: 92px; margin-bottom: 6px; }

/* rysunek */
#map .voiv { fill: rgba(244, 241, 234, 0.025); stroke: var(--paper); stroke-opacity: 0.38; stroke-width: 0.7; }
#map .graticule { fill: none; stroke: var(--rule); stroke-opacity: 0.55; stroke-width: 0.5; }
#map .city { cursor: pointer; }
#map .city .dot { fill: var(--paper); fill-opacity: 0.16; stroke: var(--paper); stroke-opacity: 0.9; stroke-width: 1; }
#map .city .ring path { stroke: var(--ground); stroke-width: 0.6; }
#map .city .capital { fill: none; stroke: var(--brass); stroke-dasharray: 3 4; stroke-width: 1; }
#map .city .hit { fill: transparent; }
#map .city.selected .dot { stroke: var(--brass); stroke-width: 2; }
#map .city.selected .sel { fill: none; stroke: var(--brass); stroke-width: 1.5; }
#map .city.dim { opacity: 0.35; }
#map .label { font-family: var(--serif); fill: var(--paper); font-size: 13px; pointer-events: none; paint-order: stroke; stroke: var(--ground); stroke-width: 3px; stroke-linejoin: round; }
#map .label.sub { font-family: var(--sans); font-size: 10px; fill: var(--brass); stroke-width: 2.5px; }
#map .label.small { font-size: 11px; fill: var(--ink-muted); }

/* panel */
.panel .rank li .no { color: var(--ink-faint); min-width: 1.6em; font-variant-numeric: tabular-nums; }
.panel .rank li .name { flex: 1; }
.panel .hero-num { font-family: var(--serif); font-size: var(--t-2xl); line-height: 1; color: var(--paper); margin: 10px 0 2px; }
.panel .hero-sub { color: var(--ink-muted); font-size: var(--t-sm); }
.panel .spark { display: block; width: 100%; height: 96px; margin-top: 6px; overflow: visible; }
.panel .spark rect.cur { fill: var(--brass); }
.panel .spark rect { fill: var(--paper); fill-opacity: 0.7; }
.panel .spark text { font-family: var(--sans); font-size: 10px; fill: var(--ink-faint); }
.panel .bars { list-style: none; margin: 0; padding: 0; font-size: var(--t-sm); }
.panel .bars li { display: grid; grid-template-columns: 10.5rem 1fr 4.2rem; gap: 8px; align-items: center; padding: 3px 0; }
.panel .bars li .b { height: 7px; background: var(--paper); opacity: 0.75; border-radius: 1px; }
.panel .bars li .v { color: var(--ink-muted); text-align: right; font-variant-numeric: tabular-nums; }
.panel .bars li .k { color: var(--paper); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.panel .back { margin-top: 20px; }
.panel .note { font-size: var(--t-xs); color: var(--ink-faint); margin-top: 6px; }
.panel .seat { display: inline-block; font-size: var(--t-xs); color: var(--brass); border: 1px dashed var(--brass); border-radius: 3px; padding: 1px 7px; margin-top: 4px; }

@media (max-width: 1250px) {
  .controls { gap: 10px; }
  .year-scrub .year { font-size: var(--t-xl); }
  input[type="range"] { width: min(300px, 24vw); }
  .controls .seg button, #play { padding: 5px 9px; }
}
@media (max-width: 900px) {
  .map-legend { max-width: 60vw; }
  input[type="range"] { width: 50vw; }
}
