Prudent for shadcn/ui

Prudent is a shadcn/ui theme built around a light green primary color (#eceed3) with light green accents (#deeed3). The light mode uses a neutral background (#fdfefb). Dark mode keeps the light green primary (#eceed3) on a neutral background (#080802).

Color palette

TokenLightDark
Background
#fdfefbwhite
#080802black
Foreground
#000000black
#ffffffwhite
Card
#fdfefbwhite
#080802black
Card foreground
#000000black
#ffffffwhite
Popover
#fdfefbwhite
#080802black
Popover foreground
#000000black
#ffffffwhite
Primary
#eceed3beige
#eceed3beige
Primary foreground
#1c1e0bblack
#1c1e0bblack
Secondary
#eee3d3antiquewhite
#eee3d3antiquewhite
Secondary foreground
#684d27darkolivegreen
#684d27darkolivegreen
Muted
#e6e1dbgainsboro
#242019black
Muted foreground
#4d4a47darkslategray
#b8b6b2silver
Accent
#deeed3gainsboro
#deeed3gainsboro
Accent foreground
#131e0bblack
#131e0bblack
Destructive
#8f1e04darkred
#df2e07orangered
Destructive foreground
#fdd2c9peachpuff
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#eceed3beige
#eceed3beige

Contrast

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

Light mode
Text on background20.71:1AAA
Text on card20.71:1AAA
Primary button14.31:1AAA
Secondary button6.17:1AA
Muted text6.78:1AA
Accent14.19:1AAA
Destructive6.44:1AA
Dark mode
Text on background20.08:1AAA
Text on card20.08:1AAA
Primary button14.31:1AAA
Secondary button6.17:1AA
Muted text8.02:1AAA
Accent14.19:1AAA
Destructive4.63:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.995 0.003 110.303);
  --foreground: oklch(0 0 0);
  --muted: oklch(0.913 0.011 76.596);
  --muted-foreground: oklch(0.412 0.007 76.573);
  --popover: oklch(0.995 0.003 110.303);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(0.995 0.003 110.303);
  --card-foreground: oklch(0 0 0);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.941 0.036 110.961);
  --primary-foreground: oklch(0.226 0.032 112.857);
  --secondary: oklch(0.92 0.025 76.502);
  --secondary-foreground: oklch(0.439 0.064 74.019);
  --accent: oklch(0.93 0.04 132.086);
  --accent-foreground: oklch(0.217 0.037 133.414);
  --destructive: oklch(0.426 0.152 33.175);
  --destructive-foreground: oklch(0.899 0.051 32.785);
  --ring: oklch(0.941 0.036 110.961);
  --chart-1: oklch(0.941 0.036 110.961);
  --chart-2: oklch(0.92 0.025 76.502);
  --chart-3: oklch(0.93 0.04 132.086);
  --chart-4: oklch(0.94 0.019 76.55);
  --chart-5: oklch(0.943 0.039 111.005);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.131 0.018 111.757);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.245 0.014 76.211);
  --muted-foreground: oklch(0.776 0.006 76.619);
  --popover: oklch(0.131 0.018 111.757);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.131 0.018 111.757);
  --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.941 0.036 110.961);
  --primary-foreground: oklch(0.226 0.032 112.857);
  --secondary: oklch(0.92 0.025 76.502);
  --secondary-foreground: oklch(0.439 0.064 74.019);
  --accent: oklch(0.93 0.04 132.086);
  --accent-foreground: oklch(0.217 0.037 133.414);
  --destructive: oklch(0.586 0.215 32.596);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.941 0.036 110.961);
  --chart-1: oklch(0.941 0.036 110.961);
  --chart-2: oklch(0.92 0.025 76.502);
  --chart-3: oklch(0.93 0.04 132.086);
  --chart-4: oklch(0.94 0.019 76.55);
  --chart-5: oklch(0.943 0.039 111.005);
}