/* =========================
   Modal shell
========================= */

html.fxt-login-modal-open,
html.fxt-login-modal-open body {
  overflow: hidden;
}

.fxt-login-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99999;
}

.fxt-login-modal.is-open {
  display: block;
}

.fxt-login-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.fxt-login-modal__panel {
  position: relative;
  max-width: 520px;
  margin: 8vh auto 0;
  background: #fff;
  border-radius: 10px;
  padding: 28px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}

.fxt-login-modal__close {
  position: absolute;
  top: 10px;
  right: 12px;
  font-size: 28px;
  line-height: 1;
  background: transparent;
  border: 0;
  cursor: pointer;
}

/* =========================
   Intro + below text
========================= */

.fxt-login-modal__intro {
  margin: 0 0 14px;
  text-align: center;
  color: #7a7a7a;
  font-size: 16px;
}

.fxt-login-modal__below {
  margin-top: 18px;
}

.fxt-login-modal__below-text {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: #6b6b6b;
  text-align: center;
}

.fxt-login-modal__below-text a {
  text-decoration: underline;
}

/* =========================
   Modal form (wp_login_form)
========================= */

#fxt-loginform-modal {
  margin: 0;
}

/* Hide WP’s default "Lost your password?" row if it appears */
#fxt-loginform-modal p.login-forgot {
  display: none !important;
}

/* Username/password rows with icon OUTSIDE input */
#fxt-loginform-modal p.login-username,
#fxt-loginform-modal p.login-password {
  position: relative;
  margin: 0 0 14px;
  padding-left: 34px; /* space for icon */
}

/* Hide labels (placeholders used) */
#fxt-loginform-modal .login-username > label,
#fxt-loginform-modal .login-password > label {
  display: none;
}

/* Inputs */
#fxt-loginform-modal .login-username > input,
#fxt-loginform-modal .login-password > input {
  width: 100%;
  height: 50px;
  padding-left: 12px; /* normal padding; icon is outside */
  border-radius: 4px;
}

/* Font Awesome icon to the left (FA4) */
#fxt-loginform-modal .login-username::before,
#fxt-loginform-modal .login-password::before {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  color: #fd6600;
  font-size: 22px;
  line-height: 1;
  font-family: "FontAwesome";
  font-weight: 400;
}

/* FA4 codes */
#fxt-loginform-modal .login-username::before { content: "\f007"; } /* user */
#fxt-loginform-modal .login-password::before { content: "\f023"; } /* lock */

/* Remember + Forgot row (pairs with your JS wrapper .fxt-remember-left) */
#fxt-loginform-modal p.login-remember {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin: 6px 0 16px;
}

#fxt-loginform-modal .fxt-remember-left label {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  white-space: nowrap;
  font-weight: 600;
}

/* Native checkbox (with orange accent on modern browsers) */
#fxt-loginform-modal #rememberme {
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: #fd6600;
  appearance: auto;
  -webkit-appearance: checkbox;
}

/* Forgot link we inject via JS */
#fxt-loginform-modal .login-forgot-link {
  color: #7e7e7e;
  text-decoration: none;
  white-space: nowrap;
}

#fxt-loginform-modal .login-forgot-link:hover {
  color: #fd6600;
  text-decoration: none;
}

/* Submit button */
#fxt-loginform-modal p.login-submit {
  margin: 0;
}

#fxt-loginform-modal input[type="submit"] {
  width: 100%;
  background: #fd6600;
  border: 0;
  color: #fff;
  height: 56px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  border-radius: 4px;
  cursor: pointer;
}

#fxt-loginform-modal input[type="submit"]:hover {
  filter: brightness(0.95);
}

/* Custom checkbox (orange outline square) */
#fxt-loginform-modal #rememberme {
  -webkit-appearance: none !important;
  appearance: none !important;
  display: inline-block !important;
  width: 18px;
  height: 18px;
  border: 2px solid #fd6600;
  border-radius: 3px;
  background: #fff;
  margin: 0;
  cursor: pointer;
  position: relative;
  opacity: 1 !important;
  visibility: visible !important;
  clip: auto !important;
  clip-path: none !important;
}

#fxt-loginform-modal #rememberme:checked {
  background: #fd6600;
}

#fxt-loginform-modal #rememberme:checked::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 1px;
  width: 5px;
  height: 10px;
  border: 2px solid #fff;
  border-top: 0;
  border-left: 0;
  transform: rotate(45deg);
}

/* Override theme rule that hides the checkbox (modal only) */
#fxt-loginform-modal .login-remember input[type="checkbox"] {
  position: static !important;
  opacity: 1 !important;
  z-index: auto !important;
  width: 16px;
  height: 16px;
  margin: 0;
  accent-color: #fd6600;
}


/* Make Remember left + Forgot right (modal only, hard override) */
#fxt-loginform-modal p.login-remember {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  width: 100% !important;
}

#fxt-loginform-modal .fxt-remember-left {
  display: flex !important;
  align-items: center !important;
}

#fxt-loginform-modal .fxt-remember-right {
  margin-left: auto !important;
  display: block !important;
  text-align: right !important;
}
