/* Advanced Search 4 - recherche par famille (v6.7.0) */
/* la liste de produits d'origine de la barre de recherche ne s'affiche plus */
html.as4f-on .ui-autocomplete.searchbar-autocomplete,
html.as4f-on ul.ui-autocomplete.ui-front.searchbar-autocomplete { display: none !important; }

.as4f-dd {
    position: absolute;
    z-index: 10050;
    max-height: 70vh;
    overflow-y: auto;
    padding: 6px 0;
    border: 1px solid #dfe3e8;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 12px 30px rgba(0, 0, 0, .18);
    font-size: 14px;
    text-align: left;
}
.as4f-dd-title { padding: 6px 14px 4px; color: #8a96a3; font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.as4f-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 14px; color: #1f2a37; text-decoration: none; }
.as4f-item:hover, .as4f-item.is-active { background: #eef3f8; color: #0b2a4a; text-decoration: none; }
.as4f-item-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.as4f-item-parent { color: #8a96a3; }
.as4f-item-name { font-weight: 700; }
.as4f-item-count { flex: 0 0 auto; padding: 2px 8px; border-radius: 10px; background: #f1f3f5; color: #4a5866; font-size: 12px; }
.as4f-empty { padding: 10px 14px; color: #8a96a3; }
.as4f-all { display: block; margin-top: 4px; padding: 10px 14px; border-top: 1px solid #eef0f2; color: #0b2a4a; font-weight: 700; text-decoration: underline; }
.as4f-all:hover { background: #f7f9fb; }

/* page de resultats */
.as4f-results { margin: 0 0 20px; }
.as4f-results-title { margin: 0 0 10px; font-size: 18px; font-weight: 700; }
.as4f-results-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.as4f-card { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border: 1px solid #dfe3e8; border-radius: 10px; background: #fff; color: #1f2a37; text-decoration: none; transition: border-color .15s ease, box-shadow .15s ease; }
.as4f-card:hover { border-color: #0b2a4a; box-shadow: 0 4px 12px rgba(0, 0, 0, .08); color: #0b2a4a; text-decoration: none; }
.as4f-card-parent { color: #8a96a3; font-size: 12px; }
.as4f-card-name { font-weight: 700; line-height: 1.25; }
.as4f-card-count { color: #6b7785; font-size: 12px; }

.as4f-dd-title-products { margin-top: 6px; border-top: 1px solid #eef0f2; padding-top: 10px; }
.as4f-product { justify-content: flex-start; gap: 10px; font-weight: 400; }
.as4f-product-img { width: 36px; height: 36px; object-fit: contain; border-radius: 4px; background: #fff; flex: 0 0 36px; }
.as4f-product-name { white-space: normal; }
.as4f-card.is-active { border-color: #0b2a4a; background: #0b2a4a; color: #fff; }
.as4f-card.is-active .as4f-card-parent, .as4f-card.is-active .as4f-card-count { color: rgba(255,255,255,.8); }
.as4f-card-all { justify-content: center; border-style: dashed; }
/* dans le panneau de recherche d'Advanced Top Menu */
.atmd-search-results .as4f-inline { position: static; display: block !important; max-height: none; border: 0; box-shadow: none; border-radius: 0; padding: 0; }

/* v6.7.2 : bouton principal en tete de la previsualisation */
.as4f-all-top {
    display: block;
    margin: 4px 10px 8px;
    padding: 10px 14px;
    border: 1px solid #0b2a4a;
    border-radius: 8px;
    background: #0b2a4a;
    color: #fff !important;
    font-weight: 700;
    text-align: center;
    text-decoration: none !important;
}
.as4f-all-top:hover, .as4f-all-top:focus { filter: brightness(1.12); color: #fff !important; }

/* v6.8.0 : prix et disponibilite des produits proposes */
.as4f-product-info { display: flex; flex-direction: column; min-width: 0; gap: 2px; }
.as4f-product-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 12px; }
.as4f-product-price { font-weight: 700; color: #0b2a4a; }
.as4f-product-stock { padding: 1px 7px; border-radius: 9px; font-weight: 600; }
.as4f-stock-1 { background: #e7f6ec; color: #1e7a3c; }
.as4f-stock-2 { background: #fff4e0; color: #9a5b00; }
.as4f-stock-0 { background: #fdeaea; color: #b42318; }
