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

const halant = Halant({
  variable: "--font-halant",
  subsets: ["latin"],
  weight: ["300", "400", "500", "600", "700"],
});

const inter = Inter({
  variable: "--font-inter",
  subsets: ["latin"],
});

const manrope = Manrope({
  variable: "--font-manrope",
  subsets: ["latin"],
});

const dmSans = DM_Sans({
  variable: "--font-dm-sans",
  subsets: ["latin"],
});

export const metadata: Metadata = {
  title: "Sadek Musical Instruments | Music Store Dubai",
  description: "Dubai's trusted music store since 1998. Premium guitars, drums, keyboards, and audio equipment. Expert repair & setup services. 4.6★ rating from 800+ customers.",
  keywords: "music store Dubai, guitars, drums, keyboards, audio equipment, music instruments UAE, repair service, professional musicians",
  openGraph: {
    title: "Sadek Musical Instruments - Dubai's Music Store",
    description: "Your Sound Starts Here. Premium instruments, expert service, and passionate musicians serving Dubai since 1998.",
    type: "website",
    siteName: "Sadek Musical Instruments",
    images: [
      {
        url: "http://img.b2bpic.net/free-photo/close-up-man-playing-guitar-studio_23-2148366499.jpg",
        alt: "Sadek Musical Instruments Store Dubai",
      },
    ],
  },
  robots: {
    index: true,
    follow: true,
  },
};

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