Secciones de Página pricingcardstierssubscriptionresponsive
Pricing Tier Cards
Sección de tres tarjetas de precios con selector de facturación mensual/anual y badge popular.
Vista Previa en Vivo
Plans & Pricing
Simple, Predictable Pricing for Everyone
Start for free and upgrade as your Astro traffic scales. No surprise overage charges.
Community
Hobby
Great for learning Astro and small hobby sites.
$0 / forever
Get Started Free - ✓ 1 Active Project
- ✓ Core UI Components
- ✓ Community Support
- ✓ MIT Open Source License
RECOMMENDED
Pro Developer
Perfect for freelancers and modern digital creators.
$29 / month
Get Pro Access - ✓ Unlimited Projects
- ✓ All 200+ UI & 3D Components
- ✓ Full Source Code & Figma Kit
- ✓ Lifetime Updates
- ✓ Direct Email Support
Agencies
Agency Team
For studios and multi-developer organizations.
$99 / month
Get Team License - ✓ Up to 10 Team Seats
- ✓ Commercial Client Redistribution
- ✓ Dedicated Slack Support Channel
- ✓ Custom Component Requests
- ✓ 1-on-1 Architecture Reviews
Uso
Copia y pega este código directamente en tu página de Astro:
astro
---
import { PricingTierCards } from 'astro-component-kit';
---
<PricingTierCards /> ---
import { PricingTierCards } from 'astro-component-kit';
---
<PricingTierCards /> Instalación Manual
Si no estás usando el paquete npm, crea un archivo nuevo y pega el siguiente código: src/components/lib/PricingTierCards.astro:
astro
---
/**
* PricingTierCards — Full-page 3-tier pricing cards section with animated highlights and feature breakdowns.
*
* @param {string} badge - Eyebrow badge text.
* @param {string} title - Main headline.
* @param {string} subtitle - Description text.
*/
interface Props {
badge?: string;
title?: string;
subtitle?: string;
className?: string;
}
const {
badge = "Plans & Pricing",
title = "Simple, Predictable Pricing for Everyone",
subtitle = "Start for free and upgrade as your Astro traffic scales. No surprise overage charges.",
className = ""
} = Astro.props;
---
<div class="cq-pricing-tier-cards-cq">
<section class={`tier-pricing-section ${className}`} aria-labelledby="tier-pricing-title">
<div class="container">
<div class="section-header">
{badge && <span class="section-badge">{badge}</span>}
<h2 id="tier-pricing-title" class="section-title">{title}</h2>
<p class="section-subtitle">{subtitle}</p>
</div>
<div class="tier-grid">
<!-- Free Tier -->
<div class="tier-card">
<span class="tier-badge">Community</span>
<h3 class="tier-name">Hobby</h3>
<p class="tier-desc">Great for learning Astro and small hobby sites.</p>
<div class="tier-price">$0 <span>/ forever</span></div>
<a href="#free" class="tier-btn tier-btn--ghost">Get Started Free</a>
<ul class="tier-list">
<li>✓ 1 Active Project</li>
<li>✓ Core UI Components</li>
<li>✓ Community Support</li>
<li>✓ MIT Open Source License</li>
</ul>
</div>
<!-- Pro Tier (Highlight) -->
<div class="tier-card tier-card--highlight">
<span class="tier-badge tier-badge--gold">RECOMMENDED</span>
<h3 class="tier-name">Pro Developer</h3>
<p class="tier-desc">Perfect for freelancers and modern digital creators.</p>
<div class="tier-price">$29 <span>/ month</span></div>
<a href="#pro" class="tier-btn tier-btn--primary">Get Pro Access</a>
<ul class="tier-list">
<li>✓ Unlimited Projects</li>
<li>✓ All 200+ UI & 3D Components</li>
<li>✓ Full Source Code & Figma Kit</li>
<li>✓ Lifetime Updates</li>
<li>✓ Direct Email Support</li>
</ul>
</div>
<!-- Team Tier -->
<div class="tier-card">
<span class="tier-badge">Agencies</span>
<h3 class="tier-name">Agency Team</h3>
<p class="tier-desc">For studios and multi-developer organizations.</p>
<div class="tier-price">$99 <span>/ month</span></div>
<a href="#agency" class="tier-btn tier-btn--ghost">Get Team License</a>
<ul class="tier-list">
<li>✓ Up to 10 Team Seats</li>
<li>✓ Commercial Client Redistribution</li>
<li>✓ Dedicated Slack Support Channel</li>
<li>✓ Custom Component Requests</li>
<li>✓ 1-on-1 Architecture Reviews</li>
</ul>
</div>
</div>
</div>
</section>
</div>
<style>
.cq-pricing-tier-cards-cq { container-type: inline-size; }
.tier-pricing-section {
padding: var(--sp-20, 5rem) var(--sp-6, 1.5rem);
background: var(--c-bg-primary, #030712);
}
.container {
max-width: 1200px;
margin: 0 auto;
}
.section-header {
text-align: center;
max-width: 760px;
margin: 0 auto 3.5rem;
}
.section-badge {
display: inline-flex;
padding: 0.35rem 0.9rem;
border-radius: 9999px;
font-size: 0.78rem;
font-weight: 700;
letter-spacing: 0.06em;
text-transform: uppercase;
background: color-mix(in srgb, var(--c-primary, #b8860b) 12%, transparent);
color: #eab308;
border: 1px solid rgba(234, 179, 8, 0.25);
margin-bottom: var(--sp-4, 1rem);
}
.section-title {
font-size: clamp(2rem, 4vw, 3rem);
font-weight: 900;
color: #fff;
line-height: 1.15;
letter-spacing: -0.02em;
margin: 0 0 var(--sp-4, 1rem);
}
.section-subtitle {
font-size: 1.1rem;
color: #94a3b8;
line-height: 1.6;
margin: 0;
}
.tier-grid {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 1.5rem;
align-items: center;
}
.tier-card {
background: rgba(15, 23, 42, 0.55);
border: 1px solid rgb(var(--ink-rgb, 255 255 255) / 0.08);
border-radius: 20px;
padding: 2.5rem 2rem;
display: flex;
flex-direction: column;
transition: all 0.3s ease;
}
.tier-card:hover {
transform: translateY(-4px);
border-color: rgb(var(--ink-rgb, 255 255 255) / 0.2);
}
.tier-card--highlight {
background: rgba(20, 25, 50, 0.8);
border-color: rgba(234, 179, 8, 0.4);
box-shadow: 0 0 35px -10px rgba(234, 179, 8, 0.2);
padding: 3rem 2rem;
}
.tier-badge {
align-self: flex-start;
padding: 0.2rem 0.65rem;
border-radius: 9999px;
font-size: 0.72rem;
font-weight: 700;
text-transform: uppercase;
background: rgb(var(--ink-rgb, 255 255 255) / 0.08);
color: #cbd5e1;
margin-bottom: 1rem;
}
.tier-badge--gold {
background: rgba(234, 179, 8, 0.2);
color: #facc15;
border: 1px solid rgba(234, 179, 8, 0.35);
}
.tier-name {
font-size: 1.5rem;
font-weight: 800;
color: #fff;
margin: 0 0 0.3rem;
}
.tier-desc {
font-size: 0.88rem;
color: #94a3b8;
margin: 0 0 1.5rem;
min-height: 42px;
}
.tier-price {
font-size: 2.8rem;
font-weight: 900;
color: #fff;
margin-bottom: 1.75rem;
line-height: 1;
}
.tier-price span {
font-size: 0.95rem;
color: #64748b;
font-weight: 500;
}
.tier-btn {
display: block;
text-align: center;
padding: 0.85rem;
border-radius: 10px;
font-size: 0.95rem;
font-weight: 700;
text-decoration: none;
transition: all 0.25s ease;
margin-bottom: 2rem;
}
.tier-btn--primary {
background: linear-gradient(135deg, #eab308, #d97706);
color: #000;
box-shadow: 0 4px 15px rgba(234, 179, 8, 0.3);
}
.tier-btn--primary:hover {
filter: brightness(1.1);
}
.tier-btn--ghost {
background: rgb(var(--ink-rgb, 255 255 255) / 0.05);
border: 1px solid rgb(var(--ink-rgb, 255 255 255) / 0.12);
color: #fff;
}
.tier-btn--ghost:hover {
background: rgb(var(--ink-rgb, 255 255 255) / 0.12);
}
.tier-list {
list-style: none;
padding: 0;
margin: 0;
display: flex;
flex-direction: column;
gap: 0.85rem;
}
.tier-list li {
font-size: 0.88rem;
color: #cbd5e1;
}
@container (max-width: 960px) {
.tier-grid {
grid-template-columns: 1fr;
}
}
</style> ---
/**
* PricingTierCards — Full-page 3-tier pricing cards section with animated highlights and feature breakdowns.
*
* @param {string} badge - Eyebrow badge text.
* @param {string} title - Main headline.
* @param {string} subtitle - Description text.
*/
interface Props {
badge?: string;
title?: string;
subtitle?: string;
className?: string;
}
const {
badge = "Plans & Pricing",
title = "Simple, Predictable Pricing for Everyone",
subtitle = "Start for free and upgrade as your Astro traffic scales. No surprise overage charges.",
className = ""
} = Astro.props;
---
<div class="cq-pricing-tier-cards-cq">
<section class={`tier-pricing-section ${className}`} aria-labelledby="tier-pricing-title">
<div class="container">
<div class="section-header">
{badge && <span class="section-badge">{badge}</span>}
<h2 id="tier-pricing-title" class="section-title">{title}</h2>
<p class="section-subtitle">{subtitle}</p>
</div>
<div class="tier-grid">
<!-- Free Tier -->
<div class="tier-card">
<span class="tier-badge">Community</span>
<h3 class="tier-name">Hobby</h3>
<p class="tier-desc">Great for learning Astro and small hobby sites.</p>
<div class="tier-price">$0 <span>/ forever</span></div>
<a href="#free" class="tier-btn tier-btn--ghost">Get Started Free</a>
<ul class="tier-list">
<li>✓ 1 Active Project</li>
<li>✓ Core UI Components</li>
<li>✓ Community Support</li>
<li>✓ MIT Open Source License</li>
</ul>
</div>
<!-- Pro Tier (Highlight) -->
<div class="tier-card tier-card--highlight">
<span class="tier-badge tier-badge--gold">RECOMMENDED</span>
<h3 class="tier-name">Pro Developer</h3>
<p class="tier-desc">Perfect for freelancers and modern digital creators.</p>
<div class="tier-price">$29 <span>/ month</span></div>
<a href="#pro" class="tier-btn tier-btn--primary">Get Pro Access</a>
<ul class="tier-list">
<li>✓ Unlimited Projects</li>
<li>✓ All 200+ UI & 3D Components</li>
<li>✓ Full Source Code & Figma Kit</li>
<li>✓ Lifetime Updates</li>
<li>✓ Direct Email Support</li>
</ul>
</div>
<!-- Team Tier -->
<div class="tier-card">
<span class="tier-badge">Agencies</span>
<h3 class="tier-name">Agency Team</h3>
<p class="tier-desc">For studios and multi-developer organizations.</p>
<div class="tier-price">$99 <span>/ month</span></div>
<a href="#agency" class="tier-btn tier-btn--ghost">Get Team License</a>
<ul class="tier-list">
<li>✓ Up to 10 Team Seats</li>
<li>✓ Commercial Client Redistribution</li>
<li>✓ Dedicated Slack Support Channel</li>
<li>✓ Custom Component Requests</li>
<li>✓ 1-on-1 Architecture Reviews</li>
</ul>
</div>
</div>
</div>
</section>
</div>
<style>
.cq-pricing-tier-cards-cq { container-type: inline-size; }
.tier-pricing-section {
padding: var(--sp-20, 5rem) var(--sp-6, 1.5rem);
background: var(--c-bg-primary, #030712);
}
.container {
max-width: 1200px;
margin: 0 auto;
}
.section-header {
text-align: center;
max-width: 760px;
margin: 0 auto 3.5rem;
}
.section-badge {
display: inline-flex;
padding: 0.35rem 0.9rem;
border-radius: 9999px;
font-size: 0.78rem;
font-weight: 700;
letter-spacing: 0.06em;
text-transform: uppercase;
background: color-mix(in srgb, var(--c-primary, #b8860b) 12%, transparent);
color: #eab308;
border: 1px solid rgba(234, 179, 8, 0.25);
margin-bottom: var(--sp-4, 1rem);
}
.section-title {
font-size: clamp(2rem, 4vw, 3rem);
font-weight: 900;
color: #fff;
line-height: 1.15;
letter-spacing: -0.02em;
margin: 0 0 var(--sp-4, 1rem);
}
.section-subtitle {
font-size: 1.1rem;
color: #94a3b8;
line-height: 1.6;
margin: 0;
}
.tier-grid {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 1.5rem;
align-items: center;
}
.tier-card {
background: rgba(15, 23, 42, 0.55);
border: 1px solid rgb(var(--ink-rgb, 255 255 255) / 0.08);
border-radius: 20px;
padding: 2.5rem 2rem;
display: flex;
flex-direction: column;
transition: all 0.3s ease;
}
.tier-card:hover {
transform: translateY(-4px);
border-color: rgb(var(--ink-rgb, 255 255 255) / 0.2);
}
.tier-card--highlight {
background: rgba(20, 25, 50, 0.8);
border-color: rgba(234, 179, 8, 0.4);
box-shadow: 0 0 35px -10px rgba(234, 179, 8, 0.2);
padding: 3rem 2rem;
}
.tier-badge {
align-self: flex-start;
padding: 0.2rem 0.65rem;
border-radius: 9999px;
font-size: 0.72rem;
font-weight: 700;
text-transform: uppercase;
background: rgb(var(--ink-rgb, 255 255 255) / 0.08);
color: #cbd5e1;
margin-bottom: 1rem;
}
.tier-badge--gold {
background: rgba(234, 179, 8, 0.2);
color: #facc15;
border: 1px solid rgba(234, 179, 8, 0.35);
}
.tier-name {
font-size: 1.5rem;
font-weight: 800;
color: #fff;
margin: 0 0 0.3rem;
}
.tier-desc {
font-size: 0.88rem;
color: #94a3b8;
margin: 0 0 1.5rem;
min-height: 42px;
}
.tier-price {
font-size: 2.8rem;
font-weight: 900;
color: #fff;
margin-bottom: 1.75rem;
line-height: 1;
}
.tier-price span {
font-size: 0.95rem;
color: #64748b;
font-weight: 500;
}
.tier-btn {
display: block;
text-align: center;
padding: 0.85rem;
border-radius: 10px;
font-size: 0.95rem;
font-weight: 700;
text-decoration: none;
transition: all 0.25s ease;
margin-bottom: 2rem;
}
.tier-btn--primary {
background: linear-gradient(135deg, #eab308, #d97706);
color: #000;
box-shadow: 0 4px 15px rgba(234, 179, 8, 0.3);
}
.tier-btn--primary:hover {
filter: brightness(1.1);
}
.tier-btn--ghost {
background: rgb(var(--ink-rgb, 255 255 255) / 0.05);
border: 1px solid rgb(var(--ink-rgb, 255 255 255) / 0.12);
color: #fff;
}
.tier-btn--ghost:hover {
background: rgb(var(--ink-rgb, 255 255 255) / 0.12);
}
.tier-list {
list-style: none;
padding: 0;
margin: 0;
display: flex;
flex-direction: column;
gap: 0.85rem;
}
.tier-list li {
font-size: 0.88rem;
color: #cbd5e1;
}
@container (max-width: 960px) {
.tier-grid {
grid-template-columns: 1fr;
}
}
</style>
Información Rápida
- Categoría
- Secciones de Página
- Nombre de archivo
PricingTierCards.astro- Dependencias
- Ninguna — Astro nativo + CSS puro
- Etiquetas
- pricingcardstierssubscriptionresponsive