background-animations
Expert knowledge for creating stunning animated backgrounds - gradient flows, particle systems, mesh gradients, aurora effects, wave patterns, and dynamic textures that bring depth and life to your interfaces.
What this skill does
# Background Animations Skill
Expert knowledge for creating stunning animated backgrounds - gradient flows, particle systems, mesh gradients, aurora effects, wave patterns, and dynamic textures that bring depth and life to your interfaces.
## When to Use
Activate this skill when:
- User wants animated backgrounds or hero sections
- Building landing pages with dynamic visuals
- Creating gradient animations or color flows
- Implementing particle systems or starfields
- Need mesh gradient or aurora-style effects
- Building wave patterns or liquid backgrounds
## File Patterns
- `**/*.tsx` with background components
- `**/components/Background*.tsx`
- `**/components/Hero*.tsx`
- Files with canvas or WebGL usage
## Background Animation Types
### 1. Animated Gradients
#### Flowing Gradient Background
```tsx
import { motion } from 'framer-motion';
export function FlowingGradient() {
return (
<motion.div
className="absolute inset-0 -z-10"
style={{
background: 'linear-gradient(-45deg, #ee7752, #e73c7e, #23a6d5, #23d5ab)',
backgroundSize: '400% 400%',
}}
animate={{
backgroundPosition: ['0% 50%', '100% 50%', '0% 50%'],
}}
transition={{
duration: 15,
repeat: Infinity,
ease: 'linear',
}}
/>
);
}
```
#### Radial Gradient Pulse
```tsx
export function RadialPulse() {
return (
<motion.div
className="absolute inset-0 -z-10"
animate={{
background: [
'radial-gradient(circle at 50% 50%, #667eea 0%, transparent 50%)',
'radial-gradient(circle at 50% 50%, #764ba2 0%, transparent 70%)',
'radial-gradient(circle at 50% 50%, #667eea 0%, transparent 50%)',
],
}}
transition={{
duration: 4,
repeat: Infinity,
ease: 'easeInOut',
}}
/>
);
}
```
#### Mesh Gradient (CSS)
```tsx
export function MeshGradient() {
return (
<div className="absolute inset-0 -z-10 overflow-hidden">
<motion.div
className="absolute w-[150%] h-[150%] -left-[25%] -top-[25%]"
style={{
background: `
radial-gradient(at 40% 20%, #ff6b6b 0px, transparent 50%),
radial-gradient(at 80% 0%, #feca57 0px, transparent 50%),
radial-gradient(at 0% 50%, #48dbfb 0px, transparent 50%),
radial-gradient(at 80% 50%, #ff9ff3 0px, transparent 50%),
radial-gradient(at 0% 100%, #54a0ff 0px, transparent 50%),
radial-gradient(at 80% 100%, #5f27cd 0px, transparent 50%)
`,
}}
animate={{
rotate: [0, 360],
scale: [1, 1.1, 1],
}}
transition={{
rotate: { duration: 60, repeat: Infinity, ease: 'linear' },
scale: { duration: 10, repeat: Infinity, ease: 'easeInOut' },
}}
/>
</div>
);
}
```
### 2. Particle Systems
#### Floating Particles
```tsx
import { motion } from 'framer-motion';
import { useMemo } from 'react';
interface Particle {
id: number;
x: number;
y: number;
size: number;
duration: number;
delay: number;
}
export function FloatingParticles({ count = 50 }: { count?: number }) {
const particles = useMemo<Particle[]>(() =>
Array.from({ length: count }, (_, i) => ({
id: i,
x: Math.random() * 100,
y: Math.random() * 100,
size: Math.random() * 4 + 2,
duration: Math.random() * 20 + 10,
delay: Math.random() * 5,
})),
[count]
);
return (
<div className="absolute inset-0 -z-10 overflow-hidden">
{particles.map((particle) => (
<motion.div
key={particle.id}
className="absolute rounded-full bg-white/20"
style={{
left: `${particle.x}%`,
top: `${particle.y}%`,
width: particle.size,
height: particle.size,
}}
animate={{
y: [0, -100, 0],
x: [0, Math.random() * 50 - 25, 0],
opacity: [0, 1, 0],
}}
transition={{
duration: particle.duration,
delay: particle.delay,
repeat: Infinity,
ease: 'easeInOut',
}}
/>
))}
</div>
);
}
```
#### Starfield
```tsx
export function Starfield({ count = 200 }: { count?: number }) {
const stars = useMemo(() =>
Array.from({ length: count }, (_, i) => ({
id: i,
x: Math.random() * 100,
y: Math.random() * 100,
size: Math.random() * 2 + 0.5,
twinkleDuration: Math.random() * 3 + 2,
delay: Math.random() * 3,
})),
[count]
);
return (
<div className="absolute inset-0 -z-10 bg-slate-950 overflow-hidden">
{stars.map((star) => (
<motion.div
key={star.id}
className="absolute rounded-full bg-white"
style={{
left: `${star.x}%`,
top: `${star.y}%`,
width: star.size,
height: star.size,
}}
animate={{
opacity: [0.3, 1, 0.3],
scale: [1, 1.2, 1],
}}
transition={{
duration: star.twinkleDuration,
delay: star.delay,
repeat: Infinity,
ease: 'easeInOut',
}}
/>
))}
</div>
);
}
```
### 3. Wave Patterns
#### Animated Waves
```tsx
export function AnimatedWaves() {
return (
<div className="absolute bottom-0 left-0 right-0 -z-10 h-64 overflow-hidden">
<svg
viewBox="0 0 1440 320"
className="absolute bottom-0 w-full"
preserveAspectRatio="none"
>
{/* Wave 1 - Back */}
<motion.path
fill="rgba(99, 102, 241, 0.3)"
d="M0,192L48,197.3C96,203,192,213,288,229.3C384,245,480,267,576,250.7C672,235,768,181,864,181.3C960,181,1056,235,1152,234.7C1248,235,1344,181,1392,154.7L1440,128L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"
animate={{
d: [
"M0,192L48,197.3C96,203,192,213,288,229.3C384,245,480,267,576,250.7C672,235,768,181,864,181.3C960,181,1056,235,1152,234.7C1248,235,1344,181,1392,154.7L1440,128L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z",
"M0,128L48,154.7C96,181,192,235,288,234.7C384,235,480,181,576,181.3C672,181,768,235,864,250.7C960,267,1056,245,1152,229.3C1248,213,1344,203,1392,197.3L1440,192L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z",
],
}}
transition={{
duration: 8,
repeat: Infinity,
repeatType: 'reverse',
ease: 'easeInOut',
}}
/>
{/* Wave 2 - Middle */}
<motion.path
fill="rgba(99, 102, 241, 0.5)"
d="M0,256L48,261.3C96,267,192,277,288,266.7C384,256,480,224,576,213.3C672,203,768,213,864,224C960,235,1056,245,1152,234.7C1248,224,1344,192,1392,176L1440,160L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"
animate={{
d: [
"M0,256L48,261.3C96,267,192,277,288,266.7C384,256,480,224,576,213.3C672,203,768,213,864,224C960,235,1056,245,1152,234.7C1248,224,1344,192,1392,176L1440,160L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z",
"M0,160L48,176C96,192,192,224,288,234.7C384,245,480,235,576,224C672,213,768,203,864,213.3C960,224,1056,256,1152,266.7C1248,277,1344,267,1392,261.3L1440,256L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z",
Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.