Emerald is a shadcn/ui theme built around a neutral gray primary color (#6c6c6a) with neutral gray accents (#6c6a6c). The light mode uses a neutral background (#fefdfb). Dark mode keeps the neutral gray primary (#6c6c6a) on a yellow-tinted background (#0a0a05).
| Token | Light | Dark |
|---|---|---|
| Background | #fefdfbsnow | #0a0a05black |
| Foreground | #000000black | #fdfdfcwhite |
| Card | #fdfcf7snow | #0e0d07black |
| Card foreground | #000000black | #ffffffwhite |
| Popover | #fefdfbsnow | #0a0a05black |
| Popover foreground | #000000black | #fdfdfcwhite |
| Primary | #6c6c6adimgray | #6c6c6adimgray |
| Primary foreground | #ffffffwhite | #ffffffwhite |
| Secondary | #6a6c6cdimgray | #6a6c6cdimgray |
| Secondary foreground | #ffffffwhite | #ffffffwhite |
| Muted | #e6eaealavender | #151919black |
| Muted foreground | #474d4cdarkslategray | #b2b8b7silver |
| Accent | #6c6a6cdimgray | #6c6a6cdimgray |
| Accent foreground | #ffffffwhite | #ffffffwhite |
| Destructive | #a90f0ffirebrick | #ef4343tomato |
| Destructive foreground | #fdececlinen | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #6c6c6adimgray | #6c6c6adimgray |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.70:1 | AAA |
| Text on card | 20.41:1 | AAA |
| Primary button | 5.26:1 | AA |
| Secondary button | 5.27:1 | AA |
| Muted text | 7.12:1 | AAA |
| Accent | 5.36:1 | AA |
| Destructive | 6.66:1 | AA |
| Text on background | 19.50:1 | AAA |
| Text on card | 19.46:1 | AAA |
| Primary button | 5.26:1 | AA |
| Secondary button | 5.27:1 | AA |
| Muted text | 8.80:1 | AAA |
| Accent | 5.36:1 | AA |
| Destructive | 3.78:1 | AA Large |
Paste this into your globals.css to use Emerald in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.995 0.003 100.377);
--foreground: oklch(0 0 0);
--muted: oklch(0.934 0.004 188.796);
--muted-foreground: oklch(0.414 0.008 188.462);
--popover: oklch(0.995 0.003 100.377);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.99 0.006 100.425);
--card-foreground: oklch(0 0 0);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.531 0.003 100.415);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.53 0.003 188.79);
--secondary-foreground: oklch(1 0 180);
--accent: oklch(0.527 0.004 322.139);
--accent-foreground: oklch(1 0 180);
--destructive: oklch(0.467 0.184 28.332);
--destructive-foreground: oklch(0.957 0.019 17.483);
--ring: oklch(0.531 0.003 100.415);
--chart-1: oklch(0.531 0.003 100.415);
--chart-2: oklch(0.53 0.003 188.79);
--chart-3: oklch(0.527 0.004 322.139);
--chart-4: oklch(0.557 0.003 188.789);
--chart-5: oklch(0.538 0.012 100.653);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.142 0.012 102.627);
--foreground: oklch(0.993 0.001 100.343);
--muted: oklch(0.209 0.006 188.177);
--muted-foreground: oklch(0.778 0.007 188.705);
--popover: oklch(0.142 0.012 102.627);
--popover-foreground: oklch(0.993 0.001 100.343);
--card: oklch(0.158 0.014 101.884);
--card-foreground: oklch(1 0 180);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.531 0.003 100.415);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.53 0.003 188.79);
--secondary-foreground: oklch(1 0 180);
--accent: oklch(0.527 0.004 322.139);
--accent-foreground: oklch(1 0 180);
--destructive: oklch(0.636 0.208 25.378);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.531 0.003 100.415);
--chart-1: oklch(0.531 0.003 100.415);
--chart-2: oklch(0.53 0.003 188.79);
--chart-3: oklch(0.527 0.004 322.139);
--chart-4: oklch(0.557 0.003 188.789);
--chart-5: oklch(0.538 0.012 100.653);
}