Cooperative is a shadcn/ui theme built around a muted light red primary color (#e0d1d1) with muted light red accents (#e3dede). The light mode uses a neutral background (#fefbfb). Dark mode keeps the muted light red primary (#e0d1d1) on a neutral background (#000000).
| Token | Light | Dark |
|---|---|---|
| Background | #fefbfbsnow | #000000black |
| Foreground | #000000black | #ffffffwhite |
| Card | #fefbfbsnow | #000000black |
| Card foreground | #000000black | #ffffffwhite |
| Popover | #fefbfbsnow | #000000black |
| Popover foreground | #000000black | #ffffffwhite |
| Primary | #e0d1d1lightgrey | #e0d1d1lightgrey |
| Primary foreground | #4d3333darkslategray | #4d3333darkslategray |
| Secondary | #e3dedegainsboro | #1b1313black |
| Secondary foreground | #4d4242darkslategray | #bfa1a1darkgray |
| Muted | #f6efefwhitesmoke | #100909black |
| Muted foreground | #5c4747darkolivegreen | #b8a3a3darkgray |
| Accent | #e3dedegainsboro | #1b1313black |
| Accent foreground | #4d4242darkslategray | #bfa1a1darkgray |
| Destructive | #821e03maroon | #f03805orangered |
| Destructive foreground | #fec8b9peachpuff | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #e0d1d1lightgrey | #e0d1d1lightgrey |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.40:1 | AAA |
| Text on card | 20.40:1 | AAA |
| Primary button | 7.74:1 | AAA |
| Secondary button | 7.25:1 | AAA |
| Muted text | 7.54:1 | AAA |
| Accent | 7.25:1 | AAA |
| Destructive | 6.63:1 | AA |
| Text on background | 21.00:1 | AAA |
| Text on card | 21.00:1 | AAA |
| Primary button | 7.74:1 | AAA |
| Secondary button | 7.69:1 | AAA |
| Muted text | 8.25:1 | AAA |
| Accent | 7.69:1 | AAA |
| Destructive | 3.98:1 | AA Large |
Paste this into your globals.css to use Cooperative in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.99 0.003 17.207);
--foreground: oklch(0 0 0);
--muted: oklch(0.957 0.008 17.291);
--muted-foreground: oklch(0.42 0.029 18.379);
--popover: oklch(0.99 0.003 17.207);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.99 0.003 17.207);
--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.873 0.017 17.484);
--primary-foreground: oklch(0.351 0.037 19.099);
--secondary: oklch(0.904 0.005 17.256);
--secondary-foreground: oklch(0.39 0.016 17.848);
--accent: oklch(0.904 0.005 17.256);
--accent-foreground: oklch(0.39 0.016 17.848);
--destructive: oklch(0.4 0.139 34.699);
--destructive-foreground: oklch(0.876 0.065 35.983);
--ring: oklch(0.873 0.017 17.484);
--chart-1: oklch(0.873 0.017 17.484);
--chart-2: oklch(0.904 0.005 17.256);
--chart-3: oklch(0.904 0.005 17.256);
--chart-4: oklch(0.928 0.004 17.229);
--chart-5: oklch(0.872 0.02 17.535);
}
.dark {
--radius: 0.5rem;
--background: oklch(0 0 0);
--foreground: oklch(1 0 180);
--muted: oklch(0.151 0.013 18.677);
--muted-foreground: oklch(0.733 0.025 17.733);
--popover: oklch(0 0 0);
--popover-foreground: oklch(1 0 180);
--card: oklch(0 0 0);
--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.873 0.017 17.484);
--primary-foreground: oklch(0.351 0.037 19.099);
--secondary: oklch(0.196 0.015 18.468);
--secondary-foreground: oklch(0.735 0.036 17.989);
--accent: oklch(0.196 0.015 18.468);
--accent-foreground: oklch(0.735 0.036 17.989);
--destructive: oklch(0.623 0.225 33.569);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.873 0.017 17.484);
--chart-1: oklch(0.873 0.017 17.484);
--chart-2: oklch(0.196 0.015 18.468);
--chart-3: oklch(0.196 0.015 18.468);
--chart-4: oklch(0.227 0.019 18.631);
--chart-5: oklch(0.872 0.02 17.535);
}