/* Login, Passwort ändern, Benutzerverwaltung — baut auf style.css auf */

input[type="password"] {
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 8px 12px;
  color: var(--text-primary);
  font-family: 'Outfit', sans-serif;
  font-size: 14px;
  width: 100%;
  transition: border-color 0.15s;
}

/* ─── Einzelkarte (Login, Passwort, Kein Zugriff) ─── */
.auth-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
}
.auth-box { width: 100%; max-width: 380px; }
.auth-logo { text-align: center; margin-bottom: 28px; }
.auth-logo-title { font-size: 36px; font-weight: 700; color: var(--accent); letter-spacing: -1px; }
.auth-logo-sub { color: var(--text-secondary); font-size: 14px; margin-top: 4px; }
.auth-title { margin: 0 0 18px; font-size: 16px; font-weight: 600; }
.auth-label { font-size: 13px; color: var(--text-secondary); display: block; margin: 0 0 6px; }
.auth-box input + .auth-label { margin-top: 14px; }
.auth-text { font-size: 14px; color: var(--text-secondary); line-height: 1.5; margin: 0 0 14px; }
.auth-error {
  margin: 14px 0 0;
  padding: 8px 10px;
  background: rgba(255, 107, 107, 0.1);
  border: 1px solid rgba(255, 107, 107, 0.25);
  border-radius: 6px;
  color: var(--danger);
  font-size: 13px;
}
.auth-success {
  margin: 0 0 16px;
  padding: 8px 10px;
  background: rgba(81, 207, 102, 0.1);
  border: 1px solid rgba(81, 207, 102, 0.25);
  border-radius: 6px;
  color: var(--success);
  font-size: 13px;
}
.auth-submit { width: 100%; justify-content: center; margin-top: 18px; text-decoration: none; }
.auth-hint { text-align: center; font-size: 13px; color: var(--text-muted); margin-top: 16px; }
.auth-hint a { color: var(--text-secondary); }

/* ─── Benutzerverwaltung ─── */
.admin-page { min-height: 100vh; display: flex; flex-direction: column; }
.admin-header {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.admin-brand { display: flex; align-items: center; gap: 10px; }
.admin-brand-title { font-size: 20px; font-weight: 700; color: var(--accent); text-decoration: none; }
.admin-brand-sub { color: var(--text-secondary); font-size: 14px; }
.admin-header-actions { display: flex; align-items: center; gap: 8px; }
.admin-header-actions .btn { text-decoration: none; }
.admin-user { color: var(--text-secondary); font-size: 13px; margin-right: 4px; }
.admin-main { flex: 1; padding: 24px; max-width: 1200px; width: 100%; margin: 0 auto; }
.admin-section { margin-bottom: 20px; }
.admin-h2 { margin: 0 0 14px; font-size: 16px; font-weight: 600; }
.admin-msg { margin: 0 0 16px; }

.admin-notice { margin-bottom: 20px; border-color: rgba(81, 207, 102, 0.35); }
.admin-notice-title { font-size: 14px; margin-bottom: 10px; }
.admin-notice-text { font-size: 13px; color: var(--text-secondary); margin-top: 10px; }
.admin-otp { display: flex; align-items: center; gap: 10px; }
.admin-otp code {
  font-size: 20px;
  letter-spacing: 1px;
  padding: 6px 12px;
  border-radius: 6px;
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
}

.admin-create { display: flex; flex-direction: column; gap: 14px; }
.admin-field { max-width: 320px; }
.admin-tools { border: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.admin-tools legend { padding: 0; margin-bottom: 6px; width: 100%; }
.admin-check { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; cursor: pointer; white-space: nowrap; }
.admin-check input { width: auto; margin: 0; }
.admin-check-admin { color: var(--text-secondary); }

.admin-table-wrap { overflow-x: auto; }
.admin-table td { vertical-align: top; }
.admin-tool-checks { display: flex; flex-wrap: wrap; gap: 4px 14px; max-width: 520px; }
.admin-name { font-weight: 600; white-space: nowrap; }
.admin-sub { font-size: 12px; color: var(--text-muted); font-weight: 400; }
.admin-nowrap { white-space: nowrap; }
.admin-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.admin-actions form { margin: 0; }
.admin-row-inactive td { opacity: 0.55; }
.admin-badge-self { background: rgba(108, 140, 255, 0.15); color: var(--accent); }
.admin-ok { color: var(--success); }
.admin-danger { color: var(--danger); }
.admin-agent { max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; color: var(--text-muted); }

@media (max-width: 640px) {
  .admin-main { padding: 16px; }
  .admin-header { padding: 12px 16px; }
}

/* ─── Mein Konto (/konto) ─── */
[x-cloak] { display: none !important; }
.konto-main { max-width: 820px; }
.konto-error { display: flex; align-items: center; gap: 8px; }
.konto-x { margin-left: auto; background: none; border: none; cursor: pointer; color: var(--danger); font-size: 13px; padding: 2px 4px; }
.konto-ok { margin-bottom: 16px; }
.konto-muted { font-size: 13px; color: var(--text-muted); }
.konto-note { margin: 10px 0 0; font-size: 12px; }
.konto-empty { font-size: 14px; color: var(--text-secondary); padding: 8px 0; }
.konto-world + .konto-world { margin-top: 14px; }
.konto-world-title {
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--text-secondary); margin-bottom: 6px;
}
.konto-acc {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 8px 12px; border: 1px solid var(--border); border-radius: 6px; background: var(--bg-tertiary);
}
.konto-acc + .konto-acc { margin-top: 6px; }
.konto-acc-name { font-weight: 600; font-size: 14px; }
.konto-role {
  font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 3px;
  border: 1px solid var(--border-light); color: var(--text-secondary);
}
.konto-default { font-size: 12px; font-weight: 600; color: var(--warning); }
.konto-grow { flex: 1; }
.konto-actions { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.konto-danger-text { font-size: 12px; color: var(--danger); }
.konto-form { display: flex; gap: 10px; flex-wrap: wrap; align-items: flex-end; }
.konto-field { display: flex; flex-direction: column; min-width: 0; }
.konto-field .auth-label { margin-bottom: 5px; }
.konto-field-world { width: 170px; }
.konto-field-role { width: 130px; }
.konto-form select, .konto-form input[type="text"] { height: 38px; }
.konto-suggest-wrap { position: relative; }
.konto-suggest-list {
  position: absolute; top: 100%; left: 0; right: 0; z-index: 50; margin-top: 4px;
  background: var(--bg-primary); border: 1px solid var(--border-light); border-radius: 6px;
  max-height: 280px; overflow-y: auto; box-shadow: 0 10px 28px rgba(0,0,0,0.55);
}
.konto-suggest-item {
  display: flex; justify-content: space-between; gap: 10px; align-items: baseline;
  padding: 8px 12px; cursor: pointer; font-size: 13px; border-bottom: 1px solid var(--border);
}
.konto-suggest-item:last-child { border-bottom: none; }
.konto-suggest-item:hover { background: #1a201c; }
.konto-suggest-item.active { background: #1f3a2a; box-shadow: inset 3px 0 0 var(--accent); }
.konto-suggest-name { font-weight: 600; }
.konto-suggest-meta { font-size: 11px; color: var(--text-muted); white-space: nowrap; }
.konto-suggest-empty { padding: 10px 12px; font-size: 12px; color: var(--text-muted); }
.konto-back { color: var(--text-secondary); font-size: 13px; }
.konto-back:hover { color: var(--accent); }
/* .card hat backdrop-filter (eigener Stacking-Context) — Vorschlagsliste über der nächsten Karte halten */
.konto-main .admin-section:has(.konto-suggest-list) { position: relative; z-index: 5; }
