/*
 * Products archive, product-category archives, and product singles.
 */

.myco-products-container {
	width: min(100%, 1600px);
	max-width: none;
	margin-inline: auto;
}

/* ---------- Breadcrumb ---------- */

.myco-products-archive__breadcrumb {
	background: var(--myco-color-surface-breadcrumb, var(--myco-color-surface-strong));
}

.myco-products-archive__breadcrumb .myco-products-container {
	padding-inline: 20px;
}

.myco-products-archive__breadcrumb .breadcrumbs {
	justify-content: flex-start;
	gap: 0;
	margin: 0;
	color: var(--myco-color-muted);
	font-family: var(--myco-font-sans);
	font-size: 14px;
	font-weight: 400;
	line-height: 30px;
}

.myco-products-archive__breadcrumb .breadcrumbs__link {
	color: var(--myco-color-muted);
}

.myco-products-archive__breadcrumb .breadcrumbs__current {
	color: var(--myco-color-primary);
}

.myco-products-archive__breadcrumb .breadcrumbs__separator {
	margin-inline: 5px;
	font-size: 13px;
}

/* ---------- Copy-free archive hero ---------- */

.myco-products-hero {
	position: relative;
	width: min(100%, 1600px);
	overflow: hidden;
	margin-inline: auto;
	background: var(--myco-color-heading);
	aspect-ratio: 7 / 3;
}

.myco-products-hero__video,
.myco-products-hero__poster,
.myco-products-hero__fallback {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
}

.myco-products-hero__fallback {
	background: var(--myco-color-surface-dark);
}

/* ---------- Dynamic category cards ---------- */

.myco-product-categories {
	padding: 50px 0 80px;
	background: var(--myco-color-surface);
}

.myco-product-categories__heading {
	margin: 0 0 32px;
	font-family: var(--myco-font-sans);
	font-size: 35px;
	font-weight: 400;
	line-height: 1;
	text-align: center;
}

.myco-product-categories__grid {
	display: grid;
	gap: 40px 30px;
	margin: 0;
	padding: 0;
	list-style: none;
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.myco-product-category-card {
	min-width: 0;
	padding: 20px;
	background: var(--myco-color-white);
	box-shadow: var(--myco-shadow-product-card, var(--myco-shadow-card));
	transition: box-shadow 300ms ease;
}

.myco-product-category-card:hover,
.myco-product-category-card:focus-within {
	box-shadow: var(--myco-shadow-product-card-hover, var(--myco-shadow-card));
}

.myco-product-category-card__link {
	display: flex;
	height: 100%;
	flex-direction: column;
	color: var(--myco-color-heading);
	text-decoration: none;
}

.myco-product-category-card__link:focus-visible {
	outline: 2px solid var(--myco-color-primary);
	outline-offset: 6px;
}

.myco-product-category-card__media {
	position: relative;
	overflow: hidden;
	margin: -20px -20px 28px;
	background: var(--myco-color-surface-strong);
}

.myco-product-category-card__poster {
	position: relative;
	display: block;
	width: 100%;
	height: auto;
	object-fit: cover;
	object-position: center;
}

.myco-product-category-card__video {
	position: absolute;
	inset: 0;
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
	opacity: 0;
	transition: opacity 160ms ease;
}

.myco-product-category-card.is-video-playing .myco-product-category-card__video {
	opacity: 1;
}

.myco-product-category-card__video:only-child {
	position: relative;
	min-height: 187px;
}

.myco-product-category-card__video-data {
	display: none;
}

.myco-product-category-card__title {
	margin: 0 0 16px;
	font-family: var(--myco-font-sans);
	font-size: 28px;
	font-weight: 400;
	line-height: 1.2;
}

.myco-product-category-card__description {
	margin-bottom: 32px;
	color: var(--myco-color-heading);
	font-family: var(--myco-font-sans);
	font-size: 18px;
	font-weight: 400;
	line-height: 30px;
}

.myco-product-category-card__description p {
	margin: 0;
}

.myco-product-category-card__detail,
.myco-products-button,
.myco-product-card__detail {
	display: inline-flex;
	min-height: 0;
	align-items: center;
	justify-content: center;
	align-self: flex-start;
	margin-top: auto;
	padding: 20px 32px;
	border: 1px solid var(--myco-color-primary);
	border-radius: 0;
	background: var(--myco-color-primary);
	color: var(--myco-color-white);
	font-family: var(--myco-font-sans);
	font-size: 16px;
	font-weight: 400;
	letter-spacing: 0.8px;
	line-height: 1;
	text-transform: none;
	transition: background var(--myco-transition), color var(--myco-transition), border-color var(--myco-transition);
}

.myco-product-category-card__link:hover .myco-product-category-card__detail,
.myco-product-category-card__link:focus-visible .myco-product-category-card__detail,
.myco-product-card__link:hover .myco-product-card__detail,
.myco-product-card__link:focus-visible .myco-product-card__detail {
	border-color: var(--myco-color-primary);
	background: var(--myco-color-white);
	color: var(--myco-color-primary);
}

/* ---------- Products production principles ---------- */

.myco-products-principles {
	padding: 40px 0 80px;
	background: var(--myco-color-surface);
}

.myco-products-principles__heading {
	margin: 0 0 32px;
	font-family: var(--myco-font-sans);
	font-size: 35px;
	font-weight: 400;
	line-height: 1;
	text-align: center;
}

.myco-products-principles__grid {
	display: grid;
	gap: 30px;
	grid-template-columns: repeat(3, minmax(0, 1fr));
}

.myco-products-principles__card {
	padding: 125px 55px;
	background: var(--myco-color-white);
}

.myco-products-principles__card h3 {
	margin: 0 0 16px;
	font-family: var(--myco-font-sans);
	font-size: 28px;
	font-weight: 300;
	line-height: 1.35;
}

.myco-products-principles__card p {
	margin: 0;
	color: var(--myco-color-muted);
	font-family: var(--myco-font-sans);
	font-size: 18px;
	font-weight: 400;
	line-height: 30px;
}

/* ---------- Contact CTA ---------- */

.myco-products-cta {
	background: var(--myco-color-primary-soft);
}

.myco-products-cta__inner {
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 28px;
	padding-top: 50px;
	padding-bottom: 50px;
	text-align: center;
}

.myco-products-cta h2 {
	margin: 0;
	color: var(--myco-color-white);
	font-family: var(--myco-font-sans);
	font-size: 36px;
	font-weight: 600;
	line-height: 1.2;
}

.myco-products-button {
	min-height: 0;
	align-self: center;
	cursor: pointer;
}

.myco-products-button--light {
	border-color: var(--myco-color-white);
	background: transparent;
	color: var(--myco-color-white);
}

.myco-products-button--light:hover,
.myco-products-button--light:focus-visible {
	border-color: var(--myco-color-white);
	background: var(--myco-color-white);
	color: var(--myco-color-primary);
}

/* ---------- Taxonomy and product detail ---------- */

.myco-product-page-header {
	padding: var(--myco-space-3xl) 20px;
	background: var(--myco-color-surface);
}

.myco-product-page-header h1 {
	margin: var(--myco-space-md) 0 0;
	font-size: clamp(2rem, 5vw, 4.5rem);
	font-weight: 300;
}

.myco-product-page-header__description,
.myco-product-entry__lead {
	max-width: 70ch;
	margin: var(--myco-space-lg) 0 0;
	font-size: var(--myco-font-size-base);
	line-height: 1.75;
}

.myco-product-page-header__description p {
	margin: 0;
}

.myco-product-listing,
.myco-product-entry__body {
	padding: var(--myco-space-3xl) 20px var(--myco-space-4xl);
}

.myco-product-grid {
	display: grid;
	gap: var(--myco-space-xl);
	grid-template-columns: 1fr;
}

.myco-product-card {
	overflow: hidden;
	background: var(--myco-color-white);
	box-shadow: var(--myco-shadow-card);
}

.myco-product-card__link {
	display: block;
	height: 100%;
	color: var(--myco-color-text);
	text-decoration: none;
}

.myco-product-card__image {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	object-fit: cover;
}

.myco-product-card__body {
	display: flex;
	min-height: 14rem;
	flex-direction: column;
	padding: var(--myco-space-xl);
}

.myco-product-card__title {
	margin: 0 0 var(--myco-space-sm);
	font-size: var(--myco-font-size-xl);
	font-weight: 400;
}

.myco-product-card__excerpt {
	margin: 0 0 var(--myco-space-lg);
	line-height: 1.65;
}

.myco-product-entry__media {
	margin: 0 0 var(--myco-space-2xl);
}

.myco-product-entry__image {
	display: block;
	width: 100%;
	height: auto;
}

.myco-product-entry__content {
	max-width: 52rem;
}

@media (max-width: 1024px) {
	.myco-product-categories {
		padding: 30px 20px 0;
	}

	.myco-product-categories__heading {
		margin-bottom: 28px;
		font-size: 26px;
	}

	.myco-product-categories__grid {
		grid-template-columns: 1fr;
	}

	.myco-product-category-card__media {
		height: 255px;
	}

	.myco-product-category-card__poster {
		height: 100%;
	}

	.myco-product-category-card__title {
		font-size: 20px;
	}

	.myco-product-category-card__description {
		font-size: 16px;
		line-height: 1.4;
	}

	.myco-product-category-card__detail,
	.myco-products-button,
	.myco-product-card__detail {
		padding: 15px 30px;
		font-size: 13px;
	}

	.myco-products-principles {
		padding: 30px 20px 60px;
	}

	.myco-products-principles__heading {
		font-size: 22px;
	}

	.myco-products-principles__grid {
		gap: 32px;
		grid-template-columns: 1fr;
	}

	.myco-products-principles__card {
		padding: 40px;
	}

	.myco-products-principles__card h3 {
		font-size: 20px;
	}

	.myco-products-principles__card p {
		font-size: 16px;
		line-height: 1.6;
	}

	.myco-products-cta h2 {
		font-size: 22px;
	}

	.myco-product-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 767px) {
	.myco-products-archive__breadcrumb .breadcrumbs {
		font-size: 12px;
		line-height: 30px;
	}

	.myco-products-archive__breadcrumb .breadcrumbs__separator {
		font-size: 12px;
	}

	.myco-product-categories {
		padding-right: 16px;
		padding-left: 16px;
	}

	.myco-product-category-card__media {
		height: 140px;
	}

	.myco-products-principles {
		padding: 40px 16px 80px;
	}

	.myco-products-principles__heading {
		margin-bottom: 24px;
	}

	.myco-products-principles__grid {
		gap: 20px;
	}

	.myco-products-principles__card {
		padding: 50px;
	}

	.myco-products-cta__inner {
		padding-right: 16px;
		padding-left: 16px;
	}

	.myco-product-grid {
		grid-template-columns: 1fr;
	}
}

@media (min-width: 1025px) {
	.myco-product-categories,
	.myco-products-principles {
		padding-right: 20px;
		padding-left: 20px;
	}

	.myco-product-category-card__media {
		height: 187px;
	}

	.myco-product-category-card__poster {
		height: 100%;
	}

	.myco-product-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

@media (prefers-reduced-motion: reduce) {
	.myco-product-category-card,
	.myco-product-category-card__video {
		transition: none;
	}
}
