Purple Noir Puffin for shadcn/ui

Purple Noir Puffin is a shadcn/ui theme built around a deep indigo primary color (#302c54) with deep green accents (#50542c). The light mode uses a neutral background (#fbfbfe). Dark mode keeps the deep indigo primary (#302c54) on a neutral background (#040307).

Color palette

TokenLightDark
Background
#fbfbfeghostwhite
#040307black
Foreground
#020104black
#fcfcfdwhite
Card
#f7f7fdghostwhite
#05050bblack
Card foreground
#000000black
#ffffffwhite
Popover
#f7f7fdghostwhite
#05050bblack
Popover foreground
#000000black
#ffffffwhite
Primary
#302c54darkslategray
#302c54darkslategray
Primary foreground
#cfcde5lightgrey
#cfcde5lightgrey
Secondary
#50542cdarkolivegreen
#50542cdarkolivegreen
Secondary foreground
#e2e5cdgainsboro
#e2e5cdgainsboro
Muted
#f4f5f0whitesmoke
#0f0f0ablack
Muted foreground
#494b3adarkslategray
#c4c5b4silver
Accent
#50542cdarkolivegreen
#50542cdarkolivegreen
Accent foreground
#e2e5cdgainsboro
#e2e5cdgainsboro
Destructive
#c32404firebrick
#eb2b05orangered
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e1e0e6gainsboro
#1e1e24black
Input
#e1e0e6gainsboro
#1e1e24black
Ring
#302c54darkslategray
#302c54darkslategray

Contrast

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

Light mode
Text on background20.14:1AAA
Text on card19.65:1AAA
Primary button8.38:1AAA
Secondary button6.21:1AA
Muted text8.13:1AAA
Accent6.21:1AA
Destructive5.88:1AA
Dark mode
Text on background20.05:1AAA
Text on card20.35:1AAA
Primary button8.38:1AAA
Secondary button6.21:1AA
Muted text10.97:1AAA
Accent6.21:1AA
Destructive4.30:1AA Large

CSS variables

Paste this into your globals.css to use Purple Noir Puffin in your shadcn/ui project.

:root {
  --radius: 0.5rem;
  --background: oklch(0.989 0.004 290.933);
  --foreground: oklch(0.078 0.015 288.746);
  --muted: oklch(0.967 0.006 111.132);
  --muted-foreground: oklch(0.406 0.028 112.277);
  --popover: oklch(0.978 0.009 290.849);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(0.978 0.009 290.849);
  --card-foreground: oklch(0 0 0);
  --border: oklch(0.909 0.008 290.856);
  --input: oklch(0.909 0.008 290.856);
  --primary: oklch(0.318 0.069 286.338);
  --primary-foreground: oklch(0.857 0.033 290.285);
  --secondary: oklch(0.43 0.059 113.58);
  --secondary-foreground: oklch(0.913 0.032 111.658);
  --accent: oklch(0.43 0.059 113.58);
  --accent-foreground: oklch(0.913 0.032 111.658);
  --destructive: oklch(0.528 0.197 32.106);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.318 0.069 286.338);
  --chart-1: oklch(0.318 0.069 286.338);
  --chart-2: oklch(0.43 0.059 113.58);
  --chart-3: oklch(0.43 0.059 113.58);
  --chart-4: oklch(0.465 0.065 113.618);
  --chart-5: oklch(0.314 0.076 285.72);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.103 0.014 289.411);
  --foreground: oklch(0.991 0.002 290.978);
  --muted: oklch(0.166 0.009 112.047);
  --muted-foreground: oklch(0.818 0.024 111.553);
  --popover: oklch(0.118 0.016 289.401);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.118 0.016 289.401);
  --card-foreground: oklch(1 0 180);
  --border: oklch(0.238 0.013 289.993);
  --input: oklch(0.238 0.013 289.993);
  --primary: oklch(0.318 0.069 286.338);
  --primary-foreground: oklch(0.857 0.033 290.285);
  --secondary: oklch(0.43 0.059 113.58);
  --secondary-foreground: oklch(0.913 0.032 111.658);
  --accent: oklch(0.43 0.059 113.58);
  --accent-foreground: oklch(0.913 0.032 111.658);
  --destructive: oklch(0.606 0.228 31.902);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.318 0.069 286.338);
  --chart-1: oklch(0.318 0.069 286.338);
  --chart-2: oklch(0.43 0.059 113.58);
  --chart-3: oklch(0.43 0.059 113.58);
  --chart-4: oklch(0.465 0.065 113.618);
  --chart-5: oklch(0.314 0.076 285.72);
}