// Mock data shared across the app

const websites = [
  {
    id: "winforlife88",
    name: "WINFORLIFE88",
    domain: "winforlife88.com",
    initials: "WFL",
    color: "#A6F84A",
    accent: "from-lime-400 to-emerald-500",
    team: "Tier 1 · Manila",
    online: true,
    activeChats: 14,
    waiting: 3,
    allowed: ["winforlife88.com", "play.winforlife88.com", "promo.winforlife88.com"],
  },
  {
    id: "affiliate-hub",
    name: "Affiliate Hub PH",
    domain: "affiliatehubph.com",
    initials: "AH",
    color: "#7AB6FF",
    accent: "from-sky-400 to-indigo-500",
    team: "Partners · Cebu",
    online: true,
    activeChats: 6,
    waiting: 1,
    allowed: ["affiliatehubph.com", "dashboard.affiliatehubph.com"],
  },
  {
    id: "tripai",
    name: "TripAI PH",
    domain: "tripai.ph",
    initials: "TA",
    color: "#FF9DD2",
    accent: "from-fuchsia-400 to-rose-500",
    team: "Beta crew",
    online: false,
    activeChats: 2,
    waiting: 0,
    allowed: ["tripai.ph", "app.tripai.ph"],
  },
];

const agents = [
  { id: "angelo", name: "CS Angelo", email: "angelo@loop.cs", role: "Senior CSR", avatar: "AN", color: "#A6F84A", status: "online", websites: ["winforlife88","affiliate-hub"], chats: 142, csat: 4.9, avg: "32s" },
  { id: "mika", name: "CS Mika", email: "mika@loop.cs", role: "CSR · Tier 2", avatar: "MK", color: "#7AB6FF", status: "online", websites: ["winforlife88","tripai"], chats: 118, csat: 4.8, avg: "41s" },
  { id: "admin", name: "Admin", email: "admin@loop.cs", role: "Admin", avatar: "AD", color: "#FF9DD2", status: "away", websites: ["winforlife88","affiliate-hub","tripai"], chats: 64, csat: 4.7, avg: "1m 02s" },
  { id: "joy", name: "CS Joy", email: "joy@loop.cs", role: "CSR · Tier 1", avatar: "JY", color: "#FFD37A", status: "online", websites: ["affiliate-hub"], chats: 91, csat: 4.6, avg: "48s" },
  { id: "kai", name: "CS Kai", email: "kai@loop.cs", role: "CSR · Tier 1", avatar: "KA", color: "#C7B6FF", status: "offline", websites: ["tripai"], chats: 47, csat: 4.5, avg: "1m 18s" },
];

const concerns = [
  { id: "cashio", label: "Cash In / Cash Out", icon: "Wallet", tint: "#A6F84A" },
  { id: "account", label: "Account Concern", icon: "Shield", tint: "#7AB6FF" },
  { id: "gaming", label: "Gaming Concern", icon: "Game", tint: "#FF9DD2" },
  { id: "kyc", label: "KYC Verification", icon: "Id", tint: "#FFD37A" },
  { id: "others", label: "Others", icon: "Help", tint: "#C7B6FF" },
];

const conversations = [
  {
    id: "c1",
    visitor: "Marisol Cruz",
    username: "@mari_2k",
    initials: "MC",
    color: "#A6F84A",
    site: "winforlife88",
    concern: "cashio",
    status: "active",
    page: "/cashier/withdraw",
    last: "Pending pa po yung withdrawal ko since 2pm.",
    unread: 2,
    minutes: 3,
    tags: ["VIP", "Returning"],
    messages: [
      { who: "v", t: "Hi po, gusto ko sana itanong yung withdrawal ko." },
      { who: "v", t: "Pending pa po yung withdrawal ko since 2pm." },
      { who: "a", t: "Hello Marisol! Tinitignan ko po yung transaction mo ngayon. Bigyan mo ako ng 1 minute." },
      { who: "v", t: "Sige po, salamat." },
    ],
  },
  {
    id: "c2",
    visitor: "Jericho Lim",
    username: "@jer_lim",
    initials: "JL",
    color: "#7AB6FF",
    site: "winforlife88",
    concern: "account",
    status: "waiting",
    page: "/login",
    last: "Locked po yung account ko after 3 attempts.",
    unread: 1,
    minutes: 1,
    tags: ["Lockout"],
    messages: [
      { who: "v", t: "Hi po, locked yung account ko." },
      { who: "v", t: "Locked po yung account ko after 3 attempts." },
    ],
  },
  {
    id: "c3",
    visitor: "Aya Ramirez",
    username: "@ayar",
    initials: "AR",
    color: "#FF9DD2",
    site: "tripai",
    concern: "others",
    status: "active",
    page: "/itineraries/seoul-5d",
    last: "Pwede ba i-share yung itinerary sa group?",
    unread: 0,
    minutes: 12,
    tags: ["Beta"],
    messages: [
      { who: "v", t: "Pwede ba i-share yung itinerary sa group?" },
      { who: "a", t: "Yes po Aya! Nasa share button sa kanan tuktok." },
    ],
  },
  {
    id: "c4",
    visitor: "Diego Pascual",
    username: "@dpasq",
    initials: "DP",
    color: "#FFD37A",
    site: "affiliate-hub",
    concern: "kyc",
    status: "waiting",
    page: "/kyc/upload",
    last: "Anong file format po sa government ID?",
    unread: 1,
    minutes: 6,
    tags: ["New"],
    messages: [
      { who: "v", t: "Anong file format po sa government ID?" },
    ],
  },
  {
    id: "c5",
    visitor: "Patricia Tan",
    username: "@pat_t",
    initials: "PT",
    color: "#C7B6FF",
    site: "winforlife88",
    concern: "gaming",
    status: "active",
    page: "/games/pearl-fortune",
    last: "Crash ng laro pagkapagspin ng 5x.",
    unread: 0,
    minutes: 22,
    tags: ["Bug"],
    messages: [
      { who: "v", t: "Crash ng laro pagkapagspin ng 5x." },
      { who: "a", t: "Sorry po Patricia. Nilipat ko na sa engineering. Refund 100 chips na po." },
      { who: "v", t: "Salamat!" },
    ],
  },
  {
    id: "c6",
    visitor: "Noel Aguilar",
    username: "@noeli",
    initials: "NA",
    color: "#A6F84A",
    site: "affiliate-hub",
    concern: "cashio",
    status: "closed",
    page: "/payouts",
    last: "Resolved · payout released.",
    unread: 0,
    minutes: 90,
    tags: ["Resolved"],
    messages: [
      { who: "v", t: "Wala pa rin yung payout ko nung Friday." },
      { who: "a", t: "Inilabas na po. Sorry sa abala!" },
      { who: "v", t: "Thanks!" },
    ],
  },
];

const cannedResponses = [
  { id: "r1", title: "Greeting · Tagalog", shortcut: "/hello", body: "Hi po! Salamat sa pag-message sa amin. Paano po kita matutulungan ngayon?" },
  { id: "r2", title: "Withdrawal SLA", shortcut: "/wd-sla", body: "Withdrawals are processed within 5–15 minutes. May ipo-process pa lang po kami sa account mo." },
  { id: "r3", title: "KYC Documents", shortcut: "/kyc-docs", body: "For KYC, kakailanganin po namin: 1 valid government ID, selfie holding the ID, at proof of address (utility bill, less than 3 months old)." },
  { id: "r4", title: "Closing · Thanks", shortcut: "/bye", body: "Salamat po sa inyong pagtitiwala. May iba pa po ba kayong tatanungin?" },
  { id: "r5", title: "Escalation · Engineering", shortcut: "/esc-eng", body: "Ie-escalate ko po ito sa engineering team namin. Babalikan ka namin sa loob ng 24 hours via email." },
  { id: "r6", title: "VIP Welcome", shortcut: "/vip", body: "Hello {name}! Welcome to our priority support. Bigyan natin yan ng white-glove treatment." },
];

const navItems = [
  { id: "overview", label: "Overview", icon: "Home" },
  { id: "conversations", label: "Conversations", icon: "Chat" },
  { id: "messenger", label: "Messenger", icon: "Messenger" },
  { id: "websites", label: "Websites", icon: "Globe" },
  { id: "agents", label: "Agents", icon: "Users" },
  { id: "canned", label: "Canned Responses", icon: "Bookmark" },
  { id: "analytics", label: "Analytics", icon: "Chart" },
  { id: "settings", label: "Settings", icon: "Settings" },
  { id: "admin", label: "Admin", icon: "Shield" },
];

const overviewStats = [
  { id: "active", label: "Active chats", value: 22, delta: "+8%", trend: "up", icon: "Chat", tint: "#A6F84A" },
  { id: "waiting", label: "Waiting users", value: 4, delta: "−2", trend: "down", icon: "Bell", tint: "#FFD37A" },
  { id: "online", label: "Online agents", value: "3 / 5", delta: "All hands", trend: "flat", icon: "Headset", tint: "#7AB6FF" },
  { id: "websites", label: "Total websites", value: 3, delta: "Active", trend: "flat", icon: "Globe", tint: "#FF9DD2" },
  { id: "avg", label: "Avg response", value: "38s", delta: "−6s", trend: "up", icon: "Bolt", tint: "#C7B6FF" },
];

window.Mock = { websites, agents, concerns, conversations, cannedResponses, navItems, overviewStats };
