import type { Metadata } from "next";
import { Halant } from "next/font/google";
import { Inter } from "next/font/google";
import { Mulish } 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 mulish = Mulish({
  variable: "--font-mulish",
  subsets: ["latin"],
});

export const metadata: Metadata = {
  title: "Sonam, Will You Be Mine? - A Special Proposal",
  description: "A heartfelt proposal website dedicated to Sonam. A journey of love, feelings, and the most important question. Made with love and hope.",
  keywords: "proposal, love, sonam, forever, girlfriend, marry me",
  openGraph: {
    title: "Sonam, Will You Be Mine?",
    description: "I have something important to tell you. Come take a journey through my heart.",
    siteName: "For Sonam ❤️",
    type: "website",
    images: [
      {
        url: "http://img.b2bpic.net/free-vector/heart-confetti-transparent-background_23-2148035909.jpg",
        alt: "A romantic proposal moment",
      },
    ],
  },
  twitter: {
    card: "summary_large_image",
    title: "Sonam, Will You Be Mine?",
    description: "A special proposal just for you",
    images: ["http://img.b2bpic.net/free-vector/heart-confetti-transparent-background_23-2148035909.jpg"],
  },
};

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