Understated for shadcn/ui

Understated is a shadcn/ui theme built around a red primary color (#da6270) with near-white accents (#ebeaea). The light mode uses a neutral background (#fefbfb). Dark mode keeps the red primary (#da6270) on a red-tinted background (#0a0506).

Color palette

TokenLightDark
Background
#fefbfbsnow
#0a0506black
Foreground
#0c0404black
#fdfcfcsnow
Card
#fefbfbsnow
#0a0506black
Card foreground
#0c0404black
#fdfcfcsnow
Popover
#fefbfbsnow
#0a0506black
Popover foreground
#0c0404black
#fdfcfcsnow
Primary
#da6270indianred
#da6270indianred
Primary foreground
#000000black
#000000black
Secondary
#ebeaealinen
#312b2cdarkslategray
Secondary foreground
#544f50darkslategray
#cac4c4silver
Muted
#e8c9cdthistle
#36171bblack
Muted foreground
#6d5558dimgray
#aa9295rosybrown
Accent
#ebeaealinen
#312b2cdarkslategray
Accent foreground
#544f50darkslategray
#cac4c4silver
Destructive
#7d2703saddlebrown
#f54d05orangered
Destructive foreground
#fdcab4peachpuff
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#da6270indianred
#da6270indianred

Contrast

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

Light mode
Text on background19.72:1AAA
Text on card19.72:1AAA
Primary button5.96:1AA
Secondary button6.70:1AA
Muted text4.43:1AA Large
Accent6.70:1AA
Destructive6.59:1AA
Dark mode
Text on background19.75:1AAA
Text on card19.75:1AAA
Primary button5.96:1AA
Secondary button8.06:1AAA
Muted text5.61:1AA
Accent8.06:1AAA
Destructive3.53:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.99 0.003 8.982);
  --foreground: oklch(0.12 0.02 10.163);
  --muted: oklch(0.864 0.035 9.859);
  --muted-foreground: oklch(0.475 0.031 10.455);
  --popover: oklch(0.99 0.003 8.982);
  --popover-foreground: oklch(0.12 0.02 10.163);
  --card: oklch(0.99 0.003 8.982);
  --card-foreground: oklch(0.12 0.02 10.163);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.647 0.151 15.14);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.938 0.001 8.944);
  --secondary-foreground: oklch(0.433 0.007 9.266);
  --accent: oklch(0.938 0.001 8.944);
  --accent-foreground: oklch(0.433 0.007 9.266);
  --destructive: oklch(0.401 0.126 39.179);
  --destructive-foreground: oklch(0.879 0.066 44.375);
  --ring: oklch(0.647 0.151 15.14);
  --chart-1: oklch(0.647 0.151 15.14);
  --chart-2: oklch(0.938 0.001 8.944);
  --chart-3: oklch(0.938 0.001 8.944);
  --chart-4: oklch(0.961 0.001 8.93);
  --chart-5: oklch(0.647 0.158 15.521);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.125 0.011 9.486);
  --foreground: oklch(0.992 0.001 8.932);
  --muted: oklch(0.25 0.049 13.917);
  --muted-foreground: oklch(0.683 0.028 9.878);
  --popover: oklch(0.125 0.011 9.486);
  --popover-foreground: oklch(0.992 0.001 8.932);
  --card: oklch(0.125 0.011 9.486);
  --card-foreground: oklch(0.992 0.001 8.932);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.647 0.151 15.14);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.296 0.008 9.558);
  --secondary-foreground: oklch(0.825 0.008 9.128);
  --accent: oklch(0.296 0.008 9.558);
  --accent-foreground: oklch(0.825 0.008 9.128);
  --destructive: oklch(0.651 0.214 37.461);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.647 0.151 15.14);
  --chart-1: oklch(0.647 0.151 15.14);
  --chart-2: oklch(0.296 0.008 9.558);
  --chart-3: oklch(0.296 0.008 9.558);
  --chart-4: oklch(0.326 0.009 9.581);
  --chart-5: oklch(0.647 0.158 15.521);
}