"use client";

import { ThemeProvider } from "@/providers/themeProvider/ThemeProvider";
import NavbarStyleFullscreen from '@/components/navbar/NavbarStyleFullscreen/NavbarStyleFullscreen';
import HeroBillboardDashboard from '@/components/sections/hero/HeroBillboardDashboard';
import FeatureBento from '@/components/sections/feature/FeatureBento';
import FeatureHoverPattern from '@/components/sections/feature/featureHoverPattern/FeatureHoverPattern';
import MetricSplitMediaAbout from '@/components/sections/about/MetricSplitMediaAbout';
import TestimonialCardSix from '@/components/sections/testimonial/TestimonialCardSix';
import PricingCardThree from '@/components/sections/pricing/PricingCardThree';
import FaqDouble from '@/components/sections/faq/FaqDouble';
import ContactCTA from '@/components/sections/contact/ContactCTA';
import FooterBaseCard from '@/components/sections/footer/FooterBaseCard';

import {
  Award,
  BarChart3,
  CheckCircle,
  Cloud,
  Code,
  Database,
  DollarSign,
  GitBranch,
  Headphones,
  HelpCircle,
  House,
  Link2,
  Package,
  Play,
  Rocket,
  Settings,
  Shield,
  Sparkles,
  Star,
  TrendingUp,
  Users,
  Zap
} from "lucide-react";

export default function LandingPage() {
  return (
    <ThemeProvider
      defaultButtonVariant="icon-arrow"
      defaultTextAnimation="background-highlight"
      borderRadius="rounded"
      contentWidth="medium"
      sizing="medium"
      background="none"
      cardStyle="gradient-bordered"
      primaryButtonStyle="gradient"
      secondaryButtonStyle="layered"
      headingFontWeight="semibold"
    >
      <div id="nav" data-section="nav">
        <NavbarStyleFullscreen
          navItems={[
            { name: "Features", id: "features-bento" },
            { name: "About", id: "about" },
            { name: "Pricing", id: "pricing" },
            { name: "FAQ", id: "faq" },
            { name: "Contact", id: "contact" }
          ]}
          brandName="AIFlow"
          bottomLeftText="Intelligent Automation"
          bottomRightText="hello@aiflow.com"
        />
      </div>

      <div id="hero" data-section="hero">
        <HeroBillboardDashboard
          title="Intelligent Automation at Scale"
          description="Harness the power of AI-driven insights and real-time analytics. Monitor, analyze, and optimize your entire operation from a single intelligent dashboard."
          tag="Next Generation AI"
          tagIcon={Sparkles}
          tagAnimation="slide-up"
          buttons={[
            { text: "Start Free Trial", href: "https://app.aiflow.com" },
            { text: "View Documentation", href: "#" }
          ]}
          buttonAnimation="slide-up"
          background={{ variant: "radial-gradient" }}
          dashboard={{
            title: "AI Metrics Hub",            logoIcon: Zap,
            imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3ARUTfDf61ekIcDAd2e7CmaPRNW/a-sleek-modern-ai-dashboard-interface-di-1772554985092-29f1b57f.png",            imageAlt: "AIFlow Dashboard",            searchPlaceholder: "Search analytics, reports, integrations...",            buttons: [
              { text: "Dashboard", href: "#" },
              { text: "Export Report", href: "#" }
            ],
            sidebarItems: [
              { icon: House, active: true },
              { icon: BarChart3, active: false },
              { icon: Settings, active: false }
            ],
            stats: [
              {
                title: "Processing Speed",                values: [2.4, 3.1, 4.2],
                valuePrefix: "",                description: "Faster than competitors"
              },
              {
                title: "Accuracy Rate",                values: [94.2, 96.8, 98.5],
                valuePrefix: "",                description: "AI prediction accuracy"
              },
              {
                title: "Active Users",                values: [12400, 18650, 24890],
                description: "Growing community"
              }
            ],
            chartTitle: "Platform Growth",            chartData: [
              { value: 45 },
              { value: 62 },
              { value: 58 },
              { value: 78 },
              { value: 92 }
            ],
            listTitle: "Recent Automations",            listItems: [
              { icon: Zap, title: "Data Pipeline Optimized", status: "Completed" },
              { icon: CheckCircle, title: "ML Model Updated", status: "Active" },
              { icon: TrendingUp, title: "Revenue Analysis Running", status: "Processing" }
            ]
          }}
        />
      </div>

      <div id="features-bento" data-section="features-bento">
        <FeatureBento
          title="Powerful AI Capabilities"
          description="Explore the advanced features that make AIFlow the leading intelligent automation platform. From real-time analytics to predictive insights."
          tag="Advanced Features"
          tagIcon={Zap}
          tagAnimation="slide-up"
          textboxLayout="default"
          animationType="slide-up"
          useInvertedBackground={false}
          features={[
            {
              title: "Real-Time Analytics",              description: "Live dashboards with instant insights and automated reporting",              bentoComponent: "animated-bar-chart"
            },
            {
              title: "AI Predictions",              description: "Machine learning models that forecast trends and opportunities",              bentoComponent: "line-chart"
            },
            {
              title: "Smart Integrations",              description: "Connect 500+ apps and services seamlessly",              bentoComponent: "orbiting-icons",              centerIcon: Zap,
              items: [
                { icon: Database, ring: 1 },
                { icon: Cloud, ring: 1 },
                { icon: Link2, ring: 2 },
                { icon: Package, ring: 2 }
              ]
            },
            {
              title: "Automated Workflows",              description: "Intelligent automation that learns and improves over time",              bentoComponent: "icon-info-cards",              items: [
                { icon: Zap, label: "Triggers", value: "10K+" },
                { icon: Play, label: "Actions", value: "50K+" },
                { icon: GitBranch, label: "Workflows", value: "Unlimited" }
              ]
            }
          ]}
        />
      </div>

      <div id="features-hover" data-section="features-hover">
        <FeatureHoverPattern
          title="Why Choose AIFlow"
          description="Experience the difference with intelligent automation designed for modern enterprises"
          tag="Premium Benefits"
          tagIcon={Award}
          tagAnimation="slide-up"
          textboxLayout="default"
          animationType="slide-up"
          useInvertedBackground={false}
          features={[
            {
              icon: Shield,
              title: "Enterprise Security",              description: "Bank-level encryption and compliance with GDPR, SOC 2, and ISO standards"
            },
            {
              icon: Zap,
              title: "Lightning Fast",              description: "Process millions of events per second with sub-millisecond latency"
            },
            {
              icon: Users,
              title: "Team Collaboration",              description: "Real-time collaboration with role-based access and audit trails"
            },
            {
              icon: TrendingUp,
              title: "Scalable Growth",              description: "Grow from startup to enterprise without changing your platform"
            },
            {
              icon: Headphones,
              title: "24/7 Support",              description: "Dedicated support team available around the clock for your success"
            },
            {
              icon: Code,
              title: "Developer Friendly",              description: "Comprehensive APIs, SDKs, and documentation for seamless integration"
            }
          ]}
        />
      </div>

      <div id="about" data-section="about">
        <MetricSplitMediaAbout
          tag="Our Impact"
          tagIcon={Sparkles}
          tagAnimation="slide-up"
          title="Transforming Business Operations with Intelligent Automation"
          description="Founded in 2022, AIFlow has empowered thousands of enterprises to automate their most critical workflows. Our platform combines cutting-edge machine learning with intuitive design to deliver measurable results in weeks, not months."
          metrics={[
            { value: "10,000+", title: "Active Users Worldwide" },
            { value: "5B+", title: "Daily Automations Processed" }
          ]}
          imageSrc="https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3ARUTfDf61ekIcDAd2e7CmaPRNW/team-collaboration-scene-showing-diverse-1772554985591-500e4ae7.png"
          imageAlt="AIFlow Team Collaboration"
          mediaAnimation="slide-up"
          metricsAnimation="slide-up"
          useInvertedBackground={false}
        />
      </div>

      <div id="testimonials" data-section="testimonials">
        <TestimonialCardSix
          title="Loved by Industry Leaders"
          description="See what customers are saying about AIFlow"
          tag="Customer Success"
          tagIcon={Star}
          tagAnimation="slide-up"
          textboxLayout="default"
          animationType="slide-up"
          useInvertedBackground={false}
          testimonials={[
            {
              id: "1",              name: "Sarah Chen",              handle: "@sarah_chen",              testimonial: "AIFlow transformed our operations. We automated 80% of repetitive tasks and saw a 3x improvement in productivity within the first month.",              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3ARUTfDf61ekIcDAd2e7CmaPRNW/professional-headshot-of-a-confident-tec-1772554984967-d879e861.png",              imageAlt: "Sarah Chen"
            },
            {
              id: "2",              name: "Michael Rodriguez",              handle: "@mrodriguez",              testimonial: "The platform's intelligence is remarkable. It learns from our workflows and continuously suggests optimizations that actually work.",              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3ARUTfDf61ekIcDAd2e7CmaPRNW/professional-headshot-of-a-business-lead-1772554984848-d228c73b.png",              imageAlt: "Michael Rodriguez"
            },
            {
              id: "3",              name: "Emily Watson",              handle: "@emily_w",              testimonial: "Best investment we've made. The ROI was immediate, and the support team is phenomenal. Highly recommended for any enterprise.",              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3ARUTfDf61ekIcDAd2e7CmaPRNW/professional-headshot-of-a-startup-found-1772554984937-12e79493.png",              imageAlt: "Emily Watson"
            },
            {
              id: "4",              name: "David Kim",              handle: "@dkim_tech",              testimonial: "AIFlow's integrations are seamless. We connected our entire tech stack in hours, not weeks. Game-changer for our team.",              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3ARUTfDf61ekIcDAd2e7CmaPRNW/professional-headshot-of-a-tech-executiv-1772554984889-8b5ee281.png",              imageAlt: "David Kim"
            },
            {
              id: "5",              name: "Jessica Allen",              handle: "@jallen",              testimonial: "The dashboard is intuitive, powerful, and beautiful. Our entire team adopted it within days. Outstanding product.",              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3ARUTfDf61ekIcDAd2e7CmaPRNW/professional-headshot-of-a-business-inno-1772554984811-15a6a644.png",              imageAlt: "Jessica Allen"
            },
            {
              id: "6",              name: "Marcus Johnson",              handle: "@mjohnson",              testimonial: "Exceptional analytics capabilities. We now have insights into our operations that were impossible to get before. Worth every penny.",              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3ARUTfDf61ekIcDAd2e7CmaPRNW/professional-headshot-of-a-tech-visionar-1772554984870-1275a3d0.png",              imageAlt: "Marcus Johnson"
            }
          ]}
          speed={40}
          topMarqueeDirection="left"
        />
      </div>

      <div id="pricing" data-section="pricing">
        <PricingCardThree
          title="Simple, Transparent Pricing"
          description="Choose the perfect plan for your business. Scale up anytime with no hidden fees."
          tag="Flexible Plans"
          tagIcon={DollarSign}
          tagAnimation="slide-up"
          textboxLayout="default"
          animationType="slide-up"
          useInvertedBackground={false}
          plans={[
            {
              id: "starter",              price: "$299",              name: "Starter",              buttons: [
                { text: "Get Started", href: "https://app.aiflow.com" },
                { text: "Contact Sales", href: "#" }
              ],
              features: [
                "Up to 10 automations",                "Real-time dashboards",                "Basic integrations",                "Email support",                "1 team member"
              ]
            },
            {
              id: "pro",              badge: "Most Popular",              badgeIcon: Sparkles,
              price: "$999",              name: "Professional",              buttons: [
                { text: "Get Started", href: "https://app.aiflow.com" },
                { text: "Contact Sales", href: "#" }
              ],
              features: [
                "Unlimited automations",                "Advanced analytics",                "500+ integrations",                "Priority support",                "Up to 10 team members",                "Custom workflows"
              ]
            },
            {
              id: "enterprise",              price: "Custom",              name: "Enterprise",              buttons: [
                { text: "Contact Sales", href: "#" },
                { text: "Schedule Demo", href: "#" }
              ],
              features: [
                "Everything in Pro",                "Dedicated account manager",                "Custom integrations",                "SLA guarantee",                "Unlimited team members",                "Advanced security"
              ]
            }
          ]}
        />
      </div>

      <div id="faq" data-section="faq">
        <FaqDouble
          title="Frequently Asked Questions"
          description="Find answers to common questions about AIFlow"
          tag="Help & Support"
          tagIcon={HelpCircle}
          tagAnimation="slide-up"
          textboxLayout="default"
          animationType="slide-up"
          useInvertedBackground={false}
          faqsAnimation="slide-up"
          animationType="smooth"
          faqs={[
            {
              id: "1",              title: "How does AIFlow's automation work?",              content: "AIFlow uses machine learning algorithms to analyze your workflows and identify automation opportunities. Our platform learns from your patterns and continuously optimizes performance."
            },
            {
              id: "2",              title: "Is my data secure with AIFlow?",              content: "Absolutely. We use bank-level encryption, comply with GDPR and SOC 2, and perform regular security audits. Your data is encrypted in transit and at rest."
            },
            {
              id: "3",              title: "Can I integrate AIFlow with my existing tools?",              content: "Yes! AIFlow integrates with 500+ applications including Salesforce, HubSpot, Slack, and more. We also offer custom API integrations."
            },
            {
              id: "4",              title: "What's the typical implementation timeline?",              content: "Most customers are up and running within 48 hours. Our onboarding team guides you through setup, and you can start automating workflows immediately."
            },
            {
              id: "5",              title: "Do you offer free trials?",              content: "Yes, we offer a 14-day free trial with full access to all features. No credit card required to start."
            },
            {
              id: "6",              title: "What support options are available?",              content: "All plans include email support. Professional and Enterprise plans include priority phone support, live chat, and a dedicated success manager."
            }
          ]}
        />
      </div>

      <div id="contact" data-section="contact">
        <ContactCTA
          tag="Ready to Transform?"
          tagIcon={Rocket}
          tagAnimation="slide-up"
          title="Start Your AI Automation Journey Today"
          description="Join thousands of enterprises automating their operations with AIFlow. Get your free trial account set up in minutes."
          buttons={[
            { text: "Start Free Trial", href: "https://app.aiflow.com" },
            { text: "Schedule Demo", href: "#" }
          ]}
          buttonAnimation="slide-up"
          background={{ variant: "gradient-bars" }}
          useInvertedBackground={false}
        />
      </div>

      <div id="footer" data-section="footer">
        <FooterBaseCard
          logoText="AIFlow"
          columns={[
            {
              title: "Product",              items: [
                { label: "Features", href: "#features-bento" },
                { label: "Pricing", href: "#pricing" },
                { label: "Security", href: "#" },
                { label: "Integrations", href: "#" }
              ]
            },
            {
              title: "Company",              items: [
                { label: "About", href: "#about" },
                { label: "Blog", href: "#" },
                { label: "Careers", href: "#" },
                { label: "Contact", href: "#contact" }
              ]
            },
            {
              title: "Resources",              items: [
                { label: "Documentation", href: "#" },
                { label: "API Docs", href: "#" },
                { label: "Help Center", href: "#" },
                { label: "Community", href: "#" }
              ]
            },
            {
              title: "Legal",              items: [
                { label: "Privacy Policy", href: "#" },
                { label: "Terms of Service", href: "#" },
                { label: "Cookie Policy", href: "#" },
                { label: "Status", href: "#" }
              ]
            }
          ]}
          copyrightText="© 2025 AIFlow. Intelligent automation for the modern enterprise."
        />
      </div>
    </ThemeProvider>
  );
}
