import type { AppConfig } from "@/stores/useAppStore";

export const templateCategories = ["All", "Business", "Lifestyle", "Media", "Food"] as const;
export type TemplateCategory = typeof templateCategories[number];

export interface PresetTemplate {
  name: string;
  description: string | null;
  category: TemplateCategory;
  config: AppConfig;
}

export const presetTemplates: PresetTemplate[] = [
  {
    name: "E-commerce",
    description: "Shopping app with cart and product catalog",
    category: "Business",
    config: {
      websiteUrl: "",
      appName: "My Store",
      primaryColor: "#10B981",
      accentColor: "#F59E0B",
      navigationStyle: "bottom-nav",
      suggestedFeatures: ["Push Notifications", "Offline Mode", "Share Feature", "Search"],
      appCategory: "Shopping",
      description: "A modern e-commerce shopping experience",
      iconStyle: "modern",
      splashScreenStyle: "centered-logo",
      recommendations: ["Add product quick-view", "Enable wishlist feature"],
      aiProvider: "gemini",
      automationWorkflows: ["data-sync", "push-automation", "email-workflows"],
    },
  },
  {
    name: "News App",
    description: "Content-focused with reading mode",
    category: "Media",
    config: {
      websiteUrl: "",
      appName: "Daily News",
      primaryColor: "#EF4444",
      accentColor: "#1D4ED8",
      navigationStyle: "tabs",
      suggestedFeatures: ["Push Notifications", "Offline Mode", "Share Feature", "Dark Mode", "Pull to Refresh"],
      appCategory: "News",
      description: "Stay informed with the latest news",
      iconStyle: "modern",
      splashScreenStyle: "centered-logo",
      recommendations: ["Add reading time estimates", "Enable article bookmarks"],
      aiProvider: "gemini",
      automationWorkflows: ["push-automation", "scheduled-tasks", "data-sync"],
    },
  },
  {
    name: "Portfolio",
    description: "Showcase work with elegant design",
    category: "Business",
    config: {
      websiteUrl: "",
      appName: "My Portfolio",
      primaryColor: "#8B5CF6",
      accentColor: "#EC4899",
      navigationStyle: "drawer",
      suggestedFeatures: ["Dark Mode", "Share Feature", "In-App Browser"],
      appCategory: "Business",
      description: "Professional portfolio showcase",
      iconStyle: "modern",
      splashScreenStyle: "centered-logo",
      recommendations: ["Add contact form", "Include social links"],
      aiProvider: "gemini",
      automationWorkflows: ["form-automation", "email-workflows"],
    },
  },
  {
    name: "Restaurant",
    description: "Menu and ordering focused",
    category: "Food",
    config: {
      websiteUrl: "",
      appName: "Food & Dine",
      primaryColor: "#F97316",
      accentColor: "#84CC16",
      navigationStyle: "bottom-nav",
      suggestedFeatures: ["Push Notifications", "Share Feature", "Search", "In-App Browser"],
      appCategory: "Food & Drink",
      description: "Delicious food at your fingertips",
      iconStyle: "modern",
      splashScreenStyle: "centered-logo",
      recommendations: ["Add table reservations", "Enable order tracking"],
      aiProvider: "gemini",
      automationWorkflows: ["push-automation", "scheduled-tasks", "form-automation"],
    },
  },
  {
    name: "Fitness",
    description: "Health tracking and workouts",
    category: "Lifestyle",
    config: {
      websiteUrl: "",
      appName: "FitLife",
      primaryColor: "#06B6D4",
      accentColor: "#14B8A6",
      navigationStyle: "bottom-nav",
      suggestedFeatures: ["Push Notifications", "Offline Mode", "Dark Mode", "Biometric Login"],
      appCategory: "Health & Fitness",
      description: "Your personal fitness companion",
      iconStyle: "modern",
      splashScreenStyle: "centered-logo",
      recommendations: ["Add workout reminders", "Track progress charts"],
      aiProvider: "gemini",
      automationWorkflows: ["scheduled-tasks", "push-automation", "data-sync", "cloud-backup"],
    },
  },
  {
    name: "Blog",
    description: "Personal blog with rich content",
    category: "Media",
    config: {
      websiteUrl: "",
      appName: "My Blog",
      primaryColor: "#6366F1",
      accentColor: "#A855F7",
      navigationStyle: "drawer",
      suggestedFeatures: ["Dark Mode", "Share Feature", "Offline Mode", "Pull to Refresh"],
      appCategory: "Lifestyle",
      description: "Share your thoughts with the world",
      iconStyle: "modern",
      splashScreenStyle: "centered-logo",
      recommendations: ["Add comment sections", "Enable RSS feed"],
      aiProvider: "gemini",
      automationWorkflows: ["scheduled-tasks", "email-workflows"],
    },
  },
  {
    name: "Travel",
    description: "Explore destinations and bookings",
    category: "Lifestyle",
    config: {
      websiteUrl: "",
      appName: "Wanderlust",
      primaryColor: "#0EA5E9",
      accentColor: "#F43F5E",
      navigationStyle: "bottom-nav",
      suggestedFeatures: ["Push Notifications", "Offline Mode", "Share Feature", "Search"],
      appCategory: "Travel",
      description: "Discover amazing destinations",
      iconStyle: "modern",
      splashScreenStyle: "centered-logo",
      recommendations: ["Add offline maps", "Enable trip planning"],
      aiProvider: "gemini",
      automationWorkflows: ["data-sync", "push-automation", "cloud-backup"],
    },
  },
  {
    name: "Café",
    description: "Coffee shop with loyalty rewards",
    category: "Food",
    config: {
      websiteUrl: "",
      appName: "Bean & Brew",
      primaryColor: "#78350F",
      accentColor: "#D97706",
      navigationStyle: "bottom-nav",
      suggestedFeatures: ["Push Notifications", "Offline Mode", "Share Feature"],
      appCategory: "Food & Drink",
      description: "Your daily coffee companion",
      iconStyle: "modern",
      splashScreenStyle: "centered-logo",
      recommendations: ["Add loyalty program", "Enable mobile ordering"],
      aiProvider: "gemini",
      automationWorkflows: ["push-automation", "event-triggers"],
    },
  },
];