Gruvbox Light Medium is a shadcn/ui theme built around a neutral gray primary color (#3b3735) with vivid yellow accents (#f6de7e). The light mode uses a yellow-tinted background (#fbf0c6). Dark mode keeps the neutral gray primary (#3b3735) on a yellow-tinted background (#fbf0c6).
| Token | Light | Dark |
|---|---|---|
| Background | #fbf0c6blanchedalmond | #fbf0c6blanchedalmond |
| Foreground | #3b3735darkslategray | #3b3735darkslategray |
| Card | #faeebcmoccasin | #faeebcmoccasin |
| Card foreground | #2e2b29darkslategray | #2e2b29darkslategray |
| Popover | #faedb7moccasin | #faedb7moccasin |
| Popover foreground | #201e1dblack | #201e1dblack |
| Primary | #3b3735darkslategray | #3b3735darkslategray |
| Primary foreground | #d3d0cflightgrey | #d3d0cflightgrey |
| Secondary | #bfbfbfsilver | #bfbfbfsilver |
| Secondary foreground | #262626darkslategray | #262626darkslategray |
| Muted | #dbd9d1lightgrey | #dbd9d1lightgrey |
| Muted foreground | #454236darkslategray | #454236darkslategray |
| Accent | #f6de7ekhaki | #f6de7ekhaki |
| Accent foreground | #3e3204darkolivegreen | #3e3204darkolivegreen |
| Destructive | #681203maroon | #681203maroon |
| Destructive foreground | #fcafa1lightpink | #fcafa1lightpink |
| Border | #f5e8b2wheat | #f5e8b2wheat |
| Input | #f3e4a5palegoldenrod | #f3e4a5palegoldenrod |
| Ring | #3b3735darkslategray | #3b3735darkslategray |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 10.32:1 | AAA |
| Text on card | 12.06:1 | AAA |
| Primary button | 7.66:1 | AAA |
| Secondary button | 8.25:1 | AAA |
| Muted text | 7.13:1 | AAA |
| Accent | 9.43:1 | AAA |
| Destructive | 7.02:1 | AAA |
| Text on background | 10.32:1 | AAA |
| Text on card | 12.06:1 | AAA |
| Primary button | 7.66:1 | AAA |
| Secondary button | 8.25:1 | AAA |
| Muted text | 7.13:1 | AAA |
| Accent | 9.43:1 | AAA |
| Destructive | 7.02:1 | AAA |
Paste this into your globals.css to use Gruvbox Light Medium in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.954 0.056 95.609);
--foreground: oklch(0.341 0.006 48.534);
--muted: oklch(0.885 0.011 95.175);
--muted-foreground: oklch(0.377 0.02 95.558);
--popover: oklch(0.943 0.07 95.702);
--popover-foreground: oklch(0.237 0.004 48.564);
--card: oklch(0.947 0.065 95.674);
--card-foreground: oklch(0.29 0.005 48.546);
--border: oklch(0.928 0.07 95.71);
--input: oklch(0.916 0.082 95.766);
--primary: oklch(0.341 0.006 48.534);
--primary-foreground: oklch(0.861 0.004 48.694);
--secondary: oklch(0.805 0 169.695);
--secondary-foreground: oklch(0.27 0 180);
--accent: oklch(0.901 0.119 95.697);
--accent-foreground: oklch(0.322 0.063 93.945);
--destructive: oklch(0.338 0.121 32.586);
--destructive-foreground: oklch(0.824 0.094 30.295);
--ring: oklch(0.341 0.006 48.534);
--chart-1: oklch(0.341 0.006 48.534);
--chart-2: oklch(0.805 0 169.695);
--chart-3: oklch(0.901 0.119 95.697);
--chart-4: oklch(0.829 0 180);
--chart-5: oklch(0.34 0.01 48.413);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.954 0.056 95.609);
--foreground: oklch(0.341 0.006 48.534);
--muted: oklch(0.885 0.011 95.175);
--muted-foreground: oklch(0.377 0.02 95.558);
--popover: oklch(0.943 0.07 95.702);
--popover-foreground: oklch(0.237 0.004 48.564);
--card: oklch(0.947 0.065 95.674);
--card-foreground: oklch(0.29 0.005 48.546);
--border: oklch(0.928 0.07 95.71);
--input: oklch(0.916 0.082 95.766);
--primary: oklch(0.341 0.006 48.534);
--primary-foreground: oklch(0.861 0.004 48.694);
--secondary: oklch(0.805 0 169.695);
--secondary-foreground: oklch(0.27 0 180);
--accent: oklch(0.901 0.119 95.697);
--accent-foreground: oklch(0.322 0.063 93.945);
--destructive: oklch(0.338 0.121 32.586);
--destructive-foreground: oklch(0.824 0.094 30.295);
--ring: oklch(0.341 0.006 48.534);
--chart-1: oklch(0.341 0.006 48.534);
--chart-2: oklch(0.805 0 169.695);
--chart-3: oklch(0.901 0.119 95.697);
--chart-4: oklch(0.829 0 180);
--chart-5: oklch(0.34 0.01 48.413);
}