/* Search: the suggestions under the search field (gfx/pol/search_suggest.js) and the categories above the search
   results (includes/advanced_search_result.php). Pictures are square boxes with object-fit: contain, so they are
   never stretched. Rows are at least 56px high for fingers. */

.search-suggest {
    z-index: 10050;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    background: #fff;
    border: 1px solid #e1e1e1;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    font-family: "Open Sans", Arial, sans-serif;
    text-align: left;
    -webkit-text-size-adjust: 100%;
}
.search-suggest.ss-loading {
    opacity: .85;
}
.search-suggest .ss-title {
    padding: 10px 14px 4px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .6px;
    text-transform: uppercase;
    color: #8a8a8a;
}
.search-suggest .ss-row {
    display: -webkit-box;
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    min-height: 56px;
    padding: 6px 14px;
    color: #171414;
    text-decoration: none;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.05);
}
.search-suggest .ss-row:hover,
.search-suggest .ss-row:focus,
.search-suggest .ss-row.ss-active {
    background: #f6f2f4;
    color: #171414;
    text-decoration: none;
}
.search-suggest .ss-pic {
    -webkit-flex: 0 0 48px;
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    margin-right: 12px;
    overflow: hidden;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 6px;
}
.search-suggest .ss-pic img {
    display: block;
    width: 100%;
    height: 100%;
    -o-object-fit: contain;
    object-fit: contain;
}
/* a category without a picture: a small grid sign */
.search-suggest .ss-pic-empty {
    background:
        linear-gradient(#c9b3bf, #c9b3bf) 13px 13px / 9px 9px no-repeat,
        linear-gradient(#c9b3bf, #c9b3bf) 25px 13px / 9px 9px no-repeat,
        linear-gradient(#c9b3bf, #c9b3bf) 13px 25px / 9px 9px no-repeat,
        linear-gradient(#c9b3bf, #c9b3bf) 25px 25px / 9px 9px no-repeat,
        #faf7f8;
}
/* a product without a picture: a plain box (the grid sign is for categories) */
.search-suggest .ss-product .ss-pic-empty {
    background: #f4f4f4;
}
.search-suggest .ss-text {
    display: -webkit-box;
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    -webkit-flex: 1 1 auto;
    flex: 1 1 auto;
    min-width: 0;
}
.search-suggest .ss-name {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 14px;
    line-height: 1.3;
}
.search-suggest .ss-name b {
    font-weight: 700;
    color: #A64273;
}
.search-suggest .ss-parent {
    margin-top: 2px;
    font-size: 12px;
    color: #8a8a8a;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.search-suggest .ss-count {
    -webkit-flex: 0 0 auto;
    flex: 0 0 auto;
    margin-left: 10px;
    padding: 3px 8px;
    font-size: 12px;
    color: #6b6b6b;
    background: #f3f3f3;
    border-radius: 12px;
    white-space: nowrap;
}
.search-suggest .ss-price {
    margin-top: 3px;
    font-size: 14px;
    font-weight: 700;
    color: #A64273;
}
.search-suggest .ss-price s {
    margin-right: 4px;
    font-size: 12px;
    font-weight: 400;
    color: #8a8a8a;
}
.search-suggest .ss-all {
    -webkit-justify-content: center;
    justify-content: center;
    min-height: 50px;
    margin-top: 4px;
    border-top: 1px solid #eee;
    font-size: 14px;
    font-weight: 600;
    color: #A64273;
}
.search-suggest .ss-all:hover,
.search-suggest .ss-all.ss-active {
    color: #A64273;
}
.search-suggest .ss-empty {
    padding: 18px 14px;
    font-size: 14px;
    color: #6b6b6b;
}

/* the categories above the search results */
.search-categories {
    margin: 10px 0 22px;
    padding: 0 10px;
    text-align: left;
}
.search-section-title {
    margin: 0 0 12px;
    padding: 0 10px;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: .3px;
    text-transform: uppercase;
    color: #171414;
}
.search-categories-list {
    display: -webkit-box;
    display: -webkit-flex;
    display: flex;
    -webkit-flex-wrap: wrap;
    flex-wrap: wrap;
    margin: 0 -5px;
}
.search-category {
    display: -webkit-box;
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    width: calc(25% - 10px);
    min-height: 72px;
    margin: 0 5px 10px;
    padding: 8px 12px 8px 8px;
    background: #fff;
    border: 1px solid #e1e1e1;
    border-radius: 10px;
    color: #171414;
    text-decoration: none;
    transition: border-color .2s, box-shadow .2s;
}
.search-category:hover,
.search-category:focus {
    border-color: #bdbdbd;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    color: #171414;
    text-decoration: none;
}
.search-category-image {
    -webkit-flex: 0 0 56px;
    flex: 0 0 56px;
    width: 56px;
    height: 56px;
    margin-right: 12px;
    overflow: hidden;
    border-radius: 6px;
    background:
        linear-gradient(#c9b3bf, #c9b3bf) 16px 16px / 10px 10px no-repeat,
        linear-gradient(#c9b3bf, #c9b3bf) 30px 16px / 10px 10px no-repeat,
        linear-gradient(#c9b3bf, #c9b3bf) 16px 30px / 10px 10px no-repeat,
        linear-gradient(#c9b3bf, #c9b3bf) 30px 30px / 10px 10px no-repeat,
        #faf7f8;
}
.search-category-image img {
    display: block;
    width: 100%;
    height: 100%;
    -o-object-fit: contain;
    object-fit: contain;
    background: #fff;
}
.search-category-text {
    display: -webkit-box;
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
    min-width: 0;
}
.search-category-text b {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-size: 14px;
    line-height: 1.3;
}
.search-category-parent,
.search-category-count {
    margin-top: 2px;
    font-size: 12px;
    color: #8a8a8a;
}
.search-category-count {
    color: #A64273;
    font-weight: 600;
}
/* the filter of the search results by the categories of the found products: chips (links), the chosen ones
   filled; at least 40px high for fingers */
.search-filter {
    margin: 0 0 18px;
    padding: 0 10px;
    text-align: left;
}
.search-filter-title {
    margin-bottom: 8px;
    font-size: 13px;
    color: #6b6b6b;
}
.search-filter-chips {
    display: -webkit-box;
    display: -webkit-flex;
    display: flex;
    -webkit-flex-wrap: wrap;
    flex-wrap: wrap;
    -webkit-align-items: center;
    align-items: center;
}
.search-chip,
.search-chip-clear,
.search-filter-more > summary {
    display: -webkit-inline-box;
    display: -webkit-inline-flex;
    display: inline-flex;
    -webkit-align-items: center;
    align-items: center;
    min-height: 40px;
    margin: 0 8px 8px 0;
    padding: 6px 14px;
    border: 1px solid #d9d9d9;
    border-radius: 20px;
    background: #fff;
    color: #171414;
    font-size: 14px;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0.05);
    transition: border-color .2s, background-color .2s;
}
.search-chip small {
    margin-left: 6px;
    font-size: 12px;
    color: #8a8a8a;
}
.search-chip:hover,
.search-chip:focus {
    border-color: #A64273;
    color: #171414;
    text-decoration: none;
}
.search-chip.search-chip-on {
    border-color: #A64273;
    background: #A64273;
    color: #fff;
}
.search-chip.search-chip-on small {
    color: #f3dbe7;
}
/* a tick before a chosen category */
.search-chip.search-chip-on:before {
    content: "";
    width: 5px;
    height: 10px;
    margin: -3px 9px 0 0;
    border-right: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(45deg);
}
.search-chip-clear {
    border-color: transparent;
    background: #f3f3f3;
    color: #6b6b6b;
}
.search-chip-clear:hover,
.search-chip-clear:focus {
    color: #171414;
    text-decoration: none;
}
.search-filter-more {
    display: inline;
}
.search-filter-more > summary {
    list-style: none;
    color: #A64273;
    border-style: dashed;
}
.search-filter-more > summary::-webkit-details-marker {
    display: none;
}
.search-filter-more[open] > summary {
    display: none;
}
.search-filter-more[open] {
    display: block;
    -webkit-flex-basis: 100%;
    flex-basis: 100%;
}
/* the filters by the characteristics of the inArt products (includes/functions/inart_filter.php) under one button */
.inart-search-more {
    margin: 0 0 14px;
    padding: 0 10px;
}
.inart-search-more > summary {
    display: -webkit-inline-box;
    display: -webkit-inline-flex;
    display: inline-flex;
    -webkit-align-items: center;
    align-items: center;
    min-height: 40px;
    max-width: 100%;
    padding: 6px 16px;
    border: 1px solid #A64273;
    border-radius: 20px;
    color: #A64273;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    list-style: none;
}
.inart-search-more > summary::-webkit-details-marker {
    display: none;
}
.inart-search-more > summary span {
    margin-left: 4px;
    overflow: hidden;
    font-weight: 400;
    color: #6b6b6b;
    white-space: nowrap;
    text-overflow: ellipsis;
}
/* an arrow that turns when the filters are open */
.inart-search-more > summary:after {
    content: "";
    -webkit-flex: 0 0 auto;
    flex: 0 0 auto;
    width: 7px;
    height: 7px;
    margin: -4px 0 0 10px;
    border-right: 2px solid #A64273;
    border-bottom: 2px solid #A64273;
    transform: rotate(45deg);
}
.inart-search-more[open] > summary:after {
    margin-top: 4px;
    transform: rotate(-135deg);
}
.inart-search-more[open] > summary {
    margin-bottom: 14px;
}
.inart-search-more .search-filter {
    padding: 0;
}

/* the old ФИЛТРИРАЙ button has no filter column on the search page */
.search-filter ~ .productlistContainer .mob-filter-button {
    display: none !important;
}

@media (max-width: 1199px) {
    .search-category {
        width: calc(33.333% - 10px);
    }
}
@media (max-width: 991px) {
    .search-category {
        width: calc(50% - 10px);
    }
}
@media (max-width: 480px) {
    .search-category {
        width: calc(100% - 10px);
        min-height: 64px;
    }
}
