/* M5S Natale Putignano - area amministrativa */
.admin .contenuto.largo { max-width: 1180px; }

.riga-intestazione {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.azioni-amministratore {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.pulsante.piccolo {
  padding: 8px 14px;
  font-size: 13.5px;
}

select,
input[type="date"],
input[type="password"],
input[type="number"],
input[type="search"] {
  width: 100%;
  padding: 11px 13px;
  font-size: 15px;
  font-family: inherit;
  color: var(--testo);
  background: #fbfdfc;
  border: 1.5px solid var(--bordo);
  border-radius: 9px;
}

select:focus,
input[type="date"]:focus {
  outline: none;
  border-color: var(--giallo);
  box-shadow: 0 0 0 3px rgba(11, 107, 58, .15);
}

/* statistiche */
.statistiche {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(165px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.stat {
  background: var(--giallo-chiaro);
  border: 1px solid #e8dcb0;
  border-radius: 10px;
  padding: 13px 15px;
}

.stat .valore {
  font-size: 26px;
  font-weight: 700;
  color: var(--giallo-scuro);
  line-height: 1.15;
}

.stat .etichetta {
  font-size: 12.5px;
  color: var(--grigio);
  text-transform: uppercase;
  letter-spacing: .3px;
}

.stat .dettaglio {
  font-size: 12.5px;
  color: var(--giallo-scuro);
  margin-top: 5px;
  line-height: 1.4;
}

/* filtri */
.filtri {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  padding: 14px;
  background: #f7faf8;
  border: 1px solid var(--bordo);
  border-radius: 10px;
  margin-bottom: 16px;
}

.filtri .campo { flex: 1 1 180px; }

/* tabella */
.tabella-contenitore {
  overflow-x: auto;
  border: 1px solid var(--bordo);
  border-radius: 10px;
}

.tabella {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  background: #fff;
}

.tabella th {
  background: var(--giallo);
  color: var(--testo-scuro);
  text-align: left;
  padding: 10px 11px;
  font-weight: 600;
  white-space: nowrap;
  position: sticky;
  top: 0;
}

.tabella td {
  padding: 9px 11px;
  border-bottom: 1px solid #edf1f2;
  vertical-align: top;
}

.tabella tbody tr:nth-child(even) { background: #fafcfb; }
.tabella tbody tr:hover { background: var(--oro-chiaro); }

.codice-cell {
  font-family: Consolas, "Courier New", monospace;
  font-weight: 700;
  color: var(--giallo-scuro);
  white-space: nowrap;
}

.badge {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.badge.bambino { background: #d9ecff; color: #0b4f8a; }
.badge.bambina { background: #ffe1ef; color: #8a0b4f; }
.badge.fascia { background: var(--giallo-chiaro); color: var(--giallo-scuro); }

.conteggio { margin-top: 10px; text-align: right; }

.messaggio.info {
  background: var(--giallo-chiaro);
  border: 1px solid #e8dcb0;
  color: var(--giallo-scuro);
}

/* ---------- gestione utenti ---------- */
.utenti-scheda { margin-top: 20px; }

.utenti-form { align-items: flex-end; }

.utenti-form .campo { flex: 1 1 150px; }

.pulsanti-utente,
.pulsanti-filtro {
  flex: 1 1 190px;
  display: flex;
  flex-direction: row;
  gap: 8px;
  align-items: center;
}

.pulsanti-utente .pulsante,
.pulsanti-filtro .pulsante { flex: 0 0 auto; }

.pulsante.pericolo {
  background: #fff;
  color: var(--rosso);
  border: 1.5px solid var(--rosso);
}

.pulsante.pericolo:hover { background: var(--rosso); color: #fff; }

.link-modifica {
  background: none;
  border: none;
  color: var(--giallo-scuro);
  font-family: inherit;
  font-size: 13px;
  cursor: pointer;
  padding: 2px 6px;
  text-decoration: underline;
}

.link-modifica.elimina { color: var(--rosso); }

.badge.amministratore { background: var(--giallo-chiaro); color: var(--giallo-scuro); }
.badge.operatore { background: #e2eefb; color: #0b4f8a; }
