"use client";

import Link from "next/link";
import { ThemeProvider } from "@/providers/themeProvider/ThemeProvider";
import NavbarLayoutFloatingInline from "@/components/navbar/NavbarLayoutFloatingInline";
import HeroBillboardCarousel from "@/components/sections/hero/HeroBillboardCarousel";
import FeatureBento from "@/components/sections/feature/FeatureBento";
import ProductCardOne from "@/components/sections/product/ProductCardOne";
import PricingCardNine from "@/components/sections/pricing/PricingCardNine";
import MetricSplitMediaAbout from "@/components/sections/about/MetricSplitMediaAbout";
import MetricCardThree from "@/components/sections/metrics/MetricCardThree";
import TestimonialCardTen from "@/components/sections/testimonial/TestimonialCardTen";
import FaqSplitMedia from "@/components/sections/faq/FaqSplitMedia";
import ContactSplit from "@/components/sections/contact/ContactSplit";
import FooterLogoEmphasis from "@/components/sections/footer/FooterLogoEmphasis";
import {
  Zap,
  Brain,
  Code2,
  AlertCircle,
  Code,
  Database,
  Container,
  Palette,
  TrendingUp,
  BarChart3,
  PieChart,
  Search,
  BookMarked,
  Lightbulb,
  Globe,
  Crown,
  Tag,
  Activity,
  Users,
  Shield,
  Info,
  Mail,
  BookOpen,
  User,
} from "lucide-react";

export default function HomePage() {
  const navItems = [
    { name: "Home", id: "home" },
    { name: "Features", id: "features" },
    { name: "Pricing", id: "pricing" },
    { name: "About", id: "about" },
    { name: "Contact", id: "contact" },
  ];

  const footerColumns = [
    {
      items: [
        { label: "Home", href: "/" },
        { label: "Features", href: "/#features" },
        { label: "Pricing", href: "/#pricing" },
        { label: "About", href: "/#about" },
      ],
    },
    {
      items: [
        { label: "Study Helper", href: "/modes/study-helper" },
        { label: "Code Helper", href: "/modes/code-helper" },
        { label: "Business Helper", href: "/modes/business-helper" },
        { label: "Deep Research", href: "/modes/deep-research" },
      ],
    },
    {
      items: [
        { label: "Developer API", href: "/developer" },
        { label: "Documentation", href: "/docs" },
        { label: "Status", href: "https://status.airbrone.ai" },
        { label: "Blog", href: "/blog" },
      ],
    },
    {
      items: [
        { label: "Privacy Policy", href: "/privacy" },
        { label: "Terms of Service", href: "/terms" },
        { label: "Security", href: "/security" },
        { label: "Contact", href: "/#contact" },
      ],
    },
    {
      items: [
        { label: "Twitter", href: "https://twitter.com/airbrone" },
        { label: "LinkedIn", href: "https://linkedin.com/company/airbrone" },
        { label: "GitHub", href: "https://github.com/airbrone" },
        { label: "Instagram", href: "https://instagram.com/airbrone" },
      ],
    },
  ];

  return (
    <ThemeProvider
      defaultButtonVariant="shift-hover"
      defaultTextAnimation="reveal-blur"
      borderRadius="soft"
      contentWidth="compact"
      sizing="mediumLarge"
      background="grid"
      cardStyle="layered-gradient"
      primaryButtonStyle="double-inset"
      secondaryButtonStyle="radial-glow"
      headingFontWeight="semibold"
    >
      {/* Navbar */}
      <div id="nav" data-section="nav">
        <NavbarLayoutFloatingInline
          brandName="AIRBRONE AI"
          navItems={navItems}
          button={{
            text: "Get Started Free",
            href: "/auth/login",
          }}
        />
      </div>

      {/* Hero Section */}
      <div id="hero" data-section="hero" className="relative overflow-hidden">
        <HeroBillboardCarousel
          title="Meet AIRBRONE AI - Your Intelligent Assistant"
          description="Four powerful AI modes combining Gemini and ChatGPT intelligence. Study, code, manage business, and research with seamless AI integration across iOS, iPadOS, and Android."
          background={{ variant: "animated-grid" }}
          tag="AI-Powered Platform"
          tagIcon={Zap}
          tagAnimation="slide-up"
          buttons={[
            {
              text: "Start Free Trial",
              href: "/auth/register",
            },
            {
              text: "Watch Demo",
              href: "#demo",
            },
          ]}
          buttonAnimation="slide-up"
          mediaItems={[
            {
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/modern-ai-application-dashboard-with-cle-1773905442678-2f17b25a.png?_wi=1",
              imageAlt: "AIRBRONE AI Main Dashboard",
            },
            {
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/educational-ai-study-mode-interface-show-1773905442614-c68979aa.png?_wi=1",
              imageAlt: "Study Helper Mode Interface",
            },
            {
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/developer-code-editor-interface-showing--1773905444256-87f6b027.png?_wi=1",
              imageAlt: "Code Helper Developer Interface",
            },
            {
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/business-intelligence-dashboard-with-ana-1773905443382-e57d5934.png",
              imageAlt: "Business Intelligence Dashboard",
            },
            {
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/advanced-research-analysis-tool-interfac-1773905443161-0ed15881.png",
              imageAlt: "Deep Research Analysis Tool",
            },
            {
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/airbrone-ai-mobile-app-interface-showing-1773905443504-c82b0832.png",
              imageAlt: "Mobile Application Interface",
            },
          ]}
          ariaLabel="AIRBRONE AI Hero Section"
        />
      </div>

      {/* Features Section */}
      <div id="features" data-section="features" className="py-16 md:py-24">
        <FeatureBento
          title="Four Intelligent AI Modes"
          description="Each mode is powered by combined Gemini and ChatGPT intelligence for maximum accuracy and capabilities."
          tag="AI Capabilities"
          tagIcon={Brain}
          tagAnimation="slide-up"
          textboxLayout="default"
          useInvertedBackground={false}
          animationType="slide-up"
          features={[
            {
              title: "Study Helper Mode",
              description: "Personalized learning with AI tutoring, homework assistance, exam preparation, and adaptive learning paths.",
              bentoComponent: "chat",
              aiIcon: BookOpen,
              userIcon: User,
              placeholder: "Ask me anything about your studies...",
              exchanges: [
                {
                  userMessage: "How do I solve quadratic equations?",
                  aiResponse: "Quadratic equations can be solved using the quadratic formula: x = (-b ± √(b²-4ac)) / 2a. Let me break this down step by step for you...",
                },
                {
                  userMessage: "Can you explain photosynthesis?",
                  aiResponse: "Photosynthesis is the process plants use to convert light energy into chemical energy. It occurs in two main stages: the light-dependent reactions and the Calvin cycle...",
                },
              ],
            },
            {
              title: "Agent Code Helper Mode",
              description: "Professional code generation, debugging, optimization, and multi-language support for developers.",
              bentoComponent: "phone",
              statusIcon: Code2,
              alertIcon: AlertCircle,
              alertTitle: "Code Review",
              alertMessage: "Optimization suggestions ready",
              apps: [
                { name: "JavaScript", icon: Code },
                { name: "Python", icon: Code2 },
                { name: "React", icon: Code },
                { name: "Node.js", icon: Code2 },
                { name: "SQL", icon: Database },
                { name: "CSS", icon: Palette },
                { name: "TypeScript", icon: Code },
                { name: "Docker", icon: Container },
              ],
            },
            {
              title: "Business Helper Mode",
              description: "Business analytics, market insights, strategic planning, and enterprise intelligence.",
              bentoComponent: "icon-info-cards",
              items: [
                {
                  icon: TrendingUp,
                  label: "Market Analysis",
                  value: "Real-time insights",
                },
                {
                  icon: BarChart3,
                  label: "Analytics",
                  value: "Data visualization",
                },
                {
                  icon: PieChart,
                  label: "Reports",
                  value: "Comprehensive data",
                },
              ],
            },
            {
              title: "Deep Research Mode",
              description: "Advanced research capabilities, comprehensive analysis, and knowledge synthesis.",
              bentoComponent: "orbiting-icons",
              centerIcon: Search,
              items: [
                { icon: BookMarked, ring: 1 },
                { icon: Lightbulb, ring: 1 },
                { icon: Database, ring: 2 },
                { icon: Globe, ring: 2 },
                { icon: Zap, ring: 3 },
              ],
            },
          ]}
        />
      </div>

      {/* Products Section */}
      <div id="products" data-section="products" className="py-16 md:py-24">
        <ProductCardOne
          title="Premium Features"
          description="Experience the full power of AIRBRONE AI with our premium features designed for maximum productivity."
          tag="Premium"
          tagIcon={Crown}
          tagAnimation="slide-up"
          textboxLayout="default"
          useInvertedBackground={true}
          animationType="slide-up"
          gridVariant="three-columns-all-equal-width"
          products={[
            {
              id: "1",
              name: "Unlimited Queries",
              price: "Premium Feature",
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/unlimited-query-capabilities-visualizati-1773905444244-05921507.png?_wi=1",
              imageAlt: "Unlimited AI Queries",
            },
            {
              id: "2",
              name: "Priority Support",
              price: "24/7 Available",
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/24-7-customer-support-illustration-showi-1773905443468-7e63add5.png?_wi=1",
              imageAlt: "Priority Support Access",
            },
            {
              id: "3",
              name: "Advanced Analytics",
              price: "Real-time Data",
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/advanced-analytics-dashboard-showing-rea-1773905443061-987aff26.png?_wi=1",
              imageAlt: "Advanced Analytics Dashboard",
            },
          ]}
        />
      </div>

      {/* Pricing Section */}
      <div id="pricing" data-section="pricing" className="py-16 md:py-24">
        <PricingCardNine
          title="Simple, Transparent Pricing"
          description="Choose the perfect plan for your needs. Start free for 1 day, then select your subscription."
          tag="Pricing"
          tagIcon={Tag}
          tagAnimation="slide-up"
          textboxLayout="default"
          useInvertedBackground={false}
          animationType="slide-up"
          plans={[
            {
              id: "study",
              title: "Study Helper",
              price: "₹749",
              period: "per month",
              features: [
                "Unlimited homework help",
                "AI tutor availability",
                "Study materials",
                "Exam preparation",
                "Progress tracking",
              ],
              button: {
                text: "Subscribe Now",
                href: "/checkout?plan=study",
              },
            },
            {
              id: "code",
              title: "Agent Code Helper",
              price: "₹1,999",
              period: "per month",
              features: [
                "Code generation",
                "Debugging assistance",
                "Multi-language support",
                "Performance optimization",
                "Code review analytics",
                "Priority response time",
              ],
              button: {
                text: "Subscribe Now",
                href: "/checkout?plan=code",
              },
            },
            {
              id: "business",
              title: "Business Helper",
              price: "₹2,999",
              period: "per month",
              features: [
                "Business analytics",
                "Market insights",
                "Strategic planning",
                "Competitor analysis",
                "Enterprise reports",
                "Team collaboration",
                "API access",
              ],
              button: {
                text: "Subscribe Now",
                href: "/checkout?plan=business",
              },
            },
            {
              id: "research",
              title: "Deep Research",
              price: "₹3,359",
              period: "per month",
              features: [
                "Advanced research tools",
                "Comprehensive analysis",
                "Knowledge synthesis",
                "Data aggregation",
                "Custom reports",
                "White-label options",
                "Dedicated support",
              ],
              button: {
                text: "Subscribe Now",
                href: "/checkout?plan=research",
              },
            },
            {
              id: "combo",
              title: "Ultimate Combo",
              price: "₹8,999",
              period: "per month",
              features: [
                "All four AI modes included",
                "Unlimited queries",
                "Priority 24/7 support",
                "Advanced analytics",
                "Team management",
                "API access",
                "Custom integrations",
                "White-label option",
              ],
              button: {
                text: "Subscribe Now",
                href: "/checkout?plan=combo",
              },
            },
          ]}
        />
      </div>

      {/* About Section */}
      <div id="about" data-section="about" className="py-16 md:py-24">
        <MetricSplitMediaAbout
          title="About AIRBRONE AI"
          description="AIRBRONE AI combines the power of Google Gemini and OpenAI ChatGPT into one unified intelligent platform. Designed for students, developers, business professionals, and researchers, our app delivers seamless AI assistance across iOS, iPadOS, and Android with enterprise-grade security and performance."
          tag="About Us"
          tagIcon={Info}
          tagAnimation="slide-up"
          imageSrc="https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/professional-team-collaboration-image-sh-1773905443021-4cb782b6.png?_wi=1"
          imageAlt="AIRBRONE AI Team"
          mediaAnimation="slide-up"
          metricsAnimation="slide-up"
          useInvertedBackground={true}
          metrics={[
            { value: "10K+", title: "Active Users" },
            { value: "4", title: "AI Modes" },
            { value: "99.9%", title: "Uptime" },
            { value: "24/7", title: "Support" },
          ]}
        />
      </div>

      {/* Metrics Section */}
      <div id="metrics" data-section="metrics" className="py-16 md:py-24">
        <MetricCardThree
          title="Platform Performance"
          description="Real-time metrics showcasing AIRBRONE AI's reliability and capability."
          tag="Performance"
          tagIcon={Activity}
          tagAnimation="slide-up"
          textboxLayout="default"
          useInvertedBackground={false}
          animationType="depth-3d"
          metrics={[
            {
              id: "1",
              icon: Zap,
              title: "Response Time",
              value: "<100ms",
            },
            {
              id: "2",
              icon: Users,
              title: "Concurrent Users",
              value: "10,000+",
            },
            {
              id: "3",
              icon: Globe,
              title: "Global Coverage",
              value: "50+ Countries",
            },
            {
              id: "4",
              icon: Shield,
              title: "Security Score",
              value: "A+",
            },
          ]}
        />
      </div>

      {/* Testimonials Section */}
      <div id="testimonials" data-section="testimonials" className="py-16 md:py-24">
        <TestimonialCardTen
          title="What Users Love About AIRBRONE AI"
          description="Thousands of satisfied users across students, developers, and business professionals share their success stories."
          tag="Testimonials"
          tagAnimation="slide-up"
          textboxLayout="default"
          useInvertedBackground={true}
          testimonials={[
            {
              id: "1",
              title: "Game Changer for Studies",
              quote: "AIRBRONE AI's Study Helper mode completely transformed my learning approach. The explanations are so clear and personalized!",
              name: "Priya Sharma",
              role: "Medical Student",
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/professional-photo-of-a-young-indian-fem-1773905442253-419dd7b6.png",
            },
            {
              id: "2",
              title: "Developer's Best Friend",
              quote: "The Code Helper mode saved me weeks of debugging. Multi-language support is incredible. It's like having a senior developer on speed dial.",
              name: "Raj Kumar",
              role: "Software Engineer",
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/professional-headshot-of-a-young-indian--1773905442644-45d6b2bd.png",
            },
            {
              id: "3",
              title: "Business Intelligence Simplified",
              quote: "The Business Helper mode provides insights we used to spend hours generating manually. Now it's instantaneous and incredibly accurate.",
              name: "Ananya Verma",
              role: "Business Analyst",
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/professional-headshot-of-an-indian-femal-1773905442065-65eda6f1.png",
            },
            {
              id: "4",
              title: "Research Made Effortless",
              quote: "Deep Research mode synthesizes complex information better than I ever could manually. This tool is invaluable for my PhD work.",
              name: "Dr. Vikram Singh",
              role: "Research Scholar",
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/professional-headshot-of-dr-vikram-singh-1773905443008-6ba57ac2.png",
            },
            {
              id: "5",
              title: "Best Cross-Platform Experience",
              quote: "Using AIRBRONE AI seamlessly across my iPhone, iPad, and Android tablet. The synchronization is flawless!",
              name: "Neha Patel",
              role: "Entrepreneur",
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/professional-headshot-of-a-young-indian--1773905442392-8cb7cede.png",
            },
            {
              id: "6",
              title: "Exceptional Customer Support",
              quote: "The 24/7 support team is incredibly responsive. They genuinely care about helping users succeed with the platform.",
              name: "Arjun Desai",
              role: "Tech Startup Founder",
              imageSrc: "https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/professional-headshot-of-arjun-desai-you-1773905442336-c5e9cefb.png",
            },
          ]}
        />
      </div>

      {/* FAQ Section */}
      <div id="faq" data-section="faq" className="py-16 md:py-24">
        <FaqSplitMedia
          title="Frequently Asked Questions"
          description="Find answers to common questions about AIRBRONE AI features, pricing, and technical details."
          tag="FAQ"
          tagAnimation="slide-up"
          textboxLayout="default"
          useInvertedBackground={false}
          faqsAnimation="slide-up"
          mediaAnimation="slide-up"
          imageSrc="https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/customer-support-and-help-center-illustr-1773905442717-7971a9a0.png?_wi=1"
          imageAlt="FAQ Support"
          faqs={[
            {
              id: "1",
              title: "What makes AIRBRONE AI different?",
              content: "AIRBRONE AI uniquely combines Google Gemini and OpenAI ChatGPT intelligence into one seamless platform. Our four specialized AI modes are optimized for specific use cases - studying, coding, business, and research - with superior accuracy and contextual understanding.",
            },
            {
              id: "2",
              title: "Can I use the free trial across all platforms?",
              content: "Yes! Your free 1-day trial works seamlessly across iOS, iPadOS, and Android devices. Your progress syncs automatically, so you can switch between devices without losing any data or conversation history.",
            },
            {
              id: "3",
              title: "How secure is my data?",
              content: "We employ enterprise-grade encryption (AES-256) for all data in transit and at rest. User conversations are protected with end-to-end encryption, and we comply with GDPR and data protection regulations. Your data is never shared with third parties.",
            },
            {
              id: "4",
              title: "What payment methods do you accept?",
              content: "We accept all major payment methods including UPI (7655019291@fam), credit/debit cards, net banking, and digital wallets. All transactions are processed through secure payment gateways with 256-bit SSL encryption.",
            },
            {
              id: "5",
              title: "Can I switch between subscription plans?",
              content: "Absolutely! You can upgrade, downgrade, or switch between plans anytime. Changes take effect immediately, and we'll prorate any charges or credits based on your current billing cycle.",
            },
            {
              id: "6",
              title: "Is API access available?",
              content: "Yes! Business Helper, Deep Research, and Ultimate Combo plans include API access. Developers can integrate AIRBRONE AI's intelligence into their own applications with comprehensive documentation and SDKs.",
            },
          ]}
        />
      </div>

      {/* Contact Section */}
      <div id="contact" data-section="contact" className="py-16 md:py-24">
        <ContactSplit
          tag="Get In Touch"
          title="Contact AIRBRONE AI"
          description="Have questions? Our support team is here to help. Reach out via email, phone, or the contact form below."
          tagIcon={Mail}
          tagAnimation="slide-up"
          background={{ variant: "animated-grid" }}
          useInvertedBackground={true}
          mediaAnimation="slide-up"
          imageSrc="https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3B9dMftQ4AQBXAKtnCOA7fukWXU/contact-form-and-support-channel-illustr-1773905442054-5bf6e7a4.png?_wi=1"
          imageAlt="Contact Support"
          inputPlaceholder="Enter your email address"
          buttonText="Get Support"
          termsText="By contacting us, you agree to our Terms and Conditions and Privacy Policy."
        />
      </div>

      {/* Footer */}
      <div id="footer" data-section="footer">
        <FooterLogoEmphasis
          logoText="AIRBRONE AI"
          columns={footerColumns}
        />
      </div>
    </ThemeProvider>
  );
}