Card

Free + Pro

Container component with both Free and Pro versions. Free offers basic layout, Pro adds 3D effects and animations.

Unlock Advanced Card Features

Get access to powerful pro features that enhance your card component with advanced capabilities, premium styling options, and optimized performance.

  • Both Free and Pro versions available - Choose based on your needs
  • Free: Basic card layout with header, content, and footer sections
  • Free: 6 variants, a sm-to-xl density scale, radius options and asChild polymorphic rendering

Pro Features

Unlock advanced capabilities with the Pro version

Premium Variants

Access glass, gradient, neon, and glow card styles with stunning visual effects

Interactive Effects

3D tilt perspective, parallax depth layers, glow hover, and smooth lift animations

Visual Enhancements

Backdrop blur, animated gradients, glow effects, and shadow transitions

Performance Optimized

GPU-accelerated animations with reduced repaints for smooth 60fps interactions

Installation

Install via CLI

# Default installation (asks for version if Pro license detected)
npx @moontra/moonui-cli add card

# Explicit version selection
npx @moontra/moonui-cli add card --variant=free  # Install free version
npx @moontra/moonui-cli add card --variant=pro   # Install pro version (requires license)

# Installation paths:
# - Free version: components/ui/card.tsx
# - Pro version: components/pro/card-pro.tsx

Usage

Basic Usage

Pro Required

Create project

Deploy your new project in one-click.

Choose a framework to get started with your project.

Pro Usage

PRO
Pro Required

Premium Features

Experience enhanced card interactions

Advanced card with glassmorphism effect and smooth hover animations.

Examples

Simple Card

Basic card with minimal content.

Notifications

You have 3 unread messages.

Card with Content

Card with header, content, and footer sections.

Performance

Your app performance metrics

98.5%

Uptime this month

User Profile Card

Card displaying user information with avatar.

JD

John Doe

Software Engineer

Building amazing products with modern web technologies.

Stats Card

Card showing statistics with icons.

Total Revenue

$45,231.89

+20.1%from last month

Size Scale (Section Padding)

size is a density switch, not a width switch: the root Card hands its resolved size down to CardHeader, CardContent and CardFooter through React context. md is the default and keeps the classic 24px padding, so existing cards render exactly as before.

Small

p-4 - 16px sections

Dense lists, sidebars and compact dashboards.

Medium

p-6 - 24px sections (default)

The default density used by every example above.

Large

p-8 - 32px sections

Marketing sections and feature highlights.

Extra large

p-10 - 40px sections

Hero cards where the card is the page.

Variants

All six free variants side by side. glass and gradient are rendered over a tinted surface here, because their translucency only reads against a background with some contrast.

default

Border plus a subtle shadow.

outline

Transparent surface, no shadow.

filled

Secondary surface, no border.

elevated

Borderless with a raised shadow.

gradient

Primary tinted diagonal gradient.

glass

Translucent surface with backdrop blur.

Radius Scale

radius is independent from size and variant. It replaces the rounding of the card root only, so nested media still needs its own rounding.

none

sm

default

lg

full

Card as a Link (asChild)

With asChild the card styles are applied to your own element through Radix Slot, so the whole card becomes a single anchor: one hit target, one focus stop, real middle-click and open-in-new-tab behaviour. The size context still reaches the sections and the interactive CSS classes still apply, but the Framer Motion micro-interaction is skipped in this mode - Slot merges props into one child while motion needs an element of its own. Swap the anchor for a Next.js Link when you route internally.

PRO
Pro Examples

Premium Analytics Dashboard Card

PRO

Advanced glassmorphism card with real-time stats, animated charts, and interactive hover effects.

Pro Required

Premium Analytics

Real-time performance metrics & insights

Total Revenue

$124,592

+22.4%

Active Users

8,429

+15.3%
Weekly Performance
7 Days
MonWedFriSun
Goal Progress87%

$13,408 remaining to monthly goal

3D Interactive Pricing Card

PRO

Advanced 3D tilt effect with parallax layers, animated gradients, and interactive elements.

Pro Required
MOST POPULAR

Pro Enterprise

Everything you need to build at scale

$99/month
$149
Save 33%
500+ Premium Components
AI-Powered Code Generation
Priority Support & Updates
Commercial License
Custom Theming Engine
SSL Secured
10k+ Teams

System Monitoring Card with Live Updates

PRO

Real-time system monitoring with animated progress bars, status indicators, and gradient animations.

Pro Required

System Health Monitor

Real-time infrastructure status

Operational
API Server
99.9%uptime
Database
1.2mslatency
CPU Usage
45%
Memory
68%
Storage
82%

Response Time

124ms

Requests/min

2.4k

Error Rate

0.01%

Interactive Glow Card

PRO

Premium glow effect using the real Pro `glow` variant with `microInteraction="glow"`. For a cursor-following spotlight, use the dedicated Spotlight Card Pro component.

Pro Required

Interactive Glow

Premium glow variant with smooth hover lighting

Hover over this card to see the premium glow effect, powered by the real Pro glow variant. For a cursor-tracking spotlight, reach for the dedicated Spotlight Card component.

Dynamic

Interactive

Elegant