/* ==========================================================================
   Auth pages v2 (MOA_Final_27112026/login.html)
   Sign in, Create account, Forgot password (Backbone logistration views),
   Reset password confirm + complete (registration/*.html).

   Values are the design's *resolved* cascade (login.html inline <style>s on top
   of style.css / inner-banner-center.css), so the pages match it pixel for pixel.
   Everything is scoped to .moa-auth so the legacy .login-register styles of
   core edx-platform never apply.
   ========================================================================== */
.moa-auth {
  --moa-auth-red: #ee343b;
  --moa-auth-ink: #171c29;
  --moa-auth-muted: #6d7584;
  /* "MHP Montserrat" = the variable Montserrat (400-800) site_header.css loads on every page */
  --moa-auth-font: "MHP Montserrat", Montserrat, Arial, sans-serif;
  background: #f7f8fa;
  padding: 55px 0 70px;
  font-family: var(--moa-auth-font);
  color: var(--moa-auth-ink);
}
.moa-auth *, .moa-auth *::before, .moa-auth *::after { box-sizing: border-box; }
.moa-auth a { color: inherit; text-decoration: none; }
/* Legacy global sheets (common_dev.css, sumac_override.css, lms-main) force Roboto / Inter /
   italic Crimson labels and 20px paragraph links with !important: neutralise them here. */
.moa-auth :is(h1, h2, h3, h4, p, a, span, div, label, input, select, textarea, button, li, strong, b, ul) {
  font-family: var(--moa-auth-font) !important; font-style: normal !important; text-shadow: none;
}
.moa-auth p a:not(.btn), .moa-auth p a:visited:not(.btn) { font-size: inherit !important; color: var(--moa-auth-red) !important; }
.moa-auth .hidden { display: none !important; }
.moa-auth .sr, .moa-auth .sr-only {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ---------- Card (design: main) ---------- */
.moa-auth .moa-auth-card {
  max-width: 1300px; margin: 0 auto; padding: 0 25px;
  display: grid; grid-template-columns: 1.05fr .95fr; min-height: 620px;
  border-radius: 24px; overflow: hidden; box-shadow: 0 20px 65px #2222220e; background: #fff;
  font-size: 16px; line-height: normal; text-align: start;
}
.moa-auth .moa-auth-card:focus { outline: none; }

/* ---------- Hero (design: section.hero) ---------- */
.moa-auth .moa-auth-hero {
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 58px 60px 56px;
  background: linear-gradient(135deg, #a91b27, #ee343b 65%, #f56a6c);
  color: #fff; text-align: center;
}
.moa-auth .moa-auth-hero::before,
.moa-auth .moa-auth-hero::after {
  content: ""; position: absolute; border: 1px solid #ffffff38; border-radius: 50%;
  width: 560px; height: 560px; right: -280px; top: -160px;
}
.moa-auth .moa-auth-hero::after { width: 400px; height: 400px; right: -180px; top: -75px; }
.moa-auth .moa-auth-hero > * { position: relative; z-index: 1; }
.moa-auth .moa-auth-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 700; letter-spacing: 1.8px; text-transform: uppercase; color: #fff;
}
.moa-auth .moa-auth-dot { display: block; width: 8px; height: 8px; background: #fff; border-radius: 50%; }
.moa-auth .moa-auth-hero h1 {
  font-family: var(--moa-auth-font);
  font-size: clamp(30px, 3.1vw, 50px); font-weight: 800; line-height: 1.18; letter-spacing: .2px;
  margin: 10px 0 0; padding: 0; color: #fff !important; text-transform: none;
}
.moa-auth .moa-auth-hero p {
  font-size: 15px; line-height: 1.6; max-width: 430px; margin: 14px auto 25px;
  color: #fff9; font-weight: 400;
}
.moa-auth .moa-auth-features { display: flex; flex-wrap: wrap; gap: 13px; }
.moa-auth .moa-auth-feature {
  border: 1px solid #ffffff55; background: #ffffff1b; padding: 13px 15px; border-radius: 13px;
  font-size: 12px; font-weight: 600; line-height: normal; color: #fff;
}

/* ---------- Form side (design: .formside / .formwrap) ---------- */
.moa-auth .moa-auth-formside { display: flex; align-items: center; justify-content: center; padding: 65px 50px; min-width: 0; }
.moa-auth .moa-auth-formwrap { width: 100%; max-width: 390px; }
.moa-auth .moa-auth-formwrap:has(#register-form:not(.hidden)) { max-width: 480px; }
.moa-auth .moa-auth-formwrap .form-type { margin: 0; padding: 0; border: 0; width: 100%; max-width: none; min-width: 0; float: none; }
/* Legacy wrappers (custom_css/*, lms-main) give .form-wrapper padding, borders and a max-width. */
.moa-auth .moa-auth-formwrap .form-wrapper {
  margin: 0 !important; padding: 0 !important; border: 0 !important; border-radius: 0 !important;
  max-width: none !important; width: 100% !important; background: none !important; box-shadow: none !important;
}
.moa-auth input#password-reset-email::placeholder { visibility: visible !important; }

.moa-auth .moa-auth-intro {
  font-size: 12px; font-weight: 800; letter-spacing: 2px; text-transform: uppercase; color: var(--moa-auth-red);
}
.moa-auth .moa-auth-formwrap h2.moa-auth-title {
  font-family: var(--moa-auth-font);
  font-size: 32px; font-weight: 700; line-height: normal; letter-spacing: -1px;
  margin: 12px 0 8px; padding: 0; border: 0; color: var(--moa-auth-ink); text-transform: none;
}
.moa-auth .moa-auth-sub { font-size: 13px; line-height: 1.8; color: var(--moa-auth-muted); margin: 0 0 30px; }

/* Tabs */
.moa-auth .moa-auth-tabs {
  display: grid; grid-template-columns: 1fr 1fr; background: #f4f5f7; border-radius: 13px; padding: 5px; margin-bottom: 27px;
}
.moa-auth .moa-auth-tab {
  border: 0; background: transparent; box-shadow: none; text-shadow: none; margin: 0;
  padding: 13px; border-radius: 10px; font: 700 13px var(--moa-auth-font); line-height: normal;
  cursor: pointer; color: #697080; text-align: center; text-transform: none; letter-spacing: normal;
}
.moa-auth .moa-auth-tab:hover { color: var(--moa-auth-red); background: transparent; }
.moa-auth .moa-auth-tab:focus, .moa-auth .reset-help:focus{box-shadow: none !important;}
.moa-auth .moa-auth-tab.is-active { background: #fff; color: var(--moa-auth-red); box-shadow: 0 3px 12px #00000010; cursor: default; }

/* Fields (rendered by student_account/form_field.underscore) */
.moa-auth form { margin: 0; padding: 0; }
.moa-auth form:focus { outline: none; }
.moa-auth .form-field { margin: 0; padding: 0; width: auto; float: none; min-width: 0; position: relative; }
.moa-auth .form-field > label,
.moa-auth .moa-auth-label {
  display: block; position: static; opacity: 1;
  font-family: var(--moa-auth-font); font-size: 12px; font-weight: 700; line-height: normal;
  margin: 17px 0 9px; padding: 0; color: var(--moa-auth-ink); text-transform: none; letter-spacing: normal;
}
.moa-auth .form-field > label .label-text { font-size: inherit !important; font-family: inherit !important; font-weight: inherit; padding: 0 !important; margin: 0 !important; }
.moa-auth .form-field .label-required,
.moa-auth .form-field .label-optional { margin-left: 4px; font-size: 11px; font-weight: 500; color: var(--moa-auth-muted); }
.moa-auth .form-field label .icon.fa { display: none; }
.moa-auth .form-field > label.error { color: #c8232b; }

.moa-auth .form-field input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
.moa-auth .form-field select,
.moa-auth .form-field textarea,
.moa-auth .moa-auth-input {
  display: block; width: 100%; height: auto; min-height: 0; margin: 0;
  padding: 15px 16px; border: 1px solid #dfe2e8 !important; border-radius: 11px;
  font: 500 13px var(--moa-auth-font); font-size: 13px !important; line-height: normal; letter-spacing: normal;
  color: #000; background-color: #fff; box-shadow: none; outline: none; text-shadow: none;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.moa-auth .form-field select { cursor: pointer; }
.moa-auth .form-field select:disabled { color: #000; opacity: 1; background-color: #fff; cursor: default; }
.moa-auth .form-field input::placeholder,
.moa-auth .moa-auth-input::placeholder { color: #757575 !important; opacity: 1 !important; }
.moa-auth .form-field input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]):focus,
.moa-auth .form-field select:focus,
.moa-auth .form-field textarea:focus,
.moa-auth .moa-auth-input:focus { border-color: var(--moa-auth-red) !important; box-shadow: 0 0 0 3px #ee343b14; }
.moa-auth .form-field input.error:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]),
.moa-auth .form-field select.error,
.moa-auth .form-field textarea.error,
.moa-auth .moa-auth-input.error { border-color: var(--moa-auth-red) !important; }
/* number spin buttons (phone) */
.moa-auth .form-field input[type="number"] { -moz-appearance: textfield; appearance: textfield; }
.moa-auth .form-field input[type="number"]::-webkit-outer-spin-button,
.moa-auth .form-field input[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* Password + show/hide (design: .password / .show) */
.moa-auth .moa-auth-password { position: relative; }
.moa-auth .moa-auth-password input:not([type="checkbox"]) { padding-right: 65px !important; }
.moa-auth .moa-auth-show {
  position: absolute; top: 6px; right: 9px; width: 38px; height: 38px; padding: 0; margin: 0;
  display: flex; align-items: center; justify-content: center;
  border: 0; border-radius: 8px; background: none; box-shadow: none; color: var(--moa-auth-red); cursor: pointer;
}
.moa-auth .moa-auth-show:hover,
.moa-auth .moa-auth-show:focus { background: #fff1f2; color: var(--moa-auth-red); }
.moa-auth .moa-auth-show svg { display: block; width: 21px; height: 21px; }

/* Field-level validation messages */
.moa-auth .form-field .tip { display: block; font-size: 11px; line-height: 1.6; font-weight: 500; color: var(--moa-auth-muted); margin: 0; }
.moa-auth .form-field .tip.tip-input { margin-top: 6px; }
.moa-auth #login .form-field .tip.tip-input { display: none; }
.moa-auth .form-field .tip.error { color: #c8232b; font-weight: 600; }
.moa-auth .form-field .tip.error ul { list-style: none; margin: 0; padding: 0; }
.moa-auth .form-field .tip.error li { margin: 6px 0 0; padding: 0; position: static; }
.moa-auth .form-field .tip.error li .fa, .moa-auth .form-field .tip.error .fa-li { display: none; }
.moa-auth .form-field .tip.error > span:not(.sr-only):not(:empty) { display: block; }
.moa-auth .form-field .tip.error > span[id$="-validation-error-msg"]:not(:has(li)):not(:empty) { margin-top: 6px; }
.moa-auth .supplemental-link { margin: 0 0 8px; font-size: 11px; }
.moa-auth .supplemental-link a { color: var(--moa-auth-red); font-weight: 700; }

/* Form-level feedback (FormView.renderErrors / success / account activation) */
.moa-auth .js-form-feedback:focus { outline: none; }
.moa-auth .js-form-feedback .status {
  margin: 0 0 20px; padding: 12px 14px; border-radius: 9px; border: 0;
  background: #fff6f6; color: #934044; font-size: 12px; line-height: 1.7; box-shadow: none;
}
.moa-auth .js-form-feedback .status.submission-success,
.moa-auth .moa-auth-notice.is-success { background: #f0f9f3; color: #20633a; }
.moa-auth .js-form-feedback .status .message-title { margin: 0 0 4px; font: 700 13px/1.5 var(--moa-auth-font); color: inherit; text-transform: none; letter-spacing: normal; }
.moa-auth .js-form-feedback .status .message-copy { margin: 0; padding: 0; list-style: none; font-size: 12px; color: inherit; }
.moa-auth .js-form-feedback .status .message-copy li { margin: 0; padding: 0; list-style: none; }
.moa-auth .js-form-feedback .status .message-copy p { margin: 0 0 6px; line-height: 1.7; font-size: 12px; }
.moa-auth .js-form-feedback .status a,
.moa-auth .moa-auth-notice a { color: var(--moa-auth-red); font-weight: 700; text-decoration: underline; }

/* Remember me / Forgot password (design: .extras) */
.moa-auth .moa-auth-extras { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 17px 0 24px; font-size: 11px; }
.moa-auth .moa-auth-extras label {
  margin: 0; padding: 0; display: flex; align-items: center; gap: 7px; font-size: 11px; font-weight: 700; line-height: normal; color: #555; cursor: pointer;
}
.moa-auth .moa-auth-extras input[type="checkbox"] { margin: 3px 3px 3px 4px; width: 13px; height: 13px; accent-color: var(--moa-auth-red); }
.moa-auth .moa-auth-link,
.moa-auth .moa-auth-extras a,
.moa-auth .moa-auth-bottom a {
  color: var(--moa-auth-red); font-weight: 700; cursor: pointer; background: none; border: 0; padding: 0; font-size: inherit;
}
.moa-auth .moa-auth-link:hover, .moa-auth .moa-auth-extras a:hover, .moa-auth .moa-auth-bottom a:hover { text-decoration: underline; }

/* Submit (design: .submit) */
.moa-auth .moa-auth-submit {
  display: block; width: 100%; margin: 0; padding: 17px !important; border: 0 !important; border-radius: 12px !important;
  background: var(--moa-auth-red); color: #fff; box-shadow: none; text-shadow: none;
  font: 700 13px var(--moa-auth-font); line-height: normal; letter-spacing: normal; text-transform: none;
  cursor: pointer; transition: .2s; height: auto !important; min-height: 0;
}
.moa-auth a.moa-auth-submit, .moa-auth a.moa-auth-submit:visited { color: #fff !important; text-decoration: none !important; text-align: center; }
.moa-auth .moa-auth-submit:hover,
.moa-auth .moa-auth-submit:focus { background: #d6222a; color: #fff; transform: translateY(-2px); box-shadow: none; }
.moa-auth .moa-auth-submit:disabled,
.moa-auth .moa-auth-submit[disabled] { opacity: .65; cursor: wait; transform: none; }

.moa-auth .moa-auth-bottom { text-align: center; font-size: 12px; line-height: 1.8; color: var(--moa-auth-muted); margin: 25px 0 0; }
.moa-auth .moa-auth-notice { margin: 0 0 20px; padding: 12px; border-radius: 9px; background: #fff6f6; color: #934044; font-size: 11px; line-height: 1.7; }

/* ---------- Register specifics ---------- */
/* Profile Name + Username side by side (design: .register-grid) */
.moa-auth #register .required-fields { display: grid; grid-template-columns: 1fr 1fr; column-gap: 14px; }
.moa-auth #register .required-fields > .form-field { grid-column: 1 / -1; }
.moa-auth #register .required-fields > .text-name,
.moa-auth #register .required-fields > .text-username { grid-column: auto; }

/* Consent checkbox (design: .consent-label) */
.moa-auth .form-field.checkbox-terms_of_service,
.moa-auth .form-field.checkbox-honor_code,
.moa-auth .form-field.checkbox-marketing_emails_opt_in,
.moa-auth .form-field.checkbox-optional_fields_toggle {
  display: flex; flex-wrap: wrap; align-items: flex-start; gap: 0 10px; margin: 20px 0;
}
.moa-auth .form-field.checkbox-terms_of_service > input[type="checkbox"],
.moa-auth .form-field.checkbox-honor_code > input[type="checkbox"],
.moa-auth .form-field.checkbox-marketing_emails_opt_in > input[type="checkbox"],
.moa-auth .form-field.checkbox-optional_fields_toggle > input[type="checkbox"] {
  flex: 0 0 auto; width: 13px; height: 13px; margin: 3px 0 0; padding: 0; accent-color: var(--moa-auth-red); cursor: pointer;
}
.moa-auth .form-field[class*="checkbox-"] > label {
  flex: 1 1 0; min-width: 0; margin: 0; font-size: 12px; font-weight: 500; line-height: 1.65; cursor: pointer;
}
.moa-auth .form-field[class*="checkbox-"] > label .label-text { font-size: 12px !important; padding: 0 !important; }
.moa-auth .form-field[class*="checkbox-"] > .tip { flex: 0 0 100%; }
.moa-auth .form-field[class*="checkbox-"] .label-required { display: none; }
.moa-auth .form-field[class*="checkbox-"] > input[type="checkbox"].error { outline: 2px solid var(--moa-auth-red); outline-offset: 1px; }
.moa-auth .plaintext-field { font-size: 11px; line-height: 1.8; color: var(--moa-auth-muted); }

/* Terms (design: .terms-text) */
.moa-auth .moa-auth-terms { font-size: 11px; line-height: 1.8; color: var(--moa-auth-muted); margin: 18px 0 0; }
.moa-auth .moa-auth-terms a { color: var(--moa-auth-red); font-weight: 700; text-decoration: underline; }

/* Mobile number: intl-tel-input styled as the design's dial-code prefix */
.moa-auth .iti { display: block; width: 100%; }
.moa-auth .iti--separate-dial-code .iti__selected-flag,
.moa-auth .iti--allow-dropdown .iti__flag-container:hover .iti__selected-flag {
  background: #f7f8fa; border-right: 1px solid #dfe2e8; border-radius: 11px 0 0 11px; padding: 0 10px 0 13px;
}
.moa-auth .iti__selected-dial-code { font: 700 13px var(--moa-auth-font); color: var(--moa-auth-ink); }
.moa-auth .iti__country-list { font: 500 13px var(--moa-auth-font); border-radius: 9px; z-index: 30; }
.moa-auth .iti__flag-container { padding: 1px; }

/* Third-party providers */
.moa-auth .login-providers { margin-top: 24px; text-align: center; }
.moa-auth .login-providers h4 { font: 600 12px var(--moa-auth-font); color: var(--moa-auth-muted); margin: 0 0 12px; text-transform: none; }
.moa-auth .login-providers .login_social { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.moa-auth .login-providers .login-provider {
  display: inline-flex; align-items: center; justify-content: center; min-width: 52px; height: 46px; padding: 8px 14px;
  border: 1px solid #dfe2e8; border-radius: 11px; background: #fff; box-shadow: none; cursor: pointer;
}
.moa-auth .login-providers .login-provider:hover { border-color: var(--moa-auth-red); }
.moa-auth .login-providers .icon-image { max-height: 24px; width: auto; }
.moa-auth .login-providers .moa-auth-provider-terms { margin: 14px 0 0; font-size: 11px; color: var(--moa-auth-muted); }
.moa-auth .login-providers .moa-auth-provider-terms a { color: var(--moa-auth-red); font-weight: 700; }

/* Forgot password: "Need other help signing in?" */
.moa-auth .reset-help {
  display: inline-flex; align-items: center; gap: 5px; margin: 10px 0 0; padding: 0; border: 0; background: none; box-shadow: none;
  font: 600 11px var(--moa-auth-font); color: var(--moa-auth-muted); cursor: pointer;
}
.moa-auth .reset-help:hover { color: var(--moa-auth-red); background: none; }
.moa-auth #reset-help { margin-top: 8px; font-size: 11px; }
.moa-auth #reset-help .field-link,
.moa-auth #reset-help a { display: inline; margin-right: 14px; padding: 0; border: 0; background: none; box-shadow: none;
  font: 700 11px var(--moa-auth-font); color: var(--moa-auth-red); cursor: pointer; }
.moa-auth .password-reset-form .moa-auth-submit { margin-top: 24px !important; }

/* ---------- Responsive (design breakpoints) ---------- */
@media (min-width: 1200px) {
  .moa-auth .moa-auth-hero p { margin: 20px auto 40px; }
}
@media (min-width: 761px) and (max-width: 1199px) {
  .moa-auth .moa-auth-hero { padding-top: 52px; padding-bottom: 42px; }
}
@media (max-width: 850px) {
  .moa-auth { padding: 20px 0; }
  .moa-auth .moa-auth-card { grid-template-columns: 1fr; }
  .moa-auth .moa-auth-hero { min-height: 320px; padding: 52px 35px 42px; }
  .moa-auth .moa-auth-formside { padding: 45px 25px; }
}
@media (max-width: 760px) {
  .moa-auth .moa-auth-hero { padding-top: 38px; padding-bottom: 26px; }
}
@media (max-width: 600px) {
  .moa-auth .moa-auth-hero h1 { font-size: 32px; }
}
@media (max-width: 520px) {
  .moa-auth #register .required-fields { grid-template-columns: 1fr; }
  .moa-auth #register .required-fields > .text-name,
  .moa-auth #register .required-fields > .text-username { grid-column: 1 / -1; }
}

/* mhpro_mobile.css forces `h2, p, a { font-size: 18px !important }` below 768px:
   pin the design sizes for every text element that could match. */
.moa-auth .moa-auth-hero p { font-size: 15px !important; }
.moa-auth .moa-auth-formwrap h2.moa-auth-title { font-size: 32px !important; }
.moa-auth .moa-auth-sub { font-size: 13px !important; }
.moa-auth .moa-auth-bottom { font-size: 12px !important; }
.moa-auth .moa-auth-terms,
.moa-auth .moa-auth-provider-terms,
.moa-auth .moa-auth-notice { font-size: 11px !important; }
.moa-auth .js-form-feedback .status .message-copy p { font-size: 12px !important; }
.moa-auth a:not(.moa-auth-submit) { font-size: inherit !important; }
.moa-auth a.moa-auth-submit { font-size: 13px !important; }
