Glittering for shadcn/ui

Glittering is a shadcn/ui theme built around a neutral gray primary color (#918583) with neutral gray accents (#cfcac9). The light mode uses a neutral background (#fcf9f8). Dark mode keeps the neutral gray primary (#918583) on a red-tinted background (#0c0403).

Color palette

TokenLightDark
Background
#fcf9f8snow
#0c0403black
Foreground
#0c0503black
#fbf9f9snow
Card
#fcf9f8snow
#0c0403black
Card foreground
#0c0503black
#fbf9f9snow
Popover
#fcf9f8snow
#0c0403black
Popover foreground
#0c0503black
#fbf9f9snow
Primary
#918583gray
#918583gray
Primary foreground
#000000black
#000000black
Secondary
#cfcac9lightgrey
#37302fdarkslategray
Secondary foreground
#363130darkslategray
#d0c9c8lightgrey
Muted
#f7efedlinen
#120908black
Muted foreground
#4e3e3bdarkslategray
#c4b3b1silver
Accent
#cfcac9lightgrey
#37302fdarkslategray
Accent foreground
#363130darkslategray
#d0c9c8lightgrey
Destructive
#b93e0efirebrick
#ef5e25chocolate
Destructive foreground
#ffffffwhite
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#918583gray
#918583gray

Contrast

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

Light mode
Text on background19.24:1AAA
Text on card19.24:1AAA
Primary button5.86:1AA
Secondary button7.89:1AAA
Muted text8.91:1AAA
Accent7.89:1AAA
Destructive5.57:1AA
Dark mode
Text on background19.31:1AAA
Text on card19.31:1AAA
Primary button5.86:1AA
Secondary button7.90:1AAA
Muted text9.75:1AAA
Accent7.90:1AAA
Destructive6.28:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.983 0.004 29.48);
  --foreground: oklch(0.125 0.017 35.229);
  --muted: oklch(0.958 0.009 29.501);
  --muted-foreground: oklch(0.381 0.024 29.816);
  --popover: oklch(0.983 0.004 29.48);
  --popover-foreground: oklch(0.125 0.017 35.229);
  --card: oklch(0.983 0.004 29.48);
  --card-foreground: oklch(0.125 0.017 35.229);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.626 0.015 29.566);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.842 0.006 29.492);
  --secondary-foreground: oklch(0.318 0.008 29.567);
  --accent: oklch(0.842 0.006 29.492);
  --accent-foreground: oklch(0.318 0.008 29.567);
  --destructive: oklch(0.535 0.167 38.312);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.626 0.015 29.566);
  --chart-1: oklch(0.626 0.015 29.566);
  --chart-2: oklch(0.842 0.006 29.492);
  --chart-3: oklch(0.842 0.006 29.492);
  --chart-4: oklch(0.867 0.005 29.487);
  --chart-5: oklch(0.623 0.023 29.635);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.124 0.018 35.802);
  --foreground: oklch(0.984 0.002 29.475);
  --muted: oklch(0.153 0.015 31.118);
  --muted-foreground: oklch(0.781 0.019 29.57);
  --popover: oklch(0.124 0.018 35.802);
  --popover-foreground: oklch(0.984 0.002 29.475);
  --card: oklch(0.124 0.018 35.802);
  --card-foreground: oklch(0.984 0.002 29.475);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.626 0.015 29.566);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.317 0.01 29.613);
  --secondary-foreground: oklch(0.842 0.008 29.501);
  --accent: oklch(0.317 0.01 29.613);
  --accent-foreground: oklch(0.842 0.008 29.501);
  --destructive: oklch(0.662 0.19 39.591);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.626 0.015 29.566);
  --chart-1: oklch(0.626 0.015 29.566);
  --chart-2: oklch(0.317 0.01 29.613);
  --chart-3: oklch(0.317 0.01 29.613);
  --chart-4: oklch(0.346 0.012 29.619);
  --chart-5: oklch(0.623 0.023 29.635);
}