/**
 * Menu Allergen and Filter Styles
 *
 * @package Napule_Restaurant
 * @since 1.0.0
 */

/* Search and Filter Bar */
.menu-filters {
    background-color: var(--color-white);
    padding: var(--spacing-xl);
    border-radius: var(--radius-lg);
    margin-bottom: var(--spacing-2xl);
    box-shadow: var(--shadow-sm);
}

/* Search Box */
.menu-search {
    margin-bottom: var(--spacing-lg);
}

.menu-search-input {
    width: 100%;
    padding: var(--spacing-md) var(--spacing-lg);
    font-size: var(--font-size-base);
    border: 2px solid var(--color-accent);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
}

.menu-search-input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(41, 59, 97, 0.1);
}

.menu-search-input::placeholder {
    color: var(--color-text-light);
}

/* Dietary Filters */
.dietary-filters {
    display: flex;
    gap: var(--spacing-sm);
    flex-wrap: wrap;
}

.filter-button {
    padding: var(--spacing-sm) var(--spacing-lg);
    border: 2px solid var(--color-accent);
    background-color: var(--color-white);
    color: var(--color-primary);
    font-size: var(--font-size-sm);
    font-weight: 600;
    border-radius: var(--radius-full);
    cursor: pointer;
    transition: all var(--transition-base);
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-xs);
}

.filter-button:hover {
    border-color: var(--color-primary);
    background-color: var(--color-bg-light);
}

.filter-button.active {
    background-color: var(--color-primary);
    color: var(--color-white);
    border-color: var(--color-primary);
}

.filter-button svg {
    width: 16px;
    height: 16px;
}

/* Allergen Icons */
.allergen-icons {
    display: flex;
    gap: var(--spacing-xs);
    margin-top: var(--spacing-xs);
    flex-wrap: wrap;
}

.allergen-icon {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background-color: var(--color-bg-light);
    border-radius: 50%;
    font-size: 11px;
    font-weight: 700;
    color: var(--color-primary);
    cursor: help;
    transition: all var(--transition-base);
}

.allergen-icon:hover {
    background-color: var(--color-primary);
    color: var(--color-white);
    transform: scale(1.1);
}

/* Tooltip */
.allergen-tooltip {
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    background-color: var(--color-primary);
    color: var(--color-white);
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--radius-sm);
    font-size: var(--font-size-xs);
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-base);
    z-index: 100;
}

.allergen-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: var(--color-primary);
}

.allergen-icon:hover .allergen-tooltip {
    opacity: 1;
}

/* Dietary Badges */
.dietary-badges {
    display: flex;
    gap: var(--spacing-xs);
    margin-top: var(--spacing-xs);
    flex-wrap: wrap;
}

.dietary-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px var(--spacing-sm);
    border-radius: var(--radius-sm);
    font-size: var(--font-size-xs);
    font-weight: 600;
}

.dietary-badge svg {
    width: 12px;
    height: 12px;
}

.dietary-badge.vegetarian {
    background-color: rgba(76, 175, 80, 0.15);
    color: #2E7D32;
    border: 1px solid #4CAF50;
}

.dietary-badge.vegan {
    background-color: rgba(139, 195, 74, 0.15);
    color: #558B2F;
    border: 1px solid #8BC34A;
}

.dietary-badge.gluten-free {
    background-color: rgba(255, 152, 0, 0.15);
    color: #E65100;
    border: 1px solid #FF9800;
}

.dietary-badge.lactose-free {
    background-color: rgba(33, 150, 243, 0.15);
    color: #1565C0;
    border: 1px solid #2196F3;
}

/* No Results Message */
.no-results {
    text-align: center;
    padding: var(--spacing-3xl);
    color: var(--color-text-light);
}

.no-results svg {
    width: 64px;
    height: 64px;
    margin-bottom: var(--spacing-lg);
    opacity: 0.3;
}

/* Hidden Items (filtered out) */
.menu-item.hidden {
    display: none;
}

.menu-category.hidden {
    display: none;
}

/* Responsive */
@media (max-width: 768px) {
    .menu-filters {
        padding: var(--spacing-md);
    }
    
    .dietary-filters {
        gap: var(--spacing-xs);
    }
    
    .filter-button {
        padding: var(--spacing-xs) var(--spacing-md);
        font-size: var(--font-size-xs);
    }
}
