Miserly for shadcn/ui

Miserly is a shadcn/ui theme built around a vivid deep blue primary color (#003175) with vivid deep indigo accents (#0a0075). The light mode uses a neutral background (#f7f9fd). Dark mode keeps the vivid deep blue primary (#003175) on a neutral background (#030507).

Color palette

TokenLightDark
Background
#f7f9fdghostwhite
#030507black
Foreground
#000000black
#f9fafbghostwhite
Card
#f3f7fcaliceblue
#04070bblack
Card foreground
#000000black
#fcfcfdwhite
Popover
#f3f7fcaliceblue
#04070bblack
Popover foreground
#000000black
#fcfcfdwhite
Primary
#003175midnightblue
#003175midnightblue
Primary foreground
#a8ccfflightblue
#a8ccfflightblue
Secondary
#006c75teal
#006c75teal
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#dbe9eblavender
#142224black
Muted foreground
#4b6062dimgray
#9db2b4darkgray
Accent
#0a0075navy
#0a0075navy
Accent foreground
#b0a8fflightsteelblue
#b0a8fflightsteelblue
Destructive
#78290dsaddlebrown
#d94b17chocolate
Destructive foreground
#f8cebepeachpuff
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#003175midnightblue
#003175midnightblue

Contrast

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

Light mode
Text on background19.96:1AAA
Text on card19.45:1AAA
Primary button7.51:1AAA
Secondary button6.20:1AA
Muted text5.36:1AA
Accent7.78:1AAA
Destructive6.85:1AA
Dark mode
Text on background19.56:1AAA
Text on card19.67:1AAA
Primary button7.51:1AAA
Secondary button6.20:1AA
Muted text7.34:1AAA
Accent7.78:1AAA
Destructive4.23:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.982 0.006 256.675);
  --foreground: oklch(0 0 0);
  --muted: oklch(0.925 0.015 203.439);
  --muted-foreground: oklch(0.473 0.025 203.197);
  --popover: oklch(0.973 0.008 256.686);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(0.973 0.008 256.686);
  --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.331 0.127 258.814);
  --primary-foreground: oklch(0.838 0.081 256.84);
  --secondary: oklch(0.484 0.083 205.766);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.259 0.173 267.511);
  --accent-foreground: oklch(0.772 0.123 286.969);
  --destructive: oklch(0.396 0.117 38.455);
  --destructive-foreground: oklch(0.883 0.053 40.97);
  --ring: oklch(0.331 0.127 258.814);
  --chart-1: oklch(0.331 0.127 258.814);
  --chart-2: oklch(0.484 0.083 205.766);
  --chart-3: oklch(0.259 0.173 267.511);
  --chart-4: oklch(0.528 0.09 205.911);
  --chart-5: oklch(0.332 0.131 258.838);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.111 0.011 250.044);
  --foreground: oklch(0.984 0.002 256.662);
  --muted: oklch(0.241 0.019 203.123);
  --muted-foreground: oklch(0.747 0.023 203.327);
  --popover: oklch(0.127 0.012 250.241);
  --popover-foreground: oklch(0.992 0.001 256.657);
  --card: oklch(0.127 0.012 250.241);
  --card-foreground: oklch(0.992 0.001 256.657);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.331 0.127 258.814);
  --primary-foreground: oklch(0.838 0.081 256.84);
  --secondary: oklch(0.484 0.083 205.766);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.259 0.173 267.511);
  --accent-foreground: oklch(0.772 0.123 286.969);
  --destructive: oklch(0.603 0.187 37.733);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.331 0.127 258.814);
  --chart-1: oklch(0.331 0.127 258.814);
  --chart-2: oklch(0.484 0.083 205.766);
  --chart-3: oklch(0.259 0.173 267.511);
  --chart-4: oklch(0.528 0.09 205.911);
  --chart-5: oklch(0.332 0.131 258.838);
}