/* ==========================================================================
   Chafery – shop / category archive
   ========================================================================== */

.chafery-shop,
.chafery-shop #wrapper,
.chafery-shop #main { background: #fff; }
.chafery-shop { --cf-sale: #d93a3a; --cf-green: #2e9d5b; --cf-gray: #ececec; }

/* Hero */
.cf-shop-hero {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 240px;
	padding: 40px 16px;
	background-color: #3a2a26;
	background-position: center;
	background-size: cover;
	text-align: center;
	color: #fff;
}
.cf-shop-hero::before {
	content: "";
	position: absolute;
	inset: 0;
	background: rgba(20, 12, 10, .55);
}
.cf-shop-hero__inner { position: relative; max-width: 760px; }
.cf-shop-hero h1 {
	margin: 0 0 8px;
	color: #fff;
	font-family: "Jost", sans-serif;
	font-size: 34px;
	font-weight: 600;
	letter-spacing: .04em;
	text-transform: uppercase;
}
.cf-shop-hero__crumbs { font-size: 11px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; }
.cf-shop-hero__crumbs a { color: #fff; opacity: .85; }
.cf-shop-hero__crumbs a:hover { opacity: 1; color: #fff; }
.cf-shop-hero .cf-sep { margin: 0 8px; }
.cf-shop-hero__desc { margin-top: 14px; font-size: 13px; line-height: 1.6; color: rgba(255, 255, 255, .9); }
.cf-shop-hero__desc p { margin: 0; }

/* Layout */
.cf-shop {
	display: grid;
	grid-template-columns: 260px minmax(0, 1fr);
	gap: 28px;
	max-width: 1240px;
	margin: 0 auto;
	padding: 32px 20px 40px;
	box-sizing: border-box;
}
.cf-shop__main .shop-container,
.cf-shop__main .woocommerce-notices-wrapper { padding: 0; }
.cf-shop__overlay, .cf-shop__sidebar-head { display: none; }

/* Sidebar */
.cf-shop__sidebar {
	align-self: start;
	border: 1px solid var(--cf-gray);
	background: #fff;
	font-size: 12px;
}
.cf-filter { margin: 0; padding: 16px 18px; border-bottom: 1px solid var(--cf-gray); }
.cf-filter:last-child { border-bottom: 0; }
.cf-filter > summary {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin: 0 0 12px;
	font-size: 13px;
	font-weight: 500;
	color: #222;
	cursor: pointer;
	list-style: none;
}
.cf-filter > summary::-webkit-details-marker { display: none; }
.cf-filter > summary::after { content: "\2013"; font-size: 16px; font-weight: 300; }
.cf-filter:not([open]) > summary { margin-bottom: 0; }
.cf-filter:not([open]) > summary::after { content: "+"; }

.cf-search { display: flex; margin: 0; }
.cf-search input[type=search] {
	flex: 1;
	height: 36px;
	margin: 0;
	border: 1px solid var(--cf-gray);
	border-right: 0;
	box-shadow: none;
	font-size: 12px;
}
.cf-search button,
.cf-quickbar button {
	height: 36px;
	min-height: 0;
	margin: 0;
	padding: 0 14px;
	border: 0;
	background: #111;
	color: #fff;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: .06em;
	line-height: 36px;
	text-transform: uppercase;
}

.cf-check {
	position: relative;
	display: flex;
	align-items: center;
	gap: 9px;
	margin: 0 0 9px;
	color: #444;
	font-size: 12px;
	font-weight: 400;
	cursor: pointer;
}
.cf-check input { position: absolute; opacity: 0; pointer-events: none; }
.cf-check__box {
	flex: none;
	width: 13px;
	height: 13px;
	border: 1px solid #b9b9b9;
	border-radius: 2px;
	background: #fff;
}
.cf-check.is-checked .cf-check__box,
.cf-check input:checked + .cf-check__box {
	border-color: #111;
	background: #111 url("data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 24 24%22 fill=%22none%22 stroke=%22white%22 stroke-width=%224%22%3E%3Cpath d=%22m5 12 5 5 9-10%22/%3E%3C/svg%3E") center / 9px no-repeat;
}
.cf-check:hover { color: #000; }
a.cf-check.is-checked { color: #000; font-weight: 500; }
.cf-filter__clear { font-size: 11px; color: var(--cf-sale); text-decoration: underline; }

.cf-cat-tree { margin: 0; padding: 0; list-style: none; }
.cf-cat-tree li { position: relative; margin: 0; }
.cf-cat-tree .cf-cat-tree { display: none; margin-left: 14px; }
.cf-cat-tree li.is-open > .cf-cat-tree { display: block; }
.cf-cat-tree__toggle {
	position: absolute;
	top: -3px;
	right: 0;
	width: 20px;
	height: 20px;
	min-height: 0;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	color: #777;
	font-size: 15px;
	line-height: 20px;
}
.cf-cat-tree__toggle::before { content: "+"; }
.cf-cat-tree li.is-open > .cf-cat-tree__toggle::before { content: "\2013"; }

.cf-price__slider { position: relative; height: 22px; margin: 4px 4px 12px; }
.cf-price__track { position: absolute; top: 10px; left: 0; right: 0; height: 2px; background: #ddd; }
.cf-price__range { position: absolute; top: 0; bottom: 0; background: #111; }
.cf-price__slider input[type=range] {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 22px;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	box-shadow: none;
	pointer-events: none;
	-webkit-appearance: none;
	appearance: none;
}
.cf-price__slider input[type=range]::-webkit-slider-thumb {
	width: 4px;
	height: 14px;
	border: 0;
	border-radius: 0;
	background: #111;
	pointer-events: auto;
	cursor: pointer;
	-webkit-appearance: none;
}
.cf-price__slider input[type=range]::-moz-range-thumb {
	width: 4px;
	height: 14px;
	border: 0;
	border-radius: 0;
	background: #111;
	pointer-events: auto;
	cursor: pointer;
}
.cf-price__slider input[type=range]::-moz-range-track { background: none; }
.cf-price__foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 11px; color: #555; }
.cf-btn-outline {
	height: 26px;
	min-height: 0;
	margin: 0;
	padding: 0 12px;
	border: 1px solid #111;
	background: #fff;
	color: #111;
	font-size: 10px;
	font-weight: 600;
	letter-spacing: .08em;
	line-height: 24px;
	text-transform: uppercase;
}
.cf-btn-outline:hover { background: #111; color: #fff; }

.cf-count-list { margin: 0; padding: 0; list-style: none; }
.cf-count-list li { display: flex; justify-content: space-between; margin: 0 0 8px; color: #444; }
.cf-count-list a { color: #444; }
.cf-count-list li.is-current a, .cf-count-list a:hover { color: #000; font-weight: 500; }
.cf-count-list span { color: #888; }

.cf-select {
	width: 100%;
	height: 34px;
	margin: 0;
	padding: 0 10px;
	border: 1px solid var(--cf-gray);
	background-color: #fff;
	box-shadow: none;
	font-size: 12px;
	color: #555;
}

/* Quick filter bar */
.cf-quickbar {
	display: flex;
	gap: 10px;
	margin: 0 0 22px;
	padding: 10px;
	border: 1px solid var(--cf-gray);
}
.cf-quickbar .cf-select { flex: 1; }
.cf-quickbar button { flex: 0 0 45%; background: #8f8f8f; }
.cf-quickbar button:hover { background: #111; }

/* Toolbar */
.cf-toolbar {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 10px 16px;
	margin-bottom: 14px;
	font-size: 11px;
	color: #666;
}
.cf-toolbar .woocommerce-result-count { margin: 0; font-size: 11px; color: #666; }
.cf-toolbar__right { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.cf-toolbar__show a { margin-left: 8px; color: #888; }
.cf-toolbar__show a.is-active, .cf-toolbar__show a:hover { color: #000; font-weight: 600; }
.cf-toolbar__views { display: flex; align-items: center; gap: 8px; }
.cf-view {
	display: inline-flex;
	gap: 1px;
	align-items: stretch;
	width: auto;
	height: 14px;
	min-height: 0;
	margin: 0;
	padding: 0;
	border: 0;
	background: none;
	opacity: .35;
	cursor: pointer;
}
.cf-view i { display: block; width: 3px; background: #111; }
.cf-view--list { flex-direction: column; justify-content: space-between; width: 14px; }
.cf-view--list i { width: auto; height: 2px; box-shadow: 0 6px 0 #111, 0 12px 0 #111; }
.cf-view--2 i { width: 6px; }
.cf-view--3 i { width: 4px; }
.cf-view.is-active, .cf-view:hover { opacity: 1; }
.cf-toolbar .woocommerce-ordering { margin: 0; }
.cf-toolbar .woocommerce-ordering select {
	height: 28px;
	margin: 0;
	padding: 0 22px 0 4px;
	border: 0;
	background-color: transparent;
	box-shadow: none;
	font-size: 11px;
	color: #444;
}
.cf-toolbar__search, .cf-toolbar__filters {
	height: 28px;
	min-height: 0;
	margin: 0;
	padding: 0 4px;
	border: 0;
	background: none;
	color: #111;
	line-height: 1;
}
.cf-toolbar__filters { display: none; align-items: center; gap: 6px; font-size: 12px; font-weight: 500; text-transform: none; letter-spacing: 0; }
.cf-active-filters { margin: -4px 0 14px; font-size: 12px; }
.cf-active-filters a { color: var(--cf-sale); }

/* List view */
.cf-list-view .product-small.col { flex-basis: 100% !important; max-width: 100% !important; }
.cf-list-view .product-small.box { display: flex; align-items: center; }
.cf-list-view .product-small .box-image { flex: 0 0 200px; }
.cf-list-view .product-small .box-text { padding: 16px 20px; }
.cf-list-view .product-small .product-title a { font-size: 15px; }

/* Pagination */
.chafery-shop .woocommerce-pagination .page-numbers li > * {
	border: 1px solid var(--cf-gray);
	border-radius: 0;
	color: #333;
	font-size: 12px;
}
.chafery-shop .woocommerce-pagination .page-numbers li > .current { background: #111; border-color: #111; color: #fff; }

@media (max-width: 849px) {
	.cf-shop { grid-template-columns: 1fr; padding: 20px 12px 32px; gap: 0; }
	.cf-shop-hero { min-height: 180px; padding: 30px 16px; }
	.cf-shop-hero h1 { font-size: 26px; }
	.cf-shop-hero__desc { font-size: 12px; }

	.cf-shop__sidebar {
		position: fixed;
		top: 0;
		bottom: 0;
		left: 0;
		z-index: 100001;
		width: min(320px, 86vw);
		overflow-y: auto;
		border: 0;
		transform: translateX(-100%);
		transition: transform .3s;
	}
	.cf-shop.filters-open .cf-shop__sidebar { transform: none; }
	.cf-shop__sidebar-head {
		display: flex;
		justify-content: space-between;
		align-items: center;
		padding: 14px 18px;
		border-bottom: 1px solid var(--cf-gray);
		font-size: 14px;
	}
	.cf-shop__sidebar-head button { margin: 0; min-height: 0; padding: 0 4px; border: 0; background: none; font-size: 26px; line-height: 1; }
	.cf-shop.filters-open .cf-shop__overlay { display: block; position: fixed; inset: 0; z-index: 100000; background: rgba(0, 0, 0, .45); }

	.cf-toolbar__filters { display: inline-flex; border: 1px solid var(--cf-gray); padding: 0 10px; }
	.cf-toolbar__views, .cf-toolbar__show, .cf-toolbar__search { display: none; }
	.cf-toolbar .woocommerce-result-count { order: 3; width: 100%; }
	.cf-quickbar { margin-bottom: 14px; }
	.cf-list-view .product-small .box-image { flex-basis: 120px; }
}
