Ghost for shadcn/ui

Ghost is a shadcn/ui theme built around a vivid deep green primary color (#021d05) with muted light green accents (#c6dcc9). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid deep green primary (#021d05) on a neutral background (#010402).

Color palette

TokenLightDark
Background
#ffffffwhite
#010402black
Foreground
#050f06black
#f8fbf9mintcream
Card
#ffffffwhite
#010402black
Card foreground
#050f06black
#f8fbf9mintcream
Popover
#ffffffwhite
#010402black
Popover foreground
#050f06black
#f8fbf9mintcream
Primary
#021d05black
#021d05black
Primary foreground
#0dde29limegreen
#0dde29limegreen
Secondary
#e4ece5gainsboro
#131b14black
Secondary foreground
#425c46darkslategray
#a3bda7darkgray
Muted
#dbebddgainsboro
#142416black
Muted foreground
#4c574ddarkslategray
#a8b3a9darkgray
Accent
#c6dcc9lightgrey
#1f3222darkslategray
Accent foreground
#2b462edarkslategray
#b4d0b7silver
Destructive
#780d0dmaroon
#de1717crimson
Destructive foreground
#f8bebelightpink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#021d05black
#021d05black

Contrast

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

Light mode
Text on background19.49:1AAA
Text on card19.49:1AAA
Primary button9.74:1AAA
Secondary button6.10:1AA
Muted text6.09:1AA
Accent7.18:1AAA
Destructive7.04:1AAA
Dark mode
Text on background19.79:1AAA
Text on card19.79:1AAA
Primary button9.74:1AAA
Secondary button8.72:1AAA
Muted text7.49:1AAA
Accent8.20:1AAA
Destructive4.96:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.156 0.026 148.266);
  --muted: oklch(0.924 0.025 149.348);
  --muted-foreground: oklch(0.445 0.021 149.068);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.156 0.026 148.266);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.156 0.026 148.266);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.202 0.057 146.265);
  --primary-foreground: oklch(0.781 0.255 143.442);
  --secondary: oklch(0.935 0.012 149.531);
  --secondary-foreground: oklch(0.446 0.047 148.285);
  --accent: oklch(0.873 0.035 149.175);
  --accent-foreground: oklch(0.364 0.052 147.72);
  --destructive: oklch(0.367 0.14 27.726);
  --destructive-foreground: oklch(0.855 0.067 18.547);
  --ring: oklch(0.202 0.057 146.265);
  --chart-1: oklch(0.202 0.057 146.265);
  --chart-2: oklch(0.935 0.012 149.531);
  --chart-3: oklch(0.873 0.035 149.175);
  --chart-4: oklch(0.957 0.008 149.585);
  --chart-5: oklch(0.203 0.059 146.192);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.096 0.013 148.798);
  --foreground: oklch(0.986 0.005 149.622);
  --muted: oklch(0.241 0.033 147.773);
  --muted-foreground: oklch(0.755 0.019 149.37);
  --popover: oklch(0.096 0.013 148.798);
  --popover-foreground: oklch(0.986 0.005 149.622);
  --card: oklch(0.096 0.013 148.798);
  --card-foreground: oklch(0.986 0.005 149.622);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.202 0.057 146.265);
  --primary-foreground: oklch(0.781 0.255 143.442);
  --secondary: oklch(0.211 0.017 148.66);
  --secondary-foreground: oklch(0.772 0.041 148.998);
  --accent: oklch(0.296 0.038 147.928);
  --accent-foreground: oklch(0.83 0.045 148.986);
  --destructive: oklch(0.572 0.225 28.315);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.202 0.057 146.265);
  --chart-1: oklch(0.202 0.057 146.265);
  --chart-2: oklch(0.211 0.017 148.66);
  --chart-3: oklch(0.296 0.038 147.928);
  --chart-4: oklch(0.246 0.021 148.553);
  --chart-5: oklch(0.203 0.059 146.192);
}