Prudent for shadcn/ui

Prudent is a shadcn/ui theme built around a blue primary color (#3243bd) with green accents (#43bd32). The light mode uses a neutral background (#ffffff). Dark mode keeps the blue primary (#3243bd) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#ffffffwhite
#000000black
Foreground
#05060fblack
#f6f6f9whitesmoke
Card
#fcfcfcsnow
#030303black
Card foreground
#04050cblack
#f9f9fbghostwhite
Popover
#fcfcfcsnow
#030303black
Popover foreground
#04050cblack
#f9f9fbghostwhite
Primary
#3243bdroyalblue
#3243bdroyalblue
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#bd3243brown
#bd3243brown
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#edd9dbgainsboro
#261214black
Muted foreground
#6b5759dimgray
#a89497rosybrown
Accent
#43bd32limegreen
#43bd32limegreen
Accent foreground
#0a1c07black
#0a1c07black
Destructive
#bc2d10firebrick
#ee583atomato
Destructive foreground
#ffffffwhite
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#3243bdroyalblue
#3243bdroyalblue

Contrast

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

Light mode
Text on background20.20:1AAA
Text on card19.90:1AAA
Primary button7.87:1AAA
Secondary button5.65:1AA
Muted text4.95:1AA
Accent7.26:1AAA
Destructive5.98:1AA
Dark mode
Text on background19.46:1AAA
Text on card19.66:1AAA
Primary button7.87:1AAA
Secondary button5.65:1AA
Muted text6.22:1AA
Accent7.26:1AAA
Destructive6.08:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.128 0.022 275.264);
  --muted: oklch(0.902 0.023 9.499);
  --muted-foreground: oklch(0.478 0.026 10.181);
  --popover: oklch(0.992 0 161.565);
  --popover-foreground: oklch(0.116 0.019 274.993);
  --card: oklch(0.992 0 161.565);
  --card-foreground: oklch(0.116 0.019 274.993);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.451 0.191 270.603);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.536 0.175 19.192);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.705 0.206 141.462);
  --accent-foreground: oklch(0.205 0.046 141.24);
  --destructive: oklch(0.522 0.183 32.74);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.451 0.191 270.603);
  --chart-1: oklch(0.451 0.191 270.603);
  --chart-2: oklch(0.536 0.175 19.192);
  --chart-3: oklch(0.705 0.206 141.462);
  --chart-4: oklch(0.56 0.184 19.272);
  --chart-5: oklch(0.448 0.2 269.951);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.974 0.004 280.27);
  --muted: oklch(0.212 0.034 12.849);
  --muted-foreground: oklch(0.686 0.023 9.71);
  --popover: oklch(0.092 0 180);
  --popover-foreground: oklch(0.983 0.003 280.29);
  --card: oklch(0.092 0 180);
  --card-foreground: oklch(0.983 0.003 280.29);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.451 0.191 270.603);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.536 0.175 19.192);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.705 0.206 141.462);
  --accent-foreground: oklch(0.205 0.046 141.24);
  --destructive: oklch(0.655 0.191 33.202);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.451 0.191 270.603);
  --chart-1: oklch(0.451 0.191 270.603);
  --chart-2: oklch(0.536 0.175 19.192);
  --chart-3: oklch(0.705 0.206 141.462);
  --chart-4: oklch(0.56 0.184 19.272);
  --chart-5: oklch(0.448 0.2 269.951);
}