## TECHSPECS.md

### Platform Overview
A self-service ticketing platform under the brand **Black Canyon Tickets**, running at `portal.blackcanyontickets.com`, designed for upscale venues. Built for high-end events such as dance performances, weddings, and galas.

---

### Tech Stack
- **Frontend:** Astro (with islands of React if needed)
- **Auth & DB:** Supabase (PostgreSQL + Supabase Auth)
- **Payments:** Stripe + Stripe Connect (for automated payouts and platform fees)
- **QR Scanning:** Mobile-friendly browser-based scanner
- **Emails:** Resend or Supabase SMTP templates
- **Hosting:** Self-hosted on Tyler's infrastructure, served from subdomain

---

### Key Routes & Functions

#### Public
- `/e/[event-slug]` – Hosted ticket checkout page (embeddable)
- `/scan` – QR scanning interface for door staff (auth required)

#### Organizer Portal
- `/login` – Supabase Auth
- `/dashboard` – List of events and revenue summary
- `/events/new` – Event + ticket builder
- `/events/[id]/edit` – Update event/tickets
- `/events/[id]/sales` – Reporting & CSV export

---

### Database Tables
- `users`: id, email, name, organization_id
- `organizations`: id, name, logo, stripe_account_id
- `events`: id, title, slug, venue, start_time, created_by
- `tickets`: id, event_id, uuid, price, purchaser_email, checked_in, scanned_at
- `payouts`: id, event_id, gross, fee, net, stripe_transfer_id

---

### Stripe Logic
- Organizer connects Stripe via Connect onboarding
- On each ticket sale:
  - Buyer is charged via Stripe Checkout
  - Platform fee is split off
  - Remainder is sent to connected account
- Payouts tracked and displayed in dashboard

---

## COPYBANK.md

### Platform Taglines
- "Elegant ticketing for mountain-town events."
- "Built for Aspen. Ready for your venue."
- "Where your guests reserve their seat in style."

---

### Organizer Value Props
- Self-serve ticket builder — launch events in minutes
- QR code scanning on your phone, no app required
- Real-time sales dashboard + CSV export
- Embedded checkout with your brand
- Automated payouts with Stripe

---

### Buyer-Facing Messaging
- "Get your tickets to [Event Name] — delivered instantly with QR entry."
- "Reserve your seat now. No fees, no fuss."
- "Your ticket includes mobile check-in. Just show your phone at the door."

---

### Email Copy Templates
- **Ticket Confirmation:**
  - Subject: "Your ticket to [Event Name]"
  - Body: "Thanks for your purchase! Your ticket and QR code are below."

- **Event Reminder:**
  - Subject: "Coming up: [Event Name] at [Venue]"
  - Body: "Doors open at [Time]. Your ticket is attached."

---

## ROADMAP.md

### Phase 1 – Demo MVP (July 2025)
- [x] Astro frontend scaffold
- [x] Supabase project setup
- [x] Auth + RLS by organizer ID
- [x] Event + ticket schema
- [x] Checkout route
- [x] QR ticket issuing + scanning
- [ ] Stripe Connect integration
- [ ] Organizer dashboard (basic stats + CSV)
- [ ] Embed script / shareable URL

### Phase 2 – White-Label Deployments (Aug 2025)
- [ ] Multiple venues support
- [ ] Organizer branding per event
- [ ] Embed styling toolkit
- [ ] Stripe fee config per org
- [ ] Reminder + confirmation email triggers

### Phase 3 – Admin + Compliance
- [ ] Admin view for platform owner (Tyler)
- [ ] Payout logs and fee summaries
- [ ] Manual override / refunds
- [ ] Event review + approval (optional)
- [ ] Ticket cap enforcement + waitlist

---

> Final target: Run full Aspen events calendar 2025-26 under Black Canyon Tickets with minimal manual involvement. White-label ticketing made effortless for upscale venues.

