/**
 * Service landing pages — softlance/lp-* blocks (inc/section-blocks.php).
 * Builds on sections.css (ab-* shared classes) and the ds.css tokens.
 *
 * Contents: hero + form · stats · sticky bar · problems · included ·
 * CTA band · pricing · tech · FAQ · page · responsive
 */

/* ─── Hero form ───────────────────────────────────────────────────────── */
.lp-hero__inner--solo { grid-template-columns: minmax(0, 1fr); max-width: 52rem; }

.lp-form-card {
	position: relative;
	display: grid;
	gap: 0.75rem;
	padding: clamp(1.5rem, 3vw, 2.25rem);
	border: 1px solid var(--ds-line);
	border-radius: var(--ds-r-xl);
	background: #fff;
	box-shadow: var(--ds-shadow-lg);
}

.lp-form-card::before {
	content: "";
	position: absolute;
	inset: 0 1.5rem auto;
	height: 3px;
	border-radius: 0 0 3px 3px;
	background: var(--ds-blue);
}

.lp-form-card__title { margin: 0; }

.lp-form-card__text {
	margin: 0 0 0.25rem;
	font-size: 0.9375rem;
	line-height: 1.55;
	color: var(--ds-muted);
}

.lp-form-card .ds-form { gap: 0.875rem; }

.lp-form-card .ds-form__note {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.375rem;
	margin: 0;
	font-size: 0.8125rem;
	color: var(--ds-muted);
}

.lp-form-card__alt {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 0.5rem 1rem;
	padding-top: 1rem;
	border-top: 1px solid var(--ds-line);
	font-size: 0.875rem;
	color: var(--ds-muted);
}

.lp-form-card__alt a,
body.sl-shadcn-ui .lp-form-card__alt a {
	display: inline-flex;
	align-items: center;
	gap: 0.375rem;
	font-weight: 600;
	color: var(--ds-ink);
	text-decoration: none;
}

.lp-form-card__alt a:hover { color: var(--ds-blue); }

/* ─── Proof stats ─────────────────────────────────────────────────────── */
.lp-stats {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 1.5rem;
	margin: clamp(2.5rem, 5vw, 4rem) 0 0;
	padding-top: 2rem;
	border-top: 1px solid var(--ds-line-strong);
}

.lp-stat {
	display: flex;
	flex-direction: column-reverse;
	justify-content: flex-end;
	gap: 0.25rem;
}

.lp-stat__value {
	margin: 0;
	font-size: clamp(1.375rem, 2.2vw, 1.75rem);
	font-weight: 700;
	line-height: 1.15;
	letter-spacing: -0.02em;
	color: var(--ds-ink);
}

.lp-stat__label {
	margin: 0;
	font-size: 0.875rem;
	color: var(--ds-muted);
}

/* ─── Sticky bar (phones) ─────────────────────────────────────────────── */
.lp-sticky { display: none; }

@media (max-width: 760px) {
	.lp-sticky {
		position: fixed;
		inset: auto 0 0;
		z-index: 90;
		display: flex;
		gap: 0.5rem;
		padding: 0.625rem 1rem calc(0.625rem + env(safe-area-inset-bottom));
		border-top: 1px solid var(--ds-line);
		background: rgba(255, 255, 255, 0.97);
		box-shadow: 0 -8px 24px -12px rgba(10, 22, 40, 0.25);
	}

	.lp-sticky[hidden] { display: none; }
	.lp-sticky__main { flex: 1; }

	.lp-sticky__icon,
	body.sl-shadcn-ui .lp-sticky__icon {
		display: grid;
		place-items: center;
		flex: none;
		width: 2.75rem;
		height: 2.75rem;
		border-radius: 10px;
		background: var(--ds-blue-100);
		color: var(--ds-blue);
	}

	body.has-lp-sticky { padding-bottom: 4.5rem; }

	/* Lift the site chat launcher above the bar. */
	body.has-lp-sticky .slrc-chat {
		bottom: calc(4.75rem + env(safe-area-inset-bottom));
		transition: bottom 0.2s var(--ds-ease);
	}
}

/* ─── Problems & fixes ────────────────────────────────────────────────── */
.lp-problems__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 1.25rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.lp-problem {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	border: 1px solid var(--ds-line);
	border-radius: var(--ds-r-lg);
	background: #fff;
	transition: border-color 0.25s var(--ds-ease), box-shadow 0.25s var(--ds-ease);
}

.lp-problem:hover {
	border-color: var(--ds-blue-200);
	box-shadow: var(--ds-shadow);
}

.lp-problem__pain,
.lp-problem__fix {
	display: flex;
	align-items: flex-start;
	gap: 0.75rem;
	padding: 1.25rem 1.5rem;
}

.lp-problem__pain .ds-h5 { margin: 0; }

.lp-problem__fix {
	flex: 1;
	border-top: 1px dashed var(--ds-line-strong);
	background: var(--ds-blue-50);
}

.lp-problem__fix p {
	margin: 0;
	font-size: 0.9375rem;
	line-height: 1.6;
	color: var(--ds-text);
}

.lp-problem__mark {
	display: grid;
	place-items: center;
	flex: none;
	width: 1.5rem;
	height: 1.5rem;
	margin-top: 0.0625rem;
	border-radius: 50%;
	background: var(--ds-blue-100);
	color: var(--ds-blue);
}

.lp-problem__mark .ds-icon { width: 0.875rem; height: 0.875rem; stroke-width: 3; }

.lp-problem__mark--x {
	background: var(--ds-line);
	color: var(--ds-muted);
}

.lp-center {
	margin-top: clamp(2rem, 4vw, 2.75rem);
	text-align: center;
}

/* ─── Included features ───────────────────────────────────────────────── */
.lp-checklist__grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 1rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

.lp-feature {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	padding: 1.375rem;
	border: 1px solid var(--ds-line);
	border-radius: var(--ds-r-lg);
	background: #fff;
}

.lp-feature .ds-iconbox { margin-bottom: 0.25rem; }

.lp-feature__text {
	margin: 0;
	font-size: 0.875rem;
	line-height: 1.6;
	color: var(--ds-muted);
}

.lp-checklist__note {
	margin: 1.75rem 0 0;
	font-size: 0.875rem;
	text-align: center;
	color: var(--ds-muted);
}

/* ─── CTA band ────────────────────────────────────────────────────────── */
.lp-band {
	padding-block: clamp(1rem, 3vw, 2rem);
	background: #fff;
}

.lp-band__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 1.5rem 2.5rem;
	padding: clamp(2rem, 4vw, 3rem);
	border-radius: var(--ds-r-xl);
	background:
		radial-gradient(30rem 16rem at 100% 0%, rgba(255, 255, 255, 0.16), transparent 60%),
		linear-gradient(135deg, var(--ds-blue) 0%, var(--ds-navy-2) 100%);
	box-shadow: var(--ds-shadow-lg);
	color: #fff;
}

.lp-band__copy { flex: 1 1 26rem; max-width: 40rem; }

.lp-band__title,
.lp-band .ab-title strong { color: #fff; }

.lp-band__title { font-size: clamp(1.5rem, 2.6vw, 2rem); }

.lp-band__text {
	margin: 0.75rem 0 0;
	font-size: 1.0625rem;
	line-height: 1.6;
	color: rgba(255, 255, 255, 0.82);
}

.lp-band__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.75rem 1.25rem;
}

.lp-band__ghost,
body.sl-shadcn-ui .lp-band__ghost {
	border-color: rgba(255, 255, 255, 0.45);
	background: transparent;
	color: #fff;
}

.lp-band__ghost:hover {
	border-color: #fff;
	background: rgba(255, 255, 255, 0.1);
	color: #fff;
}

.lp-band__phone,
body.sl-shadcn-ui .lp-band__phone {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	font-weight: 600;
	color: #fff;
	text-decoration: none;
}

.lp-band__phone:hover { color: var(--ds-blue-200); }

/* ─── Pricing ─────────────────────────────────────────────────────────── */
.lp-pricing__note {
	margin: 1.75rem auto 0;
	max-width: 44rem;
	font-size: 0.875rem;
	line-height: 1.6;
	text-align: center;
	color: var(--ds-muted);
}

.lp-compare .ds-section { padding-top: 0; }
.lp-compare .ds-head { text-align: center; }
.lp-compare .ds-head__main { margin-inline: auto; }

/* ─── Technology ──────────────────────────────────────────────────────── */
.lp-tech__inner {
	display: grid;
	grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.4fr);
	align-items: start;
	gap: clamp(2rem, 5vw, 4.5rem);
}

.lp-tech .ab-head { margin-bottom: 0; }

.lp-tech__groups {
	display: grid;
	margin: 0;
}

.lp-tech__group {
	display: grid;
	grid-template-columns: 9rem minmax(0, 1fr);
	gap: 1rem;
	padding: 1.25rem 0;
	border-top: 1px solid var(--ds-line);
}

.lp-tech__group:last-child { border-bottom: 1px solid var(--ds-line); }

.lp-tech__group dd { margin: 0; }

.lp-tech__label {
	padding-top: 0.5rem;
	font-size: 0.8125rem;
	font-weight: 600;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	color: var(--ds-muted);
}

.lp-tech__chips {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin: 0;
	padding: 0;
	list-style: none;
}

/* ─── FAQ ─────────────────────────────────────────────────────────────── */
.lp-faq__inner {
	display: grid;
	grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.3fr);
	align-items: start;
	gap: clamp(2rem, 5vw, 4.5rem);
}

.lp-faq__aside {
	position: sticky;
	top: 7rem;
}

.lp-faq__card {
	display: grid;
	justify-items: start;
	gap: 0.625rem;
	padding: 1.5rem;
	border: 1px solid var(--ds-blue-200);
	border-radius: var(--ds-r-lg);
	background: var(--ds-blue-50);
}

.lp-faq__card .ds-h5 { margin: 0; }

.lp-faq__card-text {
	margin: 0 0 0.5rem;
	font-size: 0.9375rem;
	line-height: 1.6;
	color: var(--ds-muted);
}

.lp-faq__list { border-top: 1px solid var(--ds-line); }

.lp-faq__item { border-bottom: 1px solid var(--ds-line); }

.lp-faq__item summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 1rem;
	padding: 1.25rem 0;
	list-style: none;
	cursor: pointer;
}

.lp-faq__item summary::-webkit-details-marker { display: none; }

.lp-faq__q {
	margin: 0;
	font-size: 1.0625rem;
	font-weight: 600;
	line-height: 1.4;
	color: var(--ds-ink);
}

.lp-faq__item summary:hover .lp-faq__q { color: var(--ds-blue); }

.lp-faq__icon {
	position: relative;
	flex: none;
	width: 1.75rem;
	height: 1.75rem;
	border-radius: 50%;
	background: var(--ds-blue-100);
}

.lp-faq__icon::before,
.lp-faq__icon::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 0.75rem;
	height: 2px;
	border-radius: 2px;
	background: var(--ds-blue);
	transform: translate(-50%, -50%);
	transition: transform 0.25s var(--ds-ease);
}

.lp-faq__icon::after { transform: translate(-50%, -50%) rotate(90deg); }
.lp-faq__item[open] .lp-faq__icon::after { transform: translate(-50%, -50%) rotate(0deg); }

.lp-faq__a p,
.lp-faq__item.is-editing .lp-faq__a {
	margin: 0;
	padding: 0 2.75rem 1.25rem 0;
	line-height: 1.7;
	color: var(--ds-text);
}

.lp-faq__item.is-editing .lp-faq__q { padding-top: 1.25rem; margin-bottom: 0.5rem; }

/* ─── Page ────────────────────────────────────────────────────────────── */
.sl-landing-main,
.sl-landing-main > .entry-content { overflow: visible; }

.sl-landing-main > .entry-content > * { margin-block: 0; }

/* theme.css zeroes padding-top on every post-content child (!important). */
.wp-block-post-content > .lp-band { padding-top: clamp(1rem, 3vw, 2rem) !important; }

body.sl-landing-page .softlance-floating-cta { display: none !important; }

/* ─── Responsive ──────────────────────────────────────────────────────── */
@media (max-width: 1100px) {
	.lp-checklist__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 960px) {
	.lp-problems__grid,
	.lp-checklist__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }

	.lp-tech__inner,
	.lp-faq__inner { grid-template-columns: minmax(0, 1fr); }

	.lp-faq__aside { position: static; }
	.lp-form-card { max-width: 34rem; }
}

@media (max-width: 640px) {
	.lp-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem 1rem; }
	.lp-problems__grid { grid-template-columns: minmax(0, 1fr); }
	.lp-tech__group { grid-template-columns: minmax(0, 1fr); gap: 0.625rem; }
	.lp-tech__label { padding-top: 0; }
	.lp-band__actions,
	.lp-band__actions .ds-btn { width: 100%; }
}

@media (max-width: 420px) {
	.lp-checklist__grid { grid-template-columns: minmax(0, 1fr); }
}
