Cotton is a shadcn/ui theme built around a vivid teal primary color (#14f0ae) with vivid cyan accents (#14c4f0). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid teal primary (#14f0ae) on a teal-tinted background (#030c09).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #030c09black |
| Foreground | #010403black | #f5faf8mintcream |
| Card | #fcfcfcsnow | #04100cblack |
| Card foreground | #000000black | #f8fcfbmintcream |
| Popover | #fcfcfcsnow | #04100cblack |
| Popover foreground | #000000black | #f8fcfbmintcream |
| Primary | #14f0aemediumspringgreen | #14f0aemediumspringgreen |
| Primary foreground | #033526darkgreen | #033526darkgreen |
| Secondary | #14f040limegreen | #14f040limegreen |
| Secondary foreground | #03350ddarkgreen | #03350ddarkgreen |
| Muted | #dadddagainsboro | #222523black |
| Muted foreground | #4c5d4fdarkslategray | #a2b3a6darkgray |
| Accent | #14c4f0deepskyblue | #14c4f0deepskyblue |
| Accent foreground | #032b35darkslategray | #032b35darkslategray |
| Destructive | #6c2304maroon | #f5540forangered |
| Destructive foreground | #fbc0a7lightpink | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #14f0aemediumspringgreen | #14f0aemediumspringgreen |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.58:1 | AAA |
| Text on card | 20.54:1 | AAA |
| Primary button | 9.15:1 | AAA |
| Secondary button | 8.93:1 | AAA |
| Muted text | 5.13:1 | AA |
| Accent | 7.27:1 | AAA |
| Destructive | 7.01:1 | AAA |
| Text on background | 18.77:1 | AAA |
| Text on card | 18.71:1 | AAA |
| Primary button | 9.15:1 | AAA |
| Secondary button | 8.93:1 | AAA |
| Muted text | 6.99:1 | AA |
| Accent | 7.27:1 | AAA |
| Destructive | 3.40:1 | AA Large |
Paste this into your globals.css to use Cotton in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.1 0.014 176.872);
--muted: oklch(0.894 0.005 151.914);
--muted-foreground: oklch(0.458 0.03 150.979);
--popover: oklch(0.992 0 161.565);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.992 0 161.565);
--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.847 0.177 164.376);
--primary-foreground: oklch(0.292 0.057 167.272);
--secondary: oklch(0.831 0.262 144.453);
--secondary-foreground: oklch(0.287 0.083 146.057);
--accent: oklch(0.761 0.138 222.065);
--accent-foreground: oklch(0.267 0.045 218.839);
--destructive: oklch(0.365 0.11 39.938);
--destructive-foreground: oklch(0.856 0.077 44.281);
--ring: oklch(0.847 0.177 164.376);
--chart-1: oklch(0.847 0.177 164.376);
--chart-2: oklch(0.831 0.262 144.453);
--chart-3: oklch(0.761 0.138 222.065);
--chart-4: oklch(0.835 0.255 145.005);
--chart-5: oklch(0.856 0.181 164.014);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.143 0.017 176.324);
--foreground: oklch(0.981 0.006 176.489);
--muted: oklch(0.262 0.007 151.577);
--muted-foreground: oklch(0.751 0.027 151.461);
--popover: oklch(0.159 0.02 174.178);
--popover-foreground: oklch(0.987 0.004 176.546);
--card: oklch(0.159 0.02 174.178);
--card-foreground: oklch(0.987 0.004 176.546);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.847 0.177 164.376);
--primary-foreground: oklch(0.292 0.057 167.272);
--secondary: oklch(0.831 0.262 144.453);
--secondary-foreground: oklch(0.287 0.083 146.057);
--accent: oklch(0.761 0.138 222.065);
--accent-foreground: oklch(0.267 0.045 218.839);
--destructive: oklch(0.659 0.208 38.588);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.847 0.177 164.376);
--chart-1: oklch(0.847 0.177 164.376);
--chart-2: oklch(0.831 0.262 144.453);
--chart-3: oklch(0.761 0.138 222.065);
--chart-4: oklch(0.835 0.255 145.005);
--chart-5: oklch(0.856 0.181 164.014);
}