Cation is a shadcn/ui theme built around a vivid green primary color (#5fed0c) with muted light green accents (#dce3d9). The light mode uses a neutral background (#fcfefb). Dark mode keeps the vivid green primary (#5fed0c) on a neutral background (#000000).
| Token | Light | Dark |
|---|---|---|
| Background | #fcfefbwhite | #000000black |
| Foreground | #000000black | #fcfdfcwhite |
| Card | #f9fcf8mintcream | #030303black |
| Card foreground | #000000black | #ffffffwhite |
| Popover | #fcfefbwhite | #000000black |
| Popover foreground | #000000black | #fcfdfcwhite |
| Primary | #5fed0clawngreen | #5fed0clawngreen |
| Primary foreground | #112c02black | #112c02black |
| Secondary | #dce3d9gainsboro | #1e221cblack |
| Secondary foreground | #42503adarkslategray | #b6bfb0silver |
| Muted | #eaece9linen | #141613black |
| Muted foreground | #404c38darkslategray | #bac7b3silver |
| Accent | #dce3d9gainsboro | #1e221cblack |
| Accent foreground | #42503adarkslategray | #b6bfb0silver |
| Destructive | #d93f02orangered | #fd4d08orangered |
| Destructive foreground | #ffffffwhite | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #5fed0clawngreen | #5fed0clawngreen |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.67:1 | AAA |
| Text on card | 20.34:1 | AAA |
| Primary button | 9.85:1 | AAA |
| Secondary button | 6.58:1 | AA |
| Muted text | 7.66:1 | AAA |
| Accent | 6.58:1 | AA |
| Destructive | 4.49:1 | AA Large |
| Text on background | 20.59:1 | AAA |
| Text on card | 20.67:1 | AAA |
| Primary button | 9.85:1 | AAA |
| Secondary button | 8.54:1 | AAA |
| Muted text | 10.31:1 | AAA |
| Accent | 8.54:1 | AAA |
| Destructive | 3.37:1 | AA Large |
Paste this into your globals.css to use Cation in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.994 0.004 133.628);
--foreground: oklch(0 0 0);
--muted: oklch(0.941 0.005 133.638);
--muted-foreground: oklch(0.4 0.036 134.214);
--popover: oklch(0.994 0.004 133.628);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.988 0.007 133.65);
--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.835 0.259 138.588);
--primary-foreground: oklch(0.261 0.074 136.182);
--secondary: oklch(0.908 0.016 133.716);
--secondary-foreground: oklch(0.412 0.04 134.26);
--accent: oklch(0.908 0.016 133.716);
--accent-foreground: oklch(0.412 0.04 134.26);
--destructive: oklch(0.59 0.199 36.548);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.835 0.259 138.588);
--chart-1: oklch(0.835 0.259 138.588);
--chart-2: oklch(0.908 0.016 133.716);
--chart-3: oklch(0.908 0.016 133.716);
--chart-4: oklch(0.93 0.012 133.688);
--chart-5: oklch(0.845 0.263 138.77);
}
.dark {
--radius: 0.5rem;
--background: oklch(0 0 0);
--foreground: oklch(0.994 0.003 133.622);
--muted: oklch(0.197 0.007 133.838);
--muted-foreground: oklch(0.813 0.031 133.846);
--popover: oklch(0 0 0);
--popover-foreground: oklch(0.994 0.003 133.622);
--card: oklch(0.092 0 180);
--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.835 0.259 138.588);
--primary-foreground: oklch(0.261 0.074 136.182);
--secondary: oklch(0.244 0.013 133.941);
--secondary-foreground: oklch(0.793 0.022 133.783);
--accent: oklch(0.244 0.013 133.941);
--accent-foreground: oklch(0.793 0.022 133.783);
--destructive: oklch(0.664 0.221 36.748);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.835 0.259 138.588);
--chart-1: oklch(0.835 0.259 138.588);
--chart-2: oklch(0.244 0.013 133.941);
--chart-3: oklch(0.244 0.013 133.941);
--chart-4: oklch(0.278 0.015 133.964);
--chart-5: oklch(0.845 0.263 138.77);
}