import Link from 'next/link'
import { Button } from '@/components/ui/button'
import { Card, CardContent, CardDescription, CardHeader, CardTitle } from '@/components/ui/card'
import { PublicLayout } from '@/components/layout/public-layout'
import { Sparkles, Brain, Network } from 'lucide-react'

export default function AIMLPage() {
  const products = [
    {
      name: 'Firebird AI Engine',
      icon: Sparkles,
      description: 'AI that transforms like fire',
      features: [
        'Model inference',
        'Real-time AI',
        'Edge AI deployment',
        'GPU acceleration',
      ],
    },
    {
      name: 'Sankofa Memory Model',
      icon: Brain,
      description: 'AI models that remember and learn',
      features: [
        'Recursive learning',
        'Memory-augmented AI',
        'Context-aware models',
        'Continuous improvement',
      ],
    },
    {
      name: 'Ancestral Neural Fabric',
      icon: Network,
      description: 'Distributed AI with ancestral patterns',
      features: [
        'Distributed training',
        'Federated learning',
        'Knowledge graphs',
        'Multi-region deployment',
      ],
    },
  ]

  return (
    <PublicLayout>
      <div className="min-h-screen bg-studio-black">
        <section className="relative flex min-h-[50vh] flex-col items-center justify-center overflow-hidden px-4">
          <div className="absolute inset-0 bg-gradient-to-br from-phoenix-fire/20 via-transparent to-sankofa-gold/20" />
          
          <div className="relative z-10 max-w-4xl text-center">
            <h1 className="mb-6 text-5xl font-bold tracking-tight text-white md:text-7xl">
              AI & Machine Learning
            </h1>
            
            <p className="mb-8 text-xl text-gray-300 md:text-2xl">
              AI services powered by ancestral wisdom and modern technology
            </p>
          </div>
        </section>

        <section className="py-24 px-4">
          <div className="mx-auto max-w-7xl">
            <div className="grid gap-8 md:grid-cols-3">
              {products.map((product) => {
                const Icon = product.icon
                return (
                  <Card key={product.name} className="hover:border-phoenix-fire transition-colors">
                    <CardHeader>
                      <Icon className="mb-4 h-12 w-12 text-phoenix-fire" />
                      <CardTitle className="text-xl">{product.name}</CardTitle>
                      <CardDescription className="text-gray-400">
                        {product.description}
                      </CardDescription>
                    </CardHeader>
                    <CardContent>
                      <ul className="space-y-2 text-sm text-gray-300 mb-6">
                        {product.features.map((feature, idx) => (
                          <li key={idx} className="flex items-start gap-2">
                            <span className="text-phoenix-fire mt-1">•</span>
                            <span>{feature}</span>
                          </li>
                        ))}
                      </ul>
                      <Button variant="outline" className="w-full" asChild>
                        <Link href={`/products/${product.name.toLowerCase().replace(/\s+/g, '-')}`}>
                          Learn More
                        </Link>
                      </Button>
                    </CardContent>
                  </Card>
                )
              })}
            </div>
          </div>
        </section>

        <section className="py-24 px-4 bg-studio-dark">
          <div className="mx-auto max-w-4xl text-center">
            <h2 className="mb-6 text-4xl font-bold text-white">
              Ready to Get Started?
            </h2>
            <Button variant="phoenix" size="lg" asChild>
              <Link href="/portal">Get Started</Link>
            </Button>
          </div>
        </section>
      </div>
    </PublicLayout>
  )
}

