body.log-bg,
body.reg-bg {
  min-height: 100vh;
  margin: 0;
  background: #f4f8fb !important;
  color: #17233c;
  overflow-x: hidden;
}

body.log-bg > .row,
body.reg-bg > .row {
  margin-right: 0;
  margin-left: 0;
  margin-bottom: 0;
}

body.log-bg > .row > .col,
body.reg-bg > .row > .col {
  padding-right: 0;
  padding-left: 0;
}

body.log-bg .container,
body.reg-bg .container {
  width: 100% !important;
  max-width: none;
  padding: 0;
}

.auth-modern-page,
.auth-modern-page * {
  box-sizing: border-box;
}

.auth-modern-page,
#login-page.auth-modern-page,
#register-page.auth-modern-page {
  display: flex;
  align-items: stretch;
  justify-content: center;
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
  min-height: 100vh;
  height: auto;
  padding: 22px;
}

.auth-modern-shell {
  display: grid;
  grid-template-columns: minmax(340px, 0.9fr) minmax(420px, 1.1fr);
  overflow: hidden;
  width: min(1080px, 100%);
  min-width: 0;
  min-height: calc(100vh - 44px);
  border: 1px solid rgba(29, 39, 56, 0.08);
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 24px 72px rgba(29, 39, 56, 0.14);
}

.auth-story-panel {
  display: flex;
  position: relative;
  flex-direction: column;
  justify-content: space-between;
  width: 100%;
  min-width: 0;
  min-height: 600px;
  padding: 34px;
  background-position: center;
  background-size: cover;
  color: #ffffff;
}

.auth-story-panel:before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(17, 24, 39, 0.72), rgba(17, 24, 39, 0.5) 38%, rgba(17, 24, 39, 0.74));
}

.auth-story-login {
  background-image: url("../../luvion/img/local/uganda-currency-coins.jpg");
  background-position: center 74%;
}

.auth-story-register {
  background-image: url("../../luvion/img/local/kampala-business-front.jpg");
  background-position: center center;
}

.auth-logo,
.auth-story-content {
  position: relative;
  z-index: 1;
}

.auth-logo {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  max-width: 180px;
  min-height: 54px;
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 14px 34px rgba(17, 24, 39, 0.2);
}

.auth-logo img {
  display: block;
  width: 148px;
  height: auto;
}

.auth-story-content {
  max-width: 440px;
  padding-top: 90px;
}

.auth-eyebrow {
  display: inline-flex;
  align-items: center;
  margin-bottom: 14px;
  color: #2dd4bf;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.auth-story-content h1 {
  margin: 0;
  color: #ffffff;
  font-size: 32px;
  font-weight: 900;
  line-height: 1.12;
  letter-spacing: 0;
  overflow-wrap: break-word;
}

.auth-story-content p {
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: 16px;
  line-height: 1.7;
}

.auth-trust-line {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 24px;
  color: rgba(255, 255, 255, 0.9);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.45;
}

.auth-trust-line span + span {
  position: relative;
}

.auth-trust-line span + span:before {
  content: "";
  position: absolute;
  top: 50%;
  left: -11px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #2dd4bf;
  transform: translateY(-50%);
}

.auth-form-panel {
  display: flex;
  position: relative;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-width: 0;
  padding: 44px;
  background: linear-gradient(180deg, #ffffff, #f8fbfd);
}

.auth-form-card {
  width: min(100%, 460px);
  min-width: 0;
}

.auth-register-page .auth-form-card {
  width: min(100%, 620px);
  min-width: 0;
}

.auth-card-header {
  margin-bottom: 24px;
}

.auth-home-shortcut {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  background: #ffffff;
  color: #136f63;
  text-decoration: none;
}

.auth-home-shortcut:hover,
.auth-home-shortcut:focus {
  border-color: #136f63;
  background: rgba(19, 111, 99, 0.08);
  color: #136f63;
  text-decoration: none;
}

.auth-home-shortcut .material-icons {
  font-size: 21px;
}

.auth-home-top {
  position: absolute;
  top: 34px;
  right: 34px;
  z-index: 2;
}

.auth-card-header h2 {
  margin: 0;
  color: #17233c;
  font-size: 31px;
  font-weight: 900;
  line-height: 1.12;
  letter-spacing: 0;
}

.auth-card-header p {
  margin: 10px 0 0;
  color: #506174;
  font-size: 15px;
  line-height: 1.65;
}

.auth-form {
  display: grid;
  gap: 15px;
  margin: 0;
  min-width: 0;
}

.auth-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  min-width: 0;
}

.auth-field {
  display: grid;
  position: relative;
  gap: 8px;
  margin: 0;
  min-width: 0;
  color: #17233c;
  font-size: 13px;
  font-weight: 800;
}

.auth-field > span {
  color: #17233c;
  font-size: 13px;
  font-weight: 900;
  line-height: 1.25;
}

.auth-field > .material-icons {
  position: absolute;
  top: 40px;
  left: 15px;
  z-index: 1;
  color: #136f63;
  font-size: 20px;
  line-height: 1;
  pointer-events: none;
}

.auth-field input[type="text"],
.auth-field input[type="tel"],
.auth-field input[type="email"],
.auth-field input[type="password"],
.auth-field select {
  box-sizing: border-box !important;
  width: 100% !important;
  height: 52px !important;
  margin: 0 !important;
  padding: 0 14px 0 48px !important;
  border: 1px solid #d9e2ec !important;
  border-radius: 8px !important;
  background: #ffffff !important;
  color: #17233c !important;
  font-size: 15px !important;
  font-weight: 700 !important;
  line-height: 52px !important;
  outline: 0 !important;
  box-shadow: none !important;
}

.auth-field select {
  display: block !important;
  appearance: auto;
  cursor: pointer;
}

.auth-field input:focus,
.auth-field select:focus {
  border-color: #136f63 !important;
  box-shadow: 0 0 0 4px rgba(19, 111, 99, 0.12) !important;
}

.auth-field input::placeholder {
  color: #8492a4;
  font-weight: 600;
}

.auth-field input.is-invalid,
.auth-field select.is-invalid {
  border-color: #d92d20 !important;
}

.auth-error,
.auth-field div.error {
  margin: 0;
  color: #d92d20;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.auth-alert {
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.45;
}

.auth-alert.success {
  border: 1px solid rgba(19, 111, 99, 0.18);
  background: rgba(19, 111, 99, 0.08);
  color: #136f63;
}

.auth-captcha-group {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  background: #f6f9fc;
}

.auth-captcha-group .captcha-box {
  display: flex;
  overflow: hidden;
  align-items: center;
  justify-content: center;
  min-height: 66px;
  border: 1px solid #d9e2ec;
  border-radius: 8px;
  background: #ffffff;
}

.auth-captcha-group canvas {
  max-width: 100%;
  height: auto;
}

.auth-checkbox {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  align-items: flex-start;
  margin: 0;
  color: #506174;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.55;
}

.auth-checkbox input[type="checkbox"] {
  position: static !important;
  width: 18px;
  height: 18px;
  margin: 2px 0 0 !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

.auth-checkbox span {
  color: #506174;
}

.auth-checkbox input[type="checkbox"] + span:not(.lever) {
  display: inline;
  height: auto;
  padding-left: 0;
  color: #506174;
  line-height: 1.55;
}

.auth-checkbox input[type="checkbox"] + span:not(.lever):before,
.auth-checkbox input[type="checkbox"] + span:not(.lever):after {
  display: none;
}

.auth-checkbox a,
.auth-form-footer a {
  color: #136f63;
  font-weight: 900;
  text-decoration: none;
}

.auth-checkbox a:hover,
.auth-form-footer a:hover {
  color: #dc3506;
  text-decoration: none;
}

.auth-submit {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  min-height: 52px;
  padding: 0 20px;
  border: 0;
  border-radius: 8px;
  background: linear-gradient(90deg, #ec058c 0%, #ff5b00 100%);
  color: #ffffff;
  font-size: 15px;
  font-weight: 900;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 16px 32px rgba(236, 5, 140, 0.22);
  transition: transform .18s ease, box-shadow .18s ease;
}

.auth-submit:hover,
.auth-submit:focus {
  transform: translateY(-1px);
  box-shadow: 0 18px 36px rgba(220, 53, 6, 0.24);
}

.auth-submit:disabled {
  cursor: wait;
  opacity: 0.7;
  transform: none;
}

.auth-submit .material-icons {
  font-size: 19px;
}

.auth-progress {
  overflow: hidden;
  height: 4px;
  margin: -6px 0 0;
  border-radius: 999px;
  background: #e8eef5;
}

.auth-form-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 2px;
  font-size: 14px;
}

.auth-form-footer.single {
  justify-content: center;
}

@media (max-width: 960px) {
  .auth-modern-page,
  #login-page.auth-modern-page,
  #register-page.auth-modern-page {
    padding: 14px;
  }

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

  .auth-story-panel {
    min-height: 360px;
    padding: 28px;
  }

  .auth-story-content {
    padding-top: 56px;
  }

  .auth-story-content h1 {
    font-size: 28px;
  }

  .auth-form-panel {
    padding: 30px 22px 34px;
  }
}

@media (max-width: 640px) {
  body.log-bg,
  body.reg-bg,
  body.log-bg > .row,
  body.reg-bg > .row,
  body.log-bg > .row > .col,
  body.reg-bg > .row > .col,
  body.log-bg .container,
  body.reg-bg .container {
    overflow-x: hidden !important;
    width: 100vw !important;
    max-width: 100vw !important;
    margin-right: 0 !important;
    margin-left: 0 !important;
    padding-right: 0 !important;
    padding-left: 0 !important;
  }

  body.reg-bg {
    margin-top: 0;
  }

  .auth-modern-page,
  #login-page.auth-modern-page,
  #register-page.auth-modern-page {
    display: block;
    width: 100vw !important;
    max-width: 100vw !important;
    padding: 0 !important;
  }

  .auth-modern-shell {
    display: block !important;
    width: 100vw !important;
    max-width: 100vw !important;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .auth-story-panel {
    width: 100vw !important;
    max-width: 100vw !important;
    min-height: 190px;
    padding: 22px !important;
  }

  .auth-logo {
    max-width: 154px;
    min-height: 48px;
  }

  .auth-logo img {
    width: 128px;
  }

  .auth-story-content {
    display: none;
  }

  .auth-story-content h1 {
    font-size: 25px;
  }

  .auth-story-content p {
    font-size: 14px;
    line-height: 1.6;
  }

  .auth-trust-line {
    margin-top: 18px;
    font-size: 12px;
  }

  .auth-form-panel {
    align-items: flex-start;
    justify-content: flex-start;
    width: 100vw !important;
    max-width: 100vw !important;
    padding: 26px 18px 34px !important;
  }

  .auth-home-top {
    top: 18px;
    right: 18px;
  }

  .auth-form-card,
  .auth-register-page .auth-form-card,
  .auth-login-page .auth-form-card {
    width: 100% !important;
    max-width: 354px !important;
    margin: 0;
  }

  .auth-card-header h2 {
    font-size: 28px;
  }

  .auth-form-grid {
    grid-template-columns: 1fr;
  }

  .auth-field input[type="text"],
  .auth-field input[type="tel"],
  .auth-field input[type="email"],
  .auth-field input[type="password"],
  .auth-field select {
    height: 50px !important;
    line-height: 50px !important;
  }

  .auth-form-footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .auth-form-footer.single {
    align-items: center;
  }
}
