Astolfo v2 for shadcn/ui

Astolfo v2 is a shadcn/ui theme built around a purple primary color (#b770cd) with muted light purple accents (#d6c9d9). The light mode uses a neutral background (#ffffff). Dark mode switches to a vivid pink primary (#ff2975) on a pink-tinted background (#b20240).

Color palette

TokenLightDark
Background
#ffffffwhite
#b20240firebrick
Foreground
#0e0311black
#ffffffwhite
Card
#ffffffwhite
#881337brown
Card foreground
#0e0311black
#ffffffwhite
Popover
#ffffffwhite
#c30060mediumvioletred
Popover foreground
#0e0311black
#ffffffwhite
Primary
#b770cdmediumorchid
#ff2975deeppink
Primary foreground
#060308black
#ffffffwhite
Secondary
#e5e0e6gainsboro
#8b2549brown
Secondary foreground
#4f4153darkslategray
#ffffffwhite
Muted
#ebe2eelavender
#ff0060crimson
Muted foreground
#474148darkslategray
#ffffffwhite
Accent
#d6c9d9thistle
#d70049crimson
Accent foreground
#3d2e42darkslategray
#ffffffwhite
Destructive
#8a280fsaddlebrown
#ff006adeeppink
Destructive foreground
#fad9d1bisque
#ffffffwhite
Border
#e8e7e9lavender
#ffffffwhite
Input
#e8e7e9lavender
#ff97c6lightpink
Ring
#b770cdmediumorchid
#ffffffwhite

Contrast

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

Light mode
Text on background20.19:1AAA
Text on card20.19:1AAA
Primary button6.04:1AA
Secondary button7.26:1AAA
Muted text7.86:1AAA
Accent7.90:1AAA
Destructive6.67:1AA
Dark mode
Text on background7.08:1AAA
Text on card9.56:1AAA
Primary button3.60:1AA Large
Secondary button8.54:1AAA
Muted text3.87:1AA Large
Accent5.27:1AA
Destructive3.84:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.131 0.041 319.257);
  --muted: oklch(0.924 0.019 318.31);
  --muted-foreground: oklch(0.385 0.013 318.296);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.131 0.041 319.257);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.131 0.041 319.257);
  --border: oklch(0.93 0.002 318.328);
  --input: oklch(0.93 0.002 318.328);
  --primary: oklch(0.656 0.153 317.976);
  --primary-foreground: oklch(0.107 0.02 319.949);
  --secondary: oklch(0.911 0.011 318.319);
  --secondary-foreground: oklch(0.396 0.034 318.241);
  --accent: oklch(0.851 0.026 318.299);
  --accent-foreground: oklch(0.327 0.041 318.194);
  --destructive: oklch(0.426 0.137 34.605);
  --destructive-foreground: oklch(0.911 0.038 34.317);
  --ring: oklch(0.656 0.153 317.976);
  --chart-1: oklch(0.656 0.153 317.976);
  --chart-2: oklch(0.911 0.011 318.319);
  --chart-3: oklch(0.851 0.026 318.299);
  --chart-4: oklch(0.936 0.008 318.322);
  --chart-5: oklch(0.654 0.161 317.935);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.486 0.194 12.497);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.638 0.255 12.233);
  --muted-foreground: oklch(1 0 180);
  --popover: oklch(0.528 0.213 2.745);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.41 0.15 10.272);
  --card-foreground: oklch(1 0 180);
  --border: oklch(1 0 180);
  --input: oklch(0.798 0.136 351.99);
  --primary: oklch(0.654 0.243 7.571);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.436 0.14 3.566);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.559 0.223 14.546);
  --accent-foreground: oklch(1 0 180);
  --destructive: oklch(0.64 0.256 9.335);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(1 0 180);
  --chart-1: oklch(0.654 0.243 7.571);
  --chart-2: oklch(0.436 0.14 3.566);
  --chart-3: oklch(0.559 0.223 14.546);
  --chart-4: oklch(0.462 0.15 3.702);
  --chart-5: oklch(0.658 0.247 8.095);
}