/*
 * Nucor Login Mod – Login Page Styles  (v2 – modern redesign)
 * All selectors are scoped to body.login or use the .nlm- prefix.
 * ─────────────────────────────────────────────────────────────────────────── */

/* ── CSS custom properties ───────────────────────────────────────────────── */

:root {
	--nlm-accent:      #006325;
	--nlm-accent-dark: #004d1f;
	--nlm-card-bg:     #ffffff;
	--nlm-card-radius: 16px;
	--nlm-shadow:      0 20px 60px rgba(0, 0, 0, 0.18), 0 4px 16px rgba(0, 0, 0, 0.10);
	--nlm-input-bd:    #d1d5db;
	--nlm-input-focus: #006325;
	--nlm-text:        #111827;
	--nlm-muted:       #6b7280;
	--nlm-transition:  0.18s ease;
}

/* ── Base layout ─────────────────────────────────────────────────────────── */

body.login {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 100vh;
	margin: 0;
	padding: 1.5rem;
	font-family: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto,
		Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
	box-sizing: border-box;
	-webkit-font-smoothing: antialiased;
}

/* ── Login card ──────────────────────────────────────────────────────────── */

body.login #loginform {
	background: var(--nlm-card-bg);
	border-radius: var(--nlm-card-radius);
	box-shadow: var(--nlm-shadow);
	padding: 2.75rem 2.25rem 2.25rem;
	width: 100%;
	max-width: 400px;
	box-sizing: border-box;
	position: relative;
	overflow: hidden;
}

/* Subtle top accent stripe */
body.login #loginform::before {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	height: 4px;
	background: linear-gradient(90deg, var(--nlm-accent), var(--nlm-accent-dark));
}

/* ── Logo / header ───────────────────────────────────────────────────────── */

body.login #login h1 a,
body.login #login h1 a.wp-login-logo {
	display: block;
	margin: 0 auto 1.5rem;
	background-size: contain;
	background-repeat: no-repeat;
	background-position: center center;
	text-indent: -9999px; 
	transition: opacity var(--nlm-transition);
	height: auto !important;
    padding-bottom: 60px; /* Adjust as needed to maintain aspect ratio of the logo */
    overflow: hidden;
}

body.login #login h1 a:hover,
body.login #login h1 a.wp-login-logo:hover {
	opacity: 0.85;
}

/* ── Form fields ─────────────────────────────────────────────────────────── */

body.login .login-username,
body.login .login-password {
	margin-bottom: 1.125rem;
}

body.login .login-username label,
body.login .login-password label,
body.login .login-remember label {
	display: block;
	font-size: 0.8125rem;
	font-weight: 600;
	color: var(--nlm-text);
	margin-bottom: 0.375rem;
	letter-spacing: 0.02em;
	text-transform: uppercase;
}

body.login input[type="text"],
body.login input[type="password"] {
	width: 100%;
	padding: 0.75rem 1rem;
	border: 1.5px solid var(--nlm-input-bd);
	border-radius: 10px;
	font-size: 0.9375rem;
	color: var(--nlm-text);
	background: #f9fafb;
	transition: border-color var(--nlm-transition), box-shadow var(--nlm-transition), background var(--nlm-transition);
	box-sizing: border-box;
	-webkit-appearance: none;
}

body.login input[type="text"]:focus,
body.login input[type="password"]:focus {
	border-color: var(--nlm-input-focus);
	box-shadow: 0 0 0 4px rgba(0, 99, 37, 0.14);
	background: #ffffff;
	outline: none;
}

/* ── Remember me ─────────────────────────────────────────────────────────── */

body.login .login-remember {
	margin-top: 0.75rem;
	display: flex;
	align-items: center;
}

body.login .login-remember input[type="checkbox"] {
	margin-right: 0.5rem;
	accent-color: var(--nlm-accent);
	width: 16px;
	height: 16px;
	cursor: pointer;
}

/* ── Submit button ───────────────────────────────────────────────────────── */

body.login .wp-core-ui .button-primary {
	display: block;
	width: 100%;
	padding: 0.8125rem 1rem;
	border-radius: 10px;
	font-size: 0.9375rem;
	font-weight: 700;
	letter-spacing: 0.03em;
	background: linear-gradient(135deg, var(--nlm-accent) 0%, var(--nlm-accent-dark) 100%);
	border: none;
	color: #ffffff;
	cursor: pointer;
	transition: transform var(--nlm-transition), box-shadow var(--nlm-transition), filter var(--nlm-transition);
	text-align: center;
	box-shadow: 0 4px 14px rgba(0, 99, 37, 0.35);
	-webkit-appearance: none;
	margin-top: 0.375rem;
}

body.login .wp-core-ui .button-primary:hover {
	filter: brightness(1.08);
	transform: translateY(-1px);
	box-shadow: 0 6px 20px rgba(0, 99, 37, 0.45);
	color: #ffffff;
}

body.login .wp-core-ui .button-primary:active {
	transform: translateY(0);
	box-shadow: 0 2px 8px rgba(0, 99, 37, 0.3);
}

body.login .wp-core-ui .button-primary:focus {
	box-shadow: 0 0 0 4px rgba(0, 99, 37, 0.3);
	outline: none;
}

/* ── Navigation links (“Lost your password?”) ───────────────────────────── */

body.login #nav {
	text-align: center;
	margin-top: 1rem;
	padding: 0;
}

body.login #nav a {
	color: var(--nlm-muted);
	text-decoration: none;
	font-size: 0.8125rem;
	transition: color var(--nlm-transition);
}

body.login #nav a:hover {
	color: var(--nlm-accent);
	text-decoration: none;
}

body.login #nav a:focus {
	outline: 2px solid var(--nlm-accent);
	outline-offset: 3px;
	border-radius: 3px;
}

/* ── Back to site link (“← Back to …”) ───────────────────────────────── */

body.login #backtoblog {
	text-align: center;
	margin-top: 1.5rem;
	padding-top: 1rem;
	border-top: 1px solid #e5e7eb;
}

body.login #backtoblog a {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	color: var(--nlm-muted);
	text-decoration: none;
	font-size: 0.8125rem;
	font-weight: 500;
	transition: color var(--nlm-transition), gap var(--nlm-transition);
}

body.login #backtoblog a::before { 
	display: inline-block;
	font-size: 0.875rem;
	transition: transform var(--nlm-transition);
    
}

body.login #backtoblog a:hover {
	color: var(--nlm-accent);
	gap: 0.5rem;
}

body.login #backtoblog a:hover::before {
	transform: translateX(-3px);
}

body.login #backtoblog a:focus {
	outline: 2px solid var(--nlm-accent);
	outline-offset: 3px;
	border-radius: 3px;
}

body.login .forgetmenot   {
    padding-top: 8px;
}

body.login .dashicons-visibility, body.login .dashicons-hidden { 
    color: var(--nlm-accent);
}

/* ── Tagline ─────────────────────────────────────────────────────────────── */

.nlm-tagline {
	margin-top: 1.5rem;
	padding: 1rem 0 0;
	border-top: 1px solid #e5e7eb;
	text-align: center;
	font-size: 0.8125rem;
	color: var(--nlm-muted);
	line-height: 1.65;
}

.nlm-tagline a {
	color: var(--nlm-accent);
	text-decoration: none;
	font-weight: 500;
}

.nlm-tagline a:hover {
	text-decoration: underline;
}

/* ── Error / info messages ───────────────────────────────────────────────── */

body.login #loginform_error,
body.login .message,
body.login .success {
	border-radius: 10px;
	margin-bottom: 1.5rem;
	font-size: 0.875rem;
	padding: 0.875rem 1.125rem;
	border: none;
	font-weight: 500;
}

body.login #loginform_error {
	background: #fef2f2;
	color: #991b1b;
	border-left: 4px solid var(--nlm-accent);
}

body.login .message {
	background: #eff6ff;
	color: #1e40af;
	border-left: 4px solid var(--nlm-accent);
}

/* ── Login button and remember me checkbox ───────────────────────────────────────────────────── */ 
body.login #wp-submit {
    background-color: #006325;
    color: #ffffff;
    transition: all ease-in-out 0.2s;
    text-transform: uppercase;
    font-weight: 700;
    padding: 0.2rem 1rem;
}

body.login #wp-submit:hover {
    background-color: #fff;
    color: #006325;
}

body.login .login-remember input[type="checkbox"] {
    accent-color: #006325;
}

body.login .login-remember input[type="checkbox"]:hover {
    accent-color: #004d1f;
}


/* ── Responsive ──────────────────────────────────────────────────────────── */

@media ( max-width: 480px ) {
	body.login {
		padding: 0.75rem;
		align-items: flex-start;
		padding-top: 2rem;
	}

	body.login #loginform {
		padding: 2rem 1.25rem 1.5rem;
		border-radius: 12px;
	}
}

/* ── Reduced-motion support ──────────────────────────────────────────────── */

@media ( prefers-reduced-motion: reduce ) {
	body.login .wp-core-ui .button-primary,
	body.login input[type="text"],
	body.login input[type="password"] {
		transition: none;
	}
}
