Kid for shadcn/ui

Kid is a shadcn/ui theme built around a near-black primary color (#040406) with neutral gray accents (#dadadd). The light mode uses a neutral background (#ffffff). Dark mode keeps the near-black primary (#040406) on a neutral background (#020204).

Color palette

TokenLightDark
Background
#ffffffwhite
#020204black
Foreground
#030412black
#f6f6f9whitesmoke
Card
#fcfcfcsnow
#030307black
Card foreground
#02030dblack
#f9f9fbghostwhite
Popover
#fcfcfcsnow
#030307black
Popover foreground
#02030dblack
#f9f9fbghostwhite
Primary
#040406black
#040406black
Primary foreground
#8f91aelightslategray
#8f91aelightslategray
Secondary
#dadaddgainsboro
#202022black
Secondary foreground
#3f4046darkslategray
#b7b8bdsilver
Muted
#f0f1f4whitesmoke
#0b0b0fblack
Muted foreground
#545454dimgray
#abababdarkgray
Accent
#dadaddgainsboro
#202022black
Accent foreground
#3f4046darkslategray
#b7b8bdsilver
Destructive
#910808darkred
#e40c0cred
Destructive foreground
#fccfcfpink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#040406black
#040406black

Contrast

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

Light mode
Text on background20.38:1AAA
Text on card20.11:1AAA
Primary button6.64:1AA
Secondary button7.38:1AAA
Muted text6.68:1AA
Accent7.38:1AAA
Destructive6.66:1AA
Dark mode
Text on background19.25:1AAA
Text on card19.53:1AAA
Primary button6.64:1AA
Secondary button8.21:1AAA
Muted text8.55:1AAA
Accent8.21:1AAA
Destructive4.83:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.115 0.035 272.931);
  --muted: oklch(0.958 0.005 282.125);
  --muted-foreground: oklch(0.446 0 180);
  --popover: oklch(0.992 0 161.565);
  --popover-foreground: oklch(0.104 0.03 272.902);
  --card: oklch(0.992 0 161.565);
  --card-foreground: oklch(0.104 0.03 272.902);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.111 0.005 280.998);
  --primary-foreground: oklch(0.665 0.042 281.092);
  --secondary: oklch(0.889 0.004 282.129);
  --secondary-foreground: oklch(0.371 0.01 281.738);
  --accent: oklch(0.889 0.004 282.129);
  --accent-foreground: oklch(0.371 0.01 281.738);
  --destructive: oklch(0.417 0.166 28.594);
  --destructive-foreground: oklch(0.893 0.052 18.17);
  --ring: oklch(0.111 0.005 280.998);
  --chart-1: oklch(0.111 0.005 280.998);
  --chart-2: oklch(0.889 0.004 282.129);
  --chart-3: oklch(0.889 0.004 282.129);
  --chart-4: oklch(0.913 0.003 282.149);
  --chart-5: oklch(0.11 0.006 280.743);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.083 0.01 278.848);
  --foreground: oklch(0.974 0.004 282.145);
  --muted: oklch(0.151 0.008 281.286);
  --muted-foreground: oklch(0.741 0 171.254);
  --popover: oklch(0.104 0.012 278.848);
  --popover-foreground: oklch(0.983 0.003 282.168);
  --card: oklch(0.104 0.012 278.848);
  --card-foreground: oklch(0.983 0.003 282.168);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.111 0.005 280.998);
  --primary-foreground: oklch(0.665 0.042 281.092);
  --secondary: oklch(0.244 0.005 281.896);
  --secondary-foreground: oklch(0.783 0.007 282.061);
  --accent: oklch(0.244 0.005 281.896);
  --accent-foreground: oklch(0.783 0.007 282.061);
  --destructive: oklch(0.579 0.234 28.854);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.111 0.005 280.998);
  --chart-1: oklch(0.111 0.005 280.998);
  --chart-2: oklch(0.244 0.005 281.896);
  --chart-3: oklch(0.244 0.005 281.896);
  --chart-4: oklch(0.275 0.005 281.876);
  --chart-5: oklch(0.11 0.006 280.743);
}