/* Admin panel — layout condiviso */
.admin-wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: 1rem 1.25rem 2.5rem;
  background: #e8edf4;
  min-height: 100vh;
  color: #1a2332;
}

.admin-header {
  background: linear-gradient(135deg, var(--brand) 0%, color-mix(in srgb, var(--brand) 82%, #000) 100%);
  color: #fff;
  padding: 1.15rem 1.5rem;
  border-radius: 14px;
  margin-bottom: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 4px 18px rgba(15, 23, 42, 0.12);
}

.admin-header h1 {
  margin: 0;
  font-size: 1.35rem;
  font-weight: 700;
}

.admin-header small {
  opacity: 0.88;
  font-size: 0.85rem;
}

/* Tabs */
.admin-tabs {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
  padding: 0.35rem;
  background: #fff;
  border-radius: 12px;
  border: 1px solid #d8e0eb;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.admin-tab {
  padding: 0.55rem 0.95rem;
  border-radius: 8px;
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 500;
  color: #475569;
  transition: background 0.15s, color 0.15s;
}

.admin-tab:hover {
  background: #f1f5f9;
  color: #1e293b;
}

.admin-tab.active {
  background: var(--brand);
  color: #fff;
}

.admin-tab[data-tab="booking-schedule"].active {
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.15);
}

.panel {
  display: none;
  animation: adminFadeIn 0.2s ease;
}

.panel.active {
  display: block;
}

@keyframes adminFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: none; }
}

/* Panel header */
.admin-panel-head {
  margin-bottom: 1rem;
}

.admin-panel-head h2 {
  margin: 0 0 0.35rem;
  font-size: 1.2rem;
  font-weight: 700;
  color: #0f172a;
}

.admin-panel-head p {
  margin: 0;
  color: #64748b;
  font-size: 0.9rem;
  line-height: 1.45;
  max-width: 52rem;
}

/* Cards */
.admin-card,
.op-card {
  background: #fff;
  padding: 1.15rem 1.25rem;
  border-radius: 12px;
  margin-bottom: 1rem;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.04);
}

.admin-card__title {
  margin: 0 0 0.35rem;
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
}

.admin-card__lead {
  margin: 0 0 1rem;
  color: #64748b;
  font-size: 0.85rem;
  line-height: 1.45;
}

.admin-card__title + .admin-card__lead {
  margin-top: -0.15rem;
}

/* Forms */
.admin-grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.admin-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
}

@media (max-width: 720px) {
  .admin-grid-2,
  .admin-grid-3 {
    grid-template-columns: 1fr;
  }
}

.admin-field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.admin-field label,
.admin-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: #475569;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.admin-field input,
.admin-field select,
.admin-field textarea,
.admin-input {
  width: 100%;
  padding: 0.55rem 0.65rem;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 0.92rem;
  background: #fff;
  color: #1e293b;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.admin-field input:focus,
.admin-field select:focus,
.admin-field textarea:focus,
.admin-input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--brand) 18%, transparent);
}

.admin-field-hint {
  font-size: 0.78rem;
  color: #94a3b8;
  line-height: 1.35;
}

.admin-check-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.65rem 0;
  font-size: 0.92rem;
}

.admin-fieldset {
  margin: 0.85rem 0;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.85rem 1rem;
}

.admin-fieldset legend {
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0 0.35rem;
  color: #475569;
}

/* Tables */
.admin-table-wrap {
  overflow-x: auto;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
}

.admin-table-wrap table,
.panel > table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  margin: 0;
}

.admin-table-wrap th,
.admin-table-wrap td,
.panel > table th,
.panel > table td {
  padding: 0.65rem 0.85rem;
  text-align: left;
  border-bottom: 1px solid #eef2f7;
  font-size: 0.88rem;
  vertical-align: middle;
}

.admin-table-wrap th,
.panel > table th {
  background: #f8fafc;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #64748b;
}

.admin-table-wrap tr:last-child td,
.panel > table tr:last-child td {
  border-bottom: none;
}

.admin-table-wrap input,
.admin-table-wrap select {
  padding: 0.45rem 0.5rem;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 0.88rem;
  width: 100%;
  min-width: 4rem;
}

.admin-table-empty td {
  text-align: center;
  color: #94a3b8;
  padding: 1.5rem !important;
  font-style: italic;
}

/* Stats */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.stat {
  background: #fff;
  padding: 1rem 0.75rem;
  border-radius: 12px;
  text-align: center;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
}

.stat b {
  display: block;
  font-size: 1.65rem;
  color: var(--brand);
  font-weight: 700;
  line-height: 1.2;
}

.stat span,
.stat {
  font-size: 0.8rem;
  color: #64748b;
}

.stat small.stat-hint {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.72rem;
  color: #94a3b8;
}

.stat-hint--warn {
  color: #b45309;
}

/* Dashboard */
.dash-updated {
  margin: 0.35rem 0 0;
  font-size: 0.78rem;
  color: #94a3b8;
}

.dash-group-title {
  margin: 1.25rem 0 0.65rem;
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
}

.dash-group-title:first-of-type {
  margin-top: 0;
}

.dash-alert {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.65rem 0.9rem;
  border-radius: 10px;
  margin-bottom: 0.65rem;
  font-size: 0.88rem;
}

.dash-alert--warn {
  background: #fff7ed;
  border: 1px solid #fed7aa;
  color: #9a3412;
}

.dash-alert--info {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8;
}

.dash-quick-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}

.dash-shortcut-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.dash-shortcut {
  flex: 1 1 auto;
  min-width: 8.5rem;
}

/* Accodami */
.accodami-settings-card {
  margin-bottom: 1rem;
}

.accodami-settings-grid {
  display: grid;
  gap: 1rem;
}

.accodami-settings-grid .accodami-checkin-field {
  grid-column: 1 / -1;
}

.remote-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.remote-toolbar__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.accodami-settings-card .remote-settings__toggle,
.accodami-settings-card .remote-settings__max {
  margin: 0;
}

.remote-settings__toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
}

.remote-settings__max label {
  display: block;
  font-size: 0.75rem;
  color: #64748b;
  margin-bottom: 0.2rem;
}

.remote-settings__max input {
  width: 5rem;
}

.remote-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  white-space: nowrap;
}

.remote-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.remote-filter.active {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}

.remote-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.remote-table th,
.remote-table td {
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid #e2e8f0;
  text-align: left;
  vertical-align: middle;
}

.remote-table th {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #64748b;
  font-weight: 600;
}

.remote-badge {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
}

.remote-badge--waiting {
  background: #fef3c7;
  color: #92400e;
}

.remote-badge--notified {
  background: #dbeafe;
  color: #1d4ed8;
}

.remote-badge--checked_in {
  background: #dcfce7;
  color: #15803d;
}

.remote-badge--called {
  background: #e0e7ff;
  color: #4338ca;
}

.remote-badge--absent {
  background: #ffedd5;
  color: #c2410c;
}

.remote-badge--cancelled {
  background: #f1f5f9;
  color: #64748b;
}

.remote-sms-ok {
  color: #15803d;
  font-size: 0.75rem;
  margin-left: 0.15rem;
}

/* Operatori / utenti */
.users-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.users-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.users-table th,
.users-table td {
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid #e2e8f0;
  text-align: left;
  vertical-align: middle;
}

.users-table th {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #64748b;
  font-weight: 600;
}

/* Sportelli */
.desks-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.desks-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.desks-table th,
.desks-table td {
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid #e2e8f0;
  text-align: left;
  vertical-align: middle;
}

.desks-table th {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #64748b;
  font-weight: 600;
}

.desk-kind-badge {
  display: inline-block;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  font-size: 0.72rem;
  font-weight: 600;
  background: #e2e8f0;
  color: #334155;
}

.desk-kind-badge--acceptance {
  background: #dbeafe;
  color: #1d4ed8;
}

.desk-kind-badge--draw_room {
  background: #dcfce7;
  color: #15803d;
}

.desk-kind-badge--other {
  background: #fef3c7;
  color: #b45309;
}

.desks-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.desks-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: flex-end;
}

.desk-group-members {
  display: grid;
  gap: 0.45rem;
  max-height: 16rem;
  overflow: auto;
  padding: 0.5rem 0;
}

.desk-group-member {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
}

.users-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  white-space: nowrap;
}

.users-self-badge {
  display: inline-block;
  margin-left: 0.35rem;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 600;
  background: #e0e7ff;
  color: #4338ca;
  text-transform: uppercase;
}

.users-active-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
  font-size: 0.9rem;
}

/* Toolbar */
.admin-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.admin-toolbar__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* Badges */
.admin-badge {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.admin-badge--on {
  background: #dcfce7;
  color: #15803d;
}

.admin-badge--off {
  background: #fee2e2;
  color: #b91c1c;
}

.badge-on { color: #15803d; font-weight: 600; }
.badge-off { color: #b91c1c; font-weight: 600; }

/* URL rows */
.url-row {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  margin-bottom: 0.55rem;
  flex-wrap: wrap;
}

.url-row input {
  flex: 1;
  min-width: 200px;
  padding: 0.5rem 0.65rem;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 0.85rem;
  background: #f8fafc;
}

.url-row label {
  min-width: 100px;
  font-weight: 600;
  font-size: 0.85rem;
  color: #475569;
}

/* Stats section (existing) */
.stats-toolbar { display: flex; flex-wrap: wrap; gap: 0.75rem; align-items: flex-end; }
.stats-toolbar label { font-size: 0.8rem; font-weight: 600; display: block; margin-bottom: 0.25rem; }
.stats-toolbar input { padding: 0.45rem 0.6rem; border: 1px solid #d0d7e2; border-radius: 6px; }
.stats-toolbar select { padding: 0.45rem 0.6rem; border: 1px solid #d0d7e2; border-radius: 6px; min-width: 11rem; }
.stats-compare-toggle { display: flex; align-items: center; gap: 0.4rem; font-size: 0.85rem; color: #475569; padding-bottom: 0.35rem; }
.stats-compare-toggle input { margin: 0; }
.stats-filter-note, .stats-compare-note { font-size: 0.85rem; color: #475569; margin: 0 0 0.75rem; padding: 0.5rem 0.75rem; background: #f8fafc; border-radius: 8px; border: 1px solid #e2e8f0; }
.stat-delta { display: block; margin-top: 0.25rem; font-size: 0.72rem; font-weight: 600; color: #64748b; }
.stat-delta--up { color: #15803d; }
.stat-delta--down { color: #b45309; }
.stat-delta--neutral { color: #64748b; }
.stats-section h3 { margin: 0 0 0.75rem; font-size: 1rem; }
.stats-section-hint { margin: -0.35rem 0 0.75rem; font-size: 0.8rem; color: #64748b; }
.stats-section-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem; margin-bottom: 0.25rem; }
.stats-section-head h3 { margin: 0; }
.stats-daily-toggle { display: flex; align-items: center; gap: 0.35rem; font-size: 0.8rem; color: #475569; }
.stats-daily-wrap { max-height: 420px; overflow: auto; border: 1px solid #e2e8f0; border-radius: 8px; }
.stats-daily-table { margin: 0; }
.stats-daily-table thead th { position: sticky; top: 0; background: #f8fafc; z-index: 1; }
.stats-daily-table tfoot td { font-weight: 700; background: #f1f5f9; border-top: 2px solid #cbd5e1; }
.stats-daily-row--empty td { color: #94a3b8; }
.stats-daily-day { display: block; font-weight: 600; color: #334155; }
.stats-daily-weekday { display: block; font-size: 0.75rem; color: #64748b; font-weight: 500; }
.stats-bar-chart { display: flex; align-items: flex-end; gap: 3px; height: 120px; margin: 0.5rem 0 1.5rem; }
.stats-bar { flex: 1; background: var(--brand); border-radius: 3px 3px 0 0; min-height: 2px; position: relative; }
.stats-bar span { position: absolute; bottom: -1.35rem; left: 50%; transform: translateX(-50%); font-size: 0.65rem; color: #64748b; }
.stats-two-col { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1rem; }
.stats-two-col--nested { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.stats-muted { color: #64748b; font-size: 0.85rem; margin: 0 0 0.75rem; }
.stats-group-title {
  margin: 1.5rem 0 0.75rem;
  font-size: 1.05rem;
  color: #334155;
  font-weight: 700;
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 0.35rem;
}
.stats-group-title:first-of-type { margin-top: 0; }
.stats-presets { display: flex; flex-wrap: wrap; gap: 0.35rem; align-items: flex-end; }
.stats-presets__label { font-size: 0.8rem; font-weight: 600; color: #64748b; width: 100%; margin-bottom: 0.15rem; }
.btn-sm { padding: 0.35rem 0.65rem; font-size: 0.8rem; }
.stats-bar-chart--bookings .stats-bar { background: #0d9488; }

/* Tabelle statistiche — allineamento colonne numeriche */
.stats-table-wrap {
  overflow-x: auto;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.stats-section table,
.stats-wide-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  background: #fff;
  margin: 0;
}

.stats-section th,
.stats-section td,
.stats-wide-table th,
.stats-wide-table td {
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid #eef2f7;
  font-size: 0.88rem;
  vertical-align: middle;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stats-section th,
.stats-wide-table th {
  background: #f8fafc;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #64748b;
}

.stats-section tr:last-child td,
.stats-wide-table tbody tr:last-child td {
  border-bottom: none;
}

.stats-th-text,
.stats-td-text {
  text-align: left;
  white-space: normal;
  word-break: break-word;
  overflow: visible;
  text-overflow: clip;
}

.stats-th-num,
.stats-td-num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.stats-two-col .stats-data-table .stats-th-text,
.stats-two-col .stats-data-table .stats-td-text {
  width: 55%;
}

.stats-two-col .stats-data-table .stats-th-num,
.stats-two-col .stats-data-table .stats-td-num {
  width: 22%;
}

.stats-wide-table .stats-col-prestazione { width: 28%; }
.stats-wide-table .stats-col-narrow { width: 9%; }
.stats-wide-table .stats-col-datetime { width: 14%; }
.stats-wide-table .stats-col-code { width: 10%; }
.stats-wide-table .stats-col-name { width: 14%; }
.stats-wide-table .stats-col-contact { width: 12%; }
.stats-wide-table .stats-col-ticket { width: 8%; }

.stat--highlight b { color: #0d9488; }

.signage-form input,
.signage-form textarea,
.signage-form select {
  width: 100%;
  margin-bottom: 0.5rem;
  padding: 0.5rem;
  border: 1px solid #d0d7e2;
  border-radius: 6px;
}

/* ——— Slot e code ——— */
.bs-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 0.65rem;
  margin-bottom: 1.25rem;
}

.bs-summary-item {
  background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.75rem 0.9rem;
}

.bs-summary-item strong {
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  margin-bottom: 0.25rem;
}

.bs-summary-item span {
  font-size: 1rem;
  font-weight: 700;
  color: #0f172a;
}

.bs-mode-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin-bottom: 1rem;
}

@media (max-width: 800px) {
  .bs-mode-grid {
    grid-template-columns: 1fr;
  }
}

.bs-mode-card {
  text-align: left;
  padding: 0.85rem 1rem;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}

.bs-mode-card:hover {
  border-color: color-mix(in srgb, var(--brand) 40%, #e2e8f0);
  background: #f8fafc;
}

.bs-mode-card.active {
  border-color: var(--brand);
  background: color-mix(in srgb, var(--brand) 8%, #fff);
  box-shadow: 0 0 0 1px var(--brand);
}

.bs-mode-card strong {
  display: block;
  font-size: 0.92rem;
  color: #0f172a;
  margin-bottom: 0.25rem;
}

.bs-mode-card span {
  font-size: 0.78rem;
  color: #64748b;
  line-height: 1.35;
}

.bs-slot-preview {
  background: #0f172a;
  color: #e2e8f0;
  border-radius: 10px;
  padding: 0.85rem 1rem;
  font-family: ui-monospace, monospace;
  font-size: 0.82rem;
  line-height: 1.5;
  margin-top: 0.75rem;
}

.bs-slot-preview em {
  color: #94a3b8;
  font-style: normal;
}

.bs-section {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid #eef2f7;
}

.bs-section:first-of-type {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

.bs-route-services {
  min-width: 12rem;
  max-width: 100%;
}

.bs-route-services option {
  padding: 0.2rem 0.35rem;
}

.bs-route-add-panel {
  margin-bottom: 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  background: #f8fbff;
}

.bs-route-add-checkboxes {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin: 0.5rem 0 0;
}

.bs-route-add-checkboxes label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.92rem;
  cursor: pointer;
}

.bs-svc-row--off td {
  opacity: 0.55;
}

.bs-svc-row--off .bs-effective {
  color: #94a3b8;
}

.bs-svc-online-wrap {
  text-align: center;
}

.bs-route-label-text {
  font-weight: 600;
  color: #0f172a;
}

.bs-route-services-text {
  color: #475569;
  font-size: 0.88rem;
  line-height: 1.35;
}

.bs-cat-chip {
  padding: 0.25rem 0.55rem;
  border-radius: 999px;
  border: 1px dashed #cbd5e1;
  background: #f8fafc;
  font-size: 0.78rem;
  color: #475569;
  cursor: default;
}

.bs-cat-chip--click {
  cursor: pointer;
  border-style: solid;
  border-color: color-mix(in srgb, var(--brand) 35%, #cbd5e1);
}

.bs-cat-chip--click:hover {
  background: color-mix(in srgb, var(--brand) 10%, #fff);
}

.bs-queue-code {
  display: inline-block;
  font-family: ui-monospace, monospace;
  font-size: 0.82rem;
  background: #f1f5f9;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  color: #334155;
}

.tr-totem-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  padding: 1rem;
  background: #0f172a;
  border-radius: 8px;
  min-height: 4rem;
  margin-bottom: 1rem;
}

.tr-totem-preview .service-tile {
  cursor: default;
  pointer-events: none;
  min-width: 8rem;
  max-width: 12rem;
}

.tr-show-codes-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0 0 0.35rem;
  font-weight: 500;
}

.tr-totem-preview-empty {
  color: #94a3b8;
  font-size: 0.9rem;
  padding: 0.5rem;
}

.tr-overview {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.tr-overview-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  font-size: 0.82rem;
  background: #f1f5f9;
  color: #334155;
  border: 1px solid #e2e8f0;
}

.tr-overview-pill strong {
  font-weight: 700;
  color: #0f172a;
}

.tr-section {
  margin-bottom: 1rem;
}

.tr-section-head {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.tr-section-num {
  flex-shrink: 0;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.1rem;
}

.tr-section-head .admin-subhead {
  margin: 0 0 0.25rem;
}

.tr-section-lead {
  margin: 0;
  max-width: 42rem;
}

.tr-add-queue-details {
  margin-bottom: 1rem;
  border: 1px dashed #cbd5e1;
  border-radius: 8px;
  padding: 0.5rem 0.75rem;
  background: #f8fafc;
}

.tr-add-queue-summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.88rem;
  color: #334155;
  user-select: none;
}

.tr-add-queue-form {
  margin-top: 0.75rem;
  align-items: end;
}

.tr-queues-table .tr-col-groups th {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  font-weight: 700;
  padding-bottom: 0.25rem;
  border-bottom: none;
}

.tr-col-group--totem {
  background: color-mix(in srgb, #3b82f6 6%, #fff);
}

.tr-col-group--call {
  background: color-mix(in srgb, #f59e0b 8%, #fff);
}

.tr-col-group--desk {
  background: color-mix(in srgb, #8b5cf6 6%, #fff);
}

.tr-col-group--state {
  background: #f8fafc;
}

.tr-queues-table tbody td:nth-child(-n+5) {
  background: color-mix(in srgb, #3b82f6 3%, #fff);
}

.tr-queues-table tbody td:nth-child(n+6):nth-child(-n+7) {
  background: color-mix(in srgb, #f59e0b 5%, #fff);
}

.tr-queues-table tbody td:nth-child(8) {
  background: color-mix(in srgb, #8b5cf6 4%, #fff);
}

.tr-queues-table.mode-global tbody td:nth-child(n+6):nth-child(-n+7),
.tr-queues-table.mode-global .tr-col-group--call {
  background: color-mix(in srgb, #f59e0b 12%, #fff);
}

.tr-th-dimmed {
  opacity: 0.65;
}

.tr-call-flow-explainer {
  margin: 1rem 0;
  padding: 0.85rem 1rem;
  border-radius: 8px;
  border-left: 4px solid var(--brand);
  background: color-mix(in srgb, var(--brand) 6%, #fff);
  font-size: 0.88rem;
  line-height: 1.45;
  color: #334155;
}

.tr-call-flow-explainer strong {
  display: block;
  margin-bottom: 0.35rem;
  color: #0f172a;
}

.tr-call-flow-explainer em {
  font-style: normal;
  color: #64748b;
  font-size: 0.82rem;
}

.tr-booking-priority-field {
  margin-top: 0.5rem;
  padding-top: 1rem;
  border-top: 1px solid #e2e8f0;
}

.tr-booking-priority-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

.tr-priority-badge {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  background: #dbeafe;
  color: #1d4ed8;
  margin-left: 0.35rem;
  vertical-align: middle;
}

.tr-actions-cell {
  white-space: nowrap;
  min-width: 5.5rem;
}

.tr-delete-blocked {
  opacity: 0.45;
  cursor: not-allowed;
  font-size: 0.78rem;
}

.tr-queues-table-wrap {
  overflow-x: auto;
}

.site-checkin-card .tr-rec-badge {
  display: inline-block;
  margin-top: 0.35rem;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #059669;
  letter-spacing: 0.03em;
}

.tr-order-cell {
  white-space: nowrap;
}

.tr-order-cell .btn-sm {
  min-width: 2rem;
  padding: 0.25rem 0.4rem;
  line-height: 1.1;
}

.tr-order-cell .btn-sm + .btn-sm {
  margin-left: 0.15rem;
}

.bs-effective {
  font-size: 0.78rem;
  color: #64748b;
  margin-top: 0.15rem;
}

.admin-sticky-actions {
  position: sticky;
  bottom: 0;
  margin: 1.25rem -1.25rem -1.15rem;
  padding: 0.85rem 1.25rem;
  background: linear-gradient(180deg, rgba(255,255,255,0.92) 0%, #fff 30%);
  border-top: 1px solid #e2e8f0;
  border-radius: 0 0 12px 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  align-items: center;
  justify-content: space-between;
  backdrop-filter: blur(6px);
}

.admin-sticky-actions p {
  margin: 0;
  font-size: 0.82rem;
  color: #64748b;
}

/* Toast */
.admin-toast {
  position: fixed;
  bottom: 1.25rem;
  right: 1.25rem;
  z-index: 9999;
  padding: 0.75rem 1.1rem;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 500;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.18);
  animation: adminToastIn 0.25s ease;
}

.admin-toast--ok {
  background: #15803d;
  color: #fff;
}

.admin-toast--err {
  background: #b91c1c;
  color: #fff;
}

.admin-toast.hidden {
  display: none;
}

@keyframes adminToastIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

/* Login */
.login-form {
  max-width: 400px;
  margin: 3rem auto;
  padding: 2rem;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 4px 24px rgba(15, 23, 42, 0.08);
}

.page-admin .matrix-credit {
  text-align: center;
  padding: 1rem;
}

/* ——— Sede e link ——— */
.site-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
  gap: 1rem;
  align-items: start;
}

@media (max-width: 960px) {
  .site-layout {
    grid-template-columns: 1fr;
  }
}

.site-layout__main,
.site-layout__aside {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.site-layout__aside .admin-card {
  position: sticky;
  top: 0.5rem;
}

.site-summary {
  margin-bottom: 1rem;
}

.site-toggle-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.65rem;
}

.site-voice-repeats {
  grid-column: 1 / -1;
  max-width: 280px;
}

.site-voice-repeats .admin-hint {
  display: block;
  margin-top: 0.35rem;
  color: #64748b;
  font-size: 0.82rem;
}

.site-toggle {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  padding: 0.85rem 1rem;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.site-toggle:has(input:checked) {
  border-color: var(--brand);
  background: color-mix(in srgb, var(--brand) 6%, #fff);
}

.site-toggle input {
  margin-top: 0.2rem;
  flex-shrink: 0;
  accent-color: var(--brand);
}

.site-toggle__body {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.site-toggle__body strong {
  font-size: 0.92rem;
  color: #0f172a;
}

.site-toggle__body small {
  font-size: 0.78rem;
  color: #64748b;
  line-height: 1.35;
}

.site-checkin-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

@media (max-width: 640px) {
  .site-checkin-grid {
    grid-template-columns: 1fr;
  }
}

.site-checkin-card {
  text-align: left;
  padding: 0.85rem 1rem;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.site-checkin-card:hover {
  border-color: color-mix(in srgb, var(--brand) 35%, #e2e8f0);
}

.site-checkin-card.active {
  border-color: var(--brand);
  background: color-mix(in srgb, var(--brand) 8%, #fff);
}

.site-checkin-card strong {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
}

.site-checkin-card span {
  font-size: 0.78rem;
  color: #64748b;
  line-height: 1.35;
}

.site-display-layout-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

@media (max-width: 640px) {
  .site-display-layout-grid {
    grid-template-columns: 1fr;
  }
}

.site-display-layout-card {
  text-align: left;
  padding: 0.85rem 1rem;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.site-display-layout-card:hover {
  border-color: color-mix(in srgb, var(--brand) 35%, #e2e8f0);
}

.site-display-layout-card.active {
  border-color: var(--brand);
  background: color-mix(in srgb, var(--brand) 8%, #fff);
}

.site-display-layout-card strong {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
}

.site-display-layout-card span {
  font-size: 0.78rem;
  color: #64748b;
  line-height: 1.35;
}

.site-display-layout-preview {
  height: 4.5rem;
  border-radius: 8px;
  margin-bottom: 0.65rem;
  border: 1px solid #e2e8f0;
  background: #0f172a;
  position: relative;
  overflow: hidden;
}

.site-display-layout-preview--classic::before,
.site-display-layout-preview--classic::after {
  content: "";
  position: absolute;
  border-radius: 3px;
}

.site-display-layout-preview--classic::before {
  left: 8%;
  top: 12%;
  width: 58%;
  height: 76%;
  background: linear-gradient(180deg, #1e293b 0%, #0f172a 100%);
  border: 1px solid #334155;
}

.site-display-layout-preview--classic::after {
  right: 8%;
  top: 12%;
  width: 24%;
  height: 76%;
  background: #1e293b;
  border: 1px solid #334155;
}

.site-display-layout-preview--split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 6px;
  box-sizing: border-box;
}

.site-display-layout-preview--split::before,
.site-display-layout-preview--split::after {
  content: "";
  border-radius: 4px;
}

.site-display-layout-preview--split::before {
  background: linear-gradient(180deg, #14532d 0%, #052e16 100%);
  box-shadow: inset 0 0 0 1px #22c55e44;
}

.site-display-layout-preview--split::after {
  background: #1e293b;
  border: 1px solid #334155;
}

.site-display-layout-preview--board {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 6px;
  box-sizing: border-box;
  background: #fff;
  border: 1px solid #cbd5e1;
}

.site-display-layout-preview--board::before {
  content: "TICKET · SPORTELLO";
  font-size: 6px;
  font-weight: 700;
  color: #1e40af;
  letter-spacing: 0.04em;
  text-align: center;
  padding: 2px 0 1px;
}

.site-display-layout-preview--board::after {
  content: "";
  flex: 1;
  border-radius: 2px;
  background: linear-gradient(
    180deg,
    var(--brand, #3366cc) 0%,
    var(--brand, #3366cc) 22%,
    #fff 22%,
    #fff 26%,
    var(--brand, #3366cc) 26%,
    var(--brand, #3366cc) 48%,
    #fff 48%,
    #fff 52%,
    var(--brand, #3366cc) 52%,
    var(--brand, #3366cc) 74%,
    #fff 74%,
    #fff 78%,
    var(--brand, #3366cc) 78%
  );
}

.site-hours-preview {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.75rem 1rem;
  font-size: 0.85rem;
  color: #475569;
  margin: 0.75rem 0;
  line-height: 1.5;
}

.site-hours-preview strong {
  color: #0f172a;
}

.site-weekdays {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.site-weekday-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  border: 1px solid #cbd5e1;
  background: #fff;
  font-size: 0.82rem;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
}

.site-weekday-pill:has(input:checked) {
  background: color-mix(in srgb, var(--brand) 12%, #fff);
  border-color: var(--brand);
  font-weight: 600;
}

.site-weekday-pill input {
  accent-color: var(--brand);
}

.site-mono {
  font-family: ui-monospace, monospace;
  font-size: 0.85rem;
}

.site-sync-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  margin-top: 0.5rem;
}

.site-sync-row p {
  margin: 0;
}

.closures-editor {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  margin-bottom: 1rem;
}

.closures-section-title {
  margin: 0 0 0.5rem;
  font-size: 0.92rem;
  font-weight: 600;
}

.closures-add-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.closures-date-input {
  min-height: 2.25rem;
  padding: 0.35rem 0.5rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: inherit;
}

.closures-range-sep {
  color: var(--muted);
  font-weight: 600;
}

.closures-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.closures-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.45rem 0.65rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.02);
  font-size: 0.9rem;
}

.closures-iso {
  color: var(--muted);
  font-family: ui-monospace, monospace;
  font-size: 0.8rem;
}

.closures-list button {
  flex-shrink: 0;
}

.closures-empty {
  margin: 0.25rem 0 0;
}

.closures-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.75rem 0;
}

.closures-import-panel,
.closures-url-panel {
  margin-top: 0.75rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.65rem 0.85rem;
  background: rgba(255, 255, 255, 0.02);
}

.closures-import-panel summary,
.closures-url-panel summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--brand);
}

.closures-import-panel textarea {
  width: 100%;
  margin-top: 0.65rem;
}

.closures-url-panel .admin-field {
  margin-top: 0.75rem;
}

.site-inline-link {
  background: none;
  border: none;
  padding: 0;
  color: var(--brand);
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
  font-size: inherit;
}

.site-url-group {
  margin-bottom: 1.1rem;
}

.site-url-group:last-child {
  margin-bottom: 0;
}

.site-url-group__title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
  margin: 0 0 0.5rem;
}

.site-url-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.65rem 0.75rem;
  margin-bottom: 0.45rem;
}

.site-url-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.35rem;
}

.site-url-card__head strong {
  font-size: 0.88rem;
  color: #0f172a;
}

.site-url-card__badge {
  font-size: 0.68rem;
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  background: #e2e8f0;
  color: #475569;
  font-weight: 600;
}

.site-url-card input {
  width: 100%;
  padding: 0.4rem 0.5rem;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 0.78rem;
  background: #fff;
  color: #334155;
  margin-bottom: 0.4rem;
}

.site-url-card__actions {
  display: flex;
  gap: 0.35rem;
}

.site-url-card__actions .btn {
  flex: 1;
  font-size: 0.78rem;
  padding: 0.35rem 0.5rem;
}

.site-tokens {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.site-token-row {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.site-token-row label {
  font-size: 0.72rem;
  font-weight: 600;
  color: #64748b;
  text-transform: uppercase;
}

.site-token-row code {
  font-size: 0.75rem;
  background: #f1f5f9;
  padding: 0.35rem 0.5rem;
  border-radius: 6px;
  word-break: break-all;
  color: #334155;
}

.site-links-card .admin-card__lead,
.site-tokens-card .admin-card__lead {
  margin-bottom: 0.85rem;
}

.survey-preview-block {
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid #e2e8f0;
}
.survey-preview-block__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1rem;
  margin-bottom: 0.65rem;
}
.survey-preview-block__head strong {
  font-size: 0.92rem;
  color: #334155;
}
.survey-preview-frame-wrap {
  background: linear-gradient(160deg, #eef4fa 0%, #f8fafc 100%);
  border: 1px solid #dbe3ee;
  border-radius: 12px;
  padding: 0.65rem;
  overflow: hidden;
}
.survey-preview-frame-wrap iframe {
  display: block;
  width: 100%;
  height: min(52vw, 380px);
  min-height: 260px;
  max-height: 420px;
  border: none;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08);
}
.survey-preview-block__actions {
  margin-top: 0.65rem;
}

#site-booking-block.site-block-off {
  opacity: 0.55;
  pointer-events: none;
}

#site-hours-block.site-block-off {
  opacity: 0.55;
  pointer-events: none;
}

.platform-bar {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding: 0.65rem 1.25rem;
  background: #1e293b;
  color: #e2e8f0;
  border-bottom: 1px solid #334155;
}

.platform-bar label {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
}

.platform-bar select {
  min-width: 14rem;
  max-width: 28rem;
  padding: 0.4rem 0.55rem;
  border-radius: 8px;
  border: 1px solid #475569;
  background: #0f172a;
  color: #f8fafc;
}

.platform-bar .btn-sm {
  padding: 0.35rem 0.75rem;
  font-size: 0.85rem;
}

.login-hint {
  font-size: 0.82rem;
  color: #64748b;
  margin: -0.5rem 0 0.75rem;
}

.platform-dialog {
  border: none;
  border-radius: 12px;
  padding: 0;
  max-width: 28rem;
  width: calc(100% - 2rem);
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.25);
}

.platform-dialog form {
  padding: 1.25rem 1.35rem 1.35rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.platform-dialog h2 {
  margin: 0 0 0.25rem;
  font-size: 1.15rem;
}

.platform-dialog input,
.platform-dialog select {
  margin-bottom: 0.35rem;
  padding: 0.45rem 0.55rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
}

.platform-dialog__actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.platform-dialog--wide {
  max-width: 36rem;
}

.platform-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.65rem 0.85rem;
  margin-bottom: 0.75rem;
}

.platform-form-full {
  grid-column: 1 / -1;
}

.platform-provision-fieldset {
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 0.75rem 0.85rem 0.85rem;
  margin: 0 0 0.75rem;
}

.platform-provision-fieldset legend {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
  padding: 0 0.35rem;
}

.platform-provision-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
}

@media (max-width: 640px) {
  .platform-provision-grid {
    grid-template-columns: 1fr 1fr;
  }
  .platform-form-grid {
    grid-template-columns: 1fr;
  }
}

.platform-count {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.platform-count__label {
  font-size: 0.78rem;
  font-weight: 600;
  color: #475569;
}

.platform-count input {
  width: 100%;
  padding: 0.4rem 0.5rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  box-sizing: border-box;
}

.platform-count--lab.hidden {
  display: none;
}

.new-site-result-list {
  margin: 0.75rem 0 0;
  padding: 0;
  list-style: none;
  max-height: 16rem;
  overflow-y: auto;
}

.new-site-result-list li {
  padding: 0.35rem 0;
  border-bottom: 1px solid #f1f5f9;
  font-size: 0.85rem;
}

.new-site-result-list code {
  font-size: 0.75rem;
  word-break: break-all;
}

.clients-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.clients-content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.clients-group__title {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
  color: #0f172a;
}

.clients-table-wrap {
  overflow-x: auto;
}

.clients-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.clients-table th,
.clients-table td {
  padding: 0.55rem 0.65rem;
  border-bottom: 1px solid #e2e8f0;
  text-align: left;
  vertical-align: top;
}

.clients-table th {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #64748b;
}

.clients-table tr.is-inactive td {
  opacity: 0.55;
}

.clients-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.clients-links a {
  font-size: 0.78rem;
}

.clients-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.clients-badge {
  display: inline-block;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
}

.clients-badge--on {
  background: #dcfce7;
  color: #166534;
}

.clients-badge--off {
  background: #fee2e2;
  color: #991b1b;
}

.clients-badge--org {
  background: #e0f2fe;
  color: #0369a1;
}

.account-card {
  max-width: 28rem;
}

.account-password-form {
  display: grid;
  gap: 0.65rem;
}

.account-password-form input {
  width: 100%;
  padding: 0.55rem 0.65rem;
  border: 1px solid #d0d7e2;
  border-radius: 6px;
}

.account-form-actions {
  margin-top: 0.35rem;
}

.credentials-filter-input {
  flex: 1;
  min-width: 12rem;
  max-width: 22rem;
}

.credentials-table td:last-child {
  text-align: right;
}

.device-token-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.device-token-rotate-details {
  margin-top: 0.85rem;
  font-size: 0.88rem;
}

.device-token-rotate-details summary {
  cursor: pointer;
  color: var(--brand, #0066b3);
  font-weight: 600;
}

.device-token-rotate-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.35rem 0.75rem;
  margin: 0.65rem 0;
}

.device-token-legacy-label {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0.35rem 0 0.65rem;
  font-size: 0.85rem;
}
