import { Product } from '@/domain/entities';
import { getProductImages } from '@/infrastructure/images';

type ProductDefinition = Omit<Product, 'image' | 'images'>;

const PRODUCT_DEFINITIONS: ProductDefinition[] = [
  {
    id: 'chicken-whole',
    slug: 'whole-chicken',
    category: 'chicken',
    price: 129,
    priceUnitKey: 'perBird',
    badgeKey: 'bestseller',
    inStock: true,
    featured: true,
    weight: '1.2–1.5 kg',
    tags: ['fresh', 'whole', 'popular'],
  },
  {
    id: 'chicken-breast',
    slug: 'chicken-breast',
    category: 'chicken',
    price: 99,
    priceUnitKey: 'perPack',
    inStock: true,
    featured: true,
    weight: '500g–1kg',
    tags: ['fresh', 'boneless', 'lean'],
  },
  {
    id: 'chicken-thighs',
    slug: 'chicken-thighs',
    category: 'chicken',
    price: 85,
    priceUnitKey: 'perPack',
    inStock: true,
    featured: false,
    weight: '500g–1kg',
    tags: ['fresh', 'juicy'],
  },
  {
    id: 'chicken-wings',
    slug: 'chicken-wings',
    category: 'chicken',
    price: 79,
    priceUnitKey: 'perPack',
    inStock: true,
    featured: false,
    tags: ['fresh', 'party'],
  },
  {
    id: 'beef-nihari',
    slug: 'beef-for-nihari',
    category: 'beef',
    price: 149,
    priceUnitKey: 'perKg',
    badgeKey: 'chefsPick',
    inStock: true,
    featured: true,
    weight: '1 kg',
    tags: ['fresh', 'traditional'],
  },
  {
    id: 'beef-steak',
    slug: 'premium-beef-steak',
    category: 'beef',
    price: 229,
    priceUnitKey: 'perKg',
    badgeKey: 'premium',
    inStock: true,
    featured: true,
    weight: '1 kg',
    tags: ['premium', 'steak'],
  },
  {
    id: 'beef-mince',
    slug: 'beef-mince',
    category: 'beef',
    price: 119,
    priceUnitKey: 'perKg',
    inStock: true,
    featured: false,
    weight: '500g–1kg',
    tags: ['fresh', 'mince'],
  },
  {
    id: 'beef-boneless',
    slug: 'boneless-beef-cubes',
    category: 'beef',
    price: 169,
    priceUnitKey: 'perKg',
    inStock: true,
    featured: false,
    weight: '1 kg',
    tags: ['fresh', 'boneless'],
  },
  {
    id: 'lamb-shoulder',
    slug: 'lamb-shoulder',
    category: 'lamb',
    price: 189,
    priceUnitKey: 'perKg',
    badgeKey: 'popular',
    inStock: true,
    featured: true,
    weight: '1 kg',
    tags: ['fresh', 'traditional'],
  },
  {
    id: 'lamb-leg',
    slug: 'lamb-leg',
    category: 'lamb',
    price: 219,
    priceUnitKey: 'perKg',
    inStock: true,
    featured: true,
    weight: '1–2 kg',
    tags: ['premium', 'roast'],
  },
  {
    id: 'lamb-chops',
    slug: 'lamb-chops',
    category: 'lamb',
    price: 249,
    priceUnitKey: 'perKg',
    badgeKey: 'premium',
    inStock: true,
    featured: false,
    weight: '500g',
    tags: ['premium', 'grill'],
  },
  {
    id: 'lamb-mince',
    slug: 'lamb-mince',
    category: 'lamb',
    price: 159,
    priceUnitKey: 'perKg',
    inStock: true,
    featured: false,
    weight: '500g–1kg',
    tags: ['fresh', 'mince'],
  },
  {
    id: 'fish-salmon',
    slug: 'atlantic-salmon-fillet',
    category: 'fish',
    price: 199,
    priceUnitKey: 'perKg',
    badgeKey: 'frozen',
    inStock: true,
    featured: true,
    weight: '500g',
    tags: ['frozen', 'fillet'],
  },
  {
    id: 'fish-rohu',
    slug: 'rohu-fish',
    category: 'fish',
    price: 119,
    priceUnitKey: 'perKg',
    badgeKey: 'frozen',
    inStock: true,
    featured: true,
    weight: '1–1.5 kg',
    tags: ['frozen', 'whole'],
  },
  {
    id: 'fish-prawns',
    slug: 'jumbo-prawns',
    category: 'fish',
    price: 179,
    priceUnitKey: 'perKg',
    badgeKey: 'frozen',
    inStock: true,
    featured: false,
    weight: '500g',
    tags: ['frozen', 'seafood'],
  },
  {
    id: 'fish-basa',
    slug: 'basa-fillet',
    category: 'fish',
    price: 109,
    priceUnitKey: 'perKg',
    badgeKey: 'frozen',
    inStock: true,
    featured: false,
    weight: '500g',
    tags: ['frozen', 'fillet', 'mild'],
  },
];

/** Images are attached from the central catalog — not duplicated here */
export const PRODUCT_CATALOG: Product[] = PRODUCT_DEFINITIONS.map((product) => ({
  ...product,
  ...getProductImages(product.id),
}));