/**
 * Shop page — premium reference styling (BEM)
 * Only loaded from woocommerce/archive-product.php
 */

body.nls-is-shop {
	background: #ffffff;
}

.shop-page {
	--shop-navy: #0d1f3c;
	--shop-bg: #ffffff;
	--shop-image-bg: #ffffff;
	--shop-image-bg-hover: #f5f5f5;
	--shop-grid-line: #e2e0dc;
	--shop-badge-salmon: #f5c4bc;
	--shop-badge-salmon-text: #6b2c25;
	--shop-badge-blue: #c2d8ee;
	--shop-badge-blue-text: #1e3d58;
	--shop-font-logo: "Cormorant Garamond", serif;
	--shop-font-ui: "DM Sans", sans-serif;
	font-family: var(--shop-font-ui);
	color: var(--shop-navy);
	background: var(--shop-bg);
}

/* ── Hero ── */
.shop-hero {
	position: relative;
	min-height: 650px;
	overflow: hidden;
	background-color: var(--shop-navy);
	background-image: var(--shop-hero-image);
	background-size: cover;
	background-position: center right;
	background-repeat: no-repeat;
	margin-top: calc(-1 * var(--nls-shop-header-pull, 5rem));
	margin-top: -95px;
}

body.nls-is-shop:has(.nls-announcement-bar) .shop-hero {
	margin-top: calc(-1 * var(--nls-shop-header-pull, 7.5rem));
}

.shop-hero::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
	background: linear-gradient(
		to right,
		rgba(13, 31, 60, 0.55) 0%,
		rgba(13, 31, 60, 0.1) 60%,
		transparent 100%
	);
	pointer-events: none;
}

.shop-hero__title {
	position: absolute;
	z-index: 2;
	bottom: 40px;
	left: 60px;
	margin: 0;
	font-family: var(--shop-font-logo);
	font-size: 58px;
	font-weight: 300;
	line-height: 1.05;
	color: #ffffff;
	letter-spacing: 0.02em;
}

/* ── Filter pills ── */
.shop-filters {
	background: #ffffff;
	padding: 16px 0;
	border-bottom: 1px solid #e8e6e2;
}

.shop-filters__track {
	display: flex;
	flex-wrap: nowrap;
	gap: 0.5rem;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
	justify-content: center;
	max-width: 1440px;
	margin: 0 auto;
	padding: 0 clamp(1rem, 3vw, 2rem);
}

.shop-filters__track::-webkit-scrollbar {
	display: none;
}

.shop-filters__pill {
	flex: 0 0 auto;
	appearance: none;
	border: 1.5px solid var(--shop-navy);
	border-radius: 50px;
	background: #ffffff;
	color: var(--shop-navy);
	padding: 8px 20px;
	font-family: var(--shop-font-ui);
	font-size: 13px;
	letter-spacing: 0.04em;
	line-height: 1;
	cursor: pointer;
	transition: all 0.25s ease;
}

.shop-filters__pill:hover:not(.is-active):not([data-active="true"]),
.shop-filters__pill:focus-visible:not(.is-active):not([data-active="true"]) {
	background: #f5f5f5;
}

.shop-filters__pill.is-active,
.shop-filters__pill[data-active="true"] {
	background: var(--shop-navy);
	color: #ffffff;
}

/* ── Product grid ── */
.shop-grid {
	background: var(--shop-bg);
	padding: 0 0 3rem;
}

.shop-grid__inner {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 0;
	max-width: 1440px;
	margin: 0 auto;
	padding: 0;
	border-top: 1px solid var(--shop-grid-line);
	border-left: 1px solid var(--shop-grid-line);
}

.shop-grid__empty {
	text-align: center;
	padding: 3rem 1.5rem;
	color: rgba(13, 31, 60, 0.55);
}

/* ── Product card ── */
.product-card {
	background: var(--shop-bg);
	padding: 0;
	display: flex;
	flex-direction: column;
	border: 0;
	border-right: 1px solid var(--shop-grid-line);
	border-bottom: 1px solid var(--shop-grid-line);
	border-radius: 0;
	box-shadow: none;
	opacity: 0;
	transform: translateY(20px);
	transition: opacity 0.5s ease, transform 0.5s ease;
}

.product-card.is-revealed {
	opacity: 1;
	transform: translateY(0);
}

.product-card.is-filter-fade {
	transform: translateY(0);
	transition: opacity 0.3s ease;
}

.product-card.is-hidden {
	display: none !important;
}

.product-card__media {
	position: relative;
	height: clamp(360px, 28vw, 440px);
	background: var(--shop-image-bg);
	display: flex;
	align-items: center;
	justify-content: center;
	transition: background 0.4s ease;
}

.product-card:hover .product-card__media,
.product-card:focus-within .product-card__media {
	background: var(--shop-image-bg-hover);
}

.product-card__badge {
	position: absolute;
	top: 14px;
	left: 14px;
	z-index: 2;
	border-radius: 20px;
	padding: 4px 12px;
	font-family: var(--shop-font-ui);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.06em;
	line-height: 1.2;
	text-transform: capitalize;
}

.product-card__badge--best_seller {
	background: var(--shop-badge-salmon);
	color: var(--shop-badge-salmon-text);
}

.product-card__badge--award_winning,
.product-card__badge--new_arrival {
	background: var(--shop-badge-blue);
	color: var(--shop-badge-blue-text);
}

.product-card__image-link {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	padding: 12px 16px;
	box-sizing: border-box;
}

.product-card__image {
	width: 100% !important;
	max-width: 100%;
	max-height: 100%;
	height: auto !important;
	min-height: 75%;
	object-fit: contain;
	transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.product-card:hover .product-card__image,
.product-card:focus-within .product-card__image {
	transform: scale(1.04);
}

.product-card__quick-add {
	position: absolute;
	right: 14px;
	bottom: 14px;
	z-index: 3;
	width: 36px;
	height: 36px;
	border-radius: 50%;
	background: #ffffff;
	border: 1px solid rgba(13, 31, 60, 0.2);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: var(--shop-navy);
	font-size: 18px;
	line-height: 1;
	text-decoration: none;
	opacity: 0;
	transform: translateY(6px);
	pointer-events: none;
	transition: opacity 0.3s ease, transform 0.3s ease;
}

.product-card:hover .product-card__quick-add,
.product-card:focus-within .product-card__quick-add {
	opacity: 1;
	transform: translateY(0);
	pointer-events: auto;
}

.product-card__quick-add:hover,
.product-card__quick-add:focus-visible {
	transform: translateY(0) scale(1.05);
}

.product-card__title {
	margin: 0;
	padding: 14px 16px 0;
	font-family: var(--shop-font-logo);
	font-size: 16px;
	font-weight: 500;
	line-height: 1.35;
	color: var(--shop-navy);
	letter-spacing: 0.01em;
	text-transform: none;
}

.product-card__title a {
	color: var(--shop-navy) !important;
	text-decoration: none !important;
}

.product-card__title a:hover,
.product-card__title a:focus-visible {
	color: var(--shop-navy) !important;
	text-decoration: none !important;
}

.product-card__price {
	margin: 4px 0 0;
	padding: 0 16px 20px;
	font-family: var(--shop-font-ui);
	font-size: 14px;
	color: #555555;
}

.product-card__price .woocommerce-Price-amount {
	font-weight: 400;
}

/* ── Responsive ── */
@media (max-width: 1024px) {
	.shop-grid__inner {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.shop-filters__track {
		justify-content: flex-start;
	}

	.shop-hero__title {
		left: clamp(1.5rem, 4vw, 2.5rem);
		font-size: clamp(2.5rem, 8vw, 58px);
	}
}

@media (max-width: 600px) {
	.shop-hero {
		min-height: 360px;
	}

	.shop-hero__title {
		bottom: 28px;
		font-size: 42px;
	}

	.shop-grid__inner {
		grid-template-columns: 1fr;
	}

	.product-card__media {
		height: 340px;
	}

	.product-card__image-link {
		padding: 10px 12px;
	}
}
