/*! =============================================================================
 *  © 2026 Renzo Núñez · RonBStudio — "Perú Elige 2026 · Segunda Vuelta".
 *  Todos los derechos reservados. Código propietario.
 *  https://www.ronbstudio.com
 * ============================================================================= */
/* =============================================================================
 *  Archivo: jee-actas.css
 *  Cuadro de actas enviadas al JEE + votos netos estimados. Espejo visual de
 *  proy-departamentos.css / evolution.css para verse como sección hermana.
 * ===========================================================================*/

.jee-section {
  max-width: var(--container-max, 1100px);
  margin: 0 auto;
  padding: var(--sp-3, 0.75rem) var(--container-padding, 1rem) var(--sp-5, 1.5rem);
}

/* v0.1.16.105: enlace a la Sala JEE (jee.html) bajo el cuadro */
.jee-salalink {
  text-align: center;
  margin: 0.9rem auto 0;
}
.jee-salalink a {
  display: inline-block;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--c-mv-card-title, #2c5599);
  text-decoration: none;
  background: var(--c-mv-bg-card, #ffffff);
  border: 1px solid var(--c-mv-card-border, #e2e8f0);
  border-radius: 999px;
  padding: 0.55rem 1.2rem;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
  transition: box-shadow 0.15s ease, transform 0.15s ease;
}
.jee-salalink a:hover {
  box-shadow: 0 3px 9px rgba(15, 23, 42, 0.14);
  transform: translateY(-1px);
}

.jee {
  max-width: 980px;
  margin: 0 auto;
  background:
    radial-gradient(
      ellipse at top left,
      var(--c-mv-mapa-radial-from) 0%,
      var(--c-mv-mapa-radial-mid)  60%,
      transparent 100%
    ),
    var(--c-mv-bg-card, #ffffff);
  border: 1px solid var(--c-mv-card-border, #e2e8f0);
  border-radius: var(--c-card-radius, 16px);
  padding: 1.75rem 1.5rem 1.5rem;
  box-shadow: var(--c-card-shadow, 0 1px 3px rgba(15, 23, 42, 0.06));
}

.jee__head { text-align: center; margin-bottom: 1rem; }

.jee__title {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--c-mv-card-title, #2c5599);
  margin: 0 0 0.3rem;
  line-height: 1.25;
}

.jee__sub {
  font-size: 0.85rem;
  color: var(--c-mv-ink-muted, #64748b);
  margin: 0 auto;
  max-width: 640px;
}

/* --- Tabla --- */
.jee__table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }

.jee__table {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.9rem;
}
.jee__table th,
.jee__table td {
  padding: 0.5rem 0.65rem;
  border-bottom: 1px solid var(--c-mv-card-border, #e2e8f0);
  white-space: nowrap;
}
.jee__th-left,
.jee__th-num {
  color: var(--c-mv-ink, #1e293b);
  font-weight: 700;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.jee__th-left { text-align: left; }
.jee__th-num { text-align: right; }

.jee__td-left { text-align: left; color: var(--c-mv-ink, #1e293b); font-weight: 600; }
.jee__num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  color: var(--c-mv-ink, #1e293b);
}
.jee__net { font-weight: 800; }
.jee__net--k { color: #ea580c; }   /* Keiko: naranja vivo */
.jee__net--s { color: #9a1024; }   /* Sánchez: rojo oscuro, bien distinto del naranja */

.jee__table tbody tr:hover { background: rgba(30, 58, 95, 0.04); }

.jee__total td {
  border-top: 2px solid var(--c-mv-ink, #1e293b);
  border-bottom: none;
  font-weight: 800;
  padding-top: 0.65rem;
}

/* --- Nota al pie --- */
.jee__note {
  text-align: center;
  margin: 0.9rem auto 0;
  max-width: 680px;
  font-size: 0.78rem;
  color: var(--c-mv-ink-muted, #64748b);
}
.jee__note--preview { font-style: italic; }
.jee__note--error { color: var(--c-party-ap, #c8302a); }

/* --- Responsive --- */
@media (max-width: 560px) {
  .jee { padding: 1.5rem 0.65rem 1.25rem; }
  .jee__title { font-size: 1.05rem; }
  .jee__sub { font-size: 0.78rem; }
  /* La tabla ENTRA en el ancho del móvil: encabezados y nombres de depto pueden
     envolver; los números NO se parten; fuente y padding compactos. */
  .jee__table { font-size: 0.73rem; }
  .jee__table th,
  .jee__table td { padding: 0.42rem 0.26rem; white-space: normal; }
  .jee__table td.jee__num { white-space: nowrap; }       /* números en una línea */
  .jee__total td.jee__num { white-space: normal; }        /* "~+X Keiko" puede partir */
  .jee__th-left, .jee__th-num { font-size: 0.62rem; letter-spacing: 0; }
  .jee__td-left { word-break: break-word; line-height: 1.18; }
}

/* --- Dato resaltado: procedencia por liderazgo de la región (v0.1.16.84) --- */
.jee__insight {
  margin-top: 1.4rem;
  padding: 1.3rem 1.4rem;
  /* Mismo lenguaje visual que la tarjeta "Recta Final": base blanca con un tinte radial
     muy sutil arriba-izquierda, borde fino parejo y sombra suave. Sin franja de color. */
  background:
    radial-gradient(ellipse at top left,
      var(--c-mv-mapa-radial-from, rgba(31, 58, 95, 0.18)) 0%,
      var(--c-mv-mapa-radial-mid, rgba(31, 58, 95, 0.05)) 60%,
      transparent 100%),
    var(--c-mv-bg-card, #ffffff);
  border: 1px solid var(--c-mv-card-border, rgba(15, 23, 42, 0.07));
  border-radius: 14px;
  box-shadow: var(--c-card-shadow, 0 4px 16px rgba(15, 23, 42, 0.08), 0 1px 3px rgba(15, 23, 42, 0.06));
}
.jee__insight-label {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--c-mv-ink-muted, #64748b);
  text-align: center;
  margin-bottom: 0.3rem;
}
.jee__insight-sub + .jee__insight-sub {
  margin-top: 1.1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--c-mv-card-border, rgba(15, 23, 42, 0.07));
}
.jee__insight-subhead {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--c-mv-ink-muted, #64748b);
  text-align: center;
  margin-bottom: 1.2rem;
}
.jee__insight-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.7rem;
  flex-wrap: wrap;
}
/* Pie tipo doughnut — el background (conic-gradient con los %) lo inyecta el JS. */
.jee__insight-pie {
  position: relative;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 2px 9px rgba(15, 23, 42, 0.13);
}
.jee__insight-pie-hole {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 62%;
  height: 62%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: var(--c-mv-bg-card, #ffffff);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.jee__insight-pie-delta {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 1.02rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.jee__insight-pie-dcap {
  font-size: 0.52rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--c-mv-ink-muted, #64748b);
  margin-top: 0.18rem;
  text-align: center;
}
.jee__insight-legend {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-width: 170px;
}
.jee__insight-legrow { display: flex; align-items: center; gap: 0.6rem; }
.jee__insight-dot {
  width: 14px;
  height: 14px;
  border-radius: 4px;
  flex-shrink: 0;
}
.jee__insight-dot--k { background: var(--c-party-fp, #f37021); }
.jee__insight-dot--s { background: var(--c-party-ap, #c8302a); }
.jee__insight-legtxt { display: flex; flex-direction: column; line-height: 1.05; }
.jee__insight-legpct {
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 1.45rem;
  font-weight: 800;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.jee__insight-pct--k { color: var(--c-party-fp, #f37021); }
.jee__insight-pct--s { color: var(--c-party-ap, #c8302a); }
.jee__insight-legvotes {
  display: block;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--c-mv-ink, #334155);
  font-variant-numeric: tabular-nums;
  margin-top: 0.15rem;
}
.jee__insight-legcap {
  font-size: 0.78rem;
  line-height: 1.25;
  color: var(--c-mv-ink, #334155);
  margin-top: 0.2rem;
}
@media (max-width: 560px) {
  .jee__insight-row { gap: 1.2rem; }
  .jee__insight-pie { width: 112px; height: 112px; }
  .jee__insight-legend { min-width: 0; }
  .jee__insight-legpct { font-size: 1.25rem; }
  .jee__insight-legvotes { font-size: 0.84rem; }
  .jee__insight-legcap { font-size: 0.72rem; }
}
