/**
 * Submit-a-prayer flow. Skinned to the site tokens (warm brown/beige).
 */

/* Match the home page section rhythm (.gbp-section). */
.sp-section {
	padding: 5.5rem 1.5rem;
}

/* Full-width subtle band behind the form, like the home page sections. The
   box-shadow paints the colour edge to edge; clip-path keeps it from adding
   any horizontal scroll. Content stays within the normal container. */
.sp-section--flow {
	background: var(--base-2, #F7F5F1);
	box-shadow: 0 0 0 100vmax var(--base-2, #F7F5F1);
	clip-path: inset(0 -100vmax);
}

.sp-flow,
.sp-wall,
.sp-candle-map {
	--sp-accent: var(--accent, #866850);
	--sp-accent-2: var(--accent-2, #CDAA8C);
	--sp-accent-3: var(--accent-3, #D9CFC2);
	--sp-base: var(--base, #EAE5DC);
	--sp-base-2: var(--base-2, #F7F5F1);
	--sp-white: var(--base-3, #ffffff);
	--sp-contrast: var(--contrast, #1C1B18);
	--sp-text: var(--contrast-2, #4A463F);
	--sp-serif: var(--gp-font--cormorant-garamond, "Cormorant Garamond", Georgia, serif);
	--sp-sans: var(--gp-font--source-sans-3, "Source Sans 3", system-ui, sans-serif);
	--sp-radius: 8px;
	--sp-shadow: 0 0 14px 6px rgba(80, 80, 102, 0.06);
}

.sp-flow {
	max-width: 780px;
	margin: 0 auto;
	font-family: var(--sp-sans);
	color: var(--sp-text);
	text-align: center;
}

/* Homepage-style kicker above the form card. */
.sp-flow__lead {
	margin: 0 0 1.5rem;
}

/* The form sits in a white card on the subtle band (uses .gbp-card too). */
.sp-flow__card {
	text-align: left;
	padding: clamp(1.5rem, 4vw, 2.75rem);
}

/* Step indicator */
.sp-flow__steps {
	display: flex;
	justify-content: center;
	gap: 1.25rem;
	list-style: none;
	margin: 0 0 2.5rem;
	padding: 0;
	counter-reset: none;
}

.sp-flow__steps li {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 2.25rem;
	height: 2.25rem;
	border-radius: 9999px;
	background: var(--sp-base);
	color: var(--sp-text);
	font-weight: 600;
	font-size: 0.95rem;
	position: relative;
}

.sp-flow__steps li:not(:last-child)::after {
	content: "";
	position: absolute;
	left: 100%;
	width: 1.25rem;
	height: 2px;
	background: var(--sp-accent-3);
}

.sp-flow__steps li.is-active {
	background: var(--sp-accent);
	color: var(--sp-white);
}

.sp-flow__steps li.is-done {
	background: var(--sp-accent-2);
	color: var(--sp-white);
}

/* Panels */
.sp-flow__heading {
	font-family: var(--sp-serif);
	margin: 0 0 0.5rem;
}

.sp-flow__heading:focus {
	outline: none;
}

.sp-flow__intro {
	margin: 0 0 1.75rem;
	opacity: 0.9;
}

/* Fields */
.sp-field {
	margin-bottom: 1.25rem;
}

.sp-field label {
	display: block;
	font-weight: 600;
	margin-bottom: 0.4rem;
}

.sp-field input[type="text"],
.sp-field input[type="email"],
.sp-field textarea,
.sp-field select {
	width: 100%;
	padding: 0.75rem 0.9rem;
	border: 1px solid var(--sp-accent-3);
	border-radius: var(--sp-radius);
	background: var(--sp-white);
	color: var(--sp-text);
	font-family: var(--sp-sans);
	font-size: 1rem;
	box-sizing: border-box;
}

.sp-field textarea {
	resize: vertical;
	min-height: 8rem;
}

.sp-field input:focus,
.sp-field textarea:focus,
.sp-field select:focus {
	outline: 2px solid var(--sp-accent);
	outline-offset: 1px;
	border-color: var(--sp-accent);
}

.sp-field [aria-invalid="true"] {
	border-color: #b3261e;
}

.sp-field__error {
	color: #b3261e;
	font-size: 0.875rem;
	margin: 0.35rem 0 0;
	min-height: 1em;
}

.sp-field--check label {
	display: flex;
	align-items: flex-start;
	gap: 0.6rem;
	font-weight: 400;
}

.sp-field--check input {
	margin-top: 0.2rem;
}

/* Option cards (step 2) */
.sp-option {
	background: var(--sp-white);
	border: 1px solid var(--sp-accent-3);
	border-radius: var(--sp-radius);
	box-shadow: var(--sp-shadow);
	padding: 1.4rem 1.6rem;
	margin-bottom: 1.1rem;
}

.sp-option__head {
	display: flex;
	align-items: center;
	gap: 0.7rem;
	font-weight: 600;
	cursor: pointer;
}

.sp-option__title {
	flex: 1;
}

.sp-option__price {
	font-family: var(--sp-serif);
	font-size: 1.25rem;
	color: var(--sp-accent);
	white-space: nowrap;
}

.sp-option__desc {
	margin: 0.6rem 0 0;
	padding-left: 1.9rem;
	opacity: 0.85;
	font-size: 0.95rem;
}

.sp-option__body {
	margin-top: 1rem;
	padding-top: 1rem;
	border-top: 1px solid var(--sp-base);
}

/* Actions */
.sp-flow__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	align-items: center;
	margin-top: 1.75rem;
}

/* Buttons reuse the site's global .gbp-button--primary/--secondary styles for
   consistency with the home page; we only add interaction states here. */
.sp-flow .gbp-button,
.sp-wall .gbp-button {
	cursor: pointer;
	text-decoration: none;
}

.sp-flow .gbp-button:disabled {
	opacity: 0.6;
	cursor: default;
}

.sp-flow__skip {
	display: inline-block;
	margin-top: 1rem;
	background: none;
	border: 0;
	padding: 0;
	color: var(--sp-accent);
	text-decoration: underline;
	cursor: pointer;
	font-size: 0.95rem;
}

.sp-flow__banner {
	background: #fbeaea;
	color: #b3261e;
	border-radius: var(--sp-radius);
	padding: 0.85rem 1rem;
	margin: 1.25rem 0 0;
}

/* Thank-you panel */
.sp-flow__panel--thanks {
	text-align: center;
	padding: 2rem 0;
}

.sp-flow__thanks-candle {
	color: var(--sp-accent);
	font-weight: 600;
	margin: 0.25rem 0 0;
}

.sp-flow__thanks-copy {
	max-width: 34rem;
	margin: 0.75rem auto 1.75rem;
}

.sp-flow__thanks-actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	justify-content: center;
}

/* Honeypot: hidden from humans, present for bots */
.sp-hp {
	position: absolute !important;
	left: -9999px !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

@media (max-width: 768px) {
	.sp-section {
		padding: 2.5rem 1rem;
	}
	.sp-flow__actions {
		flex-direction: column;
		align-items: stretch;
	}
	.sp-flow__actions .gbp-button {
		width: 100%;
		text-align: center;
	}
	.sp-option__desc {
		padding-left: 0;
	}
}
