"use client" import { memo, useEffect, useState, useCallback } from 'react'; import { useRouter } from 'next/navigation'; import Cookies from 'js-cookie'; import { usePrivy } from '@privy-io/react-auth'; import { Providers } from '@/components/providers/privy-provider'; import { Mail, ArrowRight, Hexagon, LucideIcon } from 'lucide-react'; interface LoginButtonProps { icon: LucideIcon; text: string; onClick: () => void; } interface FeatureCardProps { text: string; } // Futuristic geometric background const BackgroundEffect = memo(function BackgroundEffect() { return (
{/* Base gradient */}
{/* Geometric patterns */}
{Array.from({ length: 5 }).map((_, i) => (
))}
{/* Modern gradient orbs */}
); }); // Enhanced loading animation const LoadingSpinner = memo(function LoadingSpinner() { return (
); }); // Enhanced button with modern hover effects const LoginButton = memo(function LoginButton({ icon: Icon, text, onClick }: LoginButtonProps) { return ( ); }); // Modern feature card const FeatureCard = memo(function FeatureCard({ text }: FeatureCardProps) { return (

{text}

); }); const LoginContent = memo(function LoginContent() { const router = useRouter(); const [isLoading, setIsLoading] = useState(true); const privy = usePrivy(); const handleLogin = useCallback(() => privy.login(), [privy]); // const handleWalletConnect = useCallback(() => privy.connectWallet(), [privy]); useEffect(() => { if (privy?.ready) { setIsLoading(false); if (privy.authenticated) { localStorage.setItem('useremail', privy.user?.email?.address ?? "Guest"); Cookies.set('privy-authenticated', 'true', { path: '/', expires: 1 }); router.push('/dashboard'); } } }, [privy.ready, privy.authenticated, router]); if (isLoading) return ; return (
{/* Card backdrop blur effect */}
{/* Content */}

ALMAZE

Secure Seamless Smart
{/* */}

By continuing, you agree to our{' '} Terms of Service

); }); const Home = memo(function Home() { return ( ); }); export default Home;