Deviation is a shadcn/ui theme built around a deep violet primary color (#0b051a) with muted light violet accents (#beb5d4). The light mode uses a neutral background (#fcfbfe). Dark mode keeps the deep violet primary (#0b051a) on a violet-tinted background (#080410).
| Token | Light | Dark |
|---|---|---|
| Background | #fcfbfewhite | #080410black |
| Foreground | #040208black | #f7f6f9whitesmoke |
| Card | #f9f8fcghostwhite | #0a0614black |
| Card foreground | #020104black | #f9f9fbghostwhite |
| Popover | #fcfbfewhite | #080410black |
| Popover foreground | #040208black | #f7f6f9whitesmoke |
| Primary | #0b051ablack | #0b051ablack |
| Primary foreground | #d2c3f4thistle | #d2c3f4thistle |
| Secondary | #d3cfddlightgrey | #1e1d20black |
| Secondary foreground | #393348darkslategray | #b6b3bcsilver |
| Muted | #d4cde5lightgrey | #211a32darkslategray |
| Muted foreground | #5e5671dimgray | #968ea9darkgray |
| Accent | #beb5d4lightsteelblue | #292531darkslategray |
| Accent foreground | #272037darkslategray | #c1bccdsilver |
| Destructive | #bf1c0dfirebrick | #ef2c1aorangered |
| Destructive foreground | #ffffffwhite | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #0b051ablack | #0b051ablack |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.05:1 | AAA |
| Text on card | 19.64:1 | AAA |
| Primary button | 12.23:1 | AAA |
| Secondary button | 7.91:1 | AAA |
| Muted text | 4.46:1 | AA Large |
| Accent | 7.94:1 | AAA |
| Destructive | 6.21:1 | AA |
| Text on background | 18.80:1 | AAA |
| Text on card | 19.07:1 | AAA |
| Primary button | 12.23:1 | AAA |
| Secondary button | 8.13:1 | AAA |
| Muted text | 5.34:1 | AA |
| Accent | 8.06:1 | AAA |
| Destructive | 4.16:1 | AA Large |
Paste this into your globals.css to use Deviation in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.99 0.003 299.985);
--foreground: oklch(0.101 0.02 300.237);
--muted: oklch(0.86 0.034 299.364);
--muted-foreground: oklch(0.47 0.045 298.384);
--popover: oklch(0.99 0.003 299.985);
--popover-foreground: oklch(0.101 0.02 300.237);
--card: oklch(0.98 0.006 299.931);
--card-foreground: oklch(0.08 0.016 300.237);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.141 0.046 295.323);
--primary-foreground: oklch(0.845 0.069 298.658);
--secondary: oklch(0.863 0.019 299.658);
--secondary-foreground: oklch(0.336 0.037 298.148);
--accent: oklch(0.79 0.045 299.064);
--accent-foreground: oklch(0.262 0.044 297.075);
--destructive: oklch(0.515 0.197 30.092);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.141 0.046 295.323);
--chart-1: oklch(0.141 0.046 295.323);
--chart-2: oklch(0.863 0.019 299.658);
--chart-3: oklch(0.79 0.045 299.064);
--chart-4: oklch(0.889 0.016 299.741);
--chart-5: oklch(0.139 0.048 295.15);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.126 0.028 298.884);
--foreground: oklch(0.974 0.005 299.959);
--muted: oklch(0.239 0.047 296.535);
--muted-foreground: oklch(0.662 0.042 298.969);
--popover: oklch(0.126 0.028 298.884);
--popover-foreground: oklch(0.974 0.005 299.959);
--card: oklch(0.136 0.033 297.336);
--card-foreground: oklch(0.983 0.003 299.986);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.141 0.046 295.323);
--primary-foreground: oklch(0.845 0.069 298.658);
--secondary: oklch(0.232 0.007 299.52);
--secondary-foreground: oklch(0.772 0.012 299.769);
--accent: oklch(0.275 0.023 298.633);
--accent-foreground: oklch(0.805 0.023 299.547);
--destructive: oklch(0.614 0.23 30.055);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.141 0.046 295.323);
--chart-1: oklch(0.141 0.046 295.323);
--chart-2: oklch(0.232 0.007 299.52);
--chart-3: oklch(0.275 0.023 298.633);
--chart-4: oklch(0.263 0.009 299.484);
--chart-5: oklch(0.139 0.048 295.15);
}