"use client";

import NavbarLayoutFloatingOverlay from '@/components/navbar/NavbarLayoutFloatingOverlay/NavbarLayoutFloatingOverlay';
import HeroBillboardGallery from '@/components/sections/hero/HeroBillboardGallery';
import TextSplitAbout from '@/components/sections/about/TextSplitAbout';
import FeatureCardSixteen from '@/components/sections/feature/FeatureCardSixteen';
import MetricCardTwo from '@/components/sections/metrics/MetricCardTwo';
import TestimonialCardSix from '@/components/sections/testimonial/TestimonialCardSix';
import FaqBase from '@/components/sections/faq/FaqBase';
import FooterBase from '@/components/sections/footer/FooterBase';
import { ThemeProvider } from '@/providers/themeProvider/ThemeProvider';
import { CheckCircle, HelpCircle, Shield, Star, TrendingUp, Zap } from 'lucide-react';

export default function LandingPage() {
  return (
    <ThemeProvider
      defaultButtonVariant="hover-bubble"
      defaultTextAnimation="background-highlight"
      borderRadius="soft"
      contentWidth="mediumSmall"
      sizing="mediumLarge"
      background="none"
      cardStyle="layered-gradient"
      primaryButtonStyle="inset-glow"
      secondaryButtonStyle="layered"
      headingFontWeight="extrabold"
    >
      <div id="nav" data-section="nav">
        <NavbarLayoutFloatingOverlay
          brandName="Glyde"
          navItems={[
            { name: "Features", id: "features" },
            { name: "Security", id: "security" },
            { name: "Metrics", id: "metrics" },
            { name: "FAQ", id: "faq" },
            { name: "Contact", id: "contact" }
          ]}
          button={{
            text: "Launch App",            href: "https://app.glyde.exchange"
          }}
        />
      </div>

      <div id="hero" data-section="hero">
        <HeroBillboardGallery
          title="Trade Crypto with Confidence on Glyde"
          description="The most secure and efficient decentralized exchange platform. Swap tokens instantly with zero intermediaries, transparent pricing, and advanced security protocols protecting your assets."
          tag="Launch Your Trades"
          tagIcon={Zap}
          mediaItems={[
            {
              imageSrc: "https://img.b2bpic.net/free-photo/representation-user-experience-interface-design_23-2150165975.jpg",              imageAlt: "Glyde trading interface dashboard"
            },
            {
              imageSrc: "https://img.b2bpic.net/free-vector/blockchain-background-with-dots-lines_23-2147869864.jpg",              imageAlt: "Decentralized network visualization"
            },
            {
              imageSrc: "https://img.b2bpic.net/free-photo/gold-bitcoin-padlock_93675-129565.jpg",              imageAlt: "Secure cryptocurrency transaction"
            },
            {
              imageSrc: "https://img.b2bpic.net/free-photo/technological-devices-with-statistics-documents_1232-485.jpg",              imageAlt: "Advanced trading tools"
            },
            {
              imageSrc: "https://img.b2bpic.net/free-vector/dark-blue-technology-background_1035-7564.jpg",              imageAlt: "Blockchain ecosystem"
            }
          ]}
          buttons={[
            {
              text: "Start Trading Now",              href: "https://app.glyde.exchange"
            },
            {
              text: "Learn More",              href: "#features"
            }
          ]}
        />
      </div>

      <div id="about" data-section="about">
        <TextSplitAbout
          title="About Glyde"
          description={[
            "Glyde is a next-generation decentralized exchange built for speed, security, and simplicity. We've eliminated the friction of traditional crypto trading by creating a platform where users maintain complete control of their assets while enjoying seamless token swaps.",            "Our mission is to democratize access to decentralized finance. Whether you're a seasoned trader or just entering the crypto space, Glyde provides the tools, transparency, and security you need to execute trades with confidence. Every transaction is protected by advanced encryption and smart contract audits.",            "With Glyde, you're not just trading—you're joining a community committed to building the future of finance. We prioritize user trust above all else, which is why we maintain full transparency in our operations and regularly publish security audits."
          ]}
          buttons={[
            {
              text: "Read Our Whitepaper",              href: "https://docs.glyde.exchange/whitepaper"
            },
            {
              text: "Join Community",              href: "https://discord.gg/glyde"
            }
          ]}
          showBorder={true}
          useInvertedBackground="noInvert"
        />
      </div>

      <div id="features" data-section="features">
        <FeatureCardSixteen
          title="Why Choose Glyde Over Traditional Exchanges"
          description="Experience the difference between centralized and decentralized trading. Glyde eliminates intermediaries, reduces fees, and puts you in control."
          tag="Comparison"
          tagIcon={CheckCircle}
          animationType="slide-up"
          textboxLayout="default"
          useInvertedBackground="invertDefault"
          negativeCard={{
            items: [
              "High trading fees and hidden costs",              "Centralized control of your assets",              "Slow withdrawal processes",              "Limited token selection",              "Regulatory restrictions and compliance delays",              "Single point of failure risk"
            ]
          }}
          positiveCard={{
            items: [
              "Ultra-low fees with transparent pricing",              "Non-custodial wallet integration",              "Instant settlements on-chain",              "Access to thousands of token pairs",              "Community-driven governance",              "Resilient decentralized infrastructure"
            ]
          }}
        />
      </div>

      <div id="metrics" data-section="metrics">
        <MetricCardTwo
          title="Glyde Platform Performance"
          description="Real-time statistics demonstrating the strength and adoption of our decentralized exchange ecosystem."
          tag="Live Stats"
          tagIcon={TrendingUp}
          animationType="slide-up"
          gridVariant="uniform-all-items-equal"
          textboxLayout="default"
          useInvertedBackground="noInvert"
          metrics={[
            {
              id: "1",              value: "$2.8B+",              description: "Total Value Locked (TVL)"
            },
            {
              id: "2",              value: "150K+",              description: "Active Daily Traders"
            },
            {
              id: "3",              value: "$500M+",              description: "Daily Trading Volume"
            },
            {
              id: "4",              value: "99.99%",              description: "Platform Uptime"
            }
          ]}
        />
      </div>

      <div id="security" data-section="security">
        <FeatureCardSixteen
          title="Security First. Always."
          description="Your assets are protected by enterprise-grade security measures, regular audits, and industry-leading smart contract protection protocols."
          tag="Security"
          tagIcon={Shield}
          animationType="slide-up"
          textboxLayout="default"
          useInvertedBackground="invertDefault"
          negativeCard={{
            items: [
              "Unaudited smart contracts",              "Single signature authentication",              "No liquidity insurance",              "Exposure to flash loan attacks",              "No emergency pause mechanisms"
            ]
          }}
          positiveCard={{
            items: [
              "Triple-audited smart contracts",              "Multi-signature security architecture",              "Comprehensive insurance coverage",              "Advanced flashloan protection",              "Emergency shutdown protocols"
            ]
          }}
        />
      </div>

      <div id="testimonials" data-section="testimonials">
        <TestimonialCardSix
          title="Trusted by Thousands of Traders"
          description="Join thousands of satisfied users who've made the switch to Glyde for their decentralized trading needs."
          tag="User Reviews"
          tagIcon={Star}
          animationType="slide-up"
          textboxLayout="default"
          useInvertedBackground="noInvert"
          speed={40}
          topMarqueeDirection="left"
          testimonials={[
            {
              id: "1",              name: "Alex Chen",              handle: "@alextrader_eth",              testimonial: "Glyde's interface is incredibly intuitive. I've cut my trading time in half and reduced fees by 70%. This is the future of crypto trading.",              imageSrc: "https://img.b2bpic.net/free-photo/company-administrator-searching-new-solution-obtain-business-growth-working-hard_482257-136146.jpg",              imageAlt: "Alex Chen"
            },
            {
              id: "2",              name: "Sarah Williams",              handle: "@sarahwill_defi",              testimonial: "The security measures on Glyde give me complete peace of mind. Finally, a DEX where I trust my assets are truly safe.",              imageSrc: "https://img.b2bpic.net/free-photo/businessman-wearing-coat_1098-3778.jpg",              imageAlt: "Sarah Williams"
            },
            {
              id: "3",              name: "Marcus Johnson",              handle: "@mjohn_crypto",              testimonial: "Best liquidity I've seen on any decentralized exchange. Slippage is minimal and execution is lightning fast. Highly impressed.",              imageSrc: "https://img.b2bpic.net/free-photo/man-portrait-posing-loft-modern-space_158595-5366.jpg",              imageAlt: "Marcus Johnson"
            },
            {
              id: "4",              name: "Emma Rodriguez",              handle: "@emmadefi",              testimonial: "The transparency and community governance on Glyde are game-changers. I feel like my voice actually matters as a user.",              imageSrc: "https://img.b2bpic.net/free-photo/portrait-fashionable-well-dressed-man-with-beard-posing-outdoors_1328-3268.jpg",              imageAlt: "Emma Rodriguez"
            },
            {
              id: "5",              name: "David Park",              handle: "@davidpark_eth",              testimonial: "Customer support is exceptional. Every question I had was answered within minutes. This level of care is rare in crypto.",              imageSrc: "https://img.b2bpic.net/free-photo/man-solar-panels-plant-using-laptop-improve-solar-cells-efficiency_482257-119894.jpg",              imageAlt: "David Park"
            },
            {
              id: "6",              name: "Jessica Moore",              handle: "@jmoore_trading",              testimonial: "I've tried dozens of DEXs. Glyde is the only one I use now. The combination of features, security, and user experience is unmatched.",              imageSrc: "https://img.b2bpic.net/free-photo/accounting-manager-reviewing-budget-numbers-after-monthly-costs_482257-90786.jpg",              imageAlt: "Jessica Moore"
            }
          ]}
        />
      </div>

      <div id="faq" data-section="faq">
        <FaqBase
          title="Frequently Asked Questions"
          description="Get answers to common questions about using Glyde, our security practices, and how decentralized trading works."
          tag="Help Center"
          tagIcon={HelpCircle}
          textboxLayout="default"
          useInvertedBackground="invertDefault"
          animationType="smooth"
          faqs={[
            {
              id: "1",              title: "What is a decentralized exchange (DEX) and how does Glyde work?",              content: "A decentralized exchange allows users to trade cryptocurrency directly from their wallets without relying on a centralized intermediary. Glyde uses automated market maker (AMM) technology and smart contracts to facilitate trades. You maintain complete custody of your assets throughout the process, and all transactions are recorded on the blockchain."
            },
            {
              id: "2",              title: "Is my cryptocurrency safe on Glyde?",              content: "Yes. Glyde uses non-custodial technology, meaning you control your private keys and funds at all times. Our smart contracts have been audited by three independent security firms. We also implement multi-signature security, emergency pause protocols, and insurance coverage for additional protection."
            },
            {
              id: "3",              title: "What are the trading fees on Glyde?",              content: "Glyde charges a base trading fee of 0.25% per swap, which is significantly lower than centralized exchanges (typically 0.5-1%). There are no hidden fees or withdrawal charges. Liquidity providers earn fees from each trade conducted on their pools."
            },
            {
              id: "4",              title: "How do I get started trading on Glyde?",              content: "Getting started is simple: 1) Connect your crypto wallet (MetaMask, WalletConnect, or any ERC-20 compatible wallet), 2) Deposit the tokens you want to trade, 3) Select your trading pair and execute your swap. Your transaction is processed instantly on-chain."
            },
            {
              id: "5",              title: "What blockchain networks does Glyde support?",              content: "Glyde is available on Ethereum, Polygon, Arbitrum, and Optimism. We're continuously expanding to new networks based on community demand. Each network maintains the same security standards and low-fee structure."
            },
            {
              id: "6",              title: "Can I lose my funds on Glyde?",              content: "Like all cryptocurrency trading, there are inherent market risks. However, Glyde's smart contracts eliminate counterparty risk and exchange hack exposure. Your funds are always in your control. We recommend starting with small trades as you familiarize yourself with the platform."
            },
            {
              id: "7",              title: "How does Glyde governance work?",              content: "Glyde token holders can vote on platform improvements, fee structures, and future development directions. Our DAO governance model ensures that all major decisions are made by the community. Voting power is proportional to tokens held."
            },
            {
              id: "8",              title: "What's the difference between Glyde and other DEXs?",              content: "Glyde stands out through superior security (triple-audited contracts), lowest fees in the industry (0.25%), exceptional user experience, dedicated community support, and advanced trading features like limit orders and yield farming. Our governance model also gives users real influence over platform direction."
            }
          ]}
        />
      </div>

      <div id="footer" data-section="footer">
        <FooterBase
          logoText="Glyde"
          copyrightText="© 2025 Glyde Protocol. All rights reserved."
          columns={[
            {
              title: "Product",              items: [
                { label: "Launch App", href: "https://app.glyde.exchange" },
                { label: "Features", href: "#features" },
                { label: "Security", href: "#security" },
                { label: "Pricing", href: "#metrics" }
              ]
            },
            {
              title: "Resources",              items: [
                { label: "Documentation", href: "https://docs.glyde.exchange" },
                { label: "Whitepaper", href: "https://docs.glyde.exchange/whitepaper" },
                { label: "API Reference", href: "https://docs.glyde.exchange/api" },
                { label: "Blog", href: "https://blog.glyde.exchange" }
              ]
            },
            {
              title: "Community",              items: [
                { label: "Discord", href: "https://discord.gg/glyde" },
                { label: "Twitter", href: "https://twitter.com/glydeprotocol" },
                { label: "GitHub", href: "https://github.com/glyde-protocol" },
                { label: "Governance", href: "https://governance.glyde.exchange" }
              ]
            }
          ]}
        />
      </div>
    </ThemeProvider>
  );
}