:root {
  --bg: #f6f7f9;
  --card: #ffffff;
  --border: #d7dbe0;
  --text: #1f2328;
  --muted: #6a737d;
  --blue: #2563eb;
  --green: #1a7f37;
  --red: #cf222e;
  --amber: #9a6700;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font: 14px/1.5 system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
}
.hidden { display: none !important; }
h1 { font-size: 20px; margin: 0 0 12px; }

.card {
  max-width: 340px;
  margin: 8vh auto;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 24px;
}
form { display: flex; flex-direction: column; gap: 12px; }
label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
input, select {
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-size: 14px;
  background: #fff;
  color: var(--text);
}
button {
  padding: 8px 14px;
  border: none;
  border-radius: 6px;
  background: var(--blue);
  color: #fff;
  font-size: 13px;
  cursor: pointer;
}
button.ghost { background: transparent; color: var(--muted); border: 1px solid var(--border); }
button.sm { padding: 4px 8px; font-size: 12px; margin-right: 4px; }
button.danger { background: var(--red); }
button.approve { background: var(--green); }
button.warn { background: var(--amber); }

#dashboard-view { max-width: 1100px; margin: 24px auto; padding: 0 16px; }
.topbar { display: flex; justify-content: space-between; align-items: center; }
.who { display: flex; align-items: center; gap: 8px; }
#who-name { color: var(--muted); font-size: 13px; }
.filters { display: flex; gap: 10px; align-items: center; margin: 14px 0; }
.filters #search { flex: 1; }
.count { color: var(--muted); font-size: 13px; white-space: nowrap; }

.table-wrap { overflow-x: auto; background: var(--card); border: 1px solid var(--border); border-radius: 10px; }
table { border-collapse: collapse; width: 100%; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--border); font-size: 13px; }
th { color: var(--muted); font-weight: 600; white-space: nowrap; }
td.mono { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12px; color: var(--muted); }

.badge { padding: 2px 8px; border-radius: 999px; font-size: 12px; font-weight: 600; }
.badge.pending { background: #fff4d6; color: var(--amber); }
.badge.allowed { background: #dafbe1; color: var(--green); }
.badge.blocked { background: #ffe3e3; color: var(--red); }

.error { color: var(--red); font-size: 13px; min-height: 18px; margin: 0; }
.hint { color: var(--muted); }
