/* ===== SERVICE SEARCH RESULTS ===== */
.service-search-results {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    min-width: 100%;
    background: #fff;
    border: 1px solid var(--light-gray);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    z-index: 9999;
    max-height: 350px;
    overflow-y: auto;
    overflow-x: hidden;
    display: none;
}

.service-search-results .search-result-item {
    padding: 10px 12px;
    cursor: pointer;
    border-bottom: 1px solid var(--light-gray);
    transition: background-color 0.2s ease;
    display: flex;
    align-items: center;
    gap: 12px;
}

.service-search-results .search-result-item:hover,
.service-search-results .search-result-item.selected {
    background-color: var(--light-gray);
}

.service-search-results .search-result-item:last-child {
    border-bottom: none;
}

.service-search-results .result-icon {
    flex-shrink: 0;
    color: var(--primary-orange);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: rgba(233, 91, 13, 0.1);
    border-radius: var(--radius-sm);
}

.service-search-results .result-content {
    flex: 1;
    min-width: 0;
}

.service-search-results .result-title {
    color: var(--primary-black);
    font-size: var(--font-size-sm);
    font-weight: 500;
    text-align: left;
    /* Remove text truncation to prevent cutoff */
    word-wrap: break-word;            /* legacy alias */
    overflow-wrap: anywhere;          /* break very long words (e.g., long brand names) */
    word-break: break-word;           /* additional safety */
    white-space: normal;              /* allow wrapping */
}

.service-search-results .result-title strong {
    color: var(--primary-orange);
    font-weight: 600;
}

.service-search-results .result-subtitle {
    color: var(--primary-gray);
    font-size: var(--font-size-xs);
    margin-top: 2px;
    text-align: left;
}

.service-search-results .search-loading,
.service-search-results .search-error,
.service-search-results .search-no-results {
    padding: 16px;
    text-align: center;
    font-size: var(--font-size-sm);
    color: var(--primary-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.service-search-results .search-loading {
    color: var(--primary-orange);
}

.service-search-results .search-error {
    color: #dc3545;
}

/* Category badge in results */
.search-result-item[data-type="category"] .result-icon {
    background: rgba(233, 91, 13, 0.15);
}

.search-result-item[data-type="category"] .result-title {
    font-weight: 600;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .service-search-results {
        max-height: 250px;
    }
    
    .service-search-results .search-result-item {
        padding: 8px 10px;
    }
}
