# Léyo SEO — Hands-Off Automation

Monitor-only dashboard. No clicks required for normal operation.

**Rule of Three:** 3 rivals per product line per city (Leicester, London, Birmingham, Manchester) — see `data/settings.json` → `competitor_categories`.

## URLs

| What | URL |
|------|-----|
| **Home hub (start here)** | https://srv1677041.hstgr.cloud/seo-leyo/ |
| Command Center | https://srv1677041.hstgr.cloud/seo-leyo/dashboard.php |
| Live Léyo site | https://srv1677041.hstgr.cloud/leyo/ |
| Public SEO marketing | https://srv1677041.hstgr.cloud/leyo/seo/ |
| Artifis SEO hub (related) | https://srv1677041.hstgr.cloud/seo/ |
| Cron log | `/var/www/html/seo-leyo/logs/cron.log` on Hostinger |

## Cron schedule (root crontab)

| When | Command | What happens |
|------|---------|--------------|
| Every hour at :00 | `seo-leyo/cron.php?mode=hourly` | Google Trends → merge keywords → generate meta → deploy to `leyo/index.php` |
| Every 6 hours at :30 | `seo-leyo/cron.php?mode=sniff` | Crawl 58 competitor creative-agency sites (32 categories × 3) → merge phrases |
| Daily 07:00 UTC | `seo-leyo/cron.php?mode=daily` | Sniff + generate + deploy (backup pass without Trends) |

Install: `bash scripts/hostinger/setup-seo-leyo-cron.sh`

## Pipeline

1. **Competitor sniff** — branding, web, photo, print, livery rivals in 4 cities.
2. **Google Trends** — UK rising searches for design/photography seed terms.
3. **Generate meta** — title, description, keywords + invisible JSON-LD head block.
4. **Deploy** — updates live `leyo/index.php`; bumps `leyo/sitemap.xml` lastmod if present.

Deploy target is **locked to live** in `data/settings.json`.

## Manual test

```bash
curl -fsS "https://srv1677041.hstgr.cloud/seo-leyo/cron.php?mode=sniff"
curl -fsS "https://srv1677041.hstgr.cloud/seo-leyo/cron.php?mode=hourly"
grep SEO_DEPLOYED_AT /var/www/html/leyo/index.php
```

## Credentials

Set on server only (not in git): `SEO_LEYO_DASHBOARD_PASSWORD`, optional SMTP vars — see `.env.example`.
