I worked with a team that had three brand colors: brand, brand-light and brand-lighter. Then someone needed something a bit lighter than light. There was nowhere to put it, so they picked a value by eye, and the palette started to drift.
The four layers (raw value, primitive, semantic token and component) are standard. What matters is the decisions inside them, made once so nobody remakes them on every screen. These are the five I'd make again.
Build every scale in full before you need it.
Each color gets eleven steps from the start, before most of them have a use. It's preparing for what comes later: a new product, a client's brand, a state nobody planned. When someone needs lighter than light, primary-200 already exists, so nobody invents a shade.
primary
800 · #363636The white-label hook. Every primary action derives from this scale — swap it to rebrand the whole system.
- • Primary buttons & key CTAs (800)
- • Links and active states (600)
- • Hover / active steps (900 / 950)
Use two neutrals, not one.
Neutral is for surfaces and the text you read on them. Control is for the lines and states around them: borders, dividers, focus rings and disabled controls. With one gray, everything comes from the same ramp: a disabled button can land on the same shade as the card behind it and seem to vanish, and a border can match its surface and stop separating anything. With two, a control always stands apart from the surface it sits on, so people can tell what they can use.
neutral
50 · #f8fafcA cool blue-gray (slate) that does double duty — the surfaces you read on (page, cards, popovers) and the text on them (foreground, muted). Named neutral, not surface, because it's both.
- • Page, card & popover backgrounds (50)
- • Foreground & muted text (600+ / 950)
- • Muted / secondary surfaces (100)
control
100 · #f4f4f5The grays for the lines and states around controls — input borders, dividers, the focus ring, disabled. Kept separate from the neutral ramp so a border never blends into the surface it sits on.
- • Input borders & dividers (200)
- • Focus ring (400)
- • Disabled surface & text (100 / 500)
Define every surface, even when two look the same.
Canvas, page, card, section and modal are different roles, even when some share a color today. A card can match the canvas and still lift off it with a shadow, and a modal sits higher, with a stronger one. Naming each role early means it can change later without hunting down every place it appears.
The outermost base layer the whole app sits on. Pure white in light, near-black slate in dark.
- • App shell / body background
- • The backdrop pages float on
- • Behind every surface
The page surface that sits on the canvas.
- • Body background
- • Hero section background
- • Default layout color
Surface color for cards sitting on the page background.
- • Article cards in a feed
- • Stat tiles
- • Profile boxes
Surface for anything that floats above the page — small or large.
- • Dialogs & drawers / sheets
- • Dropdown menus & command palette
- • Tooltips & date pickers
Quieter surface for non-active areas.
- • Sidebar background
- • Table row hover
- • Code block background
The one surface + text combo used for anything non-interactive. Reach for it on any disabled control.
- • Greyed-out 'Submit' button
- • Disabled menu item
- • Read-only input field
Name colors by what they do.
Components ask for a role, like primary, destructive or error, never a hex. Roles also keep meanings apart. Destructive is an action: a button that deletes. Error is a state: a message or a badge. Naming roles this way gives the team a shared design language to build on.
Filled — highest-emphasis danger action.
- • 'Delete account' confirm
- • Primary danger CTA in a dialog
Filled destructive under the cursor.
- • Delete button on hover
Filled destructive while pressed.
- • Delete mid-click
State color signalling something went wrong.
- • Invalid form field border
- • System-error toast
- • Failed-validation icon
Soft tint for inline error messages.
- • Inline alert banner
- • Validation hint background
- • Error callout bg
Rebrand by changing one token.
Every button, link and active state asks for primary, so changing it once moves all of them. That's how Afi sells one simulator to many banks: when a bank buys SAREVI, its brand goes into the design system, not into every screen.
Filled — the main affirmative action.
- • 'Save' / 'Continue' button
- • Primary CTA
- • Active tab indicator
Filled primary under the cursor.
- • Button on hover
Filled primary while pressed.
- • Button mid-click
Write the rules where the AI reads them.
Today the system lives in Claude Design, and the team generates screens from it. Its README holds the decisions above, so the AI makes them the same way a designer would. I learned how to write those rules in Creating a design.md.