Frontend Studio
Build complete, production-ready frontend pages by orchestrating 5 specialized capabilities: design engineering, motion systems, AI-generated assets, persuasive copy, and generative art.
Invocation
/frontend-dev <request>
The user provides their request as natural language (e.g. "build a landing page for a music streaming app").
Skill Structure
frontend-dev/
├── SKILL.md # Core skill (this file)
├── scripts/ # Asset generation scripts
│ ├── minimax_tts.py # Text-to-speech
│ ├── minimax_music.py # Music generation
│ ├── minimax_video.py # Video generation (async)
│ └── minimax_image.py # Image generation
├── references/ # Detailed guides (read as needed)
│ ├── minimax-cli-reference.md # CLI flags quick reference
│ ├── asset-prompt-guide.md # Asset prompt engineering rules
│ ├── minimax-tts-guide.md # TTS usage & voices
│ ├── minimax-music-guide.md # Music prompts & lyrics format
│ ├── minimax-video-guide.md # Camera commands & models
│ ├── minimax-image-guide.md # Ratios & batch generation
│ ├── minimax-voice-catalog.md # All voice IDs
│ ├── motion-recipes.md # Animation code snippets
│ ├── env-setup.md # Environment setup
│ └── troubleshooting.md # Common issues
├── templates/ # Visual art templates
│ ├── viewer.html # p5.js interactive art base
│ └── generator_template.js # p5.js code reference
└── canvas-fonts/ # Static art fonts (TTF + licenses)
Project Structure
Assets (Universal)
All frameworks use the same asset organization:
assets/
├── images/
│ ├── hero-landing-1710xxx.webp
│ ├── icon-feature-01.webp
│ └── bg-pattern.svg
├── videos/
│ ├── hero-bg-1710xxx.mp4
│ └── demo-preview.mp4
└── audio/
├── bgm-ambient-1710xxx.mp3
└── tts-intro-1710xxx.mp3
Asset naming: {type}-{descriptor}-{timestamp}.{ext}
By Framework
| Framework |
Asset Location |
Component Location |
| Pure HTML |
./assets/ |
N/A (inline or ./js/) |
| React/Next.js |
public/assets/ |
src/components/ |
| Vue/Nuxt |
public/assets/ |
src/components/ |
| Svelte/SvelteKit |
static/assets/ |
src/lib/components/ |
| Astro |
public/assets/ |
src/components/ |
Pure HTML
project/
├── index.html
├── assets/
│ ├── images/
│ ├── videos/
│ └── audio/
├── css/
│ └── styles.css
└── js/
└── main.js # Animations (GSAP/vanilla)
React / Next.js
project/
├── public/assets/ # Static assets
├── src/
│ ├── components/
│ │ ├── ui/ # Button, Card, Input
│ │ ├── sections/ # Hero, Features, CTA
│ │ └── motion/ # RevealSection, StaggerGrid
│ ├── lib/
│ ├── styles/
│ └── app/ # Pages
└── package.json
Vue / Nuxt
project/
├── public/assets/
├── src/ # or root for Nuxt
│ ├── components/
│ │ ├── ui/
│ │ ├── sections/
│ │ └── motion/
│ ├── composables/ # Shared logic
│ ├── pages/
│ └── assets/ # Processed assets (optional)
└── package.json
Astro
project/
├── public/assets/
├── src/
│ ├── components/ # .astro, .tsx, .vue, .svelte
│ ├── layouts/
│ ├── pages/
│ └── styles/
└── package.json
Component naming: PascalCase (HeroSection.tsx, HeroSection.vue, HeroSection.astro)
Compliance
All rules in this skill are mandatory. Violating any rule is a blocking error — fix before proceeding or delivering.
Workflow
Phase 1: Design Architecture
- Analyze the request — determine page type and context
- Set design dials based on page type
- Plan layout sections and identify asset needs
Phase 2: Motion Architecture
- Select animation tools per section (see Tool Selection Matrix)
- Plan motion sequences following performance guardrails
Phase 3: Asset Generation
Generate all image/video/audio assets using scripts/. NEVER use placeholder URLs (unsplash, picsum, placeholder.com, via.placeholder, placehold.co, etc.) or external URLs.
- Parse asset requirements (type, style, spec, usage)
- Craft optimized prompts, show to user, confirm before generating
- Execute via scripts, save to project — do NOT proceed to Phase 5 until all assets are saved locally
Phase 4: Copywriting & Content
Follow copywriting frameworks (AIDA, PAS, FAB) to craft all text content. Do NOT use "Lorem ipsum" — write real copy.
Phase 5: Build UI
Scaffold the project and build each section following Design and Motion rules. Integrate generated assets and copy. All <img>, <video>, <source>, and CSS background-image MUST reference local assets from Phase 3.
Phase 6: Quality Gates
Run final checklist (see Quality Gates section).
1. Design Engineering
1.1 Baseline Configuration
| Dial |
Default |
Range |
| DESIGN_VARIANCE |
8 |
1=Symmetry, 10=Asymmetric |
| MOTION_INTENSITY |
6 |
1=Static, 10=Cinematic |
| VISUAL_DENSITY |
4 |
1=Airy, 10=Packed |
Adapt dynamically based on user requests.
1.2 Architecture Conventions
- DEPENDENCY VERIFICATION: Check
package.json before importing any library. Output install command if missing.
- Framework: React/Next.js. Default to Server Components. Interactive components must be isolated
"use client" leaf components.
- Styling: Tailwind CSS. Check version in
package.json — NEVER mix v3/v4 syntax.
- ANTI-EMOJI POLICY: NEVER use emojis anywhere. Use Phosphor or Radix icons only.
- Viewport: Use
min-h-[100dvh] not h-screen. Use CSS Grid not flex percentage math.
- Layout:
max-w-[1400px] mx-auto or max-w-7xl.
1.3 Design Rules
| Rule |
Directive |
| Typography |
Headlines: text-4xl md:text-6xl tracking-tighter. Body: text-base leading-relaxed max-w-[65ch]. NEVER use Inter — use Geist/Outfit/Satoshi. NEVER use Serif on dashboards. |
| Color |
Max 1 accent, saturation < 80%. NEVER use AI purple/blue. Stick to one palette. |
| Layout |
NEVER use centered heroes when VARIANCE > 4. Force split-screen or asymmetric layouts. |
| Cards |
NEVER use generic cards when DENSITY > 7. Use border-t, divide-y, or spacing. |
| States |
ALWAYS implement: Loading (skeleton), Empty, Error, Tactile feedback (scale-[0.98]). |
| Forms |
Label above input. Error below. gap-2 for input blocks. |
1.4 Anti-Slop Techniques
- Liquid Glass:
backdrop-blur + border-white/10 + shadow-[inset_0_1px_0_rgba(255,255,255,0.1)]
- Magnetic Buttons: Use
useMotionValue/useTransform — never useState for continuous animations
- Perpetual Motion: When INTENSITY > 5, add infinite micro-animations (Pulse, Float, Shimmer)
- Layout Transitions: Use Framer
layout and layoutId props
- Stagger: Use
staggerChildren or CSS animation-delay: calc(var(--index) * 100ms)
1.5 Forbidden Patterns
| Category |
Banned |
| Visual |
Neon glows, pure black (#000), oversaturated accents, gradient text on headers, custom cursors |
| Typography |
Inter font, oversized H1s, Serif on dashboards |
| Layout |
3-column equal card rows, floating elements with awkward gaps |
| Components |
Default shadcn/ui without customization |
1.6 Creative Arsenal
| Category |
Patterns |
| Navigation |
Dock magnification, Magnetic button, Gooey menu, Dynamic island, Radial menu, Speed dial, Mega menu |
| Layout |
Bento grid, Masonry, Chroma grid, Split-screen scroll, Curtain reveal |
| Cards |
Parallax tilt, Spotlight border, Glassmorphism, Holographic foil, Swipe stack, Morphing modal |
| Scroll |
Sticky stack, Horizontal hijack, Locomotive sequence, Zoom parallax, Progress path, Liquid swipe |
| Gallery |
Dome gallery, Coverflow, Drag-to-pan, Accordion slider, Hover trail, Glitch effect |
| Text |
Kinetic marquee, Text mask reveal, Scramble effect, Circular path, Gradient stroke, Kinetic grid |
| Micro |
Particle explosion, Pull-to-refresh, Skeleton shimmer, Directional hover, Ripple click, SVG draw, Mesh gradient, Lens blur |
1.7 Bento Paradigm
- Palette: Background
#f9fafb, cards pure white with border-slate-200/50
- Surfaces:
rounded-[2.5rem], diffusion shadow
- Typography: Geist/Satoshi,
tracking-tight headers
- Labels: Outside and below cards
- Animation: Spring physics (
stiffness: 100, damping: 20), infinite loops, React.memo isolation
5-Card Archetypes:
- Intelligent List — auto-sorting with
layoutId
- Command Input — typewriter + blinking cursor
- Live Status — breathing indicators
- Wide Data Stream — infinite horizontal carousel
- Contextual UI — staggered highlight + float-in toolbar
1.8 Brand Override
When brand styling is active:
- Dark:
#141413, Light: #faf9f5, Mid: #b0aea5, Subtle: #e8e6dc
- Accents: Orange
#d97757, Blue #6a9bcc, Green #788c5d
- Fonts: Poppins (headings), Lora (body)
2. Motion Engine
2.1 Tool Selection Matrix
| Need |
Tool |
| UI enter/exit/layout |
Framer Motion — AnimatePresence, layoutId, springs |
| Scroll storytelling (pin, scrub) |
GSAP + ScrollTrigger — frame-accurate control |
| Looping icons |
Lottie — lazy-load (~50KB) |
| 3D/WebGL |
Three.js / R3F — isolated <Canvas>, own "use client" boundary |
| Hover/focus states |
CSS only — zero JS cost |
| Native scroll-driven |
CSS — animation-timeline: scroll() |
Conflict Rules [MANDATORY]:
- NEVER mix GSAP + Framer Motion in same component
- R3F MUST live in isolated Canvas wrapper
- ALWAYS lazy-load Lottie, GSAP, Three.js
2.2 Intensity Scale
| Level |
Techniques |
| 1-2 Subtle |
CSS transitions only, 150-300ms |
| 3-4 Smooth |
CSS keyframes + Framer animate, stagger ≤3 items |
| 5-6 Fluid |
whileInView, magnetic hover, parallax tilt |
| 7-8 Cinematic |
GSAP ScrollTrigger, pinned sections, horizontal hijack |
| 9-10 Immersive |
Full scroll sequences, Three.js particles, WebGL shaders |
2.3 Animation Recipes
See references/motion-recipes.md for full code. Summary:
| Recipe |
Tool |
Use For |
| Scroll Reveal |
Framer |
Fade+slide on viewport entry |
| Stagger Grid |
Framer |
Sequential list animations |
| Pinned Timeline |
GSAP |
Horizontal scroll with pinning |
| Tilt Card |
Framer |
Mouse-tracking 3D perspective |
| Magnetic Button |
Framer |
Cursor-attracted buttons |
| Text Scramble |
Vanilla |
Matrix-style decode effect |
| SVG Path Draw |
CSS |
Scroll-linked path animation |
| Horizontal Scroll |
GSAP |
Vertical-to-horizontal hijack |
| Particle Background |
R3F |
Decorative WebGL particles |
| Layout Morph |
Framer |
Card-to-modal expansion |
2.4 Performance Rules
GPU-only properties (ONLY animate these): transform, opacity, filter, clip-path
NEVER animate: width, height, top, left, margin, padding, font-size — if you need these effects, use transform: scale() or clip-path instead.
Isolation:
- Perpetual animations MUST be in
React.memo leaf components
will-change: transform ONLY during animation
contain: layout style paint on heavy containers
Mobile:
- ALWAYS respect
prefers-reduced-motion
- ALWAYS disable parallax/3D on
pointer: coarse
- Cap particles: desktop 800, tablet 300, mobile 100
- Disable GSAP pin on mobile < 768px
Cleanup: Every useEffect with GSAP/observers MUST return () => ctx.revert()
2.5 Springs & Easings
| Feel |
Framer Config |
| Snappy |
stiffness: 300, damping: 30 |
| Smooth |
stiffness: 150, damping: 20 |
| Bouncy |
stiffness: 100, damping: 10 |
| Heavy |
stiffness: 60, damping: 20 |
| CSS Easing |
Value |
| Smooth decel |
cubic-bezier(0.16, 1, 0.3, 1) |
| Smooth accel |
cubic-bezier(0.7, 0, 0.84, 0) |
| Elastic |
cubic-bezier(0.34, 1.56, 0.64, 1) |
2.6 Accessibility
- ALWAYS wrap motion in
prefers-reduced-motion check
- NEVER flash content > 3 times/second (seizure risk)
- ALWAYS provide visible focus rings (use
outline not box-shadow)
- ALWAYS add
aria-live="polite" for dynamically revealed content
- ALWAYS include pause button for auto-playing animations
2.7 Dependencies
npm install framer-motion # UI (keep at top level)
npm install gsap # Scroll (lazy-load)
npm install lottie-react # Icons (lazy-load)
npm install three @react-three/fiber @react-three/drei # 3D (lazy-load)
3. Asset Generation
3.1 Scripts
| Type |
Script |
Pattern |
| TTS |
scripts/minimax_tts.py |
Sync |
| Music |
scripts/minimax_music.py |
Sync |
| Video |
scripts/minimax_video.py |
Async (create → poll → download) |
| Image |
scripts/minimax_image.py |
Sync |
Env: MINIMAX_API_KEY (required).
3.2 Workflow
- Parse: type, quantity, style, spec, usage
- Craft prompt: Be specific (composition, lighting, style). NEVER include text in image prompts.
- Execute: Show prompt to user, MUST confirm before generating, then run script
- Save:
<project>/public/assets/{images,videos,audio}/ as {type}-{descriptor}-{timestamp}.{ext} — MUST save locally
- Post-process: Images → WebP, Videos → ffmpeg compress, Audio → normalize
- Deliver: File path + code snippet + CSS suggestion
3.3 Preset Shortcuts
| Shortcut |
Spec |
hero |
16:9, cinematic, text-safe |
thumb |
1:1, centered subject |
icon |
1:1, flat, clean background |
avatar |
1:1, portrait, circular crop ready |
banner |
21:9, OG/social |
bg-video |
768P, 6s, [Static shot] |
video-hd |
1080P, 6s |
bgm |
30s, no vocals, loopable |
tts |
MiniMax HD, MP3 |
3.4 Reference
references/minimax-cli-reference.md — CLI flags
references/asset-prompt-guide.md — Prompt rules
references/minimax-voice-catalog.md — Voice IDs
references/minimax-tts-guide.md — TTS usage
references/minimax-music-guide.md — Music generation (prompts, lyrics, structure tags)
references/minimax-video-guide.md — Camera commands
references/minimax-image-guide.md — Ratios, batch
4. Copywriting
4.1 Core Job
- Grab attention → 2. Create desire → 3. Remove friction → 4. Prompt action
4.2 Frameworks
AIDA (landing pages, emails):
ATTENTION: Bold headline (promise or pain)
INTEREST: Elaborate problem ("yes, that's me")
DESIRE: Show transformation
ACTION: Clear CTA
PAS (pain-driven products):
PROBLEM: State clearly
AGITATE: Make urgent
SOLUTION: Your product
FAB (product differentiation):
FEATURE: What it does
ADVANTAGE: Why it matters
BENEFIT: What customer gains
4.3 Headlines
| Formula |
Example |
| Promise |
"Double open rates in 30 days" |
| Question |
"Still wasting 10 hours/week?" |
| How-To |
"How to automate your pipeline" |
| Number |
"7 mistakes killing conversions" |
| Negative |
"Stop losing leads" |
| Curiosity |
"The one change that tripled bookings" |
| Transformation |
"From 50 to 500 leads" |
Be specific. Lead with outcome, not method.
4.4 CTAs
Bad: Submit, Click here, Learn more
Good: "Start my free trial", "Get the template now", "Book my strategy call"
Formula: [Action Verb] + [What They Get] + [Urgency/Ease]
Place: above fold, after value, multiple on long pages.
4.5 Emotional Triggers
| Trigger |
Example |
| FOMO |
"Only 3 spots left" |
| Fear of loss |
"Every day without this, you're losing $X" |
| Status |
"Join 10,000+ top agencies" |
| Ease |
"Set it up once. Forget forever." |
| Frustration |
"Tired of tools that deliver nothing?" |
| Hope |
"Yes, you CAN hit $10K MRR" |
4.6 Objection Handling
| Objection |
Response |
| Too expensive |
Show ROI: "Pays for itself in 2 weeks" |
| Won't work for me |
Social proof from similar customer |
| No time |
"Setup takes 10 minutes" |
| What if it fails |
"30-day money-back guarantee" |
| Need to think |
Urgency/scarcity |
Place in FAQ, testimonials, near CTA.
4.7 Proof Types
Testimonials (with name/title), Case studies, Data/metrics, Social proof, Certifications
5. Visual Art
Philosophy-first workflow. Two output modes.
5.1 Output Modes
| Mode |
Output |
When |
| Static |
PDF/PNG |
Posters, print, design assets |
| Interactive |
HTML (p5.js) |
Generative art, explorable variations |
5.2 Workflow
Step 1: Philosophy Creation
Name the movement (1-2 words). Articulate philosophy (4-6 paragraphs) covering:
- Static: space, form, color, scale, rhythm, hierarchy
- Interactive: computation, emergence, noise, parametric variation
Step 2: Conceptual Seed
Identify subtle, niche reference — sophisticated, not literal. Jazz musician quoting another song.
Step 3: Creation
Static Mode:
- Single page, highly visual, design-forward
- Repeating patterns, perfect shapes
- Sparse typography from
canvas-fonts/
- Nothing overlaps, proper margins
- Output:
.pdf or .png + philosophy .md
Interactive Mode:
- Read
templates/viewer.html first
- Keep FIXED sections (header, sidebar, seed controls)
- Replace VARIABLE sections (algorithm, parameters)
- Seeded randomness:
randomSeed(seed); noiseSeed(seed);
- Output: single self-contained HTML
Step 4: Refinement
Refine, don't add. Make it crisp. Polish into masterpiece.
Quality Gates
Design:
Motion:
General:
React and Next.js are trademarks of Meta Platforms, Inc. and Vercel, Inc., respectively. Vue.js is a trademark of Evan You. Tailwind CSS is a trademark of Tailwind Labs Inc. Svelte and SvelteKit are trademarks of their respective owners. GSAP/GreenSock is a trademark of GreenSock Inc. Three.js, Framer Motion, Lottie, Astro, and all other product names are trademarks of their respective owners.
1---
2name: frontend-dev
3description: |
4 Full-stack frontend development combining premium UI design, cinematic animations,
5 AI-generated media assets, persuasive copywriting, and visual art. Builds complete,
6 visually striking web pages with real media, advanced motion, and compelling copy.
7 Use when: building landing pages, marketing sites, product pages, dashboards,
8 generating media assets (image/video/audio/music), writing conversion copy,
9 creating generative art, or implementing cinematic scroll animations.
10description_zh: "前端开发与 AI 媒体生成"
11description_en: "Frontend dev with AI media, animations & persuasive copy"
12version: 0.1.1
13license: MIT
14metadata:
15 source: https://skillmd.com/skills/ahang1598/frontend-dev
16 version: "1.0.0"
17 category: frontend
18 sources:
19 - Framer Motion documentation
20 - GSAP / GreenSock documentation
21 - Three.js documentation
22 - Tailwind CSS documentation
23 - React / Next.js documentation
24 - AIDA Framework (Elmo Lewis)
25 - p5.js documentation
26---
27
28# Frontend Studio
29
30Build complete, production-ready frontend pages by orchestrating 5 specialized capabilities: design engineering, motion systems, AI-generated assets, persuasive copy, and generative art.
31
32## Invocation
33
34```
35/frontend-dev <request>
36```
37
38The user provides their request as natural language (e.g. "build a landing page for a music streaming app").
39
40## Skill Structure
41
42```
43frontend-dev/
44├── SKILL.md # Core skill (this file)
45├── scripts/ # Asset generation scripts
46│ ├── minimax_tts.py # Text-to-speech
47│ ├── minimax_music.py # Music generation
48│ ├── minimax_video.py # Video generation (async)
49│ └── minimax_image.py # Image generation
50├── references/ # Detailed guides (read as needed)
51│ ├── minimax-cli-reference.md # CLI flags quick reference
52│ ├── asset-prompt-guide.md # Asset prompt engineering rules
53│ ├── minimax-tts-guide.md # TTS usage & voices
54│ ├── minimax-music-guide.md # Music prompts & lyrics format
55│ ├── minimax-video-guide.md # Camera commands & models
56│ ├── minimax-image-guide.md # Ratios & batch generation
57│ ├── minimax-voice-catalog.md # All voice IDs
58│ ├── motion-recipes.md # Animation code snippets
59│ ├── env-setup.md # Environment setup
60│ └── troubleshooting.md # Common issues
61├── templates/ # Visual art templates
62│ ├── viewer.html # p5.js interactive art base
63│ └── generator_template.js # p5.js code reference
64└── canvas-fonts/ # Static art fonts (TTF + licenses)
65```
66
67## Project Structure
68
69### Assets (Universal)
70
71All frameworks use the same asset organization:
72
73```
74assets/
75├── images/
76│ ├── hero-landing-1710xxx.webp
77│ ├── icon-feature-01.webp
78│ └── bg-pattern.svg
79├── videos/
80│ ├── hero-bg-1710xxx.mp4
81│ └── demo-preview.mp4
82└── audio/
83 ├── bgm-ambient-1710xxx.mp3
84 └── tts-intro-1710xxx.mp3
85```
86
87**Asset naming:** `{type}-{descriptor}-{timestamp}.{ext}`
88
89### By Framework
90
91| Framework | Asset Location | Component Location |
92|-----------|---------------|-------------------|
93| **Pure HTML** | `./assets/` | N/A (inline or `./js/`) |
94| **React/Next.js** | `public/assets/` | `src/components/` |
95| **Vue/Nuxt** | `public/assets/` | `src/components/` |
96| **Svelte/SvelteKit** | `static/assets/` | `src/lib/components/` |
97| **Astro** | `public/assets/` | `src/components/` |
98
99### Pure HTML
100
101```
102project/
103├── index.html
104├── assets/
105│ ├── images/
106│ ├── videos/
107│ └── audio/
108├── css/
109│ └── styles.css
110└── js/
111 └── main.js # Animations (GSAP/vanilla)
112```
113
114### React / Next.js
115
116```
117project/
118├── public/assets/ # Static assets
119├── src/
120│ ├── components/
121│ │ ├── ui/ # Button, Card, Input
122│ │ ├── sections/ # Hero, Features, CTA
123│ │ └── motion/ # RevealSection, StaggerGrid
124│ ├── lib/
125│ ├── styles/
126│ └── app/ # Pages
127└── package.json
128```
129
130### Vue / Nuxt
131
132```
133project/
134├── public/assets/
135├── src/ # or root for Nuxt
136│ ├── components/
137│ │ ├── ui/
138│ │ ├── sections/
139│ │ └── motion/
140│ ├── composables/ # Shared logic
141│ ├── pages/
142│ └── assets/ # Processed assets (optional)
143└── package.json
144```
145
146### Astro
147
148```
149project/
150├── public/assets/
151├── src/
152│ ├── components/ # .astro, .tsx, .vue, .svelte
153│ ├── layouts/
154│ ├── pages/
155│ └── styles/
156└── package.json
157```
158
159**Component naming:** PascalCase (`HeroSection.tsx`, `HeroSection.vue`, `HeroSection.astro`)
160
161---
162
163## Compliance
164
165**All rules in this skill are mandatory. Violating any rule is a blocking error — fix before proceeding or delivering.**
166
167---
168
169## Workflow
170### Phase 1: Design Architecture
1711. Analyze the request — determine page type and context
1722. Set design dials based on page type
1733. Plan layout sections and identify asset needs
174
175### Phase 2: Motion Architecture
1761. Select animation tools per section (see Tool Selection Matrix)
1772. Plan motion sequences following performance guardrails
178
179### Phase 3: Asset Generation
180Generate all image/video/audio assets using `scripts/`. NEVER use placeholder URLs (unsplash, picsum, placeholder.com, via.placeholder, placehold.co, etc.) or external URLs.
181
1821. Parse asset requirements (type, style, spec, usage)
1832. Craft optimized prompts, show to user, confirm before generating
1843. Execute via scripts, save to project — do NOT proceed to Phase 5 until all assets are saved locally
185
186### Phase 4: Copywriting & Content
187Follow copywriting frameworks (AIDA, PAS, FAB) to craft all text content. Do NOT use "Lorem ipsum" — write real copy.
188
189### Phase 5: Build UI
190Scaffold the project and build each section following Design and Motion rules. Integrate generated assets and copy. All `<img>`, `<video>`, `<source>`, and CSS `background-image` MUST reference local assets from Phase 3.
191
192### Phase 6: Quality Gates
193Run final checklist (see Quality Gates section).
194
195---
196
197# 1. Design Engineering
198
199## 1.1 Baseline Configuration
200
201| Dial | Default | Range |
202|------|---------|-------|
203| DESIGN_VARIANCE | 8 | 1=Symmetry, 10=Asymmetric |
204| MOTION_INTENSITY | 6 | 1=Static, 10=Cinematic |
205| VISUAL_DENSITY | 4 | 1=Airy, 10=Packed |
206
207Adapt dynamically based on user requests.
208
209## 1.2 Architecture Conventions
210- **DEPENDENCY VERIFICATION:** Check `package.json` before importing any library. Output install command if missing.
211- **Framework:** React/Next.js. Default to Server Components. Interactive components must be isolated `"use client"` leaf components.
212- **Styling:** Tailwind CSS. Check version in `package.json` — NEVER mix v3/v4 syntax.
213- **ANTI-EMOJI POLICY:** NEVER use emojis anywhere. Use Phosphor or Radix icons only.
214- **Viewport:** Use `min-h-[100dvh]` not `h-screen`. Use CSS Grid not flex percentage math.
215- **Layout:** `max-w-[1400px] mx-auto` or `max-w-7xl`.
216
217## 1.3 Design Rules
218| Rule | Directive |
219|------|-----------|
220| Typography | Headlines: `text-4xl md:text-6xl tracking-tighter`. Body: `text-base leading-relaxed max-w-[65ch]`. **NEVER** use Inter — use Geist/Outfit/Satoshi. **NEVER** use Serif on dashboards. |
221| Color | Max 1 accent, saturation < 80%. **NEVER** use AI purple/blue. Stick to one palette. |
222| Layout | **NEVER** use centered heroes when VARIANCE > 4. Force split-screen or asymmetric layouts. |
223| Cards | **NEVER** use generic cards when DENSITY > 7. Use `border-t`, `divide-y`, or spacing. |
224| States | **ALWAYS** implement: Loading (skeleton), Empty, Error, Tactile feedback (`scale-[0.98]`). |
225| Forms | Label above input. Error below. `gap-2` for input blocks. |
226
227## 1.4 Anti-Slop Techniques
228
229- **Liquid Glass:** `backdrop-blur` + `border-white/10` + `shadow-[inset_0_1px_0_rgba(255,255,255,0.1)]`
230- **Magnetic Buttons:** Use `useMotionValue`/`useTransform` — never `useState` for continuous animations
231- **Perpetual Motion:** When INTENSITY > 5, add infinite micro-animations (Pulse, Float, Shimmer)
232- **Layout Transitions:** Use Framer `layout` and `layoutId` props
233- **Stagger:** Use `staggerChildren` or CSS `animation-delay: calc(var(--index) * 100ms)`
234
235## 1.5 Forbidden Patterns
236| Category | Banned |
237|----------|--------|
238| Visual | Neon glows, pure black (#000), oversaturated accents, gradient text on headers, custom cursors |
239| Typography | Inter font, oversized H1s, Serif on dashboards |
240| Layout | 3-column equal card rows, floating elements with awkward gaps |
241| Components | Default shadcn/ui without customization |
242
243## 1.6 Creative Arsenal
244
245| Category | Patterns |
246|----------|----------|
247| Navigation | Dock magnification, Magnetic button, Gooey menu, Dynamic island, Radial menu, Speed dial, Mega menu |
248| Layout | Bento grid, Masonry, Chroma grid, Split-screen scroll, Curtain reveal |
249| Cards | Parallax tilt, Spotlight border, Glassmorphism, Holographic foil, Swipe stack, Morphing modal |
250| Scroll | Sticky stack, Horizontal hijack, Locomotive sequence, Zoom parallax, Progress path, Liquid swipe |
251| Gallery | Dome gallery, Coverflow, Drag-to-pan, Accordion slider, Hover trail, Glitch effect |
252| Text | Kinetic marquee, Text mask reveal, Scramble effect, Circular path, Gradient stroke, Kinetic grid |
253| Micro | Particle explosion, Pull-to-refresh, Skeleton shimmer, Directional hover, Ripple click, SVG draw, Mesh gradient, Lens blur |
254
255## 1.7 Bento Paradigm
256
257- **Palette:** Background `#f9fafb`, cards pure white with `border-slate-200/50`
258- **Surfaces:** `rounded-[2.5rem]`, diffusion shadow
259- **Typography:** Geist/Satoshi, `tracking-tight` headers
260- **Labels:** Outside and below cards
261- **Animation:** Spring physics (`stiffness: 100, damping: 20`), infinite loops, `React.memo` isolation
262
263**5-Card Archetypes:**
2641. Intelligent List — auto-sorting with `layoutId`
2652. Command Input — typewriter + blinking cursor
2663. Live Status — breathing indicators
2674. Wide Data Stream — infinite horizontal carousel
2685. Contextual UI — staggered highlight + float-in toolbar
269
270## 1.8 Brand Override
271
272When brand styling is active:
273- Dark: `#141413`, Light: `#faf9f5`, Mid: `#b0aea5`, Subtle: `#e8e6dc`
274- Accents: Orange `#d97757`, Blue `#6a9bcc`, Green `#788c5d`
275- Fonts: Poppins (headings), Lora (body)
276
277---
278
279# 2. Motion Engine
280
281## 2.1 Tool Selection Matrix
282
283| Need | Tool |
284|------|------|
285| UI enter/exit/layout | **Framer Motion** — `AnimatePresence`, `layoutId`, springs |
286| Scroll storytelling (pin, scrub) | **GSAP + ScrollTrigger** — frame-accurate control |
287| Looping icons | **Lottie** — lazy-load (~50KB) |
288| 3D/WebGL | **Three.js / R3F** — isolated `<Canvas>`, own `"use client"` boundary |
289| Hover/focus states | **CSS only** — zero JS cost |
290| Native scroll-driven | **CSS** — `animation-timeline: scroll()` |
291
292**Conflict Rules [MANDATORY]:**
293- NEVER mix GSAP + Framer Motion in same component
294- R3F MUST live in isolated Canvas wrapper
295- ALWAYS lazy-load Lottie, GSAP, Three.js
296
297## 2.2 Intensity Scale
298
299| Level | Techniques |
300|-------|------------|
301| 1-2 Subtle | CSS transitions only, 150-300ms |
302| 3-4 Smooth | CSS keyframes + Framer animate, stagger ≤3 items |
303| 5-6 Fluid | `whileInView`, magnetic hover, parallax tilt |
304| 7-8 Cinematic | GSAP ScrollTrigger, pinned sections, horizontal hijack |
305| 9-10 Immersive | Full scroll sequences, Three.js particles, WebGL shaders |
306
307## 2.3 Animation Recipes
308
309See `references/motion-recipes.md` for full code. Summary:
310
311| Recipe | Tool | Use For |
312|--------|------|---------|
313| Scroll Reveal | Framer | Fade+slide on viewport entry |
314| Stagger Grid | Framer | Sequential list animations |
315| Pinned Timeline | GSAP | Horizontal scroll with pinning |
316| Tilt Card | Framer | Mouse-tracking 3D perspective |
317| Magnetic Button | Framer | Cursor-attracted buttons |
318| Text Scramble | Vanilla | Matrix-style decode effect |
319| SVG Path Draw | CSS | Scroll-linked path animation |
320| Horizontal Scroll | GSAP | Vertical-to-horizontal hijack |
321| Particle Background | R3F | Decorative WebGL particles |
322| Layout Morph | Framer | Card-to-modal expansion |
323
324## 2.4 Performance Rules
325**GPU-only properties (ONLY animate these):** `transform`, `opacity`, `filter`, `clip-path`
326
327**NEVER animate:** `width`, `height`, `top`, `left`, `margin`, `padding`, `font-size` — if you need these effects, use `transform: scale()` or `clip-path` instead.
328
329**Isolation:**
330- Perpetual animations MUST be in `React.memo` leaf components
331- `will-change: transform` ONLY during animation
332- `contain: layout style paint` on heavy containers
333
334**Mobile:**
335- ALWAYS respect `prefers-reduced-motion`
336- ALWAYS disable parallax/3D on `pointer: coarse`
337- Cap particles: desktop 800, tablet 300, mobile 100
338- Disable GSAP pin on mobile < 768px
339
340**Cleanup:** Every `useEffect` with GSAP/observers MUST `return () => ctx.revert()`
341
342## 2.5 Springs & Easings
343
344| Feel | Framer Config |
345|------|---------------|
346| Snappy | `stiffness: 300, damping: 30` |
347| Smooth | `stiffness: 150, damping: 20` |
348| Bouncy | `stiffness: 100, damping: 10` |
349| Heavy | `stiffness: 60, damping: 20` |
350
351| CSS Easing | Value |
352|------------|-------|
353| Smooth decel | `cubic-bezier(0.16, 1, 0.3, 1)` |
354| Smooth accel | `cubic-bezier(0.7, 0, 0.84, 0)` |
355| Elastic | `cubic-bezier(0.34, 1.56, 0.64, 1)` |
356
357## 2.6 Accessibility
358- ALWAYS wrap motion in `prefers-reduced-motion` check
359- NEVER flash content > 3 times/second (seizure risk)
360- ALWAYS provide visible focus rings (use `outline` not `box-shadow`)
361- ALWAYS add `aria-live="polite"` for dynamically revealed content
362- ALWAYS include pause button for auto-playing animations
363
364## 2.7 Dependencies
365
366```bash
367npm install framer-motion # UI (keep at top level)
368npm install gsap # Scroll (lazy-load)
369npm install lottie-react # Icons (lazy-load)
370npm install three @react-three/fiber @react-three/drei # 3D (lazy-load)
371```
372
373---
374
375# 3. Asset Generation
376
377## 3.1 Scripts
378
379| Type | Script | Pattern |
380|------|--------|---------|
381| TTS | `scripts/minimax_tts.py` | Sync |
382| Music | `scripts/minimax_music.py` | Sync |
383| Video | `scripts/minimax_video.py` | Async (create → poll → download) |
384| Image | `scripts/minimax_image.py` | Sync |
385
386Env: `MINIMAX_API_KEY` (required).
387
388## 3.2 Workflow
3891. **Parse:** type, quantity, style, spec, usage
3902. **Craft prompt:** Be specific (composition, lighting, style). **NEVER** include text in image prompts.
3913. **Execute:** Show prompt to user, **MUST confirm before generating**, then run script
3924. **Save:** `<project>/public/assets/{images,videos,audio}/` as `{type}-{descriptor}-{timestamp}.{ext}` — **MUST save locally**
3935. **Post-process:** Images → WebP, Videos → ffmpeg compress, Audio → normalize
3946. **Deliver:** File path + code snippet + CSS suggestion
395
396## 3.3 Preset Shortcuts
397
398| Shortcut | Spec |
399|----------|------|
400| `hero` | 16:9, cinematic, text-safe |
401| `thumb` | 1:1, centered subject |
402| `icon` | 1:1, flat, clean background |
403| `avatar` | 1:1, portrait, circular crop ready |
404| `banner` | 21:9, OG/social |
405| `bg-video` | 768P, 6s, `[Static shot]` |
406| `video-hd` | 1080P, 6s |
407| `bgm` | 30s, no vocals, loopable |
408| `tts` | MiniMax HD, MP3 |
409
410## 3.4 Reference
411
412- `references/minimax-cli-reference.md` — CLI flags
413- `references/asset-prompt-guide.md` — Prompt rules
414- `references/minimax-voice-catalog.md` — Voice IDs
415- `references/minimax-tts-guide.md` — TTS usage
416- `references/minimax-music-guide.md` — Music generation (prompts, lyrics, structure tags)
417- `references/minimax-video-guide.md` — Camera commands
418- `references/minimax-image-guide.md` — Ratios, batch
419
420---
421
422# 4. Copywriting
423
424## 4.1 Core Job
425
4261. Grab attention → 2. Create desire → 3. Remove friction → 4. Prompt action
427
428## 4.2 Frameworks
429
430**AIDA** (landing pages, emails):
431```
432ATTENTION: Bold headline (promise or pain)
433INTEREST: Elaborate problem ("yes, that's me")
434DESIRE: Show transformation
435ACTION: Clear CTA
436```
437
438**PAS** (pain-driven products):
439```
440PROBLEM: State clearly
441AGITATE: Make urgent
442SOLUTION: Your product
443```
444
445**FAB** (product differentiation):
446```
447FEATURE: What it does
448ADVANTAGE: Why it matters
449BENEFIT: What customer gains
450```
451
452## 4.3 Headlines
453
454| Formula | Example |
455|---------|---------|
456| Promise | "Double open rates in 30 days" |
457| Question | "Still wasting 10 hours/week?" |
458| How-To | "How to automate your pipeline" |
459| Number | "7 mistakes killing conversions" |
460| Negative | "Stop losing leads" |
461| Curiosity | "The one change that tripled bookings" |
462| Transformation | "From 50 to 500 leads" |
463
464Be specific. Lead with outcome, not method.
465
466## 4.4 CTAs
467
468**Bad:** Submit, Click here, Learn more
469
470**Good:** "Start my free trial", "Get the template now", "Book my strategy call"
471
472**Formula:** [Action Verb] + [What They Get] + [Urgency/Ease]
473
474Place: above fold, after value, multiple on long pages.
475
476## 4.5 Emotional Triggers
477
478| Trigger | Example |
479|---------|---------|
480| FOMO | "Only 3 spots left" |
481| Fear of loss | "Every day without this, you're losing $X" |
482| Status | "Join 10,000+ top agencies" |
483| Ease | "Set it up once. Forget forever." |
484| Frustration | "Tired of tools that deliver nothing?" |
485| Hope | "Yes, you CAN hit $10K MRR" |
486
487## 4.6 Objection Handling
488
489| Objection | Response |
490|-----------|----------|
491| Too expensive | Show ROI: "Pays for itself in 2 weeks" |
492| Won't work for me | Social proof from similar customer |
493| No time | "Setup takes 10 minutes" |
494| What if it fails | "30-day money-back guarantee" |
495| Need to think | Urgency/scarcity |
496
497Place in FAQ, testimonials, near CTA.
498
499## 4.7 Proof Types
500
501Testimonials (with name/title), Case studies, Data/metrics, Social proof, Certifications
502
503---
504
505# 5. Visual Art
506
507Philosophy-first workflow. Two output modes.
508
509## 5.1 Output Modes
510
511| Mode | Output | When |
512|------|--------|------|
513| Static | PDF/PNG | Posters, print, design assets |
514| Interactive | HTML (p5.js) | Generative art, explorable variations |
515
516## 5.2 Workflow
517
518### Step 1: Philosophy Creation
519Name the movement (1-2 words). Articulate philosophy (4-6 paragraphs) covering:
520- Static: space, form, color, scale, rhythm, hierarchy
521- Interactive: computation, emergence, noise, parametric variation
522
523### Step 2: Conceptual Seed
524Identify subtle, niche reference — sophisticated, not literal. Jazz musician quoting another song.
525
526### Step 3: Creation
527
528**Static Mode:**
529- Single page, highly visual, design-forward
530- Repeating patterns, perfect shapes
531- Sparse typography from `canvas-fonts/`
532- Nothing overlaps, proper margins
533- Output: `.pdf` or `.png` + philosophy `.md`
534
535**Interactive Mode:**
5361. Read `templates/viewer.html` first
5372. Keep FIXED sections (header, sidebar, seed controls)
5383. Replace VARIABLE sections (algorithm, parameters)
5394. Seeded randomness: `randomSeed(seed); noiseSeed(seed);`
5405. Output: single self-contained HTML
541
542### Step 4: Refinement
543Refine, don't add. Make it crisp. Polish into masterpiece.
544
545---
546
547# Quality Gates
548**Design:**
549- [ ] Mobile layout collapse (`w-full`, `px-4`) for high-variance designs
550- [ ] `min-h-[100dvh]` not `h-screen`
551- [ ] Empty, loading, error states provided
552- [ ] Cards omitted where spacing suffices
553
554**Motion:**
555- [ ] Correct tool per selection matrix
556- [ ] No GSAP + Framer mixed in same component
557- [ ] All `useEffect` have cleanup returns
558- [ ] `prefers-reduced-motion` respected
559- [ ] Perpetual animations in `React.memo` leaf components
560- [ ] Only GPU properties animated
561- [ ] Heavy libraries lazy-loaded
562
563**General:**
564- [ ] Dependencies verified in `package.json`
565- [ ] **No placeholder URLs** — grep the output for `unsplash`, `picsum`, `placeholder`, `placehold`, `via.placeholder`, `lorem.space`, `dummyimage`. If ANY found, STOP and replace with generated assets before delivering.
566- [ ] **All media assets exist as local files** in the project's assets directory
567- [ ] Asset prompts confirmed with user before generation
568
569---
570
571*React and Next.js are trademarks of Meta Platforms, Inc. and Vercel, Inc., respectively. Vue.js is a trademark of Evan You. Tailwind CSS is a trademark of Tailwind Labs Inc. Svelte and SvelteKit are trademarks of their respective owners. GSAP/GreenSock is a trademark of GreenSock Inc. Three.js, Framer Motion, Lottie, Astro, and all other product names are trademarks of their respective owners.*