/**
 * Products catalog — 2026 redesign (17-product-catalog-desktop.pdf).
 * Product cards share HP category teaser logic: 485×620, full-box bg, hover zoom + text reveal.
 */

#products .regular_box_title {
	display: none;
}

#products.section {
	padding: 0;
	background: transparent;
}

.spiro-products {
	--spiro-product-ratio: 485 / 620;
	--spiro-product-bg-fallback: #e8e8e8;
	--spiro-product-radius: 22px;
	--spiro-product-pad: 40px;
	--spiro-product-hover-lift: 40px;
	padding: clamp(32px, 4vw, 56px) var(--spiro-gutter, 50px) clamp(48px, 6vw, 80px);
	background: var(--spiro-color-bg, #f6f6f6);
	/* Contain title/filter come-right entrance (PDF 56) */
	overflow-x: clip;
}

.spiro-products__inner {
	width: 100%;
	max-width: var(--spiro-content-max, 1630px);
	margin: 0 auto;
}

.spiro-products__title {
	margin: 0 0 clamp(24px, 3vw, 40px);
	color: var(--spiro-color-ink, #000);
	font-family: var(--spiro-font-family, "Outfit", Arial, sans-serif);
	/* PDF 17: PRODUCTS 88 ExtraBold @ 1920 (same band as services overview) */
	font-size: var(--spiro-type-hero-services);
	font-weight: var(--spiro-font-weight-extrabold, 800);
	line-height: 1.05;
	letter-spacing: 0.01em;
	text-transform: uppercase;
}

.spiro-products__filters {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: clamp(16px, 2.5vw, 40px);
	margin: 0 0 clamp(28px, 4vw, 48px);
}

.spiro-products__filter {
	border: 0;
	padding: 0;
	background: transparent;
	color: var(--spiro-color-ink, #000);
	font-family: var(--spiro-font-family, "Outfit", Arial, sans-serif);
	font-size: 18px;
	font-weight: var(--spiro-font-weight-bold, 700);
	line-height: 1.35;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	cursor: pointer;
	transition: color 0.2s ease;
}

.spiro-products__filter:hover,
.spiro-products__filter:focus-visible {
	color: var(--spiro-color-blue, #007ec1);
	outline: none;
}

.spiro-products__filter.is-active {
	color: var(--spiro-color-blue, #007ec1);
}

.spiro-products__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: clamp(16px, 1.8vw, 24px);
}

.spiro-products__card {
	min-width: 0;
}

.spiro-products__card.is-hidden {
	display: none;
}

.spiro-products__card-link {
	display: block;
	position: relative;
	width: 100%;
	aspect-ratio: var(--spiro-product-ratio);
	border-radius: var(--spiro-product-radius);
	background-color: var(--spiro-product-bg-fallback);
	color: inherit;
	text-decoration: none;
	overflow: hidden;
	isolation: isolate;
}

/* Plate (thumb_bg) + product photo — slide up together on hover.
   Plate is taller than the card so translateY does not reveal the gray fallback. */
.spiro-products__card-media {
	position: absolute;
	inset: 0;
	z-index: 0;
	overflow: visible;
	transform: translateY(0);
	transition: transform var(--spiro-hover-duration, 0.55s) var(--spiro-hover-ease, cubic-bezier(0.22, 1, 0.36, 1));
	pointer-events: none;
}

.spiro-products__card-link:hover .spiro-products__card-media,
.spiro-products__card-link:focus-visible .spiro-products__card-media {
	transform: translateY(calc(-1 * var(--spiro-product-hover-lift)));
}

/* Shared plate behind every card — extends below card by the hover lift amount */
.spiro-products__card-bg {
	position: absolute;
	top: 0;
	right: 0;
	left: 0;
	bottom: calc(-1 * var(--spiro-product-hover-lift));
	z-index: 0;
	background-color: var(--spiro-product-bg-fallback);
	background-image: var(--spiro-product-plate-bg, none);
	background-repeat: no-repeat;
	background-size: cover;
	background-position: top center;
}

/* Product image — centered + contain (max-* fallback for older browsers) */
.spiro-products__card-photo {
	/* position: absolute;
	inset: 0;
	z-index: 1;
	display: block;
	width: auto;
	height: auto;
	max-width: 160%;
	max-height: 100%;
	transform: translateX(-20%);
	margin: auto;
	object-fit: contain;
	object-position: center;
	filter: drop-shadow(2px 5px 5px #afafaf); */
	
	position: absolute;
    inset: 0;
    z-index: 1;
    display: block;
    width: 104%;
   
    margin: auto;
    object-fit: cover;
    object-position: top center;
   
    margin: 0;
    border: 0;
	transform: translateX(-10px);
}

.spiro-products__card-content {
	position: absolute;
	left: var(--spiro-product-pad);
	right: var(--spiro-product-pad);
	bottom: var(--spiro-product-pad);
	z-index: 2;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	align-items: flex-start;
	max-height: calc(100% - (var(--spiro-product-pad) * 2));
}

.spiro-products__card-track {
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	align-items: flex-start;
	width: 100%;
	min-width: 0;
}

.spiro-products__card-categ {
	margin: 0;
	color: var(--spiro-color-blue, #007ec1);
	font-family: var(--spiro-font-family, "Outfit", Arial, sans-serif);
	/* font-size: 18px; */
	font-size: var(--spiro-type-card-title-lg);
	font-weight: var(--spiro-font-weight-bold, 700);
	line-height: 1.2;
	letter-spacing: 0.06em;
	text-transform: uppercase;
}

.spiro-products__card-name {
	margin: 0;
	padding: 0;
	color: var(--spiro-color-ink, #000);
	font-family: var(--spiro-font-family, "Outfit", Arial, sans-serif);
	/* PDF 17: card names 28 ExtraBold @ 1920 */
	font-size: var(--spiro-type-card-title-lg);
	font-weight: var(--spiro-font-weight-extrabold, 800);
	line-height: 1.15;
	letter-spacing: 0.01em;
	text-transform: uppercase;
}

.spiro-products__card-desc {
	display: block;
	width: 100%;
	margin: 0;
	max-height: 0;
	opacity: 0;
	overflow: hidden;
	color: var(--spiro-color-ink, #000);
	font-family: var(--spiro-font-family, "Outfit", Arial, sans-serif);
	font-size: 15px;
	font-weight: var(--spiro-font-weight-medium, 500);
	line-height: 1.1;
	transition: max-height 0.55s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.45s ease, margin-top 0.45s ease;
}

.spiro-products__card-arrow {
	display: block;
	max-height: 0;
	margin: 0;
	opacity: 0;
	overflow: hidden;
	line-height: 1;
	transition: max-height 0.45s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.4s ease 0.04s, margin-top 0.45s ease;
}

.spiro-products__card-arrow::before {
	/* content: "→"; */
	content: url(../images/black_arrow-s.svg);
	display: block;
	font-family: var(--spiro-font-family, "Outfit", Arial, sans-serif);
	font-size: 20px;
	font-weight: var(--spiro-font-weight-regular, 400);
	line-height: 1;
	color: #000;
	width: 28px;
    height: 28px;
}

.spiro-products__card-link:hover .spiro-products__card-desc,
.spiro-products__card-link:focus-visible .spiro-products__card-desc {
	margin-top: 12px;
	max-height: 10.5em;
	opacity: 1;
}

.spiro-products__card-link:hover .spiro-products__card-arrow,
.spiro-products__card-link:focus-visible .spiro-products__card-arrow {
	max-height: 24px;
	margin-top: 20px;
	opacity: 1;
}

@media (max-width: 1200px) {
	.spiro-products {
		--spiro-product-pad: clamp(24px, 3vw, 40px);
	}
}

@media (max-width: 1100px) {
	.spiro-products__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 700px) {
	.spiro-products {
		padding-left: var(--spiro-gutter, 35px);
		padding-right: var(--spiro-gutter, 35px);
	}

	.spiro-products__grid {
		grid-template-columns: 1fr;
		max-width: 485px;
		margin-left: auto;
		margin-right: auto;
	}

	.spiro-products__filter {
		font-size: 18px;
		line-height: 1.4;
	}

	.spiro-products__card-categ {
		font-size: 18px;
		line-height: 1.2;
	}

	.spiro-products__card-name {
		font-size: 16px;
		line-height: 1.15;
	}

	.spiro-products__card-desc {
		font-size: 14px;
		max-height: none;
		margin-top: 12px;
		opacity: 1;
	}

	.spiro-products__card-arrow {
		max-height: 24px;
		margin-top: 18px;
		opacity: 1;
	}

	.spiro-products__card-link:hover .spiro-products__card-media,
	.spiro-products__card-link:focus-visible .spiro-products__card-media {
		transform: translateY(0);
	}
}

/* Mobile: photo above text (no overlay) */
/* @media (max-width: 575px) { */
@media (max-width: 175px) {
	
	.spiro-products {
		--spiro-product-pad: 20px;
	}

	.spiro-products__card-link {
		display: flex;
		flex-direction: column;
		aspect-ratio: auto;
		height: auto;
		min-height: 0;
		/* Full-card plate — thumb_bg on the card only */
		background-color: var(--spiro-product-bg-fallback);
		background-image: var(--spiro-product-plate-bg, none);
		background-repeat: no-repeat;
		background-size: cover;
		background-position: top center;
	}

	.spiro-products__card-media {
		position: relative;
		inset: auto;
		flex: 0 0 auto;
		width: 100%;
		aspect-ratio: 4 / 3;
		min-height: 200px;
		overflow: hidden;
		background: transparent;
	}

	/* Plate lives on the card — hide the dedicated bg layer */
	.spiro-products__card-bg {
		display: none;
	}

	.spiro-products__card-content {
		position: relative;
		left: auto;
		right: auto;
		bottom: auto;
		z-index: 1;
		flex: 1 1 auto;
		max-height: none;
		padding: var(--spiro-product-pad);
		justify-content: flex-start;
		background: transparent;
	}

	.spiro-products__card-track {
		justify-content: flex-start;
	}

	.spiro-products__card-name {
		font-size: clamp(18px, 5.5vw, 22px);
	}
}

/* ≤920px: fluid page + card titles so they fit the column/card */
@media (max-width: 920px) {
	.spiro-products__title {
		font-size: clamp(32px, 7vw, 56px);
	}

	.spiro-products__card-name {
		font-size: clamp(15px, 3.5vw, 20px);
		line-height: 1.15;
		overflow-wrap: anywhere;
	}

	.spiro-products__card-categ {
		font-size: clamp(14px, 2.8vw, 16px);
	}
}

@media (prefers-reduced-motion: reduce) {
	.spiro-products__card-media,
	.spiro-products__card-desc,
	.spiro-products__card-arrow {
		transition: none !important;
	}

	.spiro-products__card-media {
		transform: translateY(0);
	}

	.spiro-products__card-desc {
		max-height: none;
		opacity: 1;
		margin-top: 12px;
	}

	.spiro-products__card-arrow {
		max-height: 24px;
		margin-top: 18px;
		opacity: 1;
	}
}
