2026-11-03 12:24:43 +05:30
|
|
|
import React from 'react';
|
2026-11-06 18:38:45 +05:30
|
|
|
import { KineticText } from '@/components/magicui/kinetic-text';
|
2026-11-03 12:24:43 +05:30
|
|
|
import { resolveLocalised } from '@/types';
|
|
|
|
|
|
|
|
|
|
interface StepsSectionProps {
|
|
|
|
|
title?: any;
|
|
|
|
|
subtitle?: any;
|
|
|
|
|
items?: Array<{
|
|
|
|
|
title: any;
|
|
|
|
|
desc: any;
|
|
|
|
|
}>;
|
|
|
|
|
locale?: string;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export function StepsSection({
|
|
|
|
|
title,
|
|
|
|
|
subtitle,
|
|
|
|
|
items = [],
|
|
|
|
|
locale = 'en',
|
|
|
|
|
}: StepsSectionProps) {
|
|
|
|
|
if (!items || items.length === 0) return null;
|
|
|
|
|
|
|
|
|
|
return (
|
2026-11-03 13:16:16 +05:30
|
|
|
<section className="py-20 sm:py-28 bg-[#F5F2EB] border-t border-slate-900/[0.08]">
|
2026-11-03 12:24:43 +05:30
|
|
|
<div className="max-w-6xl mx-auto px-4 sm:px-6 lg:px-8">
|
|
|
|
|
{(title || subtitle) && (
|
2026-11-03 13:16:16 +05:30
|
|
|
<div className="text-center max-w-2xl mx-auto mb-14 space-y-3">
|
2026-11-03 12:24:43 +05:30
|
|
|
{title && (
|
2026-11-03 13:16:16 +05:30
|
|
|
<h2 className="text-3xl sm:text-4xl lg:text-5xl font-display font-black text-slate-900 tracking-tight">
|
2026-11-06 18:38:45 +05:30
|
|
|
<KineticText>{resolveLocalised(title, locale)}</KineticText>
|
2026-11-03 12:24:43 +05:30
|
|
|
</h2>
|
|
|
|
|
)}
|
|
|
|
|
{subtitle && (
|
2026-11-03 13:16:16 +05:30
|
|
|
<p className="text-base sm:text-lg text-slate-600 font-normal">
|
2026-11-03 12:24:43 +05:30
|
|
|
{resolveLocalised(subtitle, locale)}
|
|
|
|
|
</p>
|
|
|
|
|
)}
|
|
|
|
|
</div>
|
|
|
|
|
)}
|
|
|
|
|
|
|
|
|
|
<div className="grid grid-cols-1 md:grid-cols-3 gap-8">
|
|
|
|
|
{items.map((step, idx) => (
|
|
|
|
|
<div
|
|
|
|
|
key={idx}
|
2026-11-03 13:16:16 +05:30
|
|
|
className="relative bg-white rounded-3xl p-8 border border-slate-900/[0.08] shadow-cream-sm hover:shadow-cream-md transition-all space-y-4"
|
2026-11-03 12:24:43 +05:30
|
|
|
>
|
2026-11-03 13:16:16 +05:30
|
|
|
<div className="w-10 h-10 rounded-xl bg-blue-600 text-white font-bold flex items-center justify-center text-base shadow-sm">
|
2026-11-03 12:24:43 +05:30
|
|
|
{idx + 1}
|
|
|
|
|
</div>
|
2026-11-03 13:16:16 +05:30
|
|
|
<h3 className="text-lg font-display font-bold text-slate-900">
|
2026-11-03 12:24:43 +05:30
|
|
|
{resolveLocalised(step.title, locale)}
|
|
|
|
|
</h3>
|
2026-11-03 13:16:16 +05:30
|
|
|
<p className="text-xs sm:text-sm text-slate-600 leading-relaxed font-normal">
|
2026-11-03 12:24:43 +05:30
|
|
|
{resolveLocalised(step.desc, locale)}
|
|
|
|
|
</p>
|
|
|
|
|
</div>
|
|
|
|
|
))}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</section>
|
|
|
|
|
);
|
|
|
|
|
}
|