/* ============================================================
   system_waechter.css — System-Wächter Sektion im Admin-Bereich.
   2026-05-26 Brand6: Wichtig — die sw-* Klassen werden SOWOHL von
   System-Wächter (dunkle Card .sys-waechter-sektion) ALS AUCH von
   Smart-Wächter (helle Card .smart-waechter-sektion) genutzt.
   → Helle Schrift NUR scopen auf System-Wächter; Smart-Wächter
     erbt die Default-Texte aus admin.css (dunkel auf hell).
   ============================================================ */

/* ---------- Wrapper ---------- */
.sys-waechter-sektion {
  border-left: 3px solid #3b82f6;
  background: #1a2030;
  border-radius: 8px;
  padding: 16px 18px;
  margin-bottom: 18px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.18);
  color: #f1f5f9;
}

/* ---------- Shared (greift in beiden Cards) ---------- */
/* Layout-Regeln, die in beiden Cards identisch funktionieren */
.sw-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  gap: 12px;
  flex-wrap: wrap;
}

.sw-title {
  font-size: 18px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.sw-badges {
  display: flex;
  gap: 10px;
  align-items: center;
}

.sw-status-badge {
  padding: 4px 12px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.2px;
}

.sw-info {
  margin: 8px 0 4px 0;
  font-size: 13px;
  line-height: 1.5;
}

.sw-fail-count { color: #ef4444; font-weight: 600; }

.sw-table {
  width: 100%;
  margin-top: 8px;
  font-size: 13px;
  border-collapse: collapse;
}

.sw-table th,
.sw-table td {
  padding: 8px 10px;
  text-align: left;
}

.sw-table th {
  font-weight: 700;
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.sw-row-ok    td:nth-child(2) { color: #16a34a; font-weight: 600; }
.sw-row-fail  td:nth-child(2) { color: #dc2626; font-weight: 700; }
.sw-row-warn  td:nth-child(2) { color: #d97706; font-weight: 600; }

.sw-details,
.sw-history { margin-top: 12px; }

.sw-details summary,
.sw-history summary {
  cursor: pointer;
  padding: 6px 0;
  user-select: none;
  font-size: 13px;
  font-weight: 500;
}

.sw-details summary:hover,
.sw-history summary:hover { color: #3b82f6; }

.sw-laden {
  padding: 20px;
  text-align: center;
  opacity: 0.7;
  font-size: 13px;
}

.sw-fehler {
  padding: 14px;
  color: #dc2626;
  font-size: 13px;
  background: rgba(239, 68, 68, 0.08);
  border-radius: 6px;
}

.sw-kein-stand {
  padding: 14px;
  font-size: 13px;
  font-style: italic;
}

/* Button */
.sw-btn {
  background: #3b82f6;
  color: #fff;
  border: none;
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}
.sw-btn:hover:not(:disabled) { background: #2563eb; }
.sw-btn:disabled { opacity: 0.6; cursor: not-allowed; }

.sw-email-hint {
  display: inline-block;
  margin-left: 10px;
  font-size: 12px;
  opacity: 0.7;
}

/* ============================================================
   ===== System-Wächter (DARK CARD) =============================
   Alle sw-* Klassen INNERHALB der dunklen Card → helle Schrift.
   ============================================================ */
.sys-waechter-sektion .sw-title           { color: #f1f5f9; }
.sys-waechter-sektion .sw-info            { color: #cbd5e1; }
.sys-waechter-sektion .sw-fail-count      { color: #f87171; }
.sys-waechter-sektion .sw-ok              { background: rgba(34,197,94,0.18);  color: #4ade80; }
.sys-waechter-sektion .sw-warn            { background: rgba(234,179,8,0.18);  color: #fbbf24; }
.sys-waechter-sektion .sw-fail            { background: rgba(239,68,68,0.18);  color: #f87171; }
.sys-waechter-sektion .sw-fail-row        { padding: 8px 12px; background: rgba(239,68,68,0.10); border-left: 3px solid #ef4444; border-radius: 6px; margin: 4px 0; font-size: 13px; color: #f1f5f9; }
.sys-waechter-sektion .sw-table th,
.sys-waechter-sektion .sw-table td        { border-bottom: 1px solid rgba(255,255,255,0.10); color: #e2e8f0; }
.sys-waechter-sektion .sw-table th        { color: #94a3b8; }
.sys-waechter-sektion .sw-table tbody tr:hover td { background: rgba(255,255,255,0.03); }
.sys-waechter-sektion .sw-row-ok    td:nth-child(2) { color: #4ade80; }
.sys-waechter-sektion .sw-row-fail  td:nth-child(2) { color: #f87171; }
.sys-waechter-sektion .sw-row-warn  td:nth-child(2) { color: #fbbf24; }
.sys-waechter-sektion .sw-details summary,
.sys-waechter-sektion .sw-history summary { color: #cbd5e1; }
.sys-waechter-sektion .sw-details summary:hover,
.sys-waechter-sektion .sw-history summary:hover { color: #60a5fa; }
.sys-waechter-sektion .sw-laden           { color: #e2e8f0; }
.sys-waechter-sektion .sw-fehler          { color: #f87171; background: rgba(239,68,68,0.10); }
.sys-waechter-sektion .sw-kein-stand      { color: #cbd5e1; }
.sys-waechter-sektion .sw-email-hint      { color: #94a3b8; }

/* ============================================================
   ===== Smart-Wächter (LIGHT CARD via .ad-section) ============
   Texte dunkel auf hellem Card-BG — passt zum Rest des Admins.
   ============================================================ */
.smart-waechter-sektion .sw-title         { color: #0f172a; }
.smart-waechter-sektion .sw-info          { color: #475569; }
.smart-waechter-sektion .sw-ok            { background: rgba(34,197,94,0.12);  color: #15803d; }
.smart-waechter-sektion .sw-warn          { background: rgba(234,179,8,0.14);  color: #a16207; }
.smart-waechter-sektion .sw-fail          { background: rgba(239,68,68,0.12);  color: #b91c1c; }
.smart-waechter-sektion .sw-fail-row      { padding: 8px 12px; background: rgba(239,68,68,0.06); border-left: 3px solid #dc2626; border-radius: 6px; margin: 4px 0; font-size: 13px; color: #0f172a; }
.smart-waechter-sektion .sw-table th,
.smart-waechter-sektion .sw-table td      { border-bottom: 1px solid rgba(0,0,0,0.08); color: #0f172a; }
.smart-waechter-sektion .sw-table th      { color: #64748b; }
.smart-waechter-sektion .sw-table tbody tr:hover td { background: rgba(0,0,0,0.02); }
.smart-waechter-sektion .sw-details summary,
.smart-waechter-sektion .sw-history summary { color: #475569; }
.smart-waechter-sektion .sw-details summary:hover,
.smart-waechter-sektion .sw-history summary:hover { color: #2563eb; }
.smart-waechter-sektion .sw-laden         { color: #475569; }
.smart-waechter-sektion .sw-fehler        { color: #b91c1c; }
.smart-waechter-sektion .sw-kein-stand    { color: #475569; }
.smart-waechter-sektion .sw-email-hint    { color: #64748b; }
