/* Focused Nutrition Design: archive surface (shop, product categories / tags, product search).
 * Ported from the approved mock (mock/css/pages/shop.css). Owner: the archive surface builder.
 * Enqueued by templates/archive.php as fnd-archive-shop (after fnd-core). Every class is prefixed .shop- */
/* ---------------------------------------------------------------- Hero */
.shop-hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;               /* product photos multiply into the hero only */
  background: var(--fn-warm);
  border-bottom: 1px solid var(--fn-line);
  /* JS fills the hero synchronously before first paint; it is kept compact so products sit in the first viewport */
}
.shop-hero__glow {
  position: absolute; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(30% 50% at 70% 100%, rgba(247, 123, 1, .08), transparent 70%),
    linear-gradient(180deg, #f8f7f5 0%, var(--fn-warm) 100%);
}
.shop-hero.is-noart .shop-hero__glow { background: linear-gradient(180deg, #f8f7f5 0%, var(--fn-warm) 100%); }
/* ghost word: desktop only. It lives inside the hero grid, starts at 55% of the container (never under the
   title column), is clipped to the right edge and fades in from the left, so it reads as texture behind the art. */
.shop-hero__word { display: none; }
@media (min-width: 1024px) {
  .shop-hero__word {
    display: block; position: absolute; z-index: -1; left: 55%; right: 0; top: 0; bottom: 0;
    margin: 0; overflow: hidden; pointer-events: none; user-select: none;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 30%);
            mask-image: linear-gradient(90deg, transparent, #000 30%);
  }
  .shop-hero__word span {
    position: absolute; right: -.03em; top: 50%; transform: translateY(-58%);
    font-family: var(--fn-font); font-weight: 700; text-transform: uppercase;
    font-size: clamp(120px, 10vw, 170px); line-height: 1; letter-spacing: -.04em;
    white-space: nowrap; color: rgba(17, 17, 17, .045);
  }
  .shop-hero.is-noart .shop-hero__word, .shop-hero.is-bare .shop-hero__word { display: none; }
}
.shop-hero__inner { position: relative; padding-top: 12px; padding-bottom: 12px; }
@media (min-width: 1024px) { .shop-hero__inner { padding-top: 18px; padding-bottom: 24px; } }
.shop-hero__crumbs { min-height: 21px; }
/* phones: breadcrumb + title only (the art and the count move out; the results bar carries the count) */
.shop-hero__grid {
  position: relative;
  display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px 16px; align-items: center;
  padding-top: 6px;
}
.shop-hero__art { display: none; }
@media (min-width: 640px) {
  .shop-hero__grid { grid-template-columns: minmax(0, 1fr) 150px; padding-top: 10px; }
  .shop-hero__art { display: grid; }
}
@media (min-width: 1024px) {
  /* the art column rises to the bottom edge so the packs stand on the hero's base line */
  .shop-hero__grid { grid-template-columns: minmax(0, 1fr) 420px; gap: 48px; align-items: end; padding-top: 14px; min-height: 0; }
  .shop-hero__art { margin-bottom: -24px; }
  .shop-hero__text { padding-bottom: 6px; }
}
.shop-hero__grid--noart, .shop-hero.is-bare .shop-hero__grid { grid-template-columns: minmax(0, 1fr); }
.shop-hero__text { position: relative; min-width: 0; }
.shop-hero__eyebrow { margin-bottom: 8px; color: var(--fn-ink-2); }
.shop-hero__eyebrow::before {
  content: ""; display: inline-block; vertical-align: middle; width: 18px; height: 3px; margin: -2px 10px 0 0;
  border-radius: 2px; background: var(--fn-orange);
}
.shop-hero__title {
  font-size: clamp(28px, 3.4vw + 14px, 60px); line-height: 1.02; letter-spacing: -.025em;
  color: var(--fn-ink); overflow-wrap: anywhere;
}
@media (min-width: 1024px) { .shop-hero__title { font-size: clamp(40px, 3vw + 16px, 64px); line-height: 1; } }
.shop-hero__q { font-weight: 700; }
.shop-hero__sub {
  margin-top: 8px; max-width: 60ch;
  font-size: 14px; line-height: 1.5; color: var(--fn-ink-2);
}
.shop-hero__count { font-variant-numeric: tabular-nums; }
/* phones: breadcrumb + H1. The count lives in the results bar; a sub stays only when it holds a link
   (Clear search, Book a consultation) */
@media (max-width: 767.98px) {
  .shop-hero__eyebrow { display: none; }
  .shop-hero__sub { margin-top: 6px; }
  .shop-hero__sub:not(.shop-hero__sub--act) { display: none; }
  .shop-hero__count { display: none; }
}
@media (max-width: 1023.98px) { .shop-hero__title { font-size: clamp(28px, 3.4vw + 14px, 44px); } }
@media (min-width: 768px) { .shop-hero__sub { font-size: 16px; margin-top: 12px; } }
.shop-hero__clear {
  color: var(--fn-ink); font-weight: 700; white-space: nowrap;
  text-decoration: underline; text-decoration-color: var(--fn-orange); text-decoration-thickness: 2px; text-underline-offset: 3px;
}
.shop-hero__clear:hover { text-decoration-color: var(--fn-ink); }
/* hero art (tablet and up) */
.shop-hero__art { position: relative; align-self: stretch; place-items: center; min-height: 150px; }
.shop-hero__art::before { /* crisp orange disc behind the product, drawn only once the image is in */
  content: ""; position: absolute; left: 50%; top: 50%; width: 78%; aspect-ratio: 1; transform: translate(-50%, -50%);
  border-radius: 50%; background: radial-gradient(closest-side, rgba(247, 123, 1, .18), rgba(247, 123, 1, .06) 70%, transparent 71%);
  z-index: -1; opacity: 0; transition: opacity 240ms var(--ease);
}
.shop-hero__art.is-ready::before { opacity: 1; }
.shop-hero__art:has(.shop-hero__photo)::before { display: none; }
.shop-hero__single, .shop-hero__stack { position: relative; width: 100%; height: 150px; }
@media (min-width: 1024px) {
  .shop-hero__single, .shop-hero__stack, .shop-hero__art { height: 240px; min-height: 240px; }
}
.shop-hero__single img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain;
  mix-blend-mode: multiply; opacity: 0;
}
.shop-hero__art.is-ready .shop-hero__single img { animation: shop-float-in 520ms var(--ease) both; }
.shop-hero__floor {
  position: absolute; left: 22%; right: 22%; bottom: 2%; height: 10%;
  background: radial-gradient(closest-side, rgba(0, 0, 0, .16), transparent); pointer-events: none;
  opacity: 0; transition: opacity 240ms var(--ease);
}
.shop-hero__art.is-ready .shop-hero__floor { opacity: 1; }
.shop-hero__pimg {
  position: absolute; bottom: 4%; height: 74%; width: 40%; object-fit: contain;
  mix-blend-mode: multiply; opacity: 0;
}
.shop-hero__art.is-ready .shop-hero__pimg { animation: shop-float-in 520ms var(--ease) both; }
.shop-hero__art.is-ready .shop-hero__pimg:nth-of-type(1) { left: 2%; animation-delay: 60ms; }
.shop-hero__art.is-ready .shop-hero__pimg:nth-of-type(3) { right: 2%; animation-delay: 100ms; }
.shop-hero__pimg:nth-of-type(1) { left: 2%; }
.shop-hero__pimg:nth-of-type(3) { right: 2%; }
.shop-hero__pimg.is-main { left: 50%; width: 50%; height: 96%; margin-left: -25%; bottom: 2%; z-index: 1; }
.shop-hero__stack--1 .shop-hero__pimg.is-main, .shop-hero__stack--2 .shop-hero__pimg.is-main { left: 50%; }
.shop-hero__stack--2 .shop-hero__pimg:not(.is-main) { left: auto; right: 4%; }
.shop-hero__photo {
  position: relative; height: 100%; max-height: 240px; aspect-ratio: 4 / 5; border-radius: var(--r-lg); overflow: hidden;
  background: var(--fn-black); box-shadow: 0 18px 44px rgba(0, 0, 0, .18);
}
.shop-hero__photo img { width: 100%; height: 100%; object-fit: cover; }
@media (min-width: 1024px) { .shop-hero__art:has(.shop-hero__photo) { margin-bottom: 0; align-self: center; height: auto; min-height: 0; } .shop-hero__photo { height: 220px; } }
@media (max-width: 1023.98px) { .shop-hero__photo { height: auto; width: 100%; max-width: 120px; border-radius: var(--r-md); } }
@keyframes shop-float-in { from { opacity: 0; transform: translateY(14px) scale(.97); } to { opacity: 1; transform: none; } }

/* count pill used by the empty-state category chips */
.shop-hchip__n {
  display: inline-grid; place-items: center; min-width: 22px; height: 20px; padding: 0 6px; margin-left: -2px;
  border-radius: var(--r-pill); background: var(--fn-warm-2); color: var(--fn-ink-2);
  font-size: 11px; font-weight: 700; font-variant-numeric: tabular-nums;
}
.shop-hchip.is-active .shop-hchip__n { background: rgba(255, 255, 255, .16); color: #fff; }

/* ---------------------------------------------------------------- Layout */
.shop-layout { padding-bottom: var(--s-8); }
@media (min-width: 1024px) {
  .shop-layout {
    display: grid; grid-template-columns: 256px minmax(0, 1fr); gap: 40px; align-items: start;
    padding-top: 32px; padding-bottom: var(--s-9);
  }
}
@media (min-width: 1280px) { .shop-layout { grid-template-columns: 272px minmax(0, 1fr); gap: 48px; } }

.shop-layout.is-noscope { grid-template-columns: minmax(0, 1fr); }
.shop-layout.is-noscope .shop-side, .shop-layout.is-noscope .shop-bar__filter { display: none; }
.shop-layout.is-noscope .shop-bar { grid-template-columns: minmax(0, 1fr); }
/* zero results: one message (the empty block), no sort control and no "No products found" counters */
.shop-layout.is-zero .shop-sort, .shop-layout.is-zero .shop-count-m, .shop-layout.is-zero .shop-count { display: none; }
.shop-layout.is-noscope .shop-bar { display: none; }
.shop-layout.is-zero .shop-bar { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1024px) { .shop-layout.is-zero .shop-bar { display: none; } }

/* ---------------------------------------------------------------- Sidebar */
.shop-side { display: none; }
@media (min-width: 1024px) {
  .shop-side {
    display: block;
    position: sticky; top: calc(var(--fn-sticky-top) + 24px);
    max-height: calc(100vh - var(--fn-sticky-top) - 48px);
    overflow-y: auto; overscroll-behavior: contain;
    padding-right: 10px; margin-right: -10px;         /* room for the scrollbar */
    /* no grey track at rest: the thin thumb only shows while the filters are hovered or focused */
    scrollbar-width: thin; scrollbar-color: transparent transparent;
  }
  .shop-side:hover, .shop-side:focus-within { scrollbar-color: #d6d4d0 transparent; }
  .shop-side::-webkit-scrollbar { width: 6px; background: transparent; }
  .shop-side::-webkit-scrollbar-track { background: transparent; }
  .shop-side::-webkit-scrollbar-thumb { background: transparent; border-radius: 6px; }
  .shop-side:hover::-webkit-scrollbar-thumb, .shop-side:focus-within::-webkit-scrollbar-thumb { background: #d6d4d0; }
}
.shop-side__head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 44px; padding-bottom: 6px;
}
.shop-side__title { font-size: 20px; letter-spacing: -.01em; }
.shop-side__clear { min-height: 32px; font-size: 14px; }

/* filter groups */
.shop-fg { border-top: 1px solid var(--fn-line); }
.shop-fg__sum {
  list-style: none; cursor: pointer; -webkit-tap-highlight-color: transparent;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 52px; font-size: 15px; font-weight: 700; color: var(--fn-ink);
}
.shop-fg__sum::-webkit-details-marker { display: none; }
.shop-fg__sum:focus-visible { border-radius: 6px; }
.shop-fg__sum > span:first-child { margin-right: auto; }
.shop-fg__val { max-width: 55%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; font-weight: 700; color: var(--fn-ink-2); background: var(--fn-warm-2); padding: 3px 10px; border-radius: var(--r-pill); }
.shop-fg[open] .shop-fg__val { display: none; }
.shop-fg__chev { width: 18px; height: 18px; transition: transform var(--t) var(--ease); }
.shop-fg[open] > .shop-fg__sum .shop-fg__chev { transform: rotate(180deg); }
.shop-fg__body { padding: 0 0 18px; }
.shop-fg[open] > .shop-fg__body { animation: fn-fade-down var(--t) var(--ease); }

/* category tree */
.shop-cats, .shop-cats__sub { list-style: none; margin: 0; padding: 0; }
.shop-cats { display: flex; flex-direction: column; gap: 2px; }
.shop-cats__sub { margin: 2px 0 4px 14px; padding-left: 8px; border-left: 1px solid var(--fn-line); display: flex; flex-direction: column; gap: 2px; }
.shop-cat {
  position: relative; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  min-height: 40px; padding: 0 10px 0 12px; border-radius: var(--r-sm);
  font-size: 14px; font-weight: 700; color: var(--fn-ink); line-height: 1.25;
  transition: background-color var(--t-fast) var(--ease), color var(--t-fast) var(--ease);
}
.shop-cat--sub { min-height: 36px; font-weight: 400; color: var(--fn-ink-2); }
.shop-cat:hover { background: var(--fn-warm-2); color: var(--fn-ink); }
.shop-cat__n {
  flex: none; min-width: 26px; height: 22px; padding: 0 7px; border-radius: var(--r-pill);
  display: inline-grid; place-items: center; background: var(--fn-warm-2);
  font-size: 12px; font-weight: 700; color: var(--fn-meta); font-variant-numeric: tabular-nums;
}
.shop-cat:hover .shop-cat__n { background: #fff; }
.shop-cat.is-active { background: var(--fn-ink); color: #fff; }
.shop-cat.is-active::before {
  content: ""; position: absolute; left: 0; top: 9px; bottom: 9px; width: 3px; border-radius: 0 3px 3px 0; background: var(--fn-orange);
}
.shop-cat.is-active .shop-cat__n { background: rgba(255, 255, 255, .14); color: #fff; }
.shop-cat.is-empty { color: #767676; }
.shop-cat.is-empty .shop-cat__n { background: transparent; color: #767676; }
.shop-cats li[hidden], .shop-opts li[hidden] { display: none !important; }
/* smaller categories wait behind "Show all categories" */
.shop-cats__more { display: none; }
.shop-cats.is-all .shop-cats__more { display: list-item; }
.shop-cats__more[hidden] { display: none !important; }
/* brand + product type rows: same look as category rows, as toggle buttons */
.shop-opts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.shop-opt { width: 100%; text-align: left; font-weight: 400; color: var(--fn-ink); }
.shop-opt.is-active { font-weight: 700; }
.shop-opts__more { display: none; }
.shop-opts.is-all .shop-opts__more { display: list-item; }
.shop-cats__toggle {
  display: inline-flex; align-items: center; gap: 6px; min-height: 40px; margin-top: 6px; padding: 0 12px;
  border-radius: var(--r-sm); font-size: 14px; font-weight: 700; color: var(--fn-ink);
  text-decoration: underline; text-decoration-color: var(--fn-orange); text-decoration-thickness: 2px; text-underline-offset: 4px;
}
.shop-cats__toggle:hover { text-decoration-color: var(--fn-ink); }
.shop-cats__toggle svg { width: 16px; height: 16px; transition: transform var(--t) var(--ease); }
.shop-cats__toggle[aria-expanded="true"] svg { transform: rotate(180deg); }

/* price: dual range slider */
.shop-range { --a: 0%; --b: 100%; position: relative; height: 32px; margin: 4px 10px 10px; }
.shop-range__track { position: absolute; left: 0; right: 0; top: 50%; height: 3px; margin-top: -1.5px; border-radius: 3px; background: #e2e0dc; }
.shop-range__fill { position: absolute; top: 0; bottom: 0; left: var(--a); right: calc(100% - var(--b)); border-radius: 3px; background: var(--fn-orange); }
.shop-range__in {
  position: absolute; top: 0; left: -10px; width: calc(100% + 20px); height: 32px; margin: 0;
  background: none; pointer-events: none; -webkit-appearance: none; appearance: none;
  -webkit-tap-highlight-color: transparent;
}
.shop-range__in:focus, .shop-range__in:focus-visible { outline: none; box-shadow: none; }
.shop-range__in::-webkit-slider-runnable-track { height: 32px; background: transparent; border: 0; }
.shop-range__in::-moz-range-track { height: 32px; background: transparent; border: 0; }
.shop-range__in::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none; pointer-events: auto; cursor: grab;
  width: 20px; height: 20px; margin-top: 6px; border-radius: 50%;
  background: #fff; border: 2px solid var(--fn-ink); box-shadow: 0 1px 4px rgba(0, 0, 0, .14);
  transition: box-shadow var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
.shop-range__in::-moz-range-thumb {
  pointer-events: auto; cursor: grab; width: 16px; height: 16px; border-radius: 50%;
  background: #fff; border: 2px solid var(--fn-ink); box-shadow: 0 1px 4px rgba(0, 0, 0, .14);
}
.shop-range__in:active::-webkit-slider-thumb { cursor: grabbing; background: var(--fn-orange); }
.shop-range__in:active::-moz-range-thumb { cursor: grabbing; background: var(--fn-orange); }
.shop-range__in:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--fn-ink), 0 0 0 9px var(--fn-orange-glow); }
.shop-range__in:focus-visible::-moz-range-thumb { box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--fn-ink), 0 0 0 9px var(--fn-orange-glow); }
.shop-range__in[data-r="hi"] { z-index: 2; }
.shop-range.is-lo-top .shop-range__in[data-r="lo"] { z-index: 3; }

.shop-price { display: grid; grid-template-columns: minmax(0, 1fr) 12px minmax(0, 1fr); align-items: center; gap: 6px; }
.shop-price__dash { height: 1.5px; background: #b8b8b8; }
.shop-price__f {
  position: relative; display: flex; align-items: center; height: 46px; padding: 0 10px;
  border: 1.5px solid #d0d0d0; border-radius: var(--r-sm); background: #fff; cursor: text;
  transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease);
}
.shop-price__f:hover { border-color: #a8a8a8; }
.shop-price__f:focus-within { border-color: var(--fn-ink); box-shadow: 0 0 0 3px var(--fn-orange-glow); }
/* label sits quietly on the left; "$" and the number read as one value */
.shop-price__lbl { flex: none; font-size: 12px; font-weight: 400; color: var(--fn-meta); margin-right: 8px; }
.shop-price__val { display: flex; align-items: center; flex: 1; min-width: 0; height: 100%; }
.shop-price__cur { flex: none; margin-right: 1px; font-family: var(--fn-font-text); font-size: 16px; font-weight: 600; color: var(--fn-ink); }
.shop-price__f input {
  width: 100%; min-width: 0; height: 100%; border: 0; background: transparent; padding: 0;
  font-family: var(--fn-font-text); font-size: 16px; font-weight: 600; color: var(--fn-ink);
  -moz-appearance: textfield; appearance: textfield; font-variant-numeric: tabular-nums;
}
.shop-price__f input::-webkit-outer-spin-button, .shop-price__f input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.shop-price__f input:focus, .shop-price__f input:focus-visible { outline: none; box-shadow: none; }

.shop-presets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 12px; }
.shop-preset {
  display: flex; align-items: center; justify-content: space-between; gap: 6px;
  min-height: 40px; padding: 0 10px 0 12px; border-radius: var(--r-sm);
  border: 1.5px solid var(--fn-line-2); background: #fff;
  font-size: 13px; font-weight: 700; color: var(--fn-ink); text-align: left; line-height: 1.2;
  transition: border-color var(--t-fast) var(--ease), background-color var(--t-fast) var(--ease);
}
.shop-preset:hover { border-color: #a8a8a8; }
.shop-preset__n { font-size: 12px; color: var(--fn-meta); font-variant-numeric: tabular-nums; }
.shop-preset.is-on { border-color: var(--fn-ink); background: var(--fn-orange-tint); box-shadow: inset 0 0 0 1px var(--fn-ink); }
.shop-preset.is-on .shop-preset__n { color: var(--fn-ink-2); }
.shop-preset.is-empty, .shop-preset:disabled { color: #767676; background: var(--fn-warm); border-color: var(--fn-warm); cursor: not-allowed; }
.shop-preset:disabled .shop-preset__n { color: #767676; }

/* availability */
.shop-switch { width: 100%; }
.shop-switch > span:not(.shop-n) { flex: 1; font-weight: 700; font-size: 14px; }
.shop-n, .shop-check .fn-count {
  margin-left: auto; min-width: 26px; height: 22px; padding: 0 7px; border-radius: var(--r-pill);
  display: inline-grid; place-items: center; background: var(--fn-warm-2);
  font-size: 12px; font-weight: 700; color: var(--fn-meta); font-variant-numeric: tabular-nums;
}
.shop-check { width: 100%; min-height: 48px; align-items: center; }
.shop-check__txt { display: flex; flex-direction: column; line-height: 1.25; }
.shop-check__txt > span { font-size: 14px; font-weight: 700; }
.shop-check__txt small { font-size: 12px; color: var(--fn-meta); }
.shop-check.is-empty .shop-check__txt > span { color: #8f8f8f; }
.shop-check + .shop-check { margin-top: 2px; }

/* ---------------------------------------------------------------- Results bar */
.shop-results { min-width: 0; }
.shop-results h2[tabindex="-1"]:focus { outline: none; }
.shop-bar-sentinel { height: 1px; margin-bottom: -1px; }
.shop-bar {
  position: sticky; top: var(--fn-sticky-top); z-index: var(--z-sticky);
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; align-items: center;
  margin-inline: calc(var(--fn-gutter) * -1); padding: 8px var(--fn-gutter);
  background: #fff; border-bottom: 1px solid var(--fn-line);
  transition: box-shadow var(--t) var(--ease);
}
.shop-bar.is-stuck { box-shadow: var(--sh-bar); }
.shop-bar__filter {
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 14px; border-radius: var(--r-sm);
  background: var(--fn-ink); color: #fff; font-size: 14px; font-weight: 700;
  transition: background-color var(--t) var(--ease), color var(--t) var(--ease);
}
.shop-bar__filter:hover { background: var(--fn-orange); color: var(--fn-ink); }
.shop-bar__filter .fn-icon { width: 18px; height: 18px; }
.shop-bar__badge {
  display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px;
  background: var(--fn-orange); color: var(--fn-ink); font-size: 11px; font-weight: 700;
}
.shop-bar__filter:hover .shop-bar__badge { background: var(--fn-ink); color: #fff; }
.shop-count { display: none; font-size: 14px; color: var(--fn-ink-2); font-variant-numeric: tabular-nums; }
.shop-sort { position: relative; min-width: 0; }
.shop-sort__label {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.shop-sort__select { width: 100%; min-height: 44px; height: 44px; font-size: 14px; padding-left: 14px; padding-right: 38px; background-position: right 12px center; }
.shop-count-m { margin: 10px 0 0; font-size: 13px; color: var(--fn-ink-2); font-variant-numeric: tabular-nums; }
.shop-count b, .shop-count-m b { font-weight: 700; color: var(--fn-ink); }
@media (min-width: 1024px) { .shop-count-m { display: none; } }
@media (min-width: 1024px) {
  .shop-bar {
    position: static; display: flex; justify-content: space-between; gap: 16px;
    margin: 0; padding: 0 0 16px; border: 0; border-bottom: 1px solid var(--fn-line); box-shadow: none !important;
  }
  .shop-bar__filter { display: none; }
  .shop-count { display: block; font-size: 15px; }
  .shop-sort { display: flex; align-items: center; gap: 12px; }
  .shop-sort__label {
    position: static !important; width: auto; height: auto; margin: 0; overflow: visible; clip: auto;
    font-size: 14px; font-weight: 700; color: var(--fn-ink-2);
  }
  .shop-sort__select { width: auto; min-width: 210px; }
}

/* active filter chips */
.shop-active {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 12px 0 2px;
}
.shop-active[hidden] { display: none; }
.shop-active__list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
.shop-achip { background: #fff; border-color: var(--fn-line-2); min-height: 34px; padding-left: 12px; }
.shop-achip .fn-chip__x { width: 26px; height: 26px; }
.shop-active__clear { min-height: 34px; font-size: 13px; margin-left: 4px; }

/* ---------------------------------------------------------------- Grid */
.shop-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--fn-gap);
  padding-top: 12px;
}
.shop-grid { row-gap: 28px; }
@media (min-width: 768px) { .shop-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1024px) { .shop-grid { padding-top: 24px; gap: 40px 20px; } }
@media (min-width: 1280px) { .shop-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px 24px; } }

/* one shape per product: the grey media tile. No card frame, no inner padding. */
.shop-grid .fn-card { border-color: transparent; padding: 0; background: none; border-radius: 0; }
.shop-grid .fn-card__body { padding: 14px 4px 0; }
.shop-grid .fn-card__media { border-radius: var(--r-md); outline: 1px solid transparent; outline-offset: -1px; transition: outline-color var(--t) var(--ease); }
@media (hover: hover) and (pointer: fine) {
  .shop-grid .fn-card:hover { box-shadow: none; transform: none; border-color: transparent; }
  .shop-grid .fn-card:hover .fn-card__media { outline-color: var(--fn-line-2); }
}
/* scale the product up inside its tile: the photo gets a tighter inset; each 3D render is then sized from its
   own bounding box by shop.js (fitShot) so the pack fills about 78% of the tile height. This is the
   average-case size used until that measurement lands. */
.shop-grid .fn-card__imgwrap { inset: 6%; }
.shop-grid .fn-card__img3d { inset: -9%; width: 118%; height: 118%; }

/* tighter type for the 2-up phone grid */
@media (max-width: 400px) {
  .shop-grid .fn-card__title { font-size: 13px; }
  .shop-grid .fn-card__price { font-size: 15px; }
  .shop-grid .fn-card__cta { font-size: 12.5px; padding: 0 6px; gap: 6px; }
  .shop-grid .fn-card__cta svg { width: 16px; height: 16px; }
}
/* card buttons: one shared style in css/fn.css (.fn-card__cta). Out of stock: quieter tile */
.shop-grid .fn-card.is-out .fn-card__media { background: #efeeec; }
.shop-grid .fn-card.is-out .fn-card__img3d { filter: grayscale(.55); opacity: .75; }
.shop-grid .fn-card.is-out .fn-card__media.is-3d .fn-card__img3d { opacity: .75; }
/* once the 3D render is in, the flat photo must be fully gone: fn.css dims it to .7 on out-of-stock cards, which
   would leave it showing under the render (a doubled, ghosted pack). Local guard until fn.css scopes that rule. */
.shop-grid .fn-card.is-out .fn-card__media.is-3d .fn-card__img { opacity: 0; }
.shop-grid .fn-card.is-out .fn-card__price { color: var(--fn-meta); }
/* the photo stays until the 3D render can actually paint. fn3d adds .is-3d as soon as the render's address is set;
   if that image has not loaded or decoded yet (slow phones, lazy images further down) the tile would be an empty grey
   well. shop.js adds .is-3d-painted once the render has decoded, and only then does the crossfade run.
   Local guard until fn.js applies .is-3d after img.decode() itself. */
.shop-grid .fn-card .fn-card__media.is-3d:not(.is-3d-painted) .fn-card__img { opacity: 1; }
.shop-grid .fn-card.is-out .fn-card__media.is-3d:not(.is-3d-painted) .fn-card__img { opacity: .7; }
.shop-grid .fn-card .fn-card__media.is-3d:not(.is-3d-painted) .fn-card__img3d { opacity: 0; }
.shop-grid .fn-card .fn-card__media.is-3d:not(.is-3d-painted)::before { opacity: 1; }

/* cards arrive with a short stagger after each filter change */
.shop-in { animation: shop-card-in 380ms var(--ease) both; animation-delay: calc(var(--i, 0) * 28ms); }
@keyframes shop-card-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ---------------------------------------------------------------- Show previous (a /page/N/ landing) */
.shop-prev { display: flex; justify-content: center; padding-bottom: 20px; }
.shop-prev[hidden] { display: none; }
.shop-prev__btn { min-width: 220px; }
.shop-prev__btn svg { transform: rotate(180deg); }

/* ---------------------------------------------------------------- Load more */
.shop-more { display: flex; flex-direction: column; align-items: center; gap: 12px; padding-top: 40px; text-align: center; }
.shop-more__txt { font-size: 14px; color: var(--fn-ink-2); font-variant-numeric: tabular-nums; }
.shop-more__bar { width: min(260px, 70%); height: 4px; border-radius: 4px; background: var(--fn-line); overflow: hidden; }
.shop-more__bar span { display: block; height: 100%; width: 0; border-radius: 4px; background: var(--fn-orange); transition: width var(--t-slow) var(--ease); }
.shop-more__btn { margin-top: 8px; min-width: 220px; }
.shop-more__btn svg { transition: transform var(--t) var(--ease); }
.shop-more__btn:hover svg { transform: translateY(2px); }

/* ---------------------------------------------------------------- Empty */
.shop-empty { text-align: center; padding: 48px 8px 16px; max-width: 620px; margin: 0 auto; }
.shop-empty .fn-empty__icon { background: #fff; border: 1px solid var(--fn-line); box-shadow: 0 0 0 10px var(--fn-warm); margin-bottom: 26px; }
.shop-empty__title { font-size: var(--fn-fs-h3); line-height: 1.2; overflow-wrap: anywhere; }
.shop-empty__txt { margin-top: 10px; font-family: var(--fn-font-text); font-size: 15px; line-height: 1.6; color: var(--fn-ink-2); }
.shop-empty__btns { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 22px; }
.shop-empty__label { margin-top: 32px; font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--fn-meta); }
.shop-empty__chips { justify-content: center; margin-top: 12px; }
.shop-empty__chips .shop-hchip__n { background: var(--fn-warm-2); }

/* ---------------------------------------------------------------- Mobile sheet */
.shop-sheet { max-height: 88vh; max-height: 88dvh; }
.shop-sheet__head {
  flex: none; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 6px 8px 6px 20px; border-bottom: 1px solid var(--fn-line);
}
.shop-sheet__title { font-size: 18px; }
.shop-sheet__body { flex: 1 1 auto; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 4px 20px 12px; }
.shop-sheet__body .shop-fg:first-child { border-top: 0; }
.shop-sheet__body .shop-cat { min-height: 44px; }
.shop-sheet__body .shop-cat--sub { min-height: 42px; }
.shop-sheet__foot {
  flex: none; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px;
  padding: 12px 20px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid var(--fn-line); background: #fff;
  box-shadow: var(--sh-up);
}
.shop-sheet__foot .fn-btn { min-height: 50px; }
#shop-sheet-clear:disabled { opacity: .45; pointer-events: none; }
.shop-sheet__foot .fn-btn--primary { white-space: normal; }
@media (min-width: 1024px) { .shop-sheet { display: none; } }

/* ---------------------------------------------------------------- Explore */
.shop-explore .fn-sechead__sub { font-size: 15px; }
.shop-explore[hidden] { display: none; }
/* six cut-out tiles: 3 x 2 on tablets and small laptops, one row of 6 on wide screens (no orphan row) */
@media (min-width: 1024px) { .shop-explore .fn-tiles { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1280px) { .shop-explore .fn-tiles { grid-template-columns: repeat(6, minmax(0, 1fr)); } }

/* reduced motion: fn.css already zeroes durations; also skip the hero float */
@media (prefers-reduced-motion: reduce) {
  .shop-in, .shop-hero__art.is-ready .shop-hero__single img, .shop-hero__art.is-ready .shop-hero__pimg { animation: none; opacity: 1; }
}

/* ---------------------------------------------------------------- WordPress build additions */
/* the results bar is a GET form (sort works without JS); it carries no form spacing of its own */
form.shop-bar { margin-block: 0; }
.shop-sort noscript .fn-btn { margin-left: 8px; }
/* server pagination (WooCommerce main query): shown to no-JS visitors and crawlers; shop.js swaps it for "Load more" */
.shop-pager { padding-top: 40px; display: flex; justify-content: center; }
.shop-pager[hidden] { display: none; }
.shop-pager .nav-links { justify-content: center; }
/* the server renders the count; the phone line copies it once shop.js runs */
.shop-count:empty { display: none; }
/* the hero sub always starts on its own line under the H1 */
.shop-hero__tag { display: inline; }
/* hidden helpers that must win over component display rules */
.shop-grid[hidden], .shop-empty[hidden], .shop-more[hidden] { display: none !important; }
