@media (min-width: 769px) {
  .wmfd-filter-button,
  .wmfd-overlay,
  .wmfd-drawer { display: none !important; }
}

@media (max-width: 768px) {
  body.wmfd-lock { overflow: hidden !important; }

  /* Force visibility: some themes/plugins style all buttons or fixed elements aggressively. */
  html body .wmfd-filter-button {
    position: fixed !important;
    left: 50% !important;
    right: auto !important;
    top: auto !important;
    bottom: calc(var(--wmfd-btn-bottom, 74px) + env(safe-area-inset-bottom, 0px)) !important;
    transform: translate3d(-50%, 0, 0) !important;
    z-index: 2147483000 !important;
    display: inline-flex !important;
    visibility: visible !important;
    opacity: 1 !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    min-height: 46px !important;
    width: auto !important;
    max-width: calc(100vw - 28px) !important;
    padding: 0 20px !important;
    border: 0 !important;
    border-radius: 999px !important;
    color: var(--wmfd-btn-color, #fff) !important;
    background: var(--wmfd-btn-bg, #1f2937) !important;
    box-shadow: 0 10px 28px rgba(0,0,0,.25) !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
    cursor: pointer !important;
    pointer-events: auto !important;
    margin: 0 !important;
    text-decoration: none !important;
  }

  html body .wmfd-filter-button[hidden] { display: inline-flex !important; }

  .wmfd-filter-icon {
    width: 16px;
    height: 16px;
    display: inline-block;
    position: relative;
    flex: 0 0 16px;
  }

  .wmfd-filter-icon:before,
  .wmfd-filter-icon:after {
    content: '';
    position: absolute;
    right: 0;
    left: 0;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
  }

  .wmfd-filter-icon:before { top: 4px; box-shadow: 0 4px 0 currentColor; }
  .wmfd-filter-icon:after { bottom: 2px; width: 9px; margin-right: 4px; }

  html body .wmfd-overlay {
    position: fixed !important;
    inset: 0 !important;
    z-index: 2147483001 !important;
    background: var(--wmfd-overlay, rgba(0,0,0,.48)) !important;
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s ease, visibility .25s ease;
  }

  html body .wmfd-overlay.is-active { opacity: 1 !important; visibility: visible !important; display:block !important; }

  html body .wmfd-drawer {
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    left: auto !important;
    bottom: 0 !important;
    z-index: 2147483002 !important;
    width: min(88vw, 390px) !important;
    max-width: 390px !important;
    height: 100dvh !important;
    background: #fff !important;
    color: #222 !important;
    transform: translateX(105%) !important;
    transition: transform .28s ease !important;
    box-shadow: -12px 0 34px rgba(0,0,0,.22) !important;
    display: flex !important;
    flex-direction: column !important;
    direction: rtl !important;
    opacity: 1 !important;
    visibility: visible !important;
  }

  html body .wmfd-drawer.is-active { transform: translateX(0) !important; }

  .wmfd-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 58px;
    padding: 14px 18px;
    border-bottom: 1px solid #ececec;
    background: #f8f8f8;
    flex: 0 0 auto;
  }

  .wmfd-drawer-header strong { font-size: 15px; font-weight: 800; }

  .wmfd-close {
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    background: #e9e9e9;
    color: #111;
    font-size: 26px;
    line-height: 34px;
    cursor: pointer;
  }

  .wmfd-drawer-content {
    flex: 1 1 auto;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 16px 18px 28px;
  }

  .wmfd-drawer-content .widget,
  .wmfd-drawer-content .wd-widget,
  .wmfd-drawer-content .woodmart-widget {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    margin-bottom: 22px !important;
    padding-bottom: 18px;
    border-bottom: 1px solid #eee;
  }

  .wmfd-drawer-content .widget:last-child,
  .wmfd-drawer-content .wd-widget:last-child,
  .wmfd-drawer-content .woodmart-widget:last-child { border-bottom: 0; }

  .wmfd-drawer-content .widget-title,
  .wmfd-drawer-content .wd-widget-title,
  .wmfd-drawer-content .title {
    font-size: 14px;
    font-weight: 800;
    margin-bottom: 12px;
  }

  .wmfd-empty {
    padding: 20px 0;
    color: #777;
    font-size: 14px;
    text-align: center;
  }
}
