/* -------------------------------------------------------
   Category accordion – sidebar widget
------------------------------------------------------- */
.tp-shop-widget-categories ul li.tp-cat-accordion-item {
  margin-bottom: 0;
}

.tp-cat-accordion-header {
  display: flex;
  align-items: center;
  width: 100%;
  margin-bottom: 10px;
}

.tp-cat-accordion-header > a {
  flex: 1;
}

.tp-cat-accordion-toggle {
  background: none;
  border: none;
  padding: 4px 4px 4px 8px;
  cursor: pointer;
  color: var(--tp-text-body);
  line-height: 1;
  flex-shrink: 0;
  transition:
    transform 0.2s ease,
    color 0.2s ease;
}

.tp-cat-accordion-toggle:hover {
  color: var(--tp-theme-primary);
}

.tp-cat-accordion-item.is-open
  > .tp-cat-accordion-header
  .tp-cat-accordion-toggle {
  transform: rotate(180deg);
}

.tp-cat-accordion-children {
  margin-bottom: 10px;
}

.tp-cat-accordion-children li a {
  padding-left: 32px !important;
}

.tp-cat-accordion-header > a.is-active {
  color: var(--tp-theme-primary);
}

.tp-cat-accordion-header > a.is-active::after {
  background-color: var(--tp-theme-primary);
}

.tp-cat-accordion-children li.tp-cat-current a {
  color: var(--tp-theme-primary);
}

.tp-cat-accordion-children li.tp-cat-current a::after {
  background-color: var(--tp-theme-primary);
}

/* -------------------------------------------------------
   Sub-category filter badge bar – above product grid
------------------------------------------------------- */
.tp-subcat-filter-title {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--tp-text-body);
  margin-bottom: 12px;
}

.tp-subcat-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.tp-subcat-badge {
  display: inline-block;
  padding: 6px 18px;
  border: 1px solid #eaeaea;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 500;
  color: var(--tp-text-body);
  background: #fff;
  text-decoration: none;
  line-height: 1.5;
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease;
}

.tp-subcat-badge:hover,
.tp-subcat-badge.is-active {
  background: var(--tp-theme-primary);
  border-color: var(--tp-theme-primary);
  color: #fff;
}

/* -------------------------------------------------------
   Brand filter – sidebar checkbox widget
------------------------------------------------------- */
.tp-brand-filter-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.tp-brand-filter-label {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0;
  cursor: pointer;
  font-size: 15px;
  color: var(--tp-text-body);
  transition: color 0.2s ease;
}

.tp-brand-filter-label:hover {
  color: var(--tp-theme-primary);
}

.tp-brand-filter-checkbox {
  appearance: none;
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  min-width: 16px;
  border: 1.5px solid #c5c5c5;
  border-radius: 3px;
  background: #fff;
  cursor: pointer;
  position: relative;
  transition:
    border-color 0.2s ease,
    background 0.2s ease;
}

.tp-brand-filter-checkbox:checked {
  background: var(--tp-theme-primary);
  border-color: var(--tp-theme-primary);
}

.tp-brand-filter-checkbox:checked::after {
  content: '';
  position: absolute;
  left: 3px;
  top: 0px;
  width: 5px;
  height: 9px;
  border: 2px solid #fff;
  border-top: none;
  border-left: none;
  transform: rotate(45deg);
}

.tp-brand-filter-name {
  flex: 1;
  line-height: 1.4;
}

.tp-brand-filter-submit {
  display: inline-block;
  margin-top: 12px;
  padding: 8px 20px;
  background: var(--tp-theme-primary);
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.tp-brand-filter-submit:hover {
  opacity: 0.85;
}
