Molding for shadcn/ui

Molding is a shadcn/ui theme built around a yellow primary color (#e4cb4e) with green accents (#b2e44e). The light mode uses a neutral background (#fdfcf7). Dark mode keeps the yellow primary (#e4cb4e) on a neutral background (#040301).

Color palette

TokenLightDark
Background
#fdfcf7snow
#040301black
Foreground
#040401black
#f9f9f5whitesmoke
Card
#fbfaf3floralwhite
#070703black
Card foreground
#000000black
#fbfbf8snow
Popover
#fdfcf7snow
#040301black
Popover foreground
#040401black
#f9f9f5whitesmoke
Primary
#e4cb4esandybrown
#e4cb4esandybrown
Primary foreground
#000000black
#000000black
Secondary
#e4804ecoral
#e4804ecoral
Secondary foreground
#000000black
#000000black
Muted
#e6dfdbgainsboro
#241d19black
Muted foreground
#625a55dimgray
#aaa19ddarkgray
Accent
#b2e44egreenyellow
#b2e44egreenyellow
Accent foreground
#000000black
#000000black
Destructive
#dd2108red
#f62509orangered
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#e4cb4esandybrown
#e4cb4esandybrown

Contrast

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

Light mode
Text on background19.92:1AAA
Text on card20.07:1AAA
Primary button12.99:1AAA
Secondary button7.50:1AAA
Muted text5.10:1AA
Accent14.15:1AAA
Destructive4.87:1AA
Dark mode
Text on background19.51:1AAA
Text on card19.48:1AAA
Primary button12.99:1AAA
Secondary button7.50:1AAA
Muted text6.56:1AA
Accent14.15:1AAA
Destructive4.05:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.989 0.006 97.338);
  --foreground: oklch(0.104 0.017 102.113);
  --muted: oklch(0.907 0.009 48.624);
  --muted-foreground: oklch(0.473 0.013 48.429);
  --popover: oklch(0.989 0.006 97.338);
  --popover-foreground: oklch(0.104 0.017 102.113);
  --card: oklch(0.984 0.009 97.377);
  --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.842 0.145 97.836);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.701 0.14 46.074);
  --secondary-foreground: oklch(0 0 0);
  --accent: oklch(0.857 0.184 125.952);
  --accent-foreground: oklch(0 0 0);
  --destructive: oklch(0.575 0.221 30.744);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.842 0.145 97.836);
  --chart-1: oklch(0.842 0.145 97.836);
  --chart-2: oklch(0.701 0.14 46.074);
  --chart-3: oklch(0.857 0.184 125.952);
  --chart-4: oklch(0.721 0.13 46.547);
  --chart-5: oklch(0.848 0.149 97.747);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.099 0.01 100.497);
  --foreground: oklch(0.981 0.005 97.325);
  --muted: oklch(0.237 0.013 48.131);
  --muted-foreground: oklch(0.715 0.012 48.554);
  --popover: oklch(0.099 0.01 100.497);
  --popover-foreground: oklch(0.981 0.005 97.325);
  --card: oklch(0.125 0.013 100.497);
  --card-foreground: oklch(0.987 0.003 97.303);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.842 0.145 97.836);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.701 0.14 46.074);
  --secondary-foreground: oklch(0 0 0);
  --accent: oklch(0.857 0.184 125.952);
  --accent-foreground: oklch(0 0 0);
  --destructive: oklch(0.622 0.24 30.697);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.842 0.145 97.836);
  --chart-1: oklch(0.842 0.145 97.836);
  --chart-2: oklch(0.701 0.14 46.074);
  --chart-3: oklch(0.857 0.184 125.952);
  --chart-4: oklch(0.721 0.13 46.547);
  --chart-5: oklch(0.848 0.149 97.747);
}