/**
 * PrayerPrompt Theme — assets/css/signup.css
 *
 * Styles for the [pp_signup_form] shortcode.
 * Loaded conditionally on pages containing the shortcode.
 * Uses design tokens from base.css.
 *
 * @since 1.4.6
 */

/* "The Standard": the signup is the brand's loudest red moment —
   a flat red panel with white inputs and a navy submit. */
.pp-signup {
	max-width: 520px;
	margin: 0 auto;
	padding: 36px 28px;
	background: var(--color-red);
	border: none;
	border-radius: var(--radius-sm);
	font-family: var(--font-body);
	color: #ffffff;
}

/* ── Hero header ───────────────────────────────────────────── */
.pp-signup__hero {
	text-align: center;
	margin-bottom: 28px;
}

.pp-signup__icon {
	font-size: 44px;
	line-height: 1;
	margin-bottom: 12px;
}

.pp-signup__title {
	margin: 0 0 10px;
	font-family: var(--font-display);
	font-size: var(--text-3xl);
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.005em;
	color: #ffffff;
	line-height: 0.95;
}

.pp-signup__subtitle {
	margin: 0;
	font-size: var(--text-sm);
	color: rgba(255, 255, 255, 0.88);
	line-height: 1.55;
}

/* ── Form ──────────────────────────────────────────────────── */
.pp-signup__form {
	display: flex;
	flex-direction: column;
	gap: 18px;
}

.pp-signup__field {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.pp-signup__label {
	font-family: var(--font-display);
	font-size: var(--text-sm);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.01em;
	color: #ffffff;
}

.pp-signup__input {
	width: 100%;
	padding: 12px 16px;
	font-family: var(--font-body);
	font-size: var(--text-base);
	color: var(--text-primary);
	background: var(--bg-white);
	border: 2px solid var(--bg-white);
	border-radius: var(--radius-sm);
	transition: border-color 0.15s ease, box-shadow 0.15s ease;
	-webkit-appearance: none;
	appearance: none;
}

.pp-signup__input:focus {
	outline: none;
	border-color: var(--color-navy);
	box-shadow: 0 0 0 3px rgba(12, 35, 53, 0.35);
}

.pp-signup__input--error {
	border-color: var(--color-red-hover);
	box-shadow: 0 0 0 3px rgba(244, 28, 43, 0.08);
}

.pp-signup__hint {
	font-size: var(--text-xs);
	color: var(--text-muted);
	font-style: italic;
}

/* Honeypot — offscreen, never visible to real users. */
.pp-signup__honeypot {
	position: absolute !important;
	left: -10000px;
	top: -10000px;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* ── Submit button ─────────────────────────────────────────── */
.pp-signup__submit {
	width: 100%;
	padding: 14px 20px;
	margin-top: 6px;
	font-family: var(--font-display);
	font-size: var(--text-lg);
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.02em;
	color: var(--bg-white);
	background: var(--color-navy);
	border: none;
	border-radius: var(--radius-sm);
	cursor: pointer;
	transition: background 0.15s ease, transform 0.1s ease;
}

.pp-signup__submit:hover,
.pp-signup__submit:focus-visible {
	background: var(--bg-navy-dark);
	outline: none;
}

.pp-signup__submit:focus-visible {
	box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.55);
}

.pp-signup__submit:active {
	transform: scale(0.98);
}

.pp-signup__submit:disabled {
	background: var(--text-light);
	cursor: wait;
}

/* ── Message box (success / error) ─────────────────────────── */
.pp-signup__message {
	display: none;
	padding: 12px 16px;
	border-radius: 8px;
	font-size: var(--text-sm);
	line-height: 1.5;
}

.pp-signup__message--visible {
	display: block;
}

.pp-signup__message--error {
	background: var(--bg-red-tint);
	color: var(--color-burgundy);
	border: 1px solid var(--border-red);
}

.pp-signup__message--success {
	background: var(--bg-page);
	color: var(--color-navy);
	border: 1px solid var(--border-warm);
	border-left: 3px solid var(--color-red-hover);
}

/* ── Legal / footer ─────────────────────────────────────────── */
.pp-signup__legal {
	margin: 4px 0 0;
	font-size: var(--text-xs);
	color: var(--text-muted);
	line-height: 1.5;
	text-align: center;
}

.pp-signup__divider {
	display: flex;
	align-items: center;
	gap: 12px;
	margin: 28px 0 16px;
	color: var(--text-muted);
	font-size: var(--text-xs);
	text-transform: uppercase;
	letter-spacing: var(--tracking-wider);
}

.pp-signup__divider::before,
.pp-signup__divider::after {
	content: '';
	flex: 1;
	height: 1px;
	background: var(--border-warm);
}

.pp-signup__signin-row {
	margin: 0;
	text-align: center;
}

.pp-signup__signin-link {
	color: var(--color-navy);
	font-weight: 600;
	font-size: var(--text-sm);
	text-decoration: none;
	border-bottom: 1px solid transparent;
	transition: border-color 0.15s ease;
}

.pp-signup__signin-link:hover,
.pp-signup__signin-link:focus-visible {
	border-bottom-color: var(--color-navy);
	outline: none;
}

/* ── Already logged-in state ───────────────────────────────── */
.pp-signup--loggedin {
	text-align: center;
}

.pp-signup--loggedin .pp-signup__text {
	color: var(--text-secondary);
	font-size: var(--text-sm);
	margin: 0 0 20px;
}

.pp-signup__cta {
	display: inline-block;
	padding: 12px 24px;
	background: var(--color-navy);
	color: var(--bg-white);
	border-radius: 999px;
	text-decoration: none;
	font-weight: 600;
	font-size: var(--text-sm);
	transition: background 0.15s ease;
}

.pp-signup__cta:hover,
.pp-signup__cta:focus-visible {
	background: var(--bg-navy-dark);
	color: var(--bg-white);
	outline: none;
}

/* ── Mobile ────────────────────────────────────────────────── */
@media (max-width: 520px) {
	.pp-signup {
		padding: 24px 18px;
		border-radius: 12px;
	}
	.pp-signup__title {
		font-size: var(--text-xl);
	}
}

@media (prefers-reduced-motion: reduce) {
	.pp-signup__input,
	.pp-signup__submit,
	.pp-signup__cta,
	.pp-signup__signin-link {
		transition: none;
	}
	.pp-signup__submit:active {
		transform: none;
	}
}

/* ── The Standard: white-on-red panel adaptations + squared edges ── */
.pp-signup__hint,
.pp-signup__legal {
	color: rgba(255, 255, 255, 0.82);
}

.pp-signup__hint {
	font-style: normal;
}

.pp-signup__divider {
	color: rgba(255, 255, 255, 0.7);
}

.pp-signup__divider::before,
.pp-signup__divider::after {
	background: rgba(255, 255, 255, 0.3);
}

.pp-signup__signin-link {
	color: #ffffff;
	box-shadow: inset 0 -2px 0 rgba(255, 255, 255, 0.5);
	border-bottom: none;
}

.pp-signup__signin-link:hover,
.pp-signup__signin-link:focus-visible {
	box-shadow: inset 0 -2px 0 #ffffff;
	border-bottom: none;
}

.pp-signup__message {
	border-radius: var(--radius-sm);
}

/* Logged-in state: invert to a white card with navy CTA (no red flood) */
.pp-signup--loggedin {
	background: var(--bg-white);
	color: var(--text-primary);
	border: 2px solid var(--color-navy);
}

.pp-signup--loggedin .pp-signup__title {
	color: var(--color-navy);
}

.pp-signup--loggedin .pp-signup__text {
	color: var(--text-secondary);
}

.pp-signup__cta {
	border-radius: var(--radius-sm);
	font-family: var(--font-display);
	text-transform: uppercase;
	letter-spacing: 0.02em;
}

@media (max-width: 520px) {
	.pp-signup {
		border-radius: var(--radius-sm);
	}
}
