/**
* ADVANCED SEARCH STYLES
* High-level search UI styles
*/

.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    display: none;
    align-items: flex-start;
    justify-content: center;
    padding-top: 10vh;
    backdrop-filter: blur(5px);
}

.search-overlay.active {
    display: flex;
}

.search-container {
    width: 90%;
    max-width: 600px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.search-header {
    display: flex;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid #e0e0e0;
}

.search-input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 1.1rem;
    padding: 0.5rem;
}

.search-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    color: #666;
    transition: color 0.2s;
}

.search-close:hover {
    color: #000;
}

.search-results {
    max-height: 60vh;
    overflow-y: auto;
    padding: 0.5rem;
}

.search-result-item {
    padding: 1rem;
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.2s;
    margin-bottom: 0.5rem;
}

.search-result-item:hover {
    background: #f5f5f5;
}

.search-result-type {
    font-size: 0.75rem;
    color: #666;
    text-transform: uppercase;
    margin-bottom: 0.25rem;
}

.search-result-title {
    font-weight: 600;
    margin-bottom: 0.25rem;
    color: #0d6efd;
}

.search-result-description {
    font-size: 0.9rem;
    color: #666;
}

.search-result-description mark {
    background: #ffeb3b;
    padding: 0 2px;
}

.search-no-results {
    padding: 2rem;
    text-align: center;
    color: #666;
}

.search-suggestions {
    padding: 0.5rem;
}

.search-suggestion {
    padding: 0.75rem;
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.search-suggestion:hover {
    background: #f5f5f5;
}

.search-suggestion i {
    color: #0d6efd;
}

.search-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.5rem;
    color: inherit;
    transition: color 0.2s;
}

.search-btn:hover {
    color: #0d6efd;
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    .search-container {
        background: #1a1a1a;
        color: #fff;
    }

    .search-header {
        border-bottom-color: #333;
    }

    .search-input {
        background: #1a1a1a;
        color: #fff;
    }

    .search-result-item:hover {
        background: #2a2a2a;
    }

    .search-suggestion:hover {
        background: #2a2a2a;
    }
}

