// src/app/layout.tsx import type { Metadata } from 'next'; import Script from 'next/script'; import '@/styles/globals.css'; import '@/styles/background-web.css'; import { AuthProvider } from '@/lib/hooks/useAuth'; import { THEME_STORAGE_KEY } from '@/lib/theme'; export const metadata: Metadata = { title: 'DyoLink - Dental Clinic & Lab Communication Hub', description: 'Connect dental clinics and laboratories seamlessly', }; export default function RootLayout({ children, }: { children: React.ReactNode; }) { const themeInit = `(function(){try{var k=${JSON.stringify(THEME_STORAGE_KEY)};var t=localStorage.getItem(k);document.documentElement.setAttribute('data-theme',t==='light'||t==='dark'?t:'dark');}catch(e){document.documentElement.setAttribute('data-theme','dark');}})();`; return (