"use client"

import { ThemeProvider } from "@/providers/themeProvider/ThemeProvider";
import NavbarLayoutFloatingInline from "@/components/navbar/NavbarLayoutFloatingInline";
import HeroLogo from "@/components/sections/hero/HeroLogo";
import TextAbout from "@/components/sections/about/TextAbout";
import FeatureCardTwentyOne from "@/components/sections/feature/FeatureCardTwentyOne";
import MetricCardThree from "@/components/sections/metrics/MetricCardThree";
import BlogCardOne from "@/components/sections/blog/BlogCardOne";
import FaqDouble from "@/components/sections/faq/FaqDouble";
import ContactText from "@/components/sections/contact/ContactText";
import FooterCard from "@/components/sections/footer/FooterCard";
import { Globe, Waves, Shield, Leaf, Heart, Share2, BookOpen } from "lucide-react";

export default function LandingPage() {
  return (
    <ThemeProvider
      defaultButtonVariant="bounce-effect"
      defaultTextAnimation="background-highlight"
      borderRadius="soft"
      contentWidth="mediumLarge"
      sizing="mediumLargeSizeLargeTitles"
      background="aurora"
      cardStyle="glass-elevated"
      primaryButtonStyle="inset-glow"
      secondaryButtonStyle="radial-glow"
      headingFontWeight="semibold"
    >
      <div id="nav" data-section="nav">
        <NavbarLayoutFloatingInline
          brandName="Turtle Quest"
          navItems={[
            { name: "About", id: "about" },
            { name: "Species", id: "features" },
            { name: "Facts", id: "blog" },
            { name: "FAQ", id: "faq" }
          ]}
          button={{
            text: "Learn More",            href: "contact"
          }}
        />
      </div>

      <div id="hero" data-section="hero">
        <HeroLogo
          logoText="TURTLE QUEST"
          description="Discover the fascinating world of sea turtles and their incredible journeys across the ocean. Learn about conservation efforts and help protect these endangered creatures."
          buttons={[
            { text: "Explore Species", href: "features" },
            { text: "Discover Facts", href: "blog" }
          ]}
          imageSrc="https://img.b2bpic.net/free-photo/beautiful-closeup-shot-large-turtle-swimming-underwater-ocean_181624-3718.jpg"
          imageAlt="Sea turtle swimming in the ocean"
          showDimOverlay={true}
          logoLineHeight={1.2}
        />
      </div>

      <div id="about" data-section="about">
        <TextAbout
          title="Sea turtles have survived for over 100 million years, evolving from land-dwelling reptiles to graceful ocean navigators. These ancient mariners face unprecedented challenges today, making education and conservation more critical than ever."
          useInvertedBackground="invertDefault"
          buttons={[
            { text: "Learn About Conservation", href: "contact" }
          ]}
        />
      </div>

      <div id="features" data-section="features">
        <FeatureCardTwentyOne
          title="Turtle Species Around the World"
          description="Explore the incredible diversity of sea turtle species, each uniquely adapted to their ocean habitats with distinctive characteristics and behaviors."
          tag="Biodiversity"
          imageSrc="https://img.b2bpic.net/free-photo/turtle_658691-680.jpg"
          imageAlt="Close-up of sea turtle"
          accordionItems={[
            {
              id: "1",              title: "Green Sea Turtle",              content: "Named for the greenish color of their fat, green sea turtles are one of the largest hard-shelled sea turtles. They migrate thousands of miles to nesting beaches and are primarily herbivorous as adults, feeding on seagrass."
            },
            {
              id: "2",              title: "Loggerhead Turtle",              content: "Loggerheads have the largest heads of any living turtle species. They are carnivorous and feed on mollusks, crustaceans, and jellyfish. Their powerful jaws help them crush hard shells."
            },
            {
              id: "3",              title: "Hawksbill Turtle",              content: "Named for their narrow, pointed beak, hawksbill turtles are crucial for maintaining coral reef health. They feed on sponges, sea cucumbers, and jellyfish, helping to keep reef ecosystems in balance."
            }
          ]}
          useInvertedBackground="noInvert"
          mediaPosition="left"
        />
      </div>

      <div id="metrics" data-section="metrics">
        <MetricCardThree
          title="Conservation Impact"
          description="Global efforts to protect sea turtles and their habitats are making a measurable difference. Here are key statistics about marine turtle conservation."
          tag="Impact"
          metrics={[
            {
              id: "1",              icon: Globe,
              title: "Species Protected",              value: "7"
            },
            {
              id: "2",              icon: Waves,
              title: "Ocean Miles",              value: "40k+"
            },
            {
              id: "3",              icon: Shield,
              title: "Protected Areas",              value: "500+"
            },
            {
              id: "4",              icon: Leaf,
              title: "Years Surviving",              value: "100M"
            }
          ]}
          animationType="slide-up"
          textboxLayout="default"
          useInvertedBackground="invertDefault"
        />
      </div>

      <div id="blog" data-section="blog">
        <BlogCardOne
          title="Fascinating Turtle Facts"
          description="Dive into amazing discoveries about sea turtles through our collection of educational articles and fascinating insights."
          tag="Learning"
          animationType="slide-up"
          textboxLayout="default"
          useInvertedBackground="noInvert"
          carouselMode="buttons"
          blogs={[
            {
              id: "1",              category: "Habitat",              title: "Ancient Navigators of the Sea",              excerpt: "Sea turtles possess an incredible ability to navigate across thousands of miles of open ocean using the Earth's magnetic field. Scientists are still unraveling the mysteries of their navigation systems.",              imageSrc: "https://img.b2bpic.net/free-photo/turtle_658691-680.jpg",              imageAlt: "Turtle habitat on beach",              authorName: "Dr. Maria Santos",              authorAvatar: "https://img.b2bpic.net/free-photo/woman-sitting-library-couch_273609-12733.jpg",              date: "15 Jan 2025"
            },
            {
              id: "2",              category: "Lifecycle",              title: "The Remarkable Turtle Life Cycle",              excerpt: "From tiny hatchlings racing to the ocean to mature adults returning to the same beaches where they were born, the turtle life cycle is one of nature's greatest journeys.",              imageSrc: "https://img.b2bpic.net/free-photo/turtle_658691-257.jpg",              imageAlt: "Turtle eggs in sand",              authorName: "Prof. James Wilson",              authorAvatar: "https://img.b2bpic.net/free-photo/boy-studying-university-library_23-2148844679.jpg",              date: "12 Jan 2025"
            },
            {
              id: "3",              category: "Diet",              title: "What Do Sea Turtles Really Eat?",              excerpt: "Different turtle species have evolved diverse diets adapted to their ocean environments. From herbivorous grazers to carnivorous hunters, sea turtles play crucial roles in marine food webs.",              imageSrc: "https://img.b2bpic.net/free-photo/crab-walking-water-sand_209690-267.jpg",              imageAlt: "Sea turtle feeding",              authorName: "Dr. Elena Rodriguez",              authorAvatar: "https://img.b2bpic.net/free-photo/laughing-teen-girl-with-book-library_23-2147860590.jpg",              date: "10 Jan 2025"
            }
          ]}
        />
      </div>

      <div id="faq" data-section="faq">
        <FaqDouble
          title="Frequently Asked Questions"
          description="Answers to common questions about sea turtles, their behavior, conservation, and how you can help protect them."
          tag="Education"
          textboxLayout="default"
          useInvertedBackground="invertDefault"
          animationType="smooth"
          faqs={[
            {
              id: "1",              title: "How long do sea turtles live?",              content: "Sea turtles can live 50-70 years or even longer in the wild. Their long lifespan makes them particularly vulnerable to overhunting and other human threats, as they must reach maturity before reproducing."
            },
            {
              id: "2",              title: "Why do sea turtles return to their birth beaches?",              content: "Female sea turtles use a combination of Earth's magnetic field and chemical cues to return to the exact beaches where they were born, sometimes traveling thousands of miles to do so. This behavior ensures they lay eggs in suitable, familiar habitats."
            },
            {
              id: "3",              title: "What are the main threats to sea turtles?",              content: "Sea turtles face numerous threats including plastic pollution (especially plastic bags mistaken for jellyfish), climate change affecting nesting beaches, fishing nets, habitat loss, and coastal development. Conservation efforts focus on addressing these human-caused threats."
            },
            {
              id: "4",              title: "How fast can sea turtles swim?",              content: "Most sea turtles swim at speeds of 0.5 to 5 mph during normal cruising. Some species can reach speeds of up to 20 mph in short bursts when escaping predators or migrating."
            },
            {
              id: "5",              title: "Can sea turtles breathe underwater?",              content: "No, sea turtles are reptiles and must surface to breathe air. However, they can hold their breath for extended periods. Some species can remain underwater for up to 7 hours while hibernating."
            },
            {
              id: "6",              title: "How can I help protect sea turtles?",              content: "You can help by reducing plastic use, supporting marine conservation organizations, respecting nesting beaches, reporting injured turtles, and spreading awareness about turtle conservation in your community."
            }
          ]}
        />
      </div>

      <div id="contact" data-section="contact">
        <ContactText
          text="Join the movement to protect sea turtles and their ocean habitats. Together, we can ensure these magnificent creatures thrive for generations to come."
          animationType="entrance-slide"
          useInvertedBackground="noInvert"
          buttons={[
            { text: "Get Involved", href: "#" },
            { text: "Learn More", href: "#" }
          ]}
        />
      </div>

      <div id="footer" data-section="footer">
        <FooterCard
          logoText="Turtle Quest"
          copyrightText="© 2025 Turtle Quest | A Science Education Initiative"
          socialLinks={[
            {
              icon: Heart,
              href: "#",              ariaLabel: "Support turtle conservation"
            },
            {
              icon: Share2,
              href: "#",              ariaLabel: "Share our mission"
            },
            {
              icon: BookOpen,
              href: "#",              ariaLabel: "Educational resources"
            }
          ]}
        />
      </div>
    </ThemeProvider>
  );
}