Coalition is a shadcn/ui theme built around a vivid light violet primary color (#d8b1f6) with muted light violet accents (#d5cbdc). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid light violet primary (#d8b1f6) on a violet-tinted background (#0b060e).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #0b060eblack |
| Foreground | #08040cblack | #fdfcfdwhite |
| Card | #ffffffwhite | #0b060eblack |
| Card foreground | #08040cblack | #fdfcfdwhite |
| Popover | #ffffffwhite | #0b060eblack |
| Popover foreground | #08040cblack | #fdfcfdwhite |
| Primary | #d8b1f6plum | #d8b1f6plum |
| Primary foreground | #410c6aindigo | #410c6aindigo |
| Secondary | #e1dde4gainsboro | #2a222fdarkslategray |
| Secondary foreground | #493f50darkslategray | #c3b8ccsilver |
| Muted | #dacde5gainsboro | #281a32darkslategray |
| Muted foreground | #615f63dimgray | #9e9ca0darkgray |
| Accent | #d5cbdclightgrey | #423050darkslategray |
| Accent foreground | #3c3046darkslategray | #dacfe2gainsboro |
| Destructive | #7a2500maroon | #ff7033tomato |
| Destructive foreground | #ffc6adpeachpuff | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #d8b1f6plum | #d8b1f6plum |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.32:1 | AAA |
| Text on card | 20.32:1 | AAA |
| Primary button | 7.77:1 | AAA |
| Secondary button | 7.40:1 | AAA |
| Muted text | 4.15:1 | AA Large |
| Accent | 7.88:1 | AAA |
| Destructive | 6.65:1 | AA |
| Text on background | 19.58:1 | AAA |
| Text on card | 19.58:1 | AAA |
| Primary button | 7.77:1 | AAA |
| Secondary button | 8.06:1 | AAA |
| Muted text | 6.00:1 | AA |
| Accent | 7.93:1 | AAA |
| Destructive | 7.62:1 | AAA |
Paste this into your globals.css to use Coalition in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.119 0.023 312.493);
--muted: oklch(0.865 0.037 310.719);
--muted-foreground: oklch(0.489 0.007 310.965);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.119 0.023 312.493);
--card: oklch(1 0 180);
--card-foreground: oklch(0.119 0.023 312.493);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.818 0.104 309.971);
--primary-foreground: oklch(0.308 0.146 303.95);
--secondary: oklch(0.902 0.011 310.98);
--secondary-foreground: oklch(0.384 0.031 310.379);
--accent: oklch(0.856 0.025 310.834);
--accent-foreground: oklch(0.331 0.042 309.974);
--destructive: oklch(0.393 0.126 39.057);
--destructive-foreground: oklch(0.871 0.074 44.313);
--ring: oklch(0.818 0.104 309.971);
--chart-1: oklch(0.818 0.104 309.971);
--chart-2: oklch(0.902 0.011 310.98);
--chart-3: oklch(0.856 0.025 310.834);
--chart-4: oklch(0.927 0.008 311.008);
--chart-5: oklch(0.817 0.108 309.925);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.136 0.019 310.962);
--foreground: oklch(0.992 0.002 311.07);
--muted: oklch(0.247 0.049 309.293);
--muted-foreground: oklch(0.696 0.006 311.008);
--popover: oklch(0.136 0.019 310.962);
--popover-foreground: oklch(0.992 0.002 311.07);
--card: oklch(0.136 0.019 310.962);
--card-foreground: oklch(0.992 0.002 311.07);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.818 0.104 309.971);
--primary-foreground: oklch(0.308 0.146 303.95);
--secondary: oklch(0.267 0.026 310.239);
--secondary-foreground: oklch(0.798 0.03 310.76);
--accent: oklch(0.343 0.059 309.55);
--accent-foreground: oklch(0.87 0.028 310.8);
--destructive: oklch(0.711 0.189 41.477);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.818 0.104 309.971);
--chart-1: oklch(0.818 0.104 309.971);
--chart-2: oklch(0.267 0.026 310.239);
--chart-3: oklch(0.343 0.059 309.55);
--chart-4: oklch(0.296 0.03 310.201);
--chart-5: oklch(0.817 0.108 309.925);
}