import type { Dictionary } from "@/i18n/get-dictionary";
import { features } from "@/content/catalog";
import { Section } from "@/components/shared/section";
import { WhyUsItem } from "./why-us-item";

/** Dark strip of four strengths under the About section. */
export function WhyUsSection({ t }: { t: Dictionary["home"]["features"] }) {
  return (
    <Section className="py-0 max-md:py-5 md:max-lg:py-10">
      <ul className="grid gap-8 rounded-3xl border border-white/6 bg-surface-night px-6 py-10 max-lg:gap-6 max-lg:px-[25px] max-lg:py-[21px] md:grid-cols-2 lg:grid-cols-4 lg:gap-6">
        {features.map(({ id, icon }) => (
          <WhyUsItem key={id} icon={icon} title={t[id].title} description={t[id].description} />
        ))}
      </ul>
    </Section>
  );
}
