"use client" import { useEffect, useRef, useState } from "react" import { MessageCircle, Search, Cog, Rocket } from "lucide-react" const steps = [ { icon: MessageCircle, title: "Get in Touch", description: "Tell us about your business and what you need. We'll have a friendly chat to understand your goals.", color: "from-green-500/20 to-emerald-500/20" }, { icon: Search, title: "We Assess", description: "Our team reviews your current setup and identifies the best solutions for your specific needs.", color: "from-emerald-500/20 to-teal-500/20" }, { icon: Cog, title: "We Build", description: "We implement your solution, whether it's a new website, cloud setup, or fixing that stubborn printer.", color: "from-teal-500/20 to-cyan-500/20" }, { icon: Rocket, title: "Launch & Support", description: "Go live with confidence. We provide ongoing support to keep everything running smoothly.", color: "from-cyan-500/20 to-green-500/20" } ] export function Process() { const [activeStep, setActiveStep] = useState(0) const [isVisible, setIsVisible] = useState(false) const sectionRef = useRef(null) useEffect(() => { const observer = new IntersectionObserver( ([entry]) => { if (entry.isIntersecting) { setIsVisible(true) } }, { threshold: 0.2 } ) if (sectionRef.current) { observer.observe(sectionRef.current) } return () => observer.disconnect() }, []) return (
{/* Background */}
{/* Section Header */}
How It Works

Our Simple Process

Getting started with Cloudrite is easy. Here's how we work with you to transform your business technology.

{/* Process Steps - Desktop */}
{/* Step indicators */}
{steps.map((step, index) => (
setActiveStep(index)} >
{activeStep === index && (
)}
{step.title}
))}
{/* Connecting line */}
{/* Active step content */}
Step {activeStep + 1} of {steps.length}

{steps[activeStep].title}

{steps[activeStep].description}

{(() => { const StepIcon = steps[activeStep].icon return })()}
{/* Process Steps - Mobile */}
{steps.map((step, index) => { const StepIcon = step.icon return (
Step {index + 1}

{step.title}

{step.description}

) })}
) }