﻿
.search-form {
    max-width: 500px;
    width: 100%;
}

.search-input-group {
    width: 100%;
}

#search-suggestions {
    min-width: 100%;
    width: 100%;
}
/* Search Input Group */

.search-input-group {
    border-radius: 50rem;
    overflow: hidden;
    display: flex;
    align-items: stretch;
    width: 100%;
}

.search-input-group-text {
    border-right: 0;
    background-color: white;
    padding-left: 1rem;
    padding-right: 1rem;
    border-radius: 0 !important;
    display: flex;
    align-items: center;
}

/* Search Inputs */
#searchBox,
#searchBoxMobile {
    font-size: 0.95rem;
    border-left: 0;
    border-radius: 0 !important;
    box-shadow: none !important;
    outline: none;
    padding-left: 0.75rem;
    padding-right: 0.75rem;
    flex: 1 1 auto;
    min-width: 0;
    height: 100%;
}

    /* Placeholders */
    #searchBox::placeholder,
    #searchBoxMobile::placeholder {
        color: #6c757d;
        font-style: italic;
        font-size: 0.9rem;
    }

/* Suggestions container */
#search-suggestions,
#search-suggestions-mobile {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1000;
    display: none;
    background: #fff;
    border: 1px solid #ccc;
    border-radius: 0 0 0.5rem 0.5rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
    max-height: 280px;
    overflow-y: auto;
    overflow-x: hidden;
    min-width: 100%;
}

    /* UL Reset */
    #search-suggestions ul,
    #search-suggestions-mobile ul {
        list-style: none;
        margin: 0;
        padding: 0;
    }

/* List Items */
.search-list-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.9rem;
    border-bottom: 1px solid #e2e3e5;
    font-size: 0.95rem;
    cursor: pointer;
    background-color: white;
    transition: background-color 0.2s ease-in-out;
}

    .search-list-item:last-child {
        border-bottom: none;
    }

    .search-list-item:hover {
        background-color: #f8f9fa;
    }

    /* Icons */
    .search-list-item i {
        flex-shrink: 0;
        font-size: 1rem;
        color: #0d6efd;
    }

    /* Link Wrapper */
    .search-list-item a {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        text-decoration: none;
        color: inherit;
        flex-grow: 1;
        min-width: 0;
        width: 100%;
    }

        /* Link Text Span */
        .search-list-item a span {
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
            display: inline-block;
            flex-grow: 1;
            min-width: 0;
            max-width: 100%;
        }

/* View All Link */
.search-view-all {
    text-align: center;
    padding: 0.6rem;
    background: #f1f3f5;
    font-weight: 500;
    font-size: 0.85rem;
    color: #0d6efd;
}

    .search-view-all a {
        color: inherit;
        text-decoration: none;
    }

/* Mobile max-width tweaks */
@media (max-width: 576px) {
    .search-list-item a span {
        max-width: 100%;
    }
}
