d for shadcn/ui

d is a shadcn/ui theme built around a yellow primary color (#6f7330) with muted yellow accents (#bdbeac). The light mode uses a neutral background (#fcfdf7). Dark mode keeps the yellow primary (#6f7330) on a yellow-tinted background (#0d0e07).

Color palette

TokenLightDark
Background
#fcfdf7snow
#0d0e07black
Foreground
#101103black
#fdfdfcwhite
Card
#fcfdf7snow
#0d0e07black
Card foreground
#101103black
#fdfdfcwhite
Popover
#fcfdf7snow
#0d0e07black
Popover foreground
#101103black
#fdfdfcwhite
Primary
#6f7330darkolivegreen
#6f7330darkolivegreen
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#cfcfc9lightgrey
#20201dblack
Secondary foreground
#363630darkslategray
#bbbbb4silver
Muted
#e0e0dcgainsboro
#23231fblack
Muted foreground
#4b4c3ddarkslategray
#c1c2b3silver
Accent
#bdbeacsilver
#3b3c2fdarkslategray
Accent foreground
#1f1f19black
#d4d4c9lightgrey
Destructive
#860e0edarkred
#ea3434crimson
Destructive foreground
#faccccpink
#ffffffwhite
Border
#e6e6e5gainsboro
#1a1a19black
Input
#e6e6e5gainsboro
#1a1a19black
Ring
#6f7330darkolivegreen
#6f7330darkolivegreen

Contrast

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

Light mode
Text on background18.59:1AAA
Text on card18.59:1AAA
Primary button5.03:1AA
Secondary button7.76:1AAA
Muted text6.59:1AA
Accent8.76:1AAA
Destructive7.00:1AAA
Dark mode
Text on background19.05:1AAA
Text on card19.05:1AAA
Primary button5.03:1AA
Secondary button8.45:1AAA
Muted text8.72:1AAA
Accent7.50:1AAA
Destructive4.17:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.991 0.008 109.619);
  --foreground: oklch(0.173 0.029 112.087);
  --muted: oklch(0.905 0.005 109.589);
  --muted-foreground: oklch(0.412 0.024 110.554);
  --popover: oklch(0.991 0.008 109.619);
  --popover-foreground: oklch(0.173 0.029 112.087);
  --card: oklch(0.991 0.008 109.619);
  --card-foreground: oklch(0.173 0.029 112.087);
  --border: oklch(0.925 0.002 109.52);
  --input: oklch(0.925 0.002 109.52);
  --primary: oklch(0.537 0.09 112.545);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.853 0.008 109.661);
  --secondary-foreground: oklch(0.331 0.011 110.064);
  --accent: oklch(0.795 0.024 110.046);
  --accent-foreground: oklch(0.238 0.012 110.434);
  --destructive: oklch(0.396 0.152 27.864);
  --destructive-foreground: oklch(0.885 0.052 18.171);
  --ring: oklch(0.537 0.09 112.545);
  --chart-1: oklch(0.537 0.09 112.545);
  --chart-2: oklch(0.853 0.008 109.661);
  --chart-3: oklch(0.795 0.024 110.046);
  --chart-4: oklch(0.875 0.007 109.628);
  --chart-5: oklch(0.545 0.095 112.685);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.16 0.015 111.05);
  --foreground: oklch(0.994 0.002 109.514);
  --muted: oklch(0.255 0.007 110.006);
  --muted-foreground: oklch(0.808 0.021 109.955);
  --popover: oklch(0.16 0.015 111.05);
  --popover-foreground: oklch(0.994 0.002 109.514);
  --card: oklch(0.16 0.015 111.05);
  --card-foreground: oklch(0.994 0.002 109.514);
  --border: oklch(0.218 0.003 109.728);
  --input: oklch(0.218 0.003 109.728);
  --primary: oklch(0.537 0.09 112.545);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.243 0.006 109.912);
  --secondary-foreground: oklch(0.79 0.01 109.712);
  --accent: oklch(0.351 0.021 110.593);
  --accent-foreground: oklch(0.867 0.016 109.815);
  --destructive: oklch(0.612 0.217 26.504);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.537 0.09 112.545);
  --chart-1: oklch(0.537 0.09 112.545);
  --chart-2: oklch(0.243 0.006 109.912);
  --chart-3: oklch(0.351 0.021 110.593);
  --chart-4: oklch(0.276 0.007 109.94);
  --chart-5: oklch(0.545 0.095 112.685);
}