Headrest is a shadcn/ui theme built around a muted deep yellow primary color (#473e2a) with muted deep violet accents (#3e2a47). The light mode uses a neutral background (#fbfbf8). Dark mode keeps the muted deep yellow primary (#473e2a) on a yellow-tinted background (#100d04).
| Token | Light | Dark |
|---|---|---|
| Background | #fbfbf8snow | #100d04black |
| Foreground | #161104black | #f9f8f6whitesmoke |
| Card | #fbfbf8snow | #100d04black |
| Card foreground | #161104black | #f9f8f6whitesmoke |
| Popover | #fbfbf8snow | #100d04black |
| Popover foreground | #161104black | #f9f8f6whitesmoke |
| Primary | #473e2adarkslategray | #473e2adarkslategray |
| Primary foreground | #ddd6c5lightgrey | #ddd6c5lightgrey |
| Secondary | #2a473edarkslategray | #2a473edarkslategray |
| Secondary foreground | #c5ddd6lightgrey | #c5ddd6lightgrey |
| Muted | #e5f1edlavender | #0e1a17black |
| Muted foreground | #455450darkslategray | #abbab6darkgray |
| Accent | #3e2a47darkslategray | #3e2a47darkslategray |
| Accent foreground | #d6c5ddthistle | #d6c5ddthistle |
| Destructive | #d03111firebrick | #ef5739tomato |
| Destructive foreground | #ffffffwhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #473e2adarkslategray | #473e2adarkslategray |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 18.11:1 | AAA |
| Text on card | 18.11:1 | AAA |
| Primary button | 7.26:1 | AAA |
| Secondary button | 7.12:1 | AAA |
| Muted text | 6.85:1 | AA |
| Accent | 7.94:1 | AAA |
| Destructive | 5.10:1 | AA |
| Text on background | 18.30:1 | AAA |
| Text on card | 18.30:1 | AAA |
| Primary button | 7.26:1 | AAA |
| Secondary button | 7.12:1 | AAA |
| Muted text | 8.82:1 | AAA |
| Accent | 7.94:1 | AAA |
| Destructive | 6.09:1 | AA |
Paste this into your globals.css to use Headrest in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.987 0.003 88.811);
--foreground: oklch(0.178 0.027 90.32);
--muted: oklch(0.947 0.013 177.303);
--muted-foreground: oklch(0.432 0.02 176.269);
--popover: oklch(0.987 0.003 88.811);
--popover-foreground: oklch(0.178 0.027 90.32);
--card: oklch(0.987 0.003 88.811);
--card-foreground: oklch(0.178 0.027 90.32);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.368 0.035 88.896);
--primary-foreground: oklch(0.878 0.024 88.943);
--secondary: oklch(0.371 0.038 174.216);
--secondary-foreground: oklch(0.878 0.027 176.794);
--accent: oklch(0.321 0.057 316.042);
--accent-foreground: oklch(0.845 0.038 316.479);
--destructive: oklch(0.561 0.199 32.637);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.368 0.035 88.896);
--chart-1: oklch(0.368 0.035 88.896);
--chart-2: oklch(0.371 0.038 174.216);
--chart-3: oklch(0.321 0.057 316.042);
--chart-4: oklch(0.404 0.042 174.132);
--chart-5: oklch(0.371 0.039 88.819);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.159 0.02 91.382);
--foreground: oklch(0.979 0.003 88.813);
--muted: oklch(0.207 0.018 174.811);
--muted-foreground: oklch(0.776 0.018 177.029);
--popover: oklch(0.159 0.02 91.382);
--popover-foreground: oklch(0.979 0.003 88.813);
--card: oklch(0.159 0.02 91.382);
--card-foreground: oklch(0.979 0.003 88.813);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.368 0.035 88.896);
--primary-foreground: oklch(0.878 0.024 88.943);
--secondary: oklch(0.371 0.038 174.216);
--secondary-foreground: oklch(0.878 0.027 176.794);
--accent: oklch(0.321 0.057 316.042);
--accent-foreground: oklch(0.845 0.038 316.479);
--destructive: oklch(0.656 0.193 33.207);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.368 0.035 88.896);
--chart-1: oklch(0.368 0.035 88.896);
--chart-2: oklch(0.371 0.038 174.216);
--chart-3: oklch(0.321 0.057 316.042);
--chart-4: oklch(0.404 0.042 174.132);
--chart-5: oklch(0.371 0.039 88.819);
}