Troubled for shadcn/ui

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).

Color palette

TokenLightDark
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

Contrast

WCAG 2 contrast ratios between each background and its foreground color.

Light mode
Text on background19.93:1AAA
Text on card19.93:1AAA
Primary button7.30:1AAA
Secondary button7.17:1AAA
Muted text7.75:1AAA
Accent7.32:1AAA
Destructive6.06:1AA
Dark mode
Text on background19.42:1AAA
Text on card19.42:1AAA
Primary button7.30:1AAA
Secondary button7.17:1AAA
Muted text8.76:1AAA
Accent7.32:1AAA
Destructive3.60:1AA Large

CSS variables

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);
}