/* ==========================================================================
   Shahbandar Universal Filterable Search Dropdown System
   نظام البحث والفلترة الموحد لشاشات الشاهبندر (الأسماء والحسابات والأصناف)
   ========================================================================== */

.search-lookup-container {
    position: relative !important;
}

.search-lookup-dropdown {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    z-index: 1085;
    background-color: #ffffff;
    border: 2px solid #3B1E44;
    border-radius: 10px;
    box-shadow: 0 12px 32px rgba(59, 30, 68, 0.22);
    max-height: 290px;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 4px 0;
    margin: 0;
    list-style: none;
    animation: shahbandarFadeIn 0.15s ease-out;
}

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

.search-lookup-dropdown .search-item-row {
    padding: 8px 14px;
    cursor: pointer;
    border-bottom: 1px solid #f3efd8;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.12s ease, color 0.12s ease;
    font-size: 0.9rem;
    color: #212529;
}

.search-lookup-dropdown .search-item-row:last-child {
    border-bottom: none;
}

.search-lookup-dropdown .search-item-row:hover,
.search-lookup-dropdown .search-item-row.active {
    background-color: #fbf8d8 !important;
    color: #3B1E44 !important;
}

.search-lookup-dropdown .search-item-code {
    display: inline-block;
    padding: 2px 7px;
    font-size: 0.78rem;
    font-weight: 700;
    font-family: monospace, monospace;
    background-color: #3B1E44;
    color: #FBF8D8;
    border-radius: 5px;
    margin-left: 8px;
    vertical-align: middle;
}

.search-lookup-dropdown .search-item-name {
    font-weight: 600;
    color: inherit;
}

.search-lookup-dropdown .search-item-meta {
    font-size: 0.8rem;
    color: #6c757d;
    text-align: left;
    white-space: nowrap;
    margin-right: 8px;
}

.search-lookup-dropdown .search-no-results,
.search-lookup-dropdown .search-loading {
    padding: 14px;
    text-align: center;
    color: #6c757d;
    font-size: 0.88rem;
}

.search-lookup-dropdown mark.search-match {
    background-color: #ffe69c;
    color: #3B1E44;
    font-weight: bold;
    padding: 0 2px;
    border-radius: 3px;
}

/* Clear Button styling inside input-group */
.search-lookup-container .btn-clear-search {
    border-color: #c8c3a7;
    background-color: #fdfdfd;
    color: #6c757d;
    transition: all 0.15s ease;
}

.search-lookup-container .btn-clear-search:hover {
    background-color: #dc3545;
    border-color: #dc3545;
    color: #ffffff;
}

/* Auto-converted searchable select wrapper */
.shahbandar-filter-wrapper {
    position: relative;
    width: 100%;
}

