.server-health-summary,.security-summary-grid,.hardware-telemetry-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:14px;
}

.health-summary-card,.service-health-card,.hardware-card{
  min-width:0;
  border:1px solid var(--b);
}

.health-summary-card strong,.hardware-card strong{
  display:block;
  margin-top:8px;
  font-size:clamp(20px,2vw,30px);
  overflow-wrap:anywhere;
}

.server-health-toolbar,.incident-toolbar,.security-toolbar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:14px;
}

.server-health-toolbar select,.incident-toolbar select{min-width:220px}

.service-health-grid{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  gap:12px;
}

.service-health-card{
  padding:16px;
  border-radius:16px;
  background:rgba(6,18,34,.72);
}

.service-health-card.good{border-color:rgba(34,197,94,.55)}
.service-health-card.bad{border-color:rgba(239,68,68,.65)}
.service-health-card.warn{border-color:rgba(245,158,11,.6)}
.service-health-card .service-state{margin-top:8px;font-size:18px;font-weight:800}

.container-health-table,.session-table,.security-audit-table{
  width:100%;
  border-collapse:collapse;
}

.container-health-table th,.container-health-table td,
.session-table th,.session-table td,.security-audit-table th,.security-audit-table td{
  padding:11px 10px;
  border-bottom:1px solid var(--b);
  text-align:left;
  vertical-align:top;
}

.incident-list{display:grid;gap:16px}
.incident-card{overflow:hidden}
.incident-head{display:flex;justify-content:space-between;gap:14px;align-items:flex-start}
.incident-head h3{margin:0}
.incident-status{padding:5px 10px;border-radius:999px;background:rgba(245,158,11,.15);color:var(--y);font-weight:800}
.incident-status.completed{background:rgba(34,197,94,.14);color:var(--g)}
.incident-timeline{position:relative;display:grid;gap:0;margin-top:16px;padding-left:24px}
.incident-event{position:relative;padding:0 0 18px 22px;border-left:2px solid var(--b)}
.incident-event:last-child{border-left-color:transparent;padding-bottom:0}
.incident-event::before{content:'';position:absolute;left:-7px;top:4px;width:11px;height:11px;border-radius:50%;background:#64748b;border:2px solid var(--bg)}
.incident-event.warning::before{background:var(--y)}
.incident-event.critical::before{background:var(--r)}
.incident-event.success::before{background:var(--g)}
.incident-event small{display:block;color:var(--muted);margin-top:3px}

.hardware-card{padding:16px;border-radius:16px;background:rgba(7,18,34,.76)}
.hardware-card.good{border-color:rgba(34,197,94,.55)}
.hardware-card.warn{border-color:rgba(245,158,11,.6)}
.hardware-card.bad{border-color:rgba(239,68,68,.65)}
.hardware-card.neutral{border-color:var(--b)}
.hardware-card .hardware-label{display:flex;justify-content:space-between;gap:8px;color:var(--muted)}
.hardware-card small{display:block;margin-top:8px;color:var(--muted);line-height:1.35}

.security-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.4fr);gap:16px}
.security-actions{display:flex;flex-wrap:wrap;gap:10px;margin-top:16px}
.totp-secret{display:block;margin:12px 0;padding:12px;border:1px dashed var(--b);border-radius:12px;word-break:break-all;user-select:all}
.active-alert-list{display:grid;gap:8px}
.active-alert-item{padding:12px;border:1px solid rgba(239,68,68,.45);border-radius:12px;background:rgba(127,29,29,.12)}
.collector-note{padding:12px;border:1px solid rgba(245,158,11,.45);border-radius:12px;background:rgba(120,53,15,.12)}

@media(max-width:1100px){
  .server-health-summary,.security-summary-grid,.hardware-telemetry-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .service-health-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
}

@media(max-width:700px){
  .server-health-summary,.security-summary-grid,.hardware-telemetry-grid,.service-health-grid,.security-layout{grid-template-columns:1fr}
  .server-health-toolbar,.incident-toolbar,.security-toolbar,.incident-head{align-items:stretch;flex-direction:column}
  .server-health-toolbar select,.incident-toolbar select{width:100%;min-width:0}
  .container-health-table,.session-table,.security-audit-table{display:block;overflow-x:auto}
}
