/**
 * Search Auto-Suggest Styles
 */

/* Search Bar Container */
.search-bar {
    position: relative;
    flex: 1;
    max-width: 600px;
}

/* Search Suggestions Dropdown */
.search-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #e0e0e0;
    border-top: none;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-height: 500px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
    margin-top: -1px;
}

/* Suggestions Header */
.search-suggestions-header {
    padding: 12px 16px;
    background: #f8f9fa;
    border-bottom: 1px solid #e0e0e0;
    font-weight: 600;
    font-size: 13px;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Individual Suggestion Item */
.search-suggestion-item {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #f0f0f0;
    text-decoration: none;
    color: #333;
    transition: background-color 0.2s ease;
}

.search-suggestion-item:hover {
    background-color: #f8f9fa;
}

.search-suggestion-item:last-of-type {
    border-bottom: none;
}

/* Suggestion Image */
.suggestion-image {
    width: 60px;
    height: 60px;
    flex-shrink: 0;
    margin-right: 12px;
    border-radius: 6px;
    overflow: hidden;
    background: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.suggestion-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Suggestion Details */
.suggestion-details {
    flex: 1;
    min-width: 0;
}

.suggestion-name {
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.suggestion-name strong {
    color: #34a853;
    font-weight: 600;
}

.suggestion-meta {
    display: flex;
    gap: 8px;
    margin-bottom: 4px;
    font-size: 12px;
}

.suggestion-category,
.suggestion-brand {
    padding: 2px 8px;
    background: #e8f5e9;
    color: #2e7d32;
    border-radius: 4px;
    font-size: 11px;
}

.suggestion-brand {
    background: #e3f2fd;
    color: #1565c0;
}

.suggestion-price {
    font-size: 14px;
    font-weight: 600;
    color: #34a853;
}

/* Suggestions Footer */
.search-suggestions-footer {
    padding: 12px 16px;
    background: #f8f9fa;
    border-top: 1px solid #e0e0e0;
    text-align: center;
}

.view-all-results {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #34a853;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: color 0.2s ease;
}

.view-all-results:hover {
    color: #2e7d32;
}

.view-all-results i {
    font-size: 12px;
}

/* No Results */
.search-no-results {
    padding: 40px 20px;
    text-align: center;
    color: #666;
}

.search-no-results i {
    font-size: 48px;
    color: #ccc;
    margin-bottom: 16px;
}

.search-no-results p {
    font-size: 16px;
    margin-bottom: 8px;
    color: #333;
}

.search-no-results small {
    font-size: 13px;
    color: #666;
}

.search-no-results a {
    color: #34a853;
    text-decoration: none;
    font-weight: 500;
}

.search-no-results a:hover {
    text-decoration: underline;
}

/* Scrollbar Styling */
.search-suggestions::-webkit-scrollbar {
    width: 8px;
}

.search-suggestions::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.search-suggestions::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 4px;
}

.search-suggestions::-webkit-scrollbar-thumb:hover {
    background: #999;
}

/* Search Results Page Styles */
.search-results-header {
    text-align: center;
    padding: 40px 0;
    border-bottom: 1px solid #e0e0e0;
    margin-bottom: 40px;
}

.search-results-header h1 {
    font-size: 32px;
    color: #333;
    margin-bottom: 12px;
}

.results-count {
    font-size: 16px;
    color: #666;
}

/* No Results Styles */
.no-results {
    text-align: center;
    padding: 80px 20px;
}

.no-results h2 {
    font-size: 24px;
    color: #333;
    margin-bottom: 16px;
}

.no-results p {
    font-size: 16px;
    color: #666;
    margin-bottom: 32px;
}

.no-results .suggestions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.no-results .btn {
    padding: 12px 24px;
    background: #34a853;
    color: white;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 500;
    transition: background 0.3s ease;
}

.no-results .btn:hover {
    background: #2e7d32;
}

.no-results .btn-secondary {
    background: #666;
}

.no-results .btn-secondary:hover {
    background: #555;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .search-suggestions {
        max-height: 400px;
    }

    .suggestion-image {
        width: 50px;
        height: 50px;
    }

    .suggestion-name {
        font-size: 13px;
    }

    .suggestion-price {
        font-size: 13px;
    }

    .search-results-header h1 {
        font-size: 24px;
    }

    .no-results {
        padding: 60px 20px;
    }

    .no-results h2 {
        font-size: 20px;
    }
}

