'use client' import { useState } from 'react'; import { motion, AnimatePresence } from 'framer-motion'; import Link from 'next/link'; import Logo from './Logo'; const Header = () => { const [isMobileMenuOpen, setIsMobileMenuOpen] = useState(false); const navItems = [ { label: 'Our Products', href: '/products' }, { label: 'Our Story', href: '/history' }, { label: 'Contact', href: '/contact' }, ]; return (
{/* Logo */} {/* Desktop Navigation */} {/* Mobile menu button */}
{/* Mobile Navigation — must UNMOUNT when closed. A panel parked off-screen at translate-x-full still extends the scrollable area, which is what let you scroll sideways and find the menu. */} {isMobileMenuOpen && (
)}
); }; export default Header;