.filter-bar {
    width: 100%;
    background: white;
    margin-bottom:80px;
}

.filter-bar__container {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    --min: 16;
    --max: 16;
    --mintrans: 1000;
    --maxtrans: 1920;
    font-size: clamp(var(--min) * 1px, calc((var(--max) - var(--min)) * ((100vw - var(--mintrans) * 1px) / (var(--maxtrans) - var(--mintrans))) + var(--min) * 1px), var(--max) * 1px) !important;
}

.filter-bar__filters {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin-left: auto;
}

.filter-bar__filter {
    position: relative;
    min-width: 180px;
}

.filter-bar__dropdown-trigger {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border-bottom: solid 1px #000000;
    color: var(--color-text-default, #333);
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative; 
    gap: 10px;
}

.filter-bar__dropdown-trigger--active {
    border-color: #000000;
}

.filter-bar__dropdown-trigger--open {
    border-color: var(--color-primary, #0066cc);
}

.filter-bar__label {
    flex: 1;
    text-align: left;
}

.filter-bar__placeholder {
    color: #000;
}

.filter-bar__selected {
    color: #000000;
    font-weight: 500;
}

.filter-bar__count-badge {
    position: absolute;
    top: -8px;
    right: 24px;
    background: #000;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    z-index: 10;
}

.filter-bar__chevron {
    transition: transform 0.2s ease;
    color: #000000;
}

.filter-bar__chevron--up {
    transform: rotate(180deg);
}

.filter-bar__dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 50;
    margin-top: 0.25rem;
    background: white;
    border: 1px solid #e9ecef;
    overflow: hidden;
}

.filter-bar__dropdown--enter {
    transition: all 0.2s ease;
}

.filter-bar__dropdown--enter-start {
    opacity: 0;
    transform: translateY(-8px) scale(0.95);
}

.filter-bar__dropdown--enter-end {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.filter-bar__dropdown--leave {
    transition: all 0.15s ease;
}

.filter-bar__dropdown--leave-start {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.filter-bar__dropdown--leave-end {
    opacity: 0;
    transform: translateY(-8px) scale(0.95);
}

.filter-bar__dropdown-content {
    max-height: 200px;
    overflow-y: auto;
}

.filter-bar__option {
    width: 100%;
    padding: 0.75rem 1rem;
    text-align: left;
    background: none;
    border: none;
    color: var(--color-text-default, #333);
    cursor: pointer;
    transition: background-color 0.15s ease;
}


.filter-bar__option--selected {
    color: var(--color-primary, #0066cc);
    font-weight: 500;
}

.filter-bar__actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.filter-bar__reset {
    padding: 0.75rem;
    background: transparent;
    border: 2px solid #e9ecef;
    color: var(--color-text-secondary, #666);
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: center;
}

.filter-bar__reset:hover {
    border-color: var(--color-danger, #dc3545);
    color: var(--color-danger, #dc3545);
    background: rgba(220, 53, 69, 0.05);
}

.filter-bar__reset:hover img {
    filter: var(--filter-color-danger);
}

.filter-bar__search {
    padding: 0.75rem;
    background: #000;
    border: 2px solid var(--color-primary, #0066cc);
    color: white;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0;
}


.filter-bar__search img {
    filter: brightness(0) saturate(100%) invert(100%) sepia(61%) saturate(352%) hue-rotate(183deg) brightness(101%) contrast(107%);
}

.filter-bar__search:hover {
    background: var(--color-primary-dark, #0052a3);
    border-color: var(--color-primary-dark, #0052a3);
    transform: translateY(-1px);
}

.filter-bar__search:active {
    transform: translateY(0);
}

.filter-bar__icon {
    width: 20px;
    height: 20px;
    display: block;
}

.filter-bar__option-wrapper:has(.filter-bar__option--selected) {
    background-color: rgba(var(--color-primary-rgb, 0, 102, 204), 0.1);
}

.filter-bar__option-wrapper {
    display: flex;
    padding-inline: 12px;
}

.filter-bar__checkbox {
    background-color: green;
}

/* Responsive */
@media (max-width: 768px) {
    .filter-bar {
        padding-block: 1rem;
    }

    .filter-bar__container {
        flex-direction: column;
        align-items: stretch;
        position: relative
    }

    .filter-bar__filters {
        flex-direction: column;
        width: 100%;
    }

    .filter-bar__filter {
        min-width: auto;
    }

    .filter-bar__actions {
        justify-content: space-between;
        position: absolute;
        bottom: -64px;
    }
    .reports-container {
        padding-top: 2rem;
    }
    
}

@media (max-width: 480px) {

    .filter-bar__reset,
    .filter-bar__search {
        width: 100%;
        justify-content: center;
    }

}


.filter-bar__range-input {
    accent-color: var(--color-primary, #0576E5);
    width: 100%;
}