/* TFA Learning: branded login / password screens (wp-login.php). */
body.tfal-login {
	--g: #84BD41;
	--t: #005463;
	--ink: #000;
	--slate: #5E5E5E;
	--line: #dcdcdc;
	background: #f4f5f2;
	color: var(--slate);
	font-family: "Open Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
	min-height: 100vh;
}

/* Photo panel (when an image is set in Settings) */
body.tfal-login--image::before {
	content: "";
	position: fixed;
	inset: 0 auto 0 0;
	width: 46vw;
	background:
		linear-gradient(160deg, rgba(0, 0, 0, .05) 30%, rgba(0, 84, 99, .55) 100%),
		var(--tfal-login-image) center / cover no-repeat;
}
body.tfal-login--image::after {
	content: "";
	position: fixed;
	left: 0;
	bottom: 0;
	width: 46vw;
	height: 8px;
	background: linear-gradient(90deg, var(--g), var(--t));
}

body.tfal-login #login {
	width: 400px;
	max-width: calc(100vw - 32px);
	padding: 6vh 0 40px;
	margin: 0 auto;
	box-sizing: border-box;
}
body.tfal-login--image #login {
	margin-left: calc(46vw + (54vw - 400px) / 2);
}

/* Logo */
body.tfal-login h1 a {
	background-image: var(--tfal-login-logo);
	background-size: contain;
	background-position: left center;
	width: 210px;
	height: 58px;
	margin: 0 0 28px;
}

/* Heading */
body.tfal-login .tfal-login__intro h2 {
	color: var(--ink);
	font-size: 26px;
	line-height: 1.2;
	font-weight: 700;
	margin: 0 0 6px;
}
body.tfal-login .tfal-login__intro p {
	font-size: 15px;
	margin: 0 0 22px;
	color: var(--slate);
}

/* Form card */
body.tfal-login #loginform,
body.tfal-login #lostpasswordform,
body.tfal-login #resetpassform,
body.tfal-login #registerform {
	margin: 0;
	padding: 28px 28px 24px;
	border: 1px solid var(--line);
	border-top: 4px solid var(--g);
	border-radius: 0 0 10px 10px;
	box-shadow: 0 8px 28px rgba(0, 0, 0, .06);
	background: #fff;
}
body.tfal-login form label {
	color: var(--ink);
	font-size: 14px;
	font-weight: 600;
}
body.tfal-login form .input,
body.tfal-login input[type="text"],
body.tfal-login input[type="email"],
body.tfal-login input[type="password"] {
	font-size: 16px;
	padding: 8px 12px;
	min-height: 44px;
	border: 1px solid #bdbdbd;
	border-radius: 6px;
	box-shadow: none;
	background: #fff;
}
body.tfal-login form .input:focus,
body.tfal-login input[type="password"]:focus,
body.tfal-login input[type="text"]:focus {
	border-color: var(--t);
	box-shadow: 0 0 0 2px rgba(132, 189, 65, .45);
	outline: none;
}
body.tfal-login .wp-pwd .button.wp-hide-pw { color: var(--slate); min-height: 44px; }
body.tfal-login .wp-pwd .button.wp-hide-pw:focus { box-shadow: 0 0 0 2px var(--g); }

body.tfal-login .forgetmenot { float: none; margin-bottom: 16px; }
body.tfal-login .forgetmenot label { font-weight: 400; color: var(--slate); }

/* Buttons: green with black text (accessible contrast), black on hover */
body.tfal-login .button-primary,
body.tfal-login #wp-submit {
	float: none;
	width: 100%;
	min-height: 46px;
	font-size: 16px;
	font-weight: 700;
	background: var(--g);
	border: 0;
	border-radius: 6px;
	color: var(--ink);
	text-shadow: none;
	box-shadow: none;
}
body.tfal-login .button-primary:hover,
body.tfal-login .button-primary:focus,
body.tfal-login #wp-submit:hover,
body.tfal-login #wp-submit:focus {
	background: var(--ink);
	color: #fff;
	box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--ink);
}
body.tfal-login .submit { clear: both; }
body.tfal-login #resetpassform .reset-pass-submit { display: flex; flex-direction: column-reverse; gap: 10px; }
body.tfal-login #resetpassform .reset-pass-submit .button { float: none; width: 100%; min-height: 44px; }

/* Messages */
body.tfal-login .message,
body.tfal-login .notice,
body.tfal-login #login_error {
	border-left-width: 4px;
	border-radius: 0 6px 6px 0;
	box-shadow: none;
	margin: 0 0 18px;
	background: #fff;
}
body.tfal-login .message,
body.tfal-login .notice-info,
body.tfal-login .notice-success { border-left-color: var(--g); }

/* Help + links under the form */
body.tfal-login .tfal-login__help {
	font-size: 14px;
	line-height: 1.5;
	margin: 18px 0 0;
	padding: 14px 16px;
	background: #fff;
	border: 1px solid var(--line);
	border-radius: 8px;
}
body.tfal-login .tfal-login__help strong { color: var(--ink); }
body.tfal-login #nav,
body.tfal-login #backtoblog {
	padding: 0;
	margin: 16px 0 0;
	font-size: 14px;
}
body.tfal-login a { color: var(--t); }
body.tfal-login a:hover,
body.tfal-login a:focus { color: var(--ink); }
body.tfal-login #nav a,
body.tfal-login #backtoblog a { color: var(--slate); text-decoration: underline; }
body.tfal-login .privacy-policy-page-link { text-align: left; margin: 24px 0 0; }

/* Smaller screens: drop the photo panel */
@media (max-width: 900px) {
	body.tfal-login--image::before,
	body.tfal-login--image::after { display: none; }
	body.tfal-login--image #login { margin-left: auto; }
	body.tfal-login #login { padding-top: 32px; }
}
@media (max-width: 480px) {
	body.tfal-login #loginform,
	body.tfal-login #lostpasswordform,
	body.tfal-login #resetpassform { padding: 22px 18px 18px; }
	body.tfal-login .tfal-login__intro h2 { font-size: 23px; }
}
