Pathology for shadcn/ui

Pathology is a shadcn/ui theme built around a muted yellow primary color (#b9b5ac) with muted light yellow accents (#d1cec7). The light mode uses a neutral background (#fdfbf6). Dark mode keeps the muted yellow primary (#b9b5ac) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#fdfbf6snow
#000000black
Foreground
#0e0a02black
#ffffffwhite
Card
#fcfaf2floralwhite
#030303black
Card foreground
#090701black
#ffffffwhite
Popover
#fcfaf2floralwhite
#030303black
Popover foreground
#090701black
#ffffffwhite
Primary
#b9b5acdarkgray
#b9b5acdarkgray
Primary foreground
#1c1a17black
#1c1a17black
Secondary
#d1cec7lightgrey
#23221fblack
Secondary foreground
#38352edarkslategray
#bebcb6silver
Muted
#dfddd8gainsboro
#272520black
Muted foreground
#736c59dimgray
#a69f8crosybrown
Accent
#d1cec7lightgrey
#23221fblack
Accent foreground
#38352edarkslategray
#bebcb6silver
Destructive
#b62411firebrick
#db2c14firebrick
Destructive foreground
#fffbfasnow
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#b9b5acdarkgray
#b9b5acdarkgray

Contrast

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

Light mode
Text on background19.16:1AAA
Text on card19.24:1AAA
Primary button8.52:1AAA
Secondary button7.79:1AAA
Muted text3.83:1AA Large
Accent7.79:1AAA
Destructive6.28:1AA
Dark mode
Text on background21.00:1AAA
Text on card20.67:1AAA
Primary button8.52:1AAA
Secondary button8.37:1AAA
Muted text5.79:1AA
Accent8.37:1AAA
Destructive4.78:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.989 0.007 88.835);
  --foreground: oklch(0.146 0.023 94.466);
  --muted: oklch(0.897 0.007 88.838);
  --muted-foreground: oklch(0.532 0.03 89.014);
  --popover: oklch(0.984 0.01 88.856);
  --popover-foreground: oklch(0.128 0.02 95.797);
  --card: oklch(0.984 0.01 88.856);
  --card-foreground: oklch(0.128 0.02 95.797);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.775 0.014 88.902);
  --primary-foreground: oklch(0.22 0.007 88.952);
  --secondary: oklch(0.852 0.01 88.867);
  --secondary-foreground: oklch(0.33 0.013 88.986);
  --accent: oklch(0.852 0.01 88.867);
  --accent-foreground: oklch(0.33 0.013 88.986);
  --destructive: oklch(0.504 0.184 31.023);
  --destructive-foreground: oklch(0.99 0.004 26.467);
  --ring: oklch(0.775 0.014 88.902);
  --chart-1: oklch(0.775 0.014 88.902);
  --chart-2: oklch(0.852 0.01 88.867);
  --chart-3: oklch(0.852 0.01 88.867);
  --chart-4: oklch(0.875 0.009 88.855);
  --chart-5: oklch(0.778 0.019 88.931);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.265 0.009 88.965);
  --muted-foreground: oklch(0.703 0.028 88.987);
  --popover: oklch(0.092 0 180);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.092 0 180);
  --card-foreground: oklch(1 0 180);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.775 0.014 88.902);
  --primary-foreground: oklch(0.22 0.007 88.952);
  --secondary: oklch(0.252 0.006 88.918);
  --secondary-foreground: oklch(0.795 0.009 88.859);
  --accent: oklch(0.252 0.006 88.918);
  --accent-foreground: oklch(0.795 0.009 88.859);
  --destructive: oklch(0.578 0.213 31.001);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.775 0.014 88.902);
  --chart-1: oklch(0.775 0.014 88.902);
  --chart-2: oklch(0.252 0.006 88.918);
  --chart-3: oklch(0.252 0.006 88.918);
  --chart-4: oklch(0.285 0.007 88.924);
  --chart-5: oklch(0.778 0.019 88.931);
}