# Cta 3

> Compact banner CTA block

A shadcn/ui block from the [@smoothui](https://smoothui.dev) registry, listed on [shadcn.exchange](https://shadcn.exchange/r/smoothui/cta-3).

- Page, with a live preview: https://shadcn.exchange/r/smoothui/cta-3
- Screenshot: https://abzjhwgwpdpz7ua5.public.blob.vercel-storage.com/shots/smoothui/cta-3-light-2d43572a6ee36a23.png
- Registry item: https://smoothui.dev/r/cta-3.json
- Listed: 2026-10-13, source last changed 2026-10-13

## Install

```bash
npx shadcn@latest add https://smoothui.dev/r/cta-3.json
```

Run it in a project that has shadcn/ui set up. It adds the files below and installs what they depend on.

## Dependencies

- npm packages: `motion`
- Registry items: `https://smoothui.dev/r/smooth-button.json`

## Files

### `index.tsx`

```tsx
"use client";

import SmoothButton from "@/components/smoothui/smooth-button";
import { motion, useReducedMotion } from "motion/react";

const SPRING = {
  bounce: 0.1,
  duration: 0.25,
  type: "spring" as const,
};

export function CtaBanner() {
  const shouldReduceMotion = useReducedMotion();

  return (
    <section aria-labelledby="cta-banner-heading">
      <div className="px-6 py-12">
        <motion.div
          className="mx-auto max-w-4xl overflow-hidden rounded-2xl border bg-gradient-to-r from-primary/5 via-background to-primary/5 p-8 md:p-12"
          initial={
            shouldReduceMotion ? { opacity: 1 } : { opacity: 0, scale: 0.97 }
          }
          transition={shouldReduceMotion ? { duration: 0 } : SPRING}
          viewport={{ once: true }}
          whileInView={
            shouldReduceMotion ? { opacity: 1 } : { opacity: 1, scale: 1 }
          }
        >
          <div className="flex flex-col items-center justify-between gap-6 md:flex-row">
            <div>
              <h2
                className="font-bold text-xl md:text-2xl"
                id="cta-banner-heading"
              >
                Start building today
              </h2>
              <p className="mt-1 text-foreground/70 text-sm md:text-base">
                Install any component with a single command.
              </p>
            </div>
            <SmoothButton variant="candy">Get Started →</SmoothButton>
          </div>
        </motion.div>
      </div>
    </section>
  );
}

export default CtaBanner;
```
