Crib for shadcn/ui

Crib is a shadcn/ui theme built around a muted orange primary color (#887a6d) with muted yellow accents (#88876d). The light mode uses a neutral background (#ffffff). Dark mode keeps the muted orange primary (#887a6d) on an orange-tinted background (#100a05).

Color palette

TokenLightDark
Background
#ffffffwhite
#100a05black
Foreground
#040201black
#faf7f5whitesmoke
Card
#ffffffwhite
#100a05black
Card foreground
#040201black
#faf7f5whitesmoke
Popover
#ffffffwhite
#100a05black
Popover foreground
#040201black
#faf7f5whitesmoke
Primary
#887a6dgray
#887a6dgray
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#886d6egray
#886d6egray
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#e1dadagainsboro
#251e1eblack
Muted foreground
#614c4ddimgray
#b39e9fdarkgray
Accent
#88876dgray
#88876dgray
Accent foreground
#000000black
#000000black
Destructive
#ca2e07firebrick
#e73508orangered
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#887a6dgray
#887a6dgray

Contrast

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

Light mode
Text on background20.70:1AAA
Text on card20.70:1AAA
Primary button4.17:1AA Large
Secondary button4.71:1AA
Muted text5.76:1AA
Accent5.72:1AA
Destructive5.38:1AA
Dark mode
Text on background18.46:1AAA
Text on card18.46:1AAA
Primary button4.17:1AA Large
Secondary button4.71:1AA
Muted text6.50:1AA
Accent5.72:1AA
Destructive4.26:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.094 0.014 75.407);
  --muted: oklch(0.895 0.008 14.958);
  --muted-foreground: oklch(0.439 0.028 16.039);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.094 0.014 75.407);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.094 0.014 75.407);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.587 0.026 63.5);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.561 0.034 15.976);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.617 0.038 105.82);
  --accent-foreground: oklch(0 0 0);
  --destructive: oklch(0.548 0.196 33.372);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.587 0.026 63.5);
  --chart-1: oklch(0.587 0.026 63.5);
  --chart-2: oklch(0.561 0.034 15.976);
  --chart-3: oklch(0.617 0.038 105.82);
  --chart-4: oklch(0.587 0.035 15.932);
  --chart-5: oklch(0.589 0.033 63.321);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.15 0.017 68.251);
  --foreground: oklch(0.978 0.005 64.031);
  --muted: oklch(0.242 0.011 15.696);
  --muted-foreground: oklch(0.717 0.025 15.442);
  --popover: oklch(0.15 0.017 68.251);
  --popover-foreground: oklch(0.978 0.005 64.031);
  --card: oklch(0.15 0.017 68.251);
  --card-foreground: oklch(0.978 0.005 64.031);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.587 0.026 63.5);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.561 0.034 15.976);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.617 0.038 105.82);
  --accent-foreground: oklch(0 0 0);
  --destructive: oklch(0.606 0.219 33.226);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.587 0.026 63.5);
  --chart-1: oklch(0.587 0.026 63.5);
  --chart-2: oklch(0.561 0.034 15.976);
  --chart-3: oklch(0.617 0.038 105.82);
  --chart-4: oklch(0.587 0.035 15.932);
  --chart-5: oklch(0.589 0.033 63.321);
}