/* Arte y Fiesta — shop / catalog sidebar (quiet retail) */

@import url("https://fonts.googleapis.com/css2?family=Fredoka:wght@500;600&family=Plus+Jakarta+Sans:wght@500;600;700&display=swap");

.wd-sidebar {
  --ayf-sb-brand: #872e8c;
  --ayf-sb-brand-deep: #6a2470;
  --ayf-sb-ink: #1e1524;
  --ayf-sb-muted: #6b5f72;
  --ayf-sb-soft: #f7f2f8;
  --ayf-sb-line: rgba(30, 21, 36, 0.08);
  --ayf-sb-display: "Fredoka", system-ui, sans-serif;
  --ayf-sb-body: "Plus Jakarta Sans", system-ui, sans-serif;
}

.wd-sidebar .widget-area {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

/* Flat widgets — no card chrome */
.wd-sidebar .wd-widget,
.wd-sidebar .sidebar-widget {
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.wd-sidebar .widget-title {
  margin: 0 0 0.85rem !important;
  padding: 0 0 0.55rem !important;
  border-bottom: 1px solid var(--ayf-sb-line) !important;
  font-family: var(--ayf-sb-display) !important;
  font-weight: 600 !important;
  font-size: 0.95rem !important;
  letter-spacing: 0.04em;
  text-transform: uppercase !important;
  color: var(--ayf-sb-ink) !important;
}

/* ---------- Categories ---------- */

.wd-sidebar .widget_product_categories .product-categories,
.wd-sidebar .widget_product_categories ul {
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

/* Accordion room for WoodMart toggle without crowding counts */
.categories-accordion-on .wd-sidebar .widget_product_categories .product-categories:has(.cat-item ul) {
  padding-inline-end: 1.65rem !important;
}

.wd-sidebar .widget_product_categories .cat-item {
  position: relative;
  display: flex !important;
  flex-wrap: wrap;
  align-items: center !important;
  margin: 0 !important;
  padding: 0 !important;
}

.wd-sidebar .widget_product_categories .cat-item > a {
  flex: 1 1 auto;
  min-width: 0;
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0.52rem 0.5rem 0.52rem 0.55rem !important;
  border-radius: 8px;
  border-left: 0;
  font-family: var(--ayf-sb-display) !important;
  font-weight: 500 !important;
  font-size: 0.95rem !important;
  line-height: 1.3 !important;
  letter-spacing: 0.005em;
  color: var(--ayf-sb-ink) !important;
  text-decoration: none !important;
  background: transparent !important;
  box-shadow: none;
  transition:
    color 0.15s ease,
    background-color 0.15s ease,
    box-shadow 0.15s ease;
}

.wd-sidebar .widget_product_categories .cat-item > a:hover,
.wd-sidebar .widget_product_categories .cat-item > a:focus-visible {
  color: var(--ayf-sb-brand) !important;
  background: transparent !important;
  outline: none;
}

/* Parent of current path: weight only (accordion open ≠ selected) */
.wd-sidebar .widget_product_categories .cat-item.current-cat-parent > a {
  color: var(--ayf-sb-brand) !important;
  font-weight: 600 !important;
  background: transparent !important;
}

/* True active category */
.wd-sidebar .widget_product_categories .cat-item.current-cat > a {
  color: var(--ayf-sb-brand) !important;
  font-weight: 600 !important;
  background: var(--ayf-sb-soft) !important;
  box-shadow: inset 3px 0 0 var(--ayf-sb-brand);
}

/* Counts: quiet numerals, never white-on-pink */
.wd-sidebar .widget_product_categories .cat-item > .count {
  flex: 0 0 auto !important;
  position: static !important;
  transform: none !important;
  display: inline-block;
  min-width: 0 !important;
  height: auto !important;
  margin: 0 0.15rem 0 0.35rem !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: var(--ayf-sb-muted) !important;
  font-family: var(--ayf-sb-body) !important;
  font-size: 0.78rem !important;
  font-weight: 600 !important;
  font-style: normal !important;
  line-height: 1 !important;
  letter-spacing: 0.02em;
  opacity: 0.7;
  pointer-events: none;
}

.wd-sidebar .widget_product_categories .cat-item > a:hover + .count {
  color: var(--ayf-sb-brand) !important;
  background: transparent !important;
  border: 0 !important;
  opacity: 0.9;
}

.wd-sidebar .widget_product_categories .cat-item.current-cat > .count,
.wd-sidebar .widget_product_categories .cat-item.current-cat-parent > .count {
  color: var(--ayf-sb-brand) !important;
  background: transparent !important;
  border: 0 !important;
  opacity: 0.85;
}

.categories-accordion-on .wd-sidebar .widget_product_categories .count {
  margin-top: 0 !important;
}

/* Children */
.wd-sidebar .widget_product_categories .children {
  flex: 1 1 100% !important;
  width: 100% !important;
  margin: 0.15rem 0 0.4rem !important;
  padding: 0.15rem 0 0.15rem 0.95rem !important;
  border-left: 1px solid var(--ayf-sb-line);
}

.wd-sidebar .widget_product_categories .children .cat-item > a {
  padding: 0.4rem 0.45rem 0.4rem 0.4rem !important;
  font-size: 0.88rem !important;
  font-weight: 500 !important;
  color: var(--ayf-sb-muted) !important;
  border-radius: 7px;
}

.wd-sidebar .widget_product_categories .children .cat-item.current-cat > a {
  color: var(--ayf-sb-brand) !important;
  font-weight: 600 !important;
  background: var(--ayf-sb-soft) !important;
  box-shadow: inset 3px 0 0 var(--ayf-sb-brand);
}

.wd-sidebar .widget_product_categories .children .cat-item.current-cat-parent > a {
  color: var(--ayf-sb-brand) !important;
  font-weight: 600 !important;
  background: transparent !important;
  box-shadow: none;
}

/* Toggle: quiet, open ≠ selected */
.wd-sidebar .widget_product_categories .wd-cats-toggle {
  top: 0.45rem !important;
  inset-inline-end: -1.55rem !important;
  width: 1.35rem !important;
  height: 1.35rem !important;
  line-height: 1.35rem !important;
  background: transparent !important;
  color: rgba(30, 21, 36, 0.32) !important;
  font-size: 0.55rem !important;
}

.wd-sidebar .widget_product_categories .cat-item:hover > .wd-cats-toggle,
.wd-sidebar .widget_product_categories .wd-cats-toggle:hover {
  background: var(--ayf-sb-soft) !important;
  color: var(--ayf-sb-brand) !important;
}

.wd-sidebar .widget_product_categories .wd-cats-toggle.toggle-active {
  background: transparent !important;
  color: rgba(30, 21, 36, 0.45) !important;
}

.wd-sidebar .widget_product_categories .cat-item.current-cat > .wd-cats-toggle,
.wd-sidebar .widget_product_categories .cat-item.current-cat > .wd-cats-toggle.toggle-active {
  color: var(--ayf-sb-brand) !important;
  background: transparent !important;
}

/* ---------- Layered nav ---------- */

.wd-sidebar .woocommerce-widget-layered-nav ul,
.wd-sidebar .woodmart-woocommerce-layered-nav ul,
.wd-sidebar .widget_layered_nav ul {
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

.wd-sidebar .woocommerce-widget-layered-nav-list__item,
.wd-sidebar .woodmart-woocommerce-layered-nav li,
.wd-sidebar .widget_layered_nav li {
  display: flex !important;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin: 0 !important;
}

.wd-sidebar .woocommerce-widget-layered-nav-list__item > a,
.wd-sidebar .woodmart-woocommerce-layered-nav li > a,
.wd-sidebar .widget_layered_nav li > a {
  flex: 1 1 auto;
  margin: 0 !important;
  padding: 0.45rem 0.5rem !important;
  border-radius: 8px;
  border-left: 0;
  font-family: var(--ayf-sb-display) !important;
  font-weight: 500 !important;
  font-size: 0.9rem !important;
  color: var(--ayf-sb-ink) !important;
  text-decoration: none !important;
  background: transparent !important;
  box-shadow: none;
  transition: color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease;
}

.wd-sidebar .woocommerce-widget-layered-nav-list__item > a:hover,
.wd-sidebar .woodmart-woocommerce-layered-nav li > a:hover,
.wd-sidebar .widget_layered_nav li > a:hover {
  color: var(--ayf-sb-brand) !important;
  background: transparent !important;
}

.wd-sidebar .woocommerce-widget-layered-nav-list__item > .count,
.wd-sidebar .woodmart-woocommerce-layered-nav li > .count,
.wd-sidebar .widget_layered_nav li > .count {
  flex: 0 0 auto;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  color: var(--ayf-sb-muted) !important;
  font-family: var(--ayf-sb-body) !important;
  font-size: 0.76rem !important;
  font-weight: 600 !important;
  font-style: normal !important;
  opacity: 0.7;
  pointer-events: none;
}

.wd-sidebar .woocommerce-widget-layered-nav-list__item--chosen > a,
.wd-sidebar .woodmart-woocommerce-layered-nav li.chosen > a,
.wd-sidebar .widget_layered_nav li.chosen > a {
  color: var(--ayf-sb-brand) !important;
  font-weight: 600 !important;
  background: var(--ayf-sb-soft) !important;
  box-shadow: inset 3px 0 0 var(--ayf-sb-brand);
}

.wd-sidebar .woocommerce-widget-layered-nav-list__item--chosen > .count,
.wd-sidebar .woodmart-woocommerce-layered-nav li.chosen > .count,
.wd-sidebar .widget_layered_nav li.chosen > .count,
.wd-sidebar .woocommerce-widget-layered-nav-list__item > a:hover + .count {
  color: var(--ayf-sb-brand) !important;
  background: transparent !important;
  border: 0 !important;
  opacity: 0.85;
}

/* ---------- Price ---------- */

.wd-sidebar .widget_price_filter .price_slider_amount {
  font-family: var(--ayf-sb-body) !important;
  color: var(--ayf-sb-muted);
}

.wd-sidebar .ui-slider .ui-slider-range,
.wd-sidebar .price_slider .ui-slider-range {
  background: var(--ayf-sb-brand) !important;
}

.wd-sidebar .ui-slider .ui-slider-handle,
.wd-sidebar .price_slider .ui-slider-handle {
  border-color: var(--ayf-sb-brand) !important;
  background: #fff !important;
  box-shadow: 0 0 0 2px rgba(135, 46, 140, 0.18);
}

.wd-sidebar .price_slider_amount .button {
  border-radius: 999px !important;
  background: var(--ayf-sb-brand) !important;
  color: #fff !important;
  font-family: var(--ayf-sb-body) !important;
  font-weight: 700 !important;
  border: 0 !important;
}

.wd-sidebar .price_slider_amount .button:hover {
  background: var(--ayf-sb-brand-deep) !important;
}
