:root {
  color-scheme: light dark;
  --bg: #0f172a;
  --panel: #111827;
  --border: #263247;
  --text: #e5e7eb;
  --muted: #94a3b8;
  --ok: #22c55e;
  --warn: #f59e0b;
  --danger: #ef4444;
  --error: #a855f7;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}

.container {
  width: min(1100px, calc(100% - 32px));
  margin: 48px auto;
}

.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

h1 { margin: 0 0 8px; }
p { color: var(--muted); }

button {
  border: 0;
  border-radius: 10px;
  padding: 11px 16px;
  font-weight: 700;
  cursor: pointer;
}

.summary {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.badge, .status {
  display: inline-block;
  border-radius: 999px;
  padding: 4px 9px;
  font-size: 13px;
  font-weight: 700;
}

.badge { background: #1e293b; }

.status.ok { background: color-mix(in srgb, var(--ok) 22%, transparent); color: #86efac; }
.status.warning { background: color-mix(in srgb, var(--warn) 22%, transparent); color: #fcd34d; }
.status.expired { background: color-mix(in srgb, var(--danger) 22%, transparent); color: #fca5a5; }
.status.error { background: color-mix(in srgb, var(--error) 22%, transparent); color: #d8b4fe; }

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--panel);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 850px;
}

th, td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

th { color: var(--muted); font-size: 13px; }
tbody tr:last-child td { border-bottom: 0; }

.hint { margin-top: 16px; font-size: 14px; }

.error-text { color: #fca5a5; }

@media (max-width: 700px) {
  .container { margin-top: 24px; }
  .header { align-items: flex-start; flex-direction: column; }
}
