/**
 * Unified Search CSS for Budli Theme
 */

/* ============================================================
   BSB — Budli Search Band (scoped with unique prefix)
   Prevents conflicts with other page-level search styles.
   ============================================================ */

.bsb-band {
    padding: 50px 16px;
    width: 100%;
    background-color: rgb(4, 116, 180);
}

.bsb-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bsb-form-wrap {
    position: relative;
    width: 100%;
    max-width: 780px;
}

.bsb-form {
    display: flex;
    width: 100%;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.bsb-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 0 18px;
    height: 48px;
    font-size: 15px;
    color: #333;
    background: #fff;
    font-family: inherit;
}

.bsb-input::placeholder {
    color: #888;
}

.bsb-btn {
    flex-shrink: 0;
    width: 56px;
    height: 48px;
    background: #BC1C5C;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    transition: background 0.2s;
}

.bsb-btn:hover,
.bsb-btn:focus {
    background: #a0184f;
}

/* Responsive */
@media (max-width: 576px) {
    .bsb-band {
        padding: 14px 12px;
    }

    .bsb-input {
        font-size: 13px;
        padding: 0 12px;
    }

    .bsb-btn {
        width: 48px;
    }
}

.budli-search {
    position: relative !important;
    /* Ensure children can be absolute positioned relative to this */
    overflow: visible !important;
    /* Ensure suggestions aren't clipped */
}

.budli-search-suggestions {
    position: absolute !important;
    top: calc(100% + 5px) !important;
    left: 0 !important;
    right: 0 !important;
    background: #fff !important;
    border: 1px solid #ddd !important;
    border-radius: 4px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
    z-index: 9999 !important;
    /* Force on top of everything */
    max-height: 300px !important;
    overflow-y: auto !important;
    display: block;
    /* Control visibility via [hidden] attribute */
}

.budli-search-suggestions[hidden] {
    display: none !important;
}

.budli-search-suggestions ul {
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.budli-search-suggestions li {
    border-bottom: 1px solid #f0f0f0 !important;
}

.budli-search-suggestions li:last-child {
    border-bottom: none !important;
}

.budli-search-suggestions li a {
    display: block !important;
    padding: 10px 15px !important;
    color: #333 !important;
    text-decoration: none !important;
    font-size: 14px !important;
    transition: background 0.2s !important;
}

.budli-search-suggestions li:hover a,
.budli-search-suggestions li.selected a {
    background: #f5f5f5 !important;
    color: #BC1C5C !important;
    /* Budli Red highlight */
}

.budli-search-suggestions mark {
    background: transparent !important;
    color: #0474B4 !important;
    /* Budli Blue for matches */
    font-weight: 700 !important;
}

/* Fix for mobile screens */
@media (max-width: 768px) {
    .budli-search-suggestions {
        max-height: 250px !important;
    }
}