/* ============================================================
   FRUTA FRESCA — Data layer (window.FF)
   Real photography via Unsplash CDN. img(id,w,h) builds URLs.
   ============================================================ */
(function () {
  const img = (id, w = 900, h = null) =>
    /\.(jpe?g|png|webp|gif|avif)$/i.test(id)
      ? id
      : `https://images.unsplash.com/photo-${id}?auto=format&fit=crop&q=80&w=${w}` + (h ? `&h=${h}` : "");

  // Verified Unsplash photo IDs (fruit + farm/editorial)
  const PH = {
    mango:        "1553279768-865429fa0078",
    mangoPile:    "1713273576831-a81cb528853a",
    mangoBasket:  "1669207334420-66d0e3450283",
    mangoTree:    "1685429631345-3de21cc2eb65",
    mangoOnTree:  "1689899148821-71705bd9ab56",
    slicedBowl:   "1582655299221-2b6bff351df0",
    plateFruit:   "1635716279493-d1e30afc25a0",
    citrus:       "1623930376395-0f3ad22cfac2",
    yellowWood:   "1588931929796-8f0ea6da0faa",
    greenApple:   "1680559044009-bb031f8a2409",
    roundFruits:  "1629637272678-9b0d5a41b1e5",
    groupYellow:  "1664183238215-0848f923e3dc",
    fruitTree:    "1685478677113-8c4a58503230",
    greenTree:    "1680452284386-d10214aeeed0",
  };

  // Products — realistic Indian D2C fruit catalog
  const products = [
    {
      id: "alphonso",
      name: "Ratnagiri Alphonso Mango",
      origin: "Ratnagiri, Maharashtra",
      grade: "Class 1 · Export grade",
      cat: "Regional", season: "In season", organic: false, exotic: false,
      price: 1200, unit: "per dozen", priceFrom: false,
      rating: 4.9, reviews: 412, img: PH.mango,
      gallery: [PH.mango, PH.mangoBasket, PH.mangoPile, PH.mangoTree],
      tagline: "The Hapus. King of mangoes, picked at the Ratnagiri belt.",
      about: "Hand-picked from orchards in the Ratnagiri–Devgad belt, our Alphonso is naturally ripened — never carbide-treated. Saffron flesh, non-fibrous, with the honeyed aroma the Konkan coast is famous for.",
      nutrition: "Rich in Vitamin A & C, dietary fibre and antioxidants. ~135 kcal per fruit.",
      storage: "Keep at room temperature until fully ripe (2–4 days), then refrigerate. Best within 5 days of ripening.",
      origins: ["Ratnagiri", "Devgad"],
      packs: [
        { label: "Half-dozen", qty: "6", price: 650, sub: "6 pcs" },
        { label: "Dozen", qty: "12", price: 1200, sub: "12 pcs", def: true },
        { label: "Box of 24", qty: "24", price: 2300, sub: "24 pcs" },
      ],
      sensory: { Sweetness: "High", Juiciness: "High", Firmness: "Medium", Tartness: "Low" },
      specs: {
        Origin: "Ratnagiri–Devgad, Maharashtra", Variety: "Alphonso (Hapus)",
        Grade: "Class 1 · Export", Harvest: "Apr–Jun (peak)",
        "Net weight": "~2.4 kg / dozen", Ripening: "Naturally ripened, carbide-free",
      },
      grower: { coords: "16.99° N, 73.30° E", place: "Ratnagiri–Devgad belt, Konkan coast",
        story: "Sourced from family orchards along the Konkan coast, where the sea breeze and laterite soil give Alphonso its signature saffron flesh and honeyed aroma. Hand-picked, naturally ripened, graded for export.",
        img: PH.mangoOnTree },
      fssai: "11522998000234", packedBy: "Fruta Fresca Pvt. Ltd., Mumbai", country: "India",
    },
    {
      id: "kiwi",
      name: "New Zealand Kiwi",
      origin: "Bay of Plenty, NZ",
      grade: "Class 1 · Imported",
      cat: "Imported", season: "Fresh stock", organic: false, exotic: false,
      price: 240, unit: "box of 6", priceFrom: false,
      rating: 4.7, reviews: 188, img: "img/kiwi.jpg",
      gallery: ["img/kiwi.jpg", "img/kiwi-3.jpg", "img/exotic.jpg"],
      tagline: "Tangy, emerald and loaded with Vitamin C.",
      about: "Sun-grown in New Zealand's Bay of Plenty and cold-chain shipped. Firm, sweet-tart flesh that's perfect sliced, blended or scooped.",
      nutrition: "Exceptional Vitamin C (more than an orange), Vitamin K and potassium.",
      storage: "Ripen at room temperature; refrigerate once soft. Keeps up to 7 days chilled.",
      origins: ["New Zealand"],
    },
    {
      id: "fuji",
      name: "Imported Fuji Apple",
      origin: "Washington, USA",
      grade: "Class 1 · Imported",
      cat: "Imported", season: "Fresh stock", organic: false, exotic: false,
      price: 320, unit: "per kg", priceFrom: false,
      rating: 4.6, reviews: 256, img: "img/fuji.jpg",
      gallery: ["img/fuji.jpg"],
      tagline: "Crisp, honey-sweet and impossibly juicy.",
      about: "Premium Fuji apples with a dense, crunchy bite and high natural sugar. Wax-free and individually inspected.",
      nutrition: "Good source of fibre, Vitamin C and polyphenol antioxidants.",
      storage: "Refrigerate in the crisper drawer. Stays crisp for up to 3 weeks.",
      origins: ["USA"],
    },
    {
      id: "dragon",
      name: "Dragon Fruit",
      origin: "Mekong Delta, Vietnam",
      grade: "Class 1 · Exotic",
      cat: "Exotic", season: "Limited", organic: false, exotic: true,
      price: 180, unit: "each", priceFrom: false,
      rating: 4.5, reviews: 96, img: "img/dragon.jpg",
      gallery: ["img/dragon.jpg"],
      tagline: "Striking pink skin, speckled snow-white flesh.",
      about: "A showstopping exotic with mildly sweet, refreshing flesh and crunchy seeds. As good on a grazing board as it is in a smoothie.",
      nutrition: "High in fibre, magnesium and antioxidants. Low calorie.",
      storage: "Refrigerate and eat within 4–5 days. Serve chilled, halved and scooped.",
      origins: ["Vietnam"],
    },
    {
      id: "pomegranate",
      name: "Class 1 Pomegranate",
      origin: "Nashik, Maharashtra",
      grade: "Class 1 · Export grade",
      cat: "Regional", season: "In season", organic: false, exotic: false,
      price: 220, unit: "per kg", priceFrom: false,
      rating: 4.8, reviews: 174, img: "img/pomegranate.jpg",
      gallery: ["img/pomegranate.jpg", "img/pomegranates.jpg", "img/exotic-2.jpg"],
      tagline: "Ruby arils, deep colour, exceptional sweetness.",
      about: "Bhagwa-variety pomegranates from Nashik — large, deep-red arils with a high juice yield and very few hard seeds.",
      nutrition: "Loaded with antioxidants (punicalagins), Vitamin C and potassium.",
      storage: "Keeps 1–2 weeks refrigerated. Arils freeze beautifully.",
      origins: ["Nashik"],
    },
    {
      id: "avocado",
      name: "Imported Hass Avocado",
      origin: "Michoacán, Mexico",
      grade: "Class 1 · Imported",
      cat: "Imported", season: "Fresh stock", organic: true, exotic: false,
      price: 150, unit: "each", priceFrom: false,
      rating: 4.7, reviews: 203, img: "img/avocado.jpg",
      gallery: ["img/avocado.jpg"],
      tagline: "Buttery Hass, ripened to perfect.",
      about: "Creamy Hass avocados, conditioned so they arrive ready-to-eat in 1–2 days. Nutty, rich and spreadable.",
      nutrition: "Heart-healthy monounsaturated fats, fibre, folate and potassium.",
      storage: "Ripen at room temperature; refrigerate once it yields to gentle pressure.",
      origins: ["Mexico"],
    },
    {
      id: "blueberry",
      name: "Organic Blueberries",
      origin: "Nilgiris, Tamil Nadu",
      grade: "Class 1 · Organic",
      cat: "Organic", season: "Limited", organic: true, exotic: false,
      price: 380, unit: "box of 125g", priceFrom: false,
      rating: 4.6, reviews: 142, img: "img/blueberry.jpg",
      gallery: ["img/blueberry.jpg", "img/blueberries.jpg"],
      tagline: "Plump, antioxidant-rich and certified organic.",
      about: "Hand-harvested organic blueberries, firm and sweet with a gentle bloom. Perfect for breakfast bowls and baking.",
      nutrition: "One of the highest antioxidant fruits; rich in Vitamin K and manganese.",
      storage: "Refrigerate unwashed; wash just before eating. Best within 5 days.",
      origins: ["Nilgiris"],
    },
    {
      id: "litchi",
      name: "Muzaffarpur Litchi",
      origin: "Muzaffarpur, Bihar",
      grade: "Class 1 · Seasonal",
      cat: "Seasonal", season: "Pre-order", organic: false, exotic: false,
      price: 280, unit: "per kg", priceFrom: true,
      rating: 4.8, reviews: 119, img: "img/litchi.jpg",
      gallery: ["img/litchi.jpg"],
      tagline: "Shahi litchi — fragrant, translucent, fleeting.",
      about: "The legendary Shahi litchi of Muzaffarpur, available for a few short weeks. Floral, juicy and intensely sweet. Pre-order to reserve from the first harvest.",
      nutrition: "Vitamin C rich, hydrating and naturally low in fat.",
      storage: "Refrigerate and enjoy within 3–4 days for peak fragrance.",
      origins: ["Bihar"],
    },
    {
      id: "orange", name: "Nagpur Orange", origin: "Nagpur, Maharashtra",
      grade: "Class 1 · Regional", cat: "Regional", season: "In season", organic: false, exotic: false,
      price: 140, unit: "per kg", priceFrom: false, rating: 4.6, reviews: 167,
      img: "img/oranges.jpg", gallery: ["img/oranges.jpg", "img/orange-3.jpg", "img/orange6.jpg", "img/oranges43.jpg", "img/exotice45.jpg"],
      tagline: "Sweet, seedless and bursting with juice.",
      about: "The famous Nagpur santra — thin-skinned, easy to peel, with a perfect sweet-tangy balance. Cold-chain fresh from the orchards of Vidarbha.",
      nutrition: "Excellent Vitamin C, folate and fibre.",
      storage: "Keeps a week at room temperature, longer refrigerated.",
      origins: ["Nagpur"],
    },
    {
      id: "strawberry", name: "Mahabaleshwar Strawberry", origin: "Mahabaleshwar, Maharashtra",
      grade: "Class 1 · Regional", cat: "Regional", season: "Limited", organic: false, exotic: false,
      price: 160, unit: "box of 200g", priceFrom: false, rating: 4.7, reviews: 134,
      img: "img/strawberry.jpg", gallery: ["img/strawberry.jpg", "img/bowl.jpg"],
      tagline: "Fragrant, ruby-red and freshly picked.",
      about: "Plump, aromatic strawberries from the hills of Mahabaleshwar, hand-picked at peak ripeness. Sweet with a gentle tartness.",
      nutrition: "High in Vitamin C, manganese and antioxidants.",
      storage: "Refrigerate unwashed; wash just before eating. Best within 3 days.",
      origins: ["Mahabaleshwar"],
    },
    {
      id: "guava", name: "Allahabad Guava", origin: "Prayagraj, Uttar Pradesh",
      grade: "Class 1 · Regional", cat: "Regional", season: "In season", organic: false, exotic: false,
      price: 120, unit: "per kg", priceFrom: false, rating: 4.5, reviews: 98,
      img: "img/guava.jpg", gallery: ["img/guava.jpg"],
      tagline: "Crisp, fragrant and rich in Vitamin C.",
      about: "The legendary Allahabad Safeda guava — crunchy white flesh, intensely fragrant, with far more Vitamin C than citrus.",
      nutrition: "Very high Vitamin C and dietary fibre; low calorie.",
      storage: "Ripen at room temperature; refrigerate once soft.",
      origins: ["Uttar Pradesh"],
    },
    {
      id: "sitaphal", name: "Sitaphal (Custard Apple)", origin: "Beed, Maharashtra",
      grade: "Class 1 · Regional", cat: "Regional", season: "Pre-order", organic: false, exotic: false,
      price: 240, unit: "per kg", priceFrom: true, rating: 4.8, reviews: 76,
      img: "img/sitaphal.jpg", gallery: ["img/sitaphal.jpg"],
      tagline: "Custard-sweet, creamy and seasonal.",
      about: "Hand-picked custard apples with sweet, creamy, fragrant pulp. A short-season delicacy — reserve from the first harvest.",
      nutrition: "Rich in Vitamin C, B6, magnesium and fibre.",
      storage: "Ripen at room temperature; eat within 1–2 days once soft.",
      origins: ["Beed"],
    },
    {
      id: "banana", name: "Elaichi Banana", origin: "Jalgaon, Maharashtra",
      grade: "Class 1 · Regional", cat: "Regional", season: "Fresh stock", organic: false, exotic: false,
      price: 70, unit: "per dozen", priceFrom: false, rating: 4.4, reviews: 211,
      img: "img/banana.jpg", gallery: ["img/banana.jpg"],
      tagline: "Petite, fragrant and naturally sweet.",
      about: "Small-batch Elaichi (Yelakki) bananas — thin-skinned, dense and honey-sweet. Naturally ripened, never gassed.",
      nutrition: "Good source of potassium, Vitamin B6 and quick energy.",
      storage: "Store at room temperature; do not refrigerate until fully ripe.",
      origins: ["Jalgaon"],
    },
    {
      id: "apple-shimla", name: "Shimla Apple", origin: "Shimla, Himachal Pradesh",
      grade: "Class 1 · Regional", cat: "Regional", season: "Fresh stock", organic: false, exotic: false,
      price: 220, unit: "per kg", priceFrom: false, rating: 4.6, reviews: 152,
      img: "img/apple.jpg", gallery: ["img/apple.jpg", "img/apple3.jpg"],
      tagline: "Crisp Himalayan apples, naturally grown.",
      about: "Royal Delicious apples from the orchards of Himachal — firm, crunchy and sweet, hand-graded for size and colour.",
      nutrition: "Fibre, Vitamin C and antioxidants.",
      storage: "Refrigerate in the crisper; stays crisp for weeks.",
      origins: ["Himachal Pradesh"],
    },
    {
      id: "green-apple", name: "Green Apple", origin: "Washington, USA",
      grade: "Class 1 · Imported", cat: "Imported", season: "Fresh stock", organic: false, exotic: false,
      price: 260, unit: "per kg", priceFrom: false, rating: 4.5, reviews: 119,
      img: "img/green-apple.jpg", gallery: ["img/green-apple.jpg"],
      tagline: "Tart, crunchy Granny Smith.",
      about: "Bright-green Granny Smith apples with a sharp, refreshing tartness and a dense crunch. Great for snacking and baking.",
      nutrition: "Fibre, Vitamin C and polyphenols.",
      storage: "Refrigerate; stays crisp up to 3 weeks.",
      origins: ["USA"],
    },
    {
      id: "fig", name: "Pune Anjeer (Fig)", origin: "Pune, Maharashtra",
      grade: "Class 1 · Regional", cat: "Regional", season: "Limited", organic: false, exotic: false,
      price: 320, unit: "box of 250g", priceFrom: false, rating: 4.7, reviews: 64,
      img: "img/fig-1.jpg", gallery: ["img/fig-1.jpg"],
      tagline: "Soft, honeyed and delicate.",
      about: "Purandar figs from the Pune belt — tender, jammy and floral, with edible skin. A short-window seasonal treat.",
      nutrition: "Fibre, calcium, potassium and antioxidants.",
      storage: "Refrigerate and eat within 2–3 days.",
      origins: ["Pune"],
    },
    {
      id: "cherry", name: "Imported Cherries", origin: "Washington, USA",
      grade: "Class 1 · Imported", cat: "Imported", season: "Limited", organic: false, exotic: false,
      price: 650, unit: "box of 250g", priceFrom: false, rating: 4.8, reviews: 88,
      img: "img/cherries.jpg", gallery: ["img/cherries.jpg"],
      tagline: "Dark, glossy and intensely sweet.",
      about: "Premium dark-red cherries, cold-chain flown in and inspected for firmness and shine. Snappy skin, juicy flesh.",
      nutrition: "Antioxidants, Vitamin C and potassium.",
      storage: "Refrigerate unwashed; best within 4–5 days.",
      origins: ["USA"],
    },
    {
      id: "tangerine", name: "Imported Tangerine", origin: "Murcia, Spain",
      grade: "Class 1 · Imported", cat: "Imported", season: "Fresh stock", organic: false, exotic: false,
      price: 290, unit: "per kg", priceFrom: false, rating: 4.5, reviews: 73,
      img: "img/tangerine.jpg", gallery: ["img/tangerine.jpg"],
      tagline: "Easy-peel, seedless and sweet.",
      about: "Sweet, aromatic tangerines — loose-skinned and seedless, perfect for lunchboxes and quick snacking.",
      nutrition: "Vitamin C, folate and fibre.",
      storage: "Keeps a week at room temperature, longer chilled.",
      origins: ["Spain"],
    },
    {
      id: "grapefruit", name: "Ruby Grapefruit", origin: "Texas, USA",
      grade: "Class 1 · Exotic", cat: "Exotic", season: "Limited", organic: false, exotic: true,
      price: 120, unit: "each", priceFrom: false, rating: 4.4, reviews: 51,
      img: "img/exotice11.jpg", gallery: ["img/exotice11.jpg", "img/exotic-4.jpg"],
      tagline: "Ruby flesh, sweet-tart and refreshing.",
      about: "Deep-pink ruby grapefruit with juicy, sweet-tart segments. As good halved at breakfast as it is in a salad.",
      nutrition: "Vitamin C, Vitamin A and antioxidants.",
      storage: "Refrigerate; juicy for up to 2 weeks.",
      origins: ["USA"],
    },
    {
      id: "watermelon", name: "Seedless Watermelon", origin: "Solapur, Maharashtra",
      grade: "Class 1 · Seasonal", cat: "Seasonal", season: "In season", organic: false, exotic: false,
      price: 90, unit: "each", priceFrom: true, rating: 4.5, reviews: 142,
      img: "img/watermelon-1.jpg", gallery: ["img/watermelon-1.jpg"],
      tagline: "Crisp, hydrating and summer-sweet.",
      about: "Seedless watermelons picked at peak sweetness — crisp, deep-red flesh and high water content for the Indian summer.",
      nutrition: "Hydrating, with lycopene and Vitamin C.",
      storage: "Refrigerate whole; once cut, wrap and chill, eat within 3 days.",
      origins: ["Solapur"],
    },
    {
      id: "lemon", name: "Fresh Lemon", origin: "Vijayapura, Karnataka",
      grade: "Class 1 · Organic", cat: "Organic", season: "Fresh stock", organic: true, exotic: false,
      price: 80, unit: "per kg", priceFrom: false, rating: 4.3, reviews: 96,
      img: "img/lemon.jpg", gallery: ["img/lemon.jpg"],
      tagline: "Zesty, juicy and kitchen-essential.",
      about: "Thin-skinned, juicy lemons with bright acidity — pesticide-free and perfect for cooking, drinks and dressings.",
      nutrition: "High Vitamin C; antibacterial and alkalising.",
      storage: "Keeps 1 week at room temperature, 3–4 weeks refrigerated.",
      origins: ["Karnataka"],
    },
  ];

  // Pack-size generator for products without explicit packs
  const genPacks = (p) => {
    if (p.packs) return p.packs;
    const u = p.unit;
    if (/each/.test(u)) return [
      { label: "Single", price: p.price, sub: "1 pc" },
      { label: "Pack of 4", price: Math.round(p.price * 4 * 0.95), sub: "4 pcs", def: true },
      { label: "Pack of 8", price: Math.round(p.price * 8 * 0.9), sub: "8 pcs" }];
    if (/kg/.test(u)) return [
      { label: "500 g", price: Math.round(p.price * 0.5), sub: "0.5 kg" },
      { label: "1 kg", price: p.price, sub: "1 kg", def: true },
      { label: "2 kg", price: Math.round(p.price * 1.9), sub: "2 kg" }];
    if (/dozen/.test(u)) return [
      { label: "Half-dozen", price: Math.round(p.price * 0.54), sub: "6 pcs" },
      { label: "Dozen", price: p.price, sub: "12 pcs", def: true },
      { label: "Box of 24", price: Math.round(p.price * 1.92), sub: "24 pcs" }];
    if (/box|g\b/.test(u)) return [
      { label: u, price: p.price, sub: u, def: true },
      { label: "Twin pack", price: Math.round(p.price * 1.9), sub: "2 × " + u }];
    return [{ label: u, price: p.price, sub: u, def: true }];
  };

  // Fill new detail fields for every product
  products.forEach((p) => {
    p.sensory = p.sensory || { Sweetness: "Medium", Juiciness: "Medium", Firmness: "Medium", Tartness: "Low" };
    p.specs = p.specs || {
      Origin: p.origin, Variety: p.name.replace(/^(Imported|Organic|Class 1)\s+/, ""),
      Grade: p.grade, Harvest: "In season", "Net weight": "~1 kg", Ripening: "Naturally ripened",
    };
    p.grower = p.grower || { coords: "", place: p.origin, story: p.about, img: p.cat === "Imported" ? PH.greenTree : PH.mangoOnTree };
    p.fssai = p.fssai || "11522998000234";
    p.packedBy = p.packedBy || "Fruta Fresca Pvt. Ltd., Mumbai";
    p.country = p.country || (p.cat === "Imported" ? p.origins[0] : "India");
  });
  // A couple of tuned sensory profiles
  Object.assign(FFsensory(products, "pomegranate"), { Sweetness: "High", Juiciness: "High", Firmness: "Medium", Tartness: "Medium" });
  Object.assign(FFsensory(products, "kiwi"), { Sweetness: "Medium", Juiciness: "High", Firmness: "Medium", Tartness: "High" });
  Object.assign(FFsensory(products, "avocado"), { Sweetness: "Low", Juiciness: "Low", Firmness: "Soft", Tartness: "Low" });
  function FFsensory(list, id) { return (list.find((x) => x.id === id) || {}).sensory || {}; }

  const categories = [
    { key: "Regional", label: "Regional", desc: "Indian heritage harvests", img: "img/pomegranates.jpg" },
    { key: "Imported", label: "Imported", desc: "Cold-chain from abroad", img: "img/fuji.jpg" },
    { key: "Exotic",   label: "Exotic",   desc: "Rare & remarkable", img: "img/dragon.jpg" },
    { key: "Organic",  label: "Organic",  desc: "Certified, clean-grown", img: "img/blueberry.jpg" },
    { key: "Seasonal", label: "Seasonal", desc: "Here for a moment", img: "img/watermelon-1.jpg" },
  ];

  const hampers = [
    { id: "classic", name: "The Classic Crate", price: 1499, img: "img/hamper2.jpg",
      desc: "A curated everyday selection of six seasonal fruits in a kraft crate.", items: ["Alphonso Mango", "Fuji Apple", "Pomegranate", "Kiwi"] },
    { id: "festive", name: "Festive Premium Hamper", price: 3299, img: "img/exotic_1.jpg",
      desc: "Exotic and regional best-sellers with dry fruits in a keepsake box.", items: ["Dragon Fruit", "Avocado", "Blueberries", "Alphonso Mango", "Litchi"], tag: "Best seller" },
    { id: "getwell", name: "Get Well Soon Box", price: 1199, img: "img/bowl.jpg",
      desc: "Light, immune-boosting fruits with a handwritten note.", items: ["Kiwi", "Pomegranate", "Blueberries"] },
  ];

  const subscriptions = [
    { id: "daily", name: "Daily Fresh Bowl", price: 199, cadence: "per day", img: "img/exotic-6.jpg",
      blurb: "A single-serve bowl of cut, ready-to-eat seasonal fruit at your door each morning.",
      perks: ["Delivered before 8 AM", "Skip any day", "Cancel anytime"] },
    { id: "weekly", name: "Weekly Seasonal Box", price: 899, cadence: "per week", img: "img/exotice45.jpg",
      blurb: "Five to seven varieties of peak-season fruit, hand-picked by our buyers.", popular: true,
      perks: ["Free delivery", "Customise your box", "Pause when travelling"] },
    { id: "monthly", name: "Monthly Exotic Selection", price: 2499, cadence: "per month", img: "img/dragon.jpg",
      blurb: "A monthly discovery of imported and rare exotics, with tasting notes.",
      perks: ["Rare imports first", "Tasting card included", "Member pricing"] },
  ];

  const occasions = [
    { key: "birthday", label: "Birthday", img: "img/exotice45.jpg" },
    { key: "wedding",  label: "Wedding",  img: "img/hamper2.jpg" },
    { key: "getwell",  label: "Get Well Soon", img: "img/bowl.jpg" },
    { key: "festive",  label: "Festive",  img: "img/exotic_1.jpg" },
  ];

  const testimonials = [
    { q: "The Alphonsos arrived perfectly ripe and smelled like my grandmother's kitchen. Unreal quality.", a: "Ananya M.", city: "Bandra, Mumbai" },
    { q: "I gift the Festive Hamper every Diwali now. The packaging alone gets gasps.", a: "Rohan & Priya", city: "Powai, Mumbai" },
    { q: "Weekly box has replaced my market runs entirely. Always fresh, always on time.", a: "Dr. Kavita S.", city: "Juhu, Mumbai" },
  ];

  const reviews = [
    { name: "Ananya M.", rating: 5, date: "2 weeks ago", verified: true,
      text: "Perfectly ripe, zero bruising. The cold-chain box kept everything cool even in the May heat." },
    { name: "Vikram T.", rating: 5, date: "1 month ago", verified: true,
      text: "Genuinely export quality. You can taste the difference vs the local market." },
    { name: "Sara D.", rating: 4, date: "1 month ago", verified: true,
      text: "Loved the fruit. Wish the dozen had one or two more — but flavour was outstanding." },
  ];

  const nav = ["Shop", "Hampers", "Subscriptions", "Gifting", "Our Sourcing", "About"];

  window.FF = {
    img, PH, products, categories, hampers, subscriptions, occasions,
    testimonials, reviews, nav, genPacks,
    rupee: (n) => "₹" + n.toLocaleString("en-IN"),
    byId: (id) => products.find((p) => p.id === id),
  };
})();
