Foundations
The tokens every component is built from: a flat cream, white and ink palette with one orange accent, two typefaces, a small set of radii and shadows, and quiet motion. Every value here is read live from css/framework/tokens.css.
Colour tokens
Always use a token, never a raw hex: DesignSystemRulesTests fails the build on hex colours in views. If a value is missing, add it to :root in tokens.css first. Orange is the one accent: one primary action, one highlight and one active state per viewport. If a section feels too orange, it is.
Surfaces
--cream Header bands, inset bands behind card groups, input fills in filter bars.
--cream-warm Special callouts: newsletter band, notices.
--content The page body. Content is white, never cream.
--surface Cards, inputs, menus.
Ink & text
--ink Body text and dark slabs and the footer. Never pure black.
--ink-inverse Text on ink.
--text-muted Secondary text, meta, hints (5.6:1 on white).
--text-subtle A step lighter: the current breadcrumb (4.8:1 on white).
--inverse-muted Secondary text on ink.
Orange
--orange The one accent: dots, icons, borders, large text. Never behind small white text.
--orange-deep Primary button fill, any fill with white text, text links, eyebrows.
--orange-deeper Hover for orange-deep fills (primary button).
--orange-tint Orange chip fill, focus halo on inputs.
Blue
--blue Relief only: eyebrows on ink, illustration. Never text or focus rings on light.
--blue-tint Blue chip fill, placeholder art.
--blue-deep Text on blue tint; keyboard focus ring (--focus-ring).
States
--live Live and success dots and fills only. Never decorative.
--live-deep Green text (live chip, success notes) and fills behind white text.
--live-tint Live chip fill.
--warn-tint Warning chip fill.
--warn-deep Warning text.
--danger Errors, destructive actions, overlap warnings.
--danger-tint Error fills.
--danger-soft Danger zone card background.
--danger-border Danger zone card border.
--star Rating and favourite star only.
Lines & veils
--border Every 1px line and card outline.
--ink-soft Quiet hover fill on ghost controls.
--ink-veil Modal backdrop.
--ink-shadow-strong Colour inside --shadow-overlay.
--ink-scrim Dark veil behind controls that sit on photos.
- Reference colours as
var(--token)in framework CSS. - Pick state colours by meaning:
--livefor live and success,--warn-*for attention,--dangerfor errors. - Use
--bluefor relief: chips, illustration, eyebrows on ink.
- Pure black, the retired deep blue, or gradients as page backgrounds.
- Green for anything decorative.
- Blue as a call to action.
Accessible pairings
Text must reach WCAG AA: 4.5:1 for body and small text, 3:1 for large text (24px, or 18.5px bold). Use this table before you put text on a colour. Ratios are computed from the token values.
| Sample | Pairing | Ratio | Use |
|---|---|---|---|
| Aa | --ink on white | 18.5:1 | All body text. |
| Aa | --ink on --cream | 16.8:1 | Text in header bands and inset bands. |
| Aa | --ink-inverse on --ink | 16.8:1 | Dark slabs and the footer. |
| Aa | --text-muted on white / cream | 5.6:1 / 5.1:1 | Secondary text, meta, hints. |
| Aa | --orange-deep on white / cream | 5.4:1 / 4.9:1 | Text links, eyebrows, dates, any small orange text. |
| Aa | --orange on white / cream | 4.1:1 / 3.8:1 | Large text, icons, dots and borders only. Small text never sits in --orange. |
| Aa | White on --orange-deep / --orange-deeper | 5.4:1 / 7.0:1 | Primary button, active pills, counters, badges. White on --orange is 4.1:1 and fails for small text. |
| Aa | --live-deep on --live-tint / white | 5.1:1 / 5.8:1 | Live chip, success text. --live as text is 3.6:1 / 4.1:1 and fails. |
| Aa | --warn-deep on --warn-tint | 5.5:1 | Warn chips and notices. |
| Aa | --blue-deep on --blue-tint | 5.3:1 | Blue chips. |
| Aa | --blue on --ink | 7.9:1 | Eyebrows on dark slabs. |
| Aa | --blue on white | 2.4:1 | Never for text or focus rings on light backgrounds. |
| Aa | --focus-ring outline on white / cream | 6.3:1 / 5.6:1 | Every :focus-visible outline (needs 3:1). |
- Links in running text:
--orange-deep. - Check contrast when you add a new token pairing, and add it here.
- Small orange text on white or cream.
- Logo blue text on white or cream.
- Rely on colour alone for meaning; pair status colours with a label.
Typefaces
Two free, self-hosted typefaces. Space Grotesk carries the techy voice: headings, eyebrows, stats and dates. Instrument Sans does the reading: body copy and UI. Both load from css/fonts.css; never add a Google Fonts link or fall back to the retired Montserrat or Open Sans.
Learn, build and grow with AI.
Headings (600, -0.02em), eyebrows (500, uppercase), stats and dates (600, tabular numbers).
Every chapter is run by volunteers, with free events, talks and workshops around the world. Find yours, or put your city on the map.
Body 16.5px / 1.65 at 400, labels and buttons at 600. Running text stops at 65ch (.prose).
Type scale
Headings carry no size of their own: the context class sets it, so use the real container (.home-hero, .hero, .sec-head, .card) instead of picking a size. Sizes are fluid clamp() values that land on the mobile and desktop steps below.
Learn, build and grow with AI.
Free events, courses and a community of 199 chapters in 76 countries.
Find your next event.
Talks, workshops and full-day conferences, hosted by chapters around the world.
Events near you
AgentCon - London
Sep 8 · London South Bank University
Body text sits at 16.5px with a 1.65 line height, in ink on white.
| Step | Desktop / mobile | Rendered by | Use |
|---|---|---|---|
| Display | 64 / 38px, 650 | .home-hero h1 | The homepage headline only. |
| h1 | 48 / 30px, 600 | .hero h1 | Page titles, one per page. |
| h2 | 34 / 26px, 600 | .sec-head h2 | Section titles. |
| h3 | 19px, 600 | .card h3 and friends | Card and block titles. |
| Body | 16.5px, 400 | body | Default text. Hero sublines use .hero-sub (about 18px, muted). |
| Small | 14px, 500 | .crumbs, .stat-mini | Captions and meta. |
| Eyebrow | 13px, 500, uppercase | .eyebrow | Section labels. |
- Keep heading levels in order: one
h1, thenh2per section. - Write headings in sentence case.
- Pick a heading level for its size; change the context class instead.
- Set font sizes inline or per page for a one-off.
Eyebrow
The signature device: every section opens with a short uppercase label above its heading. Use .eyebrow on a <span>; add .eyebrow-block when it sits directly above a heading outside a .sec-head. On ink it turns logo blue automatically.
Your local AI crew.
Start a chapter in your city.
- One to three words: "Upcoming", "Local chapters", "AI news".
- Keep it a
<span>; the heading below carries the meaning.
- Use an eyebrow as the only label for a section (screen readers need the heading).
- Stack two eyebrows.
Tabular numbers
Stats, dates, times, durations and counts use Space Grotesk with font-feature-settings: "tnum" so digits line up and count-ups don't jitter. The framework classes already set it: .hero-stats, .stat-big, .card-date, .stat-mini, .hero-meta, .going, .otp-input.
- Use the existing stat and date classes; they carry
tnum. - When you add a numeric style to the framework, include
font-feature-settings: "tnum".
- Show changing numbers in proportional figures.
Spacing
Space comes from a fixed scale, applied with flex and grid gap rather than margins. Section rhythm comes from two tokens: --section-gap between content sections (.home-sec, .slab-zone) and --head-gap under a section head.
| Step | Preview |
|---|---|
| 4 | |
| 8 | |
| 12 | |
| 16 | |
| 24 | |
| 32 | |
| 48 | |
| 64 | |
| 96 | |
| 128 | |
--section-gap | |
--head-gap | |
--gutter |
- Use
gapon.cluster,.stack-md,.fstackand grids. - Use
var(--section-gap)andvar(--head-gap)for section rhythm so every page breathes the same.
- Invent off-scale values like 13px or 37px.
- Space sections with margins on their children.
Radii
Four radii, no sharp corners. Large surfaces get the large radius; actions are always pills.
--r-card Cards, inset bands, dark slabs, modals.
--r-media Images, thumbnails, notices, filter bar.
--r-input Inputs, selects, textareas, OTP boxes.
--r-pill Buttons, chips, segmented controls, filter inputs.
Shadows & scrim
Depth is rare. --shadow-card is the only shadow allowed in the page, and nothing grows it on hover. Things that float above the page (modals, dropdowns, toasts, menus) use the overlay shadows. --ink-scrim darkens a photo just enough to put a control on it.
--shadow-cardIn-page only: hero photos, toggle knobs, selected segments, suggestion lists.
--shadow-overlayModals and nav dropdowns.
--shadow-floatToasts, tooltips, row menus.
Scrim on a photo
- Use the tokens; never write a new
box-shadowvalue. - Give overlay controls on photos an
aria-labeland keep them reachable by keyboard.
- Hard or offset shadows.
- Add or grow a shadow on hover.
Motion
Motion is seasoning, not the meal. Hover feedback is colour: cards warm their border to orange, list rows tint cream, buttons darken, arrows nudge right. Nothing lifts, grows a shadow or zooms. Hover the examples.
Scroll reveal
Learn
Free, hands-on courses.
Meet
Events in 76 countries.
Build
Ship something real.
| Motion | Timing | Rule |
|---|---|---|
| Hover | 200ms ease-out | Colour only: border-color, background-color, color, or a small arrow translateX. |
| Reveal | 600ms cubic-bezier(0.22, 1, 0.36, 1) | Add .reveal; the site script adds .in once when it enters the viewport (fade up 16px). No parallax. |
| Count-up | About 1.3s | .stat-big b[data-count] rolls up on load. |
| Reduced motion | - | prefers-reduced-motion: reduce shows reveals immediately, removes transitions and stops loops (marquee, logo strip, photo river, map pins). |
- Animate colour on hover, at 200ms ease-out.
- Put new keyframes in
motion.cssand switch them off under reduced motion. - Pause loops on hover; at most two per page.
translateYlifts,scalezooms or shadow growth on hover.- Zoom photos on hover.
- Motion that carries meaning on its own.