:root {
  --font: "Segoe UI Variable Text", "Segoe UI Variable", "Segoe UI", -apple-system, BlinkMacSystemFont, system-ui, "Helvetica Neue", Arial, sans-serif;
  --accent: #005fb8;
  --accent-hover: #1a6dbd;
  --on-accent: #fff;
  --bg: linear-gradient(115deg, #dfe8f4 0%, #eceef6 45%, #f1e9f1 100%);
  --card: rgba(255, 255, 255, 0.78);
  --text: #1a1a1a;
  --text-2: #5d5d5d;
  --stroke: rgba(0, 0, 0, 0.0578);
  --stroke-input: rgba(0, 0, 0, 0.4458);
  --input: #ffffff;
  --danger: #c42b1c;
  --danger-bg: #fde7e9;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --accent: #60cdff;
    --accent-hover: #5abce9;
    --on-accent: #000;
    --bg: linear-gradient(115deg, #1a1f26 0%, #1d1d21 50%, #221d24 100%);
    --card: rgba(44, 44, 44, 0.85);
    --text: #fff;
    --text-2: #cfcfcf;
    --stroke: rgba(255, 255, 255, 0.0698);
    --stroke-input: rgba(255, 255, 255, 0.5442);
    --input: #1e1e1e;
    --danger: #ff99a4;
    --danger-bg: #442726;
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  font-family: var(--font);
  font-size: 14px;
  line-height: 20px;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
button, input { font-family: var(--font); font-size: inherit; color: inherit; }
.card {
  width: min(400px, 100%);
  padding: 36px 32px 32px;
  border: 1px solid var(--stroke);
  border-radius: 8px;
  background: var(--card);
  box-shadow: 0 32px 64px rgba(0, 0, 0, 0.12), 0 2px 21px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(30px) saturate(1.4);
}
.logo { display: block; margin: 0 auto 12px; }
h1 {
  margin: 0;
  text-align: center;
  font-family: "Segoe UI Variable Display", var(--font);
  font-size: 28px;
  line-height: 36px;
  font-weight: 600;
}
.sub { margin: 4px 0 24px; text-align: center; color: var(--text-2); }
label { display: block; margin: 0 0 6px; font-size: 14px; }
input {
  width: 100%;
  height: 32px;
  margin-bottom: 16px;
  padding: 0 10px;
  border: 1px solid var(--stroke);
  border-bottom-color: var(--stroke-input);
  border-radius: 4px;
  background: var(--input);
  outline: none;
}
input:focus { border-bottom: 2px solid var(--accent); }
.pw { position: relative; }
.pw input { padding-right: 40px; }
.reveal {
  position: absolute;
  right: 2px;
  top: 2px;
  width: 30px;
  height: 28px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: var(--text-2);
}
.reveal:hover { background: rgba(127, 127, 127, 0.12); }
.reveal svg { width: 16px; height: 16px; fill: currentColor; }
.btn {
  width: 100%;
  height: 32px;
  margin-top: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-bottom-color: rgba(0, 0, 0, 0.4);
  border-radius: 4px;
  background: var(--accent);
  color: var(--on-accent);
}
.btn:hover:not(:disabled) { background: var(--accent-hover); }
.btn:disabled { opacity: 0.6; }
.btn:focus-visible, .reveal:focus-visible { outline: 2px solid var(--text); outline-offset: 1px; }
.error {
  margin: 0 0 8px;
  padding: 8px 12px;
  border-radius: 4px;
  background: var(--danger-bg);
  color: var(--danger);
  font-size: 13px;
}
[hidden] { display: none !important; }
