:root {
  color-scheme: dark;
  --bg: #11181b;
  --surface: #192326;
  --line: #2d3b40;
  --text: #e5eeec;
  --muted: #91a2a3;
  --dim: #6e8285;
  --accent: #5ccdb4;
  --accent-strong: #78e0c8;
  --danger: #ef8b8b;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; margin: 0; }
body {
  display: grid;
  min-width: 320px;
  min-height: 100vh;
  place-items: center;
  padding: 22px;
  color: var(--text);
  background: var(--bg);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
}

button, input { font: inherit; letter-spacing: 0; }
button { cursor: pointer; }
.hidden { display: none !important; }

.login-shell { width: min(360px, 100%); }
.login-card {
  padding: 30px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface);
  box-shadow: 0 18px 44px rgba(0, 0, 0, .24);
}
h1 { margin: 0; font-size: 22px; font-weight: 700; line-height: 1.25; }
form { margin-top: 26px; }
label {
  display: block;
  margin: 17px 0 7px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 650;
}
.input-shell {
  display: flex;
  min-height: 43px;
  align-items: center;
  padding: 0 11px;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--dim);
  background: #121c20;
}
.input-shell:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(92, 205, 180, .1);
}
.input-shell > svg { width: 16px; height: 16px; flex: 0 0 16px; }
.input-shell input {
  width: 100%;
  min-width: 0;
  height: 41px;
  padding: 0 10px;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
}
.password-toggle {
  display: grid;
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  place-items: center;
  padding: 0;
  border: 0;
  color: var(--dim);
  background: transparent;
}
.password-toggle:hover { color: var(--text); }
.password-toggle svg { width: 16px; height: 16px; }
.login-error {
  margin-top: 14px;
  padding: 10px 11px;
  border: 1px solid #71373d;
  border-radius: 5px;
  color: var(--danger);
  background: #2d1c21;
  font-size: 11px;
  line-height: 1.45;
}
.login-submit {
  display: flex;
  width: 100%;
  min-height: 43px;
  margin-top: 20px;
  padding: 0 14px;
  align-items: center;
  justify-content: space-between;
  border: 1px solid #3e9d8b;
  border-radius: 6px;
  color: #061512;
  background: var(--accent);
  font-size: 12px;
  font-weight: 750;
}
.login-submit:hover { border-color: var(--accent-strong); background: #69d9c0; }
.login-submit:disabled { cursor: wait; opacity: .65; }
.login-submit svg { width: 16px; height: 16px; }
.login-submit.loading svg { animation: login-spin .8s linear infinite; }
@keyframes login-spin { to { transform: rotate(360deg); } }

@media (max-width: 420px) {
  body { padding: 16px; }
  .login-card { padding: 24px 20px; }
}
