/**
 * Custom Formulation page-only styles.
 * Loads only on /custom-formulation/.
 */

.ahm-page-custom-formulation {
	--formulation-navy: #101d3a;
	--formulation-navy-soft: #1b2948;
	--formulation-green: #356f3b;
	--formulation-green-hover: #4c833c;
	--formulation-green-soft: #edf4ea;
	--formulation-surface: #f7faf8;
	--formulation-line: #dce5df;
	background: #fff;
}

.ahm-page-custom-formulation .text-link {
	color: var(--formulation-green);
	font-weight: 760;
	text-decoration: none;
}

.ahm-page-custom-formulation .text-link span {
	display: inline-block;
	transition: transform .18s ease;
}

.ahm-page-custom-formulation .text-link:hover,
.ahm-page-custom-formulation .text-link:focus-visible {
	color: var(--formulation-green-hover);
	text-decoration: underline;
	text-underline-offset: 4px;
}

.ahm-page-custom-formulation .text-link:hover span,
.ahm-page-custom-formulation .text-link:focus-visible span {
	transform: translateX(3px);
}

/* Hero */
.ahm-formulation-hero {
	position: relative;
	overflow: hidden;
	border-bottom: 1px solid var(--formulation-line);
	background:
		radial-gradient(circle at 93% 8%, rgba(77, 130, 73, .12), transparent 27%),
		linear-gradient(110deg, #fff 0 58%, #f2f7f2 58% 100%);
}

.ahm-formulation-hero::after {
	position: absolute;
	right: -120px;
	bottom: -170px;
	width: 430px;
	height: 430px;
	border: 1px solid rgba(53, 111, 59, .11);
	border-radius: 50%;
	content: '';
}

.ahm-formulation-hero__grid {
	position: relative;
	z-index: 1;
	display: grid;
	min-height: 610px;
	padding: 50px 0 64px;
	align-items: center;
	grid-template-columns: minmax(0, 1.03fr) minmax(430px, .97fr);
	gap: 76px;
}

.ahm-formulation-hero__copy h1 {
	max-width: 800px;
	margin: 22px 0 0;
	color: var(--color-primary);
	font-size: clamp(3.15rem, 4.7vw, 4.55rem);
	line-height: 1.035;
	letter-spacing: -.052em;
}

.ahm-formulation-hero__intro {
	max-width: 760px;
	margin: 25px 0 0;
	color: var(--color-muted);
	font-size: clamp(1.03rem, 1.45vw, 1.17rem);
	line-height: 1.72;
}

.ahm-formulation-hero__actions {
	display: flex;
	margin-top: 31px;
	flex-wrap: wrap;
	gap: 12px;
}

.ahm-formulation-hero__media {
	position: relative;
}

.ahm-formulation-hero__media img {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	border-radius: 30px;
	object-fit: cover;
	box-shadow: 0 28px 60px rgba(11, 29, 58, .14);
}

/* Shared section headings */
.ahm-formulation-section {
	padding: 96px 0;
}

.ahm-formulation-heading {
	max-width: 900px;
	margin: 0 auto 48px;
	text-align: center;
}

.ahm-formulation-heading h2,
.ahm-formulation-sampling__copy h2,
.ahm-formulation-faq__heading h2,
.ahm-formulation-cta__copy h2 {
	margin: 0;
	color: var(--color-primary);
	font-size: clamp(2.35rem, 3.6vw, 3.35rem);
	line-height: 1.08;
	letter-spacing: -.043em;
}

.ahm-formulation-heading > p:not(.eyebrow),
.ahm-formulation-faq__heading > p:not(.eyebrow) {
	max-width: 800px;
	margin: 19px auto 0;
	color: var(--color-muted);
	font-size: 1rem;
	line-height: 1.72;
}

/* Starting routes */
.ahm-formulation-start {
	background: #fff;
}

.ahm-formulation-start__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 24px;
}

.ahm-formulation-start__card {
	display: flex;
	min-height: 455px;
	padding: 38px;
	flex-direction: column;
	border: 1px solid var(--formulation-line);
	border-radius: 24px;
	background: #fff;
	box-shadow: 0 16px 34px rgba(11, 29, 58, .07);
	transition: border-color .18s ease, box-shadow .18s ease;
}

.ahm-formulation-start__card:hover {
	border-color: #bfd2c1;
	box-shadow: 0 22px 45px rgba(11, 29, 58, .1);
}

.ahm-formulation-start__top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
}

.ahm-formulation-start__top span {
	color: var(--formulation-green);
	font-family: var(--font-numeric);
	font-size: 2.35rem;
	font-weight: 800;
	line-height: 1;
}

.ahm-formulation-start__top small {
	padding: 8px 12px;
	border-radius: 999px;
	background: var(--formulation-green-soft);
	color: var(--formulation-green);
	font-size: .68rem;
	font-weight: 800;
	letter-spacing: .08em;
}

.ahm-formulation-start__card h3 {
	margin: 31px 0 13px;
	color: var(--color-primary);
	font-size: clamp(1.7rem, 2.2vw, 2.15rem);
	line-height: 1.14;
	letter-spacing: -.035em;
}

.ahm-formulation-start__card > p {
	margin: 0;
	color: var(--color-muted);
	font-size: .96rem;
	line-height: 1.75;
}

.ahm-formulation-start__card ul {
	display: grid;
	margin: 25px 0 28px;
	padding: 0;
	gap: 12px;
	list-style: none;
}

.ahm-formulation-start__card li {
	position: relative;
	padding-left: 25px;
	color: var(--color-primary);
	font-size: .87rem;
	font-weight: 680;
	line-height: 1.5;
}

.ahm-formulation-start__card li::before {
	position: absolute;
	left: 0;
	color: var(--formulation-green);
	content: '✓';
	font-weight: 900;
}

.ahm-formulation-start__card .text-link {
	margin-top: auto;
}

/* Formula factors */
.ahm-formulation-factors {
	background: var(--formulation-surface);
}

.ahm-formulation-factor-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 20px;
}

.ahm-formulation-factor-grid article {
	min-height: 255px;
	padding: 31px;
	border: 1px solid var(--formulation-line);
	border-radius: 20px;
	background: #fff;
	box-shadow: 0 12px 26px rgba(11, 29, 58, .055);
	transition: border-color .18s ease, box-shadow .18s ease;
}

.ahm-formulation-factor-grid article:hover {
	border-color: #bfd2c1;
	box-shadow: 0 18px 36px rgba(11, 29, 58, .08);
}

.ahm-formulation-factor-grid article > span {
	display: flex;
	width: 48px;
	height: 48px;
	margin-bottom: 22px;
	align-items: center;
	justify-content: center;
	border-radius: 15px;
	background: var(--formulation-green-soft);
	color: var(--formulation-green);
	font-family: var(--font-numeric);
	font-size: 1.45rem;
	font-weight: 800;
}

.ahm-formulation-factor-grid h3 {
	margin: 0 0 11px;
	color: var(--color-primary);
	font-size: 1.26rem;
	line-height: 1.28;
}

.ahm-formulation-factor-grid p {
	margin: 0;
	color: var(--color-muted);
	font-size: .86rem;
	line-height: 1.68;
}

/* Process */
.ahm-formulation-process {
	padding: 100px 0;
	background: var(--formulation-navy);
}

.ahm-formulation-heading--dark h2 {
	color: #fff;
}

.ahm-formulation-heading--dark .eyebrow {
	color: #9bdc7c;
}

.ahm-formulation-heading--dark > p:not(.eyebrow) {
	color: rgba(255, 255, 255, .72);
}

.ahm-formulation-process__grid {
	display: grid;
	margin: 0;
	padding: 0;
	grid-template-columns: repeat(6, minmax(0, 1fr));
	gap: 18px;
	list-style: none;
}

.ahm-formulation-process__grid li {
	min-height: 248px;
	padding: 30px 28px;
	border: 1px solid rgba(255, 255, 255, .18);
	border-radius: 20px;
	background: rgba(255, 255, 255, .055);
}

.ahm-formulation-process__grid li {
	grid-column: span 2;
}

.ahm-formulation-process__grid li:nth-child(4) {
	grid-column: 2 / span 2;
}

.ahm-formulation-process__grid li:nth-child(5) {
	grid-column: 4 / span 2;
}

.ahm-formulation-process__grid li > span {
	display: block;
	margin-bottom: 35px;
	color: #9bdc7c;
	font-family: var(--font-numeric);
	font-size: 2rem;
	font-weight: 800;
	line-height: 1;
}

.ahm-formulation-process__grid h3 {
	margin: 0 0 12px;
	color: #fff;
	font-size: 1.18rem;
	line-height: 1.28;
}

.ahm-formulation-process__grid p {
	margin: 0;
	color: rgba(255, 255, 255, .7);
	font-size: .86rem;
	line-height: 1.68;
}

/* Sampling */
.ahm-formulation-sampling {
	background: #fff;
}

.ahm-formulation-sampling__grid {
	display: grid;
	align-items: center;
	grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr);
	gap: 76px;
}

.ahm-formulation-sampling__media img {
	display: block;
	width: 100%;
	aspect-ratio: 1.08 / 1;
	border-radius: 28px;
	object-fit: cover;
	box-shadow: 0 24px 50px rgba(11, 29, 58, .11);
}

.ahm-formulation-sampling__copy h2 {
	max-width: 620px;
}

.ahm-formulation-sampling__copy > p:not(.eyebrow) {
	margin: 21px 0 0;
	color: var(--color-muted);
	font-size: 1rem;
	line-height: 1.75;
}

.ahm-formulation-sampling__copy ul {
	display: grid;
	margin: 27px 0 0;
	padding: 0;
	gap: 13px;
	list-style: none;
}

.ahm-formulation-sampling__copy li {
	position: relative;
	padding-left: 27px;
	color: var(--color-primary);
	font-size: .9rem;
	font-weight: 680;
	line-height: 1.55;
}

.ahm-formulation-sampling__copy li::before {
	position: absolute;
	left: 0;
	color: var(--formulation-green);
	content: '✓';
	font-weight: 900;
}

.ahm-formulation-note {
	margin-top: 28px;
	padding: 17px 19px;
	border-left: 3px solid var(--formulation-green);
	background: var(--formulation-green-soft);
	color: var(--color-muted);
	font-size: .82rem;
	line-height: 1.6;
}

/* Documentation */
.ahm-formulation-docs {
	background: var(--formulation-surface);
}

.ahm-formulation-doc-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 18px;
}

.ahm-formulation-doc-grid article {
	min-height: 260px;
	padding: 29px;
	border: 1px solid var(--formulation-line);
	border-radius: 20px;
	background: #fff;
}

.ahm-formulation-doc-grid article > span {
	display: block;
	margin-bottom: 35px;
	color: var(--formulation-green);
	font-family: var(--font-numeric);
	font-size: 1.75rem;
	font-weight: 800;
}

.ahm-formulation-doc-grid h3 {
	margin: 0 0 11px;
	color: var(--color-primary);
	font-size: 1.16rem;
	line-height: 1.3;
}

.ahm-formulation-doc-grid p {
	margin: 0;
	color: var(--color-muted);
	font-size: .82rem;
	line-height: 1.67;
}

/* FAQ */
.ahm-formulation-faq {
	background: #fff;
}

.ahm-formulation-faq__grid {
	display: grid;
	align-items: start;
	grid-template-columns: minmax(320px, .72fr) minmax(0, 1.28fr);
	gap: 78px;
}

.ahm-formulation-faq__heading {
	position: sticky;
	top: 124px;
}

.ahm-formulation-faq__heading h2 {
	max-width: 480px;
}

.ahm-formulation-faq__heading > p:not(.eyebrow) {
	margin-left: 0;
	text-align: left;
}

.ahm-formulation-faq__list details {
	border-top: 1px solid var(--formulation-line);
}

.ahm-formulation-faq__list details:last-child {
	border-bottom: 1px solid var(--formulation-line);
}

.ahm-formulation-faq__list summary {
	position: relative;
	padding: 23px 52px 23px 0;
	color: var(--color-primary);
	font-size: 1rem;
	font-weight: 760;
	cursor: pointer;
	list-style: none;
}

.ahm-formulation-faq__list summary::-webkit-details-marker {
	display: none;
}

.ahm-formulation-faq__list summary::after {
	position: absolute;
	top: 50%;
	right: 6px;
	display: flex;
	width: 32px;
	height: 32px;
	align-items: center;
	justify-content: center;
	border-radius: 50%;
	background: var(--formulation-green-soft);
	color: var(--formulation-green);
	font-size: 1.25rem;
	content: '+';
	transform: translateY(-50%);
}

.ahm-formulation-faq__list details[open] summary::after {
	content: '−';
}

.ahm-formulation-faq__list details p {
	margin: 0;
	padding: 0 52px 23px 0;
	color: var(--color-muted);
	font-size: .88rem;
	line-height: 1.7;
}

/* Final formulation brief and CTA */
.ahm-formulation-cta {
	padding: 0 0 82px;
	background: #fff;
}

.ahm-formulation-cta__card {
	display: grid;
	padding: 48px;
	align-items: center;
	border-radius: 28px;
	background: linear-gradient(110deg, #101d3a, #223653 72%, #31515a);
	grid-template-columns: minmax(0, 1.05fr) minmax(320px, .82fr) minmax(250px, .58fr);
	gap: 40px;
	box-shadow: 0 25px 55px rgba(11, 29, 58, .15);
}

.ahm-formulation-cta__copy .eyebrow,
.ahm-formulation-cta__action > strong {
	color: #9bdc7c;
}

.ahm-formulation-cta__copy h2 {
	max-width: 620px;
	color: #fff;
}

.ahm-formulation-cta__copy > p:not(.eyebrow) {
	margin: 19px 0 0;
	color: rgba(255, 255, 255, .72);
	font-size: .95rem;
	line-height: 1.72;
}

.ahm-formulation-cta__list {
	display: grid;
	margin: 0;
	padding: 0;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 13px 22px;
	list-style: none;
}

.ahm-formulation-cta__list li {
	position: relative;
	padding-left: 23px;
	color: #fff;
	font-size: .8rem;
	font-weight: 670;
	line-height: 1.5;
}

.ahm-formulation-cta__list li::before {
	position: absolute;
	left: 0;
	color: #9bdc7c;
	content: '✓';
	font-weight: 900;
}

.ahm-formulation-cta__action {
	padding: 24px;
	border: 1px solid rgba(255, 255, 255, .18);
	border-radius: 20px;
	background: rgba(255, 255, 255, .06);
}

.ahm-formulation-cta__action > strong {
	display: block;
	font-size: .72rem;
	letter-spacing: .1em;
}

.ahm-formulation-cta__action p {
	margin: 13px 0 22px;
	color: rgba(255, 255, 255, .72);
	font-size: .8rem;
	line-height: 1.65;
}

.ahm-formulation-cta__action .button {
	width: 100%;
	text-align: center;
}

/* Responsive */
@media (max-width: 1220px) {
	.ahm-formulation-hero__grid {
		grid-template-columns: minmax(0, 1fr) minmax(390px, .85fr);
		gap: 48px;
	}

	.ahm-formulation-process__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.ahm-formulation-process__grid li,
	.ahm-formulation-process__grid li:nth-child(4),
	.ahm-formulation-process__grid li:nth-child(5) {
		grid-column: auto;
	}

	.ahm-formulation-doc-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.ahm-formulation-cta__card {
		grid-template-columns: minmax(0, 1fr) minmax(320px, .85fr);
	}

	.ahm-formulation-cta__action {
		grid-column: 1 / -1;
		display: grid;
		align-items: center;
		grid-template-columns: minmax(0, 1fr) auto;
		gap: 22px;
	}

	.ahm-formulation-cta__action p {
		margin: 7px 0 0;
	}

	.ahm-formulation-cta__action .button {
		width: auto;
		grid-column: 2;
		grid-row: 1 / span 2;
	}
}

@media (max-width: 980px) {
	.ahm-formulation-hero {
		background: var(--formulation-surface);
	}

	.ahm-formulation-hero__grid,
	.ahm-formulation-sampling__grid,
	.ahm-formulation-faq__grid,
	.ahm-formulation-cta__card {
		grid-template-columns: 1fr;
	}

	.ahm-formulation-hero__grid {
		min-height: auto;
		padding: 44px 0 62px;
	}

	.ahm-formulation-hero__media {
		max-width: 760px;
	}

	.ahm-formulation-factor-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.ahm-formulation-process__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.ahm-formulation-sampling__grid {
		gap: 45px;
	}

	.ahm-formulation-faq__heading {
		position: static;
	}

	.ahm-formulation-cta__action {
		display: block;
		grid-column: auto;
	}

	.ahm-formulation-cta__action p {
		margin: 13px 0 22px;
	}

	.ahm-formulation-cta__action .button {
		width: 100%;
	}
}

@media (max-width: 760px) {
	.ahm-formulation-section,
	.ahm-formulation-process {
		padding: 72px 0;
	}

	.ahm-formulation-heading {
		margin-bottom: 36px;
	}

	.ahm-formulation-start__grid,
	.ahm-formulation-factor-grid,
	.ahm-formulation-process__grid,
	.ahm-formulation-doc-grid {
		grid-template-columns: 1fr;
	}

	.ahm-formulation-start__card {
		min-height: 0;
		padding: 28px;
	}

	.ahm-formulation-factor-grid article,
	.ahm-formulation-doc-grid article {
		min-height: 0;
	}

	.ahm-formulation-process__grid li {
		min-height: 0;
	}

	.ahm-formulation-sampling__media img {
		aspect-ratio: 4 / 3;
	}

	.ahm-formulation-cta__card {
		padding: 36px 28px;
		gap: 32px;
	}

	.ahm-formulation-cta__list {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 560px) {
	.ahm-formulation-hero__copy h1 {
		font-size: clamp(2.55rem, 12vw, 3.35rem);
	}

	.ahm-formulation-hero__actions {
		flex-direction: column;
	}

	.ahm-formulation-hero__actions .button {
		width: 100%;
		text-align: center;
	}

	.ahm-formulation-hero__media img {
		border-radius: 20px;
	}

	.ahm-formulation-start__top {
		align-items: flex-start;
		flex-direction: column;
		gap: 13px;
	}

	.ahm-formulation-faq__list summary {
		padding-right: 46px;
	}

	.ahm-formulation-faq__list details p {
		padding-right: 0;
	}
}

@media (prefers-reduced-motion: reduce) {
	.ahm-page-custom-formulation *,
	.ahm-page-custom-formulation *::before,
	.ahm-page-custom-formulation *::after {
		scroll-behavior: auto !important;
		transition-duration: .01ms !important;
	}
}
