:root {
  color-scheme: dark;
  --bg: #0b1020;
  --card: #121a2e;
  --card-2: #0e1628;
  --text: #edf2ff;
  --muted: #8e9bb7;
  --line: #26324d;
  --accent: #5b8cff;
  --accent-2: #7c5cff;
  --danger: #ff6b81;
  --ok: #35d0a0;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(900px 500px at 15% 0%, rgba(91,140,255,.28), transparent 60%),
    radial-gradient(800px 500px at 95% 10%, rgba(124,92,255,.22), transparent 55%),
    var(--bg);
  display: grid;
  place-items: center;
  padding: 24px;
}
.page { width: 100%; max-width: 420px; }
.card {
  background: linear-gradient(180deg, rgba(18,26,46,.96), rgba(14,22,40,.96));
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 30px;
  box-shadow: 0 30px 80px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.04);
  backdrop-filter: blur(12px);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; }
.mark { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; color: white; font-weight: 800; background: linear-gradient(135deg, var(--accent), var(--accent-2)); box-shadow: 0 8px 24px rgba(91,140,255,.35); }
h1 { margin: 22px 0 6px; font-size: 28px; letter-spacing: -.02em; }
.sub { margin: 0 0 24px; color: var(--muted); font-size: 14px; }
label { display: block; margin: 14px 0 7px; color: #b7c3dc; font-size: 13px; }
input {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--card-2);
  color: var(--text);
  font-size: 15px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(91,140,255,.18); }
button {
  width: 100%;
  height: 46px;
  margin-top: 20px;
  border: 0;
  border-radius: 11px;
  color: white;
  font-size: 15px;
  font-weight: 700;
  cursor: pointer;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  box-shadow: 0 12px 30px rgba(91,140,255,.28);
  transition: transform .12s, opacity .12s;
}
button:hover { transform: translateY(-1px); }
button:disabled { opacity: .6; cursor: not-allowed; transform: none; }
button.secondary { background: #1a2540; border: 1px solid var(--line); box-shadow: none; }
.message { min-height: 20px; margin-top: 12px; font-size: 13px; color: var(--danger); }
.message.ok { color: var(--ok); }
.hint { margin: 18px 0 0; color: var(--muted); font-size: 12px; line-height: 1.6; }
.user-box { display: flex; align-items: center; gap: 12px; margin: 22px 0 4px; padding: 14px; border: 1px solid var(--line); border-radius: 14px; background: rgba(14,22,40,.7); }
.avatar { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; background: linear-gradient(135deg, var(--accent), var(--accent-2)); }
.label { color: var(--muted); font-size: 11px; margin-bottom: 3px; }
.username { font-size: 16px; font-weight: 700; }
@media (max-width: 480px) { .card { padding: 22px; border-radius: 18px; } h1 { font-size: 24px; } }
