"use client";

import Link from "next/link";
import { ThemeProvider } from "@/providers/themeProvider/ThemeProvider";
import NavbarStyleCentered from '@/components/navbar/NavbarStyleCentered/NavbarStyleCentered';
import ContactSplit from '@/components/sections/contact/ContactSplit';
import FaqBase from '@/components/sections/faq/FaqBase';
import SocialProofOne from '@/components/sections/socialProof/SocialProofOne';
import FooterLogoReveal from '@/components/sections/footer/FooterLogoReveal';

export default function ContactPage() {
  const handleContactSubmit = (email: string) => {
    console.log('Contact form submitted:', email);
    // Handle form submission logic here
  };

  return (
    <ThemeProvider
      defaultButtonVariant="text-shift"
      defaultTextAnimation="reveal-blur"
      borderRadius="pill"
      contentWidth="smallMedium"
      sizing="mediumLargeSizeMediumTitles"
      background="circleGradient"
      cardStyle="inset"
      primaryButtonStyle="diagonal-gradient"
      secondaryButtonStyle="solid"
      headingFontWeight="medium"
    >
      <div id="nav" data-section="nav">
        <NavbarStyleCentered 
          brandName="Stemple Electric"
          navItems={[
            { name: "Home", id: "/" },
            { name: "Services", id: "/services" },
            { name: "About", id: "/about" },
            { name: "Contact", id: "/contact" }
          ]}
          button={{
            text: "Call Now",
            href: "tel:+13075551234"
          }}
        />
      </div>

      <div id="contact" data-section="contact">
        <ContactSplit 
          tag="Get In Touch"
          title="Ready to start your electrical project?"
          description="Contact Stemple Electric for fast, reliable electrical services across Wyoming. Free estimates, flexible scheduling, and professional service you can trust."
          background={{ variant: "sparkles-gradient" }}
          useInvertedBackground={false}
          imageSrc="http://img.b2bpic.net/free-photo/electrician-overalls-focused-work-switchboard-with-fuses-using-tablet_169016-66854.jpg?_wi=5"
          imageAlt="Professional electrician providing electrical services"
          mediaAnimation="slide-up"
          mediaPosition="right"
          inputPlaceholder="Enter your email for estimate"
          buttonText="Request Estimate"
          termsText="We'll contact you within 24 hours to discuss your electrical needs and provide a free estimate."
          onSubmit={handleContactSubmit}
        />
      </div>

      <div id="faq" data-section="faq">
        <FaqBase 
          title="Frequently Asked Questions"
          description="Find answers to common questions about our electrical services, scheduling, and pricing."
          tag="Help"
          textboxLayout="default"
          useInvertedBackground={false}
          faqs={[
            {
              id: "1",
              title: "Are you licensed and insured?",
              content: "Yes, Stemple Electric is fully licensed and insured. We follow all Wyoming electrical codes and safety standards. Your protection is our priority."
            },
            {
              id: "2",
              title: "Do you offer emergency electrical service?",
              content: "We do offer emergency electrical service for urgent situations. Call us immediately if you experience electrical emergencies like sparking outlets, burning smells, or loss of power."
            },
            {
              id: "3",
              title: "Do you provide free estimates?",
              content: "Yes, we provide free estimates for all services. We'll inspect your electrical needs, explain what's required, and give you a clear price before we start any work."
            },
            {
              id: "4",
              title: "How quickly can you schedule service?",
              content: "We understand electrical issues can't wait. We offer flexible scheduling and often can fit you in within 24-48 hours for non-emergencies."
            },
            {
              id: "5",
              title: "What payment methods do you accept?",
              content: "We accept cash, check, and all major credit cards for your convenience. Payment is due upon completion of work unless other arrangements are made in advance."
            }
          ]}
          faqsAnimation="slide-up"
          animationType="smooth"
        />
      </div>

      <div id="service-area" data-section="service-area">
        <SocialProofOne 
          title="Service Coverage"
          description="Proudly serving Wyoming communities with professional electrical services and reliable support."
          tag="Wyoming Wide"
          textboxLayout="default"
          useInvertedBackground={false}
          names={["Cheyenne", "Casper", "Laramie", "Gillette", "Sheridan", "Rock Springs"]}
          speed={40}
          showCard={true}
        />
      </div>

      <FooterLogoReveal 
        logoText="STEMPLE ELECTRIC"
        leftLink={{
          text: "Privacy Policy",
          href: "#"
        }}
        rightLink={{
          text: "Terms of Service",
          href: "#"
        }}
      />
    </ThemeProvider>
  );
}