/* OTLY 869 — Archive Category Filter Grid */

/* Suppress WoodMart native loop when OTLY grid is present */
/* Prevent horizontal scrollbar jump when hero uses viewport breakout. */
body.otly-archive-has-grid,
body.otly-archive-has-hero {
  overflow-x: clip;
}

.otly-archive-has-grid .wd-products-holder,
.otly-archive-has-grid .products.wd-products,
.otly-archive-has-grid ul.products,
.otly-archive-has-grid .woocommerce-result-count,
.otly-archive-has-grid .woocommerce-ordering {
  display: none !important;
}

.otly-cg-wrap {
  position: relative;
  background: var(--otly-archive-beige, #f9f8f6);
  padding: 0 0 80px;
  box-sizing: border-box;
}

.otly-cg-wrap.otly-container {
  padding-left: var(--otly-sp-32, 32px);
  padding-right: var(--otly-sp-32, 32px);
}

.elementor-widget-otly_category_grid {
  width: 100% !important;
  max-width: 100% !important;
}

.otly-cg-wrap--filter-open {
  overflow: hidden;
}

.otly-cg {
  position: relative;
  padding: 28px 0 0;
  background: transparent;
}

/* ── COLLECTION NAVIGATION (sitewide category tabs) ───────── */
.elementor-widget-otly_category_grid .otly-cg__tab,
.elementor-widget-otly_category_grid a.otly-cg__tab,
.elementor-widget-otly_category_grid button.otly-cg__tab {
  text-transform: none !important;
  letter-spacing: 0.02em !important;
  border-radius: 999px !important;
  font-family: 'Inter', sans-serif !important;
  box-shadow: none !important;
}

.elementor-widget-otly_category_grid .otly-cg__tab.is-active,
.elementor-widget-otly_category_grid a.otly-cg__tab.is-active,
.elementor-widget-otly_category_grid button.otly-cg__tab.is-active {
  border-radius: 999px !important;
}

.elementor-widget-otly_category_grid .otly-cg--nav-bar .otly-cg__tab-icon--upload svg,
.elementor-widget-otly_category_grid .otly-cg--nav-bar .otly-cg__tab-icon--upload img {
  width: 20px !important;
  height: 20px !important;
  max-width: 20px !important;
  max-height: 20px !important;
}

.otly-cg-wrap--collection-nav .otly-cg__tabs-wrap {
  --otly-nav-gap: 22px;
  --otly-nav-text: #5a5a56;
  --otly-nav-text-active: #1b1c18;
}

.otly-cg__tabs-wrap {
  margin-bottom: 28px;
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scroll-behavior: smooth;
  scroll-snap-type: x proximity;
  scroll-padding-inline: var(--otly-cg-ui-pad-x, 20px);
  scrollbar-width: none;
  padding: 4px 0 12px;
  position: relative;
  mask-image: linear-gradient(
    to right,
    transparent 0,
    #000 24px,
    #000 calc(100% - 24px),
    transparent 100%
  );
}

.otly-cg__tabs-wrap::-webkit-scrollbar {
  display: none;
}

.otly-cg__tabs-wrap.is-scroll-start {
  mask-image: linear-gradient(to right, #000 0, #000 calc(100% - 24px), transparent 100%);
}

.otly-cg__tabs-wrap.is-scroll-end {
  mask-image: linear-gradient(to right, transparent 0, #000 24px, #000 100%);
}

.otly-cg__tabs-wrap.is-scroll-start.is-scroll-end {
  mask-image: none;
}

.otly-cg__tabs-track {
  width: 100%;
  background: transparent;
  border: none;
  padding: 0 6px;
  border-radius: 0;
  box-sizing: border-box;
}

.otly-cg__tabs {
  display: flex;
  gap: var(--otly-nav-gap, 18px);
  flex-wrap: nowrap;
  min-width: max-content;
  padding-inline: 2px;
  align-items: center;
}

.otly-cg__tab,
a.otly-cg__tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: var(--otly-nav-pad-y, 6px) var(--otly-nav-pad-x, 14px);
  min-height: 32px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 400;
  font-family: 'Inter', sans-serif;
  color: var(--otly-nav-text, #4a4a46);
  background: transparent;
  border: 1px solid transparent;
  cursor: pointer;
  transition:
    background 0.28s ease,
    color 0.28s ease,
    border-color 0.28s ease;
  white-space: nowrap;
  scroll-snap-align: center;
  text-transform: none;
  letter-spacing: 0.02em;
  flex-shrink: 0;
  text-decoration: none;
  box-sizing: border-box;
  line-height: 1.3;
  box-shadow: none;
}

.otly-cg__tab--long {
  letter-spacing: 0.015em;
}

.otly-cg__tab--long .otly-cg__tab-text {
  font-size: 12px;
}

/* ── Bar navigation (reference: icon wells + gray track) ─── */
.otly-cg--nav-bar .otly-cg__tabs-wrap {
  --otly-nav-well-size: 34px;
  --otly-nav-icon-size: 20px;
  --otly-nav-active-bg: #3d3f3a;
  --otly-nav-active-border: #3d3f3a;
  --otly-nav-gap: 22px;
  overflow: visible;
  mask-image: none;
}

.otly-cg--nav-bar .otly-cg__tabs-wrap.is-scroll-start,
.otly-cg--nav-bar .otly-cg__tabs-wrap.is-scroll-end,
.otly-cg--nav-bar .otly-cg__tabs-wrap.is-scroll-start.is-scroll-end {
  mask-image: none;
}

.otly-cg--nav-bar .otly-cg__tabs-track {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  background: #eceae4;
  border-radius: 14px;
  padding: 10px 14px;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-x: contain;
  scroll-behavior: smooth;
  scroll-snap-type: x proximity;
  scrollbar-width: none;
  position: relative;
  mask-image: linear-gradient(
    to right,
    transparent 0,
    #000 20px,
    #000 calc(100% - 20px),
    transparent 100%
  );
}

.otly-cg--nav-bar .otly-cg__tabs-track::-webkit-scrollbar {
  display: none;
}

.otly-cg--nav-bar .otly-cg__tabs-track.is-scroll-start {
  mask-image: linear-gradient(to right, #000 0, #000 calc(100% - 20px), transparent 100%);
}

.otly-cg--nav-bar .otly-cg__tabs-track.is-scroll-end {
  mask-image: linear-gradient(to right, transparent 0, #000 20px, #000 100%);
}

.otly-cg--nav-bar .otly-cg__tabs-track.is-scroll-start.is-scroll-end {
  mask-image: none;
}

.otly-cg--nav-bar .otly-cg__tabs {
  gap: var(--otly-nav-gap, 22px);
}

.otly-cg--nav-bar .otly-cg__tab,
.otly-cg--nav-bar a.otly-cg__tab {
  gap: 10px;
  padding: 4px 0;
  min-height: 36px;
  color: var(--otly-nav-text, #5a5a56);
  background: transparent;
  border-color: transparent;
}

.otly-cg--nav-bar .otly-cg__tab:hover:not(.is-active) {
  color: var(--otly-nav-text-active, #1b1c18);
  background: transparent;
}

.otly-cg--nav-bar .otly-cg__tab.is-active,
.otly-cg--nav-bar a.otly-cg__tab.is-active {
  background: var(--otly-nav-active-bg, #3d3f3a) !important;
  color: #fff !important;
  border-color: var(--otly-nav-active-border, #3d3f3a) !important;
  font-weight: 500;
  padding: 8px 18px 8px 10px;
  box-shadow: none !important;
}

.otly-cg--nav-bar .otly-cg__tab-icon {
  width: var(--otly-nav-well-size, 32px);
  height: var(--otly-nav-well-size, 32px);
  min-width: var(--otly-nav-well-size, 32px);
  min-height: var(--otly-nav-well-size, 32px);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: #fff;
  border-radius: 50%;
  opacity: 1;
  color: #4a4a46;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.otly-cg--nav-bar .otly-cg__tab.is-active .otly-cg__tab-icon {
  opacity: 1;
  color: #3d3f3a;
  background: #fff;
}

.otly-cg--nav-bar .otly-cg__tab.is-loading .otly-cg__tab-icon {
  position: relative;
}

.otly-cg--nav-bar .otly-cg__tab.is-loading .otly-cg__tab-icon::after {
  content: '';
  position: absolute;
  inset: -3px;
  border: 2px solid rgba(61, 63, 58, 0.15);
  border-top-color: #3d3f3a;
  border-radius: 50%;
  animation: otly-spin 0.65s linear infinite;
  pointer-events: none;
}

.otly-cg--nav-bar .otly-cg__tab.is-active.is-loading .otly-cg__tab-icon::after {
  border-color: rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
}

.otly-cg--nav-bar .otly-cg__tab-icon-svg {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--otly-nav-icon-size, 20px);
  height: var(--otly-nav-icon-size, 20px);
}

.otly-cg--nav-bar .otly-cg__tab-icon-svg svg {
  width: var(--otly-nav-icon-size, 20px);
  height: var(--otly-nav-icon-size, 20px);
  max-width: var(--otly-nav-icon-size, 20px);
  max-height: var(--otly-nav-icon-size, 20px);
  stroke-width: 1.45;
}

.otly-cg--nav-bar .otly-cg__tab-icon--upload {
  width: var(--otly-nav-well-size, 32px);
  height: var(--otly-nav-well-size, 32px);
  min-width: var(--otly-nav-well-size, 32px);
  min-height: var(--otly-nav-well-size, 32px);
  opacity: 1;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.otly-cg--nav-bar .otly-cg__tab-icon--upload .otly-cg__tab-icon-img,
.otly-cg--nav-bar .otly-cg__tab-icon--upload img,
.otly-cg--nav-bar .otly-cg__tab-icon--upload svg {
  max-width: var(--otly-nav-icon-size, 18px);
  max-height: var(--otly-nav-icon-size, 18px);
}

/* ── Minimal navigation (text-first, small icons) ────────── */
.otly-cg--nav-minimal .otly-cg__tabs-wrap {
  --otly-nav-pad-y: 6px;
  --otly-nav-pad-x: 14px;
  --otly-nav-pad-icon: 10px;
  --otly-nav-active-bg: rgba(45, 45, 45, 0.07);
  --otly-nav-active-border: rgba(45, 45, 45, 0.14);
  --otly-nav-icon-size: 12px;
  --otly-nav-icon-opacity: 0.38;
  --otly-nav-icon-opacity-active: 0.55;
}

.otly-cg--nav-minimal .otly-cg__tab,
.otly-cg--nav-minimal a.otly-cg__tab {
  padding: var(--otly-nav-pad-y, 6px) var(--otly-nav-pad-x, 14px) var(--otly-nav-pad-y, 6px) var(--otly-nav-pad-icon, 10px);
}

.otly-cg--nav-minimal .otly-cg__tab:hover:not(.is-active) {
  color: var(--otly-nav-text-active, #1b1c18);
  background: rgba(45, 45, 45, 0.04);
  border-color: transparent;
}

.otly-cg--nav-minimal .otly-cg__tab.is-active {
  background: var(--otly-nav-active-bg) !important;
  color: var(--otly-nav-text-active, #1b1c18) !important;
  border-color: var(--otly-nav-active-border) !important;
  font-weight: 500;
  box-shadow: none !important;
}

.otly-cg__tab-text {
  flex: 0 1 auto;
  min-width: 0;
}

.otly-cg--nav-text-only .otly-cg__tab-icon,
.otly-cg--nav-text-only .otly-cg__tab-icon--upload {
  display: none !important;
}

.otly-cg--nav-text-only .otly-cg__tab,
.otly-cg--nav-text-only a.otly-cg__tab {
  padding-left: var(--otly-nav-pad-x, 14px);
}

.otly-cg__tab-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  order: -1;
  transition: opacity 0.28s ease, color 0.28s ease, background 0.28s ease;
}

.otly-cg--nav-minimal .otly-cg__tab-icon {
  width: var(--otly-nav-icon-size, 12px);
  height: var(--otly-nav-icon-size, 12px);
  min-width: var(--otly-nav-icon-size, 12px);
  min-height: var(--otly-nav-icon-size, 12px);
  background: transparent;
  color: inherit;
  opacity: var(--otly-nav-icon-opacity, 0.38);
}

.otly-cg--nav-minimal .otly-cg__tab:hover:not(.is-active) .otly-cg__tab-icon {
  opacity: calc(var(--otly-nav-icon-opacity, 0.38) + 0.12);
}

.otly-cg--nav-minimal .otly-cg__tab.is-active .otly-cg__tab-icon {
  opacity: var(--otly-nav-icon-opacity-active, 0.55);
  color: inherit;
}

.otly-cg__tab-icon-svg {
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 0;
}

.otly-cg--nav-minimal .otly-cg__tab-icon-svg,
.otly-cg--nav-minimal .otly-cg__tab-icon-svg svg {
  width: var(--otly-nav-icon-size, 12px);
  height: var(--otly-nav-icon-size, 12px);
  max-width: var(--otly-nav-icon-size, 12px);
  max-height: var(--otly-nav-icon-size, 12px);
}

.otly-cg__tab-icon-svg svg {
  stroke: currentColor;
  fill: none;
  stroke-width: 1.35;
  stroke-linecap: round;
  stroke-linejoin: round;
  display: block;
}

.otly-cg__tab-icon-svg svg [fill='currentColor'] {
  fill: currentColor;
  stroke: none;
}

.otly-cg--nav-minimal .otly-cg__tab-icon--upload {
  background: transparent;
  overflow: hidden;
  opacity: var(--otly-nav-icon-opacity, 0.38);
  width: var(--otly-nav-icon-size, 12px);
  height: var(--otly-nav-icon-size, 12px);
  min-width: var(--otly-nav-icon-size, 12px);
  min-height: var(--otly-nav-icon-size, 12px);
}

.otly-cg--nav-minimal .otly-cg__tab.is-active .otly-cg__tab-icon--upload {
  opacity: var(--otly-nav-icon-opacity-active, 0.55);
}

.otly-cg--nav-minimal .otly-cg__tab-icon--upload .otly-cg__tab-icon-img,
.otly-cg--nav-minimal .otly-cg__tab-icon--upload img,
.otly-cg--nav-minimal .otly-cg__tab-icon--upload svg {
  width: 100%;
  height: 100%;
  max-width: var(--otly-nav-icon-size, 12px);
  max-height: var(--otly-nav-icon-size, 12px);
  object-fit: contain;
  display: block;
  margin: auto;
}

@media (max-width: 767px) {
  .otly-cg-wrap--collection-nav .otly-cg__tabs-wrap {
    scroll-snap-type: x mandatory;
  }

  .otly-cg__tabs-wrap {
    scroll-padding-inline: var(--otly-cg-ui-pad-x, 16px);
    margin-bottom: 24px;
    mask-image: none;
  }

  .otly-cg__tabs-wrap.is-scroll-start,
  .otly-cg__tabs-wrap.is-scroll-end,
  .otly-cg__tabs-wrap.is-scroll-start.is-scroll-end {
    mask-image: none;
  }

  .otly-cg--nav-bar .otly-cg__tabs-wrap {
    --otly-nav-well-size: 38px;
    --otly-nav-icon-size: 22px;
    --otly-nav-gap: 18px;
    padding-bottom: 14px;
    overflow: visible;
  }

  .otly-cg-wrap--collection-nav .otly-cg--nav-bar .otly-cg__tabs-track {
    scroll-snap-type: x mandatory;
  }

  .otly-cg--nav-bar .otly-cg__tab,
  .otly-cg--nav-bar a.otly-cg__tab {
    scroll-snap-align: center;
  }

  .otly-cg--nav-bar .otly-cg__tabs-track {
    padding: 12px 16px;
    border-radius: 16px;
    scroll-padding-inline: 12px;
    mask-image: none;
  }

  .otly-cg--nav-bar .otly-cg__tabs-track.is-scroll-start,
  .otly-cg--nav-bar .otly-cg__tabs-track.is-scroll-end,
  .otly-cg--nav-bar .otly-cg__tabs-track.is-scroll-start.is-scroll-end {
    mask-image: none;
  }

  .otly-cg--nav-bar .otly-cg__tab-icon-svg svg {
    stroke-width: 1.5;
  }

  .otly-cg--nav-bar .otly-cg__tab-icon--upload .otly-cg__tab-icon-img,
  .otly-cg--nav-bar .otly-cg__tab-icon--upload img,
  .otly-cg--nav-bar .otly-cg__tab-icon--upload svg {
    max-width: var(--otly-nav-icon-size, 22px);
    max-height: var(--otly-nav-icon-size, 22px);
  }

  .elementor-widget-otly_category_grid .otly-cg--nav-bar .otly-cg__tab-icon--upload svg,
  .elementor-widget-otly_category_grid .otly-cg--nav-bar .otly-cg__tab-icon--upload img {
    width: 22px !important;
    height: 22px !important;
    max-width: 22px !important;
    max-height: 22px !important;
  }

  .otly-cg--nav-bar .otly-cg__tab.is-active,
  .otly-cg--nav-bar a.otly-cg__tab.is-active {
    padding: 10px 16px 10px 10px;
  }

  .otly-cg__tab,
  a.otly-cg__tab {
    min-height: 44px;
    --otly-nav-pad-y: 10px;
    --otly-nav-pad-x: 16px;
    --otly-nav-pad-icon: 12px;
  }

  .otly-cg__tab--long {
    max-width: min(200px, 76vw);
    white-space: normal;
    text-align: center;
    align-items: center;
  }

  .otly-cg__tab--long .otly-cg__tab-text {
    line-height: 1.35;
    font-size: 12px;
  }

  .otly-cg--pills-icon-mobile .otly-cg__tab,
  .otly-cg--pills-icon-mobile a.otly-cg__tab {
    min-width: 44px;
    min-height: 44px;
    padding: 10px 12px;
    justify-content: center;
    gap: 0;
    max-width: none;
    white-space: nowrap;
    background: transparent;
    border-color: transparent;
  }

  .otly-cg--nav-bar.otly-cg--pills-icon-mobile .otly-cg__tab.is-active {
    background: #3d3f3a !important;
    border-color: #3d3f3a !important;
    color: #fff !important;
  }

  .otly-cg--nav-minimal.otly-cg--pills-icon-mobile .otly-cg__tab.is-active {
    background: rgba(45, 45, 45, 0.07) !important;
    border-color: rgba(45, 45, 45, 0.14) !important;
  }

  .otly-cg--nav-bar .otly-cg__tab,
  .otly-cg--nav-bar a.otly-cg__tab {
    min-height: 44px;
  }

  .otly-cg--pills-icon-mobile .otly-cg__tab-text {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }
}

.otly-cg-filter-term__thumb .otly-cg__tab-icon-img,
.otly-cg-filter-term__thumb img,
.otly-cg-filter-term__thumb svg {
  width: 100%;
  height: 100%;
  max-width: 28px;
  max-height: 28px;
  object-fit: contain;
  display: block;
}

.otly-cg-filter-term--cat {
  display: flex;
  align-items: center;
  gap: 10px;
}

.otly-cg-filter-term__thumb {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  overflow: hidden;
  background: #f3f2ee;
}

.otly-cg-filter-term__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ── TOOLBAR ─────────────────────────────────────────────── */
.otly-cg__toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0 20px;
  border-top: 1px solid rgba(45, 45, 45, 0.08);
  border-bottom: 1px solid rgba(45, 45, 45, 0.08);
  margin-bottom: 32px;
  gap: 12px;
  flex-wrap: wrap;
}

.otly-cg--sticky-toolbar .otly-cg__toolbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--otly-archive-beige, #f5f5f0);
  padding: 12px 0;
  margin-bottom: 20px;
}

.otly-cg__toolbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.otly-cg__filter-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: #2d2d2d;
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  line-height: 1;
  margin-left: 2px;
}

.otly-cg__filter-count[hidden] {
  display: none !important;
}

.otly-cg__toolbar-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-left: auto;
}

.otly-cg__filter-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 14px;
  border: 1.5px solid #d8d6cf;
  border-radius: 4px;
  font-size: 13px;
  font-family: 'Inter', sans-serif;
  color: #2d2d2d;
  background: transparent;
  cursor: pointer;
  transition: border-color 0.2s ease;
}

.otly-cg__filter-btn:hover {
  border-color: #2d2d2d;
}

.otly-cg__chevron {
  transition: transform 0.2s ease;
}

.otly-cg__filter-btn[aria-expanded="true"] .otly-cg__chevron {
  transform: rotate(180deg);
}

.otly-cg__count {
  font-size: 13px;
  color: #888;
  white-space: nowrap;
}

.otly-cg--grid-loading .otly-cg__count-num {
  opacity: 0.45;
}

/* ── SORT LIST (visible pills) ───────────────────────────── */
.otly-cg__sort-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-family: 'Inter', sans-serif;
  color: #2d2d2d;
  flex-wrap: wrap;
}

.otly-cg__sort-label {
  font-size: 13px;
  color: #2d2d2d;
  white-space: nowrap;
  font-weight: 500;
}

.otly-cg__sort-list {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
}

.otly-cg__sort-btn {
  display: inline-flex;
  align-items: center;
  padding: 5px 12px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 12px;
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  color: #6b6b66;
  background: transparent;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  white-space: nowrap;
  line-height: 1.4;
}

.otly-cg__sort-btn:hover {
  color: #2d2d2d;
  background: rgba(45, 45, 45, 0.06);
}

.otly-cg__sort-btn.is-active {
  color: #fff;
  background: #2d2d2d;
  border-color: #2d2d2d;
  font-weight: 500;
}

/* ── VIEW SWITCH (grid/list selector) ────────────────────── */
.otly-cg__view-switch {
  display: inline-flex;
  align-items: center;
  position: relative;
  gap: 0;
  padding: 3px;
  background: #e8e7e1;
  border: 1px solid #d8d6cf;
  border-radius: 8px;
}

.otly-cg__view-pill {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 42px;
  height: 42px;
  background: #2d2d2d;
  border-radius: 6px;
  pointer-events: none;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
  z-index: 0;
}

.otly-cg__view-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border: none;
  border-radius: 6px;
  background: transparent;
  color: #8a8a82;
  cursor: pointer;
  padding: 0;
  z-index: 1;
  font-family: "woodmart-font" !important;
  font-size: 22px;
  font-weight: 400;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
  transition: background 0.25s ease, color 0.25s ease;
  touch-action: manipulation;
}

.otly-cg__view-btn:hover:not(.is-active) {
  background: #ffffff;
  color: #2d2d2d;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
}

.otly-cg__view-btn.is-active:hover {
  background: #ffffff;
  color: #2d2d2d;
  box-shadow: none;
}

.otly-cg__view-btn.is-active {
  background: #2d2d2d;
  color: #ffffff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.otly-cg__view-btn[data-cols="4"]::before { content: "\f12d" !important; }
.otly-cg__view-btn[data-cols="3"]::before { content: "\f12c" !important; }
.otly-cg__view-btn[data-cols="2"]::before { content: "\f12b" !important; }
.otly-cg__view-btn[data-cols="1"]::before { content: "\f12a" !important; }
.otly-cg__view-btn[data-view="list"]::before { content: "\f13" !important; }

.otly-cg__view-btn[data-cols="1"] {
  display: none;
}

.otly-cg__view-btn::before {
  display: block !important;
  font-family: "woodmart-font" !important;
  font-size: 22px;
  font-weight: 400;
  line-height: 1;
  color: #8a8a82;
  transition: color 0.25s ease;
  pointer-events: none;
}

.otly-cg__view-btn.is-active::before {
  color: #ffffff !important;
}

.otly-cg__view-btn.is-active:hover::before {
  color: #2d2d2d !important;
}

.otly-cg__view-btn:hover:not(.is-active)::before {
  color: #2d2d2d !important;
}

/* ── MOBILE ─────────────────────────────────────────────── */
@media (max-width: 768px) {
  .otly-cg__view-switch {
    display: none !important;
  }
  .otly-cg__toolbar {
    flex-wrap: wrap;
    gap: 10px;
  }
  .otly-cg__toolbar-left {
    order: 1;
    flex: 1 1 100%;
  }
  .otly-cg__toolbar-right {
    order: 2;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: nowrap;
  }
}

.otly-cg__view-btn.is-active::before {
  color: #ffffff !important;
}

.otly-cg__view-btn:hover:not(.is-active)::before {
  color: #2d2d2d !important;
}

/* ── LIST VIEW ───────────────────────────────────────────── */
.otly-cg__grid--list-view {
  grid-template-columns: 1fr !important;
  row-gap: 16px;
  column-gap: 0;
}

.otly-cg__grid--list-view .otly-cg-card {
  display: grid;
  grid-template-columns: minmax(140px, 200px) 1fr;
  gap: 24px;
  align-items: start;
}

.otly-cg__grid--list-view .otly-cg-card__img-wrap {
  aspect-ratio: 3 / 4;
  border-radius: 10px;
}

.otly-cg__grid--list-view .otly-cg-card__meta {
  padding-top: 8px;
  gap: 6px;
  justify-content: flex-start;
}

.otly-cg__grid--list-view .otly-cg-card__name {
  font-size: 16px;
  line-height: 1.4;
}

.otly-cg__grid--list-view .otly-cg-card__price {
  font-size: 15px;
}

.otly-cg__grid--list-view .otly-cg-card__actions-zone {
  position: relative;
  bottom: auto;
  left: auto;
  right: auto;
  opacity: 1;
  transform: none;
  pointer-events: auto;
  margin-top: 8px;
}

.otly-cg__grid--list-view .otly-cg-hover-bar {
  border-radius: 6px;
}

.otly-cg__grid--list-view .otly-cg-card__wish {
  position: static;
  opacity: 1;
  transform: none;
  pointer-events: auto;
  margin-top: 4px;
}

@media (max-width: 600px) {
  .otly-cg__grid--list-view .otly-cg-card {
    grid-template-columns: minmax(100px, 140px) 1fr;
    gap: 16px;
  }
}

/* ── GRID ────────────────────────────────────────────────── */
.otly-cg__grid {
  display: grid;
  grid-template-columns: repeat(var(--otly-cg-cols, 4), minmax(0, 1fr));
  row-gap: var(--otly-cg-row-gap, 44px);
  column-gap: var(--otly-cg-col-gap, 24px);
  align-items: stretch;
}

.otly-cg__grid.is-loading,
.otly-cg__grid.is-swapping {
  opacity: 0.58;
  transform: scale(0.996);
  pointer-events: none;
  transition: opacity 0.32s cubic-bezier(0.4, 0, 0.2, 1), transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: opacity, transform;
}

.otly-cg__grid.is-loading.is-skeleton {
  opacity: 1;
  transform: none;
}

.otly-cg-card--skeleton {
  pointer-events: none;
}

.otly-cg-card--skeleton .otly-cg-card__img-wrap {
  aspect-ratio: 3 / 4;
  background: #eceae4;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
}

.otly-cg-skeleton__shimmer,
.otly-cg-skeleton__line {
  background: linear-gradient(
    90deg,
    rgba(236, 234, 228, 0.9) 0%,
    rgba(250, 249, 246, 1) 45%,
    rgba(236, 234, 228, 0.9) 90%
  );
  background-size: 220% 100%;
  animation: otly-shimmer 1.15s ease-in-out infinite;
}

.otly-cg-skeleton__shimmer {
  position: absolute;
  inset: 0;
}

.otly-cg-skeleton__line {
  height: 11px;
  border-radius: 6px;
  margin-top: 14px;
}

.otly-cg-skeleton__line--title {
  width: 72%;
}

.otly-cg-skeleton__line--price {
  width: 38%;
  margin-top: 10px;
  animation-delay: 0.12s;
}

.otly-cg__grid.is-revealing .otly-cg-card:not(.otly-cg-card--skeleton) {
  animation: otly-card-in 0.42s cubic-bezier(0.22, 1, 0.36, 1) backwards;
}

@keyframes otly-shimmer {
  0% { background-position: 120% 0; }
  100% { background-position: -120% 0; }
}

@keyframes otly-card-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.otly-cg__empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 24px;
  font-size: 15px;
  color: var(--otly-text-2);
}

/* ── PRODUCT CARD (reference layout) ───────────────────────── */
.otly-cg-card {
  display: flex;
  flex-direction: column;
  background: transparent;
  position: relative;
  min-width: 0;
  width: 100%;
  box-sizing: border-box;
  padding-left: var(--otly-cg-card-pad-x, 0);
  padding-right: var(--otly-cg-card-pad-x, 0);
}

.otly-cg-card__img-wrap {
  position: relative;
  overflow: hidden;
  background: #f3f2ee;
  border-radius: 12px;
  flex-shrink: 0;
  line-height: 0;
}

.otly-cg-card--ratio-3-4 .otly-cg-card__img-wrap { aspect-ratio: 3 / 4; }
.otly-cg-card--ratio-1-1 .otly-cg-card__img-wrap { aspect-ratio: 1 / 1; }
.otly-cg-card--ratio-4-5 .otly-cg-card__img-wrap { aspect-ratio: 4 / 5; }

.otly-cg-card__img-link {
  display: block;
  position: absolute;
  inset: 0;
  z-index: 1;
  line-height: 0;
  overflow: hidden;
  border-radius: inherit;
}

.otly-cg-card__media {
  position: absolute;
  inset: 0;
  display: block;
  transform: translate3d(var(--otly-tx, 0px), var(--otly-ty, 0px), 0) scale(var(--otly-media-scale, 1));
  transition: transform 0.38s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

@media (hover: hover) and (pointer: fine) {
  .otly-cg-card:hover .otly-cg-card__media {
    --otly-media-scale: 1.035;
  }

  .otly-cg-card--has-hover:hover .otly-cg-card__media {
    --otly-media-scale: 1;
  }
}

.otly-cg-card__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  display: block;
  transform: scale(1) translateZ(0);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

.otly-cg-card__img--primary {
  z-index: 1;
  transition:
    opacity 0.48s cubic-bezier(0.25, 0.1, 0.25, 1),
    transform 1.65s cubic-bezier(0, 0, 0.35, 1);
}

.otly-cg-card__img--hover {
  z-index: 2;
  opacity: 0;
  transition:
    opacity 0.48s cubic-bezier(0.25, 0.1, 0.25, 1),
    transform 1.65s cubic-bezier(0, 0, 0.35, 1);
  pointer-events: none;
}

/* WoodMart-like: slow zoom on gallery hover image */
.otly-cg-card--has-hover:hover .otly-cg-card__img--primary {
  opacity: 0;
  transform: scale(1.06) translateZ(0);
}

.otly-cg-card--has-hover:hover .otly-cg-card__img--hover {
  opacity: 1;
  transform: scale(1.09) translateZ(0);
}

@media (hover: hover) and (pointer: fine) {
  .otly-cg-card:not(.otly-cg-card--has-hover):hover .otly-cg-card__img--primary {
    transform: scale(1.05) translateZ(0);
  }
}

.otly-cg-badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 2;
  background: #1b1c18;
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 4px 7px;
  font-family: 'Inter', sans-serif;
  line-height: 1;
  border-radius: 0;
}

.otly-cg-card__wish {
  position: absolute;
  top: 10px;
  right: 10px;
  left: auto;
  bottom: auto;
  z-index: 10;
  margin: 0;
  padding: 0;
  pointer-events: auto;
}

.otly-cg-card__img-wrap .otly-cg-card__wish {
  top: 10px;
  right: 10px;
}

/* Desktop: wishlist fades in on hover (WoodMart-style); touch: always visible */
@media (hover: hover) and (pointer: fine) {
  .otly-cg-card__wish {
    opacity: 0;
    transform: translateY(-8px);
    transition:
      opacity 0.38s cubic-bezier(0.22, 1, 0.36, 1),
      transform 0.42s cubic-bezier(0.22, 1, 0.36, 1);
    pointer-events: none;
  }

  .otly-cg-card:hover .otly-cg-card__wish,
  .otly-cg-card:focus-within .otly-cg-card__wish {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }
}

.otly-cg-card__wish .otly-cg-wishlist-btn,
.otly-cg-card__wish .wd-wishlist-btn {
  margin: 0;
  line-height: 0;
}

.otly-cg-card__wish .wd-wishlist-btn > a {
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 34px !important;
  height: 34px !important;
  min-height: 34px !important;
  border-radius: 50% !important;
  background: #fff !important;
  border: none !important;
  box-shadow: 0 1px 4px rgba(27, 28, 24, 0.12);
  padding: 0 !important;
  text-decoration: none !important;
  color: #2d2d2d !important;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.otly-cg-card__wish .wd-action-text {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.otly-cg-card__wish .wd-action-icon {
  margin: 0 !important;
}

.otly-cg-card__wish .wd-wishlist-btn > a:hover {
  transform: scale(1.08);
  background: #fff !important;
}

.otly-cg-card__wish .wd-wishlist-btn > a.added {
  background: #fff !important;
  color: #c0392b !important;
}

.otly-cg-card__wish .wd-wishlist-btn > a.added .wd-action-icon:before {
  color: #c0392b !important;
}

.otly-cg-card__wish .wd-wishlist-btn > a.loading {
  opacity: 0.55;
  pointer-events: none;
}

/* Bottom action zone (on card image) */
.otly-cg-card__actions-zone {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 6;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity 0.38s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.42s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: none;
}

.otly-cg-card:hover .otly-cg-card__actions-zone,
.otly-cg-card:focus-within .otly-cg-card__actions-zone {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* WoodMart quick shop on archive cards */
.otly-cg-card {
  position: relative;
}

.otly-cg-card.product-type-variable .otly-cg-card__img-wrap.wd-quick-shop {
  position: relative;
}

.otly-cg-card.product.quick-shop-shown,
.otly-cg-card.product.wd-loading-quick-shop {
  z-index: 12;
  overflow: visible;
}

.otly-cg-card.product.quick-shop-shown .otly-cg-card__img-wrap,
.otly-cg-card.product.wd-loading-quick-shop .otly-cg-card__img-wrap {
  overflow: visible;
  z-index: 2;
}

.otly-cg-card.product.quick-shop-shown .otly-cg-card__actions-zone,
.otly-cg-card.product.wd-loading-quick-shop .otly-cg-card__actions-zone {
  opacity: 0;
  pointer-events: none;
}

/* Hide heart while select-options panel is open (avoids clash with Close) */
.otly-cg-card.product.quick-shop-shown .otly-cg-card__wish,
.otly-cg-card.product.wd-loading-quick-shop .otly-cg-card__wish,
.otly-cg-card.otly-cg-card--quick-shop-open .otly-cg-card__wish {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
  opacity: 0 !important;
}

.otly-cg-card .quick-shop-wrapper {
  position: absolute;
  inset: 0;
  z-index: 15;
}

/* Quick shop open: stop parallax / zoom on container */
.otly-cg-card.quick-shop-shown .otly-cg-card__media,
.otly-cg-card.wd-loading-quick-shop .otly-cg-card__media,
.otly-cg-card.otly-cg-card--quick-shop-open .otly-cg-card__media {
  --otly-tx: 0px !important;
  --otly-ty: 0px !important;
  --otly-media-scale: 1 !important;
  transition: transform 0.25s ease;
}

.otly-cg-card .quick-shop-wrapper .quick-shop-close {
  top: 8px;
  right: 8px;
  left: auto;
  z-index: 25;
}

.otly-cg-card .quick-shop-wrapper .wd-sizeguide-btn,
.otly-cg-card .quick-shop-wrapper .wd-open-sizeguide,
.otly-cg-card .quick-shop-wrapper a[href*='wd_sizeguide'],
.otly-cg-card .quick-shop-wrapper a[href*='size-guide'],
.otly-cg-card .wd-open-sizeguide,
.otly-cg-card .wd-sizeguide-btn,
.otly-cg-card .wd-sizeguide-opener,
.otly-cg-card a[href*='size-guide'],
.otly-cg-card #wd_sizeguide {
  display: none !important;
}

.otly-cg-hover-bar {
  position: relative !important;
  top: auto !important;
  left: auto !important;
  right: auto !important;
  bottom: auto !important;
  z-index: 1;
  display: block;
  width: 100%;
  margin: 0;
  padding: 12px 10px;
  border: none;
  border-radius: 0;
  background: rgba(45, 45, 45, 0.94);
  color: #fff !important;
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: none;
  appearance: none;
  -webkit-appearance: none;
  transition:
    background 0.28s cubic-bezier(0.22, 1, 0.36, 1),
    color 0.2s ease,
    opacity 0.25s ease;
}

.otly-cg-hover-bar:hover,
.otly-cg-hover-bar:focus {
  background: rgba(27, 28, 24, 0.98);
  color: #fff !important;
}

.otly-cg-hover-bar:disabled,
.otly-cg-hover-bar.is-disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.otly-cg-hover-bar.loading {
  opacity: 0.65;
  pointer-events: none;
}

.otly-cg-hover-bar.added {
  background: #1b1c18;
}

/* Legacy icon actions (unused) */
.otly-cg-card__actions {
  display: none;
}

.otly-cg-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #fff;
  color: #1b1c18;
  border: none;
  box-shadow: 0 2px 10px rgba(27, 28, 24, 0.14);
  text-decoration: none;
  padding: 0;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.otly-cg-action:hover {
  transform: scale(1.06);
  box-shadow: 0 4px 14px rgba(27, 28, 24, 0.18);
  color: #1b1c18;
}

.otly-cg-action svg {
  display: block;
}

.otly-cg-action.loading {
  opacity: 0.55;
  pointer-events: none;
}

.otly-cg-action.added_to_cart {
  background: #1b1c18;
  color: #fff;
}

.otly-cg-card__meta {
  display: flex;
  flex-direction: column;
  gap: var(--otly-cg-meta-gap, 6px);
  padding-top: var(--otly-cg-meta-pad-top, 16px);
  min-width: 0;
  flex: 1 1 auto;
  position: relative;
  z-index: 2;
}

.otly-cg-swatches {
  display: flex;
  gap: 8px;
  margin-bottom: 2px;
  flex-wrap: wrap;
  min-height: 20px;
}

.otly-cg-swatch {
  width: 20px;
  height: 20px;
  min-width: 20px;
  min-height: 20px;
  border-radius: 50% !important;
  border: 2px solid #fff !important;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.22) !important;
  background-color: var(--otly-swatch, #ccc) !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  display: inline-block !important;
  cursor: pointer;
  padding: 0 !important;
  margin: 0 !important;
  appearance: none !important;
  -webkit-appearance: none !important;
  flex-shrink: 0;
  vertical-align: middle;
  line-height: 0 !important;
  font-size: 0 !important;
  overflow: hidden;
}

.otly-cg-swatch--image {
  background-size: cover !important;
}

.otly-cg-swatch.is-active {
  box-shadow: 0 0 0 1px #1b1c18, 0 0 0 2px #fff !important;
  outline: none !important;
}

.otly-cg-card__name {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: #1b1c18;
  line-height: 1.35;
  margin: 0;
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
  text-decoration: none;
  white-space: normal;
  word-break: break-word;
  overflow: visible;
}

.otly-cg-card__name:hover {
  text-decoration: underline;
}

.otly-cg-card__sub {
  font-size: 12px;
  color: #7a7974;
  font-family: 'Inter', sans-serif;
  margin: 0;
  font-weight: 400;
  line-height: 1.4;
}

.otly-cg-card__price {
  font-size: 15px;
  font-weight: 600;
  color: #1b1c18;
  font-family: 'Inter', sans-serif;
  margin: 0;
  line-height: 1.3;
}

.otly-cg-card__price del {
  color: #aaa;
  font-weight: 400;
  margin-right: 4px;
}

.otly-cg-card__price ins {
  text-decoration: none;
}

.otly-cg-delivery {
  font-size: 12px;
  font-weight: 500;
  font-family: 'Inter', sans-serif;
  letter-spacing: 0.02em;
  text-transform: none;
  color: #6b7562;
  margin: 6px 0 0;
  line-height: 1.45;
}

/* ── LOADING ───────────────────────────────────────────────── */
.otly-cg__loading {
  position: absolute;
  inset: 0;
  background: rgba(245, 245, 240, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 20;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.otly-cg__loading.is-active {
  opacity: 1;
  pointer-events: auto;
}

.otly-cg__spinner {
  width: 28px;
  height: 28px;
  border: 2px solid rgba(27, 28, 24, 0.12);
  border-top-color: #1b1c18;
  border-radius: 50%;
  animation: otly-spin 0.65s linear infinite;
}

@keyframes otly-spin {
  to { transform: rotate(360deg); }
}

/* ── PAGINATION ──────────────────────────────────────────── */
.otly-cg__load-more-wrap {
  text-align: center;
  margin-top: 40px;
}

.otly-cg__load-more {
  display: inline-flex;
  padding: 14px 32px;
  border: 1px solid var(--otly-charcoal, #2d2d2d);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: transparent;
  color: var(--otly-charcoal, #2d2d2d);
  transition: background 0.2s ease, color 0.2s ease;
}

.otly-cg__load-more:hover {
  background: var(--otly-charcoal, #2d2d2d);
  color: #fff;
}

.otly-cg__pagination {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 40px;
  flex-wrap: wrap;
}

.otly-cg__page-btn {
  min-width: 40px;
  height: 40px;
  border: 1px solid var(--otly-border-2);
  border-radius: 8px;
  font-size: 13px;
  background: #fff;
}

.otly-cg__page-btn.is-active {
  background: var(--otly-charcoal, #2d2d2d);
  color: #fff;
  border-color: var(--otly-charcoal, #2d2d2d);
}

/* ── OFFCANVAS (viewport-fixed; portaled to body via JS) ─── */
.otly-cg-offcanvas {
  position: fixed;
  inset: 0;
  z-index: 100050;
  pointer-events: none;
  visibility: hidden;
  font-family: 'Inter', sans-serif;
}

.elementor-editor-active .otly-cg-offcanvas {
  z-index: 100;
}

.otly-cg-offcanvas.is-open,
.otly-cg-offcanvas.is-closing {
  pointer-events: auto;
  visibility: visible;
}

.otly-cg-offcanvas.is-closing {
  pointer-events: none;
}

.otly-cg-offcanvas__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(27, 28, 24, 0.4);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.otly-cg-offcanvas.is-open .otly-cg-offcanvas__backdrop {
  opacity: 1;
}

.otly-cg-offcanvas.is-closing .otly-cg-offcanvas__backdrop {
  opacity: 0;
}

.otly-cg-offcanvas__panel {
  position: absolute;
  top: 0;
  left: 0;
  width: min(400px, 92vw);
  height: 100%;
  background: #fafaf8;
  display: flex;
  flex-direction: column;
  transform: translateX(-100%);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 4px 0 40px rgba(27, 28, 24, 0.12);
}

.otly-cg-offcanvas.is-open .otly-cg-offcanvas__panel {
  transform: translateX(0);
}

.otly-cg-offcanvas.is-closing .otly-cg-offcanvas__panel {
  transform: translateX(-100%);
}

.otly-cg-offcanvas__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 28px 20px;
  border-bottom: 1px solid rgba(45, 45, 45, 0.08);
}

.otly-cg-offcanvas__head h2 {
  margin: 0;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 28px;
  font-weight: 600;
  color: #1b1c18;
  letter-spacing: -0.01em;
}

.otly-cg-offcanvas__close {
  font-size: 32px;
  line-height: 1;
  color: #888;
  padding: 0 4px;
  transition: color 0.2s ease;
}

.otly-cg-offcanvas__close:hover {
  color: #1b1c18;
}

.otly-cg-offcanvas__body {
  flex: 1;
  overflow-y: auto;
  padding: 24px 28px 32px;
}

.otly-cg-filter-group {
  margin-bottom: 32px;
  padding-bottom: 28px;
  border-bottom: 1px solid rgba(45, 45, 45, 0.08);
}

.otly-cg-filter-group:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.otly-cg-filter-group__title {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: #1b1c18;
  margin: 0 0 16px;
}

.otly-cg-filter-price {
  display: flex;
  align-items: center;
  gap: 12px;
}

.otly-cg-filter-price span {
  color: #888;
  font-size: 14px;
}

.otly-cg-filter-price input {
  flex: 1;
  border: 1px solid #d8d6cf;
  border-radius: 4px;
  padding: 12px 14px;
  font-size: 14px;
  font-family: 'Inter', sans-serif;
  color: #1b1c18;
  background: #fff;
  min-width: 0;
}

.otly-cg-filter-price input:focus {
  outline: none;
  border-color: #2d2d2d;
}

.otly-cg-filter-terms {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.otly-cg-filter-terms--colors {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2px;
}

.otly-cg-filter-term {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  color: #2d2d2d;
  margin: 0;
  padding: 8px 0;
  cursor: pointer;
  position: relative;
}

.otly-cg-filter-term input[type="checkbox"] {
  appearance: none;
  width: 18px;
  height: 18px;
  border: 1.5px solid #c8c6bf;
  border-radius: 50%;
  margin: 0;
  flex-shrink: 0;
  background: #fff;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.otly-cg-filter-term input[type="checkbox"]:checked {
  background: #2d2d2d;
  border-color: #2d2d2d;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 10'%3E%3Cpath fill='none' stroke='%23fff' stroke-width='1.8' d='M1 5l3.5 3.5L11 1'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px 8px;
}

.otly-cg-filter-term__label {
  line-height: 1.35;
}

.otly-cg-filter-color {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  cursor: pointer;
  margin: 0;
}

.otly-cg-filter-color input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.otly-cg-filter-color__swatch {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background-color: var(--otly-swatch, #ccc);
  border: 1px solid rgba(0, 0, 0, 0.15);
  flex-shrink: 0;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.otly-cg-filter-color__swatch--light {
  border: 1px solid #c8c6bf;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.06);
}

.otly-cg-filter-color input:checked + .otly-cg-filter-color__swatch {
  box-shadow: 0 0 0 2px #fff, 0 0 0 3px #2d2d2d;
  transform: scale(1.05);
  border-radius: 50%;
}

.otly-cg-filter-term:has(input:checked) {
  background: #2d2d2d;
  color: #fff;
  border-radius: 999px;
  padding: 8px 14px;
}

.otly-cg-filter-term:has(input:checked) .otly-cg-filter-term__label {
  color: #fff;
}

.otly-cg-filter-color__name {
  font-size: 14px;
  color: #2d2d2d;
}

.otly-cg-offcanvas__foot {
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-shrink: 0;
  margin-top: auto;
  padding: 20px 28px 28px;
  border-top: 1px solid rgba(45, 45, 45, 0.08);
  background: #fafaf8;
}

.otly-cg-offcanvas__clear,
.otly-cg-offcanvas__apply {
  width: 100%;
  padding: 15px 20px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border-radius: 4px;
  font-family: 'Inter', sans-serif;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.otly-cg-offcanvas__clear {
  border: none;
  background: transparent;
  color: #2d2d2d;
  text-decoration: underline;
  text-underline-offset: 3px;
  padding: 8px;
}

.otly-cg-offcanvas__clear:hover {
  color: #1b1c18;
}

.otly-cg-offcanvas__apply {
  background: #2d2d2d;
  color: #fff;
  border: 1px solid #2d2d2d;
}

.otly-cg-offcanvas__apply:hover {
  background: #1b1c18;
  border-color: #1b1c18;
}

/* ── RESPONSIVE ────────────────────────────────────────────── */
@media (max-width: 1200px) {
  .otly-cg__grid {
    grid-template-columns: repeat(var(--otly-cg-cols-t, var(--otly-cg-cols, 3)), minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .elementor-widget-otly_category_grid > .elementor-widget-container {
    overflow: visible;
  }

  .elementor-widget-otly_category_grid .otly-cg-wrap,
  .elementor-widget-otly_category_grid .otly-cg-wrap.otly-container {
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box;
  }

  .otly-cg__tabs-wrap {
    padding-left: var(--otly-cg-ui-pad-x, 16px);
    padding-right: var(--otly-cg-ui-pad-x, 16px);
    box-sizing: border-box;
  }

  .otly-cg__toolbar {
    padding-left: var(--otly-cg-ui-pad-x, 16px);
    padding-right: var(--otly-cg-ui-pad-x, 16px);
    box-sizing: border-box;
    margin-bottom: 24px;
    gap: 10px;
  }

  .otly-cg__sort-list {
    gap: 3px;
  }

  .otly-cg__sort-btn {
    padding: 5px 10px;
    font-size: 11px;
  }

  .otly-cg__view-btn {
    width: 42px;
    height: 42px;
  }

  .otly-cg__grid {
    grid-template-columns: repeat(var(--otly-cg-cols-m, var(--otly-cg-cols-t, 2)), minmax(0, 1fr));
    row-gap: var(--otly-cg-row-gap, 40px);
    column-gap: var(--otly-cg-col-gap, 0);
    width: 100%;
    padding-left: 0;
    padding-right: 0;
  }

  .otly-cg {
    padding: 24px 0 60px;
  }

  .elementor-widget-otly_category_grid .otly-cg__grid > .otly-cg-card,
  .elementor-widget-otly_category_grid .otly-cg__grid > .product.otly-cg-card {
    padding-left: max(var(--otly-cg-card-pad-x, 0px), 18px) !important;
    padding-right: max(var(--otly-cg-card-pad-x, 0px), 18px) !important;
    box-sizing: border-box !important;
  }

  .otly-cg-card__img-wrap .otly-cg-card__wish {
    top: 8px;
    right: 8px;
  }

  .otly-cg-card__wish .wd-wishlist-btn > a {
    width: 32px !important;
    height: 32px !important;
    min-height: 32px !important;
  }

  .otly-cg-card__meta {
    padding-top: var(--otly-cg-meta-pad-top, 18px);
    gap: var(--otly-cg-meta-gap, 8px);
  }

  .otly-cg-swatches {
    margin-bottom: 4px;
    gap: 9px;
  }

  .otly-cg-card__name {
    font-size: 16px;
    line-height: 1.4;
  }

  .otly-cg__load-more-wrap,
  .otly-cg__pagination {
    padding-left: var(--otly-cg-ui-pad-x, 16px);
    padding-right: var(--otly-cg-ui-pad-x, 16px);
    box-sizing: border-box;
  }
}

@media (max-width: 480px) {
  .otly-cg__grid {
    grid-template-columns: repeat(var(--otly-cg-cols-m, 1), minmax(0, 1fr));
    row-gap: var(--otly-cg-row-gap, 40px);
    column-gap: var(--otly-cg-col-gap, 0);
  }

  .elementor-widget-otly_category_grid .otly-cg__grid > .otly-cg-card,
  .elementor-widget-otly_category_grid .otly-cg__grid > .product.otly-cg-card {
    padding-left: max(var(--otly-cg-card-pad-x, 0px), 20px) !important;
    padding-right: max(var(--otly-cg-card-pad-x, 0px), 20px) !important;
  }

  .otly-cg__toolbar {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }
  .otly-cg__toolbar-left { width: 100%; flex-wrap: wrap; gap: 10px; }
  .otly-cg__toolbar-right {
    width: 100%;
    justify-content: space-between;
    margin-left: 0;
  }

  .otly-cg__sort-wrap {
    justify-content: center;
  }

  .otly-cg__sort-label {
    display: none;
  }

  .otly-cg__sort-list {
    justify-content: center;
    gap: 5px;
  }

  .otly-cg__sort-btn {
    padding: 6px 12px;
    font-size: 11px;
  }

  .otly-cg__view-switch {
    margin-left: 0;
  }

  .otly-cg__view-btn {
    width: 42px;
    height: 42px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .otly-cg__tab,
  .otly-cg-card__img,
  .otly-cg-card__media,
  .otly-cg-card__actions-zone,
  .otly-cg-card__wish,
  .otly-cg-offcanvas__panel,
  .otly-cg__grid {
    transition: none !important;
    transform: none !important;
  }

  .otly-cg-card__media {
    --otly-tx: 0 !important;
    --otly-ty: 0 !important;
    --otly-media-scale: 1 !important;
  }

  .otly-cg__grid.is-loading,
  .otly-cg__grid.is-swapping,
  .otly-cg__grid.is-revealing .otly-cg-card {
    animation: none !important;
  }
}

/* Beat WoodMart specificity */
.woocommerce .otly-cg-card,
.woocommerce ul.products .otly-cg-card,
.woodmart-theme .otly-cg-card {
  margin: 0 !important;
  padding: 0 !important;
  float: none !important;
}

.woocommerce .otly-cg-card__img-wrap,
.woodmart-theme .otly-cg-card__img-wrap {
  aspect-ratio: inherit;
}

.woocommerce .otly-cg-card__img,
.woodmart-theme .otly-cg-card__img--primary,
.woocommerce .otly-cg-card__img--hover,
.woodmart-theme .otly-cg-card__img--hover {
  border-radius: 0 !important;
  margin: 0 !important;
  max-height: none !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  position: absolute !important;
  inset: 0 !important;
}

.woocommerce .otly-cg-card--ratio-3-4 .otly-cg-card__img-wrap,
.woodmart-theme .otly-cg-card--ratio-3-4 .otly-cg-card__img-wrap {
  aspect-ratio: 3 / 4 !important;
}

.woocommerce .otly-cg-card__name,
.woodmart-theme .otly-cg-card__name,
.woocommerce .otly-cg-card__name:hover,
.woodmart-theme .otly-cg-card__name:hover {
  margin: 0 0 2px !important;
  padding: 0 !important;
  display: block !important;
  visibility: visible !important;
  font-size: 14px !important;
  line-height: 1.35 !important;
  color: #1b1c18 !important;
  font-family: 'Space Grotesk', sans-serif !important;
  font-weight: 500 !important;
  text-indent: 0 !important;
  height: auto !important;
  width: auto !important;
  clip: auto !important;
  position: static !important;
}

.woocommerce .otly-cg-card__price,
.woodmart-theme .otly-cg-card__price {
  color: #1b1c18 !important;
  margin: 0 0 4px !important;
}

.woocommerce .otly-cg-card__actions-zone .otly-cg-hover-bar,
.woodmart-theme .otly-cg-card__actions-zone .otly-cg-hover-bar,
.woocommerce .otly-cg-card__actions-zone .add_to_cart_button,
.woodmart-theme .otly-cg-card__actions-zone .add_to_cart_button,
.woocommerce .otly-cg-card__actions-zone .button,
.woodmart-theme .otly-cg-card__actions-zone .button {
  position: relative !important;
  top: auto !important;
  left: auto !important;
  right: auto !important;
  bottom: auto !important;
  transform: none !important;
  float: none !important;
  margin: 0 !important;
}

/* Hide stray WoodMart swatches on the card image — quick-shop panel keeps its own */
.otly-cg-card__img-wrap > .wd-swatches-grid,
.otly-cg-card__img-wrap > .wd-swatches-product {
  display: none !important;
}

.otly-cg-card .wd-quick-shop .wd-swatches-product {
  display: flex !important;
}

.woocommerce .otly-cg-card .otly-cg-swatch,
.woodmart-theme .otly-cg-card .otly-cg-swatch,
.woocommerce .otly-cg-card button.otly-cg-swatch,
.woodmart-theme .otly-cg-card button.otly-cg-swatch {
  width: 20px !important;
  height: 20px !important;
  min-width: 20px !important;
  min-height: 20px !important;
  border-radius: 50% !important;
  padding: 0 !important;
  line-height: 0 !important;
}

.woocommerce .otly-cg-card__wish .wd-wishlist-btn > a,
.woodmart-theme .otly-cg-card__wish .wd-wishlist-btn > a {
  width: 34px !important;
  height: 34px !important;
  min-height: 34px !important;
  border-radius: 50% !important;
}

/* Legacy drawer (removed from markup; hide if cached HTML still has it) */
.otly-cg-options {
  display: none !important;
}

/* ── OPTIONS DRAWER (deprecated) ───────── */
.otly-cg-options.otly-cg-options--legacy {
  position: fixed;
  inset: 0;
  z-index: 100060;
  pointer-events: none;
  visibility: hidden;
  font-family: 'Inter', sans-serif;
}

.otly-cg-options.is-open {
  pointer-events: auto;
  visibility: visible;
}

body.otly-cg-options-open {
  overflow: hidden;
}

.otly-cg-options__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(27, 28, 24, 0.45);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.otly-cg-options.is-open .otly-cg-options__backdrop {
  opacity: 1;
}

.otly-cg-options__sheet {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  max-height: min(88vh, 640px);
  background: #fafaf8;
  border-radius: 16px 16px 0 0;
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 0 -12px 48px rgba(27, 28, 24, 0.16);
}

.otly-cg-options.is-open .otly-cg-options__sheet {
  transform: translateY(0);
}

@media (min-width: 768px) {
  .otly-cg-options__sheet {
    left: 50%;
    right: auto;
    bottom: auto;
    top: 50%;
    width: min(440px, calc(100vw - 48px));
    max-height: min(80vh, 600px);
    border-radius: 12px;
    transform: translate(-50%, -48%) scale(0.98);
    opacity: 0;
  }

  .otly-cg-options.is-open .otly-cg-options__sheet {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
}

.otly-cg-options__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px 12px;
  border-bottom: 1px solid rgba(45, 45, 45, 0.08);
}

.otly-cg-options__eyebrow {
  margin: 0 0 4px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #8a8882;
}

.otly-cg-options__title {
  margin: 0;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 22px;
  font-weight: 600;
  line-height: 1.2;
  color: #1b1c18;
}

.otly-cg-options__price {
  margin: 6px 0 0;
  font-size: 14px;
  font-weight: 600;
  color: #2d2d2d;
}

.otly-cg-options__price .amount {
  font-weight: 600;
}

.otly-cg-options__close {
  font-size: 28px;
  line-height: 1;
  color: #888;
  padding: 0 4px;
  flex-shrink: 0;
}

.otly-cg-options__close:hover {
  color: #1b1c18;
}

.otly-cg-options__body {
  flex: 1;
  overflow-y: auto;
  padding: 20px 24px;
  -webkit-overflow-scrolling: touch;
}

.otly-cg-options__body--shake {
  animation: otly-cg-options-shake 0.35s ease;
}

@keyframes otly-cg-options-shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

.otly-cg-options__loading {
  min-height: 120px;
  background: linear-gradient(90deg, #f3f2ee 25%, #ebe9e4 50%, #f3f2ee 75%);
  background-size: 200% 100%;
  animation: otly-cg-shimmer 1s ease infinite;
  border-radius: 8px;
}

.otly-cg-options__error {
  margin: 0;
  font-size: 14px;
  color: #8a8882;
  text-align: center;
  padding: 24px 0;
}

.otly-cg-options__body .variations_form {
  margin: 0;
}

.otly-cg-options__body .variations {
  margin: 0;
  width: 100%;
  border: none;
}

.otly-cg-options__body .variations tr {
  display: block;
  margin: 0 0 18px;
}

.otly-cg-options__body .variations tr:last-child {
  margin-bottom: 0;
}

.otly-cg-options__body .variations td {
  display: block;
  padding: 0;
  border: none;
}

.otly-cg-options__body .variations .label label {
  display: block;
  margin: 0 0 10px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #8a8882;
}

.otly-cg-options__body .reset_variations {
  display: none !important;
}

.otly-cg-options__body .variations select {
  width: 100%;
  min-height: 44px;
  padding: 10px 36px 10px 12px;
  border: 1px solid #e0ded8;
  border-radius: 8px;
  background-color: #fff;
  font-size: 14px;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23666' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}

.otly-cg-options__body--has-swatches .variations select {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
  overflow: hidden !important;
}

.otly-cg-options__body .wd-swatches-product {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.otly-cg-options__body .wd-swatch.wd-bg .wd-swatch-bg,
.otly-cg-options__body .wd-swatch.wd-bg .wd-swatch-bg:before {
  width: 28px !important;
  height: 28px !important;
  min-width: 28px !important;
  min-height: 28px !important;
  border-radius: 50% !important;
}

.otly-cg-options__body .wd-swatch.wd-text {
  min-width: 40px;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid #e0ded8;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  background: #fff;
}

.otly-cg-options__body .wd-swatch.wd-active,
.otly-cg-options__body .wd-swatch:hover {
  border-color: #1b1c18;
  box-shadow: 0 0 0 1px #1b1c18;
}

.otly-cg-options__body .woocommerce-variation.single_variation,
.otly-cg-options__body .woocommerce-variation-add-to-cart,
.otly-cg-options__body .single_add_to_cart_button {
  display: none !important;
}

.otly-cg-options__foot {
  flex-shrink: 0;
  padding: 16px 24px 24px;
  border-top: 1px solid rgba(45, 45, 45, 0.08);
  background: #fafaf8;
}

.otly-cg-options__submit {
  width: 100%;
  padding: 16px 20px;
  background: #2d2d2d;
  color: #fff;
  border: none;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.2s ease, opacity 0.2s ease;
}

.otly-cg-options__submit:hover:not(:disabled) {
  background: #1b1c18;
}

.otly-cg-options__submit:disabled,
.otly-cg-options__submit.is-disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.otly-cg-options__submit.loading {
  opacity: 0.7;
  pointer-events: none;
}

.otly-cg-options__submit.added {
  background: #6b7c4a;
}

