Precious for shadcn/ui

Precious is a shadcn/ui theme built around a pink primary color (#c9318c) with red accents (#c93140). The light mode uses a neutral background (#ffffff). Dark mode keeps the pink primary (#c9318c) on a neutral background (#070306).

Color palette

TokenLightDark
Background
#ffffffwhite
#070306black
Foreground
#040103black
#fbf9fasnow
Card
#ffffffwhite
#070306black
Card foreground
#040103black
#fbf9fasnow
Popover
#ffffffwhite
#070306black
Popover foreground
#040103black
#fbf9fasnow
Primary
#c9318cmediumvioletred
#c9318cmediumvioletred
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#ba31c9darkorchid
#ba31c9darkorchid
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#e3d1e5gainsboro
#2c1a2edarkslategray
Muted foreground
#544e55darkslategray
#b0aab1darkgray
Accent
#c93140crimson
#c93140crimson
Accent foreground
#ffffffwhite
#ffffffwhite
Destructive
#8f3304saddlebrown
#f97634tomato
Destructive foreground
#fddac9bisque
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#c9318cmediumvioletred
#c9318cmediumvioletred

Contrast

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

Light mode
Text on background20.77:1AAA
Text on card20.77:1AAA
Primary button4.88:1AA
Secondary button4.81:1AA
Muted text5.60:1AA
Accent5.25:1AA
Destructive6.06:1AA
Dark mode
Text on background19.55:1AAA
Text on card19.55:1AAA
Primary button4.88:1AA
Secondary button4.81:1AA
Muted text7.15:1AAA
Accent5.25:1AA
Destructive7.64:1AAA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.085 0.016 340.366);
  --muted: oklch(0.882 0.033 322.776);
  --muted-foreground: oklch(0.433 0.013 322.746);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.085 0.016 340.366);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.085 0.016 340.366);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.576 0.205 348.864);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.584 0.238 323.51);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.554 0.188 20.856);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.449 0.135 41.058);
  --destructive-foreground: oklch(0.914 0.046 48.196);
  --ring: oklch(0.576 0.205 348.864);
  --chart-1: oklch(0.576 0.205 348.864);
  --chart-2: oklch(0.584 0.238 323.51);
  --chart-3: oklch(0.554 0.188 20.856);
  --chart-4: oklch(0.604 0.236 323.55);
  --chart-5: oklch(0.58 0.212 349.301);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.109 0.016 340.344);
  --foreground: oklch(0.984 0.003 340.302);
  --muted: oklch(0.249 0.045 323.27);
  --muted-foreground: oklch(0.745 0.011 322.688);
  --popover: oklch(0.109 0.016 340.344);
  --popover-foreground: oklch(0.984 0.003 340.302);
  --card: oklch(0.109 0.016 340.344);
  --card-foreground: oklch(0.984 0.003 340.302);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.576 0.205 348.864);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.584 0.238 323.51);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.554 0.188 20.856);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.71 0.178 44.281);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.576 0.205 348.864);
  --chart-1: oklch(0.576 0.205 348.864);
  --chart-2: oklch(0.584 0.238 323.51);
  --chart-3: oklch(0.554 0.188 20.856);
  --chart-4: oklch(0.604 0.236 323.55);
  --chart-5: oklch(0.58 0.212 349.301);
}