:root {
  color-scheme: dark;
  --bg: #07090e;
  --ink: #eef1f7;
  --mute: #8b93a7;
  --dim: #5f677a;
  --line: rgba(255, 255, 255, .09);
  --panel: #0e1219;
  --panel-2: #121722;
  --accent: #6e8bff;
  --accent-2: #8aa2ff;
  --good: #3dcea0;
  --bad: #ff8b9a;
  --font: "Outfit", ui-sans-serif, system-ui, sans-serif;
  --display: "Instrument Serif", Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { background: var(--bg); }
body {
  min-height: 100vh;
  margin: 0;
  padding: 24px;
  display: grid;
  place-items: center;
  color: var(--ink);
  font-family: var(--font);
  letter-spacing: -.011em;
  background:
    radial-gradient(1100px 560px at 50% -18%, rgba(110, 139, 255, .18), transparent 55%),
    radial-gradient(700px 420px at 100% 12%, rgba(61, 206, 160, .05), transparent 50%),
    linear-gradient(180deg, #06080d 0%, #0a0d14 48%, #07090e 100%);
}
button, input { font: inherit; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }

.login-shell {
  width: min(880px, 100%);
  display: grid;
  grid-template-columns: minmax(300px, 1.1fr) minmax(240px, .85fr);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(18, 23, 34, .98), rgba(10, 13, 20, .98));
  box-shadow: 0 30px 80px rgba(0, 0, 0, .35);
  animation: rise .55s ease both;
}

.login-panel { padding: clamp(28px, 5vw, 48px); }
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(160deg, #8aa2ff, #5a74e8);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
}
.brand-name {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -.02em;
}
.brand-name em {
  font-style: normal;
  color: var(--accent-2);
}

.login-copy { margin-top: 48px; }
.login-copy .hero-brand,
h1.hero-brand {
  margin: 0;
  font-family: var(--display);
  font-size: clamp(36px, 5vw, 48px);
  font-weight: 400;
  line-height: .95;
  letter-spacing: -.03em;
}
.login-copy p {
  max-width: 36ch;
  margin: 14px 0 0;
  color: var(--mute);
  font-size: 14px;
  line-height: 1.55;
}

.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin-top: 28px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(0, 0, 0, .25);
}
.auth-tab {
  min-height: 40px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--mute);
  font-size: 12px;
  font-weight: 650;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background .15s ease, color .15s ease;
}
.auth-tab:hover { color: var(--ink); }
.auth-tab.is-active {
  background: rgba(110, 139, 255, .14);
  color: var(--accent-2);
}

.login-form {
  display: grid;
  gap: 8px;
  margin-top: 22px;
}
.login-form.is-hidden { display: none; }
label {
  color: #aab2c1;
  font-size: 11px;
  font-weight: 650;
}
input {
  width: 100%;
  margin-bottom: 6px;
  min-height: 44px;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  outline: 0;
  background: #0b0e14;
  color: var(--ink);
  font-size: 14px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
input::placeholder { color: var(--dim); }
input:focus {
  border-color: rgba(110, 139, 255, .55);
  box-shadow: 0 0 0 3px rgba(110, 139, 255, .12);
}
.password-wrap { position: relative; }
.password-wrap input {
  padding-right: 64px;
  margin-bottom: 0;
}
.password-toggle {
  position: absolute;
  top: 50%;
  right: 10px;
  transform: translateY(-50%);
  padding: 4px 6px;
  border: 0;
  background: transparent;
  color: var(--mute);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}
.password-toggle:hover,
.password-toggle:focus-visible {
  color: var(--accent-2);
  outline: 0;
}
.remember-option {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 4px 0 2px;
  color: var(--mute);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
}
.remember-option input {
  width: 14px;
  height: 14px;
  min-height: 0;
  margin: 0;
  accent-color: var(--accent);
  cursor: pointer;
}
input.is-valid {
  border-color: rgba(61, 206, 160, .55);
  box-shadow: 0 0 0 3px rgba(61, 206, 160, .08);
}
input.is-invalid,
input.is-taken {
  border-color: rgba(255, 107, 129, .55);
  box-shadow: 0 0 0 3px rgba(255, 107, 129, .08);
}
.field-hint {
  min-height: 14px;
  margin: -2px 0 6px;
  color: var(--dim);
  font-size: 11px;
  line-height: 1.4;
}
.field-hint.is-error { color: var(--bad); }
.field-hint.is-success { color: #7fe3bd; }

.auth-submit,
button[type="submit"] {
  margin-top: 8px;
  min-height: 46px;
  padding: 0 16px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(180deg, #7b95ff, #5f7cf0);
  color: #fff;
  font-size: 14px;
  font-weight: 650;
  cursor: pointer;
  transition: background .15s ease, transform .15s ease;
}
.auth-submit:hover,
button[type="submit"]:hover {
  background: linear-gradient(180deg, #8aa2ff, #6b87f5);
  transform: translateY(-1px);
}
.auth-submit:focus-visible,
.auth-tab:focus-visible,
.back-link:focus-visible,
button[type="submit"]:focus-visible {
  outline: 2px solid var(--accent-2);
  outline-offset: 3px;
}
button[type="submit"].is-loading {
  background: #4d63c4;
  transform: none;
}
button:disabled {
  cursor: wait;
  opacity: .65;
  transform: none;
}

.notice {
  min-height: 16px;
  margin: 8px 0 0;
  color: var(--dim);
  font-size: 12px;
  line-height: 1.45;
}
.notice.is-error { color: var(--bad); }
.notice.is-success { color: #7fe3bd; }

.back-link {
  display: inline-block;
  margin-top: 24px;
  color: var(--accent-2);
  font-size: 13px;
  font-weight: 650;
}
.back-link:hover { color: #fff; }
.back-link + .back-link { margin-left: 16px; }

.login-aside {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 36px 30px;
  border-left: 1px solid var(--line);
  background:
    radial-gradient(420px 280px at 20% 100%, rgba(110, 139, 255, .16), transparent 70%),
    #10141d;
}
.aside-kicker {
  margin: 0;
  color: var(--dim);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.login-aside h2 {
  margin: 14px 0 28px;
  max-width: 12ch;
  font-family: var(--display);
  font-size: clamp(28px, 3.4vw, 36px);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -.03em;
}
.aside-list {
  display: grid;
  gap: 12px;
  color: var(--mute);
  font-size: 13px;
}
.aside-list li {
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

@keyframes rise {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: none; }
}

@media (max-width: 720px) {
  body { padding: 14px; }
  .login-shell { grid-template-columns: 1fr; }
  .login-aside { display: none; }
  .login-copy { margin-top: 36px; }
  .back-link + .back-link {
    display: block;
    margin: 14px 0 0;
  }
}

@media (max-width: 400px) {
  .login-panel { padding: 24px 18px; }
  .auth-tab { font-size: 11px; }
}
