/**
 * Product Filter — flex-only responsive styles.
 * Grid: 1 col <600, 2 col >=600, 3 col >=768, 4 col >=1024.
 */
.pfs-results,
.pf-wrap {
	--pf-gap: 20px;
	--pf-accent: #ffe000;       /* highlight (yellow) */
	--pf-accent-ink: #1a1a1a;
	--pf-border: #e4e7ec;
	--pf-card-border: #cfd6ff;
	--pf-radius: 12px;
	--pf-ink: #1f2937;
	--pf-muted: #6b7280;
	--pf-sidebar-w: 240px;
	box-sizing: border-box;
	position: relative;
	color: var(--pf-ink);
}
.pf-wrap *,
.pf-wrap *::before,
.pf-wrap *::after {
	box-sizing: border-box;
}

/* ---------- Search (above the container) ---------- */
.pf-search {
	display: flex;
	margin-bottom: var(--pf-gap);
}
.pf-search__input {
	flex: 1 1 auto;
	max-width: 420px;
	padding: 12px 16px;
	border: 1px solid var(--pf-border);
	border-radius: var(--pf-radius);
	font-size: 15px;
	background: #f7f8fa;
	outline: none;
}
.pf-search__input:focus {
	border-color: var(--pf-accent);
	background: #fff;
	box-shadow: 0 0 0 3px rgba(255, 224, 0, 0.25);
}

/* ---------- Container (sidebar + main) — flex + wrap ---------- */
.pf-container {
	display: flex;
	flex-wrap: wrap;
	gap: var(--pf-gap);
	align-items: flex-start;
}

/* ---------- Sidebar ---------- */
.pf-sidebar {
	flex: 0 0 var(--pf-sidebar-w);
	max-width: var(--pf-sidebar-w);
	border: 1px solid var(--pf-border);
	border-radius: var(--pf-radius);
	padding: 18px;
	background: #fff;
}
.pf-sidebar__title {
	margin: 0 0 12px;
	font-size: 20px;
	font-weight: 700;
}
.pf-cats {
	display: flex;
	flex-direction: column;
}
.pf-cat {
	display: block;
	padding: 8px 10px;
	border-radius: 6px;
	color: var(--pf-ink);
	text-decoration: none;
	font-size: 15px;
	line-height: 1.3;
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease;
}
.pf-cat:hover {
	background: #f3f4f6;
}
.pf-cat.is-active {
	background: var(--pf-accent);
	color: var(--pf-accent-ink);
	font-weight: 600;
}
.pf-cat.is-hidden {  /* hidden by search filter */
	display: none;
}

/* ---------- Main (products) ---------- */
.pf-main {
	flex: 1 1 320px;
	min-width: 0; /* prevent flex overflow */
}

/* ---------- Products grid — flex + wrap only ---------- */
.pf-products {
	display: flex;
	flex-wrap: wrap;
	gap: 20px;
	align-items: stretch;
}

/* Mobile-first: 1 column (<600px) */
.pf-card {
	flex: 0 1 100%;
	max-width: 100%;
	display: flex;
	flex-direction: column;
	border: 1px solid var(--pf-card-border);
	border-radius: var(--pf-radius);
	padding: 18px;
	background: #fff;
	box-shadow: 0 6px 16px rgba(17, 24, 39, 0.06);
	min-height: 200px;
	max-width: 300px !important;
}

/* >=600px → 2 columns */
@media (min-width: 600px) {
	.pf-card {
		flex-basis: calc((100% - var(--pf-gap)) / 2);
		max-width: calc((100% - var(--pf-gap)) / 2);
	}
}

/* >=768px → 3 columns */
@media (min-width: 768px) {
	.pf-card {
		flex-basis: calc((100% - (2 * var(--pf-gap))) / 3);
		max-width: calc((100% - (2 * var(--pf-gap))) / 3);
	}
}

/* >=1024px → 4 columns */
@media (min-width: 1024px) {
	.pf-card {
		flex-basis: calc((100% - (2 * var(--pf-gap))) / 3);
		max-width: calc((100% - (2 * var(--pf-gap))) / 3);
	}
}

/* Sidebar becomes full width on small screens (flex-wrap handles stacking) */
@media (max-width: 768px) {
	.pf-sidebar {
		flex-basis: 100%;
		max-width: 100%;
	}
}

/* ---------- Card internals ---------- */
.pf-card__link {
	display: flex;
	flex-direction: column;
	gap: 12px;
	text-decoration: none;
	color: inherit;
	flex: 1 1 auto;
}
.pf-card__thumb {
	display: flex;
	justify-content: center;
	align-items: center;
}
.pf-card__thumb img {
	max-width: 100%;
	height: auto;
	border-radius: 8px;
	display: block;
}
.pf-card__title {
	margin: 0;
	font-size: 18px !important;
	font-weight: 700 !important;
	line-height: 1.35 !important;
}
.pf-card__price {
	margin-top: 8px;
	color: var(--pf-muted);
	font-weight: 600;
}
.pf-card__cart {
	margin-top: 12px;
	display: flex;
	justify-content: center;
}
.pf-card__cart .button,
.pf-card__cart .added_to_cart {
	background: #ffce00;
	background-color: #ffce00 !important;
	color: var(--pf-accent-ink) !important;
	border: none;
	border-radius: 8px;
	padding: 8px 16px;
	font-weight: 600;
	text-decoration: none;
	cursor: pointer;
}

.pf-empty {
	flex: 1 1 100%;
	padding: 40px 0;
	text-align: center;
	color: var(--pf-muted);
}

/* ---------- Controls ---------- */
.pf-pagination-wrap,
.pf-loadmore-wrap {
	display: flex;
	justify-content: center;
	margin-top: 24px;
}
.pf-pagination {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
}
.pf-page {
	border: 1px solid var(--pf-border);
	background: #fff;
	border-radius: 8px;
	padding: 8px 14px;
	font-size: 14px;
	cursor: pointer;
	color: var(--pf-ink);
}
.pf-page:hover {
	background: #f3f4f6;
}
.pf-page.is-active {
	background: var(--pf-accent);
	border-color: var(--pf-accent);
	font-weight: 700;
}
.pf-dots {
	padding: 0 4px;
	color: var(--pf-muted);
}
.pf-loadmore {
	background: var(--pf-accent);
	color: var(--pf-accent-ink);
	border: none;
	border-radius: 8px;
	padding: 12px 28px;
	font-weight: 700;
	font-size: 15px;
	cursor: pointer;
}
.pf-sentinel {
	height: 1px;
	width: 100%;
}

/* ---------- Loading overlay ---------- */
.pf-overlay {
	display: none;
	position: absolute;
	inset: 0;
	background: rgba(255, 255, 255, 0.55);
	justify-content: center;
	align-items: flex-start;
	padding-top: 80px;
	z-index: 5;
	border-radius: var(--pf-radius);
}
.pf-wrap.is-loading .pf-overlay {
	display: flex;
}
.pf-spinner {
	width: 34px;
	height: 34px;
	border: 3px solid var(--pf-border);
	border-top-color: var(--pf-accent);
	border-radius: 50%;
	animation: pf-spin 0.7s linear infinite;
}
@keyframes pf-spin {
	to { transform: rotate(360deg); }
}



/* Smooth hover lift + scale for product cards */
.pf-card {
	transition: transform 0.28s ease, box-shadow 0.28s ease, border-color 0.28s ease;
	will-change: transform;
}
.pf-card:hover {
	transform: translateY(-6px) scale(1.03);
	box-shadow: 0 18px 34px rgba(17, 24, 39, 0.16);
	border-color: var(--pf-accent);
	z-index: 2;
}

/* Subtle image zoom inside the card on hover */
.pf-card__thumb {
	overflow: hidden;
	border-radius: 8px;
}
.pf-card__thumb img {
	transition: transform 0.35s ease;
}
.pf-card:hover .pf-card__thumb img {
	transform: scale(1.08);
}

/* Respect users who prefer less motion */
@media (prefers-reduced-motion: reduce) {
	.pf-card,
	.pf-card__thumb img {
		transition: none;
	}
	.pf-card:hover {
		transform: none;
	}
}

/* Action row: add-to-cart + WhatsApp */
.pf-card__actions {
	margin-top: 12px;
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
}
.pf-card__actions .pf-card__cart { margin-top: 0; flex: 1 1 auto; }
.pf-wa {
	flex: 0 0 auto;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	border-radius: 50%;
	background: #25d366;
	color: #fff !important;
	text-decoration: none;
	transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}
.pf-wa:hover {background: #1ebe57;transform: translateY(-2px);box-shadow: 0 8px 18px rgba(37,211,102,.35);color: #fff !important;transform: scale(1.25) !important;}
.pf-wa:active {transform: scale(.95);}
.pf-wa svg { display: block; }

