import React, { useEffect, useRef, useState } from 'react';
import Chatbot from '../components/Chatbot';
import { useAuth } from '../context/AuthContext';
import { useTheme } from '../context/ThemeContext';
import { ArrowRight, CheckCircle2, Home, Star, ShieldCheck, Clock, Award, TrendingDown, Users, MapPin, Phone, Mail, Instagram, Twitter, Youtube, Sun, Moon, LogOut, LayoutDashboard, User, Menu, X, ChevronDown, Zap, Briefcase, Map, Tag } from 'lucide-react';
import { Link } from 'react-router-dom';
import { SpotlightCard } from '../components/SpotlightCard';
import { ComparisonSlider } from '../components/ComparisonSlider';
import Services from '../components/Services';
import IntelligenceMap from '../components/IntelligenceMap';
import gsap from 'gsap';
import { ScrollTrigger } from 'gsap/ScrollTrigger';
import Logo from '../assets/images/LynkedUp_Pro_F_logo_Y.png';
import HeroImg from '../assets/images/hero_aerial_scan.webp';
import ProcessImg1 from '../assets/images/process.webp';
import ProcessImg2 from '../assets/images/process-2.webp';
import ProcessImg3 from '../assets/images/process-3.webp';
gsap.registerPlugin(ScrollTrigger);
const Landing = () => {
const { user } = useAuth();
const { theme, toggleTheme } = useTheme();
const heroRef = useRef(null);
const textRef = useRef(null);
const sectionsRef = useRef([]);
const statRefs = useRef([]);
const [isMobileMenuOpen, setIsMobileMenuOpen] = useState(false);
const [isScrolled, setIsScrolled] = useState(false);
const [hoveredSplit, setHoveredSplit] = useState(null);
const cursorGlowRef = useRef(null);
// Scroll-aware nav β transparent at top, glass effect on scroll
useEffect(() => {
const handleScroll = () => setIsScrolled(window.scrollY > 50);
window.addEventListener('scroll', handleScroll, { passive: true });
return () => window.removeEventListener('scroll', handleScroll);
}, []);
// Body scroll lock when mobile menu is open
useEffect(() => {
document.body.style.overflow = isMobileMenuOpen ? 'hidden' : '';
return () => { document.body.style.overflow = ''; };
}, [isMobileMenuOpen]);
const scrollToSection = (id) => {
const el = document.getElementById(id);
if (el) {
el.scrollIntoView({ behavior: 'smooth' });
setIsMobileMenuOpen(false);
}
};
// Mouse-follow ambient light β tracks cursor across the page
useEffect(() => {
const handleMouseMove = (e) => {
if (cursorGlowRef.current) {
cursorGlowRef.current.style.setProperty('--glow-x', `${e.clientX}px`);
cursorGlowRef.current.style.setProperty('--glow-y', `${e.clientY}px`);
}
};
window.addEventListener('mousemove', handleMouseMove);
return () => window.removeEventListener('mousemove', handleMouseMove);
}, []);
useEffect(() => {
// Console Signature (Info level to persist in prod)
console.info(
"%c Built by Satyam Rastogi %c π Ready for liftoff ",
"background: #3b82f6; color: white; padding: 4px; border-radius: 4px 0 0 4px; font-weight: bold;",
"background: #10b981; color: white; padding: 4px; border-radius: 0 4px 4px 0;"
);
// Hero Animation
gsap.fromTo(textRef.current.children,
{ y: 50, opacity: 0 },
{ y: 0, opacity: 1, duration: 1, stagger: 0.2, ease: "power3.out" }
);
// Scroll Animations
sectionsRef.current.forEach((el) => {
gsap.fromTo(el,
{ y: 50, opacity: 0 },
{
y: 0, opacity: 1, duration: 0.8, ease: "power2.out",
scrollTrigger: {
trigger: el,
start: "top 80%",
}
}
);
});
// Animated Stat Counters β proxy object approach (avoids GSAP innerText parsing conflicts)
statRefs.current.forEach((el) => {
if (!el) return;
const target = parseFloat(el.dataset.target);
const suffix = el.dataset.suffix || '';
const counter = { value: 0 };
el.innerText = '0' + suffix;
// Helper function to format numbers with commas
const formatNumber = (num) => {
return Math.round(num).toLocaleString('en-US');
};
gsap.to(counter, {
value: target,
duration: 2.5,
ease: "power2.out",
scrollTrigger: {
trigger: el,
start: "top 85%",
toggleActions: "play none none none",
},
onUpdate: () => {
el.innerText = formatNumber(counter.value) + suffix;
},
snap: { value: 1 }
});
});
}, []);
const addToRefs = (el) => {
if (el && !sectionsRef.current.includes(el)) {
sectionsRef.current.push(el);
}
};
// Helper to determine dashboard path based on role
const getDashboardPath = (role) => {
switch (role) {
case 'OWNER': return '/owner/snapshot';
case 'ADMIN': return '/admin/dashboard';
case 'CONTRACTOR': return '/contractor/dashboard';
case 'SUBCONTRACTOR': return '/subcontractor/dashboard';
case 'VENDOR': return '/vendor/dashboard';
case 'FIELD_AGENT': return '/emp/fa/dashboard';
case 'CUSTOMER': return '/portal/profile';
default: return '/login';
}
};
return (
{/* CURSOR AMBIENT LIGHT β subtle glow that follows mouse, desktop only */}
{/* ββ Navigation ββ */}
{/* Logo */}
window.scrollTo({ top: 0, behavior: 'smooth' })} className="flex items-center space-x-2 shrink-0">
{/* Desktop Nav Links */}
{[
{ label: 'How It Works', id: 'how-it-works' },
{ label: 'Services', id: 'services' },
{ label: 'Intelligence', id: 'intelligence' },
].map((item) => (
scrollToSection(item.id)}
className="px-3 py-2 text-sm font-medium text-zinc-500 dark:text-zinc-400 hover:text-zinc-900 dark:hover:text-white transition-colors rounded-lg hover:bg-zinc-100/50 dark:hover:bg-white/5"
>
{item.label}
))}
Pricing
{/* Desktop Right Actions */}
{theme === 'dark' ? : }
{!user ? (
<>
Sign In
Get Started
>
) : (
{user.role === 'CUSTOMER' ? 'My Profile' : 'Dashboard'}
)}
{/* Mobile Menu Toggle */}
setIsMobileMenuOpen(!isMobileMenuOpen)}
className="p-2 rounded-lg hover:bg-zinc-100 dark:hover:bg-zinc-800 transition-colors text-zinc-600 dark:text-zinc-400"
aria-label="Toggle menu"
aria-expanded={isMobileMenuOpen}
>
{isMobileMenuOpen ? : }
{/* ββ Mobile Backdrop ββ */}
{isMobileMenuOpen && (
setIsMobileMenuOpen(false)}
aria-hidden="true"
/>
)}
{/* ββ Mobile Sidebar β slides from left, mirrors Layout.jsx pattern ββ */}
{/* Header */}
setIsMobileMenuOpen(false)}
className="p-2 rounded-lg hover:bg-zinc-100 dark:hover:bg-zinc-800 text-zinc-500 dark:text-zinc-400 transition-colors"
aria-label="Close menu"
>
{/* Nav Links */}
{[
{ label: 'How It Works', id: 'how-it-works', icon: Zap },
{ label: 'Services', id: 'services', icon: Briefcase },
{ label: 'Intelligence', id: 'intelligence', icon: Map },
].map((item) => (
scrollToSection(item.id)}
className="w-full flex items-center gap-3 px-4 py-3 rounded-xl text-sm font-semibold text-zinc-700 dark:text-zinc-300 hover:bg-zinc-100 dark:hover:bg-white/5 hover:text-zinc-900 dark:hover:text-white transition-colors"
>
{item.label}
))}
setIsMobileMenuOpen(false)}
className="w-full flex items-center gap-3 px-4 py-3 rounded-xl text-sm font-semibold text-zinc-700 dark:text-zinc-300 hover:bg-zinc-100 dark:hover:bg-white/5 hover:text-zinc-900 dark:hover:text-white transition-colors"
>
Pricing
{/* Sign Up / Login nav item β visible only when logged out */}
{!user && (
<>
setIsMobileMenuOpen(false)}
className="w-full flex items-center gap-3 px-4 py-3 rounded-xl text-sm font-semibold text-blue-600 dark:text-blue-400 hover:bg-blue-50 dark:hover:bg-blue-500/10 transition-colors"
>
Sign Up / Login
>
)}
{/* Footer */}
{/* Theme Toggle */}
Dark Mode
{theme === 'dark' ? : }
{/* CTAs */}
{!user ? (
<>
setIsMobileMenuOpen(false)}
className="block w-full text-center py-3 rounded-xl text-sm font-bold bg-blue-500 text-white hover:bg-blue-600 transition-colors shadow-sm shadow-blue-500/25"
>
Get Started
setIsMobileMenuOpen(false)}
className="block w-full text-center py-3 rounded-xl text-sm font-bold border border-zinc-200 dark:border-white/10 text-zinc-700 dark:text-zinc-300 hover:bg-zinc-50 dark:hover:bg-white/5 transition-colors"
>
Sign In
>
) : (
<>
setIsMobileMenuOpen(false)}
className="block w-full text-center py-3 rounded-xl text-sm font-bold bg-blue-500 text-white hover:bg-blue-600 transition-colors shadow-sm shadow-blue-500/25"
>
{user.role === 'CUSTOMER' ? 'My Profile' : 'Dashboard'}
setIsMobileMenuOpen(false)}
className="block w-full text-center py-3 rounded-xl text-sm font-bold border border-red-200 dark:border-red-500/20 text-red-600 dark:text-red-400 hover:bg-red-50 dark:hover:bg-red-900/10 transition-colors"
>
Sign Out
>
)}
{/* ============================================ */}
{/* HERO SECTION β "The Overhead View" */}
{/* Aerospace Precision & Hometown Trust */}
{/* ============================================ */}
{/* Layer 0: Background image */}
{/* Layer 1: Subtle ambient glow behind content */}
{/* Layer 3: Content */}
{/* Patriotic badge β identity + mission statement */}
πΊπΈ
Crafted to Level the Field for Those Who Build{' '}
America
{/* Headline β Inter font-black: BOLD, commanding, statement piece */}
ROOFING
REVOLUTIONIZED
{/* Subtitle β the value proposition with credibility */}
Automated drone inspections. Instant AI estimates.
Restoring your home's integrity with{' '}
20+ years of precision.
{/* Dual CTAs */}
{/* B2C: Homeowners */}
Schedule Demo
{/* B2B: Contractors */}
See The Process
{/* Discount banner β Veterans, Seniors, Active Duty */}
Active Duty, Veterans & Seniors
Get an exclusive 15% Discount on all services.
{/* Layer 4: HUD Annotations β desktop only */}
▸
5,847 PROPERTIES TRACKED
DFW METRO · ZONE 2
▸
HAIL WATCH ACTIVE
ETA 35 MIN · WIND 24 MPH
{/* Scroll indicator */}
Scroll
{/* ββ TRUST BAR β Animated stat counters ββ */}
{[
{ value: 5000, suffix: '+', label: 'Properties Scanned' },
{ value: 200, suffix: '+', label: 'Contractors Onboarded' },
{ value: 98, suffix: '%', label: 'Estimate Accuracy' },
{ value: 15, suffix: ' min', label: 'Avg Report Time' },
].map((stat, i) => (
statRefs.current[i + 3] = el}
data-target={stat.value}
data-suffix={stat.suffix}
className="text-3xl md:text-4xl font-mono font-bold text-zinc-900 dark:text-white tracking-tight"
>
0{stat.suffix}
{stat.label}
))}
{/* ββ Shingle Divider ββ */}
{/* PROCESS SECTION (From Sky to Safety) */}
The Workflow
From Sky to Safety in 3 Steps.
{/* Step 1 */}
LIDAR_MAPPING_ACTIVE
01
The Scan.
Drones use LiDAR imagery and high-fidelity photogrammetry to map out your roof in sub-millimeter detail. We capture every angle, creating a perfect digital twin of your property without anyone ever stepping foot on a ladder.
{'$'}{'@'}{'t'}{'Ρ'}{'Π°'}{'m'} {'R'}{'Π°'}{'Ρ'}{'t'}{'0'}{'g'}{'1'}
100% Contactless Inspection
15-Minute Flight Time
{/* Step 2 */}
02
The Diagnosis.
This data is sent to our AI models , which instantly diagnose issues invisible to the naked eye. The algorithm highlights storm damage, wear patterns, and insulation failures, scoring them by urgency.
"Better, faster, and more accurate decisionsβeliminating human error."
Structure Integrity 76%
Moisture Level CRITICAL
igotsar.matyas | LynkedUpPro - Turns out roofing CRMs don't build themselves. Who knew?
{/* Step 3 */}
03
The Resolution.
{[
"Generate property assessment reports & repair estimates in minutes.",
"Document visible damage using AI-verified, objective evidence.",
"Share reports with property owners or insurance instantly.",
"Base all findings on measurable inspection data, not opinions.",
"Equip field reps with verified evidence to operate with confidence.",
"Provide a single, factual record all parties can rely on."
].map((item, i) => (
))}
Cost Efficient
Data-Backed
{/* COMPARISON SLIDER SECTION */}
{/* NEW SERVICES SECTION */}
{/* NEW INTELLIGENCE MAP SECTION */}
{/* ββ Shingle Divider ββ */}
{/* FACT CHECK & STATS β Blueprint grid + Measurement tape aesthetic */}
⚠ Critical Data
Why Risk The Wait?
Delaying roof repairs leads to exponential damage. Here are the facts.
{/* Stat Card 1 β Insurance Denials */}
statRefs.current[0] = el}
data-target="40"
data-suffix="%"
className="text-5xl font-mono font-bold text-red-500 mb-1 tracking-tight"
>
0%
Insurance Denials
Of claims are denied due to "lack of maintenance" if proof of regular inspection isn't provided.
✕ High Risk
{/* Stat Card 2 β Life Reduced */}
statRefs.current[1] = el}
data-target="5"
data-suffix=" yrs"
className="text-5xl font-mono font-bold text-yellow-500 mb-1 tracking-tight"
>
0 yrs
Life Reduced
A minor leak left for 6 months can reduce your roof's lifespan by up to 5 years.
⚠ Caution
{/* Stat Card 3 β Estimate Time */}
statRefs.current[2] = el}
data-target="15"
data-suffix=" min"
className="text-5xl font-mono font-bold text-emerald-500 mb-1 tracking-tight"
>
0 min
Our Estimate Time
While others take days, we give you a quote before our drone even lands.
✓ Verified
{/* ββ Shingle Divider ββ */}
{/* ββ THE SPLIT β B2C / B2B Routing ββ */}
◆ Dual Platform
Which side of the roof are you on?
Whether you need your roof fixed or you fix roofs for a living β we built LynkedUp for both.
{/* Roof Ridge β interactive peak shape, highlights on card hover */}
{/* Left slope β Homeowner side */}
{/* Right slope β Contractor side */}
{/* Peak glow β pulses on either hover */}
{/* Homeowner Card */}
setHoveredSplit('homeowner')}
onMouseLeave={() => setHoveredSplit(null)}
onTouchStart={() => setHoveredSplit('homeowner')}
>
I'm a Homeowner
Get a transparent, AI-powered roof assessment. Know exactly what's wrong, what it costs, and who to trust β before anyone knocks on your door.
{['Free drone inspection', 'AI damage assessment', 'Verified contractor matching', 'Insurance claim support'].map((item) => (
{item}
))}
Protect My Home
✓ Residential Verified
{/* Contractor Card */}
setHoveredSplit('contractor')}
onMouseLeave={() => setHoveredSplit(null)}
onTouchStart={() => setHoveredSplit('contractor')}
>
I'm a Contractor
Stop chasing leads. Our intelligence engine surfaces storm-damaged properties, pre-qualifies homeowners, and routes jobs directly to your crew.
{['AI-powered lead generation', 'Storm path intelligence', 'Automated estimates', 'Crew dispatch & scheduling'].map((item) => (
{item}
))}
Grow My Business
★ Contractor Certified
{/* ββ Shingle Divider ββ */}
{/* INDUSTRIES THAT LOVE US */}
Industries that Love Us
{/* Contractors Card */}
Contractors live and die by speed, quality workmanship, and trust; thatβs exactly what LynkedUp delivers.
Faster insurance approvals through time-stamped, geo-verified capture.
Fewer chargebacks & denials with irrefutable evidence.
Shorter sales cycles β homeowners trust what they can see.
More profitable jobs with accurate scopes.
Result
One system replaces 5β7 tools.
{/* Asset Managers Card */}
Asset managers care about risk reduction, documentation, and long-term asset value, not sales hype.
Verified condition records for every property.
Audit-ready documentation for lenders & investors.
Reduced fraud exposure β no undocumented claims.
Remote visibility across portfolios.
Net Effect
A digital twin that reduces capital risk.
{/* Homeowners Card */}
Homeowners want protection and clarity, not pressure. We give them exactly that.
Clear, visual proof instead of confusing explanations.
Transparency β see whatβs submitted to insurance.
Faster claim resolution with fewer surprises.
Permanent property record for resale value.
Feeling
Informed, protected, and confident.
{/* ββ Shingle Divider ββ */}
{/* ββββββββββββββββββββββββββββββββββββββββββββββββββ */}
{/* CRANE CTA β "One crane, one card, one moment" */}
{/* Construction signature element before footer */}
{/* ββββββββββββββββββββββββββββββββββββββββββββββββββ */}
{/* Blueprint grid background */}
{/* Tower Crane SVG β full-scale blueprint line art */}
{/* ===== TOWER / LATTICE MAST ===== */}
{/* Main vertical rails β extended to full viewBox height */}
{/* Horizontal rungs */}
{/* X-bracing */}
{/* ===== SLEWING PLATFORM + OPERATOR CAB ===== */}
{/* Cab window */}
{/* ===== A-FRAME / APEX ===== */}
{/* Cross-tie */}
{/* ===== SUPPORT CABLES (apex to jib tips) ===== */}
{/* ===== COUNTER-JIB (left of tower) ===== */}
{/* End closer */}
{/* Diagonals */}
{/* Counterweight blocks */}
{/* ===== MAIN JIB / BOOM (right of tower) ===== */}
{/* Top chord */}
{/* Bottom chord */}
{/* End vertical */}
{/* Diagonal bracing */}
{/* Vertical stiffeners */}
{/* ===== TROLLEY ===== */}
{/* Wheels */}
{/* ===== HOIST CABLE ===== */}
{/* ===== HOOK BLOCK ===== */}
{/* Hook */}
{/* CTA Card β "suspended" from crane, swings like a pendulum */}
{/* Attachment point β visual connector to cable above */}
✓ Project Ready
Ready to Build?
Whether you protect one home or manage a thousand roofs, the future of roofing starts here.
Schedule Demo
Start Free Trial
{/* ββ Shingle Divider ββ */}
{/* FOOTER */}
{/* Background Pattern */}
{/* Brand */}
Revolutionizing property management and roofing inspections with military-grade precision and AI-driven insights. Built for the modern homeowner.
{/* Platform */}
Platform
For Homeowners
For Contractors
Intelligence Map
How It Works
Pricing
{/* Contact */}
Contact
16990 Dallas Pkwy Suite 206 Dallas, TX 75248
866-259-6533
Info@LynkedUpPro.com
{/* Legal */}
Legal
Privacy Policy
Terms of Service
Drone Flight Safety
Sitemap
© 2026 LynkedUp Pro. All Rights Reserved.
Powered by LynkedUp Technologies
β¨
Satyam Rastogi made this. Blame him for the bugs, praise him for the features.
5@7y@m R@570g1 | LynkedUpPro - You're reading the fine print? You'd be great at roofing contracts.
);
};
export default Landing;