# Build a club home page with the Relay theme

You are building one page in an existing project: the home page of an amateur football club, with a scoreboard band that holds the last result and the next match, the latest news as a list, the top of the league table, the three kinds of membership and one main action to join. Follow this brief closely. `DESIGN.md` decides the tokens: colors, type, spacing steps and corners. This brief decides the layout, its widths included, and which token goes where. If this brief names a color, a type size, a spacing step or a corner that `DESIGN.md` does not have, `DESIGN.md` wins.

## Before you start

1. **Check the theme is installed.** The project should have `DESIGN.md` in its root and the Relay variables in its global CSS. If not, run `npx shadcn@latest add https://strictthemes.com/r/relay.json` and save https://strictthemes.com/themes/relay/DESIGN.md as `DESIGN.md` in the project root. In a project without shadcn, use https://strictthemes.com/themes/relay/tailwind.css instead. If the global CSS still imports a font the theme does not use (a new shadcn project imports Geist), remove that import, and uninstall its package if nothing else uses it. Keep every font import the theme's install added, also one for a style no page uses yet.
2. **Read `DESIGN.md` from start to finish.** It is the source of truth for every visual decision.
3. **Look at the project before writing code.** Use its framework, router and file layout. For controls (buttons, inputs, tabs, menus, dialogs, accordions, data tables) use the components in `components/ui`, and add a missing one with `npx shadcn@latest add <name>` rather than writing your own, unless this brief names a plain element. Layout is plain elements with theme classes: sections, panels, figures and lists need no component.
4. **Teach `cn()` the theme's type classes.** shadcn's class merger does not know `text-display` or `text-h1`. It takes them for colors, so `cn("text-label text-muted-foreground")` silently drops one of the two, and a type class passed to a stock component does not replace its size. In a new shadcn project, `lib/utils.ts` only passes `cn` on from the `cn` package. Unless the file already holds the lines below, change it to:

   ```ts
   import { createCn } from "cn/config"

   // The theme's type classes are font sizes, not colors.
   export const cn = createCn({
     extend: {
       classGroups: {
         "font-size": [{ text: ["display", "h1", "h2", "body", "label"] }],
       },
     },
   })
   ```

   Then make every file in `components/ui` use it: where one has `import { cn } from "cn"`, change that line to import `cn` from the project's utils file (`@/lib/utils` in a default setup). Do the same for each component you add later. If the project uses `tailwind-merge` instead of the `cn` package, its components already import from the utils file: pass the same object to `extendTailwindMerge` and keep `clsx`.
5. **Write real content.** If the user gave you details about their product, use them. Otherwise use the sample product in this brief and write the rest of the copy yourself: specific and plain, the way the samples read. Invent the company and people names; do not use real ones. Never use lorem ipsum. A link with no destination yet points to `#`. Set the page's `<title>` and meta description.

## The theme in short

- **Fonts:** Saira for headings, Rubik for body text, Kode Mono for labels and code.
- **Type scale** (size/weight; each class also sets line height and tracking): `text-display` 64px/800, `text-h1` 40px/800, `text-h2` 24px/700, `text-body` 16px/400, `text-label` 13px/500.
- **Font per size:** a type class does not set the font family. Headings (`<h1>` to `<h6>`) get the heading font on their own; on any other element add the font class: `font-heading` with `text-display`, `text-h1`, `text-h2`; `font-mono` with `text-label`.
- **Spacing scale**, with the Tailwind step in brackets: 4px (`1`), 8px (`2`), 12px (`3`), 20px (`5`), 32px (`8`), 72px (`18`).
- **Corners:** `rounded-sm` 3px, `rounded-md` 6px, `rounded-xl` 10px (the `lg` corner in `DESIGN.md`). `rounded-lg` is 6px as well: it is shadcn's name for the base corner, the one its stock buttons and inputs use.
- **Colors (light mode):** primary #FFB703, on-primary #023047, secondary #023047, on-secondary #FFFFFF, tertiary #FB8500, on-tertiary #023047, neutral #3F6377, background #F5FAFC, surface #FFFFFF, foreground #023047, border #C5E1EE, error #B3261E, ring #023047, navy #023047, on-navy #FFFFFF, ice #8ECAE6, on-ice #023047.

### How Relay pages are laid out

- **Page:** kit white, dense and squared up, with navy bands. The outermost element is a `<div>` with `flex min-h-svh flex-col bg-background text-body text-foreground`, holding `<header>`, `<main>` (`flex-1`) and `<footer>`.
- **Container:** the header's row, the content of `<main>` and the footer each sit in a centered container `<div>`, `mx-auto w-full max-w-[1240px] px-5`: a 20px gutter at every width. This width is the one arbitrary value allowed.
- **Stock components:** these pages use two, `Button` and `Input`. Everything else is plain elements with the classes these notes give: tables, badges, radios, checkboxes and cards included. Do not add the shadcn `Table`, `Badge`, `Card`, `Checkbox`, `RadioGroup`, `Switch` or `Tabs`.
- **Today:** the sample's now is Tuesday 8 June 2027 at 20:05, fixed in code, never the device clock. Nothing on these pages ticks: no timers.
- **Sample organisation:** "Wendmoor Football Club", written "Wendmoor FC" everywhere but the home page's `<h1>` and the footer's small print: an invented amateur club, founded in 1921, with 140 members and three teams (first team, reserves, under 18s). It plays at Millrace Park in Wendmoor, an invented town. The first team plays in the Kestrel Valley League, Division One: twelve invented clubs who meet twice, 22 matches each, on Saturdays at 15:00 from 6 March to 31 July 2027. After 14 matches Wendmoor FC are third with 27 points. Their last match was a 3–1 home win over Otterby Town on Saturday 5 June; the next is away to the leaders, Castlebrook United, on Saturday 12 June. Membership for the season costs £95 (Playing), £45 (Junior) or £30 (Social). The same figures appear on every page; this brief gives the ones it needs.
- **Clubs:** the twelve clubs, each with the letters of its crest and its ground: Wendmoor FC (`W`, Millrace Park), Castlebrook United (`CU`, Castle Meadow), Dunmarsh Athletic (`DA`, The Saltings), Otterby Town (`OT`, Weir Lane), Stenwick Albion (`SA`, Albion Field), Kirkfen Rangers (`KR`, Fen Road), Lowmere Welfare (`LW`, Welfare Ground), Pellow Green (`PG`, The Green), Hollinvale (`H`, Hollin Bank), Tarrowby United (`TU`, Station Road), Sedgeholme (`S`, Sedge Lane), Eastlow Wanderers (`EW`, Quarry Lane). A reserve or under 18 side has its club's letters and ground.
- **Vertical rhythm:** every vertical distance between siblings comes from a `gap-*` on their parent, a `flex flex-col` or a grid. Never use `space-y-*`, and no margins but the two these notes name: `mt-0.5` on a checkbox and `mt-1` on an icon beside body text. Rows and cells use padding. The container inside `<main>` is `flex flex-col gap-18 pt-8 pb-18`: its items are the page's sections, 72px apart, and this brief says what the items are. The other steps: `gap-1` between a figure and the label under it, and between the lines of one row; `gap-2` between a field's label, the field, its helper text and its error, and between an icon and its word; `gap-3` between a label and the heading under it, between a heading and its paragraph, between paragraphs, and between buttons in a row; `gap-5` inside a card, between cards, between the fields of a form and between grid columns; `gap-8` between a section's heading and its content where this brief says so, and between the blocks of one section. Where a page's own section gives another value, the page wins.
- **Grid:** where this brief puts things side by side, they are items of a 12-column grid, `grid grid-cols-1 gap-5 lg:grid-cols-12`, a single column below `lg`. "Eight columns" means `lg:col-span-8`, and so on; give every item `min-w-0`. A column of several cards is `flex flex-col gap-5`.
- **Bands:** a band is a block of the theme's `navy`: `bg-navy text-navy-foreground`, navy with white text in both modes, with no shadow. It is not `bg-secondary`, which turns ice blue in dark mode and is for buttons only. Write no `dark:` class. Three things are bands: the header, a scoreboard, and a table's head.
  - Everything on a band inherits the white of `text-navy-foreground` from the band. No element on a band gets `text-foreground`, `text-card-foreground`, `text-muted-foreground`, `text-secondary-foreground` or `text-primary`.
  - A label on a band is `text-ice`, ice blue, the one text color class a piece of text on a band may get. (A crest and the badge bring their own fill and text color.)
  - A rule drawn on a band, to divide two parts of it, is a 1px `border-ice` line.
  - The edge of a band: in dark mode a card is the band's own navy and the page is only a little darker, so a band gets a hairline of the theme's border color, written once for both modes. In light mode that hairline is a pale edge that hardly shows, and that is fine. A band that is a block of its own (a scoreboard) is `rounded-xl border border-border`. The header, across the full width with square corners, has `border-b border-border`. A table's head has no border of its own: the card's border and the rule on the first row under it frame it.
  - The focus outline on a band is `focus-visible:outline-navy-foreground` in place of `focus-visible:outline-ring`, with the rest of the outline classes from the rules unchanged: white on navy in both modes. The `ring` color is navy in light mode, the band's own color, and would not show.
  - A band holds text, crests, the one orange badge and text links. Never a button of any kind (the amber one included), a field, a card or an ice panel. A band is never inside a card; a table's head is part of its table, not a band put into a card.
- **Ice:** the theme's own color fills quiet panels and marked rows: `bg-ice text-ice-foreground`, the pair always together on the panel or the row itself. Ice blue and the navy text on it are the same in both modes. As a text color, `text-ice` is only for labels on a band. A panel is `rounded-xl bg-ice p-5 text-ice-foreground` with `flex flex-col gap-5` inside, no border and no shadow; a marked row (the club's own row in a table, the next match in a list) gets the two classes and keeps its row padding. Everything on ice inherits the navy: no element there gets a text color class of its own, also not the labels and small print that these notes make muted elsewhere. Ice holds text only: nothing that takes focus (the focus outline is amber in dark mode and would vanish on it), so no link, button or field, and no badge. A list on an ice panel has no rules between its rows. An ice panel sits on the page, never inside a card, and a card is never inside it.
- **Amber:** `bg-primary` is a fill for one thing, the main action: the default `Button`, navy text on amber in both modes. Each page has exactly one amber button, which this brief names, and it sits on the page or on a card. Amber is never text and never a thin mark, because it cannot be read on kit white: never write `text-primary`, `border-primary`, `decoration-primary`, `accent-primary` or `outline-primary`, never color an icon amber, and never use the `link` variant of the stock `Button`. Do not use the `chart-*` colors.
- **Orange:** `bg-tertiary` is the fill of one badge and nothing else. Never `text-tertiary`.
- **Focus:** the theme has a `ring` color, navy in light mode and amber in dark mode, and the outline from the rules uses it (`focus-visible:outline-ring`): it shows on the page and on a card in both modes. It does not show on a band in light mode or on ice in dark mode, which is why a band has an outline color of its own, white, and ice holds nothing that takes focus.
- **Header:** a `<header>` that is a band: `border-b border-border bg-navy text-navy-foreground`, full width. Its container is the row, `flex flex-wrap items-center justify-between gap-x-8 gap-y-1 py-3`, with two items:
  - The club's name, a link to `/`, `inline-flex items-center gap-3`: a crest (`size-10`, the letter `W`) and "Wendmoor FC" in a `<span>` with `font-heading text-h2 uppercase`. It is never marked as the current page.
  - A `<nav>` with the `aria-label` "Main", holding a `<ul>` with `flex flex-wrap gap-x-5` of four links in this order: Fixtures (`/fixtures`), Table (`/standings`), Report (`/report`) and Membership (`/membership`). This brief says which one is current. From `md` up the nav sits at the right end of the row; on a phone it wraps to a second line under the name, where the four links fit 375px. There is no "Menu" button and no button of any kind in the header.
  - A nav link is `inline-flex h-10 items-center font-mono text-label uppercase underline-offset-4 hover:underline`; the current page's link adds `underline decoration-2` and `aria-current="page"`. Every link in the header takes the band's focus outline.
- **Footer:** a `<footer>` with `border-t border-border`, not a band. Its container is `flex flex-col gap-3 py-8`: "Wendmoor FC" in a `<p>` with `font-heading text-h2 uppercase`; a `<nav>` with the `aria-label` "Footer", a `<ul>` with `flex flex-wrap gap-x-5 gap-y-2` of four label links, Fixtures (`/fixtures`), Table (`/standings`), Report (`/report`) and Membership (`/membership`), none marked current; then a label in `text-muted-foreground`: `© 2027 WENDMOOR FOOTBALL CLUB · MILLRACE PARK, WENDMOOR · A DEMO: NOTHING IS SENT OR STORED`.
- **Page head:** the top of a page is a row, `flex flex-wrap items-end justify-between gap-5`. On the left a stack with `gap-3`: a label in `text-muted-foreground`, the `<h1>`, and, where this brief gives one, a sentence in `text-body` with `max-w-2xl`. On the right the page's one amber action: a link to `/membership` styled as the default button, "Join the club". On a phone it wraps under the stack. The membership page has no action there: its form's button is the amber one.
- **Headings:** every heading is `uppercase`, with the class on the heading element, and is set in Saira at the weight its type class gives: do not add a weight class to an `<h1>` or `<h2>`, and never slant, outline or stretch it. The `<h1>` is `text-h1` at every width. A section's or a card's `<h2>` is `text-h2`. A smaller heading (an `<h3>`, or a name set like one) is `font-heading text-body font-bold uppercase`. No word in an `<h1>` is longer than eleven letters, so it fits 375px. A section's heading row, where it also holds a link, is `flex flex-wrap items-baseline justify-between gap-3`.
- **Scores and times:** a score, a kick-off time, a position, a price or a count that stands on its own is a **figure**: `font-heading tabular-nums`, with a size: `text-h1 md:text-display` on a scoreboard, `text-h1` in a panel or a card, `text-h2` in a row. `text-display` is used for nothing else. A score is written with an en dash and no spaces, `3–1`. A figure with a name is a stack with `gap-1`, the figure above its label; in a `<dl>` the pair is a `<div>` with `flex flex-col-reverse gap-1`, the `<dt>` (the label) first in the source.
- **Labels:** dates, kick-off times in a line of text, venues, competitions, nav links, field labels, the heads of a table's columns, and button and badge text are labels: `font-mono text-label uppercase`, a short fragment and never a sentence. A label line joins its parts with ` · ` (`SAT 5 JUN · MILLRACE PARK`), unless this brief makes them separate items. A label that is a heading element needs `font-mono`, since a heading gets Saira on its own. On the page and on a card a label is `text-muted-foreground`, unless this brief says `text-foreground`; a field's label is `text-foreground`. On a band it is `text-ice`; on ice it inherits.
- **Small print:** helper text, a note under a table and a sentence of fine print are `text-label text-muted-foreground` in the body font: no `font-mono` and no `uppercase`. Only on the page or a card; on ice it inherits.
- **Text color:** headings, body text, names and figures are `text-foreground` on the page and on a card. Labels and small print are `text-muted-foreground` there, and nowhere else: muted text never sits on a band, on ice, on amber or on orange. Paragraphs are never muted.
- **Measure:** a paragraph of body text is at most `max-w-2xl` wide.
- **Dates and times:** a date in a label is `SAT 5 JUN`, in a `<time>` with `dateTime="2027-06-05"`; with its year, `SAT 5 JUN 2027`. In a sentence a date is written out, "Saturday 5 June 2027", and is not a `<time>`. A time is on the 24-hour clock, `15:00`. A minute of a match is `58'`, with a straight apostrophe.
- **Links:** a text link is `text-foreground underline underline-offset-4 hover:decoration-2` and inherits its size: links are the text color, never amber, so the hover thickens the underline and changes no color. A label link is a label in `text-foreground` with the same underline classes. A link on a band has the underline classes, no text color class, and the band's focus outline. A link whose destination this brief does not name points to `#`.
- **Buttons:** the shadcn `Button` with `className="h-auto px-5 py-2 font-mono text-label uppercase"`; it keeps its stock corner (`rounded-lg`, 6px here). The default variant (amber) is the page's one main action, "Join the club", and nothing else. Every other button is `variant="secondary"` (navy with white text; ice blue with navy text in dark mode) or, for the unchosen buttons of a group, `variant="outline"`. No `ghost`, `destructive` or `link` buttons. The stock hover of `secondary` cannot be told from its resting color: in `components/ui/button.tsx`, replace the `secondary` variant's `hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)]` with `hover:bg-secondary/80`, once, and add no hover class on the page. A link styled as a button is an `<a>` with `cn(buttonVariants({ variant }), "h-auto px-5 py-2 font-mono text-label uppercase")`: `buttonVariants` alone does not merge classes. A button that sends a form needs `type="submit"`: this `Button` is `type="button"` unless told otherwise. No button on these pages is ever disabled, so none gets `focusableWhenDisabled`, and `button.tsx` needs no `data-disabled:` classes. The stock `Button` keeps its `transition-all` and its nudge when pressed.
- **Button groups:** a set of buttons where one is chosen is a `role="group"` with an `aria-label` and `flex flex-wrap gap-2`, on the page, never on a band or on ice. The chosen button has `aria-pressed="true"` and `variant="secondary"`; the others have `aria-pressed="false"` and `variant="outline"`. Every button in it has the Buttons classes. Pressing the chosen button again changes nothing. Not `Tabs`: there are no tab panels.
- **Badges:** the one badge of a page says "Final" or "Live". It is a plain `<span>` with `inline-flex shrink-0 items-center rounded-sm bg-tertiary px-2 py-1 font-mono text-label uppercase whitespace-nowrap text-tertiary-foreground`: orange with navy text in both modes. At most one shows at a time. It may sit on the page, on a card or on a band, never on ice.
- **Crests:** a club's crest is drawn, never an image: a `<span>` with `flex shrink-0 items-center justify-center rounded-full` and `aria-hidden="true"`, holding the club's letters from the Clubs note, beside the club's written name. It is `bg-ice text-ice-foreground`, an ice blue disc with navy letters, on the page, on a card and on a band. On ice, where that would not show, it is `bg-navy text-navy-foreground` instead: a navy disc with white letters. Sizes: `size-8` in a row, with the letters in `font-mono text-label`; `size-10` in the header and `size-12` on a scoreboard, with the letters in `font-heading text-body font-extrabold`. 48px is the theme's limit for a full round. No border and no shadow.
- **Scoreboards:** a scoreboard is a band that is a block of its own: `rounded-xl border border-border bg-navy p-5 text-navy-foreground md:p-8`. A match on it is a row, `flex items-center justify-center gap-3 md:gap-8`, with three items: the home side, the score, the away side. Each side is `flex min-w-0 flex-1 flex-col items-center gap-2 text-center`: its crest (`size-12`), then its name in a `<p>` with `font-heading text-body font-bold uppercase md:text-h2`, then anything this brief puts under the name. The score is a `<p>` with `shrink-0`, a figure in `text-h1 md:text-display`. The home side is always on the left and its goals come first.
- **Cards:** a card is a plain element with `rounded-xl border border-border bg-card p-5` and `flex flex-col gap-5` inside: white with a 1px border, no shadow. Never a card inside a card, and never a bordered box with corners inside a card: divide a card's parts with a 1px rule (`border-t border-border`).
- **Cards with rows:** a card that holds a list of rows or a table has no padding and no gap of its own, and `overflow-hidden`: `overflow-hidden rounded-xl border border-border bg-card`. Each row has `px-5 py-3` and, except the card's first row, `border-t border-border`. A heading inside such a card is a row too, the first, with `px-5 py-3`; the first item of the list under it then has the rule like any other row.
- **Tables:** a table is a plain `<table>` in a card with rows, with `w-full border-collapse text-body`, a `<caption>` that is `sr-only` (the visible name is the heading above the card), and real header cells. Its rows take the cell padding below, not the row padding of the Cards with rows note.
  - The `<thead>` is a band: `bg-navy text-navy-foreground`, with no corner class and no border of its own, since the card clips and frames it. In dark mode it is the card's own navy, and its ice blue labels and the rule under it set it off. Each `<th scope="col">` is a label on a band, `px-2 py-3 font-mono text-label uppercase text-ice`, with `text-left` for a position or a name and `text-right` for a figure.
  - Each body `<tr>` has `border-t border-border`. Cells are `px-2 py-3`; the first cell of every row, the head's too, also has `pl-5` and the last `pr-5`.
  - A club's name is a `<th scope="row">` with `px-2 py-3 text-left font-normal`. A figure cell is `text-right tabular-nums` in the body font; the points are also `font-bold`. A position is a figure in `text-h2`, left-aligned.
  - The club's own row is a marked row: the `<tr>` adds `bg-ice text-ice-foreground`, the club's name is `font-bold` and is followed by a `<span>` with `sr-only`, " (this club)". So the row is marked by more than its color.
  - No hover fill, no stripes and no other colored row. A short header is an `<abbr>` with a `title` and `no-underline`.
- **Description lists:** a list of facts is a `<dl>`. On a card each row is `flex items-baseline justify-between gap-3 py-2` with `border-t border-border` except the first: the `<dt>` a label, the `<dd>` in `text-right text-body`. On an ice panel the rows have no rules and no padding: the `<dl>` is `flex flex-col gap-2`.
- **Inputs:** the shadcn `Input` (`npx shadcn@latest add input`) with `className="h-10 px-3 text-body md:text-body"`, its stock corner (6px). In `components/ui/input.tsx`: replace `border-input` with `border-muted-foreground`, so a field's edge shows on a white card; replace the class `bg-transparent` and the class `dark:bg-input/30` with `bg-card` (`file:bg-transparent` and the `disabled:` fills stay); and delete `dark:aria-invalid:border-destructive/50`. A field is a `flex flex-col gap-2`: a visible `<label>` with `block`, a label in `text-foreground`, tied to the field with `htmlFor`; the field; its helper text, small print, where this brief gives one; and its error line when there is one. Name the helper text in the field's `aria-describedby`. Fields sit on a card.
- **Radios and checkboxes:** native `<input type="radio">` and `<input type="checkbox">`, each with `size-5 shrink-0 accent-secondary` and the focus outline from the rules written on it. `accent-secondary` draws the checked mark in the `secondary` color, navy in light mode and ice blue in dark mode, and the browser sets the tick or the dot against it: both show on a card in both modes. The shadcn `Checkbox` and `RadioGroup` fill their mark with amber and are not used. Radios of one choice share a `name`. They sit on a card or on the page, never on a band or on ice. A checkbox's row is a `<label>` with `flex items-start gap-3 text-body text-foreground`, holding the checkbox (with `mt-0.5`, 2px, so it sits on the first line) and a `<span>` with its sentence. These pages have no switch.
- **Errors:** an error line is `flex items-start gap-2 text-label text-destructive` in the body font (a sentence, so no `font-mono` and no `uppercase`), holding the `CircleAlert` icon (no margin: the line is as tall as the icon) and a sentence that says what to do. The field gets `aria-invalid` and names the line in its `aria-describedby`. Fields are checked in code on submit, with `noValidate` on the `<form>`; focus then moves to the first field with an error. Render the error lines first and move focus after: set the errors in state and focus the field in an effect that runs when they change, so the field's `aria-describedby` already points at a line that exists. An error line is removed when its own field changes (on `input` or `change`); every other error stays until the next submit. Every value is trimmed before it is checked.
- **Announcements:** a message that only tells a screen reader what changed goes into a `<p>` with `role="status"` whose only class is `sr-only`, on the page from the start, empty. It adds no gap.
- **Confirmations:** a message that replaces a form goes into a `role="status"` element that is on the page from the start, empty, or it may not be announced. That element is never hidden, has no classes, and is never an item of a `gap-*` stack: it shares one plain `<div>` with the `<form>`. The message inside it, rendered only when there is one, carries the look. Give the message's heading `tabIndex={-1}` and move focus to it, because the button that had focus is gone.
- **Icons:** from `lucide-react`, with `size-4 shrink-0`, `strokeWidth={2}`, `strokeLinecap="square"` and `aria-hidden="true"`, only where this brief or these notes name one, in the color of the text beside them. Beside a line of body text in an `items-start` row the icon gets `mt-1`, so it sits on the first line. Never amber, never emoji.
- **Corners:** `rounded-sm` (3px) for the badge and for drawn bars; `rounded-lg` (6px, what they ship with) for buttons and inputs; `rounded-xl` (10px, the spec's `lg`) for cards, bands and ice panels. `rounded-full` only for a crest, at most `size-12`. Nothing else is round: no pills, no avatars, no status dots on these pages.
- **Surfaces:** flat. No shadows, blur, gradients or glows in the code you write. The page is `bg-background`, a card is `bg-card`, a band is `bg-navy`, a quiet panel is `bg-ice`; do not use `bg-muted` or `bg-accent`. A drawn bar takes the fill this brief gives it.
- **Motion:** in the code you write, the only transition is color, `transition-colors duration-150` on links. Nothing moves on scroll, and nothing animates in. Stock components keep the motion they ship with.

## The page

Where this section and the layout notes above differ, this section wins.

Sample content, if the user gave none: "Wendmoor Football Club", four days before its biggest match of the season. On Saturday 5 June 2027 the first team beat Otterby Town 3–1 at Millrace Park in front of 212 people; on Saturday 12 June at 15:00 they go to Castle Meadow to play the leaders, Castlebrook United. The top five of the Kestrel Valley League, Division One, after 14 of 22 matches (position, club, played, goal difference, points):

1. Castlebrook United, 14, +14, 29
2. Dunmarsh Athletic, 14, +12, 27
3. Wendmoor FC, 14, +11, 27
4. Pellow Green, 14, +7, 26
5. Stenwick Albion, 14, +4, 23

This page uses the stock `button`; add it with `npx shadcn@latest add button` if the project lacks it.

Build these parts in order. The container inside `<main>` has three items: a `<div>` with `flex flex-col gap-8` that holds parts 2 and 3; the grid of part 4; and the section of part 5.

### 1. Header

The header from the layout notes. No nav link is current on the home page.

### 2. Page head

The label `KESTREL VALLEY LEAGUE · DIVISION ONE`, then the `<h1>` "Wendmoor Football Club", then the sentence "Saturday football at Millrace Park since 1921. Three teams, 140 members, and room for one more." On the right, the amber link "Join the club".

### 3. Scoreboard

A `<section>` that is a scoreboard band, with the classes of the Scoreboards note, named by an `<h2>` "Last result and next match" that is `sr-only`. Inside it, after the `<h2>`, one grid with `grid grid-cols-1 gap-8 lg:grid-cols-2` and two halves. Every label on the band is `text-ice`, except its two links, which inherit the band's white.

**Last result,** a stack with `flex flex-col gap-5`:

- A row with `flex items-center justify-between gap-3`: an `<h3>` label, `LAST RESULT` (`font-mono text-label uppercase text-ice`), and the badge "Final". This is the page's one badge.
- The match row from the Scoreboards note: Wendmoor FC with the crest `W`, the score `3–1`, Otterby Town with the crest `OT`.
- A label line, centered with `text-center`: `SAT 5 JUN · MILLRACE PARK · ATTENDANCE 212`, the date a `<time>`.
- A link on the band, "Match report", to `/report`, centered with `self-center`: a label with the underline classes of the Links note and the band's focus outline.

**Next match,** a stack with `flex flex-col gap-5 border-t border-ice pt-8 lg:border-t-0 lg:border-l lg:pt-0 lg:pl-8`, so a rule divides the halves: above this one while they are stacked, to its left from `lg` up.

- An `<h3>` label, `NEXT MATCH`, styled as the first.
- A stack with `gap-1`: the kick-off time, `15:00`, a figure in `text-h1 md:text-display`, in a `<time>` with `dateTime="2027-06-12T15:00"`; under it the label line `SAT 12 JUN · CASTLE MEADOW · AWAY`.
- A `<p>` with `font-heading text-h2 uppercase`: "Castlebrook United v Wendmoor FC".
- A `<p>` in `text-body`: "First against third. A win takes Wendmoor above the leaders with seven matches left."
- A link on the band, "All fixtures", to `/fixtures`, at its own width (`self-start`), styled as the other.

### 4. News and table

A grid row with two items.

**Latest news,** seven columns from `lg` up: a `<section>` named by its `<h2>`, laid out as `flex flex-col gap-5`. Its heading row holds the `<h2>` "Latest news" and a label link "All news" to `#`. Under it a card with rows, a `<ul>` of four rows. Each `<li>` is a row and holds an `<article>` with `flex flex-col gap-1`: the date, a label in a `<time>`; the headline, an `<h3>` in `text-h2` that holds a link with `text-foreground underline-offset-4 decoration-2 hover:underline` (a headline link has no underline at rest); and one sentence in `text-body`. The four, newest first:

1. `SAT 5 JUN`, "Achebe double sinks Otterby", to `/report`: "Two goals from Tobin Achebe and a Brandvold penalty made it three league wins in a row at Millrace Park."
2. `THU 3 JUN`, "New floodlights switched on", to `#`: "The four new masts were lit for the first time at Thursday training, in time for the reserves' evening matches."
3. `SUN 30 MAY`, "Under 18s reach the cup final", to `#`: "A 2–1 win at Pellow Green puts the under 18s in the County Youth Cup final on Sunday 27 June."
4. `WED 26 MAY`, "Summer coaching week opens", to `#`: "Booking is open for a week of coaching for ages 7 to 14 at Millrace Park, from Monday 2 August."

**League table,** five columns from `lg` up: a `<section>` named by its `<h2>`, laid out as `flex flex-col gap-5`. Its heading row holds the `<h2>` "Division One" and a label link "Full table" to `/standings`. Under it a card with rows that holds the table from the Tables note and, after the table, a row with `border-t border-border px-5 py-3` holding one line of small print: "After 14 of 22 matches. Clubs level on points are split by goal difference."

The table's caption: "Kestrel Valley League, Division One: the top five clubs after 14 of 22 matches." Five columns, with these headers: `POS` (an `<abbr>` with the `title` "Position"), `CLUB`, `P` ("Played"), `GD` ("Goal difference") and `PTS` ("Points"); the last three are right-aligned. The five rows of the sample, with the goal difference signed (`+14`). The row of Wendmoor FC is the club's own row. A club's name may wrap on a phone; the table has no scroll box, because five short columns fit 375px.

### 5. Memberships

A `<section>` named by its `<h2>`, laid out as `flex flex-col gap-5`. Its heading row holds the `<h2>` "Three ways to join" and a label link "How membership works" to `/membership`. Under it a grid row of three cards, four columns each from `lg` up. Each card holds an `<h3>` as the Headings note sets a smaller heading; a stack with `gap-1` of the price, a figure in `text-h1`, and the label `A SEASON`; one sentence in `text-body`; and a label link to `/membership` at its own width (`self-start`):

- "Playing", `£95`: "For adults who want to play. Training twice a week and a place in the first team or reserves squad." The link: "Join as a player".
- "Junior", `£45`: "For players under 18. Coaching on Thursdays and matches with the under 18s on Sundays." The link: "Join as a junior".
- "Social", `£30`: "For everyone else. Free entry to home league matches and a vote at the annual meeting." The link: "Join as a social member".

### 6. Footer

The footer from the layout notes.

### Behavior

- The page has no state. Every link needs no behavior beyond its `href`.
- Nothing counts down to the next match, and the score does not change.

## Rules

- **Colors:** only the theme's colors, through the semantic classes (`bg-background`, `text-foreground`, `bg-card`, `bg-primary`, `text-primary-foreground`, `text-muted-foreground`, `border-border` and so on). No hex, rgb or named colors in components, and no Tailwind palette classes such as `bg-blue-500` or `text-gray-600`.
- **Spacing:** padding, margin and gap use only the scale's steps (`1`, `2`, `3`, `5`, `8`, `18`) plus 0, 1px and 2px. No arbitrary values such as `p-[18px]`, and no other steps such as `p-6` or `gap-10`. `auto` margins are fine. Widths and heights such as `w-64` or `size-4` are sizes, not spacing. This applies to the code you write: a stock component keeps the spacing inside it, unless this brief changes it.
- **Type:** every piece of text you write gets its size from one of `text-display`, `text-h1`, `text-h2`, `text-body`, `text-label`, set on the element or on a parent it inherits from. Put `text-body` on the outermost element of the page you write. No other sizes. A stock shadcn component keeps the size it ships with, unless `DESIGN.md` or this brief gives that component its own style. A type class does not replace a weight class: where a stock component ships `font-medium` and the text should be regular, add `font-normal`.
- **Fonts:** only the theme's fonts, through `font-sans`, `font-heading` and `font-mono`. Do not add a font.
- **Corners:** only the `rounded-*` classes, which the theme already sets. No arbitrary radius, and `rounded-full` only where `DESIGN.md` or this brief names a full round, such as an avatar or a status dot. The theme allows a full round on a box up to 48px across; Strict Check reports a larger one, and a pill counts by its height.
- **Contrast:** all text meets WCAG AA against its background.
- **Stock components:** a component from `components/ui`, and an `<a>` styled with `buttonVariants`, keeps the hover, pressed and disabled colors and the motion it ships with, unless this brief changes them. They are the theme's colors under other names.
- **Counts:** a number with a noun reads right at one: "1 set", not "1 sets". Where this brief gives the words for only one of the two, write the other the same way.
- **Sizes from data:** a height or a width that comes from data (a chart bar, a meter) is set with an inline `style`. That is the one use for an inline style.
- **Focus:** every link and control shows a 2px outline on keyboard focus: `focus-visible:outline-solid focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ring`. Keep `focus-visible:outline-solid` in it: in Tailwind 4 an `outline-none` on the same element, which stock components carry, otherwise hides the outline. An element that only gets focus from code (a heading or a message with `tabIndex={-1}`) gets the same outline written with `focus:` in place of `focus-visible:` (`focus:outline-solid focus:outline-2 focus:outline-offset-2 focus:outline-ring`): after a mouse click, a browser does not match `:focus-visible` on an element that code focuses. A link, a button or a field that code focuses keeps the `focus-visible:` classes it has: after a mouse click it shows no outline, which is how a browser treats every control, and is right. A stock component that ships its own focus ring (`Button`, `buttonVariants`, `Input`, `Textarea`, `Checkbox`, `Switch`, `AccordionTrigger`, the close button of a `Sheet`) must lose that ring. Do it once, in the component's file in `components/ui`, which is yours to change: replace its `focus-visible:ring-*` classes with the outline classes, and in a field replace its `aria-invalid:ring-*` classes, the `dark:` ones included, with `aria-invalid:ring-0`, or a field with an error shows a tinted ring. `Button` has two more sets. Its base classes also carry `aria-invalid:ring-*` classes: replace them with `aria-invalid:ring-0`, as in a field. Its `destructive` variant carries `focus-visible:ring-*` classes of its own, the `dark:` one included: delete them and put nothing in their place, because the base classes already give every variant the outline. Wherever this rule says replace, change the classes in the file and do not add `ring-0` beside them: an added class only wins where it comes later and passes through `cn`. The stock `focus-visible:border-ring` can stay. These ring changes go only into the files of components that this page uses and that can take focus on it: a `Badge` that is not a link keeps its ring classes. The `cn` import from the setup steps is another matter and goes into every file. A box that scrolls sideways (a code block, a wide table) gets `tabIndex={0}`, `role="region"`, an `aria-label` and the same outline, also at widths where it happens to fit. Where a focusable box touches the edges of a parent that has `overflow-hidden`, draw its outline inside it: `focus-visible:-outline-offset-2` in place of `focus-visible:outline-offset-2`.
- **Not allowed:** purple or multi-color gradients; emoji used as icons or bullets; glows and colored shadows.
- **Avoid:** a card inside a card.
- **Dark mode:** the page must work with the `dark` class on `<html>`. Because every color comes from a semantic class, this needs no extra code; do not write `dark:` color overrides. A new shadcn project follows the system's mode and switches on the `d` key: leave that as it is, and add no mode switch of your own. If the page has a native `<select>` or a date or time field, tell the browser the mode, or its list and its picker stay light in dark mode: in the global CSS, give `:root` `color-scheme: light` and `.dark` `color-scheme: dark`.

From the theme's own do's and don'ts:

- Do use amber once in view, on the main action. The focus outline in dark mode does not count.
- Do set scores, times and positions large, in the heading font.
- Do keep text on a navy band white and labels on it ice blue, in both modes.
- Don't write in amber or orange on a light page, and don't use amber for a link.
- Don't slant, outline or stretch the heading font, and don't use gradients or glows.
- Don't put a card inside a card or a band inside a card.
- Don't introduce a color, size or radius that is not a token above.

## Check before you finish

Go through this list against the code you wrote, and fix anything that fails.

- [ ] The scoreboard is one band with the last result, Wendmoor FC 3–1 Otterby Town with the page's one Final badge, beside the next match and its kick-off time, the score and the time set in the heading font at `text-display` from `md` up.
- [ ] The header and the scoreboard are `bg-navy` in both modes, no text on them has a text color class but `text-ice` on labels (a crest and the badge keep their own pair), and the links there show their focus outline in `outline-navy-foreground`.
- [ ] The league table is a real `<table>` with a caption and scoped headers, shows the top five clubs, and marks Wendmoor FC, third on 27 points, with an ice blue row, a bold name and hidden words.
- [ ] Join the club in the page head is the only amber button on the page, and no text, link, icon or border is amber or orange.
- [ ] At 375px the header's nav sits on a second line, the two halves of the scoreboard stack, and the table fits without scrolling.
- [ ] No color is written as a hex, rgb or Tailwind palette value in the page's code.
- [ ] Every padding, margin and gap in the code you wrote is a step of the spacing scale.
- [ ] Every text element you wrote gets its size from a type-scale class, its own or an inherited one. Visually hidden text is exempt.
- [ ] No file in `components/ui` imports `cn` from `"cn"` directly.
- [ ] Text contrast meets WCAG AA in light and dark mode.
- [ ] The page has one `<h1>`, headings are in order, and every image has alt text.
- [ ] Every interactive element can be reached with the keyboard and shows the focus outline from the rules.
- [ ] At 375px wide the page does not scroll sideways. Wide tables and code blocks scroll inside their own box.
- [ ] The project builds without errors or warnings.

Then tell the user which checks pass, which you could not verify, and anything in this brief you did not do and why.
