Master Overhaul — 2026-05-03
docs/superpowers/plans/2026-05-03-master-overhaul.md · 6.2K
# Master Overhaul — 2026-05-03
> Single source of truth for the full Carrot overhaul: landing redesign, mobile feature completion, admin portal, SQL prep.
> All decisions confirmed by Tim (auto-mode go on 2026-05-03).
## Goals (in priority order)
1. **Landing page** — full redesign. Editorial-magazine-meets-indie-SaaS. Unique, opinionated, anti-AI. Live interactive demo. EN + DE i18n preserved. Brand orange `#FA7000` preserved. Goal-first positioning preserved.
2. **SQL migrations** — 9 migrations + seed.sql in `supabase/migrations/` ready to run when Supabase project exists. Strict RLS. pg_cron jobs. Idempotent.
3. **Manual type stubs** — `packages/shared/src/database.types.ts` written by hand, replaced by `npm run db:types` later.
4. **Admin portal** (`apps/admin/`) — Next.js 16 + Tailwind 4 + Cloudflare Workers via OpenNext + Lucide + Framer Motion + Recharts. Cloudflare Access for the 3 admin logins. 9 sections. Knowledge-base reads `.md` from repo at build time.
5. **Mobile plans 2-7** — written as detailed plan-files. Plan 2 (onboarding) implemented in this session if context allows; remainder executed in subsequent sessions.
6. **Web export** for mobile app — `npx expo export --platform web` → second CF Pages project.
## Decisions (locked)
| Topic | Decision |
|---|---|
| Domains | All `*.pages.dev` until Tim buys subdomains |
| PR strategy | One PR per area, branched from `main` |
| Co-author lines | None — no Claude attribution in commits |
| Auth (admin) | Cloudflare Access (free tier, email OTP, 3 admin emails whitelisted) |
| Auth (mobile, future) | Supabase Auth — Email + Apple + Google |
| Database | Supabase EU/Frankfurt — created later when Tim upgrades to Pro plan or pauses one of Light/Nutrition |
| Mock-data realism | German names (Anna, Max, Sarah, Lukas, Hannah…), realistic completion patterns, color-hash avatars |
| Visual direction (landing) | Editorial sport-magazine + indie SaaS hybrid. Bold display type, asymmetric grids, scroll-driven reveals, real screenshots, anti-AI |
| Typography (landing) | Bricolage Grotesque + DM Sans + JetBrains Mono accent |
| Languages | Landing: EN + DE. Admin: DE-only. Mobile: DE-only for now (EN follows post-launch) |
| Sub-domain plan | `carrot-landing.pages.dev` (live), `carrot-app.pages.dev` (planned), `carrot-admin.pages.dev` (planned) → `carrot.at`, `app.carrot.at`, `admin.carrot.at` post-purchase |
## File map of changes
```
apps/
web/ ⟶ FULL REWRITE (landing redesign)
src/
components/ ⟶ multiple new files, replace LandingPage.astro
i18n/translations.ts ⟶ rewritten copy + new keys for new sections
layouts/Layout.astro ⟶ updated fonts + global CSS + view-transitions
pages/ ⟶ index.astro + de/index.astro updated
styles/ ⟶ NEW: shared scss-like CSS modules per section
lib/ ⟶ NEW: live demo island JS + intersection helper
public/
og-image.png ⟶ NEW
favicon.svg ⟶ NEW
admin/ ⟶ NEW PROJECT
src/
app/
(dashboard)/ ⟶ KPI dashboard
users/ ⟶ user list
waitlist/ ⟶ waitlist signups
squads/ ⟶ squad list
content/ ⟶ goal-presets, habit-templates, badges
knowledge/ ⟶ docs viewer (md from repo)
infrastructure/ ⟶ status cards
design-system/ ⟶ tokens visualization
settings/ ⟶ admin user mgmt stub
layout.tsx
components/ ⟶ Sidebar, Topbar, Cards, Tables
lib/ ⟶ docs reader, mock data, supabase stub
package.json
next.config.ts
open-next.config.ts
wrangler.toml
tailwind.config.ts (postcss config)
tsconfig.json
mobile/
package.json ⟶ + build:web script
app/ ⟶ + onboarding/, + goal/, + challenge/, + bet/, + duel/
components/ ⟶ ~30 new
providers/ ⟶ + GoalProvider, SquadProvider, GamificationProvider, NotificationProvider
lib/ ⟶ + achievements.ts, + notifications.ts (mock)
supabase/
migrations/
0001_profiles.sql
0002_goals.sql
0003_habits.sql
0004_xp_system.sql
0005_badges.sql
0006_squads.sql
0007_squad_features.sql
0008_waitlist.sql
0009_cron_jobs.sql
seed.sql ⟶ dev seed data
packages/
shared/src/database.types.ts ⟶ rewritten manual stub matching migrations
docs/superpowers/plans/
2026-05-03-master-overhaul.md (this file)
2026-05-03-landing-redesign.md
2026-05-03-admin-portal.md
2026-05-03-mobile-plan-2-onboarding.md
2026-05-03-mobile-plan-3-goal-detail.md
2026-05-03-mobile-plan-4-progress.md
2026-05-03-mobile-plan-5-squad.md
2026-05-03-mobile-plan-6-profile.md
2026-05-03-mobile-plan-7-polish-web.md
```
## Execution order
1. **Setup (this session):**
- Master plan doc (this file) ✓
- SQL migrations 0001-0009 + seed.sql
- Manual type stubs
- Mobile plan-specs 2-7 written
- Landing redesign — start
- Admin portal — boilerplate (Next 16 scaffold, layout, sidebar, one section live)
2. **Subsequent sessions:**
- Landing redesign — finish all 8 sections + animations + live demo
- Admin portal — fill all 9 sections with mock data + charts
- Mobile plan 2-7 — execute one per session
- Final polish + README sync + Squad subscription mention
## Verification
- `npm run typecheck` after every plan-step
- `npm run build` for `apps/web` after landing changes
- `npm run build` for `apps/admin` after each admin section
- Visual verification via Playwright MCP for landing + admin
- Tim runs the mobile app on device; reports back
## Notes
- Supabase project not yet created. All migrations are Postgres SQL ready to apply with `supabase db push` once the project exists.
- Admin's user-list, waitlist, and squad sections all read from `lib/mock-data.ts` until Supabase is connected — the data layer is interface-first so swapping is one file change.
- Mobile app stays AsyncStorage-only across all of plan 2-7. Supabase wiring is a separate plan after all UI is locked.