// ============== DATA ==============

const PACKAGES = [
  { id: 'launchpad', tier: 'Establish', num: '01', name: 'Launchpad', tag: 'Starter Plan',
    blurb: 'For entrepreneurs taking their first step — from concept to company.',
    objective: 'Help founders establish a legally compliant, well-branded, and market-ready business foundation.',
    timeline: '3–4 weeks', featured: false,
    sections: [
      { title: 'Business Setup', items: ['Incorporation (Pvt Ltd / LLP / OPC / Partnership)', 'Legal documentation & ready-to-use templates', 'GST, PAN & business bank account setup', 'Basic business & financial strategy session'] },
      { title: 'Brand & Identity', items: ['Logo design & brand guidelines', 'Company profile & presentation design', 'Domain name & business email setup'] },
      { title: 'Product & Tech', items: ['MVP consultation & prototype planning', 'One-page website or landing page', 'Hosting setup & maintenance for 1 year'] },
    ],
  },
  { id: 'accelerator', tier: 'Scale', num: '02', name: 'Accelerator', tag: 'Growth Plan',
    blurb: 'For businesses ready to grow visibility, acquire customers, and expand faster.',
    objective: 'Boost marketing, lead generation and sales while optimising brand reach.',
    timeline: '6–8 weeks', featured: false,
    sections: [
      { title: 'Growth & Marketing', items: ['Brand positioning & differentiation', 'SEO setup (on-page, off-page, GMB)', 'Social media strategy & content calendar (3 platforms)', 'Performance marketing (Google / Meta)', 'Email marketing automation', 'CRM sales-funnel tracking'] },
      { title: 'Sales Enablement', items: ['Lead generation & data scraping (up to 500 leads)', 'Funnel mapping & conversion optimisation', 'Cold email & pitch scripts', 'Weekly sales analytics'] },
      { title: 'Content & Support', items: ['Blog writing (2/month × 2 months)', 'Monthly newsletter & automation', 'Dedicated account manager', 'Access to growth webinars'] },
    ],
  },
  { id: 'scale-manage', tier: 'Optimize', num: '03', name: 'Scale & Manage', tag: 'Premium Plan',
    blurb: 'For startups scaling rapidly and seeking end-to-end operational efficiency.',
    objective: 'Complete business management — from marketing to operations — so founders can focus on innovation.',
    timeline: 'Ongoing · 3-month minimum', featured: true,
    sections: [
      { title: 'Sales & Marketing Outsourcing', items: ['Dedicated marketing team', 'Full social media management', 'Paid ads execution & optimisation', 'Conversion tracking & ROI analysis', 'Influencer & PR support'] },
      { title: 'Operations & Management', items: ['Website & app management', 'Design & brand management', 'Finance & accounting assistance', 'Customer support outsourcing', 'HR & payroll management'] },
      { title: 'Analytics & Strategy', items: ['Monthly performance report', 'Process improvement consulting', 'Quarterly growth roadmap sessions', 'Exclusive mentorship (2–3 / quarter)', 'Conference room access (6 meetings / quarter)'] },
    ],
  },
  { id: 'branding', tier: 'Establish', num: '04', name: 'Branding & Identity', tag: 'Creative Plan',
    blurb: 'For businesses that need a polished, professional brand presence before going to market.',
    objective: 'Create a strong, memorable brand identity that increases trust, clarity and positioning.',
    timeline: '2–3 weeks', featured: false,
    sections: [
      { title: 'Brand Identity', items: ['Logo design (3 concepts + 2 revisions)', 'Full brand guidelines', 'Brand voice & messaging framework', 'Business card & stationery design'] },
      { title: 'Brand Assets', items: ['Social media branding kit (6 templates)', 'Brand-driven company profile (6 pages)', 'Pitch deck brand styling', 'Product packaging concept'] },
      { title: 'Digital & Perks', items: ['Launch-ready landing page branding', 'Visual asset library', 'Brand positioning consultation', 'Media kit (all formats)'] },
    ],
  },
  { id: 'tech', tier: 'Establish', num: '05', name: 'Tech Essentials', tag: 'Website & App Setup',
    blurb: 'For startups that need a functional digital presence without full product development.',
    objective: 'Build a fast, secure, modern website or basic app that communicates your value clearly.',
    timeline: '2–5 weeks', featured: false,
    sections: [
      { title: 'Website Development', items: ['5–7 section professional website', 'Responsive (desktop + mobile)', 'CMS integration (WordPress / Webflow / custom)', 'Basic SEO setup'] },
      { title: 'Technical Setup', items: ['Domain + hosting configuration', 'SSL setup', 'Email integration', 'Analytics (GA4 + Meta Pixel)'] },
      { title: 'Optional Add-ons', items: ['Blog setup', 'Appointment / booking system', 'Landing page for ads', 'Web-app / hybrid prototype'] },
    ],
  },
  { id: 'automation', tier: 'Scale', num: '06', name: 'Marketing Automation', tag: 'Systems Plan',
    blurb: 'For businesses that want to automate funnels, sales processes, and customer nurturing.',
    objective: 'Implement powerful automations that reduce manual work and increase lead conversions.',
    timeline: '2–4 weeks', featured: false,
    sections: [
      { title: 'Automation Setup', items: ['CRM setup (HubSpot / Zoho / Salesforce)', 'Email automation flows', 'WhatsApp automation', 'Lead capture & routing'] },
      { title: 'Integrations', items: ['Website forms → CRM', 'Ads → CRM tracking', 'Calendar → automated confirmations'] },
      { title: 'Optimisation & Support', items: ['Funnel analysis', 'Lead scoring setup', '1-month monitoring', 'Weekly reports & team training'] },
    ],
  },
  { id: 'investor', tier: 'Scale', num: '07', name: 'Investor Readiness', tag: 'Funding Plan',
    blurb: 'For startups preparing to pitch, raise funds, or join accelerators.',
    objective: 'Equip founders with the strategy, documents and financial clarity needed to secure investment.',
    timeline: '3–5 weeks', featured: false,
    sections: [
      { title: 'Pitch Essentials', items: ['Investor pitch deck (designed + structured)', 'Business plan (executive summary + GTM + ops)', 'Custom storytelling framework'] },
      { title: 'Financials', items: ['3-year projections', 'Unit economics', 'CAC / LTV modeling', 'Break-even analysis'] },
      { title: 'Investor Prep & Perks', items: ['Pitch rehearsal sessions', 'Q&A preparation', 'Introduction email templates', 'Access to investor events'] },
    ],
  },
];

const SERVICE_PILLARS = [
  { id: 'establish', num: '01', title: 'Establish', sub: 'Build your foundation.',
    desc: 'Turn a brilliant idea into a real, professional, investable business. We handle the critical first steps.',
    items: ['Legal & business establishment', 'Document templates library', 'Strategic consultancy', 'Brand identity & strategy', 'Financial & GST setup', 'MVP, website & app development', 'Initial HR & talent acquisition', 'Pitch deck creation'] },
  { id: 'scale', num: '02', title: 'Scale', sub: 'Find your customers.',
    desc: 'Accelerate reach, visibility and revenue through data-driven growth strategies that match your budget.',
    items: ['Digital marketing strategy', 'Performance marketing (PPC/SEM)', 'Content marketing & creation', 'Email marketing & automation', 'SEO boost', 'Public Relations & outreach', 'CRM implementation & management', 'Lead generation & market insights'] },
  { id: 'optimize', num: '03', title: 'Optimize', sub: 'Keep operations smooth.',
    desc: 'Once you grow, we manage daily tasks, tech and teams so you can focus on innovation, not fire-drills.',
    items: ['Outsourced sales teams', 'Outsourced design & marketing', 'Finance & bookkeeping services', 'Outsourced customer support', 'Website & app management', 'Cloud & IT infrastructure', 'Subscription management', 'Process improvement consulting'] },
];

const PROCESS = [
  { num: '01', name: 'Listen', when: 'Week 0', desc: 'A 60-minute consultation. We map your stage, your ask, and your constraints — no scripts, no slides.' },
  { num: '02', name: 'Scope', when: 'Week 1', desc: 'A written proposal: deliverables, timeline, the team you\'ll work with, and a fixed quote.' },
  { num: '03', name: 'Build', when: 'Weeks 2–N', desc: 'Weekly check-ins. Shared workspace. You see drafts before they\'re polished, not after.' },
  { num: '04', name: 'Launch', when: 'Final week', desc: 'Handoff with documentation — assets, credentials, training. Nothing locked behind us.' },
  { num: '05', name: 'Stay', when: 'Optional', desc: 'A retainer for whatever comes next — or a clean goodbye and standing offer to return.' },
];

const PARTNERS = [
  { name: 'Kalaari Studio', sector: 'D2C · Apparel' },
  { name: 'Banyan Labs', sector: 'SaaS · B2B' },
  { name: 'Monsoon Foods', sector: 'FMCG' },
  { name: 'Anvaya Legal', sector: 'Legal Tech' },
  { name: 'Aarohan EdTech', sector: 'Education' },
  { name: 'Saffron Health', sector: 'Digital Health' },
  { name: 'North Node Capital', sector: 'Venture' },
  { name: 'Marigold Kitchen', sector: 'F&B' },
  { name: 'Parallax Studio', sector: 'Design Agency' },
  { name: 'Tarang Audio', sector: 'Consumer Tech' },
  { name: 'Vitthal Logistics', sector: 'Supply Chain' },
  { name: 'Naksha Realty', sector: 'PropTech' },
];

const CASES = [
  { id: 'kalaari', glyph: 'K', name: 'Kalaari Studio', sector: 'D2C · Apparel', engagement: 'Scale & Manage',
    quote: 'We came in with a single store on Instagram. They built the brand, the site, the supply chain dashboard, and the team that runs it.',
    metrics: [['4.2×', 'Revenue (12 mo)'], ['9 → 47', 'Headcount']] },
  { id: 'banyan', glyph: 'B', name: 'Banyan Labs', sector: 'SaaS · B2B', engagement: 'Investor Readiness',
    quote: 'They re-cut our pitch in two weeks. The deck got us into a partner room we\'d been emailing for a year.',
    metrics: [['₹6.4 Cr', 'Seed raised'], ['11 wks', 'From scope to close']] },
  { id: 'monsoon', glyph: 'M', name: 'Monsoon Foods', sector: 'FMCG', engagement: 'Branding & Identity',
    quote: 'Identity, packaging, retailer kit, distributor portal — handed over in a clean folder. We just shipped.',
    metrics: [['380', 'SKUs reskinned'], ['12', 'New retailers signed']] },
  { id: 'aarohan', glyph: 'A', name: 'Aarohan EdTech', sector: 'Education', engagement: 'Marketing Automation',
    quote: 'Our funnel was a spreadsheet. They built the CRM, the flows, and the dashboards we still use every Monday.',
    metrics: [['62%', 'Lead → trial conv.'], ['11h', 'Saved per week']] },
  { id: 'saffron', glyph: 'S', name: 'Saffron Health', sector: 'Digital Health', engagement: 'Tech Essentials',
    quote: 'They shipped a HIPAA-grade telehealth MVP in 5 weeks. Our investors saw a working product on day one.',
    metrics: [['5 wks', 'MVP to live'], ['1,400', 'First-month patients']] },
];

const PERKS = [
  ['Partner Network', 'Exclusive discounts and preferred access to our vetted network of partner companies.'],
  ['Co-working & Hot Desks', 'Use our hot desks to get out of the house and be productive when you need to.'],
  ['Conference Rooms', 'Bookable, fully-equipped rooms to impress investors or hold team meetings.'],
  ['Workshops & Meetups', 'Private workshops on fundraising, marketing, sales — and a community of founders.'],
  ['Learning & Toolkits', 'Learning resources and startup toolkits to help you launch and scale efficiently.'],
];

window.PACKAGES = PACKAGES;
window.SERVICE_PILLARS = SERVICE_PILLARS;
window.PROCESS = PROCESS;
window.PARTNERS = PARTNERS;
window.CASES = CASES;
window.PERKS = PERKS;

// ============== HOOKS ==============

function useReveal() {
  React.useEffect(() => {
    const els = document.querySelectorAll('.reveal');
    if (!('IntersectionObserver' in window)) { els.forEach(e => e.classList.add('is-in')); return; }
    const io = new IntersectionObserver((entries) => {
      entries.forEach(e => { if (e.isIntersecting) { e.target.classList.add('is-in'); io.unobserve(e.target); } });
    }, { threshold: 0.12 });
    els.forEach(e => io.observe(e));
    return () => io.disconnect();
  }, []);
}

function useActiveSection(ids) {
  const [active, setActive] = React.useState(ids[0]);
  React.useEffect(() => {
    const onScroll = () => {
      const y = window.scrollY + 140;
      let cur = ids[0];
      for (const id of ids) {
        const el = document.getElementById(id);
        if (el && y >= el.offsetTop) cur = id;
      }
      setActive(cur);
    };
    onScroll();
    window.addEventListener('scroll', onScroll, { passive: true });
    return () => window.removeEventListener('scroll', onScroll);
  }, [ids.join(',')]);
  return active;
}

window.useReveal = useReveal;
window.useActiveSection = useActiveSection;
