.auth-body {
  min-width: 320px;
  min-height: 100vh;
  background: #f4f7fa;
}

.auth-body #main-content {
  min-height: 100vh;
}

.auth-layout {
  display: grid;
  min-height: 100vh;
  grid-template-columns: minmax(300px, 0.88fr) minmax(0, 1.12fr);
  background: #f4f7fa;
}

.auth-brand-panel {
  display: flex;
  min-height: 100%;
  flex-direction: column;
  padding: clamp(2rem, 5vw, 4.5rem);
  background: #163d56;
  color: #fff;
}

.auth-brand {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 0.75rem;
  color: #fff;
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.035em;
  text-decoration: none;
}

.auth-brand:hover,
.auth-brand:focus {
  color: #e4f0f5;
}

.auth-brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.1);
  font-size: 1.25rem;
}

.auth-brand-message {
  max-width: 480px;
  margin: auto 0;
  padding: 5rem 0;
}

.auth-overline {
  margin-bottom: 1rem;
  color: #b7d9ca;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.auth-brand-message h2 {
  max-width: 10ch;
  margin: 0 0 1.2rem;
  color: #fff;
  font-size: clamp(2.4rem, 4.1vw, 3.8rem);
  font-weight: 700;
  letter-spacing: -0.055em;
  line-height: 1.05;
}

.auth-brand-message > p:last-child {
  max-width: 42ch;
  margin: 0;
  color: #d3e1e8;
  font-size: 1.06rem;
  line-height: 1.7;
}

.auth-brand-points {
  display: grid;
  gap: 0.85rem;
  color: #e5eef2;
  font-size: 0.95rem;
}

.auth-brand-points span {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.auth-brand-points i {
  color: #b7d9ca;
  font-size: 1.1rem;
}

.auth-attribution {
  margin: 2rem 0 0;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  color: #c3d4dc;
  font-size: 0.9rem;
}

.auth-attribution a {
  color: #fff;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.auth-main {
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: center;
  padding: clamp(1.25rem, 4vw, 3.5rem);
}

.auth-content {
  width: min(100%, 470px);
  margin-inline: auto;
}

.auth-content-wide {
  width: min(100%, 610px);
}

.auth-card {
  padding: clamp(1.4rem, 3.5vw, 2.5rem);
  border: 1px solid #dce4e9;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 14px 40px rgba(17, 38, 54, 0.08);
}

.auth-card-register {
  width: min(100%, 610px);
  margin-inline: auto;
}

.auth-heading {
  margin: 0 0 0.55rem;
  color: #172b3a;
  font-size: clamp(1.8rem, 4vw, 2.15rem);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 1.15;
}

.auth-page-header .auth-overline {
  margin-bottom: 0.45rem;
}

.auth-page-header .auth-heading {
  font-size: clamp(1.7rem, 2.5vw, 1.95rem);
}

.auth-intro {
  margin: 0 0 1.65rem;
  color: #526576;
  font-size: 1rem;
  line-height: 1.6;
}

.auth-page-header .auth-intro {
  margin-bottom: 0.9rem;
  font-size: 0.94rem;
}

.auth-form-group {
  margin-bottom: 1.1rem;
}

.auth-form-label {
  display: block;
  margin-bottom: 0.45rem;
  color: #233949;
  font-size: 0.94rem;
  font-weight: 700;
}

.auth-input,
.auth-body .form-control.auth-input {
  width: 100%;
  min-height: 52px;
  padding: 0.75rem 0.9rem;
  border: 1px solid #aebdc6;
  border-radius: 8px;
  background: #fff;
  color: #172b3a;
  font-size: 1rem;
  line-height: 1.4;
  box-shadow: none;
}

.auth-input::placeholder {
  color: #687b88;
  opacity: 1;
}

.auth-input:focus,
.auth-body .form-control.auth-input:focus {
  border-color: #1b4965;
  box-shadow: 0 0 0 3px rgba(27, 73, 101, 0.17);
}

.auth-input[aria-invalid="true"] {
  border-color: #b42318;
}

.auth-password-wrap {
  position: relative;
}

.auth-password-wrap .auth-input {
  padding-right: 5rem;
}

.auth-password-toggle {
  position: absolute;
  top: 50%;
  right: 0.6rem;
  min-width: 44px;
  min-height: 40px;
  padding: 0.35rem 0.55rem;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #1b4965;
  font-size: 0.9rem;
  font-weight: 700;
  transform: translateY(-50%);
}

.auth-password-toggle:hover {
  background: #edf3f6;
}

.auth-help {
  margin: 0.5rem 0 0;
  color: #526576;
  font-size: 0.88rem;
  line-height: 1.55;
}

.auth-password-guidance {
  margin-top: 0.7rem;
  padding: 0.8rem 0.9rem;
  border-radius: 7px;
  background: #f3f7f8;
  color: #435b69;
  font-size: 0.87rem;
  line-height: 1.5;
}

.auth-password-guidance strong {
  display: block;
  margin-bottom: 0.2rem;
  color: #263f50;
}

.auth-field-errors {
  margin: 0.4rem 0 0;
  padding-left: 1.2rem;
  color: #a51f16;
  font-size: 0.88rem;
  line-height: 1.45;
}

.auth-field-errors li + li {
  margin-top: 0.15rem;
}

.auth-inline-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 0.15rem 0 1.35rem;
}

.auth-remember {
  display: flex;
  min-height: 44px;
  align-items: center;
  gap: 0.55rem;
  color: #435b69;
  font-size: 0.92rem;
}

.auth-remember .form-check-input {
  width: 1.15rem;
  height: 1.15rem;
  margin: 0;
  border-color: #7d909c;
}

.auth-link {
  color: #1b4965;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.auth-link:hover,
.auth-link:focus {
  color: #13354a;
}

.auth-primary-button {
  display: inline-flex;
  min-height: 52px;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1rem;
  border: 1px solid #1b4965;
  border-radius: 8px;
  background: #1b4965;
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
}

.auth-primary-button:hover,
.auth-primary-button:focus {
  border-color: #13354a;
  background: #13354a;
  color: #fff;
}

.auth-primary-button:disabled {
  opacity: 0.7;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin: 1.35rem 0;
  color: #657985;
  font-size: 0.84rem;
}

.auth-divider::before,
.auth-divider::after {
  height: 1px;
  flex: 1;
  background: #e1e8ec;
  content: "";
}

.auth-secondary-links {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin: 0;
  color: #526576;
  font-size: 0.93rem;
  text-align: center;
}

.auth-secondary-links p {
  margin: 0;
}

.auth-notices {
  display: grid;
  gap: 0.7rem;
  margin-bottom: 1rem;
}

.auth-notice {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  padding: 0.9rem 1rem;
  border: 1px solid #b5cbd6;
  border-radius: 8px;
  background: #edf5f8;
  color: #1e455d;
  font-size: 0.94rem;
  line-height: 1.5;
}

.auth-notice > i {
  margin-top: 0.15rem;
  font-size: 1.05rem;
}

.auth-notice-success {
  border-color: #9dcab4;
  background: #eff8f2;
  color: #175c3c;
}

.auth-notice-danger,
.auth-notice-error {
  border-color: #e6aaa5;
  background: #fff3f2;
  color: #8e2119;
}

.auth-notice-warning {
  border-color: #e5c28d;
  background: #fff8eb;
  color: #74420d;
}

.auth-support {
  margin: 1.25rem 0 0;
  color: #526576;
  font-size: 0.9rem;
  text-align: center;
}

.auth-support a {
  color: #1b4965;
  font-weight: 700;
}

.auth-mobile-attribution {
  display: none;
}

.auth-body :focus-visible {
  outline: 3px solid #d97706 !important;
  outline-offset: 3px !important;
}

@media (max-width: 900px) {
  .auth-layout {
    grid-template-columns: minmax(250px, 0.75fr) minmax(0, 1.25fr);
  }

  .auth-brand-panel {
    padding: 2rem;
  }

  .auth-brand-message h2 {
    font-size: clamp(2.2rem, 4vw, 3rem);
  }

  .auth-main {
    padding: 1.5rem;
  }
}

@media (max-width: 680px) {
  .auth-layout {
    grid-template-columns: 1fr;
  }

  .auth-brand-panel {
    min-height: auto;
    padding: 1.25rem clamp(1rem, 5vw, 1.75rem);
  }

  .auth-brand {
    font-size: 1.25rem;
  }

  .auth-brand-mark {
    width: 36px;
    height: 36px;
    font-size: 1.05rem;
  }

  .auth-brand-message,
  .auth-brand-points,
  .auth-attribution {
    display: none;
  }

  .auth-main {
    justify-content: flex-start;
    padding: 1.25rem clamp(1rem, 5vw, 1.75rem) 2rem;
  }

  .auth-content,
  .auth-content-wide {
    width: min(100%, 520px);
  }

  .auth-card-register {
    width: 100%;
  }

  .auth-mobile-attribution {
    display: block;
    padding: 1rem;
    color: #657985;
    font-size: 0.82rem;
    text-align: center;
  }
}

@media (max-width: 380px) {
  .auth-inline-options {
    align-items: flex-start;
    flex-direction: column;
  }

  .auth-card {
    padding: 1.25rem;
  }
}

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

.auth-register-page .auth-layout {
  min-height: 100vh;
  min-height: 100svh;
}

.auth-register-page .auth-main {
  padding-block: clamp(0.75rem, 2.5vh, 1.75rem);
}

.auth-register-page .auth-card-register {
  padding: clamp(1.15rem, 2vw, 1.65rem);
}

.auth-register-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0 1rem;
}

.auth-register-grid .auth-form-group {
  min-width: 0;
  margin-bottom: 0.7rem;
}

.auth-register-grid .auth-form-label {
  margin-bottom: 0.3rem;
  font-size: 0.89rem;
}

.auth-register-page .form-control.auth-input {
  min-height: 46px;
  padding-block: 0.6rem;
}

.auth-register-grid .auth-help {
  margin-top: 0.3rem;
  font-size: 0.78rem;
  line-height: 1.35;
}

.auth-register-page .auth-primary-button {
  min-height: 48px;
}

.auth-register-page .auth-divider {
  margin-block: 0.8rem;
}

.auth-register-page .auth-support {
  margin-top: 0.6rem;
}

.auth-account-prompt {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.2rem 0.55rem;
  margin-top: 0.9rem;
  padding: 0.55rem 0.75rem;
  border: 1px solid #e1e8ec;
  border-radius: 8px;
  background: #f5f8fa;
  color: #526576;
  font-size: 0.9rem;
  text-align: center;
}

.auth-account-prompt-link {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  gap: 0.3rem;
  padding: 0.3rem 0.55rem;
  border: 1px solid transparent;
  border-radius: 6px;
  color: #1b4965;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.auth-account-prompt-link:hover,
.auth-account-prompt-link:focus {
  border-color: #cbd9df;
  background: #edf3f6;
  color: #13354a;
}

@media (max-width: 760px) {
  .auth-register-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

@media (max-width: 680px) {
  .auth-register-page .auth-main {
    padding-block: 0.75rem 1rem;
  }

  .auth-register-page .auth-card-register {
    padding: clamp(1.1rem, 4vw, 1.5rem);
  }
}

.auth-login-page .auth-layout {
  min-height: 100vh;
  min-height: 100svh;
}

.auth-login-page .auth-main {
  padding: clamp(0.75rem, 2.5vh, 2rem) clamp(1rem, 3vw, 2.75rem);
}

.auth-login-page .auth-card {
  padding: clamp(1.2rem, 2vw, 1.8rem);
}

.auth-login-page .auth-form-group {
  margin-bottom: 0.8rem;
}

.auth-login-page .form-control.auth-input {
  min-height: 48px;
}

.auth-login-page .auth-inline-options {
  margin-bottom: 0.85rem;
}

.auth-login-page .auth-divider {
  margin-block: 0.9rem;
}

.auth-login-page .auth-support {
  margin-top: 0.75rem;
}

@media (max-width: 680px) {
  .auth-login-page .auth-main {
    justify-content: flex-start;
    padding: 0.75rem clamp(1rem, 5vw, 1.75rem) 1rem;
  }

  .auth-login-page .auth-card {
    padding: clamp(1.15rem, 4vw, 1.5rem);
  }
}

@media (max-height: 760px) and (min-width: 681px) {
  .auth-login-page .auth-brand-panel {
    padding-block: 1.5rem;
  }

  .auth-login-page .auth-brand-message {
    padding-block: 2rem;
  }

  .auth-login-page .auth-brand-message h2 {
    font-size: clamp(2rem, 4vh, 2.8rem);
  }

  .auth-login-page .auth-brand-points {
    gap: 0.5rem;
  }
}
