import Navbar from "@/components/Partials/Navbar";
import HeroSection from "@/components/Partials/Hero";
import Tentang from "@/components/Partials/Tentang";
import Pengumuman from "@/components/Partials/Pengumuman";
import Peraturan from "@/components/Partials/Peraturan";
import Undangan from "@/components/Partials/Undangan";
import Footer from "@/components/Partials/Footer";
import { Head } from "@inertiajs/react";
import Guest from "@/layouts/guest-layout";
import PopupModal from "@/components/Partials/PopupModal";
import { useState } from "react";

export default function Home() {
    const [showPopup, setShowPopup] = useState(true);

    const handleClosePopup = () => {
        setShowPopup(false);
    };

    return (
        <>
            {showPopup && <PopupModal onClose={handleClosePopup} />}
            <Guest>
                <Head title="Home" />
                <Navbar />
                <HeroSection />
                <Tentang />
                <Pengumuman />
                <Peraturan />
                <Undangan />
                <Footer />
            </Guest>
        </>
    );
}
