Style for shadcn/ui

Style is a shadcn/ui theme built around a light yellow primary color (#e3dfca) with light blue accents (#cacee3). The light mode uses a neutral background (#ffffff). Dark mode keeps the light yellow primary (#e3dfca) on a yellow-tinted background (#0e0d07).

Color palette

TokenLightDark
Background
#ffffffwhite
#0e0d07black
Foreground
#171303black
#fdfdfcwhite
Card
#fcfcfcsnow
#111008black
Card foreground
#120f02black
#ffffffwhite
Popover
#ffffffwhite
#0e0d07black
Popover foreground
#171303black
#fdfdfcwhite
Primary
#e3dfcagainsboro
#e3dfcagainsboro
Primary foreground
#504a2adarkolivegreen
#504a2adarkolivegreen
Secondary
#cacee3lightgrey
#cacee3lightgrey
Secondary foreground
#2a3150darkslategray
#2a3150darkslategray
Muted
#eff0f5whitesmoke
#0a0b10black
Muted foreground
#51566cdimgray
#9398aedarkgray
Accent
#cacee3lightgrey
#cacee3lightgrey
Accent foreground
#2a3150darkslategray
#2a3150darkslategray
Destructive
#5d0c09maroon
#e92720crimson
Destructive foreground
#f6a5a2lightpink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#e3dfcagainsboro
#e3dfcagainsboro

Contrast

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

Light mode
Text on background18.56:1AAA
Text on card18.76:1AAA
Primary button6.63:1AA
Secondary button8.11:1AAA
Muted text6.37:1AA
Accent8.11:1AAA
Destructive7.11:1AAA
Dark mode
Text on background19.15:1AAA
Text on card19.07:1AAA
Primary button6.63:1AA
Secondary button8.11:1AAA
Muted text6.88:1AA
Accent8.11:1AAA
Destructive4.39:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.187 0.032 99.431);
  --muted: oklch(0.956 0.007 277.156);
  --muted-foreground: oklch(0.456 0.036 276.023);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.187 0.032 99.431);
  --card: oklch(0.992 0 161.565);
  --card-foreground: oklch(0.169 0.028 100.197);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.9 0.029 97.658);
  --primary-foreground: oklch(0.406 0.049 98.293);
  --secondary: oklch(0.854 0.03 276.758);
  --secondary-foreground: oklch(0.321 0.057 274.167);
  --accent: oklch(0.854 0.03 276.758);
  --accent-foreground: oklch(0.321 0.057 274.167);
  --destructive: oklch(0.31 0.113 28.254);
  --destructive-foreground: oklch(0.8 0.096 21.614);
  --ring: oklch(0.9 0.029 97.658);
  --chart-1: oklch(0.9 0.029 97.658);
  --chart-2: oklch(0.854 0.03 276.758);
  --chart-3: oklch(0.854 0.03 276.758);
  --chart-4: oklch(0.882 0.024 276.874);
  --chart-5: oklch(0.903 0.031 97.692);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.157 0.013 98.798);
  --foreground: oklch(0.994 0.002 97.282);
  --muted: oklch(0.149 0.012 276.027);
  --muted-foreground: oklch(0.683 0.033 276.55);
  --popover: oklch(0.157 0.013 98.798);
  --popover-foreground: oklch(0.994 0.002 97.282);
  --card: oklch(0.171 0.015 98.319);
  --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.9 0.029 97.658);
  --primary-foreground: oklch(0.406 0.049 98.293);
  --secondary: oklch(0.854 0.03 276.758);
  --secondary-foreground: oklch(0.321 0.057 274.167);
  --accent: oklch(0.854 0.03 276.758);
  --accent-foreground: oklch(0.321 0.057 274.167);
  --destructive: oklch(0.601 0.227 28.611);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.9 0.029 97.658);
  --chart-1: oklch(0.9 0.029 97.658);
  --chart-2: oklch(0.854 0.03 276.758);
  --chart-3: oklch(0.854 0.03 276.758);
  --chart-4: oklch(0.882 0.024 276.874);
  --chart-5: oklch(0.903 0.031 97.692);
}