'use client' import Link from 'next/link' import { usePathname } from 'next/navigation' import { useStore } from '@/lib/store' import { Menu, X, TrendingUp, Gavel, CreditCard, LayoutDashboard, Coins, ArrowRight, Sparkles, Target, LogOut, User, } from 'lucide-react' import { useState, useEffect } from 'react' import Image from 'next/image' import clsx from 'clsx' export function Header() { const pathname = usePathname() const { isAuthenticated, user, logout, subscription } = useStore() const [menuOpen, setMenuOpen] = useState(false) useEffect(() => { setMenuOpen(false) }, [pathname]) const tierName = subscription?.tier_name || subscription?.tier || 'Scout' const publicNavItems = [ { href: '/discover', label: 'Discover', icon: TrendingUp }, { href: '/acquire', label: 'Acquire', icon: Gavel }, { href: '/intelligence', label: 'Intel', icon: TrendingUp }, { href: '/pricing', label: 'Pricing', icon: CreditCard }, ] const isActive = (href: string) => { if (href === '/') return pathname === '/' return pathname.startsWith(href) } const isCommandCenterPage = pathname.startsWith('/terminal') || pathname.startsWith('/admin') if (isAuthenticated && isCommandCenterPage) { return null } return ( <>
{/* Logo */}
Pounce
POUNCE {/* Desktop Nav */} {/* Desktop Auth */} {/* Mobile Menu Button */}
{/* Mobile Drawer */} {menuOpen && (
setMenuOpen(false)} />
{/* Header */}
Pounce

Pounce

Domain Intelligence

{/* Navigation */}
Explore
{publicNavItems.map((item) => ( setMenuOpen(false)} className={clsx( "flex items-center gap-3 px-4 py-3 transition-colors border-l-2", isActive(item.href) ? "border-accent text-white bg-white/[0.03]" : "border-transparent text-white/60 active:text-white active:bg-white/[0.03]" )} > {item.label} ))}
{/* Terminal section removed - "Open Terminal" button is in footer */}
{/* Footer */}
{isAuthenticated ? ( <>

{user?.name || user?.email?.split('@')[0] || 'User'}

{tierName}

setMenuOpen(false)} className="flex items-center justify-center gap-2 w-full py-3 bg-accent text-black text-xs font-bold uppercase tracking-wider active:scale-[0.98] transition-all mb-2" > Enter Terminal ) : ( <> setMenuOpen(false)} className="flex items-center justify-center gap-2 w-full py-3 bg-accent text-black text-xs font-bold uppercase tracking-wider active:scale-[0.98] transition-all mb-2" > Enter Terminal setMenuOpen(false)} className="flex items-center justify-center gap-2 w-full py-2 border border-white/10 text-white/50 text-[10px] font-mono uppercase tracking-wider active:bg-white/5 transition-all" > Sign In )}
)} ) }