<!DOCTYPE html>
<html lang="{{ str_replace('_', '-', app()->getLocale()) }}" class="dark">
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="csrf-token" content="{{ csrf_token() }}">
    <link rel="icon" href="/favicon.ico">

    <title>{{ config('app.name', 'Laravel') . ' - ' . ($title ?? __('Chat with your PDF documents')) }}</title>
    <meta name="description" content="PDFPINTAR - Ubah Cara Anda Membaca PDF" />

    <!-- Open Graph Meta Tags -->
    <meta property="og:title" content="PDFPINTAR - Ubah Cara Anda Membaca PDF">
    <meta property="og:description" content="Gali Informasi Lebih Cepat. PDFPINTAR membantu Anda menggali informasi penting dengan mudah. Ajukan pertanyaan, dapatkan jawaban instan.">
    <meta property="og:image" content="https://res.cloudinary.com/dr15yjl8w/image/upload/v1722770981/public/e6w5shtwz1thgozzsoxb.png">
    <meta property="og:url" content="{{ url()->current() }}">
    <meta property="og:type" content="website">
    <meta property="og:locale" content="id_ID">
    <meta property="og:site_name" content="pdfpintar">

    <!-- 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=JetBrains+Mono:ital,wght@0,500;1,500&display=swap" rel="stylesheet">

    @if(config('app.env') == 'production')
    <script defer data-domain="pdfpintar.com" src="https://vince.ngooding.com/js/script.js"></script>
    @endif

    <!-- Scripts -->
    @vite(['resources/css/app.css', 'resources/js/app.js', 'resources/js/mingle.svelte.js'])
</head>
<body class="font-sans text-neutral-900 antialiased bg-neutral-100 dark:bg-neutral-800 dark:text-neutral-300">
    <div class="w-full h-full dark:bg-neutral-900 dark:text-neutral-300">
        {{ $slot }}
    </div>
    @stack('scripts')
    <script>
        function updateDarkMode() {
            if (window.matchMedia('(prefers-color-scheme: dark)').matches) {
                document.documentElement.classList.add('dark');
            } else {
                document.documentElement.classList.remove('dark');
            }
        }

        updateDarkMode();
        window.matchMedia('(prefers-color-scheme: dark)').addEventListener('change', updateDarkMode);
    </script>
</body>
</html>
