html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin: 0;
  background: #f5f7fa;
  color: #172033;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.recuento-shell {
  max-width: 1500px;
  margin: 0 auto;
  padding: 28px 20px 48px;
}

.login-card,
.panel-card,
.mesa-card {
  background: #fff;
  border: 1px solid #e6eaf0;
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(20, 32, 54, 0.06);
}

.login-card {
  max-width: 520px;
  margin: 8vh auto 0;
  padding: 32px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: .75rem;
  font-weight: 800;
  color: #2457a6;
  margin-bottom: 6px;
}

.dashboard-header,
.section-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.dashboard-header {
  margin-bottom: 24px;
}

.dashboard-header h1,
.section-title-row h2,
.login-card h1 {
  margin: 0;
  font-weight: 800;
}

.mesa-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.mesa-card {
  padding: 22px;
}

.mesa-code {
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: #6b7280;
  font-weight: 800;
}

.mesa-card h3 {
  margin: 3px 0 18px;
  font-weight: 800;
}

.mesa-status-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 18px;
}

.mesa-status-row > div {
  padding: 12px;
  background: #f8fafc;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.estado-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: .72rem;
  font-weight: 800;
}

.estado-pendiente {
  background: #eef1f5;
  color: #5f6b7a;
}

.estado-contando {
  background: #fff3cd;
  color: #7a5a00;
}

.estado-finalizado {
  background: #dff3e7;
  color: #17653a;
}

.special-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.special-grid > div {
  background: #f8fafc;
  padding: 12px;
  border-radius: 12px;
}

.special-grid span {
  display: block;
  color: #6b7280;
  font-size: .78rem;
}

.special-grid strong {
  display: block;
  font-size: 1.35rem;
  margin-top: 2px;
}

.panel-card {
  padding: 22px;
}

.results-table {
  margin-bottom: 0;
}

.results-table thead th {
  color: #667085;
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .04em;
  border-bottom-width: 1px;
}

.results-table tbody td {
  border-color: #edf0f4;
}

.result-name {
  font-size: .82rem;
  color: #7a8492;
}

.vote-number,
.vote-total {
  font-variant-numeric: tabular-nums;
  font-size: 1.08rem;
  font-weight: 700;
}

.vote-total {
  font-size: 1.18rem;
  color: #173d76;
}

.party-chip {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 999px;
  background: #eef3fb;
  color: #244b7f;
  font-size: .76rem;
  font-weight: 700;
}

@media (max-width: 900px) {
  .mesa-grid {
    grid-template-columns: 1fr;
  }

  .special-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-header {
    align-items: flex-start;
  }
}
