{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "ds-cta",
  "title": "Cta",
  "description": "Container CTA core com badge, título, descrição e ações — átomo base CTA.",
  "dependencies": [
    "class-variance-authority",
    "lucide-react"
  ],
  "registryDependencies": [
    "@lema-ds/badge",
    "@lema-ds/button",
    "@lema-ds/skeleton",
    "@lema-ds/tokens"
  ],
  "files": [
    {
      "path": "components/ds/ds-cta.tsx",
      "content": "\"use client\"\n\nimport * as React from \"react\"\nimport { cva, type VariantProps } from \"class-variance-authority\"\nimport { ArrowRightIcon } from \"lucide-react\"\n\nimport { cn } from \"@/lib/utils\"\nimport { Badge } from \"@/components/ui/badge\"\nimport { Button } from \"@/components/ui/button\"\nimport { Skeleton } from \"@/components/ui/skeleton\"\n\n// ── Types ──────────────────────────────────────────────────────────────────\n\nexport interface CtaAction {\n  label: string\n  href?: string\n  onClick?: () => void\n  icon?: React.ReactNode\n}\n\nexport interface CtaProps\n  extends\n    React.HTMLAttributes<HTMLDivElement>,\n    VariantProps<typeof ctaVariants> {\n  badge?: string\n  title: string\n  description?: string\n  primaryAction?: CtaAction\n  secondaryAction?: CtaAction\n  loading?: boolean\n}\n\n// ── Variants ───────────────────────────────────────────────────────────────\n\nexport const ctaVariants = cva(\n  \"relative overflow-hidden rounded-3xl border p-8 md:p-12\",\n  {\n    variants: {\n      tone: {\n        default: \"border-border bg-card text-card-foreground\",\n        primary: \"border-transparent bg-primary text-primary-foreground\",\n        muted: \"border-border bg-muted/40 text-foreground\",\n        glow: \"border-primary/20 bg-card text-card-foreground shadow-xl shadow-primary/5\",\n      },\n      align: {\n        left: \"items-start text-left\",\n        center: \"items-center text-center\",\n      },\n      size: {\n        sm: \"p-6 md:p-8\",\n        md: \"p-8 md:p-12\",\n        lg: \"p-12 md:p-16\",\n      },\n    },\n    defaultVariants: { tone: \"default\", align: \"center\", size: \"md\" },\n  }\n)\n\nexport const ctaTitleVariants = cva(\"font-bold tracking-tight text-balance\", {\n  variants: {\n    size: {\n      sm: \"text-xl\",\n      md: \"text-2xl md:text-3xl\",\n      lg: \"text-3xl md:text-4xl lg:text-5xl\",\n    },\n  },\n  defaultVariants: { size: \"md\" },\n})\n\n// ── Component ──────────────────────────────────────────────────────────────\n\nexport function Cta({\n  className,\n  badge,\n  title,\n  description,\n  primaryAction,\n  secondaryAction,\n  tone = \"default\",\n  align = \"center\",\n  size = \"md\",\n  loading = false,\n  ...props\n}: CtaProps) {\n  if (loading) {\n    return (\n      <div\n        data-slot=\"cta-skeleton\"\n        className={cn(\n          ctaVariants({ tone, align, size }),\n          \"flex flex-col gap-4\",\n          className\n        )}\n        {...props}\n      >\n        <Skeleton className=\"h-6 w-20 rounded-full\" />\n        <Skeleton className=\"h-8 w-3/4\" />\n        <Skeleton className=\"h-4 w-full max-w-xl\" />\n        <div className=\"flex gap-3 pt-2\">\n          <Skeleton className=\"h-10 w-32 rounded-full\" />\n          <Skeleton className=\"h-10 w-32 rounded-full\" />\n        </div>\n      </div>\n    )\n  }\n\n  return (\n    <div\n      data-slot=\"cta\"\n      className={cn(\n        ctaVariants({ tone, align, size }),\n        \"flex flex-col gap-6\",\n        align === \"center\" ? \"items-center\" : \"items-start\",\n        className\n      )}\n      {...props}\n    >\n      {tone === \"glow\" && (\n        <>\n          <div\n            className=\"pointer-events-none absolute -top-16 -right-16 size-72 rounded-full bg-primary/10 blur-3xl\"\n            aria-hidden=\"true\"\n          />\n          <div\n            className=\"pointer-events-none absolute -bottom-16 -left-16 size-72 rounded-full bg-highlight-violet/10 blur-3xl\"\n            aria-hidden=\"true\"\n          />\n        </>\n      )}\n\n      <div\n        className={cn(\n          \"relative z-10 flex max-w-2xl flex-col gap-3\",\n          align === \"center\" ? \"items-center\" : \"items-start\"\n        )}\n      >\n        {badge && (\n          <Badge\n            variant=\"outline\"\n            className=\"rounded-full px-3 py-1 text-xs font-medium\"\n          >\n            {badge}\n          </Badge>\n        )}\n        <h2\n          className={cn(\n            ctaTitleVariants({ size }),\n            align === \"center\" ? \"text-center\" : \"text-left\"\n          )}\n        >\n          {title}\n        </h2>\n        {description && (\n          <p\n            className={cn(\n              \"max-w-prose leading-relaxed text-pretty\",\n              tone === \"primary\"\n                ? \"text-primary-foreground/80\"\n                : \"text-muted-foreground\",\n              size === \"sm\" ? \"text-sm\" : \"text-sm md:text-base\"\n            )}\n          >\n            {description}\n          </p>\n        )}\n      </div>\n\n      {(primaryAction || secondaryAction) && (\n        <div\n          className={cn(\n            \"relative z-10 flex flex-wrap items-center gap-3\",\n            align === \"center\" ? \"justify-center\" : \"justify-start\"\n          )}\n        >\n          {primaryAction &&\n            (primaryAction.href ? (\n              <Button\n                asChild\n                size=\"lg\"\n                variant={tone === \"primary\" ? \"secondary\" : \"default\"}\n                className=\"gap-2 rounded-full font-semibold\"\n              >\n                <a href={primaryAction.href} onClick={primaryAction.onClick}>\n                  <span>{primaryAction.label}</span>\n                  {primaryAction.icon ?? (\n                    <ArrowRightIcon className=\"size-4\" aria-hidden=\"true\" />\n                  )}\n                </a>\n              </Button>\n            ) : (\n              <Button\n                size=\"lg\"\n                variant={tone === \"primary\" ? \"secondary\" : \"default\"}\n                className=\"gap-2 rounded-full font-semibold\"\n                onClick={primaryAction.onClick}\n              >\n                <span>{primaryAction.label}</span>\n                {primaryAction.icon ?? (\n                  <ArrowRightIcon className=\"size-4\" aria-hidden=\"true\" />\n                )}\n              </Button>\n            ))}\n          {secondaryAction &&\n            (secondaryAction.href ? (\n              <Button\n                asChild\n                size=\"lg\"\n                variant={tone === \"primary\" ? \"ghost\" : \"outline\"}\n                className=\"rounded-full font-medium\"\n              >\n                <a\n                  href={secondaryAction.href}\n                  onClick={secondaryAction.onClick}\n                >\n                  {secondaryAction.label}\n                </a>\n              </Button>\n            ) : (\n              <Button\n                size=\"lg\"\n                variant={tone === \"primary\" ? \"ghost\" : \"outline\"}\n                className=\"rounded-full font-medium\"\n                onClick={secondaryAction.onClick}\n              >\n                {secondaryAction.label}\n              </Button>\n            ))}\n        </div>\n      )}\n    </div>\n  )\n}\n",
      "type": "registry:ui"
    }
  ],
  "type": "registry:ui"
}
