* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
button, input { font-family: inherit; }

.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 28px 24px;
  color: #1c2434;
  font-family: "Segoe UI", system-ui, sans-serif;
  background: #0c1736;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

.glow {
  position: fixed;
  border-radius: 50%;
  pointer-events: none;
  filter: blur(18px);
}
.glow-a {
  width: 460px;
  height: 420px;
  left: -120px;
  top: -150px;
  background: radial-gradient(circle, rgba(98, 112, 255, .95) 0%, rgba(70, 90, 240, .35) 42%, transparent 70%);
}
.glow-b {
  width: 520px;
  height: 420px;
  right: -160px;
  bottom: -180px;
  background: radial-gradient(circle, rgba(72, 78, 220, .9) 0%, rgba(40, 48, 160, .28) 46%, transparent 72%);
}
.glow-c {
  width: 340px;
  height: 280px;
  right: 6%;
  top: -90px;
  background: radial-gradient(circle, rgba(48, 78, 190, .75) 0%, transparent 68%);
}
.glow-d {
  width: 380px;
  height: 300px;
  left: 4%;
  bottom: -120px;
  background: radial-gradient(circle, rgba(36, 58, 170, .8) 0%, transparent 70%);
}

.login-card {
  position: relative;
  z-index: 1;
  width: min(836px, calc(100vw - 64px));
  height: min(548px, calc(100vh - 48px));
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-radius: 28px;
  overflow: hidden;
  background: #f7f9fc;
  box-shadow:
    0 30px 70px rgba(3, 8, 30, .45),
    0 8px 24px rgba(3, 8, 30, .28);
}

.login-art {
  position: relative;
  min-width: 0;
  color: #fff;
  background-color: #1236b0;
  background-position: 2% 78%;
  background-size: cover;
  background-repeat: no-repeat;
}
.art-brand {
  position: absolute;
  top: 26px;
  left: 28px;
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 1;
}
.art-mark {
  width: 38px;
  height: 38px;
  flex: none;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 40, .25));
}
.art-mark svg { width: 100%; height: 100%; display: block; }
.art-name strong {
  display: block;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.05;
}
.art-name small {
  display: block;
  margin-top: 1px;
  font-size: 11px;
  font-weight: 500;
  opacity: .92;
}
.art-copy {
  position: absolute;
  left: 34px;
  right: 28px;
  top: 38%;
  transform: translateY(-52%);
  z-index: 1;
  text-shadow: 0 8px 24px rgba(8, 16, 70, .28);
}
.kicker {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  opacity: .95;
}
.art-copy h1 {
  margin: 10px 0 14px;
  font-size: 40px;
  line-height: 1.08;
  font-weight: 700;
  letter-spacing: -0.035em;
}
.tagline {
  margin: 0;
  max-width: 280px;
  font-size: 15px;
  font-weight: 500;
  font-style: italic;
  line-height: 1.45;
  opacity: .96;
}

.login-pane {
  position: relative;
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 26px 48px 18px;
  background: #f7f9fc;
}
.dots {
  position: absolute;
  top: 22px;
  right: 26px;
  display: flex;
  gap: 8px;
}
.dots i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #8ea2f6;
  display: block;
}
.dots i:nth-child(2) { background: #7d90f4; }
.dots i:nth-child(3) { background: #9aaff8; }

.pane-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 0;
}
.avatar {
  width: 68px;
  height: 68px;
  margin: 0 auto 12px;
  border-radius: 50%;
  background: #e7efff;
  color: #7ea2f5;
  display: grid;
  place-items: center;
}
.avatar svg { width: 34px; height: 34px; }
.login-pane h2 {
  margin: 0;
  text-align: center;
  font-size: 32px;
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: #1a2233;
}
.welcome {
  margin: 6px 0 0;
  text-align: center;
  color: #9aa3b2;
  font-size: 13px;
  font-weight: 400;
}
.alert {
  min-height: 18px;
  margin: 8px 0 6px;
  text-align: center;
  color: #e11d48;
  font-size: 12.5px;
  font-weight: 600;
}

.field {
  position: relative;
  display: block;
  margin-top: 12px;
}
.field-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  width: 18px;
  height: 18px;
  color: #b0b8c6;
  transform: translateY(-50%);
  display: grid;
}
.field-icon svg { width: 18px; height: 18px; }
.field input {
  width: 100%;
  height: 48px;
  border: 1px solid #e3e8f0;
  border-radius: 11px;
  background: #fff;
  color: #1c2434;
  font-size: 14px;
  font-weight: 500;
  padding: 0 44px 0 42px;
  outline: none;
}
.field input::placeholder { color: #a8b1c0; font-weight: 400; }
.field input:focus { border-color: #8eabf8; box-shadow: 0 0 0 3px rgba(90, 120, 255, .12); }
.eye {
  position: absolute;
  right: 8px;
  top: 50%;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: #b0b8c6;
  transform: translateY(-50%);
  display: grid;
  place-items: center;
  cursor: pointer;
}
.eye svg { width: 18px; height: 18px; }
.eye:hover { color: #6d7cff; }

.meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 14px 2px 16px;
}
.remember {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #8b95a6;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  user-select: none;
}
.remember input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.box {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  border: 1.5px solid #c5ceda;
  background: #fff;
  display: grid;
  place-items: center;
  flex: none;
}
.remember input:checked + .box {
  background: #3b82f6;
  border-color: #3b82f6;
}
.remember input:checked + .box::after {
  content: "";
  width: 8px;
  height: 4px;
  border-left: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: translateY(-1px) rotate(-45deg);
}
.remember input:focus-visible + .box { box-shadow: 0 0 0 3px rgba(59, 130, 246, .25); }
.forgot {
  border: 0;
  background: transparent;
  padding: 0;
  color: #6d63f6;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
}
.forgot:hover { color: #564bdf; }

.submit {
  width: 100%;
  height: 48px;
  border: 0;
  border-radius: 11px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .01em;
  cursor: pointer;
  background: linear-gradient(90deg, #2f73f8 0%, #4d63fb 42%, #7a58ff 78%, #9a55fb 100%);
  box-shadow: 0 10px 22px rgba(78, 88, 250, .32);
}
.submit svg { width: 18px; height: 18px; }
.submit:hover { filter: brightness(1.05); }
.submit:active { transform: translateY(1px); }

.foot {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 16px 0 6px;
  color: #b0b8c7;
  font-size: 12px;
  font-weight: 500;
}
.foot::before,
.foot::after {
  content: "";
  flex: 1;
  height: 1px;
  background: #e4e9f1;
}

.forgot-layer {
  position: fixed;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  background: rgba(8, 16, 40, .45);
  padding: 24px;
}
.forgot-layer[hidden] { display: none; }
.forgot-card {
  width: min(380px, 100%);
  background: #fff;
  border-radius: 18px;
  padding: 22px 22px 18px;
  box-shadow: 0 24px 60px rgba(8, 16, 40, .28);
}
.forgot-card h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
}
.forgot-card p {
  margin: 8px 0 16px;
  color: #6d788a;
  font-size: 14px;
  line-height: 1.45;
}
.forgot-card button {
  height: 40px;
  padding: 0 16px;
  border: 0;
  border-radius: 10px;
  background: #3b6cff;
  color: #fff;
  font-weight: 600;
  cursor: pointer;
}

@media (max-width: 860px) {
  .login-page { overflow: auto; padding: 18px; }
  .login-card {
    width: min(460px, 100%);
    height: auto;
    min-height: 0;
    grid-template-columns: 1fr;
  }
  .login-art { min-height: 240px; }
  .art-copy h1 { font-size: 32px; }
  .login-pane { padding: 28px 22px 16px; }
  .pane-main { padding-top: 12px; }
}
