Green is a shadcn/ui theme built around a deep green primary color (#14823c) with neutral gray accents (#d6d6d6). The light mode uses a neutral background (#f0f0f0). Dark mode keeps the deep green primary (#14823c) on a neutral background (#0f0f0f).
| Token | Light | Dark |
|---|---|---|
| Background | #f0f0f0whitesmoke | #0f0f0fblack |
| Foreground | #0f0f0fblack | #f0f0f0whitesmoke |
| Card | #edededwhitesmoke | #121212black |
| Card foreground | #121212black | #edededwhitesmoke |
| Popover | #edededwhitesmoke | #121212black |
| Popover foreground | #121212black | #edededwhitesmoke |
| Primary | #14823cforestgreen | #14823cforestgreen |
| Primary foreground | #ffffffwhite | #ffffffwhite |
| Secondary | #dbdbdbgainsboro | #242424darkslategray |
| Secondary foreground | #242424darkslategray | #dbdbdbgainsboro |
| Muted | #e0e0e0gainsboro | #1f1f1fblack |
| Muted foreground | #1f1f1fblack | #e0e0e0gainsboro |
| Accent | #d6d6d6lightgrey | #242424darkslategray |
| Accent foreground | #0f0f0fblack | #f0f0f0whitesmoke |
| Destructive | #f87272salmon | #f87272salmon |
| Destructive foreground | #ffffffwhite | #ffffffwhite |
| Border | #e0e0e0gainsboro | #1f1f1fblack |
| Input | #e0e0e0gainsboro | #1f1f1fblack |
| Ring | #146e3cforestgreen | #23b45fmediumseagreen |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 16.77:1 | AAA |
| Text on card | 16.02:1 | AAA |
| Primary button | 4.89:1 | AA |
| Secondary button | 11.24:1 | AAA |
| Muted text | 12.53:1 | AAA |
| Accent | 13.21:1 | AAA |
| Destructive | 2.74:1 | Fail |
| Text on background | 16.78:1 | AAA |
| Text on card | 16.02:1 | AAA |
| Primary button | 4.89:1 | AA |
| Secondary button | 11.25:1 | AAA |
| Muted text | 12.54:1 | AAA |
| Accent | 13.67:1 | AAA |
| Destructive | 2.74:1 | Fail |
Paste this into your globals.css to use Green in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.954 0 180);
--foreground: oklch(0.17 0 180);
--muted: oklch(0.908 0 180);
--muted-foreground: oklch(0.238 0 161.565);
--popover: oklch(0.947 0 180);
--popover-foreground: oklch(0.182 0 164.055);
--card: oklch(0.947 0 180);
--card-foreground: oklch(0.182 0 164.055);
--border: oklch(0.908 0 180);
--input: oklch(0.908 0 180);
--primary: oklch(0.533 0.141 149.578);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.892 0 180);
--secondary-foreground: oklch(0.259 0 167.471);
--accent: oklch(0.877 0 180);
--accent-foreground: oklch(0.17 0 180);
--destructive: oklch(0.712 0.165 22.149);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.475 0.114 153.111);
--chart-1: oklch(0.533 0.141 149.578);
--chart-2: oklch(0.892 0 180);
--chart-3: oklch(0.877 0 180);
--chart-4: oklch(0.916 0 180);
--chart-5: oklch(0.539 0.145 149.276);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.17 0 180);
--foreground: oklch(0.954 0 180);
--muted: oklch(0.238 0 161.565);
--muted-foreground: oklch(0.908 0 180);
--popover: oklch(0.182 0 164.055);
--popover-foreground: oklch(0.947 0 180);
--card: oklch(0.182 0 164.055);
--card-foreground: oklch(0.947 0 180);
--border: oklch(0.238 0 161.565);
--input: oklch(0.238 0 161.565);
--primary: oklch(0.533 0.141 149.578);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.259 0 167.471);
--secondary-foreground: oklch(0.892 0 180);
--accent: oklch(0.259 0 167.471);
--accent-foreground: oklch(0.954 0 180);
--destructive: oklch(0.712 0.165 22.149);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.678 0.17 151.556);
--chart-1: oklch(0.533 0.141 149.578);
--chart-2: oklch(0.259 0 167.471);
--chart-3: oklch(0.259 0 167.471);
--chart-4: oklch(0.29 0 180);
--chart-5: oklch(0.539 0.145 149.276);
}