Portfolio design system
This site has a design system. Read DESIGN.md at the repo root before changing any styling, and work from it.
Rules
- Every colour, font size, spacing step, radius, and duration is a CSS custom property in the
:rootblock at the top ofindex.html. Use the token in rules. Never write a raw hex value, pixel size, or duration that a token already covers. - A new value needs a new token in
:rootand a matching row inDESIGN.md, in the same change. The design system also lives in Claude as a Design System artifact (https://claude.ai/artifact/2iPwsVBSqA9gs8nkaYC5g1). When a token, pattern, or rule changes here, update that artifact'sproject/tokens.jsonandproject/README.mdin the same piece of work, so the three copies never drift. - Text and background come as a pair. A new panel colour class sets both. Check the pairing against the AA list in
DESIGN.md, and run the axe scan fromREADME.mdbefore opening a pull request. - There is no dark mode. Do not add
prefers-color-scheme: darkrules. The page setscolor-scheme: lighton purpose. - Motion uses
--easeand the--dur-*tokens and must stop underprefers-reduced-motion: reduce. - Test at 390 px and 1280 px wide, with reduced motion on and off, using the
webapp-testingskill. A styling refactor should produce pixel-identical screenshots before and after.
Where things live
- Tokens:
:rootinindex.html - Reference and pattern catalogue:
DESIGN.md - Three.js colours: hex literals in
scene.js, kept in step with the palette by hand - The copy inside Claude: https://claude.ai/artifact/2iPwsVBSqA9gs8nkaYC5g1 (tokens, brand book, component previews)