import type { Metadata } from "next";
import { Halant } from "next/font/google";
import { Inter } from "next/font/google";
import "./globals.css";
import "@/lib/gsap-setup";
import { ServiceWrapper } from "@/components/ServiceWrapper";
import Tag from "@/tag/Tag";
import { getVisualEditScript } from "@/utils/visual-edit-script";
import { Mulish } from "next/font/google";
import { Nunito_Sans } from "next/font/google";



export const metadata: Metadata = {
  title: 'KHATWA Platform | E-commerce Solution',
  description: 'Empower your e-commerce business with KHATWA\'s intuitive platform. Streamline product, order, and customer management for the Jordanian market.',
  keywords: ["KHATWA, admin panel, e-commerce, footwear, shoes, dashboard, Jordan, JOD, product management, order management, store settings"],
  openGraph: {
    "title": "KHATWA Admin Panel",
    "description": "Manage your KHATWA e-commerce footwear store with ease.",
    "url": "https://admin.khatwa.com",
    "siteName": "KHATWA Admin",
    "images": [
      {
        "url": "http://img.b2bpic.net/free-vector/elegant-design-car-rental-business-infographic_23-2149235348.jpg",
        "alt": "KHATWA Admin Dashboard"
      }
    ],
    "type": "website"
  },
  twitter: {
    "card": "summary_large_image",
    "title": "KHATWA Admin Panel",
    "description": "Manage your KHATWA e-commerce footwear store with ease.",
    "images": [
      "http://img.b2bpic.net/free-vector/elegant-design-car-rental-business-infographic_23-2149235348.jpg"
    ]
  },
  robots: {
    "index": true,
    "follow": true
  },
};

const mulish = Mulish({
  variable: "--font-mulish",
  subsets: ["latin"],
});
const nunitoSans = Nunito_Sans({
  variable: "--font-nunito-sans",
  subsets: ["latin"],
});

export default function RootLayout({
  children,
}: Readonly<{
  children: React.ReactNode;
}>) {
  return (
    <html lang="en" suppressHydrationWarning>
      <ServiceWrapper>
        <body className={`${mulish.variable} ${nunitoSans.variable} antialiased`}>
          <Tag />
          {children}
          <script
              dangerouslySetInnerHTML={{
                  __html: `${getVisualEditScript()}`
              }}
          />
        </body>
      </ServiceWrapper>
    </html>
  );
}
