/*
Calender Crossing HOA — wp-login.php styling
Source of truth for values: color-palette.md + PROJECT-STANDARDS.md §2
Logo URL is injected as --cc-logo-url by cc-login-styling.php (wp_add_inline_style)
*/

:root {
	--cc-cream: #FBF6ED;
	--cc-paper: #FFFFFF;
	--cc-charcoal: #3A3128;
	--cc-taupe: #6B6055;
	--cc-terracotta: #A8532D;
	--cc-terracotta-deep: #813E1B;
	--cc-sage: #7A8B6F;
	--cc-sage-tint: #EEF1E9;
	--cc-sage-deep: #54604A;
	--cc-border: #E5DAC6;
	--cc-shadow: rgba(58, 44, 28, 0.10);
	--cc-shadow-hover: rgba(58, 44, 28, 0.18);
	--cc-shadow-sage: rgba(122, 139, 111, 0.9);
}

/* ---------- Page ---------- */

body.login {
	background-color: var(--cc-cream);
	font-family: "Karla", -apple-system, BlinkMacSystemFont, sans-serif;
	color: var(--cc-charcoal);
}

body.login #login {
	width: 360px;
	padding: 8% 0 0;
}

/* ---------- Logo ---------- */

body.login h1 {
	margin-bottom: 24px;
}

body.login h1 a {
	background-image: var(--cc-logo-url);
	background-size: contain;
	background-position: center;
	width: 100%;
	height: 90px;
	max-width: 280px;
	margin: 0 auto;
	display: block;
}

/* ---------- Card ---------- */

body.login form#loginform,
body.login form#lostpasswordform,
body.login form#registerform {
	background: var(--cc-paper);
	border: 1px solid var(--cc-border);
	border-radius: 14px;
	box-shadow: 0 6px 20px var(--cc-shadow), 0 0px 15px var(--cc-shadow-sage);
	padding: 32px 28px 26px;
	margin-top: 0;
}

/* ---------- Labels & inputs ---------- */

body.login label {
	color: var(--cc-charcoal);
	font-family: "Karla", sans-serif;
	font-weight: 600;
	font-size: 13px;
}

body.login form .input,
body.login input[type="text"],
body.login input[type="password"],
body.login input[type="email"] {
	background: var(--cc-sage-tint);
	border: 2px solid var(--cc-border);
	border-radius: 8px;
	color: var(--cc-charcoal);
	font-family: "Karla", sans-serif;
	font-size: 15px;
	padding: 10px 12px;
	box-shadow: none;
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

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(--cc-terracotta);
	box-shadow: 0 0 0 3px rgba(168, 83, 45, 0.15);
	outline: none;
}

/* Remember-me checkbox */
body.login input[type="checkbox"] {
	accent-color: var(--cc-terracotta);
}

body.login p.forgetmenot label {
	font-weight: 400;
	color: var(--cc-taupe);
}

/* ---------- Primary button ---------- */

body.login .button-primary {
	background: var(--cc-terracotta);
	border: none;
	border-radius: 8px;
	color: #fff;
	font-family: "Karla", sans-serif;
	font-weight: 600;
	font-size: 15px;
	padding: 10px 22px;
	height: auto;
	line-height: 1.4;
	box-shadow: none;
	text-shadow: none;
	transition: background-color 0.15s ease;
}

body.login .button-primary:hover,
body.login .button-primary:focus {
	background: var(--cc-terracotta-deep);
	box-shadow: none;
}

/* ---------- Register button ---------- */

body.login .cc-register-row {
	text-align: center;
	margin-top: 28px;
}

body.login .cc-register-button {
	display: inline-block;
	background: transparent;
	border: 2px solid var(--cc-sage);
	border-radius: 8px;
	color: var(--cc-sage-deep);
	font-family: "Karla", sans-serif;
	font-weight: 600;
	font-size: 15px;
	padding: 10px 22px;
	text-decoration: none;
	transition: background-color 0.15s ease, color 0.15s ease;
}

body.login .cc-register-button:hover,
body.login .cc-register-button:focus {
	background: var(--cc-sage);
	color: #fff;
}

/* ---------- Links: back-to-blog, nav, lost password ---------- */

body.login #nav,
body.login #backtoblog {
	margin-top: 18px;
}

body.login #nav a,
body.login #backtoblog a {
	color: var(--cc-taupe);
	font-family: "Karla", sans-serif;
	font-size: 13px;
	text-decoration: none;
}

body.login #nav a:hover,
body.login #backtoblog a:hover {
	color: var(--cc-terracotta);
	text-decoration: underline;
}

/* ---------- Messages / errors ---------- */

body.login .message,
body.login #login_error {
	border-radius: 8px;
	border-left-width: 4px;
	font-family: "Karla", sans-serif;
	font-size: 17px;
	line-height: 1.5;
	padding: 16px 16px 16px 20px;
	box-shadow: 0 2px 8px var(--cc-shadow);
}

body.login .message {
	background: var(--cc-sage-tint);
	border-left-color: var(--cc-sage-deep);
	color: var(--cc-charcoal);
}

/* Keep #login_error red-toned for accessibility — brand terracotta reads too close
   to "success" tones elsewhere on the site to double as an error indicator. */
body.login #login_error {
	background: #FBEAEA;
	border-left-color: #b32d2e;
	color: var(--cc-charcoal);
}

body.login .message a,
body.login #login_error a {
	color: var(--cc-terracotta);
	font-weight: 600;
	text-decoration: underline;
}

body.login .message a:hover,
body.login #login_error a:hover {
	color: var(--cc-terracotta-deep);
}

/* ---------- Privacy policy link / language switcher ---------- */

body.login .privacy-policy-page-link a,
body.login #language-switcher a {
	color: var(--cc-taupe);
}

body.login .privacy-policy-page-link a:hover,
body.login #language-switcher a:hover {
	color: var(--cc-terracotta);
}

/* ---------- Focus ring (accessibility) ---------- */

body.login a:focus,
body.login button:focus {
	outline: 2px solid var(--cc-terracotta);
	outline-offset: 2px;
	box-shadow: none;
}

/* ---------- Small screens ---------- */

@media (max-width: 480px) {
	body.login #login {
		width: 90%;
		padding: 12% 0 0;
	}

	body.login form#loginform,
	body.login form#lostpasswordform,
	body.login form#registerform {
		padding: 26px 20px 22px;
	}
}
