EXISTING GTM CRM — SOCIAL PAGES AND META ADS UPDATE

1. Back up your current CRM folder and database.
2. Copy the files in this ZIP into the existing CRM folder, preserving paths.
   No config.php, uploads, database dump, or SQL migration is included.
3. Sign in as Main Super Admin. Open API Integrations and save a Meta access
   token with ads_read and access to your ad accounts. Enable PHP cURL.
4. Social Pages > Meta Ad Accounts > Load Ad Accounts > select company and
   account > Map Ad Account > Sync Now. Reports are under Meta Ads.
   An account maps to one company. A shared account is not split by campaign.
5. Sync imports the last 7 days of campaign metrics. For recurring sync,
   schedule cron/meta_sync.php with PHP CLI on your host.
   Spend is in the Meta ad account currency.

Lead Ads is a separate setup. The existing webhook requires Meta App Secret,
verification token, an HTTPS callback, the Page's leadgen subscription and
lead retrieval permissions. Save the matching Facebook Page ID in Social
Pages. This update verifies incoming POST signatures. Test the existing
lead flow with a Meta test lead before relying on it.

This update uses token-based setup. Facebook Login/OAuth, ad-set/ad-level
reporting and lead form/team routing are not implemented here.
