/**
 * Search and filter styles
 * Based on original DC Airparts styles but without RFQ functionality
 */

/* Search form */
.searchform-filter,
.searchform {
    margin-bottom: 2rem;
}

.searchform-wrap {
    position: relative;
    max-width: 100%;
}

.searchform-wrap .search-field {
    border-radius: 0;
    height: 40px;
    outline: 1px solid;
    padding: 8px;
    flex-grow: 1;
    min-width: 16em;
    font-family: inherit;
    font-size: 14px;
    line-height: 1.5;
    color: #171A46;
    text-overflow: ellipsis;
    width: 100%;
}

.searchform-wrap .search-field:focus-visible {
    outline: 1px solid;
}

.searchform-wrap button[type="submit"] {
    border-radius: 0;
    border: none;
    height: 40px;
    width: 40px;
    position: absolute;
    right: 0;
    top: 0;
    background-color: #FF671D;
    color: #FFFFFF;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' version='1.1' id='Ebene_1' x='0px' y='0px' viewBox='0 0 24 24' style='enable-background:new 0 0 24 24;' xml:space='preserve'%3E%3Cstyle type='text/css'%3E .st0%7Bfill:%23FFFFFF;%7D%0A%3C/style%3E%3Cpath class='st0' d='M17.5,15h-1.1l-0.4-0.4c1.3-1.6,2.1-3.5,2.1-5.6c0-4.9-4-8.9-8.9-8.9S0.2,4.1,0.2,9s4,8.9,8.9,8.9 c2.1,0,4.1-0.8,5.6-2.1l0.4,0.4v1.1l6.9,6.8l2-2L17.5,15z M9.2,15c-3.3,0-6-2.7-6-6s2.7-6,6-6s6,2.7,6,6S12.5,15,9.2,15z'/%3E%3C/svg%3E");
    background-size: 18px;
    background-position: center;
    background-repeat: no-repeat;
}

.searchform-wrap .search-form-hint,
.searchform-wrap .search-form-hint-mobile {
    font-size: 12px;
    color: #9091a7;
    margin-top: 5px;
}

.searchform-wrap .search-form-hint-mobile {
    display: none;
}

@media (max-width: 480px) {
    .searchform-wrap .search-form-hint {
        display: none;
    }
    .searchform-wrap .search-form-hint-mobile {
        display: block;
    }
}

/* Filter styles */
.filter-header {
    background-color: #ededee;
    padding: 10px 15px;
    cursor: pointer;
    position: relative;
    margin-bottom: 1px;
}

.filter-header::after {
    content: '';
    width: 12px;
    height: 12px;
    border-right: 2px solid #171A46;
    border-bottom: 2px solid #171A46;
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-75%) rotate(45deg);
    transition: transform 0.3s ease;
}

.filter-header.active::after {
    transform: translateY(-25%) rotate(-135deg);
}

.filter-count {
    display: flex;
    gap: 5px;
    align-items: center;
}

.filter-count .count {
    display: inline-block;
    background-color: #FF671D;
    border-radius: 50%;
    color: white;
    width: 20px;
    height: 20px;
    text-align: center;
    line-height: 20px;
    font-size: 12px;
}

.filter-body {
    display: none;
    background-color: #f7f7f7;
    padding: 15px;
    border: 1px solid #ededee;
}

.filter-cat {
    margin-bottom: 15px;
}

.filter-cat p {
    font-weight: bold;
    margin-bottom: 10px;
}

.filter-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.filter-list label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.filter-list input {
    cursor: pointer;
}

/* Search results page styles */
.product-table-search-results .loading {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.7);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-table-search-results .loading::after {
    content: '';
    width: 50px;
    height: 50px;
    border: 5px solid #ededee;
    border-top: 5px solid #FF671D;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.product-table-search-results .info {
    margin: 15px 0;
}

.product-table-search-results .products {
    display: none;
}

.product-table-search-results .products.show-entries {
    display: block;
}

.product-table-search-results .wrap-empty-search-response {
    margin: 30px 0;
    padding: 20px;
    background-color: #f7f7f7;
    border: 1px solid #ededee;
    text-align: center;
}

.product-table-search-results .wrap-empty-search-response.hidden {
    display: none;
}

/* Term names on category pages */
.term-names {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.term-names .mfr-cats {
    background-color: #ededee;
    padding: 5px 10px;
    border-radius: 3px;
    font-size: 14px;
}

/* Category manufacturer template */
.cat-mfr-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.cat-mfr-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
}

.cat-mfr-header img {
    max-height: 60px;
    width: auto;
}

.wrap-search-columns {
    margin-top: 30px;
} 