
:root {
  color-scheme: light dark;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  --blue-700: #0747ad;
  --blue-600: #075bd8;
  --blue-500: #1475f8;
  --navy-950: #071a37;
  --text: #10213d;
  --muted: #5b6b83;
  --canvas: #eef4fc;
  --surface: #ffffff;
  --line: #d9e3f0;
  --input: #f8fbff;
  --danger: #b42318;
  --danger-bg: #fff2f0;
  --focus: #ffb422;
  --shadow: 0 28px 80px rgba(27, 57, 99, 0.18);
}

* {
  box-sizing: border-box;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 12% 12%, rgba(57, 134, 255, 0.16), transparent 32rem),
    radial-gradient(circle at 90% 90%, rgba(39, 203, 174, 0.12), transparent 28rem),
    var(--canvas);
}

button,
input {
  font: inherit;
}

.login-page {
  display: grid;
  min-height: 100vh;
  place-items: center;
  padding: clamp(16px, 4vw, 48px);
}

.login-shell {
  display: grid;
  grid-template-columns: minmax(300px, 0.85fr) minmax(390px, 1.15fr);
  width: min(100%, 960px);
  min-height: 620px;
  overflow: hidden;
  border: 1px solid rgba(203, 216, 233, 0.9);
  border-radius: 24px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.login-brand {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  padding: clamp(32px, 5vw, 56px);
  color: #ffffff;
  background:
    radial-gradient(circle at 88% 10%, rgba(75, 189, 255, 0.55), transparent 15rem),
    linear-gradient(155deg, var(--blue-500) 0%, var(--blue-700) 48%, var(--navy-950) 100%);
}

.login-brand::before,
.login-brand::after {
  position: absolute;
  content: "";
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 50%;
}

.login-brand::before {
  right: -150px;
  bottom: 60px;
  width: 360px;
  height: 360px;
}

.login-brand::after {
  right: -70px;
  bottom: 140px;
  width: 200px;
  height: 200px;
}

.brand-name,
.brand-copy,
.brand-footer {
  position: relative;
  z-index: 1;
}

.brand-name {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 2px solid rgba(255, 255, 255, 0.76);
  border-radius: 14px;
  color: var(--blue-700);
  background: #ffffff;
  font-size: 26px;
  font-weight: 900;
  line-height: 1;
  transform: rotate(-3deg);
}

.brand-badge {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 6px 12px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.brand-copy h2 {
  margin: 24px 0 16px;
  font-size: clamp(30px, 4vw, 42px);
  line-height: 1.12;
  letter-spacing: -0.045em;
}

.brand-copy p,
.brand-footer {
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
  line-height: 1.65;
}

.login-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(32px, 6vw, 64px);
}

.lock-icon {
  display: grid;
  width: 48px;
  height: 48px;
  margin-bottom: 24px;
  place-items: center;
  border-radius: 14px;
  color: var(--blue-600);
  background: #eaf2ff;
}

.lock-icon svg,
.session-note svg,
.login-form button svg {
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
}

.lock-icon svg {
  width: 25px;
  height: 25px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--blue-600);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.login-heading h1 {
  margin: 0;
  font-size: clamp(30px, 4vw, 38px);
  line-height: 1.16;
  letter-spacing: -0.04em;
}

.login-heading > p:last-child {
  max-width: 500px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.65;
}

.login-error {
  display: grid;
  gap: 3px;
  margin-top: 24px;
  padding: 14px 16px;
  border: 1px solid rgba(180, 35, 24, 0.22);
  border-radius: 12px;
  color: var(--danger);
  background: var(--danger-bg);
  font-size: 14px;
  line-height: 1.45;
}

.login-form {
  display: grid;
  gap: 10px;
  margin-top: 32px;
}

.login-form label {
  margin-top: 8px;
  font-size: 14px;
  font-weight: 750;
}

.login-form input {
  width: 100%;
  min-height: 52px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  outline: none;
  color: var(--text);
  background: var(--input);
  font-size: 16px;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.login-form input:hover {
  border-color: #a9bdd8;
}

.login-form input:focus-visible {
  border-color: var(--blue-500);
  background: var(--surface);
  box-shadow: 0 0 0 4px rgba(20, 117, 248, 0.15);
}

.login-form button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  margin-top: 16px;
  padding: 12px 20px;
  border: 0;
  border-radius: 12px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--blue-500), var(--blue-700));
  box-shadow: 0 10px 24px rgba(7, 91, 216, 0.24);
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, filter 160ms ease;
}

.login-form button:hover {
  filter: brightness(1.05);
  box-shadow: 0 12px 28px rgba(7, 91, 216, 0.3);
  transform: translateY(-1px);
}

.login-form button:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.login-form button:active {
  transform: translateY(0);
}

.login-form button svg {
  width: 20px;
  height: 20px;
}

.session-note {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 24px;
  color: var(--muted);
}

.session-note svg {
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  margin-top: 1px;
}

.session-note p {
  margin: 0;
  font-size: 12px;
  line-height: 1.55;
}

@media (max-width: 820px) {
  .login-page {
    align-items: start;
  }

  .login-shell {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .login-brand {
    min-height: 240px;
    gap: 48px;
  }

  .brand-copy h2 {
    font-size: 32px;
  }

  .brand-copy p {
    max-width: 540px;
  }

  .brand-footer {
    display: none;
  }
}

@media (max-width: 560px) {
  .login-page {
    display: block;
    min-height: 100svh;
    padding: 0;
    background: var(--surface);
  }

  .login-shell {
    min-height: 100svh;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .login-brand {
    min-height: 196px;
    padding: 24px;
  }

  .brand-name {
    font-size: 16px;
  }

  .brand-mark {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    font-size: 23px;
  }

  .brand-badge,
  .brand-copy p {
    display: none;
  }

  .brand-copy h2 {
    margin: 0;
    font-size: 28px;
  }

  .login-content {
    justify-content: flex-start;
    padding: 32px 24px 40px;
  }

  .lock-icon {
    display: none;
  }

  .login-form {
    margin-top: 24px;
  }
}

@media (prefers-color-scheme: dark) {
  :root {
    --text: #eef5ff;
    --muted: #aebdd2;
    --canvas: #07111f;
    --surface: #0d1a2b;
    --line: #2a3b52;
    --input: #111f32;
    --danger: #ffaaa2;
    --danger-bg: #35191b;
    --shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
  }

  .login-shell {
    border-color: #23364e;
  }

  .lock-icon {
    background: #142d50;
  }

  .login-form input:hover {
    border-color: #49627f;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
