/* Restaurant Menu Frontend Styles */

.restaurant-menu-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.restaurant-menu-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
    height: 100%;
}

.restaurant-menu-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.restaurant-menu-card.disabled {
    opacity: 0.7;
}

/* Card Image */
.card-image-container {
    position: relative;
    height: 350px;
    overflow: hidden;
}

.card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 12px 12px 0 0;
}

.placeholder-image {
    width: 100%;
    height: 100%;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6c757d;
    font-size: 2rem;
}

/* Badges */
.badges {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
}

.badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: bold;
    margin-right: 5px;
    margin-bottom: 5px;
}

.badge-vegetarian {
    background-color: #28a745;
    color: white;
}

.badge-vegan {
    background-color: #20c997;
    color: white;
}

/* Disabled Overlay */
.disabled-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(3px);
    z-index: 3;
}

.disabled-text {
    color: white;
    font-weight: bold;
    text-align: center;
    padding: 10px;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 8px;
}

/* Card Content */
.card-content {
    padding: 20px;
}

.product-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0 0 8px 0;
    color: #333;
    line-height: 1.3;
}

.product-description {
    font-size: 0.9rem;
    color: #666;
    margin: 0 0 15px 0;
    line-height: 1.4;
}

/* Price */
.price-container {
    margin: 15px 0;
}

.price-amount {
    font-size: 1.4rem;
    font-weight: 700;
    color: #dc3545;
}

.price-description {
    font-size: 0.9rem;
    font-weight: 400;
    color: #6c757d;
    margin-left: 5px;
}

/* Additional Info */
.additional-info {
    font-size: 0.85rem;
    color: #888;
    margin: 5px 0 15px 0;
    font-style: italic;
}

/* Size Buttons */
.size-buttons {
    display: flex;
    gap: 8px;
    margin-top: 15px;
}

.size-btn {
    flex: 1;
    padding: 10px 15px;
    border: 2px solid #dee2e6;
    background: white;
    color: #495057;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.size-btn:hover {
    border-color: #dc3545;
    color: #dc3545;
}

.size-btn.active {
    background: #dc3545;
    color: white;
    border-color: #dc3545;
}

.size-btn:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.25);
}

/* **v3.0** Disabled size buttons */
.size-btn:disabled {
    background: #f8f9fa;
    color: #6c757d;
    border-color: #dee2e6;
    cursor: not-allowed;
    opacity: 0.6;
}

.size-btn:disabled:hover {
    background: #f8f9fa;
    color: #6c757d;
    border-color: #dee2e6;
    transform: none;
}

/* Responsive Design */
@media (max-width: 768px) {
    .restaurant-menu-container {
        padding: 15px;
    }
    
    .card-content {
        padding: 15px;
    }
    
    .product-title {
        font-size: 1.1rem;
    }
    
    .price-amount {
        font-size: 1.2rem;
    }
    
    .size-buttons {
        flex-direction: column;
        gap: 5px;
    }
}

@media (max-width: 576px) {
    .card-image-container {
        height: 250px;
    }
    
    .restaurant-menu-container {
        padding: 10px;
    }
}

/* Loading Animation */
.restaurant-menu-loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #dc3545;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Error States */
.alert {
    padding: 15px;
    margin-bottom: 20px;
    border: 1px solid transparent;
    border-radius: 8px;
}

.alert-info {
    color: #0c5460;
    background-color: #d1ecf1;
    border-color: #bee5eb;
}

/* Custom Scrollbar for Mobile */
@media (max-width: 768px) {
    .restaurant-menu-container::-webkit-scrollbar {
        display: none;
    }
    
    .restaurant-menu-container {
        -ms-overflow-style: none;
        scrollbar-width: none;
    }
}

/* **v3.0** ALLERGEN STYLING - Diskretnije boje i manji font */

/* Product Allergens - Minimalno i diskretno */
.product-allergens {
    margin: 2px 0 6px 0;
    padding: 2px 4px;
    background: transparent;
    border: none;
    border-radius: 0;
    font-size: 8px;
    display: flex;
    align-items: center;
    gap: 2px;
    flex-wrap: wrap;
    position: relative;
}

.allergens-label {
    font-weight: 300;
    color: #dee2e6;
    font-size: 7px;
}

.allergen-codes-wrapper {
    display: flex;
    align-items: center;
    gap: 1px;
}

.allergen-code {
    background: #dee2e6;
    color: white;
    padding: 0px 1px;
    border-radius: 1px;
    font-weight: 400;
    font-size: 6px;
    white-space: nowrap;
}

.allergen-info-btn {
    color: #dee2e6;
    cursor: pointer;
    font-size: 7px;
    margin-left: 1px;
    padding: 1px 1px;
    border-radius: 50%;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.allergen-info-btn:hover {
    color: #fff;
    background: #dee2e6;
    transform: scale(1.1);
    box-shadow: 0 1px 3px rgba(222, 226, 230, 0.4);
}





/* Allergen Tooltip */
.allergen-tooltip {
    position: fixed;
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    padding: 0;
    z-index: 99999;
    width: 300px;
    max-width: 90vw;
    display: none; /* Hidden by default */
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.allergen-tooltip-header {
    background: #6c757d;
    color: white;
    padding: 8px 12px;
    border-radius: 6px 6px 0 0;
    font-size: 11px;
    font-weight: 600;
    text-align: center;
}

.allergen-tooltip-content {
    padding: 8px;
    max-height: 200px;
    overflow-y: auto;
}

.allergen-tooltip-item {
    padding: 4px 0;
    border-bottom: 1px solid #f1f3f4;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
}

.allergen-tooltip-item:last-child {
    border-bottom: none;
}

.allergen-code-small {
    background: #6c757d;
    color: white;
    padding: 2px 4px;
    border-radius: 2px;
    font-weight: 600;
    font-size: 9px;
    min-width: 20px;
    text-align: center;
}

.allergen-name-small {
    font-weight: 500;
    color: #333;
    font-size: 11px;
    flex: 1;
}

.allergen-name-sr-small {
    color: #6c757d;
    font-size: 10px;
    font-style: italic;
}

/* Tooltip arrow - pointing down (tooltip is above button) */
.allergen-tooltip::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 8px solid #dee2e6;
}

.allergen-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 7px solid transparent;
    border-right: 7px solid transparent;
    border-top: 7px solid #6c757d;
    margin-top: -1px;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .allergen-tooltip {
        width: 280px;
        max-width: 95vw;
        font-size: 10px;
    }
    
    .allergen-tooltip-item {
        font-size: 10px;
        padding: 3px 0;
    }
    
    .allergen-name-small {
        font-size: 10px;
    }
    
    .allergen-name-sr-small {
        font-size: 9px;
    }
}

/* **v3.0** Enhanced Image sizing - force 500x350px with better quality */
.card-image-container {
    height: 350px; /* Force 350px height */
    width: 100%;
    position: relative;
    overflow: hidden;
}

.card-image {
    width: 100%;
    height: 350px; /* Force 350px height */
    object-fit: cover;
    border-radius: 12px 12px 0 0;
    object-position: center;
}

.placeholder-image {
    width: 100%;
    height: 350px; /* Force 350px height */
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px 12px 0 0;
    font-size: 48px;
    color: #dee2e6;
}

/* Mobile Responsive for Allergens */
@media (max-width: 768px) {
    .allergen-modal-content {
        margin: 10px;
        width: calc(100% - 20px);
        max-height: 90vh;
    }
    
    .allergen-list-grid {
        grid-template-columns: 1fr;
    }
    
    .product-allergens {
        padding: 6px 10px;
        font-size: 13px;
    }
    
    .allergen-code {
        font-size: 11px;
        padding: 1px 4px;
    }
    
    .allergens-label {
        font-size: 12px;
    }
    
    .allergen-modal-header {
        padding: 15px 20px;
    }
    
    .allergen-modal-body {
        padding: 20px;
    }
    
    .card-image-container {
        height: 250px; /* Smaller on mobile */
    }
    
    .card-image, .placeholder-image {
        height: 250px; /* Smaller on mobile */
    }
} 