.wh-projects-filter {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 24px;
  position: relative;
  z-index: 50;
}

.wh-filter-all {
  background: none;
  border: none;
  font-weight: 600;
  text-decoration: underline;
  cursor: pointer;
  color: #111;
}

.wh-filter-all.is-active {
  color: #000;
}

.wh-filter-all.is-clear {
  color: #e0264d;
}

.wh-filter-dropdown {
  position: relative;
  flex: 1;
  min-width: 160px;
}

.wh-projects-filter-topbar {
  display: none;
}

.wh-filter-groups {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1;
  flex-wrap: wrap;
}

.wh-filter-clear-link {
  display: none;
  background: none;
  border: none;
  text-decoration: underline;
  font-size: 14px;
  cursor: pointer;
  color: #111;
}

.wh-filter-clear-link.is-active-filters {
  display: inline-block;
}
@media all and (max-width: 900px) {
  .wh-projects-filter-topbar > * {
    flex: 1;
  }

  .wh-projects-filter.is-mobile-open .wh-filter-groups {
    position: relative;
    width: 50%;
    left: 50%;
  }

  .wpb_text_column.heading-filter {
    display: none;
  }

  .wh-filter-mobile-toggle,
  .wh-filter-clear-link.is-active-filters {
    padding: 0;
  }

  .wh-projects-filter-topbar-actions {
    justify-content: space-between;
  }
}

@media (max-width: 782px) {
  .wh-projects-filter {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .wh-projects-filter-topbar {
    display: flex;
    align-items: center;
  }

  .wh-projects-filter-title {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #9a9a9a;
  }

  .wh-projects-filter-topbar-actions {
    display: flex;
    align-items: center;
    gap: 16px;
  }

  .wh-filter-mobile-toggle,
  .wh-filter-clear-link.is-active-filters {
    background: none;
    border: none;
    text-decoration: underline;
    font-weight: 500;
    font-size: 16px;
    cursor: pointer;
    color: #000;
  }

  /* Sembunyikan pill "All"/"Clear Filters" versi desktop di mobile */
  .wh-filter-all {
    display: none;
  }

  /* Grup dropdown disembunyikan sampai panel dibuka */
  .wh-filter-groups {
    display: none;
    flex-direction: column;
    gap: 12px;
    width: 100%;
  }

  .wh-projects-filter.is-mobile-open .wh-filter-groups {
    display: flex;
  }

  .wh-filter-dropdown {
    width: 100%;
  }

  .wh-filter-menu {
    position: static;
    box-shadow: none;
    border-top: none;
    border-radius: 0 0 8px 8px;
    margin-top: -1px;
  }
}

.wh-filter-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: transparent;
  border: 1px solid #c1c8ce;
  padding: 12px 16px;
  cursor: pointer;
  font-size: 16px;
  color: #000;
  font-weight: 500;
}
.wh-filter-trigger span {
  font-weight: 500;
}

.wh-filter-dropdown.has-active .wh-filter-trigger {
  border-color: #da101d;
}

.wh-filter-chevron {
  width: 10px;
  height: 10px;
  border-right: 2px solid #111;
  border-bottom: 2px solid #111;
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.wh-filter-dropdown.is-open .wh-filter-chevron {
  transform: rotate(-135deg);
}

.wh-filter-menu {
  display: none;
  position: absolute;
  /* top: calc(100% + 8px); */
  left: 0;
  width: 100%;
  background: #f5f5f5;
  /* border: 1px solid #c1c8ce; */
  border-radius: 0px;
  overflow: hidden;
}

.wh-filter-dropdown.is-open .wh-filter-menu {
  display: block;
}

.wh-filter-menu label {
  border-left: 1px solid #e0e3e7;
  border-right: 1px solid #e0e3e7;
}

.wh-filter-menu label {
  border-bottom: 1px solid #e0e3e7;
}

.wh-filter-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  cursor: pointer;
  font-size: 16px;
  font-weight: 500;
}

.wh-filter-option:hover {
  background: #f7f7f7;
}

.wh-filter-option input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.wh-filter-checkbox {
  width: 18px;
  height: 18px;
  background: #e0e3e7;
  flex-shrink: 0;
  position: relative;
}

.wh-filter-option input[type="checkbox"]:checked + .wh-filter-checkbox {
  background: #da101d;
}

.wh-filter-option input[type="checkbox"]:checked + .wh-filter-checkbox::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 10px;
  height: 2px;
  background: #fff;
  transform: translate(-50%, -50%);
}

.wh-filter-option input[type="checkbox"]:checked + .wh-filter-checkbox::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  width: 2px;
  height: 10px;
  background: #fff;
  transform: translate(-50%, -50%);
}

.wh-projects-wrapper.is-loading .wh-projects-list {
  opacity: 0.5;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.wh-projects-wrapper {
  position: relative;
}
