<?php $attributes ??= new \Illuminate\View\ComponentAttributeBag;

$__newAttributes = [];
$__propNames = \Illuminate\View\ComponentAttributeBag::extractPropNames((['products', 'title' => null, 'badge' => null, 'locale' => 'en']));

foreach ($attributes->all() as $__key => $__value) {
    if (in_array($__key, $__propNames)) {
        $$__key = $$__key ?? $__value;
    } else {
        $__newAttributes[$__key] = $__value;
    }
}

$attributes = new \Illuminate\View\ComponentAttributeBag($__newAttributes);

unset($__propNames);
unset($__newAttributes);

foreach (array_filter((['products', 'title' => null, 'badge' => null, 'locale' => 'en']), 'is_string', ARRAY_FILTER_USE_KEY) as $__key => $__value) {
    $$__key = $$__key ?? $__value;
}

$__defined_vars = get_defined_vars();

foreach ($attributes->all() as $__key => $__value) {
    if (array_key_exists($__key, $__defined_vars)) unset($$__key);
}

unset($__defined_vars, $__key, $__value); ?>

<?php
    $isArabic = $locale === 'ar';
?>

<div class="ai-product-grid-wrapper">
    <?php if($title): ?>
        <div class="ai-grid-header flex items-center justify-between mb-3">
            <h3 class="text-sm font-semibold text-gray-900 dark:text-white" dir="<?php echo e($isArabic ? 'rtl' : 'ltr'); ?>">
                <?php echo e($title); ?>

                <span class="text-gray-500 dark:text-gray-400 font-normal">(<?php echo e($products->count()); ?>)</span>
            </h3>
            <?php if($badge): ?>
                <span class="px-2 py-1 text-xs font-medium rounded-full bg-gradient-to-r from-purple-500 to-pink-500 text-white">
                    <?php echo e($badge); ?>

                </span>
            <?php endif; ?>
        </div>
    <?php endif; ?>

    <div class="grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-3">
        <?php $__empty_1 = true; $__currentLoopData = $products; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $product): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); $__empty_1 = false; ?>
            <?php if (isset($component)) { $__componentOriginal392da982830b91ad10d7d6de273bd7a9 = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginal392da982830b91ad10d7d6de273bd7a9 = $attributes; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.ai.product-card','data' => ['product' => $product,'badge' => $badge,'locale' => $locale]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('ai.product-card'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?>
<?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?>
<?php endif; ?>
<?php $component->withAttributes(['product' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($product),'badge' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($badge),'locale' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($locale)]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginal392da982830b91ad10d7d6de273bd7a9)): ?>
<?php $attributes = $__attributesOriginal392da982830b91ad10d7d6de273bd7a9; ?>
<?php unset($__attributesOriginal392da982830b91ad10d7d6de273bd7a9); ?>
<?php endif; ?>
<?php if (isset($__componentOriginal392da982830b91ad10d7d6de273bd7a9)): ?>
<?php $component = $__componentOriginal392da982830b91ad10d7d6de273bd7a9; ?>
<?php unset($__componentOriginal392da982830b91ad10d7d6de273bd7a9); ?>
<?php endif; ?>
        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); if ($__empty_1): ?>
            <div class="col-span-full text-center py-6 text-gray-500 dark:text-gray-400 text-sm">
                <?php echo e($isArabic ? 'لا توجد منتجات' : 'No products found'); ?>

            </div>
        <?php endif; ?>
    </div>
</div>
<?php /**PATH C:\xampp0\htdocs\octopus\resources\views/components/ai/product-grid.blade.php ENDPATH**/ ?>