{
  "$schema": "https://ui.shadcn.com/schema/registry-item.json",
  "name": "footer-newsletter-first",
  "type": "registry:component",
  "title": "Footer Newsletter First",
  "description": "A paper toned footer led by a large newsletter signup with a light beam circling the email field, followed by a five column sitemap and a status bar.",
  "author": "Hyperblur <hello@hyperblur.dev>",
  "dependencies": [],
  "registryDependencies": [],
  "categories": [
    "footer",
    "footer",
    "newsletter",
    "signup",
    "sitemap",
    "light",
    "form"
  ],
  "docs": "https://hyperblur.dev/effects/footer-newsletter-first",
  "files": [
    {
      "path": "registry/hyperblur/footer-newsletter-first.tsx",
      "type": "registry:component",
      "target": "components/hyperblur/footer-newsletter-first.tsx",
      "content": "\"use client\";\n\nimport * as React from \"react\";\n\nexport interface FooterNewsletterLink {\n  label: string;\n  href: string;\n}\n\nexport interface FooterNewsletterColumn {\n  title: string;\n  links: FooterNewsletterLink[];\n}\n\nexport interface FooterNewsletterFirstProps extends Omit<React.HTMLAttributes<HTMLElement>, \"title\"> {\n  eyebrow?: string;\n  title?: string;\n  subtitle?: string;\n  placeholder?: string;\n  buttonLabel?: string;\n  proof?: string;\n  brand?: string;\n  columns?: FooterNewsletterColumn[];\n  legal?: string;\n  onSubscribe?: (email: string) => void | Promise<unknown>;\n  accent?: string;\n}\n\nconst defaultColumns: FooterNewsletterColumn[] = [\n  { title: \"Product\", links: [{ label: \"Overview\", href: \"#\" }, { label: \"Field app\", href: \"#\" }, { label: \"Integrations\", href: \"#\" }, { label: \"Changelog\", href: \"#\" }, { label: \"Pricing\", href: \"#\" }] },\n  { title: \"Resources\", links: [{ label: \"Guides\", href: \"#\" }, { label: \"Templates\", href: \"#\" }, { label: \"API reference\", href: \"#\" }, { label: \"Community\", href: \"#\" }] },\n  { title: \"Company\", links: [{ label: \"About\", href: \"#\" }, { label: \"Careers\", href: \"#\" }, { label: \"Press kit\", href: \"#\" }, { label: \"Contact\", href: \"#\" }] },\n  { title: \"Legal\", links: [{ label: \"Privacy\", href: \"#\" }, { label: \"Terms\", href: \"#\" }, { label: \"Security\", href: \"#\" }, { label: \"DPA\", href: \"#\" }] },\n  { title: \"Follow\", links: [{ label: \"LinkedIn\", href: \"#\" }, { label: \"YouTube\", href: \"#\" }, { label: \"GitHub\", href: \"#\" }, { label: \"RSS\", href: \"#\" }] },\n];\n\nconst css = `\n@property --hb-yi3-angle { syntax: \"<angle>\"; inherits: false; initial-value: 0deg; }\n.hb-yi3 {\n  --hb-yi3-accent: #1f8a5b;\n  container-type: inline-size;\n  position: relative;\n  box-sizing: border-box;\n  width: 100%;\n  overflow: hidden;\n  background: #f7f5ef;\n  color: #17160f;\n  font-family: inherit;\n  -webkit-font-smoothing: antialiased;\n}\n.hb-yi3 *, .hb-yi3 *::before, .hb-yi3 *::after { box-sizing: border-box; }\n.hb-yi3-inner { max-width: 1120px; margin: 0 auto; padding: 72px 20px 28px; }\n.hb-yi3-hero { display: grid; gap: 28px; padding-bottom: 56px; border-bottom: 1px solid rgba(23, 22, 15, .12); }\n.hb-yi3-eyebrow { display: inline-flex; align-items: center; gap: 10px; margin: 0; font-size: 13px; font-weight: 600; color: var(--hb-yi3-accent); }\n.hb-yi3-issue { padding: 3px 8px; border-radius: 6px; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: #fff; background: var(--hb-yi3-accent); }\n.hb-yi3-title { margin: 14px 0 0; font-size: clamp(34px, 6.6cqi, 76px); line-height: .98; letter-spacing: -.045em; font-weight: 600; max-width: 12ch; }\n.hb-yi3-title em { font-style: normal; font-weight: 500; color: var(--hb-yi3-accent); }\n.hb-yi3-sub { margin: 18px 0 0; max-width: 440px; font-size: 16px; line-height: 1.6; color: #5f5b4f; }\n.hb-yi3-form { align-self: end; width: 100%; }\n.hb-yi3-shell {\n  position: relative; border-radius: 22px; padding: 2px;\n  background: conic-gradient(from var(--hb-yi3-angle), rgba(23, 22, 15, .1) 0deg, rgba(23, 22, 15, .1) 250deg, var(--hb-yi3-accent) 310deg, color-mix(in srgb, var(--hb-yi3-accent) 40%, #f5d76e) 340deg, rgba(23, 22, 15, .1) 360deg);\n  animation: hb-yi3-spin 5s linear infinite;\n  box-shadow: 0 30px 60px -36px rgba(23, 22, 15, .45);\n}\n.hb-yi3-shell[data-state=\"error\"] { background: #c2412d; animation: hb-yi3-shake .4s; }\n.hb-yi3-field { display: flex; align-items: center; gap: 8px; padding: 8px; border-radius: 20px; background: #fffefb; }\n.hb-yi3-field svg { width: 22px; height: 22px; margin-left: 12px; color: #8c877b; flex: none; }\n.hb-yi3-input {\n  flex: 1; min-width: 0; height: 56px; border: 0; outline: none; background: transparent; color: #17160f;\n  font: inherit; font-size: clamp(17px, 2.2cqi, 22px); letter-spacing: -.01em;\n}\n.hb-yi3-input::placeholder { color: #a8a395; }\n.hb-yi3-btn {\n  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 56px; padding: 0 22px; border: 0; border-radius: 14px; flex: none;\n  background: #17160f; color: #fffefb; font: inherit; font-size: 15px; font-weight: 600; cursor: pointer;\n  box-shadow: 0 1px 0 rgba(255, 255, 255, .18) inset; transition: background .2s, transform .2s;\n}\n.hb-yi3-btn:hover:not(:disabled) { background: var(--hb-yi3-accent); transform: translateY(-1px); }\n.hb-yi3-btn:disabled { cursor: progress; }\n.hb-yi3-btn:focus-visible, .hb-yi3-col a:focus-visible, .hb-yi3-brand:focus-visible { outline: 2px solid var(--hb-yi3-accent); outline-offset: 3px; }\n.hb-yi3-btn svg { width: 16px; height: 16px; margin: 0; color: currentColor; transition: transform .2s; }\n.hb-yi3-btn:hover svg { transform: translateX(3px); }\n.hb-yi3-spin { width: 16px; height: 16px; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .3); border-top-color: #fff; animation: hb-yi3-rot .7s linear infinite; }\n.hb-yi3-meta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; font-size: 13px; color: #6f6a5d; }\n.hb-yi3-proof { display: inline-flex; align-items: center; gap: 10px; }\n.hb-yi3-faces { display: flex; }\n.hb-yi3-faces i { width: 22px; height: 22px; border-radius: 50%; margin-left: -6px; border: 2px solid #f7f5ef; }\n.hb-yi3-faces i:first-child { margin-left: 0; }\n.hb-yi3-err { color: #c2412d; font-weight: 500; }\n.hb-yi3-ok {\n  display: flex; align-items: center; gap: 14px; padding: 18px 20px; border-radius: 20px; background: #fffefb;\n  border: 1px solid color-mix(in srgb, var(--hb-yi3-accent) 35%, transparent); animation: hb-yi3-up .5s cubic-bezier(.2, .8, .2, 1) both;\n}\n.hb-yi3-ok span { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--hb-yi3-accent); color: #fff; flex: none; }\n.hb-yi3-ok svg { width: 22px; height: 22px; }\n.hb-yi3-ok path { stroke-dasharray: 30; stroke-dashoffset: 30; animation: hb-yi3-draw .5s .15s ease-out forwards; }\n.hb-yi3-ok p { margin: 0; font-size: 15px; line-height: 1.5; }\n.hb-yi3-ok b { display: block; font-size: 17px; }\n.hb-yi3-map { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 20px; padding: 48px 0; }\n.hb-yi3-col h3 { margin: 0 0 14px; font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: #8c877b; }\n.hb-yi3-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }\n.hb-yi3-col a { position: relative; color: #2d2b23; text-decoration: none; font-size: 15px; transition: color .2s; }\n.hb-yi3-col a::after { content: \"\"; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform .3s cubic-bezier(.2, .8, .2, 1); }\n.hb-yi3-col a:hover { color: var(--hb-yi3-accent); }\n.hb-yi3-col a:hover::after { transform: scaleX(1); transform-origin: left; }\n.hb-yi3-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; padding-top: 22px; border-top: 1px solid rgba(23, 22, 15, .12); font-size: 13px; color: #6f6a5d; }\n.hb-yi3-brand { display: inline-flex; align-items: center; gap: 10px; color: #17160f; text-decoration: none; font-weight: 700; font-size: 16px; letter-spacing: -.02em; }\n.hb-yi3-mark { width: 26px; height: 26px; border-radius: 8px; background: #17160f; display: grid; place-items: center; }\n.hb-yi3-mark i { width: 10px; height: 10px; border-radius: 50%; border: 2.5px solid var(--hb-yi3-accent); }\n.hb-yi3-status { display: inline-flex; align-items: center; gap: 8px; }\n.hb-yi3-status::before { content: \"\"; width: 7px; height: 7px; border-radius: 50%; background: #22a06b; box-shadow: 0 0 0 3px rgba(34, 160, 107, .18); }\n@keyframes hb-yi3-spin { to { --hb-yi3-angle: 360deg; } }\n@keyframes hb-yi3-rot { to { transform: rotate(360deg); } }\n@keyframes hb-yi3-up { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }\n@keyframes hb-yi3-draw { to { stroke-dashoffset: 0; } }\n@keyframes hb-yi3-shake { 25% { transform: translateX(-6px); } 50% { transform: translateX(5px); } 75% { transform: translateX(-3px); } }\n@container (min-width: 560px) {\n  .hb-yi3-map { grid-template-columns: repeat(3, minmax(0, 1fr)); }\n}\n@container (min-width: 860px) {\n  .hb-yi3-inner { padding: 112px 32px 32px; }\n  .hb-yi3-hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 56px; padding-bottom: 80px; }\n  .hb-yi3-map { grid-template-columns: repeat(5, minmax(0, 1fr)); padding: 56px 0 64px; }\n}\n@media (prefers-reduced-motion: reduce) {\n  .hb-yi3-shell, .hb-yi3-ok, .hb-yi3-ok path { animation: none; stroke-dashoffset: 0; }\n  .hb-yi3-btn, .hb-yi3-btn svg, .hb-yi3-col a, .hb-yi3-col a::after { transition: none; }\n}\n`;\n\nconst faceColors = [\"#1f8a5b\", \"#e2553f\", \"#2f7bff\", \"#d4a017\"];\n\nconst emailOk = (v: string) => /^[^\\s@]+@[^\\s@]+\\.[^\\s@]{2,}$/.test(v.trim());\n\nexport function FooterNewsletterFirst({\n  eyebrow = \"The Friday brief\",\n  title = \"One good email, every Friday.\",\n  subtitle = \"Product changes, field notes from teams running audits at scale, and one link worth your weekend. Four minutes to read.\",\n  placeholder = \"you@company.com\",\n  buttonLabel = \"Subscribe\",\n  proof = \"Read by 38,412 operators\",\n  brand = \"Fieldnote\",\n  columns = defaultColumns,\n  legal = \"© 2026 Fieldnote Labs, Inc.\",\n  onSubscribe,\n  accent = \"#1f8a5b\",\n  className = \"\",\n  style,\n  ...rest\n}: FooterNewsletterFirstProps) {\n  const [email, setEmail] = React.useState(\"\");\n  const [status, setStatus] = React.useState<\"idle\" | \"error\" | \"loading\" | \"done\">(\"idle\");\n  const timer = React.useRef<number | undefined>(undefined);\n  const id = React.useId();\n\n  React.useEffect(() => () => window.clearTimeout(timer.current), []);\n\n  const submit = async (e: React.FormEvent) => {\n    e.preventDefault();\n    if (status === \"loading\") return;\n    if (!emailOk(email)) {\n      setStatus(\"error\");\n      return;\n    }\n    setStatus(\"loading\");\n    try {\n      await onSubscribe?.(email.trim());\n    } catch {\n      setStatus(\"error\");\n      return;\n    }\n    timer.current = window.setTimeout(() => setStatus(\"done\"), 800);\n  };\n\n  const vars = { \"--hb-yi3-accent\": accent, ...style } as React.CSSProperties;\n  const titleParts = title.split(\", \");\n\n  return (\n    <footer className={`hb-yi3 ${className}`} style={vars} {...rest}>\n      <style href=\"hb-footer-newsletter-first\" precedence=\"default\">{css}</style>\n      <div className=\"hb-yi3-inner\">\n        <div className=\"hb-yi3-hero\">\n          <div>\n            {eyebrow ? (\n              <p className=\"hb-yi3-eyebrow\">\n                <span className=\"hb-yi3-issue\">No. 142</span>\n                {eyebrow}\n              </p>\n            ) : null}\n            <h2 className=\"hb-yi3-title\">\n              {titleParts.length > 1 ? (\n                <>\n                  {titleParts[0]}, <em>{titleParts.slice(1).join(\", \")}</em>\n                </>\n              ) : (\n                title\n              )}\n            </h2>\n            {subtitle ? <p className=\"hb-yi3-sub\">{subtitle}</p> : null}\n          </div>\n          <div className=\"hb-yi3-form\">\n            {status === \"done\" ? (\n              <div className=\"hb-yi3-ok\" role=\"status\">\n                <span>\n                  <svg viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" strokeWidth=\"2.4\" strokeLinecap=\"round\" strokeLinejoin=\"round\" aria-hidden=\"true\">\n                    <path d=\"M5 12.5l4.5 4.5L19 7.5\" />\n                  </svg>\n                </span>\n                <p>\n                  <b>You are on the list.</b>\n                  {`Issue 143 lands in ${email.trim()} this Friday at 8:00.`}\n                </p>\n              </div>\n            ) : (\n              <form noValidate onSubmit={submit} aria-busy={status === \"loading\" || undefined}>\n                <label htmlFor={`${id}-email`} style={{ position: \"absolute\", width: 1, height: 1, overflow: \"hidden\", clip: \"rect(0 0 0 0)\", whiteSpace: \"nowrap\" }}>\n                  Email address\n                </label>\n                <div className=\"hb-yi3-shell\" data-state={status === \"error\" ? \"error\" : \"idle\"}>\n                  <div className=\"hb-yi3-field\">\n                    <svg viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" strokeWidth=\"1.8\" strokeLinecap=\"round\" strokeLinejoin=\"round\" aria-hidden=\"true\">\n                      <path d=\"M4 6h16v12H4zM4 7l8 6 8-6\" />\n                    </svg>\n                    <input\n                      id={`${id}-email`}\n                      className=\"hb-yi3-input\"\n                      type=\"email\"\n                      autoComplete=\"email\"\n                      placeholder={placeholder}\n                      value={email}\n                      aria-invalid={status === \"error\"}\n                      aria-describedby={`${id}-meta`}\n                      onChange={(e) => {\n                        setEmail(e.target.value);\n                        if (status === \"error\") setStatus(\"idle\");\n                      }}\n                    />\n                    <button type=\"submit\" className=\"hb-yi3-btn\" disabled={status === \"loading\"}>\n                      {status === \"loading\" ? <span className=\"hb-yi3-spin\" aria-hidden=\"true\" /> : null}\n                      {status === \"loading\" ? \"Joining\" : buttonLabel}\n                      {status === \"loading\" ? null : (\n                        <svg viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" strokeWidth=\"2\" strokeLinecap=\"round\" strokeLinejoin=\"round\" aria-hidden=\"true\">\n                          <path d=\"M5 12h14M13 6l6 6-6 6\" />\n                        </svg>\n                      )}\n                    </button>\n                  </div>\n                </div>\n                <div className=\"hb-yi3-meta\" id={`${id}-meta`}>\n                  {status === \"error\" ? (\n                    <span className=\"hb-yi3-err\" role=\"alert\">Enter a valid email so we know where to send it.</span>\n                  ) : (\n                    <span className=\"hb-yi3-proof\">\n                      <span className=\"hb-yi3-faces\" aria-hidden=\"true\">\n                        {faceColors.map((c) => (\n                          <i key={c} style={{ background: `linear-gradient(135deg, ${c}, #f7f5ef)` }} />\n                        ))}\n                      </span>\n                      {proof}\n                    </span>\n                  )}\n                  <span>No spam. Unsubscribe in one click.</span>\n                </div>\n              </form>\n            )}\n          </div>\n        </div>\n        <nav className=\"hb-yi3-map\" aria-label=\"Footer\">\n          {columns.map((col) => (\n            <div key={col.title} className=\"hb-yi3-col\">\n              <h3>{col.title}</h3>\n              <ul>\n                {col.links.map((l) => (\n                  <li key={l.label}>\n                    <a href={l.href}>{l.label}</a>\n                  </li>\n                ))}\n              </ul>\n            </div>\n          ))}\n        </nav>\n        <div className=\"hb-yi3-bar\">\n          <a className=\"hb-yi3-brand\" href=\"#\">\n            <span className=\"hb-yi3-mark\" aria-hidden=\"true\">\n              <i />\n            </span>\n            {brand}\n          </a>\n          <span className=\"hb-yi3-status\">All systems normal</span>\n          <span>{legal}</span>\n        </div>\n      </div>\n    </footer>\n  );\n}\n"
    }
  ]
}