import type { Metadata } from "next";
import { Geist, Geist_Mono } from "next/font/google";
import "swiper/css";
import "./globals.css";
import 'rc-rate/assets/index.css';
import "@/assets/fonts/irancell/style.css";
import { ToastContainer } from 'react-toastify';
import Header from "@/shared/Header";
import Footer from "@/shared/Footer";
import SideBar from "@/shared/SideBar";
import { ReactQueryDevtools } from '@tanstack/react-query-devtools'

import QueryProvider from "@/config/QueryProvider";

const geistSans = Geist({
  variable: "--font-geist-sans",
  subsets: ["latin"],
});

const geistMono = Geist_Mono({
  variable: "--font-geist-mono",
  subsets: ["latin"],
});

export const metadata: Metadata = {
  title: "danakcorp",
  description: "danak website",
};

export default function RootLayout({
  children,
}: Readonly<{
  children: React.ReactNode;
}>) {
  return (
    <html lang="fa">
      <head>
        <link rel="icon" href="/favicon.svg" sizes="any" />
      </head>
      <body
        className={`${geistSans.variable} ${geistMono.variable} antialiased`}
      >
        <QueryProvider>
          <div className="font-irancell xl:p-16 p-4">
            <SideBar />
            <Header />
            {children}
            <Footer />
          </div>
          <ReactQueryDevtools initialIsOpen={false} />
          <ToastContainer />

        </QueryProvider>
      </body>
    </html>
  );
}
