# Ferro hero

> A voice AI hero where a dish of ferrofluid is the agent’s voice: spikes rise with every word, drop flat the instant the caller cuts in, and reach for the pointer like a magnet.

Voice AI pages usually show a glowing orb or a waveform beside the headline, and a stranger can’t tell what the product does better. Ferro hero puts a dish of ferrofluid under the nav and plays a real call through it. While the agent talks, the spikes rise in time with each word as the subtitle lights up. When the caller talks, rings run inward over the fluid and the plate. Mid-sentence the caller cuts in, the crown drops at once and the cut line is stamped "Stopped in 38 ms". Visitors can hold the dish to talk over it themselves, and the spikes lean toward the pointer like iron filings toward a magnet. The fluid is one WebGL shader with no 3D library, and the headline sits under it like a title card.

## Install

```bash
npx shadcn@latest add @hairline-pro/ferro-hero
```

Needs React 19, Tailwind CSS v4 and shadcn/ui theme variables (any style, light and dark). Icons from lucide-react.

- npm: `lucide-react`
- Hairline UI components it needs (the CLI installs them too): none
- Docs and live preview: https://hairlineui.com/blocks/ferro-hero
- Premium block, included with All-Access (https://hairlineui.com/buy/all-access?from=blocks). Installs only with an All-Access token through the @hairline-pro registry: https://hairlineui.com/ui/installation#premium. Its source isn't public.

## Usage

```tsx
import { FerroHero } from "@/components/ferro-hero";

<FerroHero
  brand="Cadence"
  eyebrow="Realtime voice agents for phone and web"
  headline={["Voice agents that", "stop when you talk"]}
  highlight="stop when you talk"
  subheadline="Cadence answers in 180 ms and hands the turn back mid-word."
  primaryAction={{ label: "Call the demo agent", href: "/call" }}
  secondaryAction={{ label: "Read the docs", href: "/docs" }}
  stopLabel="Stopped in 38 ms"
  script={[
    { speaker: "caller", text: "Hi, can I move my cleaning to Thursday?" },
    { speaker: "agent", text: "Sure. On Thursday I have 9:30 or 2:15 open, and if you'd rather keep the morning", cutAfter: 9 },
    { speaker: "caller", text: "2:15 works." },
    { speaker: "agent", text: "Done. You're booked for Thursday at 2:15." },
  ]}
/>
```

## Your own face, colour and fluid

FerroHero reads its type from --fh-display and --fh-sans and every colour from --fh-* variables, the fluid and the plate included. Set them on the root.

```tsx
import { Familjen_Grotesk } from "next/font/google";
import { FerroHero } from "@/components/ferro-hero";

const face = Familjen_Grotesk({ subsets: ["latin"], weight: ["400", "500", "600"] });

export default function Page() {
  return (
    <FerroHero
      tone="carbon"
      style={{
        "--fh-display": face.style.fontFamily,
        "--fh-sans": face.style.fontFamily,
        "--fh-signal": "#2ee6a6",
        "--fh-metal": "#1c1a17",
      } as React.CSSProperties}
      brand="Halyard"
      agentName="Halyard"
      callerName="Customer"
      headline={["Phone support that", "lets customers cut in"]}
      highlight="cut in"
      subheadline="Answers card and account calls in 210 ms and goes quiet the moment a customer talks over it."
      primaryAction={{ label: "Hear a live call", href: "/call" }}
      stopLabel="Stopped in 41 ms"
      interruptReply="Of course, go ahead."
    />
  );
}
```

## Props

| Prop | Type | Default | Description |
| --- | --- | --- | --- |
| `brand` | `string` | – | Wordmark in the nav; also the agent’s name on its lines unless agentName is set. |
| `logo` | `ReactNode` | – | Replaces the default ferrofluid mark. |
| `navLinks` | `{ label: string; href: string }[]` | – | Links in the bar; they fold into the menu under 900px. |
| `navSecondaryAction / navPrimaryAction` | `{ label: string; href?: string; onClick?: () => void }` | – | Quiet link and small primary button at the right of the bar. |
| `eyebrow` | `string` | – | One plain line above the headline. |
| `headline` | `string[]` | – | Two or three lines; each climbs out of its slot on load. |
| `highlight` | `string` | – | A phrase inside the headline painted in --fh-signal. |
| `subheadline` | `string` | – | The sentence beside the headline. |
| `primaryAction / secondaryAction` | `{ label: string; href?: string; onClick?: () => void }` | – | The ink button with the signal arrow, and a quiet link. |
| `script` | `{ speaker: "caller" \| "agent"; text: string; cutAfter?: number }[]` | – | The call that plays under the dish, looping. cutAfter on an agent line makes the caller cut in after that many words. |
| `agentName / callerName` | `string` | `brand / "Caller"` | Names on the subtitle lines. |
| `stopLabel` | `string` | `"Stopped in 38 ms"` | Stamp on a line the agent stopped. Put your measured number here. |
| `interruptReply` | `string` | `"Sorry, go ahead. I'm listening."` | What the agent says when a visitor lets go after holding the dish. |
| `holdLabel` | `string` | `"Hold to talk over it"` | Label on the hold control under the subtitles. |
| `tone` | `"studio" \| "carbon"` | `"studio"` | Light plate with black fluid, or dark plate with chrome fluid. |

## States

- **arrival**: The fluid rises out of the dish while the headline lines climb out of their slots and the highlight paints in.
- **agent speaking**: Spikes rise with each syllable and a swell runs outward through the crown; the rim light in the agent’s colour brightens with the voice.
- **caller speaking**: The crown sinks and rings run inward over the fluid and the grooves of the plate.
- **barge-in**: The caller cuts in mid-word: the crown drops at once, the agent’s line moves up with its half-spoken word and the stop stamp, the caller’s line takes its place.
- **hold to talk**: Holding the dish, the hint or Space stops the agent and the fluid listens; letting go plays the reply.
- **magnet**: Spikes under the pointer grow and lean toward it.
- **phone**: Under 600px the dish zooms out to stay whole, subtitles wrap under it, the title card stacks and the actions go full width; the nav folds into a menu that pushes the page down.
- **reduced motion**: One still frame of the crown mid-word with the first exchange fully written; no loop, no hold.

## What it handles

Showing that a voice agent listens usually takes an embedded video, an audio player nobody presses, or a 3D library for an orb that says nothing.

- **The fluid is the voice**: Spike height follows a syllable envelope built from the script, so the crown rises and falls with each word as the subtitle lights up.
- **A barge-in you can see**: Set cutAfter on an agent line and the caller cuts in mid-word: the crown drops at once and the line keeps its half-spoken word and the stop stamp.
- **Talk over it yourself**: Hold the dish, the hint or Space: the agent stops mid-word, the fluid listens, and on release it answers with your interruptReply.
- **A magnet on the pointer**: Spikes under the cursor grow and lean toward it, and the dome slides a little after it, like iron filings under a magnet.
- **One shader, no library**: A hex lattice of spikes on a fluid dome, a machined dish, lathe grooves, three softboxes, a traced soft shadow and ACES on the metal, in one WebGL 1 shader.
- **Studio and carbon**: Light plate with black fluid, or dark plate with chrome fluid. Every colour is an --fh-* variable, including the fluid and the plate.

## Replaces

three.js orb or Lottie waveform, autoplay video of a call, separate nav and phone menu

## Where it fits

- **Voice agent platforms**: The call under the dish shows turn-taking and barge-in, the two things buyers test first.
- **AI phone support for banks, clinics and retail**: Swap the script for your own call: a booking, a card dispute, a delivery change.
- **Speech and audio models**: The fluid follows any voice envelope, so a text-to-speech or dubbing product reads just as well.
- **Realtime and WebRTC infrastructure**: Put your latency in the stamp; the cut is the proof.

## Notes

- Colours: --fh-ground, --fh-plate, --fh-metal, --fh-hover, --fh-ink, --fh-ink-2, --fh-ink-3, --fh-rule, --fh-signal, --fh-on-signal, --fh-button, --fh-on-button. They never inherit your shadcn theme.
- The canvas melts into --fh-ground at its edges, so it has no visible frame on any background you set.
- The loop runs only while the dish is on screen and the tab is visible; the canvas is capped at about 1.3 million pixels.
- The canvas is aria-hidden. The subtitles are real text, the hold control is a button that also works with Space and Enter, and the nav and actions are links.
- Under prefers-reduced-motion one still frame is drawn, the first exchange is shown in full and the hold control is disabled.

License: Hairline UI commercial license, not MIT (https://hairlineui.com/license#blocks)
