import "./globals.css";
import Header from "@/components/Header";
import Footer from "@/components/Footer";
import localFont from "next/font/local";
import { Figtree, Outfit } from "next/font/google";
import { Montserrat } from "next/font/google";
import { Toaster } from "sonner";

const aeonik = localFont({
  src: [
    {
      path: "../public/fonts/aeonik/Aeonik-Regular.ttf",
      weight: "400",
      style: "normal",
    },
    {
      path: "../public/fonts/aeonik/Aeonik-Bold.ttf",
      weight: "700",
      style: "normal",
    },
  ],
  variable: "--font-aeonik",
});

const figtree = Figtree({
  subsets: ["latin"],
  weight: ["300", "400", "500", "600", "700", "800", "900"],
  variable: "--font-figtree",
});

const outfit = Outfit({
  subsets: ["latin"],
  weight: ["300", "400", "500", "600", "700", "800", "900"],
  variable: "--font-outfit",
});

const montserrat = Montserrat({
  subsets: ["latin"],
  weight: ["300", "400", "500", "600", "700", "800", "900"],
  variable: "--font-montserrat",
});

const walsheim = localFont({
  src: [
    {
      path: "../public/fonts/gt-walsheim-trial/GT-Walsheim-Regular-Trial-BF651b7fc71a47d.otf",
      weight: "400",
      style: "normal",
    },
    {
      path: "../public/fonts/gt-walsheim-trial/GT-Walsheim-Medium-Trial-BF651b7fc728fb3.otf",
      weight: "500",
      style: "normal",
    },
    {
      path: "../public/fonts/gt-walsheim-trial/GT-Walsheim-Bold-Trial-BF651b7fc737c57.otf",
      weight: "700",
      style: "normal",
    },
  ],
  variable: "--font-walsheim",
});

export default function RootLayout({
  children,
}: {
  children: React.ReactNode;
}) {
  return (
    <html
      lang="en"
      className={`${aeonik.variable} ${figtree.variable} ${montserrat.variable} ${walsheim.variable} ${outfit.variable}`}
    >
      <body
        className="flex flex-col min-h-screen bg-white max-w-[1920px] mx-auto"
        suppressHydrationWarning
      >
        <Toaster richColors position="bottom-right" />
        <Header />
        <main className="flex-1 w-full pt-0 md:pt-[69px]">{children}</main>
        <Footer />
      </body>
    </html>
  );
}
