Troubled is a shadcn/ui theme built around a neutral gray primary color (#dcdbdb) with neutral gray accents (#dbdbdc). The light mode uses a neutral background (#fdf8f7). Dark mode keeps the neutral gray primary (#dcdbdb) on a red-tinted background (#0e0807).
| Token | Light | Dark |
|---|---|---|
| Background | #fdf8f7snow | #0e0807black |
| Foreground | #000000black | #fdfcfcsnow |
| Card | #fdf8f7snow | #0e0807black |
| Card foreground | #000000black | #fdfcfcsnow |
| Popover | #fdf8f7snow | #0e0807black |
| Popover foreground | #000000black | #fdfcfcsnow |
| Primary | #dcdbdbgainsboro | #dcdbdbgainsboro |
| Primary foreground | #444141darkslategray | #444141darkslategray |
| Secondary | #dbdcdbgainsboro | #dbdcdbgainsboro |
| Secondary foreground | #414441darkslategray | #414441darkslategray |
| Muted | #d5ecd9gainsboro | #132a17black |
| Muted foreground | #36493adarkslategray | #b6c9b9silver |
| Accent | #dbdbdcgainsboro | #dbdbdcgainsboro |
| Accent foreground | #414144darkslategray | #414144darkslategray |
| Destructive | #9d2c07saddlebrown | #f5490forangered |
| Destructive foreground | #fde1d8mistyrose | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #dcdbdbgainsboro | #dcdbdbgainsboro |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.93:1 | AAA |
| Text on card | 19.93:1 | AAA |
| Primary button | 7.30:1 | AAA |
| Secondary button | 7.17:1 | AAA |
| Muted text | 7.75:1 | AAA |
| Accent | 7.32:1 | AAA |
| Destructive | 6.06:1 | AA |
| Text on background | 19.42:1 | AAA |
| Text on card | 19.42:1 | AAA |
| Primary button | 7.30:1 | AAA |
| Secondary button | 7.17:1 | AAA |
| Muted text | 8.76:1 | AAA |
| Accent | 7.32:1 | AAA |
| Destructive | 3.60:1 | AA Large |
Paste this into your globals.css to use Troubled in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.982 0.006 32.661);
--foreground: oklch(0 0 0);
--muted: oklch(0.921 0.035 150.844);
--muted-foreground: oklch(0.385 0.036 149.984);
--popover: oklch(0.982 0.006 32.661);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.982 0.006 32.661);
--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.892 0.001 32.661);
--primary-foreground: oklch(0.379 0.003 32.662);
--secondary: oklch(0.893 0.002 151.372);
--secondary-foreground: oklch(0.382 0.005 151.217);
--accent: oklch(0.891 0.002 294.783);
--accent-foreground: oklch(0.377 0.004 294.602);
--destructive: oklch(0.465 0.154 36.056);
--destructive-foreground: oklch(0.931 0.034 39.326);
--ring: oklch(0.892 0.001 32.661);
--chart-1: oklch(0.892 0.001 32.661);
--chart-2: oklch(0.893 0.002 151.372);
--chart-3: oklch(0.891 0.002 294.783);
--chart-4: oklch(0.916 0.002 151.38);
--chart-5: oklch(0.891 0.003 32.661);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.142 0.011 35.184);
--foreground: oklch(0.992 0.001 32.661);
--muted: oklch(0.261 0.046 148.434);
--muted-foreground: oklch(0.816 0.03 150.869);
--popover: oklch(0.142 0.011 35.184);
--popover-foreground: oklch(0.992 0.001 32.661);
--card: oklch(0.142 0.011 35.184);
--card-foreground: oklch(0.992 0.001 32.661);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.892 0.001 32.661);
--primary-foreground: oklch(0.379 0.003 32.662);
--secondary: oklch(0.893 0.002 151.372);
--secondary-foreground: oklch(0.382 0.005 151.217);
--accent: oklch(0.891 0.002 294.783);
--accent-foreground: oklch(0.377 0.004 294.602);
--destructive: oklch(0.647 0.217 35.825);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.892 0.001 32.661);
--chart-1: oklch(0.892 0.001 32.661);
--chart-2: oklch(0.893 0.002 151.372);
--chart-3: oklch(0.891 0.002 294.783);
--chart-4: oklch(0.916 0.002 151.38);
--chart-5: oklch(0.891 0.003 32.661);
}