This commit is contained in:
Vula Builder
2026-09-15 18:02:57 +00:00
parent b40073c6cb
commit cc14d513ee
+58
View File
@@ -0,0 +1,58 @@
'use client';
import { useState } from 'react';
import { Menu, X } from 'lucide-react';
import Link from 'next/link';
import Image from 'next/image';
export default function Navigation() {
const [isOpen, setIsOpen] = useState(false);
return (
<header className="sticky top-0 z-50 w-full border-b bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60">
<style>{`html { scroll-behavior: smooth; }`}</style>
<div className="container mx-auto px-4 sm:px-6 lg:px-8">
<div className="flex h-16 items-center justify-between">
{/* Logo */}
<Link href="/" className="flex items-center gap-2 hover:opacity-90 transition-opacity">
<Image src="https://uploads.vulai.co.za/vula-uploads/e691b2f9-937a-45fd-a18f-c5b9cf1193f2/library/b5f9e225d0e8b533af6f7549ff80af8be30bdc813fedd7985bc93c23e6799eda.png" alt="The Bay Chiro logo" width={0} height={0} sizes="264px" className="h-11 w-auto object-contain flex-shrink-0" priority />
<span className="font-sans text-xl font-bold text-foreground">The Bay{" "}<span className="text-primary">Chiro</span></span>
</Link>
{/* Desktop nav */}
<nav className="hidden md:flex items-center gap-6">
<Link href="/" className="text-foreground/80 hover:text-primary transition-colors text-sm font-medium">Home</Link>
<a href="#about-the-practice" className="text-foreground/80 hover:text-primary transition-colors text-sm font-medium">About</a>
<a href="#chiropractic-services" className="text-foreground/80 hover:text-primary transition-colors text-sm font-medium">Services</a>
<a href="#meet-the-team" className="text-foreground/80 hover:text-primary transition-colors text-sm font-medium">Team</a>
<a href="#clinic-gallery" className="text-foreground/80 hover:text-primary transition-colors text-sm font-medium">Gallery</a>
<a href="#visit-the-clinic" className="text-foreground/80 hover:text-primary transition-colors text-sm font-medium">Contact</a>
<Link href="/services" className="bg-primary text-primary-foreground px-4 py-2 rounded-lg hover:bg-primary/90 transition-colors text-sm font-medium">Book Appointment</Link>
</nav>
{/* Mobile toggle */}
<button
className="md:hidden p-2 rounded-md text-foreground hover:bg-muted transition-colors"
onClick={() => setIsOpen(!isOpen)}
aria-label="Toggle menu"
>
{isOpen ? <X className="h-6 w-6" /> : <Menu className="h-6 w-6" />}
</button>
</div>
{/* Mobile nav */}
{isOpen && (
<div className="md:hidden border-t py-4 space-y-1 px-2">
<Link href="/" className="block px-3 py-2 rounded-lg text-foreground hover:bg-muted transition-colors" onClick={() => setIsOpen(false)}>Home</Link>
<a href="#about-the-practice" className="block px-3 py-2 rounded-lg text-foreground hover:bg-muted transition-colors" onClick={() => setIsOpen(false)}>About</a>
<a href="#chiropractic-services" className="block px-3 py-2 rounded-lg text-foreground hover:bg-muted transition-colors" onClick={() => setIsOpen(false)}>Services</a>
<a href="#meet-the-team" className="block px-3 py-2 rounded-lg text-foreground hover:bg-muted transition-colors" onClick={() => setIsOpen(false)}>Team</a>
<a href="#clinic-gallery" className="block px-3 py-2 rounded-lg text-foreground hover:bg-muted transition-colors" onClick={() => setIsOpen(false)}>Gallery</a>
<a href="#visit-the-clinic" className="block px-3 py-2 rounded-lg text-foreground hover:bg-muted transition-colors" onClick={() => setIsOpen(false)}>Contact</a>
<Link href="/services" className="block px-3 py-2 rounded-lg bg-primary text-primary-foreground font-medium" onClick={() => setIsOpen(false)}>Book Appointment</Link>
</div>
)}
</div>
</header>
);
}