:root {
  color-scheme: light;
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --cyan: #0ea5e9;
  --text: #0f172a;
  --muted: #64748b;
  --border: #dbe3ef;
  --surface-soft: #f8fafc;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

html,
body {
  min-height: 100%;
}

body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(37, 99, 235, .18), transparent 35%),
    radial-gradient(circle at bottom right, rgba(14, 165, 233, .16), transparent 35%),
    #f8fafc;
}

button,
input {
  font: inherit;
}

.login-shell {
  width: 100%;
  max-width: 1080px;
  min-height: 650px;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, .25);
  border-radius: 34px;
  background: rgba(255, 255, 255, .96);
  box-shadow: 0 30px 80px rgba(15, 23, 42, .12);
}

.login-hero {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  padding: 46px;
  color: #fff;
  background: linear-gradient(135deg, rgba(15, 23, 42, .97), rgba(30, 64, 175, .94));
}

.login-hero::before,
.login-hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

.login-hero::before {
  width: 330px;
  height: 330px;
  top: -160px;
  right: -130px;
  border: 1px solid rgba(255, 255, 255, .10);
  box-shadow: 0 0 0 55px rgba(255, 255, 255, .025), 0 0 0 110px rgba(255, 255, 255, .018);
}

.login-hero::after {
  width: 300px;
  height: 300px;
  left: -130px;
  bottom: -170px;
  background: rgba(14, 165, 233, .13);
}

.brand {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-mark {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, .22);
  border-radius: 18px;
  background: rgba(255, 255, 255, .15);
  font-weight: 900;
  letter-spacing: .08em;
}

.brand strong,
.brand span {
  display: block;
}

.brand strong {
  font-size: 18px;
}

.brand span {
  margin-top: 3px;
  color: rgba(255, 255, 255, .72);
  font-size: 13px;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-content h1 {
  max-width: 500px;
  margin-bottom: 20px;
  font-size: clamp(36px, 4vw, 56px);
  line-height: 1.02;
  letter-spacing: -.05em;
}

.hero-content p {
  max-width: 460px;
  color: rgba(255, 255, 255, .78);
  font-size: 15px;
  line-height: 1.7;
}

.feature-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 28px;
}

.feature-item {
  min-height: 52px;
  display: flex;
  align-items: center;
  padding: 13px 14px;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 16px;
  background: rgba(255, 255, 255, .11);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.4;
}

.hero-footer {
  position: relative;
  z-index: 1;
  color: rgba(255, 255, 255, .62);
  font-size: 12px;
  font-weight: 700;
}

.login-panel {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 42px;
}

.eyebrow {
  margin-bottom: 12px;
  color: var(--primary);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.login-title {
  margin-bottom: 8px;
  font-size: 34px;
  line-height: 1.1;
  letter-spacing: -.04em;
}

.subtitle {
  margin-bottom: 24px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.alert {
  margin-bottom: 18px;
  padding: 13px 15px;
  border: 1px solid;
  border-radius: 14px;
  font-size: 13px;
  font-weight: 750;
  line-height: 1.5;
}

.alert-error {
  color: #b91c1c;
  border-color: rgba(220, 38, 38, .18);
  background: #fff1f2;
}

.alert-success {
  color: #166534;
  border-color: rgba(22, 163, 74, .20);
  background: #f0fdf4;
}

.form-group {
  margin-bottom: 17px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  color: #334155;
  font-size: 13px;
  font-weight: 900;
}

.form-group input {
  width: 100%;
  min-height: 50px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 15px;
  outline: none;
  color: var(--text);
  background: #fff;
  font-size: 15px;
  transition: border-color .18s ease, box-shadow .18s ease;
}

.form-group input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .11);
}

.btn-login {
  width: 100%;
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 18px;
  border: 0;
  border-radius: 17px;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--cyan));
  box-shadow: 0 16px 34px rgba(37, 99, 235, .25);
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, opacity .15s ease;
}

.btn-login:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 20px 38px rgba(37, 99, 235, .30);
}

.btn-login:disabled {
  cursor: wait;
  opacity: .72;
}

.login-note {
  margin-top: 16px;
  padding: 13px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 15px;
  color: var(--muted);
  background: var(--surface-soft);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.55;
}

@media (max-width: 900px) {
  body {
    align-items: flex-start;
    padding: 18px;
  }

  .login-shell {
    max-width: 620px;
    min-height: auto;
    grid-template-columns: 1fr;
    border-radius: 26px;
  }

  .login-hero {
    min-height: 300px;
    padding: 34px;
  }

  .hero-content {
    margin: 46px 0;
  }

  .hero-content h1 {
    font-size: 38px;
  }

  .login-panel {
    padding: 34px;
  }
}

@media (max-width: 560px) {
  body {
    padding: 0;
    background: #fff;
  }

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

  .login-hero {
    min-height: auto;
    padding: 24px;
  }

  .hero-content {
    margin: 34px 0 16px;
  }

  .hero-content h1 {
    font-size: 32px;
  }

  .hero-content p {
    font-size: 13px;
  }

  .feature-list {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 20px;
  }

  .feature-item {
    min-height: 48px;
    padding: 10px;
    font-size: 10px;
  }

  .hero-footer {
    display: none;
  }

  .login-panel {
    padding: 28px 22px 36px;
  }

  .login-title {
    font-size: 30px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: .01ms !important;
    animation-duration: .01ms !important;
  }
}
