// Use case catalog — single source of truth.
// Each entry: id, name, desc, tags (shown on card), components (what gets built),
// nameFields: [{ key, label, defaultFn(company) }]

const INDUSTRIES = [
  "Retail & Consumer Goods",
  "Banking & Financial Services",
  "Healthcare & Life Sciences",
  "Manufacturing & Industrial",
  "Technology & Software",
  "Professional Services",
  "Public Sector",
  "Transport & Logistics",
  "Energy & Utilities",
  "Hospitality & Leisure",
];

const HEADCOUNT = ["< 500", "500 – 2,000", "2,000 – 5,000", "5,000+"];
const LANGS = [
  { k: "DE", label: "German"  },
  { k: "EN", label: "English" },
  { k: "FR", label: "French"  },
];

const USE_CASES = [
  {
    id: "spontaneous",
    name: "Spontaneous Application",
    desc: "Capture walk-in applicants via a talent form.",
    tags: ["Talent Form", "Auto-reply", "CRM Tag"],
    video: "LAYz8yXlgws",
    components: [
      { k: "Talent Form",      t: "form",  d: "Public-facing form for spontaneous applicants" },
      { k: "Consent Screen",   t: "form",  d: "GDPR consent & policy linking" },
      { k: "Confirmation Page",t: "page",  d: "Thank-you page with next-step CTA" },
      { k: "CRM Tag",          t: "data",  d: "Auto-tag \"spontaneous\" on inbound records" },
      { k: "Email Notification",t:"email", d: "Recruiter notified on new application" },
    ],
    nameFields: [
      { key: "formName",  label: "Talent form name",    fn: c => `${c || "Acme"} – Spontaneous Applicants` },
      { key: "tagName",   label: "CRM tag",             fn: c => `${(c||"acme").toLowerCase().replace(/\s+/g,"-")}-spontaneous` },
    ],
  },
  {
    id: "general-referral",
    name: "General Referral",
    desc: "Full referral flow with CRM bridge.",
    tags: ["Referral Form", "CRM Bridge", "Reward Engine", "Convo UI"],
    video: "HLZZbRmeh6w",
    components: [
      { k: "Referral Landing",  t: "page",  d: "Branded landing for employees to refer" },
      { k: "Referral Form",     t: "form",  d: "Multi-step: referee + context + consent" },
      { k: "CRM Bridge",        t: "data",  d: "Sync referred candidates to ATS/CRM" },
      { k: "Reward Engine",     t: "logic", d: "Stage-based bonus tracking" },
      { k: "Convo UI",          t: "ui",    d: "Conversational intake for employees" },
      { k: "Status Dashboard",  t: "page",  d: "Referrer sees referral status live" },
    ],
    nameFields: [
      { key: "programName", label: "Referral program name", fn: c => `${c || "Acme"} Referrals` },
      { key: "rewardName",  label: "Default reward tier",   fn: c => `${c || "Acme"} Standard Bonus` },
    ],
  },
  {
    id: "referral",
    name: "Referral",
    desc: "Basic employee referral via Convo UI.",
    tags: ["Convo UI", "Referral Form"],
    components: [
      { k: "Convo UI",          t: "ui",    d: "Guided referral conversation" },
      { k: "Referral Form",     t: "form",  d: "Streamlined referee capture" },
      { k: "Confirmation Page", t: "page",  d: "Post-referral thank-you screen" },
    ],
    nameFields: [
      { key: "programName", label: "Referral program name", fn: c => `${c || "Acme"} Quick Referral` },
    ],
  },
  {
    id: "alumni",
    name: "Alumni",
    desc: "Re-engage former employees.",
    tags: ["Alumni Form", "Segment", "Newsletter"],
    video: "tqFZCm4QHyo",
    components: [
      { k: "Alumni Sign-up Form",t: "form",  d: "Let alumni join the talent pool" },
      { k: "Alumni Segment",     t: "data",  d: "CRM segment for outreach" },
      { k: "Re-engagement Email",t: "email", d: "Welcome-back email sequence" },
      { k: "Alumni Landing",     t: "page",  d: "Branded landing + opportunity feed" },
    ],
    nameFields: [
      { key: "poolName",   label: "Alumni pool name",    fn: c => `${c || "Acme"} Alumni Network` },
      { key: "segmentKey", label: "Segment key",         fn: c => `${(c||"acme").toLowerCase().replace(/\s+/g,"-")}-alumni` },
    ],
  },
  {
    id: "event",
    name: "Event",
    desc: "Capture and follow up with event attendees.",
    tags: ["Event Form", "QR Landing", "Follow-up Email"],
    video: "dUyg1WsCaZA",
    components: [
      { k: "Event Landing Page", t: "page",  d: "Branded event page w/ QR support" },
      { k: "Attendee Form",      t: "form",  d: "Quick capture at the booth" },
      { k: "Event Segment",      t: "data",  d: "Tag attendees per event" },
      { k: "Follow-up Email",    t: "email", d: "Post-event nurture message" },
    ],
    nameFields: [
      { key: "eventName", label: "Event name",  fn: c => `${c || "Acme"} Career Fair 2026` },
      { key: "segmentKey",label: "Event tag",   fn: c => `${(c||"acme").toLowerCase().replace(/\s+/g,"-")}-event-2026` },
    ],
  },
  {
    id: "internal-mobility",
    name: "Internal Mobility",
    desc: "Let employees apply to open roles.",
    tags: ["Internal Portal", "SSO", "Internal Tag"],
    video: "CpLowbBQLXU",
    components: [
      { k: "Internal Portal",    t: "page",  d: "Employee-only jobs board" },
      { k: "SSO Gate",           t: "auth",  d: "Only employees can browse/apply" },
      { k: "Internal Apply Form",t: "form",  d: "Pre-filled with employee profile" },
      { k: "Manager Notice",     t: "email", d: "Optional manager notification" },
    ],
    nameFields: [
      { key: "portalName", label: "Internal portal name", fn: c => `${c || "Acme"} Mobility` },
    ],
  },
  {
    id: "active-sourcing",
    name: "Active Sourcing",
    desc: "Automate outreach to browser-sourced talents.",
    tags: ["Sourcing Segment", "Outreach Sequence", "Chrome Ext."],
    video: "UxLEIgSvSuk",
    components: [
      { k: "Chrome Ext. Link", t: "tool",  d: "Connect Talentry Sourcer extension" },
      { k: "Sourcing Segment", t: "data",  d: "Segment for externally-sourced talent" },
      { k: "Outreach Sequence",t: "email", d: "Multi-touch recruiter outreach" },
      { k: "Reply Handler",    t: "logic", d: "Route replies to recruiter inbox" },
    ],
    nameFields: [
      { key: "sequenceName", label: "Sequence name",  fn: c => `${c || "Acme"} Sourcing Outreach` },
      { key: "segmentKey",   label: "Segment key",    fn: c => `${(c||"acme").toLowerCase().replace(/\s+/g,"-")}-sourced` },
    ],
  },
  {
    id: "silver-medallist",
    name: "Silver Medallist",
    desc: "Re-engage near-hire candidates.",
    tags: ["Segment", "Nurture Sequence"],
    video: "P2slwr01Yug",
    components: [
      { k: "Silver Segment",    t: "data",  d: "CRM segment for rejected finalists" },
      { k: "Nurture Sequence",  t: "email", d: "Timed re-engagement cadence" },
      { k: "Opt-in Form",       t: "form",  d: "Allow them to join the talent pool" },
    ],
    nameFields: [
      { key: "segmentName", label: "Segment name",    fn: c => `${c || "Acme"} Silver Medallists` },
      { key: "sequenceName",label: "Sequence name",   fn: c => `${c || "Acme"} Silver Nurture` },
    ],
  },
  {
    id: "stories",
    name: "Stories",
    desc: "Activate employer brand stories.",
    tags: ["Stories Module", "Story Templates", "Embed"],
    video: "g4RR-JXVe7s",
    components: [
      { k: "Stories Module",     t: "ui",   d: "Short-form employee story player" },
      { k: "Story Templates",    t: "ui",   d: "3 starter templates (video/quote/gallery)" },
      { k: "Embed Snippet",      t: "tool", d: "Drop-in code for career site" },
    ],
    nameFields: [
      { key: "collectionName", label: "Story collection name", fn: c => `${c || "Acme"} Voices` },
    ],
  },
  {
    id: "career-site",
    name: "Career Site",
    desc: "Full branded career site with job board.",
    tags: ["Coming Soon"],
    video: "2ui3CoaWJJY",
    soon: true,
    components: [],
    nameFields: [],
  },
  {
    id: "qualify-agent",
    name: "Qualify Agent",
    desc: "AI-driven candidate qualification.",
    tags: ["Coming Soon"],
    soon: true,
    components: [],
    nameFields: [],
  },
];

window.TB_DATA = { INDUSTRIES, HEADCOUNT, LANGS, USE_CASES };
