/* Reviewed presentation adapters selected by Runlo Frontend Editor.
 * Catalogue, prices, media IDs and transactions remain WooCommerce-owned. */
:root {
	--bm-motion-ease: cubic-bezier(.16, 1, .3, 1);
	--bm-motion-fast: 420ms;
	--bm-motion-slow: 900ms;
}

@view-transition {
	navigation: auto;
}

@supports (view-transition-name: none) {
	html.storefront-motion-scan::view-transition-old(root) {
		animation: bm-storefront-page-out 180ms var(--bm-motion-ease) both;
	}

	html.storefront-motion-scan::view-transition-new(root) {
		animation: bm-storefront-page-in 260ms var(--bm-motion-ease) both;
	}

	html.storefront-motion-azure-v6::view-transition-old(root) {
		animation: bm-azure-page-out 150ms ease-in both;
	}

	html.storefront-motion-azure-v6::view-transition-new(root) {
		animation: bm-azure-page-in 380ms var(--bm-motion-ease) both;
	}
}

body.storefront-product-images--clean .product-card__image,
body.storefront-product-images--clean .product-card__image img,
body.storefront-product-images--clean .category-card__image,
body.storefront-product-images--clean .category-card__image img,
body.storefront-product-images--clean .woocommerce-product-gallery__image,
body.storefront-product-images--clean .woocommerce-product-gallery__image img {
	background: transparent !important;
	mix-blend-mode: normal !important;
}

body.storefront-product-images--tinted .product-card__image,
body.storefront-product-images--tinted .category-card__image,
body.storefront-product-images--tinted .woocommerce-product-gallery__image {
	background: #e5dfd5 !important;
}

body.storefront-product-images--tinted .product-card__image img,
body.storefront-product-images--tinted .category-card__image img,
body.storefront-product-images--tinted .woocommerce-product-gallery__image img {
	mix-blend-mode: multiply !important;
}

.storefront-motion-ready .hero__copy > *,
.storefront-motion-ready .hero__campaign,
.storefront-motion-ready [data-storefront-reveal] {
	opacity: 0;
	transform: translate3d(0, 24px, 0);
}

.storefront-motion-ready .hero__campaign {
	transform: scale(1.035);
}

.storefront-motion-ready.storefront-motion-loaded .hero__campaign {
	opacity: 1;
	transform: scale(1);
	transition: opacity 1s var(--bm-motion-ease), transform 1.5s var(--bm-motion-ease);
}

.storefront-motion-ready.storefront-motion-loaded .hero__copy > * {
	opacity: 1;
	transform: none;
	transition: opacity .72s var(--bm-motion-ease), transform .82s var(--bm-motion-ease);
}

.storefront-motion-ready.storefront-motion-loaded .hero__copy > :nth-child(1) { transition-delay: 100ms; }
.storefront-motion-ready.storefront-motion-loaded .hero__copy > :nth-child(2) { transition-delay: 180ms; }
.storefront-motion-ready.storefront-motion-loaded .hero__copy > :nth-child(3) { transition-delay: 260ms; }
.storefront-motion-ready.storefront-motion-loaded .hero__copy > :nth-child(4) { transition-delay: 340ms; }
.storefront-motion-ready.storefront-motion-loaded .hero__copy > :nth-child(5) { transition-delay: 420ms; }

.storefront-motion-ready [data-storefront-reveal].is-visible {
	opacity: 1;
	transform: none;
	transition: opacity .68s var(--bm-motion-ease), transform .82s var(--bm-motion-ease);
}

/* Azure V6 motion applied to the existing V1 hero markup. The content and
 * layout stay V1; only its authored entrance and reveal timing are switched. */
html.storefront-motion-azure-v6 .storefront-motion-ready .hero__campaign {
	opacity: 1;
	clip-path: inset(0 100% 0 0);
	transform: scale(1.04);
}

html.storefront-motion-azure-v6 .storefront-motion-ready.storefront-motion-loaded .hero__campaign {
	clip-path: inset(0);
	transform: scale(1);
	transition: clip-path 760ms 90ms var(--bm-motion-ease), transform 900ms 90ms var(--bm-motion-ease);
}

html.storefront-motion-azure-v6 .storefront-motion-ready .hero__copy > * {
	transform: translate3d(0, 13px, 0);
}

html.storefront-motion-azure-v6 .storefront-motion-ready.storefront-motion-loaded .hero__copy > * {
	transition-duration: 460ms, 460ms;
	transition-timing-function: var(--bm-motion-ease), var(--bm-motion-ease);
}

html.storefront-motion-azure-v6 .storefront-motion-ready [data-storefront-reveal].is-visible {
	transition-duration: 620ms, 620ms;
	transition-timing-function: var(--bm-motion-ease), var(--bm-motion-ease);
}

@keyframes bm-storefront-page-out {
	from {
		opacity: 1;
		transform: translate3d(0, 0, 0);
	}
	to {
		opacity: .84;
		transform: translate3d(0, -6px, 0);
	}
}

@keyframes bm-storefront-page-in {
	from {
		opacity: .72;
		transform: translate3d(0, 10px, 0);
	}
	to {
		opacity: 1;
		transform: translate3d(0, 0, 0);
	}
}

@keyframes bm-azure-page-out {
	to {
		opacity: 0;
		filter: blur(2px);
	}
}

@keyframes bm-azure-page-in {
	from {
		opacity: 0;
		clip-path: inset(0 0 6% 0);
	}
}

.storefront-preset--bad-mafia-v6 .hero::after {
	content: "";
	position: absolute;
	inset: 0 auto 0 50%;
	width: 1px;
	background: linear-gradient(transparent, #ed1c2e 22%, #ed1c2e 78%, transparent);
	transform: scaleY(0);
	transform-origin: top;
	pointer-events: none;
	z-index: 3;
}

.storefront-motion-loaded.storefront-preset--bad-mafia-v6 .hero::after {
	transform: scaleY(1);
	transition: transform 1.1s .2s var(--bm-motion-ease);
}

@media (max-width: 760px) {
	.storefront-preset--bad-mafia-v6 .hero::after { left: 20px; }
	.storefront-motion-ready .hero__copy > * { transform: translate3d(0, 14px, 0); }
	body.woocommerce-shop .shop-page.bad-mafia-catalogue-page .product-card__footer,
	body.tax-product_cat .shop-page.bad-mafia-catalogue-page .product-card__footer {
		min-height: 3.75rem;
		padding-block: .48rem;
		align-items: flex-start;
		flex-direction: column;
		justify-content: space-between;
		gap: .4rem;
	}
	body.woocommerce-shop .shop-page.bad-mafia-catalogue-page .product-card__stock,
	body.tax-product_cat .shop-page.bad-mafia-catalogue-page .product-card__stock {
		width: 100%;
		white-space: normal;
	}
	body.woocommerce-shop .shop-page.bad-mafia-catalogue-page .product-card__action,
	body.tax-product_cat .shop-page.bad-mafia-catalogue-page .product-card__action {
		width: 100%;
		justify-content: flex-end;
		white-space: nowrap;
	}
}

@media (prefers-reduced-motion: reduce) {
	.storefront-motion-ready .hero__copy > *,
	.storefront-motion-ready .hero__campaign,
	.storefront-motion-ready [data-storefront-reveal] {
		opacity: 1 !important;
		transform: none !important;
		transition: none !important;
	}
	.hero::after { display: none !important; }
}
