#kjcf-preloader {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  background: var(--kjcf-loader-bg, rgba(255, 255, 255, 0.75));
  backdrop-filter: saturate(120%) blur(2px);
  z-index: 9999;
}
#kjcf-preloader.show {
  display: flex;
}
#kjcf-preloader .kjcf-spinner {
  width: 42px;
  height: 42px;
  box-sizing: content-box;
  border-radius: 50%;
  border: 3px solid var(--kjcf-loader-track, #e9ecef);
  border-top-color: var(--kjcf-loader, #000);
  animation: kjcfspin 0.8s linear infinite;
}
@keyframes kjcfspin {
  to {
    transform: rotate(360deg);
  }
}
.pls-site-content.kjcf-loading {
  opacity: 0.55;
  pointer-events: none;
  transition: opacity 0.15s ease;
}
.kjcf-inline-filters {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0.5rem 0 1rem;
}
.kjcf-inline-filters .widget_layered_nav_filters ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.kjcf-inline-filters .pls-clear-filters-wrapp {
  margin-right: 0.5rem;
}
.product-categories-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 15px;
}
.product-categories-inline .category-filter-item {
  display: inline-block;
  padding: 6px 12px;
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 999px;
  text-decoration: none;
  color: #495057;
  font-size: 14px;
  transition: 0.2s;
}
.product-categories-inline .category-filter-item:hover {
  background: #e9ecef;
  border-color: #adb5bd;
}
.product-categories-inline .category-filter-item.active {
  background: #007cba;
  border-color: #006ba1;
  color: #fff;
}
.kjcf-more {
  margin-top: 8px;
}
.kjcf.product-categories li.current-cat > a {
  text-decoration: underline;
  text-underline-offset: 2px;
}
.tagcloud a.active {
  background-color: var(--pls-primary-color);
  color: var(--pls-primary-inverse-color);
  border-color: var(--pls-primary-color);
  box-shadow: none;
  text-decoration: none;
}
@media (max-width: 1024px) {
  #secondary .kjcf-mobile-actions {
    position: fixed;
    bottom: 0;
    inset-inline: 0;
    display: flex;
    gap: 0.75rem;
    padding: 0.75rem;
    background: #fff;
    border-top: 1px solid #e9ecef;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.04);
    z-index: 2000;
  }
  #secondary .kjcf-mobile-actions .kjcf-clear,
  #secondary .kjcf-mobile-actions .kjcf-apply {
    flex: 1 1 auto;
    padding: 0.65rem 0.9rem;
    border: 1px solid var(--pls-border-color, #dee2e6);
    background: #f8f9fa;
    font-weight: 600;
  }
  #secondary .kjcf-mobile-actions .kjcf-clear {
    color: #000;
  }
  #secondary .kjcf-mobile-actions .kjcf-apply {
    background: var(--pls-primary-color, #007cba);
    color: var(--pls-primary-inverse-color, #fff);
    border-color: var(--pls-primary-color, #007cba);
  }
  #secondary .widget_price_filter .price_slider_amount .button {
    display: none !important;
  }
  #secondary .kjcf-tagcloud-more {
    margin-top: 8px;
  }
  #kjcf-preloader,
  #kjcf-preloader.show {
    z-index: 1004 !important;
  }
  .pls-widget-area.opened {
    z-index: 1007 !important;
  }
}
#secondary .tagcloud a.active,
#secondary .wc-layered-nav-term a.active,
#secondary .widget_kjcf_wc_product_categories_filter a.active {
  background: var(--pls-primary-color);
  color: var(--pls-primary-inverse-color);
  padding: 2px 8px;
  text-decoration: none;
}

/* Tag cloud expand/collapse animation */
.kjcf-extra-tags {
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  line-height: 0; /* remove line box when collapsed -> no leftover gap */
  vertical-align: top;
  transition: max-height 0.25s ease, opacity 0.18s ease, line-height 0.25s ease;
}
.kjcf-extra-tags.kjcf-open {
  display: flex!important;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  opacity: 1;
  line-height: normal; /* restore natural line height when open */
}
