import { useLanguage } from "../contexts/LanguageContext";
import { Reveal } from "../components/Reveal";
import { Card, CardContent } from "@/components/ui/card";
import { Check, Sprout, Users } from "lucide-react";

export default function Baraem() {
  const { t } = useLanguage();

  return (
    <div className="container mx-auto px-4 py-10">
      {/* Intro green panel */}
      <Reveal>
        <section className="rounded-2xl bg-[#14573A] text-white p-8 md:p-12 mb-10">
          <h1 className="text-2xl md:text-3xl font-bold mb-5">{t.baraem.introTitle}</h1>
          <p className="leading-loose text-primary-foreground/90 max-w-4xl">
            {t.baraem.intro}
          </p>
        </section>
      </Reveal>

      {/* What Buds offers */}
      <Reveal>
        <h2 className="text-xl font-bold text-foreground mb-6">{t.baraem.featuresTitle}</h2>
      </Reveal>
      <div className="grid grid-cols-1 md:grid-cols-2 gap-6 mb-12">
        {t.baraem.features.map((f, i) => (
          <Reveal key={i} delay={(i % 2) * 0.08} className="h-full">
            <Card className="h-full">
              <CardContent className="p-6 flex items-start gap-4">
                <div className="w-11 h-11 rounded-xl bg-primary/10 text-primary flex items-center justify-center shrink-0">
                  <Sprout className="w-5 h-5" />
                </div>
                <div>
                  <h3 className="text-base font-bold text-foreground mb-1">{f.name}</h3>
                  <p className="text-sm text-muted-foreground leading-relaxed">{f.desc}</p>
                </div>
              </CardContent>
            </Card>
          </Reveal>
        ))}
      </div>

      {/* Goals */}
      <Reveal>
        <div className="rounded-2xl bg-muted/40 border border-border p-8 mb-12">
          <h3 className="text-lg font-bold text-primary mb-4">{t.baraem.goalsTitle}</h3>
          <ul className="grid grid-cols-1 md:grid-cols-2 gap-3">
            {t.baraem.goals.map((item, i) => (
              <li key={i} className="flex items-start gap-3">
                <Check className="w-5 h-5 text-primary shrink-0 mt-0.5" />
                <span className="text-foreground/90 leading-relaxed">{item}</span>
              </li>
            ))}
          </ul>
        </div>
      </Reveal>

      {/* Audience */}
      <Reveal>
        <h2 className="text-xl font-bold text-foreground mb-6">{t.baraem.audienceTitle}</h2>
      </Reveal>
      <div className="grid grid-cols-1 md:grid-cols-3 gap-6">
        {t.baraem.audience.map((a, i) => (
          <Reveal key={i} delay={(i % 3) * 0.08} className="h-full">
            <Card className="h-full">
              <CardContent className="p-6">
                <div className="w-11 h-11 rounded-xl bg-primary/10 text-primary flex items-center justify-center mb-4">
                  <Users className="w-5 h-5" />
                </div>
                <h3 className="text-base font-bold text-foreground mb-1">{a.name}</h3>
                <p className="text-sm text-muted-foreground leading-relaxed">{a.desc}</p>
              </CardContent>
            </Card>
          </Reveal>
        ))}
      </div>
    </div>
  );
}
