/* Xbau header autocomplete: scoped to the desktop and mobile search panels. */
body .page-header .search-autocomplete {
    box-sizing: border-box;
    max-width: calc(100vw - 24px);
    padding: 0;
    overflow-x: hidden;
    color: #4D4D4F;
    background: #fff;
    border: 1px solid rgba(77, 77, 79, .12);
    border-radius: 16px;
    box-shadow: 0 12px 32px rgba(77, 77, 79, .16);
}

body .page-header .search-autocomplete,
body .page-header .search-autocomplete * {
    box-sizing: border-box;
}

body .page-header .search-autocomplete .smile-elasticsuite-autocomplete-result,
body .page-header .search-autocomplete .autocomplete-list,
body .page-header .search-autocomplete .autocomplete-list > dt,
body .page-header .search-autocomplete .autocomplete-list > dd {
    min-width: 0;
    max-width: 100%;
}

body .page-header .search-autocomplete .smile-elasticsuite-autocomplete-result,
body .page-header .search-autocomplete .autocomplete-list {
    width: 100%;
}

body .page-header .search-autocomplete .autocomplete-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 0;
    padding: 18px 20px;
    background: #fff;
}

body .page-header .search-autocomplete .autocomplete-list + .autocomplete-list {
    border-top: 1px solid rgba(77, 77, 79, .12);
}

body .page-header .search-autocomplete .autocomplete-list > .autocomplete-list-title {
    margin: 0 0 2px;
    color: #4D4D4F;
    font-size: 14px;
    font-weight: 600;
    line-height: 20px;
}

body .page-header .search-autocomplete .autocomplete-list > dd {
    width: 100%;
    margin: 0;
    cursor: pointer;
}

body .page-header .search-autocomplete .autocomplete-list > dd.selected,
body .page-header .search-autocomplete .autocomplete-list > dd:hover {
    background: #f0f8f9;
}

body .page-header .search-autocomplete .xbau-autocomplete-product {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 78px;
    padding: 10px 12px !important;
    overflow: hidden;
    border: 1px solid rgba(77, 77, 79, .14) !important;
    border-radius: 12px;
}

body .page-header .search-autocomplete .xbau-autocomplete-product .product-image-box {
    display: grid;
    flex: 0 0 56px;
    place-items: center;
    width: 56px;
    height: 56px;
    min-width: 0;
    overflow: hidden;
    background: #f7f7f7;
    border-radius: 8px;
}

body .page-header .search-autocomplete .xbau-autocomplete-product .product-image-box img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: 56px;
    max-height: 56px;
    margin: 0;
    object-fit: contain;
}

body .page-header .search-autocomplete .xbau-autocomplete-product .product-shop,
body .page-header .search-autocomplete .xbau-autocomplete-product .f-fix,
body .page-header .search-autocomplete .xbau-autocomplete-product .product-primary,
body .page-header .search-autocomplete .xbau-autocomplete-product .product-name,
body .page-header .search-autocomplete .xbau-autocomplete-product .product-secondary {
    min-width: 0;
    max-width: 100%;
}

body .page-header .search-autocomplete .xbau-autocomplete-product .product-shop {
    flex: 1 1 auto;
    width: auto;
    overflow: hidden;
}

body .page-header .search-autocomplete .xbau-autocomplete-product .product-primary,
body .page-header .search-autocomplete .xbau-autocomplete-product .product-name {
    color: #4D4D4F;
    font-size: 13px;
    font-weight: 500;
    line-height: 18px;
    text-transform: none;
    white-space: normal;
    overflow-wrap: anywhere;
}

body .page-header .search-autocomplete .xbau-autocomplete-product .product-secondary {
    margin-top: 4px;
    color: #1E99A4;
    font-size: 13px;
    font-weight: 400;
    line-height: 18px;
    white-space: normal;
    overflow-wrap: anywhere;
}

body .page-header .search-autocomplete .xbau-autocomplete-product-link {
    text-decoration: underline;
    text-underline-offset: 2px;
}

body .page-header .search-autocomplete .xbau-autocomplete-product:hover .product-primary,
body .page-header .search-autocomplete .xbau-autocomplete-product.selected .product-primary,
body .page-header .search-autocomplete .xbau-autocomplete-product:hover .product-name,
body .page-header .search-autocomplete .xbau-autocomplete-product.selected .product-name {
    color: #1E99A4;
}

body .page-header .search-autocomplete .autocomplete-list > .xbau-autocomplete-category {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 3px;
    min-height: 52px;
    padding: 8px 12px !important;
    overflow: hidden;
    text-align: left;
    border: 1px solid rgba(77, 77, 79, .12) !important;
    border-radius: 10px;
}

body .page-header .search-autocomplete .xbau-autocomplete-category .category-mini-crumb {
    display: block;
    width: 100%;
    min-width: 0;
    color: #9C9EA1;
    font-size: 11px;
    font-style: normal;
    font-weight: 400;
    line-height: 16px;
    text-align: left;
    white-space: normal;
    overflow-wrap: anywhere;
}

body .page-header .search-autocomplete .xbau-autocomplete-category .category-mini-crumb:empty {
    display: none;
}

body .page-header .search-autocomplete .xbau-autocomplete-category .qs-option-name {
    display: block;
    width: 100%;
    min-width: 0;
    color: #1E99A4;
    font-size: 14px;
    font-weight: 500;
    line-height: 20px;
    text-align: left;
    white-space: normal;
    overflow-wrap: anywhere;
}

body .page-header .search-autocomplete .autocomplete-list > dd:not(.xbau-autocomplete-product):not(.xbau-autocomplete-category) {
    padding: 7px 10px !important;
    overflow-wrap: anywhere;
    border-radius: 8px;
}

@media (max-width: 767px) {
    body .page-header .search-mobile .field.search .control {
        position: relative;
    }

    body .page-header .search-mobile .search-autocomplete {
        right: 0 !important;
        left: 0 !important;
        width: 100% !important;
        max-width: 100%;
        margin-top: 8px;
    }

    body .page-header .search-autocomplete .autocomplete-list {
        gap: 8px;
        padding: 12px;
    }

    body .page-header .search-autocomplete .xbau-autocomplete-product {
        gap: 10px;
        min-height: 70px;
        padding: 8px 10px !important;
    }

    body .page-header .search-autocomplete .xbau-autocomplete-product .product-image-box {
        flex-basis: 50px;
        width: 50px;
        height: 50px;
    }

    body .page-header .search-autocomplete .xbau-autocomplete-product .product-image-box img {
        max-width: 50px;
        max-height: 50px;
    }
}

@media (max-width: 359px) {
    body .page-header .search-autocomplete .autocomplete-list {
        padding: 10px;
    }

    body .page-header .search-autocomplete .xbau-autocomplete-product {
        gap: 8px;
        padding: 8px !important;
    }
}

@media (prefers-reduced-motion: reduce) {
    body .page-header .search-autocomplete * {
        scroll-behavior: auto !important;
    }
}
