/*
 * Login screen styling — Westwinds Offshore Services
 *
 * Restyles WordPress's default wp-login.php form (login, register,
 * lost password, reset password) so it sits inside the theme's own
 * header/footer (added via login-customizer.php) and uses the same
 * colours, fonts and spacing as the rest of the site, rather than
 * default WordPress blue/grey styling.
 *
 * Uses the same CSS variables defined in assets/css/style.css.
 */

body.login {
  background: var(--bg-alt);
  font-family: inherit;
  padding-top: 48px;
  padding-bottom: 48px;
}

/* Default WordPress login page wraps everything in #login with its
   own logo (h1 > a) above the form box. Since our own theme header
   (with the real Westwinds logo) is now printed above this via
   login_header, hide WordPress's separate logo to avoid showing it
   twice. */
body.login #login h1 {
  display: none;
}

body.login #login {
  width: 380px;
  margin: 0 auto;
  padding: 0 20px;
}

/* The form box itself */
body.login #loginform,
body.login #registerform,
body.login #lostpasswordform,
body.login #resetpassform {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 4px;
  box-shadow: 0 1px 3px rgba(22, 39, 59, 0.06);
  padding: 32px 28px 24px;
}

body.login form .input,
body.login input[type="text"],
body.login input[type="password"],
body.login input[type="email"] {
  font-family: inherit;
  font-size: 0.95rem;
  border: 1px solid var(--line);
  border-radius: 3px;
  color: var(--ink);
  padding: 10px 12px;
  box-shadow: none;
}

body.login form .input:focus,
body.login input[type="text"]:focus,
body.login input[type="password"]:focus,
body.login input[type="email"]:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201, 162, 75, 0.15);
}

body.login label {
  color: var(--navy);
  font-weight: 600;
  font-size: 0.85rem;
}

/* Primary action button, matched to the theme's existing button
   styling rather than WordPress's default admin blue. */
body.login .wp-core-ui .button-primary {
  background: var(--navy);
  border-color: var(--navy);
  box-shadow: none;
  text-shadow: none;
  border-radius: 3px;
  font-weight: 600;
  padding: 8px 20px;
  height: auto;
  line-height: 1.5;
  transition: background-color 0.15s ease;
}

body.login .wp-core-ui .button-primary:hover,
body.login .wp-core-ui .button-primary:focus {
  background: var(--navy-light);
  border-color: var(--navy-light);
}

/* "Remember me" row and links beneath the form */
body.login #nav,
body.login #backtoblog {
  text-align: center;
  font-size: 0.85rem;
}

body.login #nav a,
body.login #backtoblog a {
  color: var(--gold-deep);
}

body.login #nav a:hover,
body.login #backtoblog a:hover {
  color: var(--navy);
}

/* Error / notice messages (wrong password, etc.) */
body.login #login_error,
body.login .message,
body.login .success {
  border-radius: 3px;
  border-left-width: 4px;
  font-size: 0.9rem;
  padding: 12px 14px;
  margin: 0 0 20px;
  box-shadow: none;
}

body.login #login_error {
  border-left-color: #C0392B;
  background: #FBEAEA;
}

body.login .message,
body.login .success {
  border-left-color: var(--gold-deep);
  background: #FBF6EA;
}

/* Checkbox row spacing tidy-up */
body.login .forgetmenot {
  font-weight: 400;
  font-size: 0.85rem;
}

/* Language switcher (if shown) — keep it unobtrusive */
body.login .language-switcher {
  text-align: center;
  margin-top: 12px;
}

@media (max-width: 480px) {
  body.login #login {
    width: 100%;
  }

  body.login #loginform,
  body.login #registerform,
  body.login #lostpasswordform,
  body.login #resetpassform {
    padding: 24px 18px 18px;
  }
}
