'use client'; import { motion } from 'framer-motion'; import { useTranslations } from 'next-intl'; import { Compass, Shield, Brain, MapPin } from 'lucide-react'; import { cn } from '@/lib/utils'; import { revealVariants, staggerContainerWide, viewportOnce, } from '@/lib/animations'; import type { LucideIcon } from 'lucide-react'; // Each item's icon scale-bounce on enter const iconBounceVariants = { hidden: { scale: 0.7, opacity: 0 }, visible: { scale: 1, opacity: 1, transition: { duration: 0.5, ease: [0.34, 1.56, 0.64, 1] as [number, number, number, number], // spring-like overshoot }, }, }; interface TrustItem { key: string; Icon: LucideIcon; } const ITEMS: TrustItem[] = [ { key: 'customBuilt', Icon: Compass }, { key: 'privateInfra', Icon: Shield }, { key: 'aiPowered', Icon: Brain }, { key: 'rivieraBased', Icon: MapPin }, ]; interface TrustCardProps { item: TrustItem; index: number; t: (key: string) => string; } function TrustCard({ item, index, t }: TrustCardProps) { const { Icon, key } = item; return ( {/* Top accent gradient bar — fades in on hover */} {/* Icon with scale-bounce on scroll reveal */} {/* Title */} {t(`${key}.title`)} {/* Description */} {t(`${key}.description`)} ); } export default function TrustBar() { const t = useTranslations('trustBar'); return ( {/* Gradient bridge — blends hero surface-high into this section */} {/* Stagger wrapper — triggers children revealVariants on scroll */} {ITEMS.map((item, index) => ( ))} ); }
{t(`${key}.description`)}