:root {
  --lp-navy:   #1f2b66;
  --lp-indigo: #30398D;
  --lp-blue:   #30398D;
  --lp-light:  #f4f5fb;
}

/* ── Body ───────────────────────────────────────────────── */
body.login-body {
  margin: 0;
  padding: 0 !important;   /* cancels the 100px header-offset from base template */
  min-height: 100vh;
  background: var(--lp-navy);
  overflow: hidden;
}

@media (max-width: 640px) {
  body.login-body { overflow-y: auto; } /* allow scroll when panels stack vertically */
}

/* ── Full-screen wrapper ─────────────────────────────────── */
.login-wrapper {
  min-height: 100vh;
  display: flex;
  align-items: stretch;
}

/* ── Brand panel (left) ─────────────────────────────────── */
.login-brand-panel {
  flex: 0 0 42%;
  background: linear-gradient(150deg, #30398D 0%, #1f2b66 55%, #111440 100%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 3rem 2.5rem;
  position: relative;
  overflow: hidden;
}

/* Decorative circles */
.login-brand-panel::before {
  content: "";
  position: absolute;
  width: 360px;
  height: 360px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .07);
  top: -100px;
  right: -120px;
  pointer-events: none;
}
.login-brand-panel::after {
  content: "";
  position: absolute;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  background: rgba(64, 84, 216, .22);
  bottom: -80px;
  left: -80px;
  pointer-events: none;
}
.lbp-ring {
  position: absolute;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .05);
  bottom: 60px;
  right: -50px;
  pointer-events: none;
}

.lbp-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 320px;
}

.lbp-logo {
  width: 160px;
  max-width: 70%;
  margin-bottom: 2.2rem;
  filter: brightness(0) invert(1);
  opacity: .95;
}

.lbp-divider {
  width: 40px;
  height: 3px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .3);
  margin: 0 auto 1.5rem;
}

.lbp-headline {
  font-size: 1.45rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.35;
  margin: 0 0 .75rem;
}

.lbp-sub {
  font-size: .88rem;
  color: rgba(255, 255, 255, .6);
  line-height: 1.6;
  margin: 0;
}

.lbp-dots {
  display: flex;
  justify-content: center;
  gap: .45rem;
  margin-top: 2.5rem;
}
.lbp-dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .25);
}
.lbp-dots span:first-child {
  background: rgba(255, 255, 255, .75);
  width: 18px;
  border-radius: 99px;
}

/* ── Form panel (right) ─────────────────────────────────── */
.login-form-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: #fff;
  padding: 3rem 2rem;
  position: relative;
}

.login-form-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(160deg, rgba(64, 84, 216, .04), transparent 55%);
  pointer-events: none;
}

.login-box {
  width: 100%;
  max-width: 380px;
  position: relative;
  z-index: 1;
}

/* Heading */
.login-heading {
  margin-bottom: 2rem;
}
.login-heading h1 {
  font-size: 1.65rem;
  font-weight: 800;
  color: #1f2a4d;
  margin: 0 0 .35rem;
  letter-spacing: -.01em;
}
.login-heading p {
  font-size: .88rem;
  color: #7b82aa;
  margin: 0;
}

/* Flash messages (inside form panel) */
.login-flash {
  display: flex;
  flex-direction: column;
  gap: .5rem;
  margin-bottom: 1.25rem;
}
.login-flash .lp-alert {
  display: flex;
  align-items: flex-start;
  gap: .6rem;
  border-radius: 10px;
  padding: .75rem .9rem;
  font-size: .87rem;
  font-weight: 500;
  border: none;
}
.login-flash .alert-danger  { background: #fff1f0; color: #8a1c1c; }
.login-flash .alert-warning { background: #fff7e8; color: #9a6a16; }
.login-flash .alert-success { background: #edfdf5; color: #146c43; }
.login-flash .alert-info    { background: #eef5ff; color: #20448c; }
.login-flash .lp-alert-icon { font-size: 1rem; margin-top: .1rem; flex-shrink: 0; }

/* Form fields */
.login-field {
  margin-bottom: 1.1rem;
}
.login-field label {
  display: block;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: #5d6389;
  margin-bottom: .45rem;
}
.login-input-wrap {
  position: relative;
}
.login-input-wrap .field-icon {
  position: absolute;
  left: .88rem;
  top: 50%;
  transform: translateY(-50%);
  color: #b0b7d8;
  font-size: .88rem;
  pointer-events: none;
  transition: color .18s;
}
.login-input-wrap input {
  width: 100%;
  padding: .7rem .88rem .7rem 2.6rem;
  border-radius: 8px;
  border: 1.5px solid rgba(48,57,141,.18);
  font-size: .94rem;
  color: #1f2a4d;
  background: #fafbff;
  transition: border .18s, box-shadow .18s, background .18s;
  outline: none;
  -webkit-appearance: none;
}
.login-input-wrap input:focus {
  border-color: var(--lp-blue);
  box-shadow: 0 0 0 3px rgba(48, 57, 141, .11);
  background: #fff;
}
.login-input-wrap input:focus + .field-icon,
.login-input-wrap .field-icon:has(~ input:focus) {
  color: var(--lp-blue);
}
.login-input-wrap input:focus ~ .field-icon {
  color: var(--lp-blue);
}

/* Password toggle */
.login-input-wrap .pw-toggle {
  position: absolute;
  right: .75rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  padding: .25rem .3rem;
  cursor: pointer;
  color: #b0b7d8;
  font-size: .85rem;
  line-height: 1;
  border-radius: 6px;
  transition: color .16s, background .16s;
}
.login-input-wrap .pw-toggle:hover {
  color: var(--lp-indigo);
  background: rgba(45, 60, 174, .07);
}

/* Submit */
.login-submit {
  display: block;
  width: 100%;
  padding: .82rem 1rem;
  margin-top: 1.6rem;
  border: none;
  border-radius: 8px;
  font-size: .95rem;
  font-weight: 700;
  letter-spacing: .02em;
  color: #fff;
  background: #30398D;
  box-shadow: 0 4px 14px rgba(31, 43, 102, .28);
  cursor: pointer;
  transition: background .15s, box-shadow .15s, transform .1s;
}
.login-submit:hover,
.login-submit:focus-visible {
  background: #1f2b66;
  box-shadow: 0 6px 18px rgba(31, 43, 102, .35);
  transform: translateY(-1px);
  outline: none;
}
.login-submit:active {
  transform: translateY(0);
}

/* Footer help */
.login-footer {
  margin-top: 1.5rem;
  text-align: center;
  font-size: .82rem;
  color: #9199c0;
}
.login-footer a {
  color: var(--lp-blue);
  font-weight: 600;
  text-decoration: none;
}
.login-footer a:hover {
  text-decoration: underline;
}

/* Copyright strip */
.login-copy {
  position: absolute;
  bottom: 1.2rem;
  left: 0;
  right: 0;
  text-align: center;
  font-size: .75rem;
  color: #c4c8e0;
}

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 860px) {
  .login-brand-panel { flex: 0 0 38%; padding: 2.5rem 1.8rem; }
  .lbp-headline { font-size: 1.2rem; }
}

@media (max-width: 640px) {
  .login-wrapper { flex-direction: column; }

  .login-brand-panel {
    flex: none;
    padding: 2rem 1.5rem 2.2rem;
    border-radius: 0 0 28px 28px;
  }
  .lbp-logo { width: 120px; margin-bottom: 1.2rem; }
  .lbp-headline { font-size: 1.1rem; }
  .lbp-sub { display: none; }
  .lbp-dots { margin-top: 1.2rem; }

  .login-form-panel {
    padding: 2.2rem 1.4rem 3.5rem;
    justify-content: flex-start;
    padding-top: 2.4rem;
  }
  .login-copy { bottom: .8rem; }
}
