/* Operqon website + login layer (REDESIGN-SPEC §5: "Login page — token
 * surface, tenant logo, action button").
 *
 * Loaded through web_include_css, so it reaches the website pages the
 * tenant surface actually exposes — above all /login. Every rule is
 * scoped to the login page's own wrapper (#page-login) so no other
 * website page changes. The logo itself is NOT set here: the branding
 * installer points Website Settings app_logo at the Operqon lockup,
 * which is the source frappe/www/login.py reads first (the app's
 * app_logo_url hook is the fallback).
 *
 * The website bundle compiles its palette at build time, so the login
 * card and its action button take the token values through the direct
 * rules below (values only — no markup is patched). Each var() carries
 * the literal token value as its fallback, resolved from the same
 * tokens.source.json the Desk file is generated from, because the
 * generated token file itself is a Desk-side (app_include_css) asset.
 *
 * v3 alignment (operqon-v3-dreams-erp, 2026-11-12): the literal
 * fallbacks below now carry the Dreams ERP package values
 * (#0F766E / #0C6760, bg #F8F9FA, border #E8E9EC, radius 6px) so the
 * login page matches the v3 SPA shell; the --opq-* vars still win
 * wherever the Desk token file is loaded.
 */
#page-login {
	background: var(--opq-bg, #f8f9fa);
}

#page-login .page-card {
	border: 1px solid var(--opq-border, #e8e9ec);
	border-radius: var(--opq-radius-lg, 6px);
	box-shadow: var(--opq-shadow, 0 8px 28px rgba(20, 39, 47, 0.08));
}

/* The v16 login submit is an Espresso button, not a bootstrap one
 * (F3, fixed 2026-11-08): frappe/www/login.html renders
 * <button class="es-button w-full" data-variant="solid" type="submit">
 * — no .btn-login / .btn-primary class exists in the current markup,
 * which is why the old rules below never reached it. The espresso
 * button.css paints the solid variant from --surface-gray-10 (hover
 * -9, active -8) with --ink-base text, so the login scope re-points
 * exactly those steps at the action tokens (the generated token file
 * is Desk-side only, hence the literal fallbacks the header notes).
 * The bootstrap-class rules are kept for the website pages that still
 * render .btn-primary inside the login wrapper (message/CTA pages). */
#page-login {
	--surface-gray-10: var(--opq-action, #0f766e);
	--surface-gray-9: var(--opq-action-dark, #0c6760);
	--surface-gray-8: var(--opq-action-dark, #0c6760);
	--ink-base: #ffffff;
}

#page-login .btn-login,
#page-login .btn-primary {
	background-color: var(--opq-action, #0f766e);
	border-color: var(--opq-action, #0f766e);
	color: #ffffff;
	border-radius: var(--opq-radius-sm, 6px);
}

#page-login .btn-login:hover,
#page-login .btn-login:focus,
#page-login .btn-primary:hover,
#page-login .btn-primary:focus {
	background-color: var(--opq-action-dark, #0c6760);
	border-color: var(--opq-action-dark, #0c6760);
	color: #ffffff;
}

#page-login a:not(.btn) {
	color: var(--opq-action, #0f766e);
}

#page-login .social-login .btn,
#page-login .login-with-email-link .btn {
	border-radius: var(--opq-radius-sm, 6px);
}
