Skip to content

Hero Signup

Sign-up hero on a large butter panel: headline with a peach marker-highlighted phrase, white pill email form with success state, check perks and a 5-star rating line.

soft-flat/section/hero-signup
Open ↗

Source

"use client";

import { useId, useState, type FormEvent } from "react";
import { Check, Star } from "lucide-react";
import { cn } from "@/lib/utils";

export interface HeroSignupProps {
  title?: string;
  highlight?: string;
  description?: string;
  buttonLabel?: string;
  onSubmit?: (email: string) => void | Promise<void>;
  perks?: string[];
  rating?: { score: string; source: string };
  className?: string;
}

/** Sign-up hero on a soft butter panel: headline with a highlighted word, email + pill button form (success state), perks and a store rating. */
export function HeroSignup({
  title = "Get your team",
  highlight = "on the same page",
  description = "Boards, weekly plans and friendly reminders — set up in two minutes, free forever for teams up to 5.",
  buttonLabel = "Create my board",
  onSubmit,
  perks = ["Free for 5 people", "No credit card", "Import from Trello"],
  rating = { score: "4.8", source: "on the App Store" },
  className,
}: HeroSignupProps) {
  const id = useId();
  const [done, setDone] = useState(false);

  const submit = async (e: FormEvent<HTMLFormElement>) => {
    e.preventDefault();
    await onSubmit?.(String(new FormData(e.currentTarget).get("email")));
    setDone(true);
  };

  return (
    <section className={cn("bg-da-bg px-4 py-10 text-da-fg sm:py-16", className)}>
      <div className="mx-auto max-w-5xl rounded-[36px] bg-da-warning/25 px-6 py-16 text-center sm:px-12">
        <h1 className="mx-auto max-w-3xl font-da-display text-[clamp(2.25rem,6vw,4rem)] leading-[1.05] font-extrabold tracking-da-display text-balance">
          {title}{" "}
          <span className="relative inline-block">
            <span aria-hidden className="absolute inset-x-0 bottom-1 -z-0 h-4 rounded-da-pill bg-da-accent sm:h-5" />
            <span className="relative">{highlight}</span>
          </span>
        </h1>
        <p className="mx-auto mt-5 max-w-xl text-lg text-pretty text-da-muted-fg">{description}</p>
        {done ? (
          <p role="status" className="mx-auto mt-8 inline-flex items-center gap-2 rounded-da-pill bg-da-secondary px-6 py-3 font-semibold text-da-secondary-fg">
            <Check aria-hidden className="size-5" /> Check your inbox — your board is ready!
          </p>
        ) : (
          <form
            onSubmit={submit}
            className="mx-auto mt-8 flex max-w-md flex-col gap-2 rounded-da-lg bg-da-surface p-2 shadow-da-md sm:flex-row sm:rounded-da-pill"
          >
            <label htmlFor={id} className="sr-only">
              Work email
            </label>
            <input
              id={id}
              name="email"
              type="email"
              required
              autoComplete="email"
              placeholder="you@team.com"
              className="da-focus h-12 min-w-0 sm:flex-1 rounded-da-pill bg-transparent px-5 outline-none placeholder:text-da-muted-fg"
            />
            <button
              type="submit"
              className="da-focus da-transition h-12 rounded-da-pill bg-da-primary px-6 font-semibold text-da-primary-fg hover:-translate-y-0.5"
            >
              {buttonLabel}
            </button>
          </form>
        )}
        <ul className="mt-6 flex flex-wrap justify-center gap-x-5 gap-y-2 text-sm font-medium">
          {perks.map((p) => (
            <li key={p} className="inline-flex items-center gap-1.5">
              <span aria-hidden className="grid size-5 place-items-center rounded-full bg-da-secondary text-da-secondary-fg">
                <Check className="size-3" />
              </span>
              {p}
            </li>
          ))}
        </ul>
        <p className="mt-8 inline-flex items-center gap-2 text-sm text-da-muted-fg">
          <span className="flex text-da-fg" aria-hidden>
            {Array.from({ length: 5 }, (_, i) => (
              <Star key={i} className="size-4 fill-current" />
            ))}
          </span>
          <span>
            <span className="font-semibold text-da-fg">{rating.score}</span> {rating.source}
          </span>
        </p>
      </div>
    </section>
  );
}

export default HeroSignup;

modules/soft-flat/section/hero-signup/index.tsx

Props

PropTypeDefaultDescription
title / highlight / description / buttonLabelstring—Copy.
onSubmit(email: string) => void | Promise<void>—Handler.
perksstring[]—Perks.
rating{ score, source }—Rating line.
classNamestring—Classes.

Other hero variants in Soft Flat

Hero in other art directions

Hero Poster

Poster-style centered hero: gigantic stacked headline alternating solid and outlined words, colored feature stickers scattered around it, two pressable CTAs and a ruled wordmark strip of customer logos.

BrutalistHero

Hero Signup

Conversion hero with the signup form in the fold: headline with a blue highlighted phrase, boxed email capture with pending/success states, checkmark reassurance list and three staggered colored step cards.

BrutalistHero

Hero Stacked

Split hero with a huge stacked uppercase headline (one line boxed in yellow), two pressable CTAs, a stats strip and a changelog window mock with a rotated sticker.

BrutalistHero

Hero Terminal

Developer-first hero: full-width uppercase headline, copyable install command button, and an ink terminal window that replays a git merge → publish session line by line with a blinking yellow cursor.

BrutalistHero

Hero Centered

Centered hero over the mesh: frosted badge, headline with gradient-text ending, gradient + frosted CTAs, then a wide glass ‘live call’ window with four video tiles, live transcript and an AI capture chip.

GlassHero

Hero Mesh

Split hero over the glass mesh: frosted announcement pill, headline with gradient-text second half, gradient + frosted CTAs, and a layered composition of glass cards (AI meeting recap, floating video update, recording pill) gently bobbing.

GlassHero

Hero Stack

Split hero with a fanned 3D stack of three glass cards (AI recap, async video, synced tasks) tilted in perspective, spreading apart with a spring on hover.

GlassHero

Hero Waitlist

Minimal waitlist hero with a central glow: badge, big headline, a glass pill email form with gradient submit (pending, success, error states) and a stack of gradient avatars with the waitlist count.

GlassHero

Hero Cli

Developer-first centered hero on a dotted grid: version badge, headline, an install command field with copy-to-clipboard, a docs button and a terminal window showing the command output.

MinimalHero

Hero Glow

Centered hero with announcement pill, gradient-ink headline, two CTAs, a single soft indigo glow over a masked hairline grid, and an HTML product window (incident list) fading out at the bottom.

MinimalHero

Hero Metrics

Editorial left-aligned hero with an oversized tight headline, copy and CTAs on one baseline, a row of three hairline-separated mono metrics and a text wordmark strip of customers.

MinimalHero

Hero Split

Two-column hero: eyebrow, headline, copy, checklist and two CTAs on the left; on the right a hairline card showing a live incident timeline with colored status dots and a resolved badge.

MinimalHero

Hero Browser

Split hero: copy on the left, a large monochrome browser frame on the right showing a mock studio portfolio (nav, giant name, image grid with mono captions) and a signal-dot “Published” badge.

Mono CleanHero

Hero Giant

Type-led hero: a mono label, an enormous tightly-tracked headline across the full width, then a 12-col row with copy + ink button on the left and mono key facts on the right, over a full-bleed gray image frame with caption.

Mono CleanHero

Hero Grid

Visible-grid hero: hairline 12-column guides behind the content, headline + copy + ink CTA in the left columns, and a ruled index list of featured templates on the right whose rows invert on hover.

Mono CleanHero

Hero Statement

Quiet manifesto hero: a single large statement set in the display face with generous line height and an orange signal dot after a key word, bottom-anchored mono footnotes and a scroll cue; nearly full-height.

Mono CleanHero

Hero Band

Stripe-style hero on a deep blue gradient band with a slanted bottom edge: headline and CTAs on the left, a stacked pair of payment UI cards (invoice + payment success) on the right.

Neo CorporateHero

Hero Dashboard

Split hero: eyebrow, strong headline, copy, blue + bordered CTAs and a compliance line; on the right a finance dashboard mock (KPIs, bar chart, invoice table).

Neo CorporateHero

Hero Demo

Enterprise demo-request hero: copy + check bullets + quote on the left, a bordered lead form (name, work email, company, size, submit) with validation-ready fields and success state on the right.

Neo CorporateHero

Hero Proof

Centered proof-first hero on a faint grid: announcement badge, headline, CTAs, a four-stat bordered strip and a customer wordmark row.

Neo CorporateHero

Hero Arch

Split hero: eyebrow with sprout icon, large serif headline with an italic sage highlight, calm copy, pill CTAs; on the right a tall arch-topped illustration (sun + rolling hills) with a floating stat chip.

Organic SoftHero

Hero Centered

Centered serif hero floating over two soft organic blobs (sage and clay), a hand-drawn underline under the italic highlight, pill CTAs and a row of three calm stats.

Organic SoftHero

Hero Editorial

Magazine-style hero: oversized serif headline across the width with an italic line, a collage of three organic shapes (arch, circle with leaf, pebble) and a pull-quote column; scroll cue.

Organic SoftHero

Hero Footprint

Product hero: copy + CTAs on the left, a soft rounded footprint card on the right with a donut chart of emissions by source, legend with percentages and a gentle “biggest lever” tip.

Organic SoftHero