2026-11-03 16:44:13 +05:30
|
|
|
'use client';
|
|
|
|
|
|
2026-11-04 11:25:57 +05:30
|
|
|
import React, { useRef, useState, useEffect, useCallback } from 'react';
|
2026-11-03 16:44:13 +05:30
|
|
|
import Link from 'next/link';
|
2026-11-04 11:25:57 +05:30
|
|
|
import { ArrowRight, Check, Smartphone, ChevronLeft, ChevronRight } from 'lucide-react';
|
2026-11-06 18:38:45 +05:30
|
|
|
import { KineticText } from '@/components/magicui/kinetic-text';
|
2026-11-04 15:36:30 +05:30
|
|
|
import { CardBeforeAfterSlider } from '@/components/ui/CardBeforeAfterSlider';
|
2026-11-03 16:44:13 +05:30
|
|
|
|
2026-11-03 18:06:20 +05:30
|
|
|
export interface ShowcaseItem {
|
2026-11-03 16:44:13 +05:30
|
|
|
id: string;
|
|
|
|
|
index: string;
|
2026-11-03 18:06:20 +05:30
|
|
|
tabLabel?: string;
|
2026-11-03 16:44:13 +05:30
|
|
|
category: string;
|
|
|
|
|
model: string;
|
|
|
|
|
latency: string;
|
|
|
|
|
title: string;
|
|
|
|
|
tagline: string;
|
|
|
|
|
description: string;
|
2026-11-03 18:06:20 +05:30
|
|
|
variant?: 'comparison' | 'banner';
|
|
|
|
|
beforeUrl?: string;
|
|
|
|
|
afterUrl?: string;
|
|
|
|
|
bannerImage?: string;
|
|
|
|
|
bannerBadge?: string;
|
2026-11-03 16:44:13 +05:30
|
|
|
toolSlug: string;
|
|
|
|
|
appSlug: string;
|
|
|
|
|
appName: string;
|
|
|
|
|
specs: string[];
|
|
|
|
|
}
|
|
|
|
|
|
2026-11-03 18:06:20 +05:30
|
|
|
interface CinematicHorizontalProps {
|
|
|
|
|
title?: string;
|
|
|
|
|
badge?: string;
|
|
|
|
|
subtitle?: string;
|
|
|
|
|
items?: ShowcaseItem[];
|
2026-11-04 15:36:30 +05:30
|
|
|
animationMode?: 'horizontal' | 'vertical';
|
2026-11-03 18:06:20 +05:30
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export function CinematicHorizontalScrollSection({
|
|
|
|
|
title = 'Interactive Model Showcase',
|
|
|
|
|
badge = 'FLAGSHIP TRANSFORMATION MODELS',
|
2026-11-04 11:25:57 +05:30
|
|
|
subtitle = 'Browse the flagship tools with native cinematic pan controls.',
|
|
|
|
|
items = [],
|
2026-11-04 15:36:30 +05:30
|
|
|
animationMode = 'horizontal',
|
2026-11-03 18:06:20 +05:30
|
|
|
}: CinematicHorizontalProps) {
|
2026-11-04 11:35:51 +05:30
|
|
|
const containerRef = useRef<HTMLElement>(null);
|
|
|
|
|
const trackRef = useRef<HTMLDivElement>(null);
|
2026-11-04 12:00:17 +05:30
|
|
|
|
2026-11-04 11:35:51 +05:30
|
|
|
const [activeIndex, setActiveIndex] = useState(0);
|
2026-11-04 11:25:57 +05:30
|
|
|
const [canScrollLeft, setCanScrollLeft] = useState(false);
|
|
|
|
|
const [canScrollRight, setCanScrollRight] = useState(true);
|
|
|
|
|
|
2026-11-04 12:00:17 +05:30
|
|
|
// Compute fluid horizontal translation directly from vertical scroll progress
|
2026-11-04 11:35:51 +05:30
|
|
|
const updateTranslation = useCallback(() => {
|
|
|
|
|
const container = containerRef.current;
|
|
|
|
|
const track = trackRef.current;
|
|
|
|
|
if (!container || !track) return;
|
2026-11-04 11:25:57 +05:30
|
|
|
|
2026-11-04 11:35:51 +05:30
|
|
|
const rect = container.getBoundingClientRect();
|
|
|
|
|
const totalScrollable = container.offsetHeight - window.innerHeight;
|
|
|
|
|
if (totalScrollable <= 0) return;
|
2026-11-04 11:25:57 +05:30
|
|
|
|
2026-11-04 12:00:17 +05:30
|
|
|
// Direct proportional progress through the sticky section [0.0, 1.0]
|
|
|
|
|
// 0.0: Card 0 centered, exactly as section pins
|
|
|
|
|
// 1.0: Final card centered, seamlessly unpins into vertical scroll
|
2026-11-04 11:35:51 +05:30
|
|
|
const progress = Math.max(0, Math.min(1, -rect.top / totalScrollable));
|
|
|
|
|
|
|
|
|
|
const cards = Array.from(track.querySelectorAll('article'));
|
|
|
|
|
if (cards.length <= 1) return;
|
|
|
|
|
|
|
|
|
|
const firstCenter = cards[0].offsetLeft + cards[0].offsetWidth / 2;
|
|
|
|
|
const lastCenter = cards[cards.length - 1].offsetLeft + cards[cards.length - 1].offsetWidth / 2;
|
|
|
|
|
const maxDistance = lastCenter - firstCenter;
|
|
|
|
|
|
2026-11-04 12:17:22 +05:30
|
|
|
const translateX = progress * maxDistance;
|
|
|
|
|
track.style.transform = `translate3d(-${translateX.toFixed(2)}px, 0, 0)`;
|
2026-11-04 11:35:51 +05:30
|
|
|
|
2026-11-04 12:00:17 +05:30
|
|
|
// Sync active card index and button states
|
2026-11-04 11:35:51 +05:30
|
|
|
const active = Math.min(
|
|
|
|
|
cards.length - 1,
|
|
|
|
|
Math.max(0, Math.round(progress * (cards.length - 1)))
|
|
|
|
|
);
|
|
|
|
|
setActiveIndex(active);
|
|
|
|
|
|
|
|
|
|
setCanScrollLeft(progress > 0.02);
|
|
|
|
|
setCanScrollRight(progress < 0.98);
|
2026-11-04 12:17:22 +05:30
|
|
|
}, []);
|
2026-11-04 11:25:57 +05:30
|
|
|
|
|
|
|
|
useEffect(() => {
|
2026-11-04 12:17:22 +05:30
|
|
|
const container = containerRef.current;
|
|
|
|
|
|
2026-11-04 11:25:57 +05:30
|
|
|
const handleScroll = () => {
|
2026-11-04 12:00:17 +05:30
|
|
|
updateTranslation();
|
2026-11-04 11:25:57 +05:30
|
|
|
};
|
|
|
|
|
|
2026-11-04 12:17:22 +05:30
|
|
|
// Support horizontal trackpad swipe (deltaX) on the showcase container
|
|
|
|
|
const handleWheel = (e: WheelEvent) => {
|
|
|
|
|
if (Math.abs(e.deltaX) > Math.abs(e.deltaY) && Math.abs(e.deltaX) > 6) {
|
|
|
|
|
e.preventDefault();
|
|
|
|
|
window.scrollBy({ top: e.deltaX * 1.2, behavior: 'auto' });
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
// Support touch horizontal swipe on mobile / tablet screens
|
|
|
|
|
let touchStartX = 0;
|
|
|
|
|
let touchStartY = 0;
|
|
|
|
|
let initialScrollY = 0;
|
|
|
|
|
|
|
|
|
|
const handleTouchStart = (e: TouchEvent) => {
|
|
|
|
|
if (!e.touches[0]) return;
|
|
|
|
|
touchStartX = e.touches[0].clientX;
|
|
|
|
|
touchStartY = e.touches[0].clientY;
|
|
|
|
|
initialScrollY = window.scrollY;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
const handleTouchMove = (e: TouchEvent) => {
|
|
|
|
|
if (!e.touches[0]) return;
|
|
|
|
|
const deltaX = touchStartX - e.touches[0].clientX;
|
|
|
|
|
const deltaY = touchStartY - e.touches[0].clientY;
|
|
|
|
|
|
|
|
|
|
if (Math.abs(deltaX) > Math.abs(deltaY) && Math.abs(deltaX) > 10) {
|
|
|
|
|
window.scrollTo({
|
|
|
|
|
top: initialScrollY + deltaX * 1.3,
|
|
|
|
|
behavior: 'auto',
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
|
2026-11-04 11:35:51 +05:30
|
|
|
updateTranslation();
|
|
|
|
|
window.addEventListener('scroll', handleScroll, { passive: true });
|
|
|
|
|
window.addEventListener('resize', handleScroll);
|
2026-11-04 11:25:57 +05:30
|
|
|
|
2026-11-04 12:17:22 +05:30
|
|
|
if (container) {
|
|
|
|
|
container.addEventListener('wheel', handleWheel, { passive: false });
|
|
|
|
|
container.addEventListener('touchstart', handleTouchStart, { passive: true });
|
|
|
|
|
container.addEventListener('touchmove', handleTouchMove, { passive: true });
|
|
|
|
|
}
|
|
|
|
|
|
2026-11-04 11:25:57 +05:30
|
|
|
return () => {
|
2026-11-04 11:35:51 +05:30
|
|
|
window.removeEventListener('scroll', handleScroll);
|
|
|
|
|
window.removeEventListener('resize', handleScroll);
|
2026-11-04 12:17:22 +05:30
|
|
|
if (container) {
|
|
|
|
|
container.removeEventListener('wheel', handleWheel);
|
|
|
|
|
container.removeEventListener('touchstart', handleTouchStart);
|
|
|
|
|
container.removeEventListener('touchmove', handleTouchMove);
|
|
|
|
|
}
|
2026-11-04 11:25:57 +05:30
|
|
|
};
|
2026-11-04 11:35:51 +05:30
|
|
|
}, [updateTranslation, items.length]);
|
2026-11-04 11:25:57 +05:30
|
|
|
|
2026-11-04 12:00:17 +05:30
|
|
|
// Slide smoothly between cards using side arrows
|
2026-11-04 11:25:57 +05:30
|
|
|
const scrollDirection = (direction: 'left' | 'right') => {
|
2026-11-04 11:35:51 +05:30
|
|
|
const container = containerRef.current;
|
|
|
|
|
if (!container) return;
|
|
|
|
|
const totalScrollable = container.offsetHeight - window.innerHeight;
|
|
|
|
|
if (totalScrollable <= 0) return;
|
2026-11-04 11:25:57 +05:30
|
|
|
|
2026-11-04 11:35:51 +05:30
|
|
|
const cardsCount = items.length;
|
|
|
|
|
if (cardsCount <= 1) return;
|
2026-11-04 11:25:57 +05:30
|
|
|
|
2026-11-04 11:35:51 +05:30
|
|
|
const rect = container.getBoundingClientRect();
|
|
|
|
|
const containerTopInDoc = window.scrollY + rect.top;
|
2026-11-04 12:00:17 +05:30
|
|
|
const progress = Math.max(0, Math.min(1, -rect.top / totalScrollable));
|
|
|
|
|
|
2026-11-04 11:35:51 +05:30
|
|
|
const currentCardIndex = Math.min(
|
|
|
|
|
cardsCount - 1,
|
2026-11-04 12:00:17 +05:30
|
|
|
Math.max(0, Math.round(progress * (cardsCount - 1)))
|
2026-11-04 11:35:51 +05:30
|
|
|
);
|
2026-11-04 11:25:57 +05:30
|
|
|
|
2026-11-04 11:35:51 +05:30
|
|
|
let targetIndex = currentCardIndex;
|
2026-11-04 11:25:57 +05:30
|
|
|
if (direction === 'right') {
|
2026-11-04 11:35:51 +05:30
|
|
|
targetIndex = Math.min(cardsCount - 1, currentCardIndex + 1);
|
|
|
|
|
} else if (direction === 'left') {
|
|
|
|
|
targetIndex = Math.max(0, currentCardIndex - 1);
|
2026-11-04 11:25:57 +05:30
|
|
|
}
|
|
|
|
|
|
2026-11-04 11:35:51 +05:30
|
|
|
const targetProgress = targetIndex / (cardsCount - 1);
|
|
|
|
|
const targetScrollY = Math.round(containerTopInDoc + targetProgress * totalScrollable);
|
|
|
|
|
|
|
|
|
|
window.scrollTo({
|
|
|
|
|
top: targetScrollY,
|
2026-11-04 11:25:57 +05:30
|
|
|
behavior: 'smooth',
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
if (!items.length) return null;
|
2026-11-03 17:31:00 +05:30
|
|
|
|
2026-11-04 15:36:30 +05:30
|
|
|
// Clean fluid vertical stack when horizontal scroll animation is disabled
|
|
|
|
|
if (animationMode === 'vertical') {
|
|
|
|
|
return (
|
|
|
|
|
<section id="flagship-models" className="py-16 sm:py-24 border-y border-slate-900/[0.08] bg-[#FAF8F5]">
|
|
|
|
|
<div className="mx-auto max-w-7xl px-4 sm:px-6 lg:px-8 mb-8 sm:mb-12">
|
|
|
|
|
<div className="max-w-2xl">
|
|
|
|
|
<p className="eyebrow">{badge}</p>
|
|
|
|
|
<h2 className="mt-1 text-2xl font-display font-bold tracking-tight text-slate-900 sm:text-3xl lg:text-4xl">
|
2026-11-06 18:38:45 +05:30
|
|
|
<KineticText>{title}</KineticText>
|
2026-11-04 15:36:30 +05:30
|
|
|
</h2>
|
|
|
|
|
<p className="mt-1 text-xs text-slate-600 sm:text-sm">{subtitle}</p>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div className="mx-auto max-w-5xl px-4 sm:px-6 lg:px-8 space-y-8">
|
|
|
|
|
{items.map((item) => (
|
|
|
|
|
<ShowcaseCard key={item.id} item={item} isVertical />
|
|
|
|
|
))}
|
|
|
|
|
</div>
|
|
|
|
|
</section>
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
|
2026-11-04 12:00:17 +05:30
|
|
|
// Fluid vertical scroll distance: 100vh base + 85vh per additional card
|
2026-11-04 11:35:51 +05:30
|
|
|
const containerHeightVh = 100 + (items.length - 1) * 85;
|
|
|
|
|
|
2026-11-03 16:44:13 +05:30
|
|
|
return (
|
2026-11-04 11:25:57 +05:30
|
|
|
<section
|
|
|
|
|
id="flagship-models"
|
2026-11-04 11:35:51 +05:30
|
|
|
ref={containerRef}
|
|
|
|
|
className="relative"
|
|
|
|
|
style={{ height: `${containerHeightVh}vh` }}
|
2026-11-03 16:44:13 +05:30
|
|
|
>
|
2026-11-04 11:35:51 +05:30
|
|
|
<div className="sticky top-0 h-screen flex flex-col justify-center overflow-hidden border-y border-slate-900/[0.08] bg-[#FAF8F5]">
|
|
|
|
|
{/* Section Header */}
|
|
|
|
|
<div className="mx-auto max-w-7xl w-full px-4 sm:px-6 lg:px-8 mb-4 sm:mb-6 shrink-0">
|
|
|
|
|
<div className="flex flex-col gap-2 sm:flex-row sm:items-end sm:justify-between">
|
|
|
|
|
<div className="max-w-2xl">
|
|
|
|
|
<p className="eyebrow">{badge}</p>
|
2026-11-06 18:38:45 +05:30
|
|
|
<h2 className="mt-1 text-2xl font-display font-bold tracking-tight text-slate-900 sm:text-3xl lg:text-4xl">
|
|
|
|
|
<KineticText>{title}</KineticText>
|
|
|
|
|
</h2>
|
2026-11-04 11:35:51 +05:30
|
|
|
<p className="mt-1 text-xs text-slate-600 sm:text-sm">{subtitle}</p>
|
|
|
|
|
</div>
|
|
|
|
|
<p className="hidden text-xs font-medium text-slate-500 sm:block">Scroll down to explore models</p>
|
2026-11-03 16:44:13 +05:30
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
2026-11-04 11:35:51 +05:30
|
|
|
{/* Carousel Viewport with Pinned Rail & Floating Side Arrows */}
|
|
|
|
|
<div className="relative group/showcase w-full overflow-hidden">
|
|
|
|
|
{/* Soft edge fades for polished boundary */}
|
|
|
|
|
<div
|
|
|
|
|
aria-hidden="true"
|
|
|
|
|
className={`pointer-events-none absolute left-0 top-0 bottom-0 w-12 sm:w-24 bg-gradient-to-r from-[#FAF8F5] to-transparent z-10 transition-opacity duration-300 ${
|
|
|
|
|
canScrollLeft ? 'opacity-100' : 'opacity-0'
|
|
|
|
|
}`}
|
|
|
|
|
/>
|
|
|
|
|
<div
|
|
|
|
|
aria-hidden="true"
|
|
|
|
|
className={`pointer-events-none absolute right-0 top-0 bottom-0 w-12 sm:w-24 bg-gradient-to-l from-[#FAF8F5] to-transparent z-10 transition-opacity duration-300 ${
|
|
|
|
|
canScrollRight ? 'opacity-100' : 'opacity-0'
|
|
|
|
|
}`}
|
|
|
|
|
/>
|
|
|
|
|
|
2026-11-04 12:00:17 +05:30
|
|
|
{/* Left Side Arrow Button */}
|
2026-11-04 11:35:51 +05:30
|
|
|
<button
|
|
|
|
|
type="button"
|
|
|
|
|
onClick={() => scrollDirection('left')}
|
|
|
|
|
disabled={!canScrollLeft}
|
|
|
|
|
aria-label="Previous flagship model"
|
|
|
|
|
className={`absolute left-3 sm:left-6 lg:left-8 top-1/2 -translate-y-1/2 z-30 grid h-12 w-12 sm:h-14 sm:w-14 place-items-center rounded-full border border-slate-900/15 bg-white/95 text-slate-800 shadow-cream-md backdrop-blur-md transition-all duration-300 hover:scale-105 hover:bg-white hover:text-blue-600 hover:border-blue-400 hover:shadow-cream-lg active:scale-95 disabled:opacity-35 disabled:cursor-not-allowed disabled:hover:scale-100 disabled:hover:bg-white/95 disabled:hover:text-slate-400 disabled:hover:border-slate-900/15 disabled:shadow-none focus:outline-none focus:ring-2 focus:ring-blue-600`}
|
|
|
|
|
>
|
|
|
|
|
<ChevronLeft className="h-6 w-6 stroke-[2.5]" />
|
|
|
|
|
</button>
|
|
|
|
|
|
|
|
|
|
{/* Horizontal Track */}
|
|
|
|
|
<div
|
|
|
|
|
ref={trackRef}
|
|
|
|
|
className="cinematic-rail flex gap-6 will-change-transform"
|
|
|
|
|
style={{
|
|
|
|
|
paddingLeft: 'calc((100vw - min(780px, 88vw)) / 2)',
|
|
|
|
|
paddingRight: 'calc((100vw - min(780px, 88vw)) / 2)',
|
2026-11-04 12:17:22 +05:30
|
|
|
transition: 'transform 0.08s cubic-bezier(0.25, 1, 0.5, 1)',
|
2026-11-04 11:35:51 +05:30
|
|
|
}}
|
|
|
|
|
>
|
|
|
|
|
{items.map((item) => (
|
|
|
|
|
<ShowcaseCard key={item.id} item={item} />
|
|
|
|
|
))}
|
|
|
|
|
</div>
|
|
|
|
|
|
2026-11-04 12:00:17 +05:30
|
|
|
{/* Right Side Arrow Button */}
|
2026-11-04 11:35:51 +05:30
|
|
|
<button
|
|
|
|
|
type="button"
|
|
|
|
|
onClick={() => scrollDirection('right')}
|
|
|
|
|
disabled={!canScrollRight}
|
|
|
|
|
aria-label="Next flagship model"
|
|
|
|
|
className={`absolute right-3 sm:right-6 lg:right-8 top-1/2 -translate-y-1/2 z-30 grid h-12 w-12 sm:h-14 sm:w-14 place-items-center rounded-full border border-slate-900/15 bg-white/95 text-slate-800 shadow-cream-md backdrop-blur-md transition-all duration-300 hover:scale-105 hover:bg-white hover:text-blue-600 hover:border-blue-400 hover:shadow-cream-lg active:scale-95 disabled:opacity-35 disabled:cursor-not-allowed disabled:hover:scale-100 disabled:hover:bg-white/95 disabled:hover:text-slate-400 disabled:hover:border-slate-900/15 disabled:shadow-none focus:outline-none focus:ring-2 focus:ring-blue-600`}
|
|
|
|
|
>
|
|
|
|
|
<ChevronRight className="h-6 w-6 stroke-[2.5]" />
|
|
|
|
|
</button>
|
|
|
|
|
</div>
|
2026-11-03 16:44:13 +05:30
|
|
|
</div>
|
|
|
|
|
</section>
|
|
|
|
|
);
|
|
|
|
|
}
|
2026-11-04 11:25:57 +05:30
|
|
|
|
2026-11-04 15:36:30 +05:30
|
|
|
function ShowcaseCard({ item, isVertical }: { item: ShowcaseItem; isVertical?: boolean }) {
|
2026-11-04 11:25:57 +05:30
|
|
|
const comparison = item.variant !== 'banner' && item.beforeUrl && item.afterUrl;
|
|
|
|
|
|
|
|
|
|
return (
|
2026-11-04 15:36:30 +05:30
|
|
|
<article
|
|
|
|
|
className={`${
|
|
|
|
|
isVertical
|
|
|
|
|
? 'w-full'
|
|
|
|
|
: 'w-[88vw] shrink-0 sm:w-[680px] lg:w-[780px]'
|
|
|
|
|
} overflow-hidden rounded-3xl border border-slate-900/[0.09] bg-white shadow-cream-md`}
|
|
|
|
|
>
|
2026-11-04 11:25:57 +05:30
|
|
|
<div className="grid lg:grid-cols-[1.1fr_.9fr]">
|
2026-11-04 15:36:30 +05:30
|
|
|
<div className="relative min-h-[280px] sm:min-h-[320px] lg:min-h-full h-full bg-slate-950 overflow-hidden">
|
2026-11-04 11:25:57 +05:30
|
|
|
{comparison ? (
|
2026-11-04 15:36:30 +05:30
|
|
|
<CardBeforeAfterSlider
|
2026-11-04 11:25:57 +05:30
|
|
|
beforeUrl={item.beforeUrl!}
|
|
|
|
|
afterUrl={item.afterUrl!}
|
2026-11-04 15:36:30 +05:30
|
|
|
beforeLabel="BEFORE"
|
|
|
|
|
afterLabel="AI RESULT"
|
|
|
|
|
aspectRatio="aspect-[4/3] sm:aspect-[16/10] lg:aspect-auto lg:h-full"
|
2026-11-04 11:25:57 +05:30
|
|
|
/>
|
|
|
|
|
) : (
|
2026-11-04 15:36:30 +05:30
|
|
|
<div className="relative h-full min-h-[280px] sm:min-h-[320px] overflow-hidden bg-slate-950">
|
2026-11-04 11:25:57 +05:30
|
|
|
{/* eslint-disable-next-line @next/next/no-img-element */}
|
|
|
|
|
<img
|
|
|
|
|
src={item.bannerImage || item.beforeUrl || ''}
|
|
|
|
|
alt={item.title}
|
2026-11-04 15:36:30 +05:30
|
|
|
loading="eager"
|
2026-11-04 11:25:57 +05:30
|
|
|
decoding="async"
|
|
|
|
|
className="h-full w-full object-cover"
|
|
|
|
|
/>
|
|
|
|
|
<div className="absolute inset-0 bg-gradient-to-t from-slate-950/70 via-transparent to-transparent" />
|
|
|
|
|
<span className="absolute left-4 top-4 rounded-full bg-white/92 px-3 py-1.5 text-[10px] font-semibold uppercase tracking-wide text-slate-800 shadow-sm">
|
|
|
|
|
{item.bannerBadge || item.model}
|
|
|
|
|
</span>
|
|
|
|
|
</div>
|
|
|
|
|
)}
|
|
|
|
|
</div>
|
|
|
|
|
|
2026-11-04 11:35:51 +05:30
|
|
|
<div className="flex flex-col p-5 sm:p-6 lg:p-7">
|
2026-11-04 11:25:57 +05:30
|
|
|
<div className="flex items-center justify-between gap-3">
|
|
|
|
|
<span className="text-xs font-bold tracking-[0.16em] text-blue-700">{item.index}</span>
|
|
|
|
|
<span className="rounded-full border border-emerald-200 bg-emerald-50 px-2.5 py-1 text-[10px] font-semibold text-emerald-800">
|
|
|
|
|
{item.latency}
|
|
|
|
|
</span>
|
|
|
|
|
</div>
|
2026-11-04 11:35:51 +05:30
|
|
|
<p className="mt-4 text-xs font-semibold uppercase tracking-[0.12em] text-slate-500">{item.category}</p>
|
|
|
|
|
<h3 className="mt-1.5 text-xl font-display font-bold leading-tight tracking-tight text-slate-900 sm:text-2xl">{item.title}</h3>
|
|
|
|
|
<p className="mt-2 text-xs leading-relaxed text-slate-600 sm:text-sm">{item.description}</p>
|
|
|
|
|
<ul className="mt-4 space-y-2 text-xs sm:text-sm text-slate-700">
|
2026-11-04 11:25:57 +05:30
|
|
|
{item.specs.slice(0, 3).map((spec) => (
|
|
|
|
|
<li key={spec} className="flex gap-2">
|
|
|
|
|
<Check className="mt-0.5 h-4 w-4 shrink-0 text-blue-700" />
|
|
|
|
|
{spec}
|
|
|
|
|
</li>
|
|
|
|
|
))}
|
|
|
|
|
</ul>
|
2026-11-04 11:35:51 +05:30
|
|
|
<div className="mt-5 flex flex-wrap gap-3">
|
|
|
|
|
<Link href={`/tools/${item.toolSlug}`} className="button-primary text-xs sm:text-sm py-2 px-4 sm:py-2.5 sm:px-5">
|
2026-11-04 11:25:57 +05:30
|
|
|
Try online <ArrowRight className="h-4 w-4" />
|
|
|
|
|
</Link>
|
2026-11-04 11:35:51 +05:30
|
|
|
<Link href={`/apps/${item.appSlug}`} className="button-secondary text-xs sm:text-sm py-2 px-4 sm:py-2.5 sm:px-5">
|
2026-11-04 11:25:57 +05:30
|
|
|
<Smartphone className="h-4 w-4" /> App
|
|
|
|
|
</Link>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</article>
|
|
|
|
|
);
|
|
|
|
|
}
|