<?php
/// file: app/Components/preloader.php

declare(strict_types=1);

$brand = \App\Models\SiteSetting::get('brand_name') ?: (string) (\App\Core\Config::get('app.name', 'SANEKSA'));
?>
<div id="preloader" class="preloader" role="status" aria-live="polite" aria-label="Loading">
    <div class="preloader__inner">
        <div class="preloader__logo">
            <?php \App\Core\View::component('site-logo', ['brand' => $brand, 'class' => 'h-4 w-auto md:h-6']); ?>
        </div>
        <div class="preloader__bar-wrap mt-10 w-48 md:w-72">
            <div class="preloader__bar-glow" aria-hidden="true"></div>
            <div class="preloader__bar h-px w-full overflow-hidden bg-white/10">
                <div class="preloader__bar-fill h-full w-full origin-left scale-x-0 bg-white"></div>
            </div>
        </div>
        <p class="preloader__hint mt-6 text-center text-[0.65rem] uppercase tracking-[0.35em] text-silver-500"><?= e(__('preloader.hint')) ?></p>
    </div>
</div>
