<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Food Item Details - Easy Restaurant Manager</title>
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }

        /* body {
            font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
            min-height: 100vh;
            padding: 20px;
            color: #ffffff;
        } */

        .easy_restaurant_manager__container {
            max-width: 1200px;
            margin: 0 auto;
            background: rgba(255, 255, 255, 0.05);
            backdrop-filter: blur(20px);
            border-radius: 8px;
            overflow: hidden;
            position: relative;
            background: linear-gradient(135deg, #fff 0%, #1a1a1a 50%, #333333 100%);

        }

        .easy_restaurant_manager__container::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            height: 2px;
            background: linear-gradient(90deg, transparent, #ffffff, transparent);
            opacity: 0.3;
        }

        .easy_restaurant_manager__header {
            background: linear-gradient(45deg, #fff, #333333);
            color: white;
            padding: 40px;
            text-align: center;
            position: relative;
            overflow: hidden;
        }

        .easy_restaurant_manager__header::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
            background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
            animation: shimmer 3s infinite;
        }

        @keyframes shimmer {
            0% { left: -100%; }
            100% { left: 100%; }
        }

        .easy_restaurant_manager__title {
            font-size: 3rem;
            font-weight: 900;
            margin-bottom: 15px;
            text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
            letter-spacing: 2px;
            text-transform: uppercase;
            color: #fff;
        }

        .easy_restaurant_manager__subtitle {
            font-size: 1.2rem;
            opacity: 0.8;
            font-weight: 300;
            letter-spacing: 1px;
        }

        .easy_restaurant_manager__content {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 50px;
            padding: 50px;
        }

        .easy_restaurant_manager__image_section {
            position: relative;
        }

        .easy_restaurant_manager__image {
            width: 100%;
            height: 450px;
            object-fit: cover;
            border-radius: 8px;
            border: 2px solid rgba(255, 255, 255, 0.1);
        }

        .easy_restaurant_manager__availability_badge {
            position: absolute;
            top: 20px;
            right: 20px;
            padding: 12px 20px;
            border-radius: 30px;
            font-weight: 700;
            font-size: 0.9rem;
            text-transform: uppercase;
            letter-spacing: 2px;
            backdrop-filter: blur(10px);
            border: 1px solid rgba(255, 255, 255, 0.2);
        }

        .easy_restaurant_manager__available {
            background: rgba(255, 255, 255, 0.9);
            color: #000000;
            box-shadow: 0 8px 25px rgba(255, 255, 255, 0.3);
        }

        .easy_restaurant_manager__unavailable {
            background: rgba(0, 0, 0, 0.9);
            color: #ffffff;
            box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
        }

        .easy_restaurant_manager__details {
            display: flex;
            flex-direction: column;
            gap: 30px;
            color: #fff;
        }

        .easy_restaurant_manager__item_name {
            font-size: 2.5rem;
            font-weight: 800;
            color: #ffffff;
            margin-bottom: 15px;
            text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
            letter-spacing: 1px;
        }

        .easy_restaurant_manager__description {
            font-size: 1.1rem;
            line-height: 1.8;
            color: #fff;
            padding: 25px;
            background: rgba(255, 255, 255, 0.05);
            border-radius: 15px;
            border-left: 4px solid #ffffff;
            backdrop-filter: blur(10px);

            border: 1px solid rgba(255, 255, 255, 0.1);
        }

        .easy_restaurant_manager__price_section {
            background: linear-gradient(135deg, #ffffff, #f0f0f0);
            color: #000000;
            padding: 30px;
            border-radius: 20px;
            text-align: center;
            box-shadow: 0 15px 30px rgba(255, 255, 255, 0.1);
            border: 2px solid rgba(255, 255, 255, 0.2);
            position: relative;
            overflow: hidden;
        }

        .easy_restaurant_manager__price_section::before {
            content: '';
            position: absolute;
            top: -50%;
            left: -50%;
            width: 200%;
            height: 200%;
            background: conic-gradient(from 0deg, transparent, rgba(0, 0, 0, 0.1), transparent);
            animation: rotate 4s linear infinite;
        }

        @keyframes rotate {
            0% { transform: rotate(0deg); }
            100% { transform: rotate(360deg); }
        }

        .easy_restaurant_manager__base_price {
            font-size: 2.8rem;
            font-weight: 900;
            margin-bottom: 8px;
            position: relative;
            z-index: 1;
        }

        .easy_restaurant_manager__price_label {
            font-size: 1rem;
            opacity: 0.7;
            font-weight: 600;
            position: relative;
            z-index: 1;
        }

        .easy_restaurant_manager__section {
            background: rgba(255, 255, 255, 0.03);
            border-radius: 20px;
            padding: 30px;
            box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
            border: 1px solid rgba(255, 255, 255, 0.1);
            backdrop-filter: blur(15px);
        }

        .easy_restaurant_manager__section_title {
            font-size: 1.6rem;
            font-weight: 700;
            color: #ffffff;
            margin-bottom: 20px;
            display: flex;
            align-items: center;
            gap: 15px;
            text-transform: uppercase;
            letter-spacing: 1px;
        }

        .easy_restaurant_manager__section_title::before {
            content: '';
            width: 6px;
            height: 30px;
            background: linear-gradient(45deg, #ffffff, #cccccc);
            border-radius: 3px;
            box-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
        }

        .easy_restaurant_manager__portion_grid,
        .easy_restaurant_manager__addon_grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
            gap: 20px;
        }

        .easy_restaurant_manager__portion_item,
        .easy_restaurant_manager__addon_item {
            background: rgba(255, 255, 255, 0.08);
            padding: 20px;
            border-radius: 15px;
            border: 1px solid rgba(255, 255, 255, 0.15);
            backdrop-filter: blur(10px);
            position: relative;
            overflow: hidden;
        }

        .easy_restaurant_manager__portion_item::before,
        .easy_restaurant_manager__addon_item::before {
            content: '';
            position: absolute;
            top: 0;
            left: -100%;
            width: 100%;
            height: 100%;
        }

        .easy_restaurant_manager__portion_item:hover::before,
        .easy_restaurant_manager__addon_item:hover::before {
            left: 100%;
        }

        .easy_restaurant_manager__portion_name,
        .easy_restaurant_manager__addon_name {
            font-weight: 600;
            color: #ffffff;
            margin-bottom: 8px;
            font-size: 1.1rem;
        }

        .easy_restaurant_manager__portion_price {
            font-size: 1.4rem;
            font-weight: 800;
            color: #ffffff;
            text-shadow: 0 0 10px rgba(255, 255, 255, 0.3);
        }

        .easy_restaurant_manager__addon_price {
            font-size: 1.2rem;
            font-weight: 700;
            color: #cccccc;
        }

        .easy_restaurant_manager__meta_info {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
            gap: 25px;
            margin-top: 40px;
        }

        .easy_restaurant_manager__meta_item {
            text-align: center;
            padding: 25px;
            background: linear-gradient(135deg, #1a1a1a, #000000);
            color: white;
            border-radius: 20px;
            font-weight: 600;
            border: 2px solid rgba(255, 255, 255, 0.1);
            transition: all 0.3s ease;
            position: relative;
            overflow: hidden;
        }

        .easy_restaurant_manager__meta_item::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            height: 2px;
            background: linear-gradient(90deg, transparent, #ffffff, transparent);
            opacity: 0;
            transition: opacity 0.3s ease;
        }

        .easy_restaurant_manager__meta_item:hover::before {
            opacity: 1;
        }

        .easy_restaurant_manager__meta_label {
            font-size: 0.9rem;
            opacity: 0.7;
            margin-bottom: 8px;
            text-transform: uppercase;
            letter-spacing: 1px;
        }

        .easy_restaurant_manager__meta_value {
            font-size: 1.2rem;
            font-weight: 800;
        }

        @media (max-width: 768px) {
            .easy_restaurant_manager__content {
                grid-template-columns: 1fr;
                gap: 30px;
                padding: 30px;
            }

            .easy_restaurant_manager__title {
                font-size: 2.2rem;
                color: #fff;
            }

            .easy_restaurant_manager__item_name {
                font-size: 2rem;
            }

            .easy_restaurant_manager__portion_grid,
            .easy_restaurant_manager__addon_grid {
                grid-template-columns: 1fr;
            }

            .easy_restaurant_manager__image {
                height: 300px;
            }

            .easy_restaurant_manager__header {
                padding: 30px 20px;
            }
        }

        /* Custom scrollbar for webkit browsers */
        ::-webkit-scrollbar {
            width: 8px;
        }

        ::-webkit-scrollbar-track {
            background: rgba(255, 255, 255, 0.1);
        }

        ::-webkit-scrollbar-thumb {
            background: rgba(255, 255, 255, 0.3);
            border-radius: 4px;
        }

        ::-webkit-scrollbar-thumb:hover {
            background: rgba(255, 255, 255, 0.5);
        }
    </style>
</head>
<body>

    <div class="easy_restaurant_manager__container">
        <div class="easy_restaurant_manager__header">
            <h1 class="easy_restaurant_manager__title">Food Item Details</h1>
            <!-- <p class="easy_restaurant_manager__subtitle">Easy Restaurant Manager</p> -->
        </div>

        <div class="easy_restaurant_manager__content">
            <div class="easy_restaurant_manager__image_section">
                <img src="<?php echo esc_url($menu->image); ?>" 
                     alt="Delicious Pizza" 
                     class="easy_restaurant_manager__image">
                <div class="easy_restaurant_manager__availability_badge easy_restaurant_manager__available">
                    <?php echo esc_html($menu->availability); ?>
                </div>
            </div>

            <div class="easy_restaurant_manager__details">
                <div>
                    <h2 class="easy_restaurant_manager__item_name"><?php echo esc_html($menu->name); ?></h2>
                    <div class="easy_restaurant_manager__description">
                        <?php echo wp_kses_post($menu->description); ?>
                    </div>
                </div>

                <div class="easy_restaurant_manager__price_section">
                    <div class="easy_restaurant_manager__base_price">$<?php echo esc_html($menu->base_price); ?></div>
                    <div class="easy_restaurant_manager__price_label">Base Price</div>
                </div>
            </div>
        </div>

        <div style="padding: 0 50px 50px;">
            <div class="easy_restaurant_manager__section">
                <h3 class="easy_restaurant_manager__section_title">Portion Sizes</h3>
                <div class="easy_restaurant_manager__portion_grid">
                    <?php 
                    if(!empty($menu->portion_sizes)) {
                    $portion_sizes = json_decode($menu->portion_sizes, true);
                    foreach ($portion_sizes as $portion):?>
                        <div class="easy_restaurant_manager__portion_item">
                            <div class="easy_restaurant_manager__portion_name"><?php echo esc_html($portion['name']); ?></div>
                            <div class="easy_restaurant_manager__portion_price">$<?php echo esc_html($portion['value']); ?></div>
                        </div>
                    <?php endforeach; } ?>
                </div>
            </div>

            <div class="easy_restaurant_manager__section" style="margin-top: 40px;">
                <h3 class="easy_restaurant_manager__section_title">Available Add-ons</h3>
                <div class="easy_restaurant_manager__addon_grid">
                    <?php 
                    if(!empty($menu->addons)) {
                    $addons = json_decode($menu->addons, true);
                    foreach ($addons as $addon):?>
                        <div class="easy_restaurant_manager__addon_item">
                            <div class="easy_restaurant_manager__addon_name"><?php echo esc_html($addon['name']); ?></div>
                            <div class="easy_restaurant_manager__addon_price">$<?php echo esc_html($addon['value']); ?></div>
                        </div>
                    <?php endforeach; } ?>
                </div>
            </div>
      
            <div class="easy_restaurant_manager__meta_info">
                <div class="easy_restaurant_manager__meta_item">
                    <div class="easy_restaurant_manager__meta_label">Item ID</div>
                    <div class="easy_restaurant_manager__meta_value"># <?php echo esc_html($menu->id); ?></div>
                </div>
                <div class="easy_restaurant_manager__meta_item">
                    <div class="easy_restaurant_manager__meta_label">Branch</div>
                    <div class="easy_restaurant_manager__meta_value">Main</div>
                </div>
                <div class="easy_restaurant_manager__meta_item">
                    <div class="easy_restaurant_manager__meta_label">Category</div>
                    <div class="easy_restaurant_manager__meta_value"><?php echo esc_html($menu->category->name); ?></div>
                </div>
                <div class="easy_restaurant_manager__meta_item">
                    <div class="easy_restaurant_manager__meta_label">Last Updated</div>
                    <div class="easy_restaurant_manager__meta_value"><?php echo esc_html(date("Y-m-d", strtotime($menu->updated_at))); ?></div>
                </div>
            </div>
        </div>
    </div>
</body>
</html>