/**
 * File: assets/css/mln-referral-landing.css
 * Purpose: W-HSP-013 absorbed referral-landing template polish.
 *          Renders when a visitor lands on a `?ref=USERNAME` URL — the page
 *          shows the sponsor's name + a CTA to join. MLN_Referrals writes
 *          the cookie on landing; this CSS styles the landing UX so the
 *          referral story is human-readable.
 *
 * V-gates covered:
 *   - V-FRONT-001 (template renders without fatal/notice)
 *   - V-FRONT-006 (responsive at 320 / 768 / 1280)
 *   - V-FRONT-007 (44x44px min tap targets)
 *
 * Loaded by: MLN_Frontend::enqueue_assets() (engine-builder wires this when
 *            templates/mln-referral-landing.php is rendered).
 *
 * @package MLN_MLM_Engine
 * @since   2.0.0
 */

.mln-referral-landing {
	max-width: 720px;
	margin: 0 auto;
	padding: 32px 16px;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: #1d2327;
	text-align: center;
}

.mln-referral-landing__hero {
	background: linear-gradient(135deg, #2271b1 0%, #135e96 100%);
	color: #fff;
	border-radius: 8px;
	padding: 40px 24px;
	margin-bottom: 24px;
	box-shadow: 0 4px 12px rgba(34, 113, 177, 0.18);
}

.mln-referral-landing__eyebrow {
	font-size: 12px;
	text-transform: uppercase;
	letter-spacing: 1.5px;
	opacity: 0.85;
	margin: 0 0 8px;
}

.mln-referral-landing__heading {
	font-size: 32px;
	font-weight: 700;
	line-height: 1.15;
	margin: 0 0 16px;
}

.mln-referral-landing__sponsor-card {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	background: rgba(255, 255, 255, 0.12);
	border: 1px solid rgba(255, 255, 255, 0.3);
	border-radius: 999px;
	padding: 10px 18px;
	margin-top: 8px;
	backdrop-filter: blur(6px);
}

.mln-referral-landing__sponsor-avatar {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: #fff;
	color: #135e96;
	display: flex;
	align-items: center;
	justify-content: center;
	font-weight: 700;
	font-size: 14px;
	flex-shrink: 0;
}

.mln-referral-landing__sponsor-name {
	font-size: 14px;
	font-weight: 600;
}

.mln-referral-landing__sponsor-label {
	display: block;
	font-size: 11px;
	font-weight: 400;
	opacity: 0.85;
}

.mln-referral-landing__intro {
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 6px;
	padding: 24px;
	margin-bottom: 24px;
	text-align: left;
}

.mln-referral-landing__intro p {
	margin: 0 0 12px;
	font-size: 15px;
	line-height: 1.55;
	color: #1d2327;
}

.mln-referral-landing__intro p:last-child {
	margin-bottom: 0;
}

.mln-referral-landing__benefits {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 12px;
	margin-bottom: 24px;
}

.mln-referral-landing__benefit {
	background: #fff;
	border: 1px solid #c3c4c7;
	border-radius: 6px;
	padding: 16px;
	text-align: center;
}

.mln-referral-landing__benefit-icon {
	width: 32px;
	height: 32px;
	margin: 0 auto 8px;
	color: #2271b1;
}

.mln-referral-landing__benefit-title {
	font-size: 13px;
	font-weight: 600;
	margin: 0 0 4px;
}

.mln-referral-landing__benefit-desc {
	font-size: 12px;
	color: #50575e;
	line-height: 1.4;
}

.mln-referral-landing__cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 52px;
	padding: 0 32px;
	background: #00a32a;
	border: 1px solid #00a32a;
	border-radius: 6px;
	color: #fff;
	font-size: 16px;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
	transition: background 0.15s ease, transform 0.05s ease;
	box-shadow: 0 2px 6px rgba(0, 163, 42, 0.25);
}

.mln-referral-landing__cta:hover {
	background: #00691c;
	border-color: #00691c;
	color: #fff;
}

.mln-referral-landing__cta:active {
	transform: translateY(1px);
}

.mln-referral-landing__cta:focus-visible {
	outline: 2px solid #00691c;
	outline-offset: 3px;
}

.mln-referral-landing__cta-arrow {
	margin-left: 8px;
	transition: transform 0.15s ease;
}

.mln-referral-landing__cta:hover .mln-referral-landing__cta-arrow {
	transform: translateX(3px);
}

.mln-referral-landing__login-note {
	margin-top: 16px;
	font-size: 13px;
	color: #50575e;
}

.mln-referral-landing__login-note a {
	color: #2271b1;
	text-decoration: none;
	font-weight: 600;
}

.mln-referral-landing__login-note a:hover {
	text-decoration: underline;
}

.mln-referral-landing__cookie-note {
	margin-top: 24px;
	font-size: 11px;
	color: #8c8f94;
	font-style: italic;
}

/* ---------- Tablet ---------- */
@media screen and (max-width: 768px) {
	.mln-referral-landing {
		padding: 24px 12px;
	}

	.mln-referral-landing__hero {
		padding: 28px 16px;
	}

	.mln-referral-landing__heading {
		font-size: 24px;
	}

	.mln-referral-landing__benefits {
		grid-template-columns: 1fr;
	}

	.mln-referral-landing__intro {
		padding: 18px;
	}
}

/* ---------- Mobile ---------- */
@media screen and (max-width: 480px) {
	.mln-referral-landing__heading {
		font-size: 20px;
	}

	.mln-referral-landing__cta {
		display: flex;
		width: 100%;
		font-size: 15px;
	}
}

/* ==========================================================================
   Unified login template ([hsp_unified_login] + [mln_unified_login]) —
   W-HSP-025 absorbed; v2.1.0-GAP-06 card refactor (Phase C, F-Maestro-017)
   ========================================================================== */

/*
 * Outer wrapper — centering context only. Keeps the shortcode usable
 * inside any theme container; the visual card lives in __card.
 */
.mln-unified-login {
	display: block;
	width: 100%;
	padding: 40px 16px;
	box-sizing: border-box;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
	color: #1d2327;
}

/*
 * v2.1.0-GAP-06: centered card matching live (~450px max-width, border,
 * padding, subtle box-shadow).
 */
.mln-unified-login__card {
	max-width: 450px;
	margin: 0 auto;
	padding: 32px 28px;
	background: #fff;
	border: 1px solid #dcdcde;
	border-radius: 8px;
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
	box-sizing: border-box;
}

@media (max-width: 480px) {
	.mln-unified-login {
		padding: 24px 12px;
	}

	.mln-unified-login__card {
		padding: 24px 20px;
		border-radius: 6px;
	}
}

.mln-unified-login__heading {
	text-align: center;
	margin: 0 0 8px;
	font-size: 22px;
	font-weight: 600;
}

.mln-unified-login__subheading {
	text-align: center;
	margin: 0 0 20px;
	font-size: 13px;
	color: #50575e;
}

.mln-unified-login__field {
	display: flex;
	flex-direction: column;
	gap: 4px;
	margin-bottom: 14px;
}

.mln-unified-login__label {
	font-size: 13px;
	font-weight: 600;
}

.mln-unified-login__input {
	width: 100%;
	min-height: 44px;
	padding: 10px 12px;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	font-size: 14px;
	background: #fff;
	/* Issue 4 (2026-06-12): the active theme/Elementor cascades a global
	 * `input { color: #fff }` (same collision already pinned for the referral
	 * link input in member-panels.css:643). Without an explicit ink colour the
	 * login email/password text renders white-on-white. Pin a readable ink and
	 * the matching -webkit-text-fill-color so typed + autofilled text are both
	 * visible. #1d2327 on #fff ≈ 16:1 (WCAG AA pass). */
	color: #1d2327;
	-webkit-text-fill-color: #1d2327;
	box-sizing: border-box;
}

.mln-unified-login__input:focus {
	outline: none;
	border-color: #2271b1;
	box-shadow: 0 0 0 1px #2271b1;
}

/* Issue 4: keep autofilled text readable (Chrome paints autofill text via
 * -webkit-text-fill-color, which the global input{color:#fff} would otherwise
 * turn white). The long transition defers Chrome's yellow autofill background
 * wash so the field stays legible. */
.mln-unified-login__input:-webkit-autofill,
.mln-unified-login__input:-webkit-autofill:hover,
.mln-unified-login__input:-webkit-autofill:focus {
	-webkit-text-fill-color: #1d2327;
	caret-color: #1d2327;
	transition: background-color 9999s ease-out 0s;
}

.mln-unified-login__row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin: 8px 0 16px;
	font-size: 12px;
}

.mln-unified-login__remember {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	color: #50575e;
}

.mln-unified-login__forgot {
	color: #2271b1;
	text-decoration: none;
}

.mln-unified-login__forgot:hover {
	text-decoration: underline;
}

.mln-unified-login__submit {
	display: block;
	width: 100%;
	min-height: 48px;
	background: #2271b1;
	border: 1px solid #2271b1;
	border-radius: 4px;
	color: #fff;
	font-size: 15px;
	font-weight: 600;
	cursor: pointer;
}

.mln-unified-login__submit:hover {
	background: #135e96;
}

.mln-unified-login__error {
	display: none;
	padding: 10px 12px;
	background: #fcf0f1;
	border: 1px solid #d63638;
	border-radius: 4px;
	color: #b32d2e;
	font-size: 13px;
	margin-bottom: 12px;
}

.mln-unified-login__error.is-visible {
	display: block;
}

/* ==========================================================================
   v2.1.1 R5 BUG-004 — .mln-login-error selector contract
   --------------------------------------------------------------------------
   The unified-login template emits BOTH .mln-unified-login__error (BEM, owned
   by this stylesheet's login section above) and .mln-login-error (V-BUG-004
   selector contract, asserted by the scripted V-gate). The class below is
   the standalone form so it renders correctly even if the template is ever
   reused outside the .mln-unified-login wrapper.
   ========================================================================== */
.mln-login-error {
	background: #fef2f2;
	color: #991b1b;
	border-left: 3px solid #dc2626;
	padding: 12px 16px;
	margin: 0 0 16px;
	border-radius: 4px;
	font-size: 14px;
	line-height: 1.5;
	min-height: 44px;
	display: flex;
	align-items: center;
}

@media (max-width: 480px) {
	.mln-login-error {
		padding: 14px 16px;
		font-size: 15px;
	}
}

.mln-unified-login__footer {
	margin-top: 18px;
	padding-top: 16px;
	border-top: 1px solid #e5e5e7;
	text-align: center;
	font-size: 13px;
	color: #50575e;
}

.mln-unified-login__footer a {
	color: #2271b1;
	text-decoration: none;
	font-weight: 600;
}

.mln-unified-login__footer a:hover {
	text-decoration: underline;
}

/* ==========================================================================
   Hub selector partial (W-HSP-035) — used inside checkout form
   ========================================================================== */

.mln-hub-selector {
	display: flex;
	flex-direction: column;
	gap: 4px;
	margin-bottom: 14px;
}

.mln-hub-selector__label {
	font-size: 13px;
	font-weight: 600;
}

.mln-hub-selector__select {
	min-height: 44px;
	padding: 10px 12px;
	border: 1px solid #c3c4c7;
	border-radius: 4px;
	background: #fff;
	font-size: 14px;
	box-sizing: border-box;
	width: 100%;
	/* Bug 2 sweep (2026-06-12): bare select inherited the theme's global
	 * input{color:#fff} → white-on-white. Pin readable ink + text-fill. */
	color: #1d2327;
	-webkit-text-fill-color: #1d2327;
}

.mln-hub-selector__select:focus {
	outline: none;
	border-color: #2271b1;
	box-shadow: 0 0 0 1px #2271b1;
}

.mln-hub-selector__hint {
	font-size: 12px;
	color: #50575e;
}
