"use client"; /** * SHAHI KITCHEN HOMEPAGE * Version with advanced Signature Menu + elegant hero (pre full Sultan redesign) */ import React, { useEffect, useState } from "react"; import { motion, AnimatePresence } from "framer-motion"; import Lenis from "lenis"; import { gsap } from "gsap"; import { ScrollTrigger } from "gsap/ScrollTrigger"; import { Crown, Clock, ArrowRight, UtensilsCrossed } from "lucide-react"; import Navbar from "@/components/Navbar"; import Footer from "@/components/Footer"; import { useCart } from "@/components/CartContext"; import { useLanguage } from "@/lib/language-context"; import { getTranslation } from "@/lib/translations"; gsap.registerPlugin(ScrollTrigger); export default function ShahiKitchenHomepage() { const { addToCart } = useCart(); const { language } = useLanguage(); const t = getTranslation(language); const [menuFilter, setMenuFilter] = useState<"All" | "Rice" | "Curry" | "Meat" | "Street" | "Roll" | "Sweet">("All"); // Lenis smooth scroll useEffect(() => { const lenis = new Lenis({ duration: 1.1, easing: (t: number) => Math.min(1, 1.001 * (-Math.pow(2, -10 * t) + 1)), smoothWheel: true, }); const raf = (time: number) => { lenis.raf(time); requestAnimationFrame(raf); }; requestAnimationFrame(raf); return () => lenis.destroy(); }, []); const signatureDishes = [ { id: "chicken-biryani", name: "Chicken Biryani", category: "Rice", price: 149, time: "32 min", desc: "Fragrant aged basmati layered with spiced chicken, saffron & caramelized onions", image: "chicken-biryani-poster.jpg" }, { id: "bong-nihari", name: "Bong Nihari", category: "Curry", price: 199, time: "45 min", desc: "Slow-cooked beef shank in rich aromatic gravy with ginger, lemon & fresh naan", image: "bong-nihari-poster.jpg" }, { id: "panipuri", name: "Golgappy / Panipuri", category: "Street", price: 69, time: "15 min", desc: "Crispy hollow puris filled with spiced chickpeas, potatoes & tangy tamarind water", image: "panipuri-poster.jpg" }, { id: "lamm-palak", name: "Lamm Palak", category: "Meat", price: 179, time: "30 min", desc: "Tender lamb cooked with fresh spinach in a flavorful mild gravy", image: "lamm-palak-poster.jpg" }, { id: "chicken-karahi", name: "Chicken Karahi", category: "Curry", price: 149, time: "28 min", desc: "Wok-tossed chicken in a robust tomato, chili & ginger gravy", image: "chicken-karahi-poster.jpg" }, { id: "chicken-haleem", name: "Chicken Haleem", category: "Curry", price: 149, time: "35 min", desc: "Slow-cooked shredded chicken with lentils, wheat & aromatic spices", image: "chicken-haleem-poster.jpg" }, { id: "tikka-boti-roll", name: "Tikka Boti Roll", category: "Roll", price: 99, time: "20 min", desc: "Juicy chicken tikka wrapped in soft naan with mint chutney & onions", image: "tikka-boti-roll-poster.jpg" }, { id: "jalebi", name: "Jalebi", category: "Sweet", price: 119, time: "12 min", desc: "Crispy golden saffron spirals soaked in fragrant sugar syrup", image: "jalebi-poster.jpg" }, { id: "kulfi", name: "Kulfi", category: "Sweet", price: 39, time: "10 min", desc: "Traditional frozen milk dessert with cardamom, pistachio & saffron", image: "kulfi-poster.jpg" }, ]; const filtered = menuFilter === "All" ? signatureDishes : signatureDishes.filter(d => d.category === menuFilter); const addDish = (d: any) => { addToCart({ id: d.id, name: d.name, price: d.price, image: d.image }); }; // Advanced GSAP effects for signature cards useEffect(() => { const cards = document.querySelectorAll(".signature-card"); gsap.fromTo(cards, { opacity: 0, y: 45 }, { opacity: 1, y: 0, duration: 0.9, ease: "power3.out", stagger: 0.06, scrollTrigger: { trigger: ".signature-menu-grid", start: "top 82%", once: true } } ); cards.forEach((card) => { const image = card.querySelector(".signature-image") as HTMLElement | null; let bounds: DOMRect; const onMouseMove = (e: MouseEvent) => { if (!bounds) bounds = card.getBoundingClientRect(); const x = ((e.clientX - bounds.left) / bounds.width - 0.5) * 2; const y = ((e.clientY - bounds.top) / bounds.height - 0.5) * 2; gsap.to(card, { rotationY: x * 11, rotationX: -y * 8, transformPerspective: 1400, duration: 0.35, ease: "power2.out" }); if (image) gsap.to(image, { x: x * 8, y: y * 6, duration: 0.45, ease: "power2.out" }); }; const onMouseLeave = () => { gsap.to(card, { rotationY: 0, rotationX: 0, duration: 1.1, ease: "elastic.out(1, 0.45)" }); if (image) gsap.to(image, { x: 0, y: 0, scale: 1, duration: 0.9, ease: "power2.out" }); }; const onMouseEnter = () => { if (image) gsap.to(image, { scale: 1.12, duration: 1.1, ease: "power2.out" }); }; card.addEventListener("mousemove", onMouseMove); card.addEventListener("mouseleave", onMouseLeave); card.addEventListener("mouseenter", onMouseEnter); (card as any)._cleanup = () => { card.removeEventListener("mousemove", onMouseMove); card.removeEventListener("mouseleave", onMouseLeave); card.removeEventListener("mouseenter", onMouseEnter); }; }); return () => { cards.forEach(card => (card as any)._cleanup?.()); }; }, [filtered]); return (
{/* HERO - Full Banner Video with responsive framing */}
{/* Banner Video - Optimized positioning per device */} {/* Subtle gradient to improve visibility of baked-in text */}
{/* ADVANCED SIGNATURE MENU */} {/* THE SHAHI EXPERIENCE */}
THE SHAHI WAY

More than a meal.
A moment of royalty.

{[ { title: "The Legendary Buffet", desc: "Our famous lunch buffet features over 20 rotating dishes — curries, biryanis, fresh naan, and sweets." }, { title: "Shahi Sweets", desc: "Homemade mithai made daily. From fresh Jalebi to Rasmalai — the perfect sweet ending." }, { title: "Warm Hospitality", desc: "Whether you're here for a quick lunch or a family celebration, you will always be treated like royalty." }, ].map((item, index) => (
0{index + 1}

{item.title}

{item.desc}

))}
); }