/* Donas de control territorial y votos (bajo el mapa provincial). */
.pies { max-width: 1320px; margin: 28px auto 0; padding-top: 20px; border-top: 1px solid var(--rule); }
.pies-head { display: grid; gap: 4px; margin-bottom: 14px; }
.pies-title { font-stretch: 75%; font-size: 22px; font-weight: 750; line-height: 1.1; }
.pies-sub { margin: 0; color: var(--muted); font-size: 12.5px; max-width: 90ch; }

.pies-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.pie-card {
  margin: 0; display: grid; gap: 10px; align-content: start;
  background: var(--panel); border: 1px solid var(--rule); border-radius: 10px; padding: 16px;
}
.pie-card figcaption {
  font-size: 11px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); font-weight: 650;
}
.pie-chart svg { display: block; width: 100%; max-width: 220px; height: auto; margin-inline: auto; }
.pie-seg { stroke: var(--panel); stroke-width: 1.5; }
.pie-undefined { stroke: var(--rule-strong); stroke-width: 1; }
.pie-total { text-anchor: middle; font-size: 22px; font-weight: 750; font-stretch: 80%; fill: var(--ink); font-variant-numeric: tabular-nums; }
.pie-unit { text-anchor: middle; font-size: 11px; fill: var(--muted); }

.pie-legend { list-style: none; margin: 0; padding: 0; display: grid; font-size: 12.5px; }
.pie-legend li {
  display: grid; grid-template-columns: minmax(0, 1fr) auto 3.4rem; gap: 8px; align-items: center;
  padding: 5px 0; border-bottom: 1px solid var(--rule);
}
.pie-legend li:last-child { border-bottom: 0; }
.pie-legend .who { min-width: 0; }
.pie-legend .who span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pie-legend .sw { width: 14px; height: 14px; border-radius: 3px; flex: none; }
.pie-legend .num { text-align: right; font-variant-numeric: tabular-nums; }
.pie-legend .pct { color: var(--muted); }
.pie-note { margin: 0; font-size: 11.5px; color: var(--muted); }

@media (max-width: 900px) {
  .pies-grid { grid-template-columns: minmax(0, 1fr); }
}
