{"$schema":"https://ui.shadcn.com/schema/registry-item.json","name":"plant-nursery-footer-wordmark-grows-from-the-ground","type":"registry:block","title":"Plant Nursery Footer With Growing Wordmark","description":"","dependencies":[],"files":[{"path":"components/we-inc/plant-nursery-footer-wordmark-grows-from-the-ground.tsx","type":"registry:component","content":"import { useEffect, useRef } from \"react\";\nimport type { CSSProperties } from \"react\";\n\nconst THRESHOLD = 0.2; // share of the wordmark that must be visible before it grows\n\n// Same markup, styles and script as the plain HTML version.\nconst STYLES = `\n/* Change these: background, text, muted text, rule colour, accent (links' focus ring and highlights). */\n  .w4grw { --w4grw-bg: #1b2a20; --w4grw-ink: #e3e9da; --w4grw-muted: #a9b8a1; --w4grw-line: #2f4234; --w4grw-accent: #b6d08f; }\n  .w4grw { position: relative; overflow: hidden; background: var(--w4grw-bg); color: var(--w4grw-ink); font-family: ui-sans-serif, system-ui, -apple-system, \"Segoe UI\", Roboto, \"Helvetica Neue\", Arial, sans-serif; padding: 72px clamp(20px, 4vw, 56px) 24px; }\n  .w4grw *, .w4grw *::before, .w4grw *::after { box-sizing: border-box; }\n  .w4grw-in { max-width: 1240px; margin: 0 auto; }\n  .w4grw-top { display: grid; grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr)); gap: 32px 40px; }\n  .w4grw-brand { margin: 0; font-size: 18px; font-weight: 650; letter-spacing: -.01em; }\n  .w4grw-blurb { margin: 12px 0 0; max-width: 32ch; font-size: 15px; line-height: 1.6; color: var(--w4grw-muted); }\n  .w4grw-addr { margin: 16px 0 0; font-style: normal; font-size: 14px; line-height: 1.65; color: var(--w4grw-muted); }\n  .w4grw-col h2 { margin: 0 0 6px; font-size: 12px; font-weight: 650; letter-spacing: .14em; text-transform: uppercase; color: var(--w4grw-muted); }\n  .w4grw-col ul, .w4grw-legal ul { list-style: none; margin: 0; padding: 0; }\n  .w4grw-col a, .w4grw-legal a { display: inline-flex; align-items: center; min-height: 40px; color: inherit; text-decoration: none; font-size: 15px; border-radius: 3px; }\n  .w4grw-col a:hover, .w4grw-legal a:hover { text-decoration: underline; text-underline-offset: 4px; }\n  .w4grw a:focus-visible { outline: 2px solid var(--w4grw-accent); outline-offset: 3px; }\n  .w4grw-big { container-type: inline-size; margin: 56px 0 0; }\n  .w4grw-legal { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0 24px; margin-top: 24px; padding-top: 6px; border-top: 1px solid var(--w4grw-line); font-size: 13px; color: var(--w4grw-muted); }\n  .w4grw-legal p { margin: 10px 0; }\n  .w4grw-legal ul { display: flex; flex-wrap: wrap; gap: 0 20px; }\n  .w4grw-legal a { font-size: 13px; }\n  .w4grw-sr { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }\n  @media (max-width: 760px) {\n    .w4grw { padding-top: 56px; }\n    .w4grw-top { grid-template-columns: 1fr 1fr; gap: 24px 20px; }\n    .w4grw-lead { grid-column: 1 / -1; }\n  }\n  /* Change these: wordmark size, growth speed, delay between letters. */\n  .w4grw { --w4grw-size: 22.5cqi; --w4grw-speed: .95s; --w4grw-step: 75ms; }\n  .w4grw-word { margin: 0; white-space: nowrap; overflow: hidden; text-align: center; font-family: ui-rounded, \"SF Pro Rounded\", \"Nunito\", \"Arial Rounded MT Bold\", system-ui, sans-serif; font-weight: 800; font-size: var(--w4grw-size); line-height: .9; letter-spacing: -.045em; color: var(--w4grw-ink); padding: .04em 0 .2em; margin-bottom: 0; }\n  .w4grw-l { display: inline-block; transform-origin: 50% 100%; transition: transform var(--w4grw-speed) cubic-bezier(.34, 1.45, .6, 1) calc(var(--i) * var(--w4grw-step)), opacity .4s ease calc(var(--i) * var(--w4grw-step)); }\n  .w4grw-l:nth-child(3n + 2) { color: var(--w4grw-accent); }\n  .w4grw-ground { height: 2px; margin: 0; background: var(--w4grw-accent); transform-origin: 0 50%; transition: transform 1.1s cubic-bezier(.2, .8, .2, 1); }\n  .w4grw[data-arm]:not([data-in]) .w4grw-l { transform: scaleY(.06); opacity: .25; }\n  .w4grw[data-arm]:not([data-in]) .w4grw-ground { transform: scaleX(0); }\n  .w4grw-tag { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 4px 16px; margin: 12px 0 0; font-size: 14px; color: var(--w4grw-muted); }\n  @media (prefers-reduced-motion: reduce) { .w4grw-l, .w4grw-ground { transition: none; transform: none !important; opacity: 1 !important; } }\n`;\n\nexport default function PlantNurseryFooterWordmarkGrows() {\n  const ref = useRef<HTMLElement>(null);\n  useEffect(() => {\n    const root: any = ref.current;\n    if (!root) return;\n    if (matchMedia(\"(prefers-reduced-motion: reduce)\").matches) return;\n    var target = root.querySelector(\".w4grw-word\");\n    root.setAttribute(\"data-arm\", \"\");\n    var io = new IntersectionObserver(function (en) {\n      if (en[0].isIntersecting) root.setAttribute(\"data-in\", \"\");\n      else root.removeAttribute(\"data-in\");\n    }, { threshold: THRESHOLD });\n    io.observe(target);\n    return function () { io.disconnect(); };\n  }, []);\n\n  return (\n    <footer className=\"w4grw\" ref={ref}>\n      <style>{STYLES}</style>\n      <div className=\"w4grw-in\">\n        <div className=\"w4grw-top\">\n          <div className=\"w4grw-lead\">\n            <p className=\"w4grw-brand\">Mossery Plant Nursery</p>\n            <p className=\"w4grw-blurb\">\n              Ferns, shade perennials and potted mosses raised under glass on the edge of Holloway Woods.\n            </p>\n            <address className=\"w4grw-addr\">\n              Glasshouse 2, Holloway Woods Road\n              <br />\n              Open Thursday to Sunday, 9am to 5pm\n              <br />\n              0117 320 4471\n            </address>\n          </div>\n          <div className=\"w4grw-col\">\n            <h2>Plants</h2>\n            <ul>\n              <li>\n                <a href=\"#\">Ferns</a>\n              </li>\n              <li>\n                <a href=\"#\">Shade perennials</a>\n              </li>\n              <li>\n                <a href=\"#\">Moss pots</a>\n              </li>\n              <li>\n                <a href=\"#\">Gift cards</a>\n              </li>\n            </ul>\n          </div>\n          <div className=\"w4grw-col\">\n            <h2>Grow</h2>\n            <ul>\n              <li>\n                <a href=\"#\">Care guides</a>\n              </li>\n              <li>\n                <a href=\"#\">Repotting days</a>\n              </li>\n              <li>\n                <a href=\"#\">Plant doctor</a>\n              </li>\n            </ul>\n          </div>\n          <div className=\"w4grw-col\">\n            <h2>Nursery</h2>\n            <ul>\n              <li>\n                <a href=\"#\">Visit us</a>\n              </li>\n              <li>\n                <a href=\"#\">Wholesale</a>\n              </li>\n              <li>\n                <a href=\"#\">Volunteer</a>\n              </li>\n            </ul>\n          </div>\n        </div>\n        <div className=\"w4grw-big\">\n          <p className=\"w4grw-word\" aria-hidden=\"true\">\n            {\"mossery\".split(\"\").map((c, i) => (\n              <span key={i} className=\"w4grw-l\" style={{ \"--i\": i } as CSSProperties}>{c === \" \" ? \"\\u00a0\" : c}</span>\n            ))}\n          </p>\n          <p className=\"w4grw-ground\" aria-hidden=\"true\" />\n          <p className=\"w4grw-tag\">\n            <span>Peat-free compost, always</span>\n            <span>Sunday seed swap at ten</span>\n          </p>\n        </div>\n        <div className=\"w4grw-legal\">\n          <p>© 2026 Mossery Plant Nursery. Grown in the Avon valley.</p>\n          <ul>\n            <li>\n              <a href=\"#\">Privacy</a>\n            </li>\n            <li>\n              <a href=\"#\">Delivery</a>\n            </li>\n            <li>\n              <a href=\"#\">Returns</a>\n            </li>\n          </ul>\n        </div>\n      </div>\n    </footer>\n  );\n}\n"}]}
