Gloom for shadcn/ui

Gloom is a shadcn/ui theme built around a muted cyan primary color (#506062) with muted red accents (#625350). The light mode uses a neutral background (#ffffff). Dark mode keeps the muted cyan primary (#506062) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#ffffffwhite
#000000black
Foreground
#021012black
#f5f9faghostwhite
Card
#fcfcfcsnow
#030303black
Card foreground
#020c0eblack
#f8fbfbghostwhite
Popover
#fcfcfcsnow
#030303black
Popover foreground
#020c0eblack
#f8fbfbghostwhite
Primary
#506062dimgray
#506062dimgray
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#625350dimgray
#625350dimgray
Secondary foreground
#f4f1f1whitesmoke
#f4f1f1whitesmoke
Muted
#e2d6d4gainsboro
#2b1e1dblack
Muted foreground
#675d5bdimgray
#a49a98darkgray
Accent
#625350dimgray
#625350dimgray
Accent foreground
#f4f1f1whitesmoke
#f4f1f1whitesmoke
Destructive
#a02303firebrick
#fb5e37tomato
Destructive foreground
#fedfd7mistyrose
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#506062dimgray
#506062dimgray

Contrast

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

Light mode
Text on background19.34:1AAA
Text on card19.35:1AAA
Primary button6.59:1AA
Secondary button6.52:1AA
Muted text4.50:1AA
Accent6.52:1AA
Destructive6.13:1AA
Dark mode
Text on background19.81:1AAA
Text on card19.87:1AAA
Primary button6.59:1AA
Secondary button6.52:1AA
Muted text5.84:1AA
Accent6.52:1AA
Destructive6.76:1AA

CSS variables

Paste this into your globals.css to use Gloom in your shadcn/ui project.

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.161 0.023 206.611);
  --muted: oklch(0.886 0.014 28.018);
  --muted-foreground: oklch(0.486 0.013 28.094);
  --popover: oklch(0.992 0 161.565);
  --popover-foreground: oklch(0.143 0.02 205.215);
  --card: oklch(0.992 0 161.565);
  --card-foreground: oklch(0.143 0.02 205.215);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.476 0.019 207.836);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.456 0.021 28.237);
  --secondary-foreground: oklch(0.961 0.002 27.946);
  --accent: oklch(0.456 0.021 28.237);
  --accent-foreground: oklch(0.961 0.002 27.946);
  --destructive: oklch(0.461 0.165 33.558);
  --destructive-foreground: oklch(0.927 0.036 34.313);
  --ring: oklch(0.476 0.019 207.836);
  --chart-1: oklch(0.476 0.019 207.836);
  --chart-2: oklch(0.456 0.021 28.237);
  --chart-3: oklch(0.456 0.021 28.237);
  --chart-4: oklch(0.483 0.022 28.241);
  --chart-5: oklch(0.48 0.025 207.847);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.979 0.004 207.914);
  --muted: oklch(0.251 0.02 28.542);
  --muted-foreground: oklch(0.694 0.012 28.028);
  --popover: oklch(0.092 0 180);
  --popover-foreground: oklch(0.986 0.003 207.921);
  --card: oklch(0.092 0 180);
  --card-foreground: oklch(0.986 0.003 207.921);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.476 0.019 207.836);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.456 0.021 28.237);
  --secondary-foreground: oklch(0.961 0.002 27.946);
  --accent: oklch(0.456 0.021 28.237);
  --accent-foreground: oklch(0.961 0.002 27.946);
  --destructive: oklch(0.683 0.199 35.049);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.476 0.019 207.836);
  --chart-1: oklch(0.476 0.019 207.836);
  --chart-2: oklch(0.456 0.021 28.237);
  --chart-3: oklch(0.456 0.021 28.237);
  --chart-4: oklch(0.483 0.022 28.241);
  --chart-5: oklch(0.48 0.025 207.847);
}