/**
 * Modern WooCommerce product category archive layout.
 */

.sac-product-category-modern-page {
	background: var(--acg-bg);
	color: var(--acg-dark);
}

.sac-product-category-modern-page #ac-main-content {
	overflow: hidden;
}

.sac-product-cat-hero {
	padding: 154px 24px 78px;
	background:
		radial-gradient(circle at 18% 18%, rgba(232, 168, 124, 0.22), transparent 28rem),
		radial-gradient(circle at 84% 14%, rgba(26, 95, 95, 0.26), transparent 28rem),
		linear-gradient(135deg, #2d2926 0%, #3d3936 100%);
	color: #fff;
}

.sac-product-cat-container,
.sac-product-cat-hero__inner {
	width: min(1180px, 92vw);
	margin: 0 auto;
}

.sac-product-cat-eyebrow {
	margin: 0 0 16px;
	color: var(--acg-peach);
	font-size: 0.8125rem;
	font-weight: 700;
	letter-spacing: 0.2em;
	text-transform: uppercase;
}

.sac-product-cat-hero h1 {
	max-width: 900px;
	margin: 0;
	font-family: var(--acg-font-heading);
	font-size: clamp(2.85rem, 7vw, 6.5rem);
	font-weight: 300;
	line-height: 0.98;
	letter-spacing: -0.05em;
}

.sac-product-cat-hero h1 strong {
	color: var(--acg-peach);
	font-weight: 700;
}

.sac-product-cat-hero__lead {
	max-width: 780px;
	margin: 26px 0 0;
	color: rgba(255, 255, 255, 0.76);
	font-size: clamp(1.125rem, 2vw, 1.38rem);
	line-height: 1.62;
}

.sac-product-cat-hero__lead p {
	margin: 0 0 1em;
}

.sac-product-cat-hero__lead p:last-child {
	margin-bottom: 0;
}

.sac-product-cat-breadcrumbs {
	margin: 30px 0 0;
	color: rgba(255, 255, 255, 0.68);
	font-weight: 700;
}

.sac-product-cat-breadcrumbs a {
	color: #fff;
	text-decoration: none;
}

.sac-product-cat-breadcrumbs a:hover {
	color: var(--acg-peach);
}

.sac-product-cat-intro {
	background: #fff;
	padding: 58px 0;
}

.sac-product-cat-description {
	max-width: 920px;
	color: var(--acg-muted);
	font-size: 1.1rem;
	line-height: 1.76;
}

.sac-product-cat-description p {
	margin: 0 0 18px;
}

.sac-product-cat-description p:last-child {
	margin-bottom: 0;
}

.sac-product-cat-section {
	padding: 70px 0 94px;
}

.sac-product-cat-section--white {
	background: #fff;
}

.sac-product-cat-section__head {
	display: flex;
	justify-content: space-between;
	align-items: end;
	gap: 24px;
	margin-bottom: 32px;
}

.sac-product-cat-section__head h2 {
	margin: 0;
	font-size: clamp(2.1rem, 4vw, 3.9rem);
	font-weight: 300;
	line-height: 1.05;
	letter-spacing: -0.035em;
}

.sac-product-cat-section__head h2 strong {
	color: var(--acg-accent);
	font-weight: 700;
}

.sac-product-cat-count {
	margin: 0;
	color: var(--acg-muted);
	font-weight: 800;
}

.sac-product-subcats {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 22px;
}

.sac-product-subcat {
	display: flex;
	min-height: 100%;
	border: 1px solid var(--acg-border);
	border-radius: 26px;
	background: #fff;
	box-shadow: 0 14px 34px rgba(45, 41, 38, 0.07);
	overflow: hidden;
	text-decoration: none;
	transition: transform var(--acg-duration) var(--acg-ease), box-shadow var(--acg-duration) var(--acg-ease);
}

.sac-product-subcat:hover {
	transform: translateY(-4px);
	box-shadow: 0 24px 56px rgba(45, 41, 38, 0.14);
	text-decoration: none;
}

.sac-product-subcat__media {
	flex: 0 0 36%;
	background: #eee7dc;
	min-height: 170px;
}

.sac-product-subcat__media img {
	width: 100%;
	height: 100%;
	display: block;
	object-fit: cover;
}

.sac-product-subcat__body {
	padding: 24px;
}

.sac-product-subcat h3 {
	margin: 0 0 10px;
	color: var(--acg-dark);
	font-size: 1.55rem;
	line-height: 1.1;
}

.sac-product-subcat p {
	margin: 0;
	color: var(--acg-muted);
	line-height: 1.6;
}

.sac-product-cat-products {
	position: relative;
}

.sac-product-category-modern-page .woocommerce-result-count {
	margin: -10px 0 26px;
	color: var(--acg-muted);
	font-weight: 800;
}

.sac-product-category-modern-page .woocommerce-notices-wrapper {
	width: min(1180px, 92vw);
	margin: 0 auto;
}

.sac-product-category-modern-page .products.sac-category-products,
.sac-product-category-modern-page .products.sac-category-products.facetwp-template,
.sac-product-category-modern-page .woocommerce .products.sac-category-products {
	display: grid !important;
	width: 100%;
	max-width: none;
	grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
	gap: 26px;
	margin: 0 !important;
	padding: 0;
}

.sac-product-category-modern-page .products.sac-category-products::before,
.sac-product-category-modern-page .products.sac-category-products::after {
	display: none !important;
}

.sac-product-category-modern-page .products.sac-category-products > .product,
.sac-product-category-modern-page .woocommerce .products.sac-category-products > .product {
	width: auto !important;
	max-width: none !important;
	flex: initial !important;
	flex-basis: auto !important;
	float: none !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 1px solid var(--acg-border);
	border-radius: 30px;
	background: #fff;
	box-shadow: 0 18px 44px rgba(45, 41, 38, 0.08);
	overflow: hidden;
	position: relative;
	display: flex;
	flex-direction: column;
	min-height: 100%;
	transition: transform var(--acg-duration) var(--acg-ease), box-shadow var(--acg-duration) var(--acg-ease), border-color var(--acg-duration) var(--acg-ease);
}

.sac-product-category-modern-page .products.sac-category-products > .product::before {
	content: "";
	position: absolute;
	inset: 0 0 auto;
	z-index: 2;
	height: 5px;
	background: linear-gradient(90deg, var(--acg-accent), var(--acg-peach));
	opacity: 0;
	transition: opacity var(--acg-duration) var(--acg-ease);
}

.sac-product-category-modern-page .products.sac-category-products > .product:hover {
	border-color: rgba(210, 96, 62, 0.22);
	transform: translateY(-6px);
	box-shadow: 0 28px 66px rgba(45, 41, 38, 0.15);
}

.sac-product-category-modern-page .products.sac-category-products > .product:hover::before {
	opacity: 1;
}

.sac-product-category-modern-page .products.sac-category-products > .product a {
	text-decoration: none;
}

.sac-product-category-modern-page .products.sac-category-products > .product .woocommerce-LoopProduct-link {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	color: inherit;
}

.sac-product-category-modern-page .products.sac-category-products > .product img {
	width: 100%;
	aspect-ratio: 16 / 10;
	height: auto !important;
	display: block;
	object-fit: cover;
	margin: 0;
	background: #eee7dc;
	border-bottom: 1px solid rgba(45, 41, 38, 0.08);
	transition: transform 0.7s var(--acg-ease), filter 0.7s var(--acg-ease);
}

.sac-product-category-modern-page .products.sac-category-products > .product:hover img {
	filter: saturate(1.05) contrast(1.03);
	transform: scale(1.035);
}

.sac-product-category-modern-page .products.sac-category-products > .product .sold-out {
	position: absolute;
	top: 18px;
	left: 18px;
	z-index: 3;
	border: 1px solid rgba(255, 255, 255, 0.28);
	border-radius: 999px;
	background: rgba(45, 41, 38, 0.82);
	box-shadow: 0 12px 30px rgba(0, 0, 0, 0.22);
	color: #fff;
	font-size: 0.72rem;
	font-weight: 900;
	letter-spacing: 0.14em;
	padding: 8px 12px;
	text-transform: uppercase;
}

.sac-product-category-modern-page .products.sac-category-products > .product h2,
.sac-product-category-modern-page .products.sac-category-products > .product h3,
.sac-product-category-modern-page .products.sac-category-products > .product .woocommerce-loop-product__title {
	margin: 0;
	padding: 26px 28px 12px;
	color: var(--acg-dark);
	font-family: var(--acg-font-heading);
	font-size: clamp(1.45rem, 2.4vw, 2.15rem);
	font-weight: 700;
	line-height: 1.08;
	letter-spacing: -0.035em;
}

.sac-product-category-modern-page .products.sac-category-products > .product .instructor,
.sac-product-category-modern-page .products.sac-category-products > .product .product_date,
.sac-product-category-modern-page .products.sac-category-products > .product .price {
	display: block;
	padding: 0 28px;
	color: var(--acg-muted);
	font-size: 1rem;
	line-height: 1.45;
}

.sac-product-category-modern-page .products.sac-category-products > .product .instructor {
	color: var(--acg-accent);
	font-weight: 900;
}

.sac-product-category-modern-page .products.sac-category-products > .product .instructor::before {
	content: "Instructor";
	display: block;
	margin-bottom: 3px;
	color: var(--acg-muted);
	font-size: 0.68rem;
	font-weight: 900;
	letter-spacing: 0.16em;
	text-transform: uppercase;
}

.sac-product-category-modern-page .products.sac-category-products > .product .product_date {
	margin-top: 10px;
	padding-top: 12px;
	border-top: 1px solid rgba(45, 41, 38, 0.1);
	color: var(--acg-dark);
	font-weight: 800;
	min-height: auto;
	height: auto;
}

.sac-product-category-modern-page .products.sac-category-products > .product .price {
	margin-top: 10px;
	color: var(--acg-teal);
	font-weight: 800;
}

.sac-product-category-modern-page .products.sac-category-products > .product .addtocartbutton,
.sac-product-category-modern-page .products.sac-category-products > .product .button {
	position: static !important;
	left: auto !important;
	right: auto !important;
	bottom: auto !important;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: calc(100% - 56px);
	margin: 26px 28px 28px !important;
	border-radius: 999px;
	background: var(--acg-accent);
	border: 0;
	color: #fff;
	font-weight: 800;
	padding: 14px 22px;
	box-shadow: 0 10px 24px rgba(210, 96, 62, 0.22);
	transition: background var(--acg-duration) var(--acg-ease), transform var(--acg-duration) var(--acg-ease), box-shadow var(--acg-duration) var(--acg-ease);
}

.sac-product-category-modern-page .products.sac-category-products > .product .addtocartbutton:hover,
.sac-product-category-modern-page .products.sac-category-products > .product .button:hover {
	background: var(--acg-accent-hover);
	color: #fff;
	transform: translateY(-1px);
	box-shadow: 0 14px 30px rgba(210, 96, 62, 0.3);
}

.sac-product-category-modern-page .sac-product-cat-products > hr {
	display: none;
}

.sac-product-category-modern-page .woocommerce-pagination,
.sac-product-category-modern-page .pagination {
	display: flex;
	align-items: center;
	justify-content: center;
	margin-top: 42px;
	width: 100%;
}

/* Undo legacy Bootstrap pagination wrapper from pagination.php */
.sac-product-category-modern-page .pagination .row {
	width: 100%;
	margin: 0;
}

.sac-product-category-modern-page .pagination [class*="col-"] {
	flex: none;
	width: 100%;
	max-width: 100%;
	margin: 0;
	padding: 0;
}

/* FacetWP pager — override legacy .pagination .facetwp-pager theme styles */
.sac-product-category-modern-page .facetwp-pager {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 8px;
}

.sac-product-category-modern-page .facetwp-pager .facetwp-pager-label,
.sac-product-category-modern-page .facetwp-pager .facetwp-page {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 42px;
	height: 42px;
	padding: 0 14px;
	margin: 0 !important;
	border: 0;
	border-radius: 999px;
	background: #fff !important;
	color: var(--acg-dark) !important;
	font-size: 1rem !important;
	font-weight: 700 !important;
	flex: none !important;
	white-space: nowrap;
	text-align: center;
	text-decoration: none;
	box-shadow: 0 8px 24px rgba(45, 41, 38, 0.08);
	cursor: pointer;
	transition: background var(--acg-duration) var(--acg-ease), color var(--acg-duration) var(--acg-ease), box-shadow var(--acg-duration) var(--acg-ease);
}

.sac-product-category-modern-page .facetwp-pager .facetwp-page.active,
.sac-product-category-modern-page .facetwp-pager .facetwp-page:hover:not(.dots) {
	background: var(--acg-accent) !important;
	color: #fff !important;
	box-shadow: 0 10px 24px rgba(210, 96, 62, 0.22);
}

.sac-product-category-modern-page .facetwp-pager .facetwp-page.dots {
	background: transparent !important;
	box-shadow: none;
	color: var(--acg-muted) !important;
	cursor: default;
	min-width: auto;
	padding: 0 6px;
}

.sac-product-category-modern-page .facetwp-pager .facetwp-pager-label {
	background: transparent !important;
	box-shadow: none;
	color: var(--acg-muted) !important;
	font-weight: 600 !important;
	min-width: auto;
	height: auto;
	padding: 0 8px 0 0;
}

.sac-product-cat-empty {
	border: 1px solid var(--acg-border);
	border-radius: 24px;
	background: #fff;
	color: var(--acg-muted);
	padding: 32px;
	text-align: center;
}

@media (max-width: 1040px) {
	.sac-product-subcats,
	.sac-product-category-modern-page .products.sac-category-products {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (max-width: 720px) {
	.sac-product-cat-hero {
		padding-top: 128px;
	}

	.sac-product-cat-section__head {
		display: block;
	}

	.sac-product-cat-count {
		margin-top: 12px;
	}

	.sac-product-subcats,
	.sac-product-category-modern-page .products.sac-category-products {
		grid-template-columns: 1fr;
	}

	.sac-product-subcat {
		display: block;
	}
}
