# Digital Invitation — Frontend Specification ## 1. Purpose A responsive, mobile-first digital birthday invitation that reproduces the visual character of a physical invitation while adding an interactive RSVP flow. The application has two distinct experiences: ### Guest Experience A highly designed invitation served publicly at `/birthday/`, consisting of: 1. **Invitation hero**: Fixed-aspect-ratio vertical composition with animated golden bokeh particles, title, honoree, date/time, and RSVP call-to-action 2. **RSVP form**: Name, phone, and optional email fields matching the invitation's visual world 3. **Submission feedback**: Explicit semantic feedback (Success, Duplicate, Error) 4. **Event reminder & logistics**: Countdown timer to the event, circular map preview, venue details, and navigation link ### Admin Experience A simple dashboard served at `/birthday/admin` (Authelia-protected) allowing the event organizer to: 1. View invitee responses in a searchable table 2. Monitor response count 3. Export responses as CSV 4. Edit invitation copy and event logistics via a form with live text preview The guest experience is the primary design focus. The admin dashboard deliberately does **not** use the invitation's visual effects. --- ## 2. Design Principles ### 2.1 The Invitation is a Physical Object (Section-Based Composition) The invitation hero maintains a fixed vertical aspect ratio (9:16) regardless of viewport width. The browser provides a responsive **stage** around it on wider screens. The page itself is a scrollable viewport composed of discrete sections: ```text PAGE (Scrollable Viewport) │ ├── Invitation Hero Section (Fixed vertical aspect ratio, desktop stage) │ ├── RSVP Section (Revealed via CTA click, matching visual world) │ └── Confirmation Section (Replaces RSVP on success; countdown + logistics) ``` The invitation hero itself is **not** an overflow-scrolling container. The page scrolls smoothly across these visual sections, maintaining balanced compositions within each viewport. ```text Desktop Stage ┌────────────────────────────────────────────┐ │ │ │ ┌──────────────────┐ │ │ │ │ │ │ │ INVITATION │ (9:16 card) │ │ │ HERO │ │ │ │ │ │ │ └──────────────────┘ │ │ │ └────────────────────────────────────────────┘ ``` On mobile, the section expands to occupy the available width while preserving vertical proportions. --- ### 2.2 One Visual Composition There are not separate mobile and desktop invitation designs. The visual card scales responsively within the viewport. Desktop provides surrounding staging; mobile provides full viewport width to the invitation. --- ### 2.3 Decoration Must Not Interfere with Information The animated particle background is subordinate to content: - Particles concentrate toward upper-left and lower-right corners - The central content area remains substantially darker and sparse - Movement is extremely slow (ambient life, not spectacle) - Particles vary in radius, opacity, and soft golden blur - Never compromises text readability --- ### 2.4 The RSVP Interaction is Part of the Invitation The RSVP form and confirmation states inherit the invitation's visual identity: - Dark background (`#0a0a0a`) - Golden accents (`#d4a843`, `#f0d68a`) - Typography system - Ambient particle canvas spanning the entire page behind all sections --- ### 2.5 Content is Configuration, Not Code Event-specific copy is never hardcoded in presentation components: - Fetched on load from `GET /birthday/api/config` - Admin can modify event details dynamically without rebuilding the frontend --- ### 2.6 Explicit Configuration Loading & Error States Before rendering the invitation, the frontend manages configuration lifecycle explicitly: ```text CONFIG_LOADING │ ├── success ──────→ INVITATION │ └── failure/error ─→ CONFIG_ERROR ``` If the API fails to load or returns invalid data: - Renders a graceful fallback: > **No pudimos cargar la invitación.** > Inténtalo nuevamente. - Includes a retry button - Never exposes broken components or undefined text values to the guest --- ### 2.7 Typography System (Self-Hosted) The design contrasts an organic handwritten script with a clean geometric sans-serif: - **Display Script**: Configurable script font (candidates: Great Vibes, Alex Brush, Sacramento, Allison, Whisper) used for "Birthday Party" and the honoree name - **Body & Metadata**: Montserrat (weights 300, 400, 500, 600, 700) with generous letter-spacing for dates, labels, and copy - **Self-Hosted Invariant**: All web fonts are bundled and served from `/birthday/fonts/` (WOFF2 format) to ensure deterministic rendering and zero third-party CDN dependencies --- ## 3. Guest Experience Lifecycle ```text PAGE LOAD │ ▼ CONFIG_LOADING │ │ fail │ │ success ▼ ▼ CONFIG_ERROR INVITATION HERO │ CTA click (smooth scroll) │ ▼ RSVP FORM │ submit │ ▼ SUBMITTING │ ┌───────────────┼───────────────┐ │ │ │ ▼ ▼ ▼ SUCCESS DUPLICATE ERROR │ │ │ ▼ ▼ ▼ CONFIRMATION "¡UPS!" "ALGO SALIÓ & COUNTDOWN (duplicate) MAL" │ │ ▼ ▼ MAP & LOGISTICS (retry) ``` --- ## 4. State 1 — Invitation Hero Displays the invitation cover in a centered 9:16 stage: ```text ┌─────────────────────────────┐ │ │ │ Birthday Party │ ← Display Script │ │ │ YOU'RE INVITED TO THE │ ← Montserrat, tracked │ BIRTHDAY PARTY HONORING │ │ │ │ Isabelle Snow │ ← Display Script │ │ │ OCT 7:00 PM │ ← Montserrat, 500 │ 28 FRIDAY │ │ │ │ │ │ CONFIRMA TU ASISTENCIA │ ← CTA Button │ ↓ │ │ │ └─────────────────────────────┘ ``` The address is intentionally omitted from the hero to focus attention on the RSVP action. --- ## 5. RSVP Call-To-Action (CTA) Default copy: > **CONFIRMA TU ASISTENCIA** > ↓ Interaction: - Click or keyboard activation smoothly scrolls the viewport to the RSVP section - Focus is moved to the first input field - Fully keyboard accessible (`