.products__head {
    border-radius: 30px 30px 0 0;
    padding: 12px 11px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 -82px 85px -15px #ffffff;
}
.products__head::before {
    /* content: ''; */
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgb(255 255 255 / 12%) 0%, rgb(0 64 255 / 18%) 70%);
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

.products-head__col {
    padding: 3px;
    flex: 1 1 calc(20% - 20px);
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
}

.products-head__col:hover {
    transform: translateY(-5px);
    border-radius: 10px;
}

.products-head__name {
    padding-bottom: 8px;
    position: relative;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.products-head__name:hover {
    color: #667eea;
    border-bottom-color: #667eea;
}

.products-head__name_sorter-top {
    position: relative;
}


.products-head__name_sorter-top.sort_desc::after {
    content: 'â†“';
    color: #764ba2;
    opacity: 1;
}

.products-head__select-container {
    position: relative;
    width: 100%;
}

.products-head__select-container::before {
    content: '▼';
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #3b82f6;
    font-size: 12px;
    pointer-events: none;
    transition: all 0.3s ease;
    z-index: 2;
}

.products-head__select-container:hover::before {
    color: #764ba2;
    transform: translateY(-50%) rotate(180deg);
}

.custom-select {
    width: 100%;
    padding: 12px 35px 12px 15px;
    font-size: 15px;
    font-weight: 500;
    color: #2d3748;
    background: #f7fafc;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    appearance: none;
    cursor: pointer;
    transition: all 0.3s ease;
    outline: none;
}

.custom-select:hover {
    background: white;
    border-color: #667eea;
    /* box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2); */
}

.custom-select:focus {
    border-color: #764ba2;
    box-shadow: 0 0 0 3px rgba(118, 75, 162, 0.2);
    background: white;
}

.custom-select option {
    padding: 12px;
    font-size: 14px;
    background: white;
    color: #2d3748;
}

.custom-select option:hover, .custom-select option:checked {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

button[onclick="resetFilters()"] {
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
    border-radius: 12px;
    padding: 12px 24px !important;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    /* margin: 10px !important; */
    min-width: 160px;
    position: relative;
    z-index: 1;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

button[onclick="resetFilters()"]:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.4);
    border-color: transparent;
}

button[onclick="resetFilters()"]:active {
    transform: translateY(0);
}

button[onclick="resetFilters()"]::before {
    /* content: 'â†º'; */
    margin-right: 8px;
    font-size: 18px;
    display: inline-block;
    transition: transform 0.5s ease;
}

button[onclick="resetFilters()"]:hover::before {
    transform: rotate(360deg);
}

@media (max-width: 1200px) {
    .products-head__col {
        flex: 1 1 calc(33.333% - 20px);
    }
}

@media (max-width: 992px) {

    .products-head__col {
        flex: 1 1 calc(50% - 20px);
        min-width: 200px;
    }
}

@media (max-width: 768px) {
    .products__head {
        padding: 15px 10px;
    }

    .products-head__col {
        flex: 1 1 100%;
        margin: 8px;
        padding: 0;
    }

    .products-head__name {
        font-size: 15px;
    }

    .custom-select {
        padding: 10px 30px 10px 12px;
        font-size: 14px;
    }

    button[onclick="resetFilters()"] {
        width: 100%;
        margin: 10px 8px !important;
    }
}

@media (max-width: 480px) {
    .products__head {
        border-radius: 15px;
    }

    .products-head__name {
        font-size: 14px;
        margin-bottom: 8px;
    }
}

.products-head__col.loading {
    position: relative;
    opacity: 0.7;
}

.products-head__col.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    animation: shimmer 1.5s infinite;
    border-radius: 16px;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(100%);
    }
}

.products-head__col:has(select:disabled) {
    opacity: 0.6;
    filter: grayscale(0.5);
}

.custom-select:disabled {
    background: #edf2f7;
    cursor: not-allowed;
    border-color: #cbd5e0;
}

.custom-select option:checked {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-weight: 600;
}

.products-head__name[title] {
    position: relative;
}

.products-head__name[title]:hover::after {
    content: attr(title);
    position: absolute;
    bottom: 100%;
    left: 0;
    background: #2d3748;
    color: white;
    padding: 5px 10px;
    border-radius: 6px;
    font-size: 12px;
    white-space: nowrap;
    z-index: 10;
    margin-bottom: 5px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.products-head__col {
    animation: fadeInUp 0.5s ease forwards;
    opacity: 0;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.products-head__col:nth-child(1) {
    animation-delay: 0.1s;
}

.products-head__col:nth-child(2) {
    animation-delay: 0.2s;
}

.products-head__col:nth-child(3) {
    animation-delay: 0.3s;
}

.products-head__col:nth-child(4) {
    animation-delay: 0.4s;
}

.products-head__col:nth-child(5) {
    animation-delay: 0.5s;
}

@media (prefers-color-scheme: dark) {
    .products__head {
        background: #ffffff;
        display: flex;
        flex-wrap: wrap;
        border-bottom: solid 1px #f1f5f9;
        align-items: end;
    }

    .products-head__name {
        color: #64748b;
        border-bottom-color: #4a5568;
    }

    .custom-select {
        background: #f1f5f9;
        color: #64748b;
        border-color: #f1f5f9;
    }

    .custom-select:hover {
        background: #ffffff;
        border-color: #667eea;
    }

    button[onclick="resetFilters()"] {
        background: #3b82f6;
        color: white;
        border-color: #f1f5f9;
    }
}