/* Smart Search Styles */

#smart-search-wrapper {
    position: relative;
}

#smart-search-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 4px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    z-index: 1000;
    max-height: 400px;
    overflow-y: auto;
}

#smart-search-dropdown.hidden {
    display: none;
}

.suggestion-item {
    padding: 8px 12px;
    cursor: pointer;
    transition: background-color 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-radius: 4px;
    margin: 2px 4px;
}

.suggestion-item:hover,
.suggestion-item.selected {
    background-color: #f0fdf4;
}

.suggestion-item i {
    width: 16px;
    margin-right: 12px;
    color: #9ca3af;
}

.suggestion-item strong {
    color: #16a34a;
    font-weight: 600;
}

#search-loading-indicator {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
}

/* Search Input Enhancement */
#search-question-bank:focus {
    outline: none;
    border-color: #22c55e;
    box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.1);
}

/* Search History Styles */
.search-history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 12px;
    margin-bottom: 4px;
}

.search-history-header button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    color: #ef4444;
    transition: color 0.15s ease;
}

.search-history-header button:hover {
    color: #dc2626;
}

/* Autocomplete Section Headers */
#smart-search-dropdown .section-header {
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    color: #6b7280;
    letter-spacing: 0.5px;
}

/* Quick Filters Enhancement */
.quick-filter-item {
    position: relative;
}

.quick-filter-item.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: #22c55e;
}

/* Mobile Responsive */
@media (max-width: 640px) {
    #smart-search-dropdown {
        position: fixed;
        top: auto;
        bottom: 0;
        left: 0;
        right: 0;
        margin: 0;
        border-radius: 16px 16px 0 0;
        max-height: 70vh;
    }

    .suggestion-item {
        padding: 12px 16px;
    }
}