<!-- SEO Component - This includes all meta tags, title, hreflang, and schema -->
<?php if(isset($metatags) && isset($schema)): ?>
    <?php if (isset($component)) { $__componentOriginalaac5c311a1def36561cfafc293b5015f = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginalaac5c311a1def36561cfafc293b5015f = $attributes; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.seo.head','data' => ['metatags' => $metatags,'schema' => $schema]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('seo.head'); ?>
<?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(['metatags' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($metatags),'schema' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($schema)]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginalaac5c311a1def36561cfafc293b5015f)): ?>
<?php $attributes = $__attributesOriginalaac5c311a1def36561cfafc293b5015f; ?>
<?php unset($__attributesOriginalaac5c311a1def36561cfafc293b5015f); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalaac5c311a1def36561cfafc293b5015f)): ?>
<?php $component = $__componentOriginalaac5c311a1def36561cfafc293b5015f; ?>
<?php unset($__componentOriginalaac5c311a1def36561cfafc293b5015f); ?>
<?php endif; ?>
<?php else: ?>
    
    <?php
        $defaultMetatags = [
            'charset' => 'utf-8',
            'viewport' => 'width=device-width, initial-scale=1.0',
            'language' => app()->getLocale(),
            'robots' => 'index, follow',
            'description' => config('configrations.site_description') ?? 'About My Company',
            'author' => config('configrations.site_name') ?? 'My Company',
            'title' => config('configrations.site_name') ?? 'My Company',
        ];

        $defaultSchema = [
            '@context' => 'https://schema.org',
            '@type' => 'WebPage',
            'name' => config('configrations.site_name') ?? 'My Company',
            'url' => url()->current(),
        ];
    ?>
    <?php if (isset($component)) { $__componentOriginalaac5c311a1def36561cfafc293b5015f = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginalaac5c311a1def36561cfafc293b5015f = $attributes; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.seo.head','data' => ['metatags' => $defaultMetatags,'schema' => $defaultSchema]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('seo.head'); ?>
<?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(['metatags' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($defaultMetatags),'schema' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute($defaultSchema)]); ?>
<?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginalaac5c311a1def36561cfafc293b5015f)): ?>
<?php $attributes = $__attributesOriginalaac5c311a1def36561cfafc293b5015f; ?>
<?php unset($__attributesOriginalaac5c311a1def36561cfafc293b5015f); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalaac5c311a1def36561cfafc293b5015f)): ?>
<?php $component = $__componentOriginalaac5c311a1def36561cfafc293b5015f; ?>
<?php unset($__componentOriginalaac5c311a1def36561cfafc293b5015f); ?>
<?php endif; ?>
<?php endif; ?>




<?php
    $currentLocale = app()->getLocale();
    $isRTL = in_array($currentLocale, ['ar', 'he', 'fa', 'ur']); // RTL languages
    $textDirection = $isRTL ? 'rtl' : 'ltr';
?>


<script>
    document.documentElement.setAttribute('lang', '<?php echo e($currentLocale); ?>');
    document.documentElement.setAttribute('dir', '<?php echo e($textDirection); ?>');
</script>


<link rel="manifest" href="/manifest.json">
<meta name="theme-color" content="#007bff">
<meta name="mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="default">
<meta name="apple-mobile-web-app-title" content="<?php echo e(config('configrations.site_name') ?? 'DHI Egypt'); ?>">
<link rel="apple-touch-icon" href="/favicon.png">


<script>
    if ('serviceWorker' in navigator) {
        window.addEventListener('load', function() {
            navigator.serviceWorker.register('/sw.js')
                .then(function(registration) {
                    console.log('Service Worker registered successfully:', registration.scope);
                })
                .catch(function(error) {
                    console.log('Service Worker registration failed:', error);
                });
        });
    }
</script>



<!-- fonts -->
 <link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Cairo:wght@200..1000&display=swap" rel="stylesheet">

<!-- CSS Files================================================== -->
<link rel="stylesheet" href="<?php echo e(Path::css('all.min.css')); ?>" />
<link rel="stylesheet" href="<?php echo e(Path::css('bootstrap.min.css')); ?>" />
<link rel="stylesheet" href="<?php echo e(Path::css('swiper-bundle.min.css')); ?>" />
<link rel="stylesheet" href="<?php echo e(Path::css('style.css')); ?>" />
<link rel="stylesheet" href="<?php echo e(Path::css('media.css')); ?>" />
 

<!-- Google Tag Manager -->
<script>
    (function(w, d, s, l, i) {
        w[l] = w[l] || [];
        w[l].push({
            'gtm.start': new Date().getTime(),
            event: 'gtm.js'
        });
        var f = d.getElementsByTagName(s)[0],
            j = d.createElement(s),
            dl = l != 'dataLayer' ? '&l=' + l : '';
        j.async = true;
        j.src =
            'https://www.googletagmanager.com/gtm.js?id=' + i + dl;
        f.parentNode.insertBefore(j, f);
    })(window, document, 'script', 'dataLayer', '<?php echo e(config('settings.google_tag_manager_id')); ?>');
</script>
<!-- End Google Tag Manager -->
<?php /**PATH /home/egypetoo/public_html/resources/views/components/website/partials/_head.blade.php ENDPATH**/ ?>