"use client"

import { ThemeProvider } from "@/providers/themeProvider/ThemeProvider";
import NavbarStyleCentered from '@/components/navbar/NavbarStyleCentered/NavbarStyleCentered';
import HeroLogoBillboardSplit from '@/components/sections/hero/HeroLogoBillboardSplit';
import TextAbout from '@/components/sections/about/TextAbout';
import FeatureCardNineteen from '@/components/sections/feature/FeatureCardNineteen';
import ProductCardOne from '@/components/sections/product/ProductCardOne';
import TestimonialCardSixteen from '@/components/sections/testimonial/TestimonialCardSixteen';
import MetricCardThree from '@/components/sections/metrics/MetricCardThree';
import ContactSplit from '@/components/sections/contact/ContactSplit';
import FooterCard from '@/components/sections/footer/FooterCard';
import { AlertCircle, CheckCircle, Clock, Mail, MapPin, Phone } from "lucide-react";

export default function LandingPage() {
  const handleContactSubmit = (email: string) => {
    console.log('Contact form submitted with email:', email);
  };

  return (
    <ThemeProvider
      defaultButtonVariant="expand-hover"
      defaultTextAnimation="reveal-blur"
      borderRadius="soft"
      contentWidth="medium"
      sizing="largeSizeMediumTitles"
      background="none"
      cardStyle="subtle-shadow"
      primaryButtonStyle="primary-glow"
      secondaryButtonStyle="layered"
      headingFontWeight="normal"
    >
      <div id="nav" data-section="nav">
        <NavbarStyleCentered
          brandName="Dallas Plumbing Pros"
          navItems={[
            { name: "Services", id: "services" },
            { name: "How It Works", id: "process" },
            { name: "Reviews", id: "testimonials" },
            { name: "About", id: "about" },
            { name: "Contact", id: "contact" }
          ]}
          button={{
            text: "Book Service",            href: "contact"
          }}
        />
      </div>
      
      <div id="hero" data-section="hero">
        <HeroLogoBillboardSplit
          logoText="DALLAS PLUMBING PROS"
          description="Precision plumbing for Dallas homes. We diagnose every problem with advanced camera inspections, explain exactly what you need, fix it right the first time, and verify results before we leave."
          background={{ variant: "plain" }}
          buttons={[
            { text: "Book Service Now", href: "contact" },
            { text: "Call for Emergency Help", href: "tel:+1-855-DAL-PROS" }
          ]}
          layoutOrder="default"
          imageSrc="https://img.b2bpic.net/free-photo/high-angle-man-working-as-plumber_23-2150746421.jpg"
          imageAlt="Professional plumber performing camera inspection of pipes"
          frameStyle="card"
          ariaLabel="Hero section - Dallas Plumbing Pros precision plumbing service"
        />
      </div>
      
      <div id="about" data-section="about">
        <TextAbout
          tag="Trusted by Dallas Homeowners"
          title="5-star diagnostics, same-day solutions, and the expertise you can trust when something goes wrong."
          useInvertedBackground="noInvert"
          buttons={[
            { text: "See Our Reviews", href: "testimonials" }
          ]}
        />
      </div>
      
      <div id="difference" data-section="difference">
        <FeatureCardNineteen
          tag="Why Choose Dallas Plumbing Pros"
          title="What Makes Us Different"
          description="No guesswork. No surprises. Just expertise, transparency, and solutions that last."
          textboxLayout="default"
          useInvertedBackground="noInvert"
          features={[
            {
              id: 1,
              tag: "Advanced Diagnostics",              title: "Camera-Based Inspection",              subtitle: "Precision problem-solving starts with seeing exactly what's happening.",              description: "Every diagnosis begins with state-of-the-art camera inspections. We locate blockages, cracks, and issues other plumbers might miss. No guessing. No unnecessary work. Just clear answers.",              imageSrc: "https://img.b2bpic.net/free-photo/modern-automobile-mechanic-composition_23-2147881677.jpg",              imageAlt: "Professional camera inspection system for pipe diagnostics"
            },
            {
              id: 2,
              tag: "Clear Communication",              title: "Explained Repairs",              subtitle: "You always know exactly what's happening and why.",              description: "We explain every problem in plain language, show you what we found, and discuss your options before we start. Transparent pricing. No pressure. Just honest expertise.",              imageSrc: "https://img.b2bpic.net/free-photo/profile-man-touching-socket-wall-with-screwdriver_259150-58245.jpg",              imageAlt: "Professional plumber explaining work to homeowner"
            },
            {
              id: 3,
              tag: "Workmanship Standard",              title: "Clean, Respectful Work",              subtitle: "Your home is treated with the same care we'd give our own.",              description: "Every job leaves your home spotless. We protect your floors, respect your space, and clean up completely. Professional service means professional respect.",              imageSrc: "https://img.b2bpic.net/free-photo/female-mechanic-smiling-while-repairing-car_1170-1227.jpg",              imageAlt: "Clean bathroom with finished plumbing installation"
            },
            {
              id: 4,
              tag: "Verified Results",              title: "Problems Fully Resolved",              subtitle: "We verify proper flow, pressure, and performance before leaving.",              description: "The job isn't done until it's done right. We test water pressure, check flow rates, and confirm every fixture works perfectly. Your peace of mind is our standard.",              imageSrc: "https://img.b2bpic.net/free-photo/plumbing-professional-doing-his-job_23-2150721539.jpg",              imageAlt: "Professional technician testing water pressure and system performance"
            }
          ]}
        />
      </div>
      
      <div id="services" data-section="services">
        <ProductCardOne
          title="Our Services"
          description="Professional plumbing solutions for every home need. Precision diagnostics, expert repairs, and verified results."
          textboxLayout="default"
          useInvertedBackground="noInvert"
          products={[
            {
              id: "1",              name: "Drain & Pipe Cleaning",              price: "Expert Service",              imageSrc: "https://img.b2bpic.net/free-photo/male-worker-operating-machinery-factory_107420-96043.jpg",              imageAlt: "Drain cleaning and pipe maintenance service"
            },
            {
              id: "2",              name: "Bathtub & Shower Repairs",              price: "Expert Service",              imageSrc: "https://img.b2bpic.net/free-photo/female-mechanic-smiling-while-repairing-car_1170-1227.jpg",              imageAlt: "Bathroom fixture repair and installation"
            },
            {
              id: "3",              name: "Toilet Repairs & Replacements",              price: "Expert Service",              imageSrc: "https://img.b2bpic.net/free-photo/plumbing-professional-doing-his-job_23-2150721542.jpg",              imageAlt: "Toilet repair and replacement service"
            },
            {
              id: "4",              name: "Water Heater Service",              price: "Expert Service",              imageSrc: "https://img.b2bpic.net/free-photo/plumbing-professional-doing-his-job_23-2150721566.jpg",              imageAlt: "Water heater service and replacement"
            },
            {
              id: "5",              name: "Leak Detection & Repair",              price: "Expert Service",              imageSrc: "https://img.b2bpic.net/free-photo/modern-automobile-mechanic-composition_23-2147881677.jpg",              imageAlt: "Advanced leak detection service"
            },
            {
              id: "6",              name: "Garbage Disposal Repair",              price: "Expert Service",              imageSrc: "https://img.b2bpic.net/free-photo/man-installs-heating-system-house-checks-pipes-with-wrench_169016-53082.jpg",              imageAlt: "Garbage disposal repair and replacement"
            },
            {
              id: "7",              name: "Outdoor Spigots & Utility Sinks",              price: "Expert Service",              imageSrc: "https://img.b2bpic.net/free-photo/plumbing-professional-doing-his-job_23-2150721549.jpg",              imageAlt: "Outdoor spigot and utility sink installation"
            },
            {
              id: "8",              name: "Re-Piping & Full Installations",              price: "Expert Service",              imageSrc: "https://img.b2bpic.net/free-photo/service-maintenance-worker-repairing_23-2149176722.jpg",              imageAlt: "Complete re-piping and installation service"
            }
          ]}
          gridVariant="bento-grid"
          animationType="slide-up"
        />
      </div>
      
      <div id="testimonials" data-section="testimonials">
        <TestimonialCardSixteen
          title="Trusted by Dallas Homeowners"
          description="Real customers, real results. See why homeowners across Dallas choose Dallas Plumbing Pros."
          textboxLayout="default"
          useInvertedBackground="noInvert"
          animationType="slide-up"
          testimonials={[
            {
              id: "1",              name: "Sarah Mitchell",              role: "Homeowner",              company: "Highland Park, Dallas",              rating: 5,
              imageSrc: "https://img.b2bpic.net/free-photo/smiling-middle-aged-attractive-woman-showing-thumb-up-outdoors_1262-12526.jpg",              imageAlt: "Portrait of Sarah Mitchell"
            },
            {
              id: "2",              name: "James Rodriguez",              role: "Homeowner",              company: "Oak Lawn, Dallas",              rating: 5,
              imageSrc: "https://img.b2bpic.net/free-photo/smiling-man-sitting-cafe-table-gesturing_1262-1141.jpg",              imageAlt: "Portrait of James Rodriguez"
            },
            {
              id: "3",              name: "Linda Chen",              role: "Homeowner",              company: "Uptown, Dallas",              rating: 5,
              imageSrc: "https://img.b2bpic.net/free-photo/happy-businesswoman-smiling-looking-camera-successful-confident-grey-haired-manager-sitting-office-room-workplace-business-management-concept_74855-7343.jpg",              imageAlt: "Portrait of Linda Chen"
            },
            {
              id: "4",              name: "Michael Thompson",              role: "Homeowner",              company: "University Park, Dallas",              rating: 5,
              imageSrc: "https://img.b2bpic.net/free-photo/attractive-blonde-girl-tulle-skirt-having-fun-stairs-she-is-smiling-down_197531-617.jpg",              imageAlt: "Portrait of Michael Thompson"
            }
          ]}
          kpiItems={[
            { value: "500+", label: "Homes Served" },
            { value: "98%", label: "Same-Day Solutions" },
            { value: "5-Star", label: "Average Rating" }
          ]}
        />
      </div>
      
      <div id="process" data-section="process">
        <FeatureCardNineteen
          tag="Simple & Transparent"
          title="How It Works"
          description="Three straightforward steps from problem to solution."
          textboxLayout="default"
          useInvertedBackground="noInvert"
          features={[
            {
              id: 1,
              tag: "Step One",              title: "Call or Book Online",              subtitle: "Same-day appointments available for urgent issues.",              description: "Contact us by phone or book directly online. Tell us what's happening, and we'll schedule you at a time that works. Emergency calls get priority response.",              imageSrc: "https://img.b2bpic.net/free-photo/plumber-assembling-pipe_1098-17772.jpg",              imageAlt: "Booking a plumbing appointment online"
            },
            {
              id: 2,
              tag: "Step Two",              title: "Expert Diagnosis",              subtitle: "Camera inspection and clear explanation of what we find.",              description: "We arrive on time, assess your issue with advanced diagnostics, and explain exactly what's needed. No pressure. No unnecessary upsells. Just honest solutions.",              imageSrc: "https://img.b2bpic.net/free-photo/side-view-man-working-as-plumber_23-2150746308.jpg",              imageAlt: "Professional plumber performing diagnostic inspection"
            },
            {
              id: 3,
              tag: "Step Three",              title: "Precise Repair & Verification",              subtitle: "Fixed right the first time with verified results.",              description: "We complete the repair with precision and verify everything works perfectly. Water pressure tested. Flow confirmed. Your plumbing working flawlessly.",              imageSrc: "https://img.b2bpic.net/free-photo/plumbing-professional-doing-his-job_23-2150721539.jpg",              imageAlt: "Quality verification and system testing"
            }
          ]}
        />
      </div>
      
      <div id="confidence" data-section="confidence">
        <MetricCardThree
          tag="Emergency Response"
          title="Available When You Need Us"
          description="Calm under pressure. Solutions when it matters most."
          textboxLayout="default"
          useInvertedBackground="noInvert"
          animationType="slide-up"
          metrics={[
            {
              id: "1",              icon: Clock,
              title: "Same-Day Service",              value: "Often Available"
            },
            {
              id: "2",              icon: AlertCircle,
              title: "Emergency Response",              value: "24/7 Available"
            },
            {
              id: "3",              icon: CheckCircle,
              title: "Problem Resolution",              value: "First Visit, 90%+"
            }
          ]}
        />
      </div>
      
      <div id="contact" data-section="contact">
        <ContactSplit
          tag="Ready to Solve It"
          title="When Plumbing Fails, We Deliver."
          description="Book your service appointment now or call immediately for emergency assistance. Dallas Plumbing Pros is ready to solve your problem with precision and care."
          background={{ variant: "plain" }}
          useInvertedBackground="noInvert"
          imageSrc="https://img.b2bpic.net/free-photo/profile-man-touching-socket-wall-with-screwdriver_259150-58245.jpg"
          imageAlt="Professional plumbing service completion"
          mediaPosition="right"
          inputPlaceholder="Your email address"
          buttonText="Schedule Service"
          termsText="We'll contact you within 2 hours during business hours to confirm your appointment and discuss your plumbing needs."
          onSubmit={handleContactSubmit}
        />
      </div>
      
      <div id="footer" data-section="footer">
        <FooterCard
          logoText="Dallas Plumbing Pros"
          copyrightText="© 2025 Dallas Plumbing Pros. All rights reserved. Precision plumbing for Dallas homes."
          socialLinks={[
            {
              icon: Phone,
              href: "tel:+1-855-DAL-PROS",              ariaLabel: "Call Dallas Plumbing Pros"
            },
            {
              icon: Mail,
              href: "mailto:service@dallasplumbingpros.com",              ariaLabel: "Email Dallas Plumbing Pros"
            },
            {
              icon: MapPin,
              href: "https://maps.google.com/?q=Dallas+TX",              ariaLabel: "Visit Dallas Plumbing Pros location"
            }
          ]}
        />
      </div>
    </ThemeProvider>
  );
}