Phosphate is a shadcn/ui theme built around a green primary color (#22d84f) with teal accents (#22d8ab). The light mode uses a neutral background (#ffffff). Dark mode keeps the green primary (#22d84f) on a neutral background (#030704).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #030704black |
| Foreground | #021206black | #f9fbf9mintcream |
| Card | #ffffffwhite | #030704black |
| Card foreground | #021206black | #f9fbf9mintcream |
| Popover | #ffffffwhite | #030704black |
| Popover foreground | #021206black | #f9fbf9mintcream |
| Primary | #22d84flimegreen | #22d84flimegreen |
| Primary foreground | #06280fblack | #06280fblack |
| Secondary | #4fd822limegreen | #4fd822limegreen |
| Secondary foreground | #0f2806black | #0f2806black |
| Muted | #eef4ebwhitesmoke | #0d140bblack |
| Muted foreground | #5a5f58dimgray | #a1a7a0darkgray |
| Accent | #22d8ablightseagreen | #22d8ablightseagreen |
| Accent foreground | #06281fblack | #06281fblack |
| Destructive | #b34e14sienna | #e87430chocolate |
| Destructive foreground | #ffffffwhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #22d84flimegreen | #22d84flimegreen |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.23:1 | AAA |
| Text on card | 19.23:1 | AAA |
| Primary button | 8.36:1 | AAA |
| Secondary button | 8.44:1 | AAA |
| Muted text | 5.84:1 | AA |
| Accent | 8.63:1 | AAA |
| Destructive | 5.21:1 | AA |
| Text on background | 19.46:1 | AAA |
| Text on card | 19.46:1 | AAA |
| Primary button | 8.36:1 | AAA |
| Secondary button | 8.44:1 | AAA |
| Muted text | 7.63:1 | AAA |
| Accent | 8.63:1 | AAA |
| Destructive | 6.96:1 | AA |
Paste this into your globals.css to use Phosphate in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.163 0.036 151.722);
--muted: oklch(0.96 0.013 137.786);
--muted-foreground: oklch(0.48 0.013 137.811);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.163 0.036 151.722);
--card: oklch(1 0 180);
--card-foreground: oklch(0.163 0.036 151.722);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.771 0.226 146.173);
--primary-foreground: oklch(0.244 0.06 148.389);
--secondary: oklch(0.777 0.238 139.832);
--secondary-foreground: oklch(0.247 0.065 138.692);
--accent: oklch(0.788 0.151 169.819);
--accent-foreground: oklch(0.249 0.042 172.907);
--destructive: oklch(0.547 0.146 45.203);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.771 0.226 146.173);
--chart-1: oklch(0.771 0.226 146.173);
--chart-2: oklch(0.777 0.238 139.832);
--chart-3: oklch(0.788 0.151 169.819);
--chart-4: oklch(0.795 0.238 139.604);
--chart-5: oklch(0.78 0.232 145.94);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.122 0.016 153.318);
--foreground: oklch(0.986 0.003 153.829);
--muted: oklch(0.179 0.02 137.99);
--muted-foreground: oklch(0.721 0.012 137.792);
--popover: oklch(0.122 0.016 153.318);
--popover-foreground: oklch(0.986 0.003 153.829);
--card: oklch(0.122 0.016 153.318);
--card-foreground: oklch(0.986 0.003 153.829);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.771 0.226 146.173);
--primary-foreground: oklch(0.244 0.06 148.389);
--secondary: oklch(0.777 0.238 139.832);
--secondary-foreground: oklch(0.247 0.065 138.692);
--accent: oklch(0.788 0.151 169.819);
--accent-foreground: oklch(0.249 0.042 172.907);
--destructive: oklch(0.683 0.164 47.182);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.771 0.226 146.173);
--chart-1: oklch(0.771 0.226 146.173);
--chart-2: oklch(0.777 0.238 139.832);
--chart-3: oklch(0.788 0.151 169.819);
--chart-4: oklch(0.795 0.238 139.604);
--chart-5: oklch(0.78 0.232 145.94);
}