Hard-to-find for shadcn/ui

Hard-to-find is a shadcn/ui theme built around a neutral gray primary color (#7d787a) with neutral gray accents (#787a7d). The light mode uses a neutral background (#fcf7fa). Dark mode keeps the neutral gray primary (#7d787a) on a pink-tinted background (#10040a).

Color palette

TokenLightDark
Background
#fcf7fasnow
#10040ablack
Foreground
#10050ablack
#ffffffwhite
Card
#fcf7fasnow
#10040ablack
Card foreground
#10050ablack
#ffffffwhite
Popover
#fcf7fasnow
#10040ablack
Popover foreground
#10050ablack
#ffffffwhite
Primary
#7d787agray
#7d787agray
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#7a7d78gray
#7a7d78gray
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#ebf2e3beige
#151c0dblack
Muted foreground
#454743darkslategray
#babcb8silver
Accent
#787a7dgray
#787a7dgray
Accent foreground
#ffffffwhite
#ffffffwhite
Destructive
#b80e05firebrick
#e51106red
Destructive foreground
#fff1f0seashell
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#7d787agray
#7d787agray

Contrast

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

Light mode
Text on background18.97:1AAA
Text on card18.97:1AAA
Primary button4.34:1AA Large
Secondary button4.17:1AA Large
Muted text8.19:1AAA
Accent4.28:1AA Large
Destructive6.15:1AA
Dark mode
Text on background20.09:1AAA
Text on card20.09:1AAA
Primary button4.34:1AA Large
Secondary button4.17:1AA Large
Muted text9.15:1AAA
Accent4.28:1AA Large
Destructive4.76:1AA

CSS variables

Paste this into your globals.css to use Hard-to-find in your shadcn/ui project.

:root {
  --radius: 0.5rem;
  --background: oklch(0.982 0.006 344.453);
  --foreground: oklch(0.136 0.026 346.232);
  --muted: oklch(0.951 0.02 128.041);
  --muted-foreground: oklch(0.394 0.007 128.008);
  --popover: oklch(0.982 0.006 344.453);
  --popover-foreground: oklch(0.136 0.026 346.232);
  --card: oklch(0.982 0.006 344.453);
  --card-foreground: oklch(0.136 0.026 346.232);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.578 0.007 344.597);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.586 0.008 127.947);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.58 0.005 246.061);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.496 0.198 29.59);
  --destructive-foreground: oklch(0.968 0.015 21.088);
  --ring: oklch(0.578 0.007 344.597);
  --chart-1: oklch(0.578 0.007 344.597);
  --chart-2: oklch(0.586 0.008 127.947);
  --chart-3: oklch(0.58 0.005 246.061);
  --chart-4: oklch(0.612 0.008 127.942);
  --chart-5: oklch(0.573 0.018 345.061);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.135 0.029 346.349);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.213 0.029 129.536);
  --muted-foreground: oklch(0.793 0.006 127.88);
  --popover: oklch(0.135 0.029 346.349);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.135 0.029 346.349);
  --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.578 0.007 344.597);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.586 0.008 127.947);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.58 0.005 246.061);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.582 0.234 29.542);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.578 0.007 344.597);
  --chart-1: oklch(0.578 0.007 344.597);
  --chart-2: oklch(0.586 0.008 127.947);
  --chart-3: oklch(0.58 0.005 246.061);
  --chart-4: oklch(0.612 0.008 127.942);
  --chart-5: oklch(0.573 0.018 345.061);
}