/* ── VERWALTUNG (Inhaltsansicht) ──────────────────────────────────
   Firmendaten, Backend Benutzer, Registrierte Benutzer, Freigeschaltete
   Benutzer, Monitoring. Die Bausteine kommen aus profile.css (.pf-*) und
   team.css (.tm-*); hier nur, was Liste, Suche, Detail und Protokoll
   zusätzlich brauchen.                                              */

/* Die Kontenliste braucht mehr Breite als die Textseiten */
#content-body.admin-wide {
  max-width: min(960px, calc(100vw - 80px));
}

.pf-f textarea {
  width: 100%;
  min-height: 72px;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 300;
  line-height: 1.5;
  color: var(--black);
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  padding: 6px 0;
  outline: none;
  resize: vertical;
}
.pf-f textarea:focus {
  border-bottom-color: var(--black);
}
.pf-f [aria-invalid='true'] {
  border-bottom-color: var(--red);
}

/* ── Liste ── */
.adm-search {
  display: block;
  max-width: 420px;
}
.adm-row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 24px;
  width: 100%;
  padding: 9px 0;
  text-align: left;
  font: inherit;
  background: none;
  border: none;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
}
.adm-row:hover .tm-email {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.adm-badge {
  margin-left: auto;
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--mid);
  white-space: nowrap;
}
.adm-badge.off {
  color: var(--red);
}
.adm-pager {
  display: flex;
  align-items: baseline;
  gap: 24px;
  margin-top: 18px;
  font-family: var(--sans);
  font-size: 13px;
  color: var(--mid);
}
.adm-pager .pf-link:disabled {
  opacity: 0.3;
  cursor: default;
}

/* ── Detail ── */
#cu-back {
  margin-bottom: 28px;
}
.adm-lines {
  white-space: pre-line;
}
.adm-form {
  margin-top: 24px;
}

/* ── Freigeschaltete Benutzer ── */
.al-form {
  margin: 8px 0 28px;
}
.al-form .pf-f {
  display: block;
}
/* Ohne Haken bleibt die Liste bearbeitbar, sie gilt nur nicht */
#allowlist-view.al-off #al-list {
  opacity: 0.55;
}

/* ── Monitoring ── */
.mo-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 36px;
}
#content-body #monitoring-view .mo-top .pf-hint {
  margin: 0;
}
/* Kennzahlen als Kacheln: Beschriftung wie .pf-dl, die Zahl groß */
.pf-dl.mo-stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px 24px;
}
.mo-stats dd {
  font-family: var(--serif);
  font-size: 30px;
  font-weight: 400;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}
@media (max-width: 600px) {
  .pf-dl.mo-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Belegung des Datenträgers: Konten, Anderes, frei */
#mo-disk-bar {
  margin-top: 26px;
}
.mo-bar {
  display: flex;
  height: 8px;
  background: var(--grau-200);
  overflow: hidden;
}
.mo-bar-accounts {
  background: var(--black);
}
.mo-bar-other {
  background: var(--grau-400);
}
.mo-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 22px;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--mid);
}
.mo-legend li {
  display: flex;
  align-items: center;
  gap: 8px;
}
.mo-key {
  display: inline-block;
  width: 10px;
  height: 10px;
}
.mo-key-free {
  background: var(--grau-200);
}

/* Konten je Plan — auf dem Telefon lässt sich die Tabelle seitlich schieben */
.mo-table-wrap {
  overflow-x: auto;
}
.mo-table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 300;
  color: var(--black);
}
.mo-table th,
.mo-table td {
  padding: 9px 0;
  border-bottom: 1px solid var(--border);
  text-align: right;
  font-weight: 300;
  font-variant-numeric: tabular-nums;
}
.mo-table th:first-child {
  text-align: left;
}
.mo-table th + :is(th, td),
.mo-table td + td {
  padding-left: 16px;
}
.mo-table thead th {
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--mid);
}
.mo-table .adm-badge {
  margin-left: 10px;
}
.mo-table tfoot :is(th, td) {
  border-bottom: none;
  font-weight: 400;
}
@media (max-width: 600px) {
  .mo-table thead th {
    letter-spacing: 0.1em;
  }
  .mo-table th + :is(th, td),
  .mo-table td + td {
    padding-left: 10px;
  }
}
