Valid for shadcn/ui

Valid is a shadcn/ui theme built around a deep green primary color (#101504) with muted light green accents (#ced6bd). The light mode uses a neutral background (#ffffff). Dark mode keeps the deep green primary (#101504) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#ffffffwhite
#000000black
Foreground
#0c1005black
#ffffffwhite
Card
#fcfcfcsnow
#030303black
Card foreground
#090c04black
#ffffffwhite
Popover
#fcfcfcsnow
#030303black
Popover foreground
#090c04black
#ffffffwhite
Primary
#101504black
#101504black
Primary foreground
#8ebd28yellowgreen
#8ebd28yellowgreen
Secondary
#dbe0d2gainsboro
#181915black
Secondary foreground
#444b34darkslategray
#b2b5aadarkgray
Muted
#e1e6d5gainsboro
#242a19black
Muted foreground
#484847darkslategray
#b8b8b7silver
Accent
#ced6bdlightgrey
#282c21darkslategray
Accent foreground
#353c25darkslategray
#c3c8b6silver
Destructive
#963c08saddlebrown
#f47125chocolate
Destructive foreground
#ffffffwhite
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#101504black
#101504black

Contrast

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

Light mode
Text on background19.23:1AAA
Text on card19.27:1AAA
Primary button8.36:1AAA
Secondary button6.76:1AA
Muted text7.21:1AAA
Accent7.67:1AAA
Destructive7.11:1AAA
Dark mode
Text on background21.00:1AAA
Text on card20.67:1AAA
Primary button8.36:1AAA
Secondary button8.51:1AAA
Muted text7.46:1AAA
Accent8.35:1AAA
Destructive7.20:1AAA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.163 0.023 122.122);
  --muted: oklch(0.917 0.024 121.195);
  --muted-foreground: oklch(0.401 0.002 120.867);
  --popover: oklch(0.992 0 161.565);
  --popover-foreground: oklch(0.146 0.02 120.782);
  --card: oklch(0.992 0 161.565);
  --card-foreground: oklch(0.146 0.02 120.782);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.185 0.033 123.265);
  --primary-foreground: oklch(0.739 0.176 126.388);
  --secondary: oklch(0.898 0.019 121.118);
  --secondary-foreground: oklch(0.4 0.038 122.388);
  --accent: oklch(0.864 0.036 121.456);
  --accent-foreground: oklch(0.343 0.04 122.775);
  --destructive: oklch(0.474 0.134 43.903);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.185 0.033 123.265);
  --chart-1: oklch(0.185 0.033 123.265);
  --chart-2: oklch(0.898 0.019 121.118);
  --chart-3: oklch(0.864 0.036 121.456);
  --chart-4: oklch(0.919 0.015 121.04);
  --chart-5: oklch(0.186 0.035 123.332);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.273 0.031 122.741);
  --muted-foreground: oklch(0.783 0.002 120.811);
  --popover: oklch(0.092 0 180);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.092 0 180);
  --card-foreground: oklch(1 0 180);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.185 0.033 123.265);
  --primary-foreground: oklch(0.739 0.176 126.388);
  --secondary: oklch(0.209 0.006 121.274);
  --secondary-foreground: oklch(0.769 0.016 121.11);
  --accent: oklch(0.284 0.02 121.92);
  --accent-foreground: oklch(0.824 0.025 121.274);
  --destructive: oklch(0.694 0.18 45.829);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.185 0.033 123.265);
  --chart-1: oklch(0.185 0.033 123.265);
  --chart-2: oklch(0.209 0.006 121.274);
  --chart-3: oklch(0.284 0.02 121.92);
  --chart-4: oklch(0.244 0.008 121.325);
  --chart-5: oklch(0.186 0.035 123.332);
}