:root {
  font-family: Arial, Helvetica, sans-serif;
  color: #172033;
  background: #f4f6f9;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
}

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 32px;
  color: white;
  background: #172554;
}

header h1 {
  margin: 0 0 6px;
}

header p {
  margin: 0;
  color: #cbd5e1;
}

button,
select,
input {
  padding: 10px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
}

button {
  cursor: pointer;
}

header button {
  color: white;
  background: #2563eb;
  border: 0;
}

main {
  padding: 24px 32px;
}

.toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  padding: 16px;
  background: white;
  border-radius: 12px;
}

.toolbar input {
  min-width: 280px;
}

.summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  gap: 16px;
  margin-bottom: 20px;
}

.summary article {
  padding: 20px;
  background: white;
  border-left: 6px solid #2563eb;
  border-radius: 12px;
}

.summary span {
  display: block;
  font-size: 28px;
  font-weight: bold;
}

.warning-card {
  border-left-color: #f59e0b !important;
}

.danger-card {
  border-left-color: #dc2626 !important;
}

.tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.tab.active {
  color: white;
  background: #2563eb;
}

.table-container {
  overflow-x: auto;
  background: white;
  border-radius: 12px;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 12px 14px;
  text-align: left;
  border-bottom: 1px solid #e2e8f0;
}

th {
  background: #e8edf5;
}

tr.status-warning {
  background: #fff7d6;
  color: #8a4b00;
}

tr.status-danger {
  background: #fee2e2;
  color: #991b1b;
  font-weight: 600;
}

tr.status-unknown {
  background: #e5e7eb;
  color: #4b5563;
}

.disabled {
  opacity: 0.55;
}

.message {
  margin-bottom: 16px;
  padding: 14px;
  color: #991b1b;
  background: #fee2e2;
  border-radius: 8px;
}

.hidden {
  display: none;
}

@media (max-width: 800px) {
  .summary {
    grid-template-columns: repeat(2, 1fr);
  }

  .toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .toolbar input {
    min-width: 0;
  }
}

th.sortable {
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}

th.sortable:hover {
  background-color: #dbe4f0;
}

.sort-indicator {
  display: inline-block;
  min-width: 16px;
  margin-left: 4px;
  color: #2563eb;
  font-weight: bold;
}
