/* Suggestions de recherche — habillage par défaut de TOUS les thèmes V4.
 *
 * Le comportement est dans `_v4/assets/js/theme.js` (un seul script). Cette
 * feuille est émise même pour un thème `v4_foundation: false` : sans elle, la
 * liste créée par le script s'afficherait sans fond ni position. Un thème
 * l'habille en redéfinissant ces classes dans sa couche, jamais en recopiant
 * le script. */

/* Repère de la liste. `:where()` = spécificité nulle : la règle d'un thème
   gagne toujours (alif ouvre sa recherche mobile en `position:absolute`). */
:where(.mnx-search--suggest) {
  position: relative;
}

.mnx-search-wrap {
  position: relative;
  flex: 1 1 auto;
  min-width: 0;
}

.mnx-search__suggest {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 1000;
  max-height: min(440px, 70vh);
  overflow-y: auto;
  padding: 6px;
  background: var(--color-background, #fff);
  color: var(--color-text, #222);
  border: 1px solid var(--color-border, #e1e1e1);
  border-radius: var(--btn-radius, 6px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .12);
  text-align: start;
}

.mnx-search__suggest[hidden] {
  display: none !important;
}

.mnx-search__suggest-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 10px;
  border-radius: var(--btn-radius, 6px);
  color: var(--color-text, #222) !important;
  text-decoration: none !important;
  cursor: pointer;
}

.mnx-search__suggest-item:hover,
.mnx-search__suggest-item.is-active {
  background: var(--color-surface, #f5f5f5);
}

.mnx-search__suggest-item .ac-img {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  object-fit: cover;
  border-radius: 4px;
  background: var(--color-surface, #f5f5f5);
}

.mnx-search__suggest-item .ac-title {
  flex: 1 1 auto;
  min-width: 0;
  font-size: 14px;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.mnx-search__suggest-item .ac-price {
  flex: 0 0 auto;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.mnx-search__suggest-item .ac-price .oldprice {
  font-weight: 500;
}

.mnx-search__suggest-empty {
  margin: 0;
  padding: 14px;
  text-align: center;
  font-size: 13.5px;
  color: var(--color-text-muted, #777);
}
