@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,ital,wght@9..144,0,500;9..144,1,400&family=Inter:wght@400;500;600&display=swap');

/* ══════════════════════════════════════════════════════
   TOKENS
══════════════════════════════════════════════════════ */
.wm-pg-root,
.wm-shop-root {
  --wm-ink:       #111827;
  --wm-text:      #374151;
  --wm-muted:     #9CA3AF;
  --wm-gold:      #c39b61;
  --wm-gold-dark: #a8824b;
  --wm-gold-bg:   #FBF5EB;
  --wm-line:      #E5E7EB;
  --wm-line-soft: #F9FAFB;
  --wm-red:       #EF4444;
  --wm-bg:        #ffffff;
  font-family: 'Inter', -apple-system, sans-serif;
  color: var(--wm-text);
  background: var(--wm-bg);
  -webkit-font-smoothing: antialiased;
}
.wm-pg-root *, .wm-shop-root * { box-sizing: border-box; }
.wm-pg-root a, .wm-shop-root a { text-decoration: none; color: inherit; }
.wm-pg-root button, .wm-shop-root button { font-family: inherit; cursor: pointer; }

/* ══════════════════════════════════════════════════════
   SHARED: HEADING
══════════════════════════════════════════════════════ */
.wm-pg-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 40px;
}
.wm-shop-heading { margin-bottom: 32px; }
.wm-pg-heading-left { display: flex; flex-direction: column; gap: 10px; }

.wm-pg-eyebrow {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--wm-gold);
  font-weight: 600;
}
.wm-pg-eyebrow::before {
  content: '';
  width: 28px; height: 1px;
  background: var(--wm-gold);
  flex-shrink: 0;
}
.wm-pg-title {
  font-family: 'Fraunces', serif;
  font-size: clamp(26px, 3vw, 40px);
  font-weight: 500;
  line-height: 1.1;
  margin: 0;
  letter-spacing: -.02em;
  color: var(--wm-ink);
}
.wm-pg-title em { font-style: italic; color: var(--wm-gold); font-weight: 400; }

.wm-pg-view-all {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--wm-ink);
  display: inline-flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--wm-ink);
  transition: color .2s, border-color .2s;
  flex-shrink: 0;
  margin-bottom: 6px;
}
.wm-pg-view-all:hover { color: var(--wm-gold); border-color: var(--wm-gold); }
.wm-pg-view-all svg { width: 13px; height: 13px; transition: transform .2s; }
.wm-pg-view-all:hover svg { transform: translateX(3px); }

/* ══════════════════════════════════════════════════════
   SHARED: PRODUCT CARD
══════════════════════════════════════════════════════ */
.wm-pg-grid {
  display: grid;
  gap: 36px 20px;
}
.wm-cols-2 { grid-template-columns: repeat(2, 1fr); }
.wm-cols-3 { grid-template-columns: repeat(3, 1fr); }
.wm-cols-4 { grid-template-columns: repeat(4, 1fr); }
.wm-cols-5 { grid-template-columns: repeat(5, 1fr); }

.wm-pg-card { display: flex; flex-direction: column; }

.wm-pg-card-img-wrap {
  position: relative;
  width: 100%;
  padding-top: 100%;
  overflow: hidden;
  border-radius: 3px;
  background: #ffffff;          /* pure white — no grey */
  display: block;
  flex-shrink: 0;
}
.wm-pg-card-img {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform .55s ease;
}
.wm-pg-card:hover .wm-pg-card-img { transform: scale(1.05); }

.wm-pg-badge {
  position: absolute;
  top: 12px; left: 12px;
  z-index: 2;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 2px;
  line-height: 1.4;
  pointer-events: none;
}
.wm-pg-badge.new  { background: #1f2937; color: #fff; }
.wm-pg-badge.sale { background: var(--wm-red); color: #fff; }

.wm-pg-card-body { padding: 14px 0 0; display: flex; flex-direction: column; gap: 6px; }
.wm-pg-card-cat {
  font-size: 10.5px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--wm-muted);
  font-weight: 500;
}
.wm-pg-card-name {
  font-family: 'Fraunces', serif;
  font-size: 17px;
  font-weight: 500;
  line-height: 1.3;
  color: var(--wm-ink);
  transition: color .2s;
  display: block;
}
.wm-pg-card:hover .wm-pg-card-name { color: var(--wm-gold-dark); }
.wm-pg-card-price { display: flex; align-items: baseline; gap: 7px; flex-wrap: wrap; margin-top: 2px; }
.wm-pg-price-current  { font-size: 15px; font-weight: 600; color: var(--wm-ink); }
.wm-pg-price-original { font-size: 13px; color: var(--wm-muted); text-decoration: line-through; }
.wm-pg-price-save     { font-size: 11.5px; color: var(--wm-red); font-weight: 600; }

.wm-no-products {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 20px;
  color: var(--wm-muted);
  font-family: 'Fraunces', serif;
  font-size: 20px;
  font-style: italic;
}

/* ══════════════════════════════════════════════════════
   [wm_products] GRID SECTION
══════════════════════════════════════════════════════ */
.wm-pg-section {
  padding: 60px 40px;
  max-width: 1400px;
  margin: 0 auto;
}
.wm-pg-cta-row { margin-top: 56px; display: flex; justify-content: center; }
.wm-pg-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--wm-ink);
  border: 1px solid var(--wm-ink);
  padding: 15px 36px;
  transition: background .25s, color .25s;
}
.wm-pg-cta:hover { background: var(--wm-ink); color: #fff; }
.wm-pg-cta svg { width: 14px; height: 14px; transition: transform .25s; }
.wm-pg-cta:hover svg { transform: translateX(4px); }

/* ══════════════════════════════════════════════════════
   SLIDER
══════════════════════════════════════════════════════ */
.wm-slider-outer {
  position: relative;
  /* side padding makes room for arrows on desktop */
  padding: 0 52px;
}
.wm-slider-viewport { overflow: hidden; width: 100%; }
.wm-slider-track {
  display: flex;
  gap: 20px;
  transition: transform .45s cubic-bezier(.25,.46,.45,.94);
  will-change: transform;
}
.wm-slide { flex: 0 0 auto; }

.wm-sl-btn {
  position: absolute;
  top: calc(50% - 40px);     /* centre on image, not whole card */
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid var(--wm-line);
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  box-shadow: 0 2px 8px rgba(0,0,0,.09);
  transition: border-color .2s, box-shadow .2s;
  color: var(--wm-ink);
}
.wm-sl-btn:hover  { border-color: var(--wm-gold); box-shadow: 0 3px 12px rgba(0,0,0,.14); }
.wm-sl-btn svg    { width: 18px; height: 18px; }
.wm-sl-prev { left: 4px; }
.wm-sl-next { right: 4px; }
.wm-sl-btn.wm-disabled { opacity: .3; pointer-events: none; }

.wm-slider-dots {
  display: flex;
  justify-content: center;
  gap: 7px;
  margin-top: 24px;
}
.wm-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  border: none;
  background: var(--wm-line);
  padding: 0;
  transition: background .2s, transform .2s, width .2s;
  cursor: pointer;
}
.wm-dot.wm-active {
  background: var(--wm-gold);
  width: 22px;
  border-radius: 4px;
}

/* ══════════════════════════════════════════════════════
   [wm_shop] WRAPPER
══════════════════════════════════════════════════════ */
.wm-shop-root {
  max-width: 1400px;
  margin: 0 auto;
  padding: 48px 40px 80px;
}

/* ── Filter bar ── */
.wm-shop-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.97);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--wm-line);
  margin: 0 -40px;
  padding: 0 40px;
}
.wm-shop-bar-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 0;
  flex-wrap: wrap;
}

/* Category chips */
.wm-shop-cats {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
  flex: 1;
  min-width: 0;
  -webkit-overflow-scrolling: touch;
  /* fade edge on right */
  -webkit-mask-image: linear-gradient(to right, #000 85%, transparent 100%);
  mask-image: linear-gradient(to right, #000 85%, transparent 100%);
}
.wm-shop-cats::-webkit-scrollbar { display: none; }

.wm-cat-chip {
  background: none;
  border: 1.5px solid transparent;
  border-radius: 30px;
  padding: 7px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--wm-muted);
  white-space: nowrap;
  flex-shrink: 0;
  transition: all .18s;
  line-height: 1;
}
.wm-cat-chip:hover     { color: var(--wm-ink); border-color: var(--wm-line); }
.wm-cat-chip.wm-active { background: var(--wm-ink); color: #fff; border-color: var(--wm-ink); }

/* Right controls */
.wm-shop-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.wm-filter-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--wm-ink);
  background: none;
  border: 1.5px solid var(--wm-line);
  border-radius: 6px;
  padding: 8px 14px;
  transition: border-color .2s, background .2s;
  white-space: nowrap;
}
.wm-filter-btn:hover  { border-color: var(--wm-gold); }
.wm-filter-btn.wm-open {
  border-color: var(--wm-gold);
  background: var(--wm-gold-bg);
  color: var(--wm-gold-dark);
}
.wm-filter-btn svg              { width: 15px; height: 15px; }
.wm-filter-btn .wm-chevron      { width: 13px; height: 13px; transition: transform .25s; }
.wm-filter-btn.wm-open .wm-chevron { transform: rotate(180deg); }

.wm-sort-wrap { display: flex; align-items: center; gap: 0; }
.wm-sort-select {
  font-size: 13px;
  font-family: 'Inter', sans-serif;
  font-weight: 500;
  color: var(--wm-ink);
  border: 1.5px solid var(--wm-line);
  border-radius: 6px;
  padding: 8px 32px 8px 12px;
  background: #fff 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='%23374151' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 10px center;
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
  outline: none;
  transition: border-color .2s;
}
.wm-sort-select:focus { border-color: var(--wm-gold); }

.wm-view-toggle { display: flex; gap: 3px; }
.wm-view-btn {
  width: 34px; height: 34px;
  border: 1.5px solid var(--wm-line);
  border-radius: 6px;
  background: none;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--wm-muted);
  transition: all .15s;
}
.wm-view-btn:hover    { border-color: var(--wm-ink); color: var(--wm-ink); }
.wm-view-btn.wm-active { background: var(--wm-ink); color: #fff; border-color: var(--wm-ink); }
.wm-view-btn svg      { width: 13px; height: 13px; }

/* ── Price panel ── */
.wm-price-panel {
  overflow: hidden;
  max-height: 0;
  transition: max-height .35s cubic-bezier(.4,0,.2,1);
  border-top: 0px solid var(--wm-line);
}
.wm-price-panel.wm-panel-open {
  max-height: 320px;
  border-top-width: 1px;
}
.wm-price-panel-inner {
  padding: 24px 0 20px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Number inputs row */
.wm-price-inputs-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.wm-price-input-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
  flex: 1;
}
.wm-price-input-label {
  font-size: 11px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--wm-muted);
  font-weight: 600;
}
.wm-price-input-wrap {
  display: flex;
  align-items: center;
  border: 1.5px solid var(--wm-line);
  border-radius: 6px;
  overflow: hidden;
  transition: border-color .2s;
}
.wm-price-input-wrap:focus-within { border-color: var(--wm-gold); }
.wm-price-symbol {
  padding: 9px 8px 9px 12px;
  font-size: 14px;
  font-weight: 600;
  color: var(--wm-muted);
  background: var(--wm-line-soft);
  border-right: 1px solid var(--wm-line);
  line-height: 1;
}
.wm-price-number-input {
  flex: 1;
  border: none;
  outline: none;
  padding: 9px 10px;
  font-size: 14px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  color: var(--wm-ink);
  background: #fff;
  width: 0;
  min-width: 0;
  -moz-appearance: textfield;
}
.wm-price-number-input::-webkit-outer-spin-button,
.wm-price-number-input::-webkit-inner-spin-button { -webkit-appearance: none; }
.wm-price-sep { color: var(--wm-muted); font-size: 18px; font-weight: 300; flex-shrink: 0; }

/* Dual range */
.wm-dual-range-wrap {
  position: relative;
  height: 36px;
  padding: 0 0;
}
.wm-range-track-bg {
  position: absolute;
  left: 0; right: 0;
  top: 50%; transform: translateY(-50%);
  height: 4px;
  background: var(--wm-line);
  border-radius: 2px;
  pointer-events: none;
}
.wm-range-fill {
  position: absolute;
  height: 100%;
  background: var(--wm-gold);
  border-radius: 2px;
  transition: left .05s, right .05s;
}
.wm-range-input {
  position: absolute;
  width: 100%;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  -webkit-appearance: none;
  appearance: none;
  height: 4px;
  outline: none;
  pointer-events: none;
  margin: 0;
}
.wm-range-input::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px; height: 22px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--wm-gold);
  box-shadow: 0 2px 8px rgba(0,0,0,.15), 0 0 0 0 rgba(195,155,97,.3);
  cursor: grab;
  pointer-events: all;
  transition: box-shadow .2s, transform .15s;
}
.wm-range-input::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 2px 8px rgba(0,0,0,.2), 0 0 0 6px rgba(195,155,97,.18);
}
.wm-range-input:active::-webkit-slider-thumb { cursor: grabbing; }
.wm-range-input::-moz-range-thumb {
  width: 22px; height: 22px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--wm-gold);
  box-shadow: 0 2px 8px rgba(0,0,0,.15);
  cursor: grab;
  pointer-events: all;
}

/* Quick presets */
.wm-price-presets {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.wm-preset-label {
  font-size: 11.5px;
  color: var(--wm-muted);
  font-weight: 500;
  white-space: nowrap;
}
.wm-preset-btn {
  font-size: 12px;
  font-weight: 500;
  padding: 5px 12px;
  border: 1.5px solid var(--wm-line);
  border-radius: 20px;
  background: none;
  color: var(--wm-text);
  white-space: nowrap;
  transition: all .15s;
}
.wm-preset-btn:hover,
.wm-preset-btn.wm-active { border-color: var(--wm-gold); background: var(--wm-gold-bg); color: var(--wm-gold-dark); }

/* Price actions */
.wm-price-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.wm-price-clear-btn {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--wm-muted);
  background: none;
  border: 1.5px solid var(--wm-line);
  border-radius: 6px;
  padding: 10px 18px;
  transition: all .2s;
}
.wm-price-clear-btn:hover { color: var(--wm-red); border-color: var(--wm-red); }
.wm-price-apply-btn {
  flex: 1;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: #fff;
  background: var(--wm-ink);
  border: none;
  border-radius: 6px;
  padding: 11px 20px;
  transition: background .2s;
}
.wm-price-apply-btn:hover { background: var(--wm-gold-dark); }

/* ── Active filters ── */
.wm-active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 16px 0 0;
}
.wm-filter-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 500;
  background: var(--wm-gold-bg);
  border: 1px solid rgba(195,155,97,.3);
  border-radius: 30px;
  padding: 5px 10px 5px 14px;
  color: var(--wm-gold-dark);
  animation: wmTagIn .2s ease;
}
@keyframes wmTagIn { from { opacity:0; transform:scale(.9); } to { opacity:1; transform:scale(1); } }
.wm-filter-tag button {
  background: none; border: none; padding: 0;
  font-size: 14px; line-height: 1; cursor: pointer;
  color: var(--wm-gold);
  display: flex; align-items: center;
  transition: color .15s;
}
.wm-filter-tag button:hover { color: var(--wm-red); }

/* ── Results bar ── */
.wm-shop-results-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0 16px;
  border-bottom: 1px solid var(--wm-line-soft);
  margin-bottom: 28px;
}
.wm-results-count { font-size: 13px; color: var(--wm-muted); }

/* ── Loading ── */
.wm-shop-grid-wrap { position: relative; min-height: 280px; }
.wm-shop-loader {
  display: none;
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,.8);
  z-index: 10;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
}
.wm-shop-loader.wm-visible { display: flex; }
.wm-spin {
  width: 34px; height: 34px;
  border: 3px solid var(--wm-line);
  border-top-color: var(--wm-gold);
  border-radius: 50%;
  animation: wmSpin .7s linear infinite;
}
@keyframes wmSpin { to { transform: rotate(360deg); } }

/* ── Pagination ── */
.wm-shop-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 5px;
  padding: 48px 0 0;
  flex-wrap: wrap;
}
.wm-page-btn {
  min-width: 38px; height: 38px;
  border: 1.5px solid var(--wm-line);
  border-radius: 6px;
  background: none;
  font-size: 13.5px;
  font-weight: 500;
  color: var(--wm-ink);
  padding: 0 10px;
  transition: all .15s;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.wm-page-btn:hover:not(.wm-disabled):not(.wm-active) { border-color: var(--wm-gold); color: var(--wm-gold-dark); }
.wm-page-btn.wm-active   { background: var(--wm-ink); color: #fff; border-color: var(--wm-ink); }
.wm-page-btn.wm-disabled { opacity: .3; pointer-events: none; }
.wm-page-ellipsis { font-size: 14px; color: var(--wm-muted); padding: 0 2px; }

/* ══════════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════════ */

/* 1100px — drop to 3 cols */
@media (max-width: 1100px) {
  .wm-cols-4 { grid-template-columns: repeat(3, 1fr); }
  .wm-shop-root { padding: 40px 28px 60px; }
  .wm-shop-bar  { margin: 0 -28px; padding: 0 28px; }
}

/* 860px — 2 col grid, stack filter bar */
@media (max-width: 860px) {
  .wm-cols-3,
  .wm-cols-4 { grid-template-columns: repeat(2, 1fr); }
  .wm-pg-grid { gap: 28px 14px; }

  /* Filter bar: chips on own row */
  .wm-shop-bar-inner { padding: 10px 0; gap: 0; flex-direction: column; align-items: stretch; }
  .wm-shop-cats {
    padding: 12px 0;
    -webkit-mask-image: linear-gradient(to right, #000 80%, transparent 100%);
    mask-image: linear-gradient(to right, #000 80%, transparent 100%);
    border-bottom: 1px solid var(--wm-line);
    margin-bottom: 0;
  }
  .wm-shop-controls {
    padding: 12px 0 2px;
    justify-content: space-between;
    width: 100%;
  }
  .wm-view-toggle { display: none; }
  .wm-price-panel.wm-panel-open { max-height: 420px; }
}

/* 640px — mobile */
@media (max-width: 640px) {
  .wm-pg-section { padding: 36px 16px; }
  .wm-pg-heading { flex-direction: column; align-items: flex-start; gap: 12px; margin-bottom: 28px; }
  .wm-pg-view-all { margin-bottom: 0; }

  .wm-shop-root { padding: 28px 16px 56px; }
  .wm-shop-bar  { margin: 0 -16px; padding: 0 16px; }

  .wm-cat-chip  { padding: 6px 13px; font-size: 12.5px; }

  .wm-price-inputs-row { gap: 8px; }
  .wm-price-panel-inner { padding: 18px 0 16px; gap: 16px; }

  .wm-slider-outer { padding: 0 36px; }

  .wm-pg-cta-row { margin-top: 40px; }
  .wm-pg-cta { padding: 13px 28px; font-size: 12px; }
}

/* 480px — 2 col always, smaller text */
@media (max-width: 480px) {
  .wm-cols-2,
  .wm-cols-3,
  .wm-cols-4 { grid-template-columns: repeat(2, 1fr); }
  .wm-pg-grid { gap: 22px 10px; }
  .wm-pg-card-name { font-size: 14.5px; }
  .wm-pg-price-current { font-size: 14px; }
  .wm-pg-badge { font-size: 9.5px; padding: 3px 8px; }

  .wm-price-presets { gap: 6px; }
  .wm-preset-btn { font-size: 11.5px; padding: 4px 10px; }

  .wm-price-actions { flex-direction: column; }
  .wm-price-clear-btn,
  .wm-price-apply-btn { width: 100%; text-align: center; }

  .wm-slider-outer { padding: 0 28px; }
  .wm-sl-btn { width: 32px; height: 32px; }
  .wm-sl-btn svg { width: 14px; height: 14px; }
}
