/* ==========================================================================
   10 — Shop archive: hero, category chips, filters, toolbar
   ========================================================================== */

.shop-hero { position: relative; padding: clamp(20px, 4vw, 40px) 0; margin-bottom: 12px; }
.shop-hero__in { width: calc(100% - var(--gutter) * 2); max-width: calc(var(--container) - var(--gutter) * 2); display: grid; gap: 20px; align-items: center; padding: clamp(22px, 4vw, 40px); border-radius: var(--r-xl); background: var(--white); border: 1px solid var(--line); overflow: hidden; position: relative; }
.shop-hero__in::before { content: ""; position: absolute; inset: 0; background: url("../img/pattern.svg") 0 0/120px; opacity: .5; pointer-events: none; }
.shop-hero__text { position: relative; }
.shop-hero__desc { margin-top: 10px; color: var(--ink-2); font-size: var(--fs-sm); line-height: 2; max-width: 640px; }
.shop-hero__desc.is-clamped { max-height: 7.4em; overflow: hidden; mask-image: linear-gradient(#000 55%, transparent); -webkit-mask-image: linear-gradient(#000 55%, transparent); }
.shop-hero__more { margin-top: 6px; font-size: var(--fs-sm); }
.shop-hero__media { position: relative; display: none; }
.shop-hero__media img { width: 220px; height: 220px; object-fit: cover; border-radius: 50% 50% var(--r-lg) var(--r-lg); margin-inline-start: auto; }
.shop-hero__art { width: 180px; height: 180px; margin-inline-start: auto; display: grid; place-items: center; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #F6DFA0, var(--gold-soft) 70%); color: var(--green); }
.shop-hero__art .ico { width: 84px; height: 84px; stroke-width: 1.1; }
.shop-hero--dates .shop-hero__art { color: var(--date); }
.shop-hero--syrup .shop-hero__art, .shop-hero--sesame .shop-hero__art { color: var(--brown); }
@media (min-width: 768px) { .shop-hero__in { grid-template-columns: 1fr auto; } .shop-hero__media { display: block; } }

.shop-cats { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 0 calc(var(--gutter) * -1) 18px; padding: 2px var(--gutter); }
.shop-cats::-webkit-scrollbar { display: none; }
.shop-cats .chip { flex-shrink: 0; }
.shop-cats .chip small { color: var(--muted); font-weight: 500; }

.shop { display: grid; gap: 24px; align-items: start; }
.shop__main { min-width: 0; }
@media (min-width: 1024px) { .shop { grid-template-columns: 270px minmax(0, 1fr); gap: 32px; } }

/* ---------- Toolbar ---------- */
.shop-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-bottom: 16px; }
.shop-bar .woocommerce-result-count { margin: 0; font-size: var(--fs-sm); color: var(--muted); }
.shop-bar .woocommerce-ordering { margin: 0 auto 0 0; }
.woocommerce-ordering select {
	height: 40px; padding: 0 14px 0 34px; border-radius: var(--r-pill); border: 1px solid var(--line); background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2307552B' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat 12px center;
	-webkit-appearance: none; appearance: none; font-size: var(--fs-sm); font-weight: 600; cursor: pointer;
}
.shop-bar__filter .ico { width: 18px; height: 18px; }
@media (min-width: 1024px) { .shop-bar__filter { display: none; } }
.active-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.active-filters .chip { height: 34px; padding: 0 12px; }
.active-filters .chip .ico { width: 14px; height: 14px; color: #fff; }

/* ---------- Filters (کشو در موبایل، ستون در دسکتاپ) ---------- */
.filters { display: flex; flex-direction: column; gap: 6px; }
.fgroup { border: 0; margin: 0; padding: 16px 0; border-bottom: 1px solid var(--line); min-width: 0; }
.fgroup:last-child { border-bottom: 0; }
.fgroup legend { float: right; width: 100%; font-weight: 800; color: var(--green-deep); margin-bottom: 12px; padding: 0; font-size: var(--fs-sm); }
.fgroup legend + * { clear: both; }
.fgroup legend small { color: var(--muted); font-weight: 500; }
.fcats { display: flex; flex-direction: column; gap: 2px; }
.fcats a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: var(--r-sm); font-size: var(--fs-sm); font-weight: 600; transition: background var(--t), color var(--t); }
.fcats a .ico { width: 20px; height: 20px; color: var(--gold); }
.fcats a small { margin-inline-start: auto; color: var(--muted); font-weight: 500; }
.fcats a:hover { background: var(--cream); }
.fcats a.is-on { background: var(--green); color: #fff; }
.fcats a.is-on .ico, .fcats a.is-on small { color: var(--gold-light); }

.frange__track { position: relative; height: 28px; margin: 4px 6px 10px; }
.frange__track::before { content: ""; position: absolute; top: 12px; right: 0; left: 0; height: 4px; border-radius: 2px; background: var(--line); }
.frange__fill { position: absolute; top: 12px; height: 4px; border-radius: 2px; background: var(--green); }
.frange input[type="range"] { position: absolute; inset: 0; width: 100%; margin: 0; background: none; pointer-events: none; -webkit-appearance: none; appearance: none; direction: rtl; }
.frange input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; pointer-events: auto; width: 22px; height: 22px; border-radius: 50%; background: #fff; border: 3px solid var(--green); box-shadow: var(--sh-1); cursor: grab; }
.frange input[type="range"]::-moz-range-thumb { pointer-events: auto; width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 3px solid var(--green); cursor: grab; }
.frange input[type="range"]::-webkit-slider-runnable-track { background: none; }
.frange__vals { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.frange__vals label { display: flex; flex-direction: column; gap: 4px; font-size: var(--fs-xs); color: var(--muted); }
.frange__vals .input { min-height: 42px; padding: 8px 10px; font-size: var(--fs-sm); text-align: center; direction: ltr; }

.fcheck { display: flex; align-items: center; gap: 10px; padding: 6px 0; font-size: var(--fs-sm); cursor: pointer; }
.fcheck input { position: absolute; opacity: 0; pointer-events: none; }
.fcheck__box { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; border: 1.5px solid var(--line-2); background: #fff; transition: all var(--t); flex-shrink: 0; }
.fcheck__box .ico { width: 14px; height: 14px; stroke-width: 3; color: #fff; transform: scale(0); transition: transform .25s var(--ease); }
.fcheck input:checked + .fcheck__box { background: var(--green); border-color: var(--green); }
.fcheck input:checked + .fcheck__box .ico { transform: scale(1); }
.fcheck input:focus-visible + .fcheck__box { outline: 2px solid var(--gold); outline-offset: 2px; }
.fpills { display: flex; flex-wrap: wrap; gap: 6px; }
.fpill input { position: absolute; opacity: 0; pointer-events: none; }
.fpill span { display: inline-flex; align-items: center; height: 36px; padding: 0 14px; border-radius: var(--r-pill); border: 1.5px solid var(--line); background: #fff; font-size: var(--fs-xs); font-weight: 700; cursor: pointer; transition: all var(--t); }
.fpill input:checked + span { background: var(--green); border-color: var(--green); color: #fff; }
.fpill input:focus-visible + span { outline: 2px solid var(--gold); outline-offset: 2px; }
.filters__foot { display: grid; grid-template-columns: 1fr 1.5fr; gap: 10px; }

@media (min-width: 1024px) {
	.shop-filters.drawer {
		position: sticky; top: calc(var(--header-h) + 16px); bottom: auto; width: auto; z-index: 1; max-height: calc(100vh - var(--header-h) - 32px);
		transform: none; visibility: visible; box-shadow: none; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--white); overflow: hidden;
	}
	.shop-filters .drawer__head .x-btn { display: none; }
	.shop-filters .drawer__head { background: var(--cream); }
	.shop-filters .filters__foot { grid-template-columns: 1fr; }
	.shop-filters .filters__foot .btn--gold { display: none; } /* در دسکتاپ با هر تغییر اعمال می‌شود */
}
