/* Search feedback stays within the existing bar, without adding filter height. */
.fcepb-search-box { position: relative; }
.fcepb-search-box .fcepb-search-status {
  position: absolute;
  inset-inline: 36px 28px;
  top: 50%;
  transform: translateY(-50%);
  background: #fff;
  font: inherit;
  font-size: 12px;
  line-height: 1.15;
  pointer-events: none;
}
.fcepb-search-box .fcepb-search-status[hidden] { display: none !important; }
.fcepb-search-box.fcepb-search-empty [data-fluent-cart-search-bar] { color: transparent !important; }
:is(.brxe-fc-shop-grid, .fcepb-fc-shop-grid) [data-fcepb-search-active="1"]:has([data-fct-product-card]) [data-fluent-cart-shop-no-result-found] { display: none !important; }
/* Native display:none removes the card grid and shifts the sticky filter while
   a search is pending. Preserve its existing display mode until replacement. */
[data-fcepb-search-loading="1"] > [data-fluent-cart-shop-app-product-list].product-list-hide {
  display: var(--fcepb-search-list-display, grid) !important;
  opacity: .65;
  pointer-events: none;
}
[data-fcepb-search-fallback] { display: none !important; }

/* Fill the configured container independently of card content. Bricks flex
   parents can otherwise shrink this element when the product list empties. */
:is(.brxe-fc-shop-grid, .fcepb-fc-shop-grid) {
  width: 100%;
  min-width: 0;
}
:is(.brxe-fc-shop-grid, .fcepb-fc-shop-grid) > div:has(> [data-fluent-cart-shop-app]) {
  width: 100%;
  min-width: 0;
}
:is(.brxe-fc-shop-grid, .fcepb-fc-shop-grid) [data-fluent-cart-shop-app] > .fct-shop-view-switcher-wrap {
  width: 100%;
  min-width: 0;
  justify-content: flex-end;
}

/* Override the grid's more-specific span filter-text rule in both views. */
:is(.brxe-fc-shop-grid, .fcepb-fc-shop-grid) [data-fluent-cart-product-filter-form] .fcepb-search-box .fcepb-search-status {
  color: #b91c1c !important;
}

/* An error must not leave an empty viewport, including while the popup is closed. */
.fcepb-grid-request-error { grid-column: 1 / -1; color: #b91c1c; padding: 12px; }
.fcepb-grid-request-error[hidden] { display: none !important; }
