import '@/assets/css/style.css'
import favicon from '@/assets/images/favicon.png'
import AppProvidersWrapper from '@/components/wrappers/AppProvidersWrapper'
import { DEFAULT_PAGE_TITLE } from '@/config/constants'
import type { Metadata } from 'next'
import { Instrument_Sans, Inter } from 'next/font/google'
import 'swiper/css'
import 'swiper/css/effect-fade'
import 'swiper/css/navigation'

const inter = Inter({
  variable: '--font-body',
  subsets: ['latin'],
  display: 'swap',
})

const instrumentSans = Instrument_Sans({
  variable: '--font-heading',
  subsets: ['latin'],
  display: 'swap',
})

export const metadata: Metadata = {
  title: {
    template: `%s | ${DEFAULT_PAGE_TITLE}`,
    default: DEFAULT_PAGE_TITLE,
  },
  icons: { icon: favicon.src },
  description: 'Mivora - Logistics, Supply Service Next.js 16 & Tailwind CSS 4 Website Template. Perfect for logistics, transport, supply chain services, freight forwarding, and warehouse management. Fully responsive, fast-loading, and easy to customize.',
  keywords: ['logistics template', 'transportation website', 'supply chain template', 'freight forwarding', 'green logistics website', 'tailwind css template', 'tailwind css 4 template', 'responsive logistics website'],
  authors: [{ name: 'Unifato' }],
  robots: 'index, follow',
}

const RootLayout = ({
  children,
}: Readonly<{
  children: React.ReactNode
}>) => {
  return (
    <html lang="en" className={`${inter.variable} ${instrumentSans.variable} antialiased`}>
      <body suppressHydrationWarning>
        <AppProvidersWrapper>{children}</AppProvidersWrapper>
      </body>
    </html>
  )
}

export default RootLayout
