/**
 * Step 3 — Homepage introduction and category cards.
 */

body.page-template-recipe-home .site.grid-container {
	width: 100%;
	max-width: none;
}

body.page-template-recipe-home .site-content {
	display: block;
	padding: 0;
}

body.page-template-recipe-home .widget-area {
	display: none;
}

.gp-child-home {
	width: 100%;
	overflow: hidden;
}

.gp-child-home-intro {
	position: relative;
	display: grid;
	align-items: center;
	min-height: min(680px, 75vh);
	padding: clamp(5rem, 10vw, 8.5rem) 0;
	background:
		radial-gradient(circle at 12% 18%, rgba(220, 128, 111, 0.18), transparent 34%),
		radial-gradient(circle at 86% 70%, rgba(239, 207, 181, 0.5), transparent 30%),
		linear-gradient(135deg, #fffaf6 0%, #f7eee6 100%);
}

.gp-child-home-intro::before,
.gp-child-home-intro::after {
	position: absolute;
	border: 1px solid rgba(220, 128, 111, 0.25);
	border-radius: 50%;
	content: "";
	pointer-events: none;
}

.gp-child-home-intro::before {
	top: -100px;
	right: -90px;
	width: 320px;
	height: 320px;
}

.gp-child-home-intro::after {
	bottom: -130px;
	left: -80px;
	width: 280px;
	height: 280px;
}

.gp-child-home-intro__inner {
	position: relative;
	z-index: 1;
	max-width: 920px;
	text-align: center;
}

.gp-child-eyebrow {
	margin: 0 0 1rem;
	color: var(--gp-child-color-accent-dark);
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.14em;
	text-transform: uppercase;
}

.gp-child-home-intro__title {
	max-width: 900px;
	margin: 0 auto 1.5rem;
	font-size: clamp(3rem, 7vw, 6.4rem);
	line-height: 0.98;
}

.gp-child-home-intro__text {
	max-width: 660px;
	margin: 0 auto 2rem;
	color: var(--gp-child-color-muted);
	font-size: clamp(1.05rem, 1.5vw, 1.25rem);
}

.gp-child-home-intro__button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
}

.gp-child-category-section {
	padding: clamp(4.5rem, 8vw, 8rem) 0;
	background: var(--gp-child-color-surface);
}

.gp-child-section-heading {
	max-width: 760px;
	margin: 0 auto clamp(2.5rem, 5vw, 4rem);
	text-align: center;
}

.gp-child-section-heading h2 {
	margin-bottom: 0;
}

.gp-child-category-grid {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: clamp(1rem, 2vw, 1.75rem);
}

.gp-child-category-card {
	min-width: 0;
	margin: 0;
}

.gp-child-category-card__link {
	position: relative;
	display: block;
	overflow: hidden;
	min-height: 510px;
	border-radius: 11rem 11rem 1.25rem 1.25rem;
	background: var(--gp-child-color-surface-soft);
	box-shadow: 0 18px 55px rgba(48, 38, 33, 0.1);
	color: #ffffff;
	text-decoration: none;
	isolation: isolate;
}

.gp-child-category-card__image {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 500ms ease;
}

.gp-child-category-card__shade {
	position: absolute;
	inset: 0;
	z-index: 1;
	background:
		linear-gradient(
			to top,
			rgba(35, 25, 21, 0.9) 0%,
			rgba(35, 25, 21, 0.45) 38%,
			rgba(35, 25, 21, 0.04) 72%
		);
}

.gp-child-category-card__content {
	position: absolute;
	inset: auto 0 0;
	z-index: 2;
	display: flex;
	flex-direction: column;
	align-items: center;
	padding: 2rem 1.4rem 1.75rem;
	text-align: center;
}

.gp-child-category-card__title {
	display: block;
	margin-bottom: 0.6rem;
	font-family: var(--gp-child-font-heading);
	font-size: clamp(1.55rem, 2.2vw, 2.25rem);
	line-height: 1.05;
}

.gp-child-category-card__description {
	display: block;
	max-width: 250px;
	margin-bottom: 1.1rem;
	color: rgba(255, 255, 255, 0.85);
	font-size: 0.92rem;
	line-height: 1.5;
}

.gp-child-category-card__action {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
	padding-bottom: 0.2rem;
	border-bottom: 1px solid rgba(255, 255, 255, 0.72);
	font-size: 0.72rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

.gp-child-category-card__link:hover,
.gp-child-category-card__link:focus-visible {
	color: #ffffff;
}

.gp-child-category-card__link:hover .gp-child-category-card__image,
.gp-child-category-card__link:focus-visible .gp-child-category-card__image {
	transform: scale(1.04);
}

.gp-child-home-editor {
	padding: clamp(3.5rem, 7vw, 6rem) 0;
	background: var(--gp-child-color-background);
}

.gp-child-home-editor__inner {
	max-width: var(--gp-child-reading-width);
}

@media (max-width: 1024px) {
	.gp-child-category-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.gp-child-category-card__link {
		min-height: 560px;
	}
}

@media (max-width: 600px) {
	.gp-child-home-intro {
		min-height: auto;
		padding: 5rem 0;
	}

	.gp-child-home-intro__title {
		font-size: clamp(2.8rem, 15vw, 4.4rem);
	}

	.gp-child-category-grid {
		grid-template-columns: 1fr;
		gap: 1.25rem;
	}

	.gp-child-category-card__link {
		min-height: 490px;
		border-radius: 9rem 9rem 1rem 1rem;
	}
}

@media (prefers-reduced-motion: reduce) {
	.gp-child-category-card__image {
		transition: none;
	}
}


/**
 * Step 4 — Newsletter.
 */

.gp-child-newsletter {
	position: relative;
	padding: clamp(4.5rem, 8vw, 7rem) 0;
	background: var(--gp-child-color-heading);
	color: #ffffff;
}

.gp-child-newsletter::before {
	position: absolute;
	inset: 1.25rem;
	border: 1px solid rgba(255, 255, 255, 0.16);
	border-radius: 1.5rem;
	content: "";
	pointer-events: none;
}

.gp-child-newsletter__inner {
	position: relative;
	z-index: 1;
	display: grid;
	grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
	align-items: center;
	gap: clamp(2.5rem, 6vw, 6rem);
}

.gp-child-newsletter .gp-child-eyebrow {
	color: #f2b6aa;
}

.gp-child-newsletter h2 {
	max-width: 650px;
	margin-bottom: 1.25rem;
	color: #ffffff;
}

.gp-child-newsletter__copy > p:last-child {
	max-width: 620px;
	margin-bottom: 0;
	color: rgba(255, 255, 255, 0.76);
}

.gp-child-newsletter-placeholder {
	display: flex;
	gap: 0.75rem;
	padding: 0.7rem;
	border-radius: 999px;
	background: #ffffff;
}

.gp-child-newsletter-placeholder input {
	flex: 1;
	min-width: 0;
	border: 0;
	background: transparent;
	color: var(--gp-child-color-text);
	box-shadow: none;
}

.gp-child-newsletter-placeholder button {
	flex: 0 0 auto;
	border-radius: 999px;
	opacity: 1;
}

.gp-child-newsletter-placeholder input:disabled,
.gp-child-newsletter-placeholder button:disabled {
	cursor: not-allowed;
}

.gp-child-newsletter__notice {
	margin: 0.85rem 0 0;
	color: rgba(255, 255, 255, 0.58);
	font-size: 0.78rem;
	text-align: center;
}

/**
 * Step 4 — Author section.
 */

.gp-child-author {
	padding: clamp(5rem, 9vw, 8rem) 0;
	background: var(--gp-child-color-background);
}

.gp-child-author__inner {
	display: grid;
	grid-template-columns: minmax(300px, 0.9fr) minmax(0, 1.1fr);
	align-items: center;
	gap: clamp(3rem, 7vw, 7rem);
}

.gp-child-author__media {
	display: flex;
	justify-content: center;
}

.gp-child-author__image-wrap {
	position: relative;
	width: min(100%, 520px);
}

.gp-child-author__image-wrap::before {
	position: absolute;
	top: -1.5rem;
	right: -1.5rem;
	width: 72%;
	height: 72%;
	border-radius: 50% 50% 1.5rem 50%;
	background: var(--gp-child-color-surface-soft);
	content: "";
}

.gp-child-author__image {
	position: relative;
	z-index: 1;
	width: 100%;
	aspect-ratio: 4 / 5;
	border-radius: 48% 48% 1.25rem 1.25rem;
	object-fit: cover;
	box-shadow: 0 24px 60px rgba(48, 38, 33, 0.14);
}

.gp-child-author__badge {
	position: absolute;
	right: -1rem;
	bottom: 2rem;
	z-index: 2;
	display: grid;
	width: 96px;
	height: 96px;
	place-items: center;
	border: 8px solid var(--gp-child-color-background);
	border-radius: 50%;
	background: var(--gp-child-color-accent);
	color: #ffffff;
	font-family: var(--gp-child-font-heading);
	font-size: 2.6rem;
	line-height: 1;
}

.gp-child-author__content {
	max-width: 660px;
}

.gp-child-author__content h2 {
	margin-bottom: 1.25rem;
}

.gp-child-author__name {
	margin-bottom: 0.8rem;
	color: var(--gp-child-color-accent-dark);
	font-family: var(--gp-child-font-heading);
	font-size: clamp(1.35rem, 2vw, 1.8rem);
}

.gp-child-author__bio {
	color: var(--gp-child-color-muted);
}

.gp-child-author__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 1.25rem 1.75rem;
	margin-top: 2rem;
}

.gp-child-author__social {
	display: flex;
	flex-wrap: wrap;
	gap: 1rem;
}

.gp-child-author__social a {
	color: var(--gp-child-color-heading);
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-decoration: none;
	text-transform: uppercase;
}

.gp-child-author__social a:hover,
.gp-child-author__social a:focus-visible {
	color: var(--gp-child-color-accent-dark);
}

@media (max-width: 900px) {
	.gp-child-newsletter__inner,
	.gp-child-author__inner {
		grid-template-columns: 1fr;
	}

	.gp-child-newsletter__copy,
	.gp-child-newsletter__form,
	.gp-child-author__content {
		max-width: 720px;
		margin-right: auto;
		margin-left: auto;
	}

	.gp-child-author__content {
		text-align: center;
	}

	.gp-child-author__actions {
		justify-content: center;
	}
}

@media (max-width: 600px) {
	.gp-child-newsletter::before {
		inset: 0.75rem;
	}

	.gp-child-newsletter-placeholder {
		flex-direction: column;
		border-radius: 1.25rem;
	}

	.gp-child-newsletter-placeholder button {
		width: 100%;
	}

	.gp-child-author__badge {
		right: -0.25rem;
		bottom: 1rem;
		width: 76px;
		height: 76px;
		border-width: 6px;
		font-size: 2rem;
	}
}


/**
 * Step 5.2 — Latest Recipes from every category.
 */

.gp-child-latest-recipes {
	padding: clamp(5rem, 9vw, 8rem) 0;
	background: var(--gp-child-color-surface-soft);
}

.gp-child-latest-recipes__heading {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 2rem;
	margin-bottom: clamp(2.25rem, 5vw, 4rem);
}

.gp-child-latest-recipes__copy {
	max-width: 760px;
}

.gp-child-latest-recipes__copy h2 {
	margin-bottom: 1rem;
}

.gp-child-latest-recipes__copy > p:last-child {
	max-width: 680px;
	margin-bottom: 0;
	color: var(--gp-child-color-muted);
}

.gp-child-text-link {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	gap: 0.6rem;
	padding-bottom: 0.35rem;
	border-bottom: 1px solid currentColor;
	color: var(--gp-child-color-heading);
	font-size: 0.76rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-decoration: none;
	text-transform: uppercase;
}

.gp-child-text-link:hover,
.gp-child-text-link:focus-visible {
	color: var(--gp-child-color-accent-dark);
}

.gp-child-latest-layout {
	display: grid;
	grid-template-columns: minmax(0, 1.08fr) minmax(360px, 0.92fr);
	align-items: stretch;
	gap: clamp(1.25rem, 3vw, 2.25rem);
}

.gp-child-latest-layout__secondary {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	grid-auto-rows: minmax(0, 1fr);
	align-content: stretch;
	height: 100%;
	gap: 1.25rem;
}

.gp-child-recipe-card {
	overflow: hidden;
	margin: 0;
	border: 1px solid var(--gp-child-color-border);
	border-radius: 1.25rem;
	background: var(--gp-child-color-surface);
	box-shadow: 0 16px 42px rgba(48, 38, 33, 0.08);
}

.gp-child-recipe-card__image-link {
	display: block;
	overflow: hidden;
	background: var(--gp-child-color-background);
}

.gp-child-recipe-card__image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 450ms ease;
}

.gp-child-recipe-card__image-link:hover .gp-child-recipe-card__image,
.gp-child-recipe-card__image-link:focus-visible .gp-child-recipe-card__image {
	transform: scale(1.035);
}

.gp-child-recipe-card--featured .gp-child-recipe-card__image-link {
	aspect-ratio: 4 / 3;
}

.gp-child-recipe-card--featured .gp-child-recipe-card__body {
	padding: clamp(1.5rem, 3vw, 2.25rem);
}

.gp-child-recipe-card--featured h3 {
	margin-bottom: 0.8rem;
	font-size: clamp(1.75rem, 3vw, 2.75rem);
}

.gp-child-recipe-card--small .gp-child-recipe-card__image-link {
	aspect-ratio: 4 / 3;
}

.gp-child-recipe-card--small .gp-child-recipe-card__body {
	padding: 1rem 1.1rem 1.2rem;
}

.gp-child-recipe-card--small h3 {
	margin: 0;
	font-size: clamp(1.05rem, 1.5vw, 1.35rem);
}

.gp-child-recipe-card h3 a {
	color: var(--gp-child-color-heading);
	text-decoration: none;
}

.gp-child-recipe-card h3 a:hover,
.gp-child-recipe-card h3 a:focus-visible {
	color: var(--gp-child-color-accent-dark);
}

.gp-child-recipe-card__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 0.45rem 0.9rem;
	margin: 0 0 0.65rem;
	color: var(--gp-child-color-accent-dark);
	font-size: 0.68rem;
	font-weight: 700;
	letter-spacing: 0.09em;
	text-transform: uppercase;
}

.gp-child-recipe-card__meta time {
	color: var(--gp-child-color-muted);
}

.gp-child-recipe-card__excerpt {
	margin-bottom: 0;
	color: var(--gp-child-color-muted);
}

.gp-child-recipe-empty {
	display: grid;
	min-height: 220px;
	place-items: center;
	padding: 2rem;
	border: 1px dashed var(--gp-child-color-border);
	border-radius: 1.25rem;
	background: var(--gp-child-color-surface);
	text-align: center;
}

.gp-child-recipe-empty p {
	max-width: 620px;
	margin: 0;
	color: var(--gp-child-color-muted);
}

.gp-child-latest-recipes__mobile-action {
	display: none;
	margin-top: 2rem;
	text-align: center;
}

@media (max-width: 1024px) {
	.gp-child-latest-layout {
		grid-template-columns: 1fr;
	}

	.gp-child-latest-layout__secondary {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (max-width: 760px) {
	.gp-child-latest-recipes__heading {
		display: block;
		text-align: center;
	}

	.gp-child-latest-recipes__copy {
		margin-right: auto;
		margin-left: auto;
	}

	.gp-child-latest-recipes__heading > .gp-child-text-link {
		display: none;
	}

	.gp-child-latest-layout__secondary {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.gp-child-latest-recipes__mobile-action {
		display: block;
	}
}

@media (max-width: 520px) {
	.gp-child-latest-layout__secondary {
		grid-template-columns: 1fr;
	}

	.gp-child-recipe-card--featured h3 {
		font-size: 1.75rem;
	}
}

@media (prefers-reduced-motion: reduce) {
	.gp-child-recipe-card__image {
		transition: none;
	}
}


/**
 * Step 6.1 — Equal-height Latest Recipes columns.
 */

.gp-child-recipe-card--featured,
.gp-child-recipe-card--small {
	display: flex;
	height: 100%;
	flex-direction: column;
}

.gp-child-recipe-card--featured .gp-child-recipe-card__body,
.gp-child-recipe-card--small .gp-child-recipe-card__body {
	display: flex;
	flex: 1;
	flex-direction: column;
}

.gp-child-recipe-card--featured .gp-child-recipe-card__excerpt {
	display: -webkit-box;
	overflow: hidden;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 3;
}

@media (max-width: 1024px) {
	.gp-child-latest-layout__secondary {
		height: auto;
	}
}
