Mandolin for shadcn/ui

Mandolin is a shadcn/ui theme built around a green primary color (#3cc350) with red accents (#c3503c). The light mode uses a neutral background (#f8fcf9). Dark mode keeps the green primary (#3cc350) on a neutral background (#010402).

Color palette

TokenLightDark
Background
#f8fcf9mintcream
#010402black
Foreground
#000000black
#f5faf6whitesmoke
Card
#f5faf5whitesmoke
#020803black
Card foreground
#000000black
#f8fbf9mintcream
Popover
#f5faf5whitesmoke
#020803black
Popover foreground
#000000black
#f8fbf9mintcream
Primary
#3cc350limegreen
#3cc350limegreen
Primary foreground
#0c2710black
#0c2710black
Secondary
#503cc3slateblue
#503cc3slateblue
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#e7e6eflavender
#111019black
Muted foreground
#4f4f4fdarkslategray
#b0b0b0darkgray
Accent
#c3503cindianred
#c3503cindianred
Accent foreground
#ffffffwhite
#ffffffwhite
Destructive
#aa2609firebrick
#f34720orangered
Destructive foreground
#feebe7linen
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#3cc350limegreen
#3cc350limegreen

Contrast

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

Light mode
Text on background20.24:1AAA
Text on card19.87:1AAA
Primary button6.94:1AA
Secondary button7.56:1AAA
Muted text6.62:1AA
Accent4.62:1AA
Destructive6.11:1AA
Dark mode
Text on background19.50:1AAA
Text on card19.40:1AAA
Primary button6.94:1AA
Secondary button7.56:1AAA
Muted text8.70:1AAA
Accent4.62:1AA
Destructive3.65:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.987 0.006 150.172);
  --foreground: oklch(0 0 0);
  --muted: oklch(0.929 0.012 293.061);
  --muted-foreground: oklch(0.428 0 180);
  --popover: oklch(0.98 0.008 150.134);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(0.98 0.008 150.134);
  --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.721 0.194 145.566);
  --primary-foreground: oklch(0.245 0.054 146.722);
  --secondary: oklch(0.466 0.2 282.219);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.579 0.152 32.023);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.483 0.171 33.113);
  --destructive-foreground: oklch(0.954 0.021 32.678);
  --ring: oklch(0.721 0.194 145.566);
  --chart-1: oklch(0.721 0.194 145.566);
  --chart-2: oklch(0.466 0.2 282.219);
  --chart-3: oklch(0.579 0.152 32.023);
  --chart-4: oklch(0.495 0.189 283.958);
  --chart-5: oklch(0.73 0.202 145.359);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.097 0.017 149.166);
  --foreground: oklch(0.979 0.007 150.156);
  --muted: oklch(0.179 0.018 291.295);
  --muted-foreground: oklch(0.757 0 180);
  --popover: oklch(0.123 0.021 149.166);
  --popover-foreground: oklch(0.986 0.005 150.187);
  --card: oklch(0.123 0.021 149.166);
  --card-foreground: oklch(0.986 0.005 150.187);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.721 0.194 145.566);
  --primary-foreground: oklch(0.245 0.054 146.722);
  --secondary: oklch(0.466 0.2 282.219);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.579 0.152 32.023);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.643 0.215 33.688);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.721 0.194 145.566);
  --chart-1: oklch(0.721 0.194 145.566);
  --chart-2: oklch(0.466 0.2 282.219);
  --chart-3: oklch(0.579 0.152 32.023);
  --chart-4: oklch(0.495 0.189 283.958);
  --chart-5: oklch(0.73 0.202 145.359);
}