export const en = {
  // Navigation tabs
  nav: {
    explore: 'Explore',
    chatbots: 'Chatbots',
    inbox: 'Inbox',
    account: 'Account',
  },

  // Auth
  auth: {
    login_title: 'Welcome back',
    login_subtitle: 'Sign in to your Contexta account',
    signup_title: 'Create your account',
    signup_subtitle: 'Start building AI chatbots — free forever',
    email: 'Email',
    password: 'Password',
    company_name: 'Company name',
    sign_in: 'Sign In',
    create_account: 'Create free account',
    no_account: "Don't have an account?",
    already_account: 'Already have an account?',
    sign_up_free: 'Sign up free',
    forgot_password: 'Forgot password?',
    forgot_title: 'Reset your password',
    forgot_subtitle: "Enter your email and we'll send a reset link.",
    send_reset: 'Send reset link',
    back_to_signin: 'Back to sign in',
    check_email_title: 'Check your email',
    check_email_desc: 'A reset link has been sent if that address is registered.',
  },

  // Dashboard
  dashboard: {
    title: 'My Chatbots',
    new: '+ New',
    empty_title: 'No chatbots yet',
    empty_desc: 'Create your first AI chatbot powered by your documents.',
    create_first: 'Create Chatbot',
    delete_title: 'Delete Chatbot',
    delete_confirm: (name: string) => `Delete "${name}"? This cannot be undone.`,
    edit: 'Edit',
    preview: 'Preview',
    publish: 'Publish',
    unpublish: 'Unpublish',
    docs: 'docs',
    chats: 'chats',
  },

  // Onboarding checklist
  onboarding: {
    title: 'Getting started',
    step_create: 'Create your first chatbot',
    step_docs: 'Add knowledge documents or URLs',
    step_publish: 'Publish your chatbot',
  },

  // Chatbot builder
  builder: {
    title_new: 'Chatbot Builder',
    title_edit: 'Chatbot Builder',
    tab_settings: 'Settings',
    tab_docs: 'Docs',
    tab_preview: 'Preview',
    tab_testing: 'Testing',
    tab_deploy: 'Deploy',
    save_first: 'Save the chatbot first.',
    save_first_preview: 'Save the chatbot first to preview it.',
    save_first_test: 'Save the chatbot first to run tests.',
    section_basic: 'Basic Info',
    name_label: 'Chatbot Name *',
    name_placeholder: 'My Support Bot',
    description_label: 'Description',
    description_placeholder: 'What does this chatbot do?',
    section_behavior: 'Behavior',
    system_prompt_label: 'System Prompt',
    system_prompt_placeholder: 'You are a helpful assistant...',
    section_model: 'AI Model',
    section_temperature: 'Temperature',
    temp_hint: '0 = focused, 1 = creative',
    section_appearance: 'Appearance',
    color_label: 'Primary Color',
    welcome_label: 'Welcome Message',
    section_classification: 'Classification',
    category_label: 'Category',
    section_advanced: 'Advanced',
    branding_label: 'Show Branding',
    branding_desc: "Display 'Powered by Contexta' in the chat widget",
    lead_label: 'Lead Capture',
    lead_desc: 'Collect visitor contact info during chats',
    handoff_label: 'Human Handoff',
    handoff_desc: 'Escalate conversations to a human agent',
    handoff_email_label: 'Handoff Email',
    save: 'Save Changes',
    create: 'Create Chatbot',
    saving: 'Saving...',
    // Templates
    template_title: 'Choose a template',
    template_skip: 'Start blank →',
    // Testing tab
    testing_title: 'Test Questions',
    testing_desc: 'Enter up to 10 questions to test how your chatbot responds.',
    testing_placeholder: 'Ask a question...',
    testing_add: '+ Add question',
    testing_run: '▶ Run Tests',
    testing_running: 'Running...',
    testing_results: (n: number) => `${n} RESULT${n !== 1 ? 'S' : ''}`,
    testing_sources: 'SOURCES',
    testing_model: 'Model',
    testing_error: 'Test failed. Make sure your chatbot has a knowledge base.',
  },

  // Documents
  documents: {
    title: 'Documents',
    add_url: 'Add URL',
    url_placeholder: 'https://...',
    upload: 'Upload Document',
    empty_title: 'No documents yet',
    empty_desc: 'Upload files or add URLs to build the knowledge base.',
    delete_title: 'Delete Document',
    delete_confirm: 'Remove this document from the knowledge base?',
    status_pending: 'Pending',
    status_processing: 'Processing...',
    status_completed: 'Ready',
    status_failed: 'Failed',
    chunks: (n: number) => `${n} chunks`,
    retry: 'Retry',
    url_sources: 'URL Sources',
    refreshing: 'Refreshing...',
  },

  // Deploy tab
  deploy: {
    publish_label: 'Published',
    publish_desc: 'Make this chatbot publicly accessible',
    chat_link: 'Public Chat Link',
    chat_link_desc: 'Share this link directly with anyone',
    copy: 'Copy',
    copied: 'Copied!',
    publish_first: 'Publish your chatbot to get a public link.',
    embed_title: 'Embed Code',
    embed_desc: 'Add the chat widget to any website',
    telegram_title: 'Telegram',
    telegram_connected: 'Connected',
    telegram_disconnect: 'Disconnect',
    telegram_token_placeholder: 'Bot token from @BotFather',
    telegram_connect: 'Connect',
    whatsapp_title: 'WhatsApp',
    whatsapp_keyword: 'Keyword (optional)',
    whatsapp_connect: 'Connect',
    section_lead: 'Lead Capture',
    section_handoff: 'Human Handoff',
    section_booking: 'Appointments',
    booking_enable: 'Enable appointment booking',
    booking_enable_sub: 'Chatbot will guide users to book appointments',
  },

  // Inbox
  inbox: {
    title: 'Inbox',
    filter_all: 'All',
    filter_open: 'Open',
    filter_handling: 'Handling',
    filter_resolved: 'Resolved',
    empty_title: 'No conversations',
    empty_desc: 'Conversations with your chatbots will appear here.',
    empty_filtered: (status: string) => `No ${status} conversations.`,
    no_messages: 'No messages yet',
    type_reply: 'Write a reply as agent...',
    send: 'Send',
    status_open: 'Open',
    status_agent: 'Handling',
    status_resolved: 'Resolved',
    take_over: 'Take over',
    resolve: 'Resolve',
    reopen: 'Reopen',
    delete: 'Delete',
    delete_confirm: 'Delete this conversation?',
  },

  // Leads
  leads: {
    title: 'Leads',
    subtitle: (n: number) => `${n} contact${n !== 1 ? 's' : ''} collected`,
    export: '⬆ Export',
    empty_title: 'No leads yet',
    empty_desc: 'Enable lead capture on your chatbots to collect visitor contact info.',
    no_export: 'There are no leads to export yet.',
    detail_title: 'Lead Details',
    contact_info: 'Contact Info',
    status_section: 'Status',
    notes_section: 'Notes',
    notes_placeholder: 'Add notes about this lead...',
    cancel: 'Cancel',
    save: 'Save',
    status_new: 'New',
    status_contacted: 'Contacted',
    status_qualified: 'Qualified',
    status_closed: 'Closed',
    status_lost: 'Lost',
    field_name: 'Name',
    field_email: 'Email',
    field_phone: 'Phone',
    field_company: 'Company',
    field_chatbot: 'Chatbot',
    field_date: 'Date',
  },

  // Analytics
  analytics: {
    title: 'Analytics',
    subtitle: 'Overview of your chatbot performance',
    conversations: 'Conversations',
    messages: 'Messages',
    chatbots: 'Chatbots',
    avg_conv: 'Avg / Conv',
    by_chatbot: 'By Chatbot',
    confidence: 'Confidence',
    empty_title: 'No data yet',
    empty_desc: 'Analytics will appear once your chatbots start receiving conversations.',
    unanswered: (n: number) => `${n} unanswered`,
    show_gaps: 'Show gaps ▼',
    hide_gaps: 'Hide ▲',
  },

  // Campaigns
  campaigns: {
    title: 'Campaigns',
    new: 'New Campaign',
    empty_title: 'No campaigns yet',
    empty_desc: 'Create a campaign to broadcast a message to all your Telegram subscribers at once.',
    select_chatbot: 'Select chatbot',
    campaign_name: 'Campaign Name',
    name_placeholder: 'e.g. Summer promo, New menu announcement...',
    message_label: 'Message',
    message_placeholder: 'Write your broadcast message here...',
    create: 'Create Campaign',
    send: 'Send',
    delete: 'Delete',
    send_confirm: (title: string, n: number) => `Send "${title}" to ${n} subscriber${n !== 1 ? 's' : ''}?`,
    send_warning: 'This cannot be undone. The message will be delivered immediately.',
    send_now: 'Send Now',
    cancel: 'Cancel',
    status_draft: 'Draft',
    status_sending: 'Sending...',
    status_sent: 'Sent',
    status_failed: 'Failed',
    subscribers: (n: number) => `${n} subscriber${n !== 1 ? 's' : ''}`,
    delivered: 'delivered',
  },

  // Appointments
  appointments: {
    title: 'Appointments',
    subtitle: 'Bookings made via your chatbots',
    empty_title: 'No appointments yet',
    empty_desc: 'Once customers book via your chatbot, appointments will appear here.',
    configure_hours: 'Configure Hours',
    save_hours: 'Save Hours',
    status_pending: 'Pending',
    status_confirmed: 'Confirmed',
    status_cancelled: 'Cancelled',
    status_completed: 'Completed',
    confirm: 'Confirm',
    decline: 'Decline',
    complete: 'Complete',
    cancel: 'Cancel',
    days: ['Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'],
    closed: 'Closed',
    open_from: 'Open from',
    to: 'to',
  },

  // Settings
  settings: {
    title: 'Settings',
    subscription: 'Subscription',
    reports: 'Reports',
    analytics: 'Analytics',
    leads: 'Leads',
    campaigns: 'Campaigns',
    appointments: 'Appointments',
    appearance: 'Appearance',
    theme_system: 'System',
    theme_light: 'Light',
    theme_dark: 'Dark',
    profile: 'Profile',
    company_label: 'Company / Team Name',
    company_placeholder: 'Acme Inc.',
    language_label: 'Language',
    change_password: 'Change Password',
    current_password: 'Current Password',
    new_password: 'New Password',
    save_profile: 'Save Profile',
    account: 'Account',
    sign_out: 'Sign Out',
    sign_out_confirm: 'Are you sure you want to sign out?',
    delete_account: 'Delete Account',
    delete_confirm: 'This will permanently delete your account and all chatbots. This cannot be undone.',
    renews: 'Renews',
    version: 'Contexta v1.0.0',
    profile_updated: 'Profile updated!',
    update_failed: 'Failed to update profile',
    company_required: 'Company name is required',
  },

  // Marketplace
  marketplace: {
    title: 'Marketplace',
    search_placeholder: 'Search chatbots...',
    empty_title: 'No chatbots found',
    empty_desc: 'Try adjusting your search or filters.',
    chat_now: 'Chat Now →',
    by: (name: string) => `by ${name}`,
    conversations: (n: number) => `${n} conversations`,
    rating: 'Your rating',
    rate_submit: 'Submit',
    login_to_rate: 'Sign in to rate',
  },

  // Guest screen
  guest: {
    sign_in: 'Sign In',
    sign_up: 'Create Account',
    or: 'or',
  },

  // Common
  common: {
    loading: 'Loading...',
    cancel: 'Cancel',
    delete: 'Delete',
    save: 'Save',
    close: 'Close',
    confirm: 'Confirm',
    retry: 'Retry',
    refresh: 'Refresh',
    error: 'Something went wrong. Please try again.',
  },
};

export type Translations = typeof en;
