:root {
  --void: #05070d;
  --paper: #f5f7fb;
  --mute: #9ca3af;
  --link: #93c5fd;
  --link-hover: #e0f2fe;
  --line: rgba(255, 255, 255, 0.12);
  --card: rgba(8, 12, 22, 0.92);
  --card-edge: rgba(255, 255, 255, 0.08);
  --input-fill: rgba(6, 10, 18, 0.9);
  --input-stroke: rgba(255, 255, 255, 0.16);
  --btn-radius: 0.75rem;
  --font: "DM Sans", system-ui, sans-serif;
  --display: "Syne", var(--font);
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-font-smoothing: antialiased; }
body.auth-body {
  margin: 0;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  font-family: var(--font);
  color: var(--mute);
  color-scheme: dark;
  background: var(--void);
}
body.auth-body a { color: var(--link); text-decoration: none; }
body.auth-body a:hover { color: var(--link-hover); }
.grid-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 100% 80% at 50% -20%, rgba(59, 130, 246, 0.22), transparent 55%),
    radial-gradient(ellipse 70% 50% at 100% 40%, rgba(34, 211, 238, 0.08), transparent 50%),
    var(--void);
}
.grid-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.22;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 80% 55% at 50% 35%, #000 12%, transparent 72%);
}
.auth-login-shell {
  position: relative;
  z-index: 1;
  display: flex;
  min-height: 100svh;
  width: 100%;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem 1rem 1.75rem;
}
.auth-login-wrap { width: 100%; max-width: 28rem; }
.auth-card {
  width: 100%;
  border: 1px solid var(--card-edge);
  border-radius: 1rem;
  background: var(--card);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.04) inset, 0 20px 50px rgba(0, 0, 0, 0.45);
  padding: 2rem 1.75rem 1.75rem;
}
.auth-login-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  width: 100%;
}
.auth-login-logo { line-height: 0; }
.auth-login-logo img {
  width: 3rem;
  height: 3rem;
  object-fit: contain;
  display: block;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.45));
}
.auth-login-intro { text-align: center; }
.auth-login-title {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(1.4rem, 4vw, 1.65rem);
  line-height: 1.2;
  margin: 0;
  color: var(--paper);
  letter-spacing: -0.03em;
}
.auth-login-sub { margin: 0.5rem 0 0; font-size: 1rem; color: #9ca3af; }
.auth-login-sub a { font-weight: 600; }
.auth-login-blocks { width: 100%; display: flex; flex-direction: column; gap: 1rem; }
.auth-login-form { display: flex; flex-direction: column; gap: 1.15rem; width: 100%; }
.auth-login-label {
  display: block;
  margin: 0 0 0.35rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #d1d5db;
}
.auth-login-pw-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
}
.auth-login-pw-head .auth-login-label { margin: 0; }
.auth-login-forgot { font-size: 0.875rem; font-weight: 600; }
.field-row {
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  min-height: 2.75rem;
  border: 1px solid var(--input-stroke);
  border-radius: 0.75rem;
  background: var(--input-fill);
  padding: 0 0.75rem;
}
.field-row--pw { grid-template-columns: 1fr 2.25rem; padding-right: 0.35rem; }
.field-row:focus-within {
  border-color: rgba(147, 197, 253, 0.7);
  box-shadow: 0 0 0 1px rgba(59, 130, 246, 0.35);
}
.field-row input {
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 0.65rem 0.15rem;
  border: 0;
  background: transparent;
  color: var(--paper);
  font: inherit;
  font-size: 1rem;
}
.field-row input::placeholder { color: #6b7280; }
.field-row input:focus { outline: none; }
.field-row input:-webkit-autofill {
  -webkit-box-shadow: 0 0 0 1000px #070b14 inset;
  -webkit-text-fill-color: var(--paper);
}
.field-pw-toggle {
  width: 1.75rem;
  height: 1.75rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #9ca3af;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}
.field-pw-toggle:hover { color: var(--paper); background: rgba(255, 255, 255, 0.06); }
.btn-gradient {
  appearance: none;
  display: block;
  width: 100%;
  min-height: 2.75rem;
  margin-top: 0.35rem;
  padding: 0.7rem 1.25rem;
  border-radius: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  background: linear-gradient(160deg, #60a5fa 0%, #2563eb 100%);
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.28);
}
.btn-gradient:hover { filter: brightness(1.06); }
.btn-gradient:active { transform: scale(0.99); }
.ok, .err {
  margin: 0;
  padding: 0.65rem 0.8rem;
  border-radius: 8px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.06);
  color: #e5e5e5;
  font-size: 0.86rem;
  list-style: none;
}
.auth-login-note { margin: 0; font-size: 0.86rem; line-height: 1.5; color: #9ca3af; text-align: center; }
.auth-login-homefoot { text-align: center; margin: 1.35rem 0 0; font-size: 0.8125rem; }
.auth-login-homefoot a { color: var(--link); font-weight: 500; }
.auth-login-homefoot a:hover { text-decoration: underline; }

* { scrollbar-width: thin; scrollbar-color: rgba(147, 160, 181, 0.32) transparent; }
*::-webkit-scrollbar { width: 8px; height: 8px; }
*::-webkit-scrollbar-track { background: transparent; }
*::-webkit-scrollbar-thumb { background: rgba(147, 160, 181, 0.28); border-radius: 999px; border: 2px solid transparent; background-clip: padding-box; }
*::-webkit-scrollbar-thumb:hover { background: rgba(147, 160, 181, 0.5); background-clip: padding-box; }
*::-webkit-scrollbar-corner, *::-webkit-scrollbar-button { display: none; background: transparent; }
