/* Dynamax Filter Lite - Ultra Compact Design */
.dynamax-filter-lite {
    background: linear-gradient(to right, #2d3748, #1e293b);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    border-radius: 3px;
    color: #f8fafc;
    position: relative;
    display: block;
    overflow: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    max-width: 100%;
    width: 100%;
}

/* Header - Matching Event Calendar Style */
.dynamax-filter-lite h4 {
    background: #cc0033;
    color: #ffffff;
    font: 900 20px/1.2 "Helvetica Neue", Arial, sans-serif;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    padding: 30px 20px; /*15px 20px*/
    margin: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
}

.dynamax-filter-lite h4::before {
    content: "🔧";
    margin-right: 12px;
    font-size: 18px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}



/* Inline layout for desktop */
@media (min-width: 992px) {
    .dynamax-filter-lite .filter-controls {
        display: flex;
        align-items: stretch;
        gap: 8px;
        padding: 50px 15px 34px 15px;/*20px 15px 12px 15px*/
        flex-wrap: nowrap;
    }
    
    .dynamax-filter-lite .filter-controls > div {
        display: flex;
        align-items: stretch;
        margin-bottom: 0;
        min-height: 38px;
    }
    
    .dynamax-filter-lite .filter-controls .col-md-2:first-child {
        flex: 1;
        min-width: 200px; /*280*/
    }
    
    .dynamax-filter-lite .filter-controls .col-md-3 {
        flex: 1;
        min-width: 200px;
    }
    
    .dynamax-filter-lite .filter-controls .col-md-2:last-child {
        flex: 1;
        min-width: 200px;
    }
    
    .dynamax-filter-lite .filter-controls .form-group {
        margin-bottom: 0;
        width: 100%;
        display: flex;
        align-items: center;
        height: 38px;
        justify-content: center;
    }
}

/* Tablet layout */
@media (min-width: 768px) and (max-width: 991px) {
    .dynamax-filter-lite .filter-controls .col-sm-6 {
        width: 50%;
        float: left;
        padding: 0 2px;
    }
    
    .dynamax-filter-lite .filter-controls .col-sm-6:nth-child(odd) {
        clear: left;
    }
    
    .dynamax-filter-lite .filter-controls .col-sm-12 {
        width: 100%;
        margin-bottom: 4px;
    }
}

/* Vehicle Type Icons - Perfect alignment with form elements */
.dynamax-filter-lite .category_list {
    display: flex;
    gap: 6px;
    margin: 0;
    list-style: none;
    padding: 0;
    justify-content: flex-start;
    align-items: center;
    height: 38px;
}

.dynamax-filter-lite .category_list_inline {
    justify-content: flex-start;
    align-items: center;
    flex-wrap: nowrap;
    height: 38px;
}

.dynamax-filter-lite .category_list .category_icon {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    padding: 0;
    cursor: pointer;
    transition: all 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    min-width: 38px;
    min-height: 38px;
    box-sizing: border-box;
}

.dynamax-filter-lite .category_list .category_icon_circle {
    border-radius: 50%;
    width: 38px;
    height: 38px;
    min-width: 38px;
    min-height: 38px;
    padding: 0;
}

.dynamax-filter-lite .category_list .category_icon:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: #cc0033;
    transform: scale(1.05);
}

.dynamax-filter-lite .category_list .category_icon.active {
    background: #cc0033;
    border-color: #cc0033;
    box-shadow: 0 1px 3px rgba(204, 0, 51, 0.4);
}

.dynamax-filter-lite .category_list .category_icon img {
    width: 20px;
    height: 20px;
    filter: brightness(0) invert(1);
}

/* Form Controls - Matching Select2 red theme exactly */
.dynamax-filter-lite .form-control {
    background: #1a1a1a !important;
    border: 1px solid #cc0033 !important;
    border-radius: 6px !important;
    color: #ffffff !important;
    height: 38px !important;
    font: 400 14px/36px system-ui, sans-serif !important;
    padding: 0 12px !important;
    transition: all 0.15s ease !important;
    width: 100% !important;
    box-sizing: border-box !important;
    vertical-align: top !important;
    margin: 0 !important;
    //*min-width: 280px !important; */
    -webkit-border-radius: 6px !important;
    -moz-border-radius: 6px !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
}

.dynamax-filter-lite .form-control:hover {
    border-color: #e60039 !important;
    background: #222222 !important;
}

.dynamax-filter-lite .form-control:focus {
    border-color: #cc0033 !important;
    box-shadow: 0 0 0 3px rgba(204, 0, 51, 0.2) !important;
    background: #1a1a1a !important;
    outline: none !important;
}

.dynamax-filter-lite .form-control::placeholder {
    color: #cccccc !important;
}

/* Select2 Styling - Red theme with strong overrides */
.dynamax-filter-lite .select2-container,
.dynamax-filter-lite .select2-container--default {
    width: 100% !important;
    height: 38px !important;
    margin: 0 !important;
    min-width: 200px !important; /*280*/
}

.dynamax-filter-lite .select2-container .select2-selection--single,
.dynamax-filter-lite .select2-container--default .select2-selection--single {
    background: #1a1a1a !important;
    border: 1px solid #cc0033 !important;
    border-radius: 6px !important;
    color: #ffffff !important;
    height: 38px !important;
    font-size: 14px !important;
    line-height: 36px !important;
    transition: all 0.15s ease !important;
    box-sizing: border-box !important;
    -webkit-border-radius: 6px !important;
    -moz-border-radius: 6px !important;
    padding: 0 !important;
}

.dynamax-filter-lite .select2-container .select2-selection--single:hover,
.dynamax-filter-lite .select2-container--default .select2-selection--single:hover {
    border-color: #e60039 !important;
    background: #222222 !important;
}

.dynamax-filter-lite .select2-container--focus .select2-selection--single,
.dynamax-filter-lite .select2-container.select2-container--focus .select2-selection--single,
.dynamax-filter-lite .select2-container--default.select2-container--focus .select2-selection--single {
    border-color: #cc0033 !important;
    box-shadow: 0 0 0 3px rgba(204, 0, 51, 0.2) !important;
    outline: none !important;
    background: #1a1a1a !important;
}

.dynamax-filter-lite .select2-container .select2-selection__rendered,
.dynamax-filter-lite .select2-container--default .select2-selection__rendered {
    color: #ffffff !important;
    line-height: 36px !important;
    padding: 0 40px 0 12px !important;
    font: 400 14px/36px system-ui, sans-serif !important;
    margin: 0 !important;
    text-overflow: ellipsis !important;
}

.dynamax-filter-lite .select2-container .select2-selection__placeholder,
.dynamax-filter-lite .select2-container--default .select2-selection__placeholder {
    color: #cccccc !important;
}

.dynamax-filter-lite .select2-container .select2-selection__arrow {
    height: 38px !important;
    right: 12px !important;
    width: 20px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    top: 0 !important;
    position: absolute !important;
}

.dynamax-filter-lite .select2-container .select2-selection__arrow b {
    border: 5px solid transparent !important;
    border-top-color: #cc0033 !important;
    border-width: 5px 4px 0 4px !important;
    margin: 0 !important;
    top: 0 !important;
    left: 0 !important;
    position: static !important;
}

.dynamax-filter-lite .select2-container--open .select2-selection__arrow b {
    border-top-color: transparent !important;
    border-bottom-color: #cc0033 !important;
    border-width: 0 4px 5px 4px !important;
}

/* Select2 Dropdown styling - Red theme with strong overrides */
.select2-dropdown,
.dynamax-filter-lite .select2-dropdown {
    background: #1a1a1a !important;
    border: 1px solid #cc0033 !important;
    border-radius: 6px !important;
    box-shadow: 0 10px 15px -3px rgba(204, 0, 51, 0.3) !important;
    z-index: 9999 !important;
}

.select2-results__option,
.dynamax-filter-lite .select2-results__option {
    background: transparent !important;
    color: #ffffff !important;
    padding: 10px 16px !important;
    font: 400 14px/1.4 system-ui, sans-serif !important;
    cursor: pointer !important;
    border: none !important;
}

.select2-results__option--highlighted,
.dynamax-filter-lite .select2-results__option--highlighted {
    background: #cc0033 !important;
    color: #ffffff !important;
}

.select2-results__option--selected,
.dynamax-filter-lite .select2-results__option--selected {
    background: #333333 !important;
    color: #ffffff !important;
}

.select2-search--dropdown .select2-search__field,
.dynamax-filter-lite .select2-search--dropdown .select2-search__field {
    background: #333333 !important;
    border: 1px solid #cc0033 !important;
    color: #ffffff !important;
    border-radius: 6px !important;
    padding: 8px 12px !important;
    font-size: 14px !important;
}

.select2-search--dropdown .select2-search__field:focus,
.dynamax-filter-lite .select2-search--dropdown .select2-search__field:focus {
    border-color: #e60039 !important;
    box-shadow: 0 0 0 3px rgba(204, 0, 51, 0.2) !important;
    outline: none !important;
}

/* Additional overrides for Select2 open state */
.dynamax-filter-lite .select2-container--open .select2-selection--single {
    border-color: #cc0033 !important;
    box-shadow: 0 0 0 3px rgba(204, 0, 51, 0.2) !important;
}

/* Global overrides to ensure red theme takes precedence */
body .select2-container--default .select2-selection--single,
body .dynamax-filter-lite .select2-container--default .select2-selection--single,
.select2-container--default .select2-selection--single,
.select2-container .select2-selection--single {
    background: #1a1a1a !important;
    border: 1px solid #cc0033 !important;
    color: #ffffff !important;
    border-radius: 6px !important;
    -webkit-border-radius: 6px !important;
    -moz-border-radius: 6px !important;
    height: 38px !important;
    font-size: 14px !important;
    line-height: 36px !important;
    box-sizing: border-box !important;
    padding: 0 !important;
}

body .select2-container--default .select2-selection--single .select2-selection__rendered,
body .dynamax-filter-lite .select2-container--default .select2-selection--single .select2-selection__rendered,
.select2-container--default .select2-selection--single .select2-selection__rendered,
.select2-container .select2-selection--single .select2-selection__rendered {
    color: #ffffff !important;
    line-height: 36px !important;
    padding: 0 40px 0 12px !important;
    font: 400 14px/36px system-ui, sans-serif !important;
    margin: 0 !important;
}

body .select2-container--default .select2-selection--single .select2-selection__arrow b,
body .dynamax-filter-lite .select2-container--default .select2-selection--single .select2-selection__arrow b,
.select2-container--default .select2-selection--single .select2-selection__arrow b,
.select2-container .select2-selection--single .select2-selection__arrow b {
    border-top-color: #cc0033 !important;
    margin: 0 !important;
    top: 0 !important;
    left: 0 !important;
    position: static !important;
}

body .select2-container--default .select2-selection--single:hover,
body .dynamax-filter-lite .select2-container--default .select2-selection--single:hover,
.select2-container--default .select2-selection--single:hover,
.select2-container .select2-selection--single:hover {
    border-color: #e60039 !important;
    background: #222222 !important;
}

body .select2-container--default.select2-container--focus .select2-selection--single,
body .dynamax-filter-lite .select2-container--default.select2-container--focus .select2-selection--single,
.select2-container--default.select2-container--focus .select2-selection--single,
.select2-container.select2-container--focus .select2-selection--single {
    border-color: #cc0033 !important;
    box-shadow: 0 0 0 3px rgba(204, 0, 51, 0.2) !important;
    background: #1a1a1a !important;
}

/* Additional Select2 border radius overrides for all states */
.dynamax-filter-lite .select2-container--default .select2-selection--single,
.dynamax-filter-lite .select2-container--focus .select2-selection--single,
.dynamax-filter-lite .select2-container--open .select2-selection--single,
.select2-container--default .select2-selection--single,
.select2-container .select2-selection--single {
    border-radius: 6px !important;
    -webkit-border-radius: 6px !important;
    -moz-border-radius: 6px !important;
}

/* Ensure dropdown has consistent border radius */
.select2-dropdown,
.dynamax-filter-lite .select2-dropdown {
    border-radius: 6px !important;
    -webkit-border-radius: 6px !important;
    -moz-border-radius: 6px !important;
}

/* Additional arrow positioning fixes for all Select2 instances */
.select2-container .select2-selection__arrow,
.dynamax-filter-lite .select2-container .select2-selection__arrow,
.select2-container--default .select2-selection__arrow {
    height: 38px !important;
    right: 12px !important;
    width: 20px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    top: 0 !important;
    position: absolute !important;
}

.select2-container .select2-selection__arrow b,
.dynamax-filter-lite .select2-container .select2-selection__arrow b,
.select2-container--default .select2-selection__arrow b {
    border: 5px solid transparent !important;
    border-top-color: #cc0033 !important;
    border-width: 5px 4px 0 4px !important;
    margin: 0 !important;
    top: 0 !important;
    left: 0 !important;
    position: static !important;
}

/* Force Select2 to match standard form control styling exactly */
.select2-selection,
.select2-selection--single,
.select2-container .select2-selection,
.select2-container .select2-selection--single,
.select2-container--default .select2-selection,
.select2-container--default .select2-selection--single,
#dynamax_filter_container .select2-container .select2-selection,
#dynamax_filter_container .select2-container .select2-selection--single,
#dynamax_filter_container .select2-container--default .select2-selection,
#dynamax_filter_container .select2-container--default .select2-selection--single {
    background: #1a1a1a !important;
    border: 1px solid #cc0033 !important;
    border-radius: 6px !important;
    color: #ffffff !important;
    height: 38px !important;
    font-size: 14px !important;
    line-height: 36px !important;
    box-sizing: border-box !important;
    padding: 0 12px !important;
    transition: all 0.15s ease !important;
    -webkit-border-radius: 6px !important;
    -moz-border-radius: 6px !important;
    max-width: 250px;
}

/* Force Select2 rendered text styling */
.select2-selection__rendered,
.select2-container .select2-selection__rendered,
.select2-container--default .select2-selection__rendered,
#dynamax_filter_container .select2-container .select2-selection__rendered,
#dynamax_filter_container .select2-container--default .select2-selection__rendered {
    color: #ffffff !important;
    line-height: 36px !important;
    padding: 0 40px 0 12px !important;
    font: 400 14px/36px system-ui, sans-serif !important;
    margin: 0 !important;
    text-overflow: ellipsis !important;
    background: transparent !important;
    border: none !important;
}

/* Force Select2 hover states */
.select2-selection:hover,
.select2-selection--single:hover,
.select2-container .select2-selection:hover,
.select2-container .select2-selection--single:hover,
.select2-container--default .select2-selection:hover,
.select2-container--default .select2-selection--single:hover,
#dynamax_filter_container .select2-container .select2-selection:hover,
#dynamax_filter_container .select2-container .select2-selection--single:hover,
#dynamax_filter_container .select2-container--default .select2-selection:hover,
#dynamax_filter_container .select2-container--default .select2-selection--single:hover {
    border-color: #e60039 !important;
    background: #222222 !important;
}

/* Force Select2 focus states */
.select2-selection:focus,
.select2-selection--single:focus,
.select2-container--focus .select2-selection,
.select2-container--focus .select2-selection--single,
.select2-container.select2-container--focus .select2-selection,
.select2-container.select2-container--focus .select2-selection--single,
.select2-container--default.select2-container--focus .select2-selection,
.select2-container--default.select2-container--focus .select2-selection--single,
#dynamax_filter_container .select2-container--focus .select2-selection,
#dynamax_filter_container .select2-container--focus .select2-selection--single,
#dynamax_filter_container .select2-container.select2-container--focus .select2-selection,
#dynamax_filter_container .select2-container.select2-container--focus .select2-selection--single,
#dynamax_filter_container .select2-container--default.select2-container--focus .select2-selection,
#dynamax_filter_container .select2-container--default.select2-container--focus .select2-selection--single {
    border-color: #cc0033 !important;
    box-shadow: 0 0 0 3px rgba(204, 0, 51, 0.2) !important;
    background: #1a1a1a !important;
    outline: none !important;
}

/* Search Button - Red theme matching Select2 */
.dynamax-filter-lite .btn-primary {
    background: linear-gradient(135deg, #cc0033, #e60039);
    border: none;
    border-radius: 6px;
    color: #ffffff;
    font: 600 14px/36px system-ui, sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0 12px;
    height: 38px;
    /*width: 100%;*/
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(204, 0, 51, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    box-sizing: border-box;
    margin: 0;
    vertical-align: top;
    min-width: 150px; /*280*/
}

.dynamax-filter-lite .btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #e60039, #ff1a4d);
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(204, 0, 51, 0.4);
}

.dynamax-filter-lite .btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(204, 0, 51, 0.3);
}

.dynamax-filter-lite .btn-primary:disabled {
    background: rgba(108, 117, 125, 0.6);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
    opacity: 0.6;
}

/* Grid Layout */
.dynamax-filter-lite .col-md-3,
.dynamax-filter-lite .col-md-2 {
    padding-left: 0;
    padding-right: 0;
    position: relative;
    min-height: 1px;
}

/* Desktop specific */
@media (min-width: 992px) {
    .dynamax-filter-lite .col-md-2,
    .dynamax-filter-lite .col-md-3 {
        float: none;
        display: block;
        padding: 0;
    }
}
@media (max-width: 1024px) {
    .select2-selection,
    .select2-selection--single,
    .select2-container .select2-selection,
    .select2-container .select2-selection--single,
    .select2-container--default .select2-selection,
    .select2-container--default .select2-selection--single,
    #dynamax_filter_container .select2-container .select2-selection,
    #dynamax_filter_container .select2-container .select2-selection--single,
    #dynamax_filter_container .select2-container--default .select2-selection,
    #dynamax_filter_container .select2-container--default .select2-selection--single {
        max-width: 550px;
    }
    .form-group {
        padding: 10px 0;
        display: flex;
        justify-content: center;
    }
    .row {
        margin-left: -15px;
        margin-right: -15px;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
}

/* Responsive Design */
@media (max-width: 767px) {
    .select2-selection,
    .select2-selection--single,
    .select2-container .select2-selection,
    .select2-container .select2-selection--single,
    .select2-container--default .select2-selection,
    .select2-container--default .select2-selection--single,
    #dynamax_filter_container .select2-container .select2-selection,
    #dynamax_filter_container .select2-container .select2-selection--single,
    #dynamax_filter_container .select2-container--default .select2-selection,
    #dynamax_filter_container .select2-container--default .select2-selection--single {
        max-width: 350px;
    }
    .form-group {
        padding: 10px 0;
        display: flex;
        justify-content: center;
    }
        .dynamax-filter-lite {
        margin: 3px 0;
    }
    
    .dynamax-filter-lite h4 {
        padding: 10px 15px;
        font-size: 16px;
    }
    
    .dynamax-filter-lite h4::before {
        font-size: 14px;
        margin-right: 8px;
    }
    
    .dynamax-filter-lite .row {
        padding: 0 40px; /*0 6px 4px 6px*/
    }
    
    .dynamax-filter-lite .col-xs-12 {
        width: 100%;
        margin-bottom: 3px;
        padding-left: 0;
        padding-right: 0;
    }
    
    .dynamax-filter-lite .category_list {
        gap: 2px;
        justify-content: center;
    }
    
    .dynamax-filter-lite .category_list .category_icon_circle {
        width: 22px;
        height: 22px;
        min-width: 22px;
        min-height: 22px;
        padding: 2px;
    }
    
    .dynamax-filter-lite .category_list .category_icon img {
        width: 12px;
        height: 12px;
    }
    
    .dynamax-filter-lite .form-control,
    .dynamax-filter-lite .btn-primary,
    .dynamax-filter-lite .select2-container .select2-selection--single {
        height: 22px !important;
        font-size: 10px !important;
    }
    
    .dynamax-filter-lite .select2-container .select2-selection__rendered {
        line-height: 20px !important;
        padding-left: 4px !important;
    }
    
    .dynamax-filter-lite .select2-container .select2-selection__arrow {
        height: 38px !important; /*20px*/
    }
    
    /* Mobile keeps vertical layout */
    .dynamax-filter-lite .filter-controls {
        display: block;
    }
    
    /* Reset flex for mobile */
    .dynamax-filter-lite .select2-container {
        width: 100% !important;
        flex: none !important;
    }
}

/* Results Page Styling */
.dynamax-results-lite {
    background: linear-gradient(to right, #2d3748, #1e293b);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border-radius: 4px;
    color: #f8fafc;
    margin: 10px 0;
    overflow: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.dynamax-results-lite .vehicle-info {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    padding: 10px;
    margin: 12px;
    margin-bottom: 12px;
}

.dynamax-results-lite .vehicle-info h4 {
    color: #cc0033;
    font: 600 14px/1.2 "Helvetica Neue", Arial, sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 6px 0;
}

.dynamax-results-lite .results-content {
    padding: 0 12px 12px 12px;
}

.dynamax-results-lite .panel-default {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    margin-bottom: 6px;
}

.dynamax-results-lite .panel-heading {
    background: rgba(204, 0, 51, 0.8);
    color: #ffffff;
    padding: 8px 10px;
    font: 500 12px/1.2 "Helvetica Neue", Arial, sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.dynamax-results-lite .panel-body {
    padding: 10px;
    color: #f8fafc;
    font-size: 12px;
}

.dynamax-results-lite .no-results {
    text-align: center;
    padding: 25px 12px;
    color: rgba(248, 250, 252, 0.6);
}

.dynamax-results-lite .no-results::before {
    content: "🔧";
    display: block;
    font-size: 24px;
    margin-bottom: 10px;
    opacity: 0.7;
}
