Stars Theme for shadcn/ui

Stars Theme is a shadcn/ui theme built around a neutral gray primary color (#6d6a71) with neutral gray accents (#706a71). The light mode uses a neutral background (#fcfbfe). Dark mode keeps the neutral gray primary (#6d6a71) on a violet-tinted background (#09070d).

Color palette

TokenLightDark
Background
#fcfbfewhite
#09070dblack
Foreground
#000000black
#f7f5fawhitesmoke
Card
#fcfbfewhite
#09070dblack
Card foreground
#000000black
#f7f5fawhitesmoke
Popover
#fcfbfewhite
#09070dblack
Popover foreground
#000000black
#f7f5fawhitesmoke
Primary
#6d6a71dimgray
#6d6a71dimgray
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#6a6b71dimgray
#6a6b71dimgray
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#dcdee4gainsboro
#1b1c23black
Muted foreground
#5c5f6adimgray
#9597a3darkgray
Accent
#706a71dimgray
#706a71dimgray
Accent foreground
#ffffffwhite
#ffffffwhite
Destructive
#99220afirebrick
#e1320eorangered
Destructive foreground
#fddfd9mistyrose
#ffffffwhite
Border
#e5e4e7gainsboro
#19181bblack
Input
#e5e4e7gainsboro
#19181bblack
Ring
#6d6a71dimgray
#6d6a71dimgray

Contrast

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

Light mode
Text on background20.36:1AAA
Text on card20.36:1AAA
Primary button5.30:1AA
Secondary button5.28:1AA
Muted text4.72:1AA
Accent5.24:1AA
Destructive6.45:1AA
Dark mode
Text on background18.49:1AAA
Text on card18.49:1AAA
Primary button5.30:1AA
Secondary button5.28:1AA
Muted text5.86:1AA
Accent5.24:1AA
Destructive4.49:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.99 0.004 302.149);
  --foreground: oklch(0 0 0);
  --muted: oklch(0.9 0.009 278.168);
  --muted-foreground: oklch(0.486 0.019 277.721);
  --popover: oklch(0.99 0.004 302.149);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(0.99 0.004 302.149);
  --card-foreground: oklch(0 0 0);
  --border: oklch(0.921 0.003 302.165);
  --input: oklch(0.921 0.003 302.165);
  --primary: oklch(0.53 0.011 301.902);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.53 0.009 278.075);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.533 0.012 321.115);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.449 0.159 32.666);
  --destructive-foreground: oklch(0.926 0.034 31.157);
  --ring: oklch(0.53 0.011 301.902);
  --chart-1: oklch(0.53 0.011 301.902);
  --chart-2: oklch(0.53 0.009 278.075);
  --chart-3: oklch(0.533 0.012 321.115);
  --chart-4: oklch(0.556 0.009 278.073);
  --chart-5: oklch(0.523 0.021 301.58);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.136 0.015 301.734);
  --foreground: oklch(0.973 0.006 302.112);
  --muted: oklch(0.227 0.013 277.407);
  --muted-foreground: oklch(0.677 0.017 277.932);
  --popover: oklch(0.136 0.015 301.734);
  --popover-foreground: oklch(0.973 0.006 302.112);
  --card: oklch(0.136 0.015 301.734);
  --card-foreground: oklch(0.973 0.006 302.112);
  --border: oklch(0.213 0.004 301.912);
  --input: oklch(0.213 0.004 301.912);
  --primary: oklch(0.53 0.011 301.902);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.53 0.009 278.075);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.533 0.012 321.115);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.593 0.215 32.42);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.53 0.011 301.902);
  --chart-1: oklch(0.53 0.011 301.902);
  --chart-2: oklch(0.53 0.009 278.075);
  --chart-3: oklch(0.533 0.012 321.115);
  --chart-4: oklch(0.556 0.009 278.073);
  --chart-5: oklch(0.523 0.021 301.58);
}