:root {
  --bg: #0e0f13;
  --card: #171922;
  --line: #262a36;
  --text: #e6e8ee;
  --muted: #8a90a2;
  --accent: #6d7cff;
  --danger: #ff5470;
  --ok: #38d39f;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.5 -apple-system, system-ui, "Segoe UI", Roboto, sans-serif;
}
.muted { color: var(--muted); }
.small { font-size: 12px; }
code { background: #0b0c10; padding: 1px 6px; border-radius: 4px; color: #b8c0ff; }

header {
  display: flex; justify-content: space-between; align-items: center;
  padding: 16px 24px; border-bottom: 1px solid var(--line);
}
header h1 { font-size: 18px; margin: 0; }
main { max-width: 920px; margin: 0 auto; padding: 24px; }

.card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: 12px; padding: 20px; margin-bottom: 24px;
}
.card h2 { margin: 0 0 16px; font-size: 15px; }

.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.small-row { margin-top: 10px; margin-bottom: 4px; }

input, select, button {
  font: inherit; padding: 8px 12px; border-radius: 8px;
  border: 1px solid var(--line); background: #0f1117; color: var(--text);
}
input:focus, select:focus { outline: 1px solid var(--accent); }
input::placeholder { color: #555b6e; }

button {
  cursor: pointer; background: var(--accent); border: none; color: #fff;
  font-weight: 600; transition: opacity .15s;
}
button:hover { opacity: .88; }
.btn-ghost { background: transparent; border: 1px solid var(--line); color: var(--text);
  text-decoration: none; padding: 8px 14px; border-radius: 8px; }
.btn-danger { background: var(--danger); }
.btn-mini { padding: 4px 10px; font-size: 12px; }
.chk { display: flex; align-items: center; gap: 6px; color: var(--muted); }

.item { border: 1px solid var(--line); border-radius: 10px; padding: 14px; margin-top: 12px; }
.item-head { display: flex; align-items: center; gap: 12px; }
.item-head b { font-size: 14px; }
.item-head button { margin-left: auto; }

.accounts, .targets { margin-top: 12px; padding-left: 6px; border-left: 2px solid var(--line); }
.acc, .tgt { display: flex; align-items: center; gap: 10px; padding: 5px 0; }

.dot { width: 9px; height: 9px; border-radius: 50%; background: #555; display: inline-block; }
.dot.ok { background: var(--ok); }
.dot.banned { background: var(--danger); }
.dot.error { background: #ffb454; }
.dot.unknown { background: #555; }

.badge { font-size: 11px; padding: 1px 8px; border-radius: 20px;
  background: #232838; color: #9aa3c0; }

.models-box { margin-top: 12px; padding: 10px 12px; border-radius: 8px;
  background: #0f1117; border: 1px solid var(--line); }
.model-row { display: flex; align-items: center; gap: 8px; padding: 5px 0;
  flex-wrap: wrap; }
.model-row code { min-width: 180px; }
.alias-inp { flex: 1; min-width: 140px; padding: 5px 10px; font-size: 13px; }

/* login */
.login-body { display: flex; min-height: 100vh; align-items: center; justify-content: center; }
.login-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  padding: 32px; width: 320px; display: flex; flex-direction: column; gap: 12px;
}
.login-card h1 { margin: 0; font-size: 20px; }
.login-card p { margin: 0 0 8px; }
.error { background: #3a1620; color: var(--danger); padding: 8px 12px; border-radius: 8px; }

#toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%);
  background: #232838; color: #fff; padding: 10px 18px; border-radius: 10px;
  border: 1px solid var(--line); opacity: 0; transition: opacity .2s; pointer-events: none;
}
#toast.show { opacity: 1; }
