import roma from "@/assets/product-roma.jpg";
import beefsteak from "@/assets/product-beefsteak.jpg";
import cherry from "@/assets/product-cherry.jpg";
import heirloom from "@/assets/product-heirloom.jpg";

export type Product = {
  id: string;
  name: string;
  variety: string;
  image: string;
  pricePerKg: number; // RWF
  unit: "kg" | "crate";
  location: string;
  district: string;
  available: boolean;
  stockKg: number;
  harvestDate: string;
  farmer: string;
  description: string;
  metaDescription: string;
  sourceFarm: string;
  delivery: string;
  status: "in_season" | "available_in_stock" | "unavailable";
  sourcePersonName: string;
  sourcePersonNote: string;
  isDraft: boolean;
  isHidden: boolean;
};

export const products: Product[] = [
  {
    id: "roma-musanze",
    name: "Vine-Ripened Roma",
    variety: "Roma",
    image: roma,
    pricePerKg: 1200,
    unit: "kg",
    location: "Musanze",
    district: "Musanze",
    available: true,
    stockKg: 420,
    harvestDate: "2026-04-25",
    farmer: "Jean-Baptiste U.",
    description:
      "Dense, low-water Roma tomatoes — perfect for sauces, stews, and slow cooking. Hand-picked at peak ripeness from the volcanic soils of Musanze.",
    metaDescription: "Dense, low-water Roma tomatoes perfect for sauces and stews.",
    sourceFarm: "Musanze Family Farm",
    delivery: "48h nationwide",
    status: "in_season",
    sourcePersonName: "Jean-Baptiste U.",
    sourcePersonNote: "Hand-picked at peak ripeness from the volcanic soils of Musanze.",
    isDraft: false,
    isHidden: false,
  },
  {
    id: "beefsteak-huye",
    name: "Highland Beefsteak",
    variety: "Beefsteak",
    image: beefsteak,
    pricePerKg: 1450,
    unit: "kg",
    location: "Huye",
    district: "Huye",
    available: true,
    stockKg: 280,
    harvestDate: "2026-04-26",
    farmer: "Marie-Claire N.",
    description:
      "Large, meaty beefsteak tomatoes grown in the cool highlands of Huye. Ideal for sandwiches, salads, and grilling.",
    metaDescription: "Large, meaty beefsteak tomatoes grown for grilling and salads.",
    sourceFarm: "Huye Harvest",
    delivery: "48h nationwide",
    status: "available_in_stock",
    sourcePersonName: "Marie-Claire N.",
    sourcePersonNote: "Large, meaty beefsteak tomatoes grown in the cool highlands of Huye. Ideal for sandwiches, salads, and grilling.",
    isDraft: false,
    isHidden: false,
  },
  {
    id: "cherry-rwamagana",
    name: "Sun-Sweet Cherry",
    variety: "Cherry",
    image: cherry,
    pricePerKg: 1800,
    unit: "kg",
    location: "Rwamagana",
    district: "Rwamagana",
    available: true,
    stockKg: 160,
    harvestDate: "2026-04-27",
    farmer: "Eric M.",
    description:
      "Tiny, sugar-sweet cherry tomatoes that burst with flavor. Snack-ready, salad-ready, kid-approved.",
    metaDescription: "Tiny, sugar-sweet cherry tomatoes that burst with flavor.",
    sourceFarm: "Rwamagana Orchards",
    delivery: "48h nationwide",
    status: "available_in_stock",
    sourcePersonName: "Eric M.",
    sourcePersonNote: "Perfect for snacking, salads, and fresh garnishes.",
    isDraft: false,
    isHidden: false,
  },
  {
    id: "heirloom-nyamagabe",
    name: "Heritage Heirloom Mix",
    variety: "Heirloom",
    image: heirloom,
    pricePerKg: 2200,
    unit: "kg",
    location: "Nyamagabe",
    district: "Nyamagabe",
    available: false,
    stockKg: 0,
    harvestDate: "2026-05-04",
    farmer: "Agnès K.",
    description:
      "A curated mix of heirloom varieties in red, orange, and yellow. Limited harvest — restocking next week.",
    metaDescription: "A curated mix of heirloom varieties in red, orange, and yellow.",
    sourceFarm: "Nyamagabe Heritage Farm",
    delivery: "Restocking soon",
    status: "unavailable",
    sourcePersonName: "Agnès K.",
    sourcePersonNote: "A limited heirloom harvest with deep flavor and colorful variety.",
    isDraft: false,
    isHidden: false,
  },
];

export const formatRWF = (n: number) =>
  new Intl.NumberFormat("en-RW", { maximumFractionDigits: 0 }).format(n) + " RWF";
