{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "incentives-block",
  "title": "Incentives Block",
  "description": "A 'why shop with us' section: a scrolling ticker of store perks, a headline, and four incentive cards (shipping, returns, recycled packaging, support) with code-drawn illustrations that come alive on hover, a big stat, a short explanation and a link.",
  "dependencies": [
    "motion",
    "clsx",
    "tailwind-merge"
  ],
  "files": [
    {
      "path": "registry/new-york/incentives-block/incentives-block.tsx",
      "content": "\"use client\";\n\nimport * as React from \"react\";\nimport { motion, useReducedMotion } from \"motion/react\";\nimport { clsx, type ClassValue } from \"clsx\";\nimport { twMerge } from \"tailwind-merge\";\n\nfunction cn(...inputs: ClassValue[]) {\n  return twMerge(clsx(inputs));\n}\n\nexport interface Incentive {\n  id: string;\n  art: \"ship\" | \"return\" | \"recycle\" | \"support\";\n  stat: string;\n  title: string;\n  body: string;\n  link?: string;\n}\n\nexport interface IncentivesBlockProps {\n  eyebrow?: string;\n  title?: string;\n  incentives?: Incentive[];\n  ticker?: string[];\n  theme?: \"dark\" | \"light\";\n  className?: string;\n}\n\nconst PALETTES = {\n  dark: { bg: \"#0A0A0A\", title: \"#FFFFFF\", muted: \"rgba(255,255,255,0.45)\", body: \"rgba(255,255,255,0.62)\", line: \"rgba(255,255,255,0.12)\", card: \"#141414\", art: \"#1C1C1C\", ink: \"#FFFFFF\", accent: \"#7CDE6A\", ring: \"rgba(255,255,255,0.5)\" },\n  light: { bg: \"#FFFFFF\", title: \"#111111\", muted: \"rgba(0,0,0,0.45)\", body: \"rgba(0,0,0,0.62)\", line: \"rgba(0,0,0,0.1)\", card: \"#F7F7F6\", art: \"#EFEFED\", ink: \"#111111\", accent: \"#2F9E44\", ring: \"rgba(0,0,0,0.45)\" },\n};\nconst INCENTIVES: Incentive[] = [\n  { id: \"ship\", art: \"ship\", stat: \"2–4 days\", title: \"Free, fast shipping\", body: \"Free on orders over $50. Order before 2 pm and it leaves the same day, with tracking the whole way.\", link: \"Shipping details\" },\n  { id: \"return\", art: \"return\", stat: \"30 days\", title: \"Returns, no questions\", body: \"Changed your mind? Print a label from your order page and drop it at any parcel point. Refunds land in 3 days.\", link: \"How returns work\" },\n  { id: \"recycle\", art: \"recycle\", stat: \"100%\", title: \"Recycled packaging\", body: \"Every box, filler and label is recycled and recyclable. No plastic, ever, and we offset every delivery.\", link: \"Our materials\" },\n  { id: \"support\", art: \"support\", stat: \"< 2 min\", title: \"Real people, quickly\", body: \"Chat with our team in Berlin seven days a week. Average first reply is under two minutes.\", link: \"Contact us\" },\n];\nconst TICKER = [\"Free shipping over $50\", \"30-day free returns\", \"2-year warranty\", \"Pay in 3 interest-free parts\", \"Plastic-free packaging\", \"Support 7 days a week\"];\n\nfunction Art({ kind, on, p, reduce }: { kind: Incentive[\"art\"]; on: boolean; p: (typeof PALETTES)[\"dark\"]; reduce: boolean }) {\n  const loop = on && !reduce;\n  const stroke = { fill: \"none\", stroke: p.ink, strokeWidth: 2.2, strokeLinecap: \"round\" as const, strokeLinejoin: \"round\" as const };\n  if (kind === \"ship\")\n    return (\n      <svg viewBox=\"0 0 200 110\" className=\"h-full w-full\" aria-hidden=\"true\">\n        {[0, 1, 2].map((i) => (\n          <motion.line key={i} x1=\"20\" x2=\"50\" y1={44 + i * 12} y2={44 + i * 12} {...stroke} strokeOpacity={0.35} animate={loop ? { x: [30, -10], opacity: [0, 1, 0] } : { x: 0, opacity: 0.5 }} transition={{ repeat: Infinity, duration: 0.9, delay: i * 0.2, ease: \"linear\" }} />\n        ))}\n        <motion.g animate={loop ? { y: [0, -1.5, 0] } : { y: 0 }} transition={{ repeat: Infinity, duration: 0.35 }}>\n          <path d=\"M62 38h62v40H62z M124 52h22l14 14v12h-36z\" {...stroke} />\n          <path d=\"M70 52h30\" {...stroke} stroke={p.accent} />\n        </motion.g>\n        {[84, 146].map((cx) => (\n          <motion.g key={cx} style={{ transformBox: \"fill-box\", originX: 0.5, originY: 0.5 }} animate={loop ? { rotate: 360 } : { rotate: 0 }} transition={{ repeat: Infinity, duration: 0.6, ease: \"linear\" }}>\n            <circle cx={cx} cy=\"82\" r=\"9\" {...stroke} fill={p.art} />\n            <path d={`M${cx} 75v14M${cx - 7} 82h14`} {...stroke} strokeWidth={1.4} />\n          </motion.g>\n        ))}\n        <line x1=\"20\" x2=\"186\" y1=\"93\" y2=\"93\" {...stroke} strokeOpacity={0.25} />\n      </svg>\n    );\n  if (kind === \"return\")\n    return (\n      <svg viewBox=\"0 0 200 110\" className=\"h-full w-full\" aria-hidden=\"true\">\n        <motion.path d=\"M100 18a38 38 0 1 1-36 26\" {...stroke} strokeOpacity={0.35} animate={loop ? { pathLength: [0, 1] } : { pathLength: 1 }} transition={{ repeat: Infinity, duration: 1.6, ease: \"easeInOut\" }} />\n        <motion.path d=\"M58 30l6 14 14-6\" {...stroke} strokeOpacity={0.6} />\n        <motion.g animate={loop ? { rotate: [0, -8, 8, 0], y: [0, -4, 0] } : { rotate: 0, y: 0 }} style={{ transformBox: \"fill-box\", originX: 0.5, originY: 0.5 }} transition={{ repeat: Infinity, duration: 1.6 }}>\n          <path d=\"M78 54l22-10 22 10v26l-22 10-22-10z M78 54l22 10 22-10 M100 64v26\" {...stroke} />\n          <path d=\"M89 49l22 10\" {...stroke} stroke={p.accent} />\n        </motion.g>\n      </svg>\n    );\n  if (kind === \"recycle\") {\n    const arc = (start: number) => {\n      const r = 30;\n      const pt = (deg: number) => [100 + r * Math.cos((deg * Math.PI) / 180), 56 + r * Math.sin((deg * Math.PI) / 180)].map((v) => v.toFixed(1)).join(\" \");\n      const end = start + 92;\n      const tip = (deg: number, off: number) => [100 + (r + off) * Math.cos((deg * Math.PI) / 180), 56 + (r + off) * Math.sin((deg * Math.PI) / 180)].map((v) => v.toFixed(1)).join(\" \");\n      return { d: `M${pt(start)} A${r} ${r} 0 0 1 ${pt(end)}`, head: `M${tip(end - 12, 7)} L${pt(end)} L${tip(end - 12, -7)}` };\n    };\n    return (\n      <svg viewBox=\"0 0 200 110\" className=\"h-full w-full\" aria-hidden=\"true\">\n        <motion.g style={{ transformBox: \"fill-box\", originX: 0.5, originY: 0.5 }} animate={loop ? { rotate: 360 } : { rotate: 0 }} transition={{ repeat: Infinity, duration: 5, ease: \"linear\" }}>\n          {[-80, 40, 160].map((st, i) => {\n            const a = arc(st);\n            return (\n              <g key={st}>\n                <path d={a.d} {...stroke} stroke={i === 0 ? p.accent : p.ink} />\n                <path d={a.head} {...stroke} stroke={i === 0 ? p.accent : p.ink} />\n              </g>\n            );\n          })}\n        </motion.g>\n        <path d=\"M92 52h16v14H92z M92 52l8 5 8-5\" {...stroke} strokeWidth={1.6} />\n      </svg>\n    );\n  }\n  return (\n    <svg viewBox=\"0 0 200 110\" className=\"h-full w-full\" aria-hidden=\"true\">\n      <path d=\"M52 30h70v40H86l-16 12V70H52z\" {...stroke} />\n      <motion.path d=\"M96 44h56v34h-14v10l-12-10H96z\" {...stroke} fill={p.art} animate={loop ? { y: [8, 0], opacity: [0, 1] } : { y: 0, opacity: 1 }} transition={{ repeat: Infinity, duration: 1.8, repeatDelay: 0.6 }} />\n      {[0, 1, 2].map((i) => (\n        <motion.circle key={i} cx={66 + i * 14} cy=\"50\" r=\"3\" fill={i === 1 ? p.accent : p.ink} animate={loop ? { y: [0, -5, 0] } : { y: 0 }} transition={{ repeat: Infinity, duration: 0.9, delay: i * 0.15 }} />\n      ))}\n    </svg>\n  );\n}\n\nexport function IncentivesBlock({ eyebrow = \"Why Northline\", title = \"Everything you'd expect, and a little more\", incentives = INCENTIVES, ticker = TICKER, theme = \"dark\", className }: IncentivesBlockProps) {\n  const p = PALETTES[theme];\n  const reduce = !!useReducedMotion();\n  const [hover, setHover] = React.useState<string | null>(incentives[0]?.id ?? null);\n  const ring = { [\"--tw-ring-color\" as string]: p.ring, [\"--tw-ring-offset-color\" as string]: p.card } as React.CSSProperties;\n  const items = [...ticker, ...ticker];\n\n  return (\n    <section className={cn(\"@container w-full overflow-hidden\", className)} style={{ background: p.bg, color: p.title }}>\n      <div className=\"border-y py-3\" style={{ borderColor: p.line }} aria-label={ticker.join(\", \")}>\n        <motion.div className=\"flex w-max gap-10 whitespace-nowrap\" animate={reduce ? undefined : { x: [\"0%\", \"-50%\"] }} transition={{ repeat: Infinity, duration: 28, ease: \"linear\" }} aria-hidden=\"true\">\n          {items.map((t, i) => (\n            <span key={i} className=\"flex items-center gap-10 text-[13px] font-medium\" style={{ color: p.body }}>\n              {t}\n              <span className=\"h-1.5 w-1.5 rounded-full\" style={{ background: p.accent }} />\n            </span>\n          ))}\n        </motion.div>\n      </div>\n\n      <div className=\"mx-auto max-w-6xl px-4 py-14 @[640px]:px-8\">\n        <p className=\"m-0 text-[12px] font-semibold tracking-[0.12em] uppercase\" style={{ color: p.accent }}>\n          {eyebrow}\n        </p>\n        <h2 className=\"m-0 mt-3 max-w-[18ch] text-[32px] leading-[1.05] font-semibold tracking-[-0.03em] @[640px]:text-[46px]\">{title}</h2>\n\n        <ul className=\"m-0 mt-10 grid list-none grid-cols-1 gap-3 p-0 @[600px]:grid-cols-2 @[1000px]:grid-cols-4\">\n          {incentives.map((it, i) => {\n            const on = hover === it.id;\n            return (\n              <motion.li\n                key={it.id}\n                initial={reduce ? false : { opacity: 0, y: 18 }}\n                animate={{ opacity: 1, y: 0 }}\n                transition={{ duration: 0.5, delay: reduce ? 0 : i * 0.08, ease: [0.22, 1, 0.36, 1] }}\n                onMouseEnter={() => setHover(it.id)}\n                onFocus={() => setHover(it.id)}\n                className=\"group flex flex-col rounded-3xl border p-3 transition-colors\"\n                style={{ borderColor: on ? p.title : p.line, background: p.card }}\n              >\n                <div className=\"relative h-[130px] overflow-hidden rounded-2xl\" style={{ background: p.art }}>\n                  <Art kind={it.art} on={on} p={p} reduce={reduce} />\n                </div>\n                <div className=\"flex flex-1 flex-col px-2 pt-4 pb-2\">\n                  <span className=\"text-[30px] leading-none font-semibold tracking-[-0.03em] tabular-nums\">{it.stat}</span>\n                  <h3 className=\"m-0 mt-3 text-[16px] font-semibold\">{it.title}</h3>\n                  <p className=\"m-0 mt-1.5 flex-1 text-[13.5px] leading-relaxed\" style={{ color: p.body }}>\n                    {it.body}\n                  </p>\n                  {it.link && (\n                    <a href=\"#\" className=\"mt-4 inline-flex w-fit items-center gap-1.5 rounded text-[13px] font-medium no-underline outline-none focus-visible:ring-2 focus-visible:ring-offset-2\" style={{ color: p.title, ...ring }}>\n                      {it.link}\n                      <motion.span animate={{ x: on && !reduce ? 3 : 0 }} aria-hidden=\"true\">\n                        →\n                      </motion.span>\n                    </a>\n                  )}\n                </div>\n              </motion.li>\n            );\n          })}\n        </ul>\n      </div>\n    </section>\n  );\n}\n\nexport default IncentivesBlock;\n",
      "type": "registry:component"
    }
  ],
  "type": "registry:component"
}