.diamond-filters {
    margin: 20px 0;
    padding: 20px;
    /* background: #f8f8f8; */
    border-radius: 8px;
}

.diamond-filters span {
    font-size: 16px;
    font-weight: 400;
}

/* Common Filter Styles */
.filter-section {
    border-bottom: 1px solid #FFF0D6;
    margin-bottom: 1em !important;
    padding: 0 20px 40px;
}

.filter-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.filter-controls {
    display: flex;
    align-items: center;
    gap: 5px;
}

.clear-section {
    background: none;
    border: 1px solid #ddd;
    color: #666;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.clear-section:hover {
    background: #f0f0f0;
    border-color: #999;
    color: #333;
}

.toggle-filter-section {
    background: #f0f0f0;
    border: 1px solid #ddd;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 16px;
    color: #666;
    transition: all 0.2s ease;
    transform: rotate(45deg);
}

.toggle-filter-section:hover {
    background: #e0e0e0;
    color: #333;
}

.toggle-filter-section.collapsed {
    transform: rotate(0deg);
}

.filter-section h4 {
    margin: 0;
    font-size: 16px;
    color: #333;
    font-weight: 600;
}

.filter-section h5 {
    margin: 10px 0;
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

/* Checkbox Group Styles */
.checkbox-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.checkbox-label {
    display: inline-flex;
    align-items: center;
    background: white;
    border-radius: 8px;
    padding: 5px 10px;
    border: 1px solid #fedea7;
    color: black;
    position: relative;
    cursor: pointer;
    background: white;
    border-radius: 8px;
    padding: 5px 10px;
    border: 1px solid #fedea7;
    color: black;
}

.checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0 !important;
    height: 0 !important;
    margin: 0;
}

.checkbox-label input[type="checkbox"]:checked + span {
    color: #000;
    font-weight: bold;
}

.checkbox-label.selected {
    background: #FFF0D6;
    border-color: #fedea7;
}

/* Active Filters Styles */
.active-filters {
    border-bottom: 1px solid #FFF0D6;
    margin-bottom: 1em !important;
    padding: 0 0 10px 0;
}

.active-filters h4 {
    margin: 0 0 10px;
    font-size: 16px;
    color: #333;
    font-weight: 600;
}

.active-filters-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
    min-height: 32px;
}

.active-filter {
    display: inline-flex;
    align-items: center;
    padding: 6px 12px;
    cursor: pointer;
}

.clear-filter {
    margin-left: 8px;
    background: none;
    border: none;
    font-size: 16px;
    line-height: 1;
    padding: 0 2px;
    cursor: pointer;
}

.clear-all-filters {
    background: none;
    border: 1px solid #999;
    color: #666;
    padding: 6px 14px;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
}

.no-filters {
    color: #999;
    font-style: italic;
    font-size: 13px;
    padding: 6px 0;
}

/* Carat Range Inputs */
.range-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.range-inputs input[type="number"] {
    width: 100px;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.2s ease;
}

.range-inputs input[type="number"]:focus {
    border-color: #2196F3;
    outline: none;
}

.range-inputs span {
    color: #666;
    font-weight: 500;
}

.apply-carat-range {
    background: #4CAF50;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.2s ease;
    font-size: 14px;
}

.apply-carat-range:hover {
    background: #45a049;
}

/* Color Filter Styles */
.color-type-toggle {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.color-type-toggle .radio-label {
    /* display: inline-flex;
    align-items: center;
    cursor: pointer;
    padding: 6px 12px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 20px;
    transition: all 0.2s ease;
    font-size: 13px;
    color: #666;
    position: relative; */
}

.color-type-toggle .white-label {
    /* background: #e7f3ff;
    border-color: #2196F3;
    color: #2196F3;
    font-weight: 500; */
}

.color-type-toggle .white-label.selected {
    /* background: #e7f3ff;
    border-color: #2196F3;
    color: #2196F3;
    font-weight: 500; */
}

.color-type-toggle .radio-label:hover {
    /* background: #f5f5f5;
    border-color: #999;
    color: #333; */
}

.color-type-toggle input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    margin: 0;
}

.color-type-toggle input[type="radio"]:checked + span {
    color: #2196F3;
}

.color-type-toggle .radio-label:has(input[type="radio"]:checked) {
    /* background: #e7f3ff;
    border-color: #2196F3;
    color: #2196F3;
    font-weight: 500; */
}

/* For browsers that don't support :has */
.color-type-toggle .radio-label.selected {
    /* background: #e7f3ff;
    border-color: #2196F3;
    color: #2196F3;
    font-weight: 500; */
}

.fancy-color-section {
    margin-top: 15px;
}

.fancy-color-section.disabled {
    opacity: 0.5;
    pointer-events: none;
}

.white-color-section.disabled {
    opacity: 0.5;
    pointer-events: none;
}

.range-selects {
    display: flex;
    align-items: center;
    gap: 10px;
}

.range-selects select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    min-width: 100px;
}

.range-selects select:focus {
    border-color: #2196F3;
    outline: none;
}

/* Loading State */
.c-product-grid.loading:before {
    content: '';
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #2196F3;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    z-index: 1000;
}

.c-product-grid.loading:after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    z-index: 999;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Responsive Styles */
@media (max-width: 768px) {
    .range-inputs,
    .range-selects {
        flex-direction: column;
        align-items: flex-start;
    }

    .range-inputs input[type="number"],
    .range-selects select {
        width: 100%;
    }

    .checkbox-group {
        gap: 6px;
    }

    .checkbox-label {
        padding: 6px 10px;
        font-size: 12px;
    }

    .color-type-toggle {
        flex-direction: column;
        gap: 10px;
    }
}

/* Mobile adjustments */
@media (min-width: 768px) {
    .checkbox-group {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: flex-start;
    }
    
    .checkbox-label {
        width: auto;
    }
}

/* Selection Controls */
.selection-controls {
    display: none;
} 

span.shape-logo {
    max-width: 48px !important;
    display: flex;
}

.shape-options.checkbox-group > label  {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
}

.diamond-filters .shape-options.checkbox-group span {
    font-size: 12px !important;
}

@media screen and (min-width: 768px) {
    .filter-group{
        display: flex;
    }
}

.filter-section {
    display: block;
    width: 100%;
}

.color-type-toggle{
    margin-top: 0px;
}

.color-type-toggle .radio-label{
    /* margin-left: 10px; */
}

@media screen and (max-width: 768px) {
    .diamond-filters {
        padding: 5px;
    }

    .clear-all-filters{
        margin-bottom: 10px;
    }

    .active-filters {
    padding: 10px 0;
    }

    .filter-section {
        padding: 0 10px 10px;
    }

    .shape-options.checkbox-group > label {
        min-width: 120px;
    }

    .color-type-toggle{
        /* margin-top: 10px; */
    }

    .color-type-toggle .radio-label{
        margin-left: 0px;
    }

    .fancy-color-section{
        display: block !important;
    }

    .dash-mobile{
        display: none !important;
    }
}

/* Select2 dropdown styling */
.filter-group .select2-container--default .select2-selection--multiple {
    border: 1px solid #ddd;
    border-radius: 4px;
    min-height: 38px;
    height: auto !important;
}

.filter-group .select2-container--default .select2-selection--multiple .select2-selection__choice {
    background-color: #f0f0f0;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 0 5px;
    margin-right: 5px;
}

.filter-group .select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    color: #999;
    margin-right: 5px;
}

.filter-group .select2-container--default .select2-results__option--highlighted[aria-selected] {
    background-color: #0073aa;
    color: white;
}

.fancy-color-section {
    display: grid;
    grid-template-columns: auto 1fr 1fr;
    grid-gap: 5px;
}

button.clear-all-filters {
    border-radius: 0;
    color: #fff;
}

button.clear-filter {
    color: #fff;
}