Perfect for shadcn/ui

Perfect is a shadcn/ui theme built around a red primary color (#ac482a) with indigo accents (#482aac). The light mode uses a neutral background (#fefcfb). Dark mode keeps the red primary (#ac482a) on a red-tinted background (#0b0604).

Color palette

TokenLightDark
Background
#fefcfbsnow
#0b0604black
Foreground
#120602black
#fdfcfcsnow
Card
#fefcfbsnow
#0b0604black
Card foreground
#120602black
#fdfcfcsnow
Popover
#fefcfbsnow
#0b0604black
Popover foreground
#120602black
#fdfcfcsnow
Primary
#ac482asienna
#ac482asienna
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#2aac48seagreen
#2aac48seagreen
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#cae8d1lightgrey
#17351edarkgreen
Muted foreground
#4f6354dimgray
#9cb0a1darkgray
Accent
#482aacrebeccapurple
#482aacrebeccapurple
Accent foreground
#ffffffwhite
#ffffffwhite
Destructive
#cc0a00firebrick
#ff3d33tomato
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#ac482asienna
#ac482asienna

Contrast

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

Light mode
Text on background19.45:1AAA
Text on card19.45:1AAA
Primary button5.62:1AA
Secondary button2.94:1Fail
Muted text4.90:1AA
Accent9.52:1AAA
Destructive5.81:1AA
Dark mode
Text on background19.69:1AAA
Text on card19.69:1AAA
Primary button5.62:1AA
Secondary button2.94:1Fail
Muted text5.82:1AA
Accent9.52:1AAA
Destructive3.51:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.991 0.003 37.728);
  --foreground: oklch(0.141 0.028 46.877);
  --muted: oklch(0.902 0.044 152.415);
  --muted-foreground: oklch(0.479 0.034 152.025);
  --popover: oklch(0.991 0.003 37.728);
  --popover-foreground: oklch(0.141 0.028 46.877);
  --card: oklch(0.991 0.003 37.728);
  --card-foreground: oklch(0.141 0.028 46.877);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.53 0.139 37.342);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.656 0.179 146.869);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.413 0.193 284.931);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.533 0.215 29.749);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.53 0.139 37.342);
  --chart-1: oklch(0.53 0.139 37.342);
  --chart-2: oklch(0.656 0.179 146.869);
  --chart-3: oklch(0.413 0.193 284.931);
  --chart-4: oklch(0.69 0.189 146.829);
  --chart-5: oklch(0.532 0.145 37.206);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.129 0.012 43.095);
  --foreground: oklch(0.992 0.001 37.74);
  --muted: oklch(0.299 0.055 149.638);
  --muted-foreground: oklch(0.736 0.031 152.543);
  --popover: oklch(0.129 0.012 43.095);
  --popover-foreground: oklch(0.992 0.001 37.74);
  --card: oklch(0.129 0.012 43.095);
  --card-foreground: oklch(0.992 0.001 37.74);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.53 0.139 37.342);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.656 0.179 146.869);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.413 0.193 284.931);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.656 0.23 28.425);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.53 0.139 37.342);
  --chart-1: oklch(0.53 0.139 37.342);
  --chart-2: oklch(0.656 0.179 146.869);
  --chart-3: oklch(0.413 0.193 284.931);
  --chart-4: oklch(0.69 0.189 146.829);
  --chart-5: oklch(0.532 0.145 37.206);
}