:root {
  --ink: #15213a;
  --muted: #68738a;
  --line: #e1e7f0;
  --paper: #f4f6fa;
  --blue: #4777ff;
}

* { box-sizing: border-box; }
html { color-scheme: light; background: var(--paper); }
body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
}
button, input { font: inherit; }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 2px solid rgba(71,119,255,.62); outline-offset: 3px; }

.auth-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  background: radial-gradient(circle at 15% 10%,rgba(71,119,255,.13),transparent 35%), radial-gradient(circle at 90% 85%,rgba(39,199,189,.1),transparent 32%), var(--paper);
}
.auth-card { width: min(100%,440px); padding: 30px; border: 1px solid #dce3ef; border-radius: 22px; background: rgba(255,255,255,.96); box-shadow: 0 24px 70px rgba(23,37,68,.12); }
.auth-card-wide { width: min(100%,620px); }
.auth-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 38px; }
.auth-brand img { width: 44px; height: 44px; border-radius: 13px; box-shadow: 0 10px 24px rgba(71,119,255,.23); }
.auth-brand strong, .auth-brand span { display: block; }
.auth-brand strong { font-size: 16px; }
.auth-brand span { margin-top: 2px; color: var(--muted); font-size: 10px; }
.auth-copy h1 { margin: 5px 0 9px; font-size: 34px; letter-spacing: -.04em; }
.auth-copy > p:last-child { margin: 0 0 24px; color: var(--muted); font-size: 13px; line-height: 1.55; }
.auth-form { padding: 0; }
.auth-card .flash { margin-bottom: 17px; }
.eyebrow { margin: 0; color: #4169bd; font-size: 12px; font-weight: 760; letter-spacing: .01em; }

.stacked-form { display: grid; gap: 15px; }
.form-split { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.field { display: block; }
.field > span { display: block; margin: 0 0 7px 2px; color: var(--muted); font-size: 10px; font-weight: 760; letter-spacing: .01em; }
.field small { display: block; margin: 6px 0 0 2px; color: #8a95a9; font-size: 10px; }
input { width: 100%; min-height: 44px; padding: 0 14px; color: var(--ink); border: 1px solid var(--line); border-radius: 11px; outline: none; background: white; }
input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(71,119,255,.12); }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 17px; appearance: none; color: var(--ink); border: 0; border-radius: 11px; background: #fff; cursor: pointer; font-size: 12px; font-weight: 780; line-height: 1.15; text-align: center; white-space: nowrap; box-shadow: 0 4px 12px rgba(23,37,68,.055); transition: transform .16s ease, box-shadow .16s ease, background .16s ease, color .16s ease; }
.button:hover { transform: translateY(-1px); box-shadow: 0 8px 18px rgba(23,37,68,.1); }
.button:active { transform: translateY(0); box-shadow: 0 2px 6px rgba(23,37,68,.06); }
.button.primary { color: white; background: linear-gradient(135deg,#527cff,#3d68e8); box-shadow: 0 9px 20px rgba(71,119,255,.22); }
.button.primary:hover { box-shadow: 0 12px 25px rgba(71,119,255,.3); }
.button.secondary { color: #315fc9; background: #edf2ff; box-shadow: none; }
.button.wide { width: 100%; }

.flash { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 16px; padding: 12px 15px; border: 1px solid transparent; border-radius: 11px; font-size: 11px; font-weight: 700; line-height: 1.45; box-shadow: 0 5px 18px rgba(23,37,68,.04); }
.flash::before { display: grid; width: 20px; height: 20px; place-items: center; flex: 0 0 auto; margin-top: -1px; border-radius: 7px; font-size: 11px; font-weight: 900; }
.flash.success { color: #176d53; border-color: #c8ebdd; background: #e6f7f0; }
.flash.success::before { content: "✓"; color: #176d53; background: #c9edde; }
.flash.error { color: #8c4d5d; border-color: #efd0d7; background: #fae9ed; white-space: pre-line; }
.flash.error::before { content: "!"; color: #8c4d5d; background: #f1ced8; }

.auth-login-page { padding: clamp(22px,4vw,64px); }
.auth-login-shell { width: min(100%,1040px); min-height: min(680px,calc(100vh - 80px)); display: grid; grid-template-columns: minmax(0,1.08fr) minmax(420px,.92fr); overflow: hidden; border: 1px solid rgba(198,208,226,.72); border-radius: 30px; background: white; box-shadow: 0 32px 90px rgba(23,37,68,.16); }
.auth-login-intro { position: relative; isolation: isolate; display: flex; flex-direction: column; padding: clamp(42px,5vw,66px); overflow: hidden; color: white; background: linear-gradient(145deg,#142348 0%,#203f86 55%,#3d67da 100%); }
.auth-login-intro::before, .auth-login-intro::after { content: ""; position: absolute; z-index: -1; border-radius: 999px; pointer-events: none; }
.auth-login-intro::before { width: 360px; height: 360px; top: -170px; right: -160px; background: rgba(119,145,255,.32); }
.auth-login-intro::after { width: 310px; height: 310px; right: -110px; bottom: -170px; border: 1px solid rgba(255,255,255,.16); box-shadow: 0 0 0 54px rgba(255,255,255,.035); }
.auth-brand-light { margin-bottom: 0; }
.auth-brand-light strong { color: white; }
.auth-brand-light span { color: #b8c8eb; }
.auth-brand-light img { box-shadow: 0 14px 32px rgba(4,12,35,.3); }
.auth-login-pitch { margin: auto 0; padding: 54px 0; }
.auth-login-pitch > p:first-child { margin: 0 0 18px; color: #bcd0ff; font-size: 12px; font-weight: 760; letter-spacing: .035em; text-transform: uppercase; }
.auth-login-pitch h1 { max-width: 520px; margin: 0 0 22px; font-size: clamp(39px,4.2vw,56px); line-height: 1.02; letter-spacing: -.05em; text-wrap: balance; }
.auth-login-pitch > p:last-child { max-width: 490px; margin: 0; color: #cbd7f2; font-size: 15px; line-height: 1.65; }
.auth-login-points { display: grid; gap: 13px; margin: 0; padding: 0; list-style: none; }
.auth-login-points li { display: grid; grid-template-columns: 32px minmax(0,1fr); gap: 12px; align-items: center; color: #e3eaff; font-size: 12px; line-height: 1.45; }
.auth-login-points span { display: grid; place-items: center; width: 32px; height: 32px; color: #c9d7ff; border: 1px solid rgba(255,255,255,.17); border-radius: 10px; background: rgba(255,255,255,.07); font-size: 9px; font-weight: 800; }
.auth-login-panel { display: flex; flex-direction: column; justify-content: center; padding: clamp(42px,5vw,68px); background: rgba(255,255,255,.98); }
.auth-login-form-wrap { width: 100%; max-width: 390px; margin: auto; }
.auth-login-panel .auth-copy { margin-bottom: 32px; }
.auth-login-panel .auth-copy h2 { margin: 8px 0 12px; font-size: 34px; line-height: 1.08; letter-spacing: -.04em; }
.auth-login-panel .auth-copy > p:last-child { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.55; }
.auth-login-panel .auth-form { gap: 19px; }
.auth-login-panel .field > span { margin-bottom: 9px; font-size: 11px; }
.auth-login-panel input { min-height: 52px; padding-inline: 16px; border-radius: 13px; font-size: 15px; }
.auth-login-panel .button { min-height: 52px; margin-top: 5px; border-radius: 13px; font-size: 13px; }
.auth-login-panel .flash { margin-bottom: 22px; }
.auth-login-note { margin: 34px 0 0; color: #8b95a8; font-size: 10px; text-align: center; }

@media (max-width:760px) {
  .auth-login-page { display: block; padding: 0; background: white; }
  .auth-login-shell { min-height: 100vh; grid-template-columns: 1fr; border: 0; border-radius: 0; box-shadow: none; }
  .auth-login-intro { min-height: 250px; padding: 30px 26px; }
  .auth-login-pitch { padding: 42px 0 8px; }
  .auth-login-pitch h1 { max-width: 430px; margin-bottom: 12px; font-size: clamp(34px,10vw,45px); }
  .auth-login-pitch > p:last-child { max-width: 460px; font-size: 13px; }
  .auth-login-points { display: none; }
  .auth-login-panel { min-height: 520px; padding: 42px 26px 30px; }
  .auth-login-form-wrap { max-width: 480px; }
  .form-split { grid-template-columns: 1fr; }
}

@media (max-width:520px) {
  .auth-page { padding: 12px; }
  .auth-login-page { padding: 0; }
  .auth-card { padding: 22px 18px; border-radius: 17px; }
  .auth-brand { margin-bottom: 28px; }
  .auth-login-page .auth-brand { margin-bottom: 0; }
  .auth-login-intro { min-height: 228px; padding: 25px 22px; }
  .auth-login-pitch { padding-top: 34px; }
  .auth-login-pitch > p:first-child { margin-bottom: 12px; font-size: 10px; }
  .auth-login-pitch h1 { font-size: 34px; }
  .auth-login-pitch > p:last-child { display: none; }
  .auth-login-panel { min-height: calc(100vh - 228px); padding: 36px 22px 24px; justify-content: flex-start; }
  .auth-login-panel .auth-copy { margin-bottom: 26px; }
  .auth-login-panel .auth-copy h2 { font-size: 30px; }
}
