/* Category Sections */
.category-section {
    margin-top: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
    scroll-margin-top: 140px; /* sticky nav (52px) + chip nav (~80px) */
}

.category-section:first-of-type {
    margin-top: var(--spacing-sm);
}

.category-section h2 {
    color: var(--category-color);
    font-size: 1.4rem;
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-xs);
    border-bottom: 2px solid var(--brand-color);
}

/* Napi menü kiemelt szekció */
.daily-menu-highlight {
    background: var(--primary-soft);
    border: 1px solid var(--primary-color);
    border-radius: var(--radius-md, 8px);
    padding: 12px;
    margin-bottom: var(--spacing-lg);
}

.daily-menu-highlight h2 {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.daily-menu-highlight h2 i {
    margin-right: 6px;
    font-size: 1.1rem;
}

/* Menü elemek és ital elemek alapszerkezete */
article.menu-item,
article.drink-item {
    background: var(--card-background);
    border-radius: var(--radius-md);
    padding: 8px 10px 10px 8px;
    margin-bottom: 8px;
    box-shadow: var(--shadow-sm);
    position: relative;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Menü fejléc - kép és cím egymás mellett */
.menu-item-header {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 6px;
    width: 100%;
    cursor: pointer;
}

/* Menü képek - kis padding a széltől */
.menu-item-image {
    width: 65px;
    height: 65px;
    border-radius: 6px;
    overflow: hidden;
    flex-shrink: 0;
    position: relative;
}

/* Skeleton shimmer kepe betoltes kozben */
@keyframes shimmer {
    0% { background-position: -200px 0; }
    100% { background-position: 200px 0; }
}
.menu-item-image.loading {
    background: linear-gradient(90deg, var(--border-color) 25%, transparent 50%, var(--border-color) 75%);
    background-size: 200px 100%;
    animation: shimmer 1.5s infinite;
}
.menu-item-image.loading img {
    opacity: 0;
}

.food-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.food-thumbnail:hover {
    transform: scale(1.05);
}

/* Menü cím rész */
.menu-item-title {
    flex: 1;
    min-width: 0;
}

.item-name {
    font-size: 1.05rem;
    color: var(--header-color);
    margin: 0;
    padding: 0;
    line-height: 1.25;
    /* Étel név max 2 sor */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.item-number {
    font-size: 0.8em;
    color: var(--text-color);
    opacity: 0.6;
    margin-right: 0.4rem;
    font-weight: normal;
}

/* Badge-ek a kép jobb felső sarkában */
.item-badges {
    position: absolute;
    top: 3px;
    right: 3px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    z-index: 1;
}

.item-badge {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 0.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
    pointer-events: auto;
}

.badge-seasonal { background: #e67e22; }
.badge-new      { background: #2ecc71; }
.badge-chef     { background: #9b59b6; }
.badge-popular  { background: #e74c3c; }

/* Régi seasonal-badge fallback (ha nincs kép) */
.seasonal-badge {
    display: inline-block;
    background-color: #E53935;
    color: white;
    font-size: 0.6rem;
    font-weight: bold;
    padding: 3px 8px;
    border-radius: 3px;
    margin-top: 4px;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Menü tartalom - leírás és allergének */
.menu-item-content {
    margin-bottom: 6px;
    width: 100%;
}

.item-description {
    font-size: 0.85rem;
    margin-bottom: 4px;
    color: var(--text-color);
    line-height: 1.35;
    /* Leírás max 2 sor */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.item-allergens {
    font-size: 0.75rem;
    color: var(--allergen-color);
    font-style: italic;
    margin-bottom: 0;
    /* Allergének max 1 sor */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Árak konténer */
.price-container {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 4px;
    width: 100%;
}

.size-price {
    display: flex;
    align-items: center;
    gap: 6px;
    background-color: var(--bg-secondary);
    padding: 6px 10px;
    border-radius: 6px;
}

.size {
    font-size: 0.8rem;
    color: var(--allergen-color);
    white-space: nowrap;
}

.price {
    font-size: 1rem;
    font-weight: 600;
    color: var(--price-color);
    white-space: nowrap;
}

/* Kosárba gomb — harmonizalo kerek gomb */
.add-to-cart {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--primary-color);
    border: none;
    color: #fff;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s, background 0.15s;
    flex-shrink: 0;
    margin-left: auto;
}

.add-to-cart:hover {
    transform: scale(1.1);
    background: var(--primary-hover);
}

.add-to-cart i {
    font-size: 0.75rem;
}

/* Desktop optimalizáció */
@media (min-width: 769px) {
    article.menu-item,
    article.drink-item {
        padding: 10px 12px 12px 10px;
    }
    
    .menu-item-image {
        width: 75px;
        height: 75px;
    }
    
    .item-name {
        font-size: 1.15rem;
    }
    
    .item-description {
        -webkit-line-clamp: 3;
    }
    
    .price-container {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 6px;
    }
    
    .size-price {
        flex: 0 0 auto;
        min-width: 140px;
    }
}

/* Mobil optimalizáció */
@media (max-width: 768px) {
    .category-section h2 {
        font-size: 1.2rem;
        margin-bottom: var(--spacing-sm);
    }
    
    article.menu-item,
    article.drink-item {
        padding: 8px;
        margin-bottom: 6px;
    }
    
    .menu-item-header {
        gap: 8px;
        margin-bottom: 4px;
    }
    
    .menu-item-image {
        width: 55px;
        height: 55px;
        border-radius: 5px;
    }
    
    .item-name {
        font-size: 0.95rem;
    }
    
    .menu-item-content {
        margin-bottom: 4px;
    }
    
    .item-description {
        font-size: 0.8rem;
    }
    
    .item-allergens {
        font-size: 0.7rem;
    }
    
    .size-price {
        padding: 5px 8px;
    }
    
    .size {
        font-size: 0.75rem;
    }
    
    .price {
        font-size: 0.9rem;
    }
    
    .item-badge {
        width: 18px;
        height: 18px;
        font-size: 0.45rem;
    }
}

/* Meg kisebb mobilok */
@media (max-width: 380px) {
    .menu-item-image {
        width: 50px;
        height: 50px;
    }

    .item-badge {
        width: 16px;
        height: 16px;
        font-size: 0.4rem;
    }

    .item-badges {
        top: 2px;
        right: 2px;
        gap: 1px;
    }

    .item-name {
        font-size: 0.9rem;
    }

    .item-description {
        font-size: 0.75rem;
        -webkit-line-clamp: 1;
    }

    .size-price {
        padding: 4px 6px;
    }

    .price {
        font-size: 0.85rem;
    }
}

/* Extra apro kijelzok (320px) */
@media (max-width: 340px) {
    article.menu-item,
    article.drink-item {
        padding: 6px;
        margin-bottom: 4px;
    }

    .menu-item-header {
        gap: 6px;
    }

    .menu-item-image {
        width: 44px;
        height: 44px;
        border-radius: 4px;
    }

    .item-name {
        font-size: 0.82rem;
    }

    .item-description {
        font-size: 0.7rem;
    }

    .item-allergens {
        font-size: 0.6rem;
    }

    .item-badge {
        width: 14px;
        height: 14px;
        font-size: 0.35rem;
    }
}
