Dark Pastel for shadcn/ui

Dark Pastel is a shadcn/ui theme built around a muted blue primary color (#63718c) with muted light blue accents (#b3bdd0). The light mode uses a neutral background (#ffffff). Dark mode keeps the muted blue primary (#63718c) on a neutral background (#020203).

Color palette

TokenLightDark
Background
#ffffffwhite
#020203black
Foreground
#040810black
#ffffffwhite
Card
#fcfcfcsnow
#040507black
Card foreground
#03060cblack
#ffffffwhite
Popover
#fcfcfcsnow
#040507black
Popover foreground
#03060cblack
#ffffffwhite
Primary
#63718cslategray
#63718cslategray
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#d3d7degainsboro
#272d3adarkslategray
Secondary foreground
#373d49darkslategray
#bfc6d4lightsteelblue
Muted
#ebeef4lavender
#0b0e14black
Muted foreground
#373d49darkslategray
#b6bcc8silver
Accent
#b3bdd0lightsteelblue
#35435fdarkslategray
Accent foreground
#1f2633darkslategray
#dbe0ebgainsboro
Destructive
#79160bmaroon
#e52a15orangered
Destructive foreground
#f9c4bepink
#ffffffwhite
Border
#f0f2f4whitesmoke
#1a1d23black
Input
#f0f2f4whitesmoke
#1a1d23black
Ring
#63718cslategray
#63718cslategray

Contrast

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

Light mode
Text on background20.05:1AAA
Text on card19.84:1AAA
Primary button4.90:1AA
Secondary button7.55:1AAA
Muted text9.38:1AAA
Accent8.02:1AAA
Destructive7.04:1AAA
Dark mode
Text on background20.71:1AAA
Text on card20.44:1AAA
Primary button4.90:1AA
Secondary button8.02:1AAA
Muted text10.15:1AAA
Accent7.51:1AAA
Destructive4.50:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.135 0.02 258.48);
  --muted: oklch(0.949 0.009 264.519);
  --muted-foreground: oklch(0.358 0.022 264.243);
  --popover: oklch(0.992 0 161.565);
  --popover-foreground: oklch(0.122 0.017 256.598);
  --card: oklch(0.992 0 161.565);
  --card-foreground: oklch(0.122 0.017 256.598);
  --border: oklch(0.96 0.004 264.539);
  --input: oklch(0.96 0.004 264.539);
  --primary: oklch(0.548 0.046 264.092);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.878 0.011 264.511);
  --secondary-foreground: oklch(0.358 0.022 264.243);
  --accent: oklch(0.797 0.03 264.392);
  --accent-foreground: oklch(0.266 0.026 263.974);
  --destructive: oklch(0.377 0.135 30.473);
  --destructive-foreground: oklch(0.865 0.062 25.735);
  --ring: oklch(0.548 0.046 264.092);
  --chart-1: oklch(0.548 0.046 264.092);
  --chart-2: oklch(0.878 0.011 264.511);
  --chart-3: oklch(0.797 0.03 264.392);
  --chart-4: oklch(0.903 0.008 264.521);
  --chart-5: oklch(0.544 0.054 263.972);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.088 0.006 260.472);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.162 0.014 264.05);
  --muted-foreground: oklch(0.795 0.018 264.466);
  --popover: oklch(0.111 0.008 260.472);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.111 0.008 260.472);
  --card-foreground: oklch(1 0 180);
  --border: oklch(0.231 0.013 264.286);
  --input: oklch(0.231 0.013 264.286);
  --primary: oklch(0.548 0.046 264.092);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.298 0.025 264.079);
  --secondary-foreground: oklch(0.825 0.021 264.45);
  --accent: oklch(0.383 0.053 263.654);
  --accent-foreground: oklch(0.906 0.016 264.488);
  --destructive: oklch(0.594 0.222 30.517);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.548 0.046 264.092);
  --chart-1: oklch(0.548 0.046 264.092);
  --chart-2: oklch(0.298 0.025 264.079);
  --chart-3: oklch(0.383 0.053 263.654);
  --chart-4: oklch(0.326 0.029 264.058);
  --chart-5: oklch(0.544 0.054 263.972);
}