/* Advanced Search Component Styles */

/* Search highlight styling */
.search-highlight {
    background-color: #fff3cd;
    color: #856404;
    padding: 2px 4px;
    border-radius: 3px;
    font-weight: 600;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

/* Advanced search form styling */
.advanced-search-form {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.advanced-search-form .form-control:focus,
.advanced-search-form .form-select:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

/* Search input group styling */
.search-input-group {
    position: relative;
}

.search-input-group .input-group-text {
    background: linear-gradient(135deg, #0d6efd 0%, #0b5ed7 100%);
    border-color: #0d6efd;
    color: #000;
}

.search-input-group .form-control {
    border-left: none;
}

.search-input-group .form-control:focus {
    border-left: none;
    box-shadow: none;
}

/* Column selector styling */
.column-selector {
    border: 1px solid #ced4da;
    border-radius: 0.375rem;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.column-selector:focus {
    border-color: #0d6efd;
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

/* Search button styling */
.search-btn {
    background: linear-gradient(135deg, #0d6efd 0%, #0b5ed7 100%);
    border: none;
    transition: all 0.3s ease;
}

.search-btn:hover {
    background: linear-gradient(135deg, #0b5ed7 0%, #0a58ca 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(13, 110, 253, 0.3);
}

/* Clear button styling */
.clear-btn {
    background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%);
    border: none;
    transition: all 0.3s ease;
}

.clear-btn:hover {
    background: linear-gradient(135deg, #5a6268 0%, #495057 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(108, 117, 125, 0.3);
}

/* Advanced options button */
.advanced-btn {
    background: linear-gradient(135deg, #17a2b8 0%, #138496 100%);
    border: none;
    transition: all 0.3s ease;
}

.advanced-btn:hover {
    background: linear-gradient(135deg, #138496 0%, #117a8b 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(23, 162, 184, 0.3);
}

/* Advanced search options panel */
.advanced-search-options {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    padding: 1rem;
    margin-top: 1rem;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* No results message styling */
.no-results-row {
    background: #f8f9fa;
}

.no-results-row td {
    border: none;
}

.no-results-message {
    text-align: center;
    padding: 2rem;
    color: #6c757d;
}

.no-results-message svg {
    opacity: 0.5;
    margin-bottom: 1rem;
}

/* Results count styling */
.results-count {
    font-size: 0.875rem;
    color: #6c757d;
    font-weight: 500;
}

/* Search suggestions */
.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #dee2e6;
    border-top: none;
    border-radius: 0 0 0.375rem 0.375rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    max-height: 200px;
    overflow-y: auto;
}

.search-suggestion-item {
    padding: 0.5rem 1rem;
    cursor: pointer;
    border-bottom: 1px solid #f1f3f4;
    transition: background-color 0.15s ease;
}

.search-suggestion-item:hover {
    background-color: #f8f9fa;
}

.search-suggestion-item:last-child {
    border-bottom: none;
}

.search-suggestion-item.active {
    background-color: #e9ecef;
}

/* Loading indicator */
.search-loading {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #0d6efd;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 0.5rem;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Responsive design */
@media (max-width: 768px) {
    .advanced-search-form {
        padding: 1rem;
    }
    
    .search-input-group {
        margin-bottom: 1rem;
    }
    
    .column-selector {
        margin-bottom: 1rem;
    }
    
    .search-btn,
    .clear-btn,
    .advanced-btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .search-highlight {
        background-color: #495057;
        color: #f8f9fa;
    }
    
    .advanced-search-form {
        background: linear-gradient(135deg, #343a40 0%, #212529 100%);
        border-color: #495057;
    }
    
    .advanced-search-options {
        background: #343a40;
        border-color: #495057;
    }
    
    .search-suggestions {
        background: #343a40;
        border-color: #495057;
    }
    
    .search-suggestion-item:hover {
        background-color: #495057;
    }
    
    .search-suggestion-item.active {
        background-color: #6c757d;
    }
}

/* Print styles */
@media print {
    .advanced-search-form,
    .search-highlight,
    .search-suggestions {
        display: none !important;
    }
} 