/**
 * Home Page template (patterns in patterns/home-page-*.php). Loaded together with service-page.css, which
 * provides the `np-svc` base (fonts, colors, buttons, links, FAQ). Home sections add an `hp-*` class.
 */

/* MontreuxC Bold is in the theme but WordPress does not print its @font-face, so load it here. */
@font-face {
	font-family: 'MontreuxC-Bd';
	src: url('../fonts/montreuxc/MontreuxC-Bd.woff2') format('woff2');
	font-weight: normal;
	font-style: normal;
	font-display: swap;
}

/* Home sections: heavier headings than the service page (theme Montreux Bold; the hero title ExtraBold). */
.np-svc[class*=" hp-"] {
	--sp-font-head: 'MontreuxC-Bd', var(--wp--preset--font-family--montreux-c-dm-bd), sans-serif;
}

.np-svc.hp-hero h1 {
	font-family: var(--wp--preset--font-family--montreuxc-x-bd, var(--sp-font-head));
}

/* ---------- Header over the hero (body.np-hp-blend) ---------- */
/* The sticky site header overlaps the hero while at the top; service-page.js adds .is-scrolled on scroll. */
body.np-hp-blend header.wp-block-template-part {
	margin-bottom: calc(-1 * var(--hp-head-h, 80px));
}

body.np-hp-blend header.wp-block-template-part .np--header__navigation {
	transition: background-color .3s ease, box-shadow .3s ease;
}

body.np-hp-blend:not(.is-scrolled) header.wp-block-template-part .np--header__navigation {
	background-color: transparent !important;
}

body.np-hp-blend.is-scrolled header.wp-block-template-part .np--header__navigation {
	box-shadow: 0 8px 24px rgba(7, 11, 36, .25);
}

/* At the top the header content lines up with the hero content (1296px); it widens as it turns solid. */
body.np-hp-blend header.wp-block-template-part .np--header__navigation > .alignfull {
	transition: padding .5s ease;
}

body.np-hp-blend:not(.is-scrolled) header.wp-block-template-part .np--header__navigation > .alignfull {
	padding-inline: max(clamp(20px, 4vw, 48px), calc((100vw - 1296px) / 2 + clamp(20px, 4vw, 48px) - 7px)) !important; /* 7px: logo inset inside the theme header */
}

/* ---------- Link hover: underline grows left to right (same as the footer links) ---------- */
.np-svc :is(.hp-caps, .hp-svc .sp-card-link, .hp-work h3) a {
	padding-bottom: 3px;
	text-decoration: none;
	background: linear-gradient(currentColor, currentColor) left bottom / 0 1px no-repeat;
	transition: background-size .3s ease;
}

.np-svc :is(.hp-caps, .hp-svc .sp-card-link, .hp-work h3) a:is(:hover, :focus-visible) {
	background-size: 100% 1px;
}

/* ---------- Light reveal on scroll (service-page.js adds .hp-anim to <html> and .is-in per item) ---------- */
.hp-anim .hp-reveal {
	opacity: 0;
	transform: translateY(18px);
	transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1);
	transition-delay: calc(var(--hp-i, 0) * 90ms);
}

.hp-anim .hp-reveal.is-in {
	opacity: 1;
	transform: none;
}

body.np-hp-blend .np-svc.hp-hero {
	padding-top: calc(clamp(48px, 6vw, 88px) + var(--hp-head-h, 80px));
}

/* ---------- 1. Hero ---------- */
.np-svc.hp-hero {
	overflow: hidden;
	padding: clamp(48px, 6vw, 88px) 0 clamp(150px, 14vw, 200px);
	background: var(--sp-ink);
	color: var(--sp-cream);
}

/* Background photo (an Image block) + the design's navy overlay. */
.np-svc .hp-hero-bg {
	position: absolute;
	inset: 0;
	z-index: 0;
	border-radius: 0;
	background: none;
}

.np-svc .hp-hero-bg img {
	object-position: 12% 35%;
}

.np-svc.hp-hero::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	background:
		linear-gradient(90deg, rgba(7, 11, 36, .86) 0%, rgba(7, 11, 36, .72) 45%, rgba(7, 11, 36, .55) 100%),
		linear-gradient(180deg, rgba(7, 11, 36, .25) 0%, rgba(7, 11, 36, .50) 50%, #070B24 94%);
	pointer-events: none;
}

.np-svc .hp-hero-grid {
	z-index: 2;
	display: grid;
	grid-template-columns: minmax(0, 1.1fr) minmax(0, 470px);
	gap: 40px clamp(40px, 5vw, 80px);
	align-items: center;
	min-height: 671px;
}

.np-svc .hp-hero-copy {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 24px;
}

.np-svc.hp-hero .sp-eyebrow {
	color: var(--sp-muted-light);
}

.np-svc.hp-hero .sp-eyebrow + h1 {
	margin-top: 0;
}

.np-svc.hp-hero h1 {
	font-size: clamp(40px, 5vw, 72px);
	font-weight: 700;
	line-height: 1;
	letter-spacing: -.035em;
}

.np-svc.hp-hero :is(h1, .hp-hero-sub, .hp-trust) {
	text-shadow: 0 2px 18px rgba(7, 11, 36, .55);
}

.np-svc .hp-hero-sub {
	max-width: 600px;
	font-size: clamp(18px, 1.6vw, 22px);
	line-height: 1.55;
	color: var(--sp-muted-light);
}

.np-svc .hp-trust {
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 15px;
	font-weight: 600;
	color: var(--sp-lime);
}

.np-svc .hp-trust::before {
	content: "★★★★★";
	letter-spacing: 3px;
}

/* Service Selector block as the glass card on the right. */
.np-svc .hp-help {
	max-width: none;
	--np-ss-accent: var(--sp-lime);
	--np-ss-accent-hover: #d3ec5a;
	--np-ss-bg: var(--sp-ink);
}

.np-svc .hp-help .np-service-selector__card {
	padding: clamp(20px, 2.4vw, 32px);
	border-radius: 24px;
	background: rgba(7, 11, 36, .62);
	border-color: rgba(255, 255, 255, .16);
	box-shadow: none;
	-webkit-backdrop-filter: blur(14px);
	backdrop-filter: blur(14px);
}

.np-svc .hp-help .np-service-selector__heading {
	margin-bottom: 20px;
	font-family: var(--sp-font-head);
	font-size: clamp(22px, 1.9vw, 26px);
	line-height: 1.15;
	letter-spacing: -.015em;
}

.np-svc .hp-help .np-service-selector__subtext {
	font-size: 15px;
	color: var(--sp-muted-light);
}

.np-svc .hp-help .np-service-selector__options {
	gap: 10px;
}

.np-svc .hp-help .np-service-selector__option {
	min-height: 52px;
	padding: 10px 14px;
	border-radius: 12px;
	background: rgba(255, 255, 255, .05);
}

.np-svc .hp-help .np-service-selector__option:hover,
.np-svc .hp-help .np-service-selector__option:has(:checked) {
	background: rgba(198, 227, 58, .16);
}

.np-svc .hp-help .np-service-selector__checkbox {
	width: 20px;
	height: 20px;
}

.np-svc .hp-help .np-service-selector__label {
	font-size: 16px;
	font-weight: 600;
	line-height: 1.25;
}

.np-svc .hp-help .np-service-selector__button {
	min-height: 58px;
	padding: 0 34px;
	font-family: var(--sp-font-body);
	font-size: 18px;
	font-weight: 600;
}

/* ---------- 2. Intro card (overlaps the hero) ---------- */
.np-svc.hp-intro {
	z-index: 2;
	padding: 0 0 clamp(56px, 6vw, 88px);
	background: var(--sp-cream);
}

.np-svc .hp-intro-card {
	margin-top: clamp(-150px, -11vw, -110px);
	padding: clamp(28px, 3.4vw, 48px);
	background: #fff;
	box-shadow: 0 24px 60px rgba(7, 11, 36, .10);
}

.np-svc .hp-intro-card::before {
	content: "";
	display: block;
	width: 120px;
	height: 6px;
	margin-bottom: 28px;
	background: var(--sp-lime);
}

.np-svc .hp-intro-card p:not(.sp-link) {
	max-width: 900px;
	font-size: 17px;
	line-height: 1.7;
	color: var(--sp-muted);
}

.np-svc .hp-intro-card strong {
	color: var(--sp-ink);
}

.np-svc .hp-caps {
	margin-top: 8px;
}

.np-svc .hp-caps a {
	font-size: 15px;
	letter-spacing: .06em;
	text-transform: uppercase;
	text-decoration: none;
}

/* ---------- 3. Services ---------- */
.np-svc.hp-services {
	--hp-g1: linear-gradient(90deg, #0A8DA1, #23A05C);
	--hp-g2: linear-gradient(90deg, #3E8E1A, #5E9612);
	--hp-g3: linear-gradient(90deg, #D46A0F, #D02F55);
	padding-top: clamp(24px, 3vw, 40px);
}

.np-svc .hp-head-center {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 18px;
	margin-bottom: clamp(40px, 5vw, 64px);
	text-align: center;
}

.np-svc .hp-cats {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: 6px 12px;
	font-size: 17px;
	font-weight: 700;
}

.np-svc .hp-cat + .hp-cat::before {
	content: "+";
	margin-right: 12px;
	color: var(--sp-ink);
	-webkit-text-fill-color: var(--sp-ink);
}

/* Gradient text (category words + card titles) and gradient card borders. */
.np-svc :is(.hp-cat, .hp-svc h3) {
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
	-webkit-text-fill-color: transparent;
}

.np-svc :is(.hp-cat.hp-c1, .hp-svc.hp-c1 h3) { background-image: var(--hp-g1); }
.np-svc :is(.hp-cat.hp-c2, .hp-svc.hp-c2 h3) { background-image: var(--hp-g2); }
.np-svc :is(.hp-cat.hp-c3, .hp-svc.hp-c3 h3) { background-image: var(--hp-g3); }

.np-svc .hp-svcs {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 30px;
}

.np-svc .hp-svc {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 12px;
	padding: clamp(28px, 2.6vw, 36px) clamp(26px, 2.4vw, 34px) clamp(30px, 2.8vw, 40px);
	border: 2px solid;
	background: #fff;
}

.np-svc .hp-svc.hp-c1 { border-image: var(--hp-g1) 1; }
.np-svc .hp-svc.hp-c2 { border-image: var(--hp-g2) 1; }
.np-svc .hp-svc.hp-c3 { border-image: var(--hp-g3) 1; }

.np-svc .hp-svc h3 {
	font-size: clamp(22px, 1.8vw, 25px);
	line-height: 1.12;
	letter-spacing: -.01em;
}

.np-svc .hp-svc p:not(.sp-card-link) {
	font-size: 17px;
	line-height: 1.6;
	color: var(--sp-muted);
}

.np-svc .hp-svc .sp-card-link {
	margin-top: auto;
	padding-top: 14px;
}

.np-svc .hp-svc .sp-card-link a {
	font-size: 18px;
	font-weight: 500;
	text-decoration: none;
}

/* ---------- 4. Client logos ---------- */
.np-svc.hp-trusted {
	padding: clamp(56px, 6vw, 88px) 0 calc(clamp(56px, 6vw, 88px) + 40px);
}

.np-svc.hp-trusted .sp-script {
	margin-bottom: clamp(16px, 2vw, 28px);
}

.np-svc .hp-logos {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	align-items: center;
	gap: 24px 48px;
	max-width: 1100px;
	margin: 0 auto;
}

.np-svc .hp-logos .wp-block-image {
	display: flex;
	align-items: center;
	justify-content: center;
	height: 64px;
	margin: 0;
	border-radius: 0;
	background: none;
	filter: grayscale(1);
}

.np-svc .hp-logos .sp-logo img {
	max-height: 56px;
	max-width: 140px;
	width: auto !important;
	height: auto !important;
}

/* ---------- 5. Our work (white panel with rounded top) ---------- */
.np-svc:is(.hp-work, .hp-faq) {
	z-index: 1;
	margin-top: -40px !important;
	border-radius: 40px 40px 0 0;
	background: #fff;
}

.np-svc .hp-head-row {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 20px;
	margin-bottom: clamp(28px, 3.5vw, 44px);
}

.np-svc .hp-bar::before {
	content: "";
	display: block;
	width: 120px;
	height: 8px;
	margin-bottom: 18px;
	background: var(--sp-ink);
}

.np-svc .hp-works {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 20px;
}

.np-svc .hp-work {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.np-svc .hp-work-media {
	position: relative;
	overflow: hidden;
	aspect-ratio: 4 / 5;
	border-radius: 22px;
	background: #EAE6DF;
}

.np-svc .hp-work-img {
	position: absolute;
	inset: 0;
	border-radius: 0;
	transition: transform .2s ease;
}

.np-svc .hp-work:hover .hp-work-img {
	transform: scale(1.015);
}

.np-svc .hp-stat {
	position: absolute;
	left: 14px;
	right: 14px;
	bottom: 14px;
	z-index: 1;
	display: flex;
	flex-direction: column;
	gap: 2px;
	padding: 16px 18px;
	border-radius: 16px;
	background: linear-gradient(32deg, #0C1435, #131D4C);
	color: var(--sp-cream);
}

.np-svc .hp-stat-num {
	font-family: var(--sp-font-head);
	font-size: clamp(34px, 3.4vw, 46px);
	font-weight: 700;
	line-height: 1;
	letter-spacing: -.04em;
	color: var(--sp-lime);
}

.np-svc .hp-stat-label {
	font-size: 15px;
	font-weight: 600;
}

.np-svc .hp-work-meta {
	font-size: 13px;
	font-weight: 600;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--sp-muted);
}

.np-svc .hp-work h3 {
	font-size: 22px;
	letter-spacing: -.015em;
}

.np-svc .hp-work h3 a {
	text-decoration: none;
}

/* ---------- 6. Reviews ---------- */
.np-svc.hp-says-sec {
	padding-top: 0;
	background: #fff;
}

.np-svc.hp-says-sec .sp-wrap {
	padding-top: clamp(36px, 4vw, 52px);
}

.np-svc.hp-says-sec .sp-wrap::before {
	content: "";
	position: absolute;
	top: 0;
	left: clamp(20px, 4vw, 48px);
	right: clamp(20px, 4vw, 48px);
	border-top: 1px solid var(--sp-line);
}

.np-svc.hp-says-sec .sp-script {
	margin-bottom: 18px;
	font-size: clamp(24px, 2.2vw, 32px);
}

.np-svc .hp-says {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 20px;
}

.np-svc .hp-say {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 14px;
	padding: 28px 26px 26px;
	border-radius: 22px;
	background: var(--sp-cream);
}

.np-svc .hp-say::after {
	content: "“";
	position: absolute;
	top: 18px;
	right: 22px;
	display: flex;
	justify-content: center;
	width: 44px;
	height: 44px;
	padding-top: 12px;
	border-radius: 50%;
	background: var(--sp-lime);
	font-family: var(--sp-font-head);
	font-size: 40px;
	font-weight: 700;
	line-height: 1;
}

.np-svc .hp-say-stars {
	font-size: 16px;
	letter-spacing: 2px;
}

.np-svc .hp-say-text {
	font-family: var(--sp-font-head);
	font-size: clamp(19px, 1.6vw, 22px);
	font-weight: 600;
	line-height: 1.4;
	letter-spacing: -.01em;
}

.np-svc .hp-say-name {
	margin-top: auto;
	font-size: 15px;
}

.np-svc .hp-say-name + .hp-say-role {
	margin-top: -12px;
}

.np-svc .hp-say-role {
	font-size: 15px;
	color: var(--sp-muted);
}

/* ---------- 7. Certified and recognized ---------- */
.np-svc:is(.hp-badges-sec, .hp-cta) {
	background: var(--sp-ink);
	color: var(--sp-cream);
}

.np-svc.hp-badges-sec {
	padding: clamp(40px, 4.5vw, 60px) 0 clamp(24px, 3vw, 40px);
}

.np-svc.hp-badges-sec .sp-eyebrow {
	margin-bottom: 18px;
	color: var(--sp-muted-light);
	text-align: center;
}

.np-svc .hp-badges {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 16px 28px;
}

.np-svc .hp-badge {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 12px;
	width: 150px;
	text-align: center;
}

.np-svc .hp-badge-img {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 124px;
	height: 112px;
	border-radius: 18px;
	background: #fff;
}

.np-svc .hp-badge-img img {
	max-width: 104px;
	max-height: 92px;
	width: auto !important;
	height: auto !important;
	object-fit: contain;
}

.np-svc .hp-badge-dark {
	background: rgba(255, 255, 255, .06);
	border: 1px solid rgba(255, 255, 255, .22);
}

.np-svc .hp-badge-wide {
	background: #020939;
	border: 1px solid rgba(255, 255, 255, .22);
}

.np-svc .hp-badge-wide img {
	max-width: 124px;
	max-height: 112px;
}

.np-svc .hp-badge-cap {
	font-size: 13px;
	font-weight: 600;
	line-height: 1.25;
	color: var(--sp-muted-light);
}

/* ---------- 8. Final CTA ---------- */
.np-svc.hp-cta {
	padding: clamp(24px, 3vw, 40px) 0 calc(clamp(56px, 6vw, 88px) + 40px);
}

.np-svc .hp-cta-card {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 28px 48px;
	padding: clamp(36px, 5vw, 64px);
	border-radius: 28px;
	background: var(--sp-lime);
	color: var(--sp-ink);
}

.np-svc .hp-cta-card h2.wp-block-heading {
	font-size: clamp(34px, 4.4vw, 60px);
	line-height: 1.02;
	letter-spacing: -.03em;
}

.np-svc .hp-cta-card p {
	max-width: 520px;
	margin-top: 12px;
	font-size: clamp(17px, 1.4vw, 20px);
	line-height: 1.55;
}

.np-svc .hp-btn-ink .wp-block-button__link,
.np-svc .hp-btn-ink .wp-block-button__link:hover {
	background: var(--sp-ink);
	color: var(--sp-cream);
}

/* ---------- 9. FAQ ---------- */
.np-svc .hp-faq-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1.8fr);
	gap: 32px clamp(40px, 6vw, 96px);
	align-items: start;
}

.np-svc .hp-faq-intro {
	position: sticky;
	top: calc(var(--hp-head-h, 80px) + 32px); /* below the sticky site header */
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 16px;
}

.np-svc .hp-faq-intro .sp-eyebrow + h2 {
	margin-top: 0;
}

.np-svc .hp-faq-intro p:not(.sp-eyebrow, .sp-link) {
	font-size: 18px;
	line-height: 1.55;
	color: var(--sp-muted);
}

.np-svc .hp-faq-intro .sp-link a::after {
	display: none;
}

body.admin-bar .np-svc .hp-faq-intro {
	top: calc(var(--hp-head-h, 80px) + 64px); /* + WordPress admin bar */
}

/* Numbered questions with a round +/× button. */
.np-svc .hp-faq-list {
	counter-reset: hp-faq;
}

.np-svc .hp-faq-list details {
	counter-increment: hp-faq;
}

.np-svc .hp-faq-list summary {
	gap: 18px;
	min-height: 76px;
	padding: 16px 58px 16px 0;
	font-family: var(--sp-font-head);
	font-size: clamp(18px, 1.5vw, 21px);
	font-weight: 700;
}

.np-svc .hp-faq-list summary::before {
	content: counter(hp-faq, decimal-leading-zero);
	flex: none;
	font-size: 15px;
	color: var(--sp-muted);
}

.np-svc .hp-faq-list summary::after {
	right: 0;
	width: 40px;
	height: 40px;
	margin-top: -20px;
	border-radius: 50%;
	background:
		linear-gradient(var(--sp-ink), var(--sp-ink)) center / 14px 3px no-repeat,
		linear-gradient(var(--sp-ink), var(--sp-ink)) center / 3px 14px no-repeat,
		var(--sp-sand);
	transition: transform .2s, background-color .2s;
}

.np-svc .hp-faq-list details[open] summary::after {
	background:
		linear-gradient(var(--sp-ink), var(--sp-ink)) center / 14px 3px no-repeat,
		linear-gradient(var(--sp-ink), var(--sp-ink)) center / 3px 14px no-repeat,
		var(--sp-lime);
}

.np-svc .hp-faq-list details > p {
	max-width: none;
	padding: 0 56px 24px 36px;
	line-height: 1.65;
}

/* ---------- Responsive ---------- */
@media (max-width: 1060px) {
	.np-svc .hp-hero-grid,
	.np-svc .hp-faq-grid {
		grid-template-columns: minmax(0, 1fr);
	}

	.np-svc .hp-hero-grid {
		min-height: 0;
	}

	.np-svc .hp-help {
		max-width: 640px;
	}

	.np-svc :is(.hp-svcs, .hp-works) {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.np-svc .hp-says {
		grid-template-columns: minmax(0, 1fr);
	}

	.np-svc .hp-faq-intro {
		position: static;
	}
}

@media (max-width: 760px) {
	.np-svc.hp-hero {
		padding-bottom: 140px;
	}

	.np-svc.hp-hero::before {
		background: linear-gradient(180deg, rgba(7, 11, 36, .62) 0%, rgba(7, 11, 36, .82) 35%, #070B24 80%);
	}

	.np-svc .hp-hero-bg {
		bottom: auto;
		height: 70%;
	}

	.np-svc .hp-hero-bg img {
		object-position: 60% top;
	}

	.np-svc .hp-hero-copy {
		gap: 22px;
	}

	.np-svc .hp-help .np-service-selector__option {
		min-height: 48px;
		padding: 8px 10px;
		gap: 10px;
	}

	.np-svc .hp-help .np-service-selector__options {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 8px;
	}

	.np-svc .hp-help .np-service-selector__label {
		font-size: 14px;
	}

	.np-svc .hp-intro-card {
		margin-top: -100px;
		padding: 24px 20px;
	}

	.np-svc :is(.hp-svcs, .hp-works) {
		grid-template-columns: minmax(0, 1fr);
	}

	.np-svc .hp-svcs {
		gap: 18px;
	}

	.np-svc .hp-logos {
		gap: 20px 28px;
	}

	.np-svc .hp-work-media {
		aspect-ratio: 4 / 3;
	}

	.np-svc .hp-badge {
		width: 140px;
	}

	.np-svc .hp-cta-card {
		flex-direction: column;
		align-items: flex-start;
	}

	.np-svc .hp-faq-list details > p {
		padding: 0 0 22px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.np-svc .hp-work-img,
	body.np-hp-blend header.wp-block-template-part :is(.np--header__navigation, .np--header__navigation > .alignfull) {
		transition: none;
	}
}
