/* ==========================================================
   TML + LoginPress -> skin stile wp-login.php
   SOSTITUISCI:
   - URL_LOGO   con l'URL del logo
   - URL_SFONDO con l'URL dell'immagine di sfondo
   ========================================================== */

:root {
  --login-box-width: 320px;
  --login-logo-height: 84px; /* regola se serve */
}

/* ====== BACKGROUND (uguale concetto wp-login, ma personalizzato) ====== */
body.login {
  /* SOSTITUISCI URL_SFONDO */
  background: url("https://dash.refrigerazioneindustrialegroup.it/wp-content/uploads/2026/01/bg-about-new.png") no-repeat right bottom;
  background-size: cover;         /* oppure contain se vuoi vederla tutta */
  background-attachment: fixed;
  background-color: #f0f0f1;      /* fallback WP */
}

/* Evita interferenze tema/Elementor */
body.login main#content,
body.login .site-main,
body.login .page-content {
  padding: 0 !important;
  margin: 0 !important;
}

body.login #content {
  min-height: 100vh;
}

/* Centra come wp-login.php */
body.login #login {
  padding: 6% 0 0;
}

/* ====== LOGO sopra al box ====== */
body.login #login h1 {
  margin: 0 auto 16px;
  padding: 0;
  text-align: center;
}

body.login #login h1 a {
  /* SOSTITUISCI URL_LOGO */
  background-image: url("https://dash.refrigerazioneindustrialegroup.it/wp-content/uploads/2026/01/scritta-per-web.png");
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;

  width: var(--login-box-width);
  height: var(--login-logo-height);

  margin: 0 auto;
  display: block;

  text-indent: -9999px;
  overflow: hidden;
}

/* ====== Contenitore TML ====== */
body.login .tml {
  width: var(--login-box-width);
  margin: 0 auto;
  padding: 0;
}

/* Box form */
body.login .tml form[name="login"] {
  margin: 0;
  padding: 26px 24px 34px;
  background: #fff;
  border: 1px solid #c3c4c7;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

/* Alert/messaggi sopra il form (se presenti) */
body.login .tml-alerts {
  width: var(--login-box-width);
  margin: 0 auto 16px;
}

/* Label e campi in stile WP */
body.login .tml-label {
  font-size: 14px;
  line-height: 1.5;
  display: inline-block;
  margin-bottom: 3px;
  color: #3c434a;
}

body.login .tml-field-wrap {
  margin-bottom: 16px;
}

body.login input#user_login,
body.login input#user_pass {
  font-size: 24px;
  line-height: 1.33333333;
  width: 100%;
  padding: 3px 5px;
  box-sizing: border-box;

  background: #fff;
  border: 1px solid #8c8f94;
  border-radius: 0;
  color: #2c3338;
}

body.login input#user_login:focus,
body.login input#user_pass:focus {
  border-color: #2271b1;
  box-shadow: 0 0 0 1px #2271b1;
  outline: 2px solid transparent;
}

/* Remember me */
body.login .tml-rememberme-wrap {
  margin: 0 0 16px;
}

body.login .tml-rememberme-wrap label {
  font-size: 13px;
  color: #50575e;
}

body.login #rememberme {
  margin-right: 6px;
}

/* Submit */
body.login .tml-submit-wrap.submit {
  margin: 0;
  padding: 0;
}

body.login #wp-submit {
  width: 100%;
  min-height: 44px;
  margin-top: 8px;
}

/* Link sotto (password dimenticata) */
body.login .tml-links {
  width: var(--login-box-width);
  margin: 16px auto 0;
  padding: 0;
  list-style: none;
}

body.login .tml-links li {
  margin: 0;
}

/* Nascondi il “Powered by LoginPress” se non lo vuoi */
body.login .loginpress-show-love {
  display: none !important;
}

/* ==========================================================
   FIX: testo spezzato tipo "se" nel campo password
   (causato da button/label del toggle password “Mostra/Nascondi”)
   ========================================================== */
body.login .user-pass-fields button,
body.login .user-pass-fields .button,
body.login .user-pass-fields .wp-hide-pw {
  font-size: 0 !important;      /* nasconde testo */
  line-height: 0 !important;
  letter-spacing: 0 !important;
}

body.login .user-pass-fields button .dashicons,
body.login .user-pass-fields .button .dashicons,
body.login .user-pass-fields .wp-hide-pw .dashicons {
  font-size: 18px !important;   /* mantiene icona */
  line-height: 1 !important;
}

/* Se il bottone non ha icona, evita comunque che "testo" compaia */
body.login .user-pass-fields button::after,
body.login .user-pass-fields .wp-hide-pw::after {
  content: "";
}
