Fog for shadcn/ui

Fog is a shadcn/ui theme built around a vivid green primary color (#8aef93) with vivid purple accents (#ef8ae7). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid green primary (#8aef93) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#ffffffwhite
#000000black
Foreground
#000000black
#f4faf5whitesmoke
Card
#fcfcfcsnow
#030303black
Card foreground
#000000black
#f8fcf8mintcream
Popover
#ffffffwhite
#000000black
Popover foreground
#000000black
#f4faf5whitesmoke
Primary
#8aef93lightgreen
#8aef93lightgreen
Primary foreground
#093f0ddarkgreen
#093f0ddarkgreen
Secondary
#ef8ae7violet
#ef8ae7violet
Secondary foreground
#3f093amidnightblue
#3f093amidnightblue
Muted
#dfd2degainsboro
#2d202cdarkslategray
Muted foreground
#654e63dimgray
#b19aafdarkgray
Accent
#ef8ae7violet
#ef8ae7violet
Accent foreground
#3f093amidnightblue
#3f093amidnightblue
Destructive
#682003maroon
#f96f39tomato
Destructive foreground
#fcbba1lightpink
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#8aef93lightgreen
#8aef93lightgreen

Contrast

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

Light mode
Text on background21.00:1AAA
Text on card20.54:1AAA
Primary button8.59:1AAA
Secondary button7.22:1AAA
Muted text5.11:1AA
Accent7.22:1AAA
Destructive7.11:1AAA
Dark mode
Text on background19.83:1AAA
Text on card19.96:1AAA
Primary button8.59:1AAA
Secondary button7.22:1AAA
Muted text6.00:1AA
Accent7.22:1AAA
Destructive7.37:1AAA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0 0 0);
  --muted: oklch(0.879 0.021 328.316);
  --muted-foreground: oklch(0.454 0.045 329.048);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(0.992 0 161.565);
  --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.868 0.158 145.887);
  --primary-foreground: oklch(0.321 0.096 143.95);
  --secondary: oklch(0.772 0.167 330.12);
  --secondary-foreground: oklch(0.263 0.103 331.836);
  --accent: oklch(0.772 0.167 330.12);
  --accent-foreground: oklch(0.263 0.103 331.836);
  --destructive: oklch(0.353 0.109 38.936);
  --destructive-foreground: oklch(0.845 0.084 42.518);
  --ring: oklch(0.868 0.158 145.887);
  --chart-1: oklch(0.868 0.158 145.887);
  --chart-2: oklch(0.772 0.167 330.12);
  --chart-3: oklch(0.772 0.167 330.12);
  --chart-4: oklch(0.796 0.148 329.848);
  --chart-5: oklch(0.872 0.163 145.808);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.98 0.009 147.964);
  --muted: oklch(0.263 0.029 329.149);
  --muted-foreground: oklch(0.714 0.04 328.637);
  --popover: oklch(0 0 0);
  --popover-foreground: oklch(0.98 0.009 147.964);
  --card: oklch(0.092 0 180);
  --card-foreground: oklch(0.987 0.006 147.998);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.868 0.158 145.887);
  --primary-foreground: oklch(0.321 0.096 143.95);
  --secondary: oklch(0.772 0.167 330.12);
  --secondary-foreground: oklch(0.263 0.103 331.836);
  --accent: oklch(0.772 0.167 330.12);
  --accent-foreground: oklch(0.263 0.103 331.836);
  --destructive: oklch(0.702 0.182 40.651);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.868 0.158 145.887);
  --chart-1: oklch(0.868 0.158 145.887);
  --chart-2: oklch(0.772 0.167 330.12);
  --chart-3: oklch(0.772 0.167 330.12);
  --chart-4: oklch(0.796 0.148 329.848);
  --chart-5: oklch(0.872 0.163 145.808);
}