Precious is a shadcn/ui theme built around a deep purple primary color (#2e0d35) with deep teal accents (#0d352e). The light mode uses a neutral background (#fbf8fc). Dark mode keeps the deep purple primary (#2e0d35) on a neutral background (#030104).
| Token | Light | Dark |
|---|---|---|
| Background | #fbf8fcghostwhite | #030104black |
| Foreground | #040104black | #fbf8fcghostwhite |
| Card | #fbf8fcghostwhite | #030104black |
| Card foreground | #040104black | #fbf8fcghostwhite |
| Popover | #fbf8fcghostwhite | #030104black |
| Popover foreground | #040104black | #fbf8fcghostwhite |
| Primary | #2e0d35midnightblue | #2e0d35midnightblue |
| Primary foreground | #d590e4plum | #d590e4plum |
| Secondary | #352e0dblack | #352e0dblack |
| Secondary foreground | #d0b53egoldenrod | #d0b53egoldenrod |
| Muted | #dfddd8gainsboro | #272620darkslategray |
| Muted foreground | #64635edimgray | #a1a09bdarkgray |
| Accent | #0d352edarkslategray | #0d352edarkslategray |
| Accent foreground | #3ed0b5mediumturquoise | #3ed0b5mediumturquoise |
| Destructive | #ab4a12sienna | #e26218chocolate |
| Destructive foreground | #ffffffwhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #2e0d35midnightblue | #2e0d35midnightblue |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.67:1 | AAA |
| Text on card | 19.67:1 | AAA |
| Primary button | 7.29:1 | AAA |
| Secondary button | 6.68:1 | AA |
| Muted text | 4.44:1 | AA Large |
| Accent | 6.92:1 | AA |
| Destructive | 5.65:1 | AA |
| Text on background | 19.71:1 | AAA |
| Text on card | 19.71:1 | AAA |
| Primary button | 7.29:1 | AAA |
| Secondary button | 6.68:1 | AA |
| Muted text | 5.80:1 | AA |
| Accent | 6.92:1 | AA |
| Destructive | 5.99:1 | AA |
Paste this into your globals.css to use Precious in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.982 0.007 319.998);
--foreground: oklch(0.081 0.027 322.587);
--muted: oklch(0.898 0.007 96.266);
--muted-foreground: oklch(0.498 0.008 96.351);
--popover: oklch(0.982 0.007 319.998);
--popover-foreground: oklch(0.081 0.027 322.587);
--card: oklch(0.982 0.007 319.998);
--card-foreground: oklch(0.081 0.027 322.587);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.235 0.082 319.817);
--primary-foreground: oklch(0.751 0.138 320.098);
--secondary: oklch(0.301 0.05 96.573);
--secondary-foreground: oklch(0.777 0.138 96.224);
--accent: oklch(0.3 0.046 178.444);
--accent-foreground: oklch(0.776 0.128 177.675);
--destructive: oklch(0.528 0.142 45.121);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.235 0.082 319.817);
--chart-1: oklch(0.235 0.082 319.817);
--chart-2: oklch(0.301 0.05 96.573);
--chart-3: oklch(0.3 0.046 178.444);
--chart-4: oklch(0.343 0.059 96.439);
--chart-5: oklch(0.235 0.085 319.759);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.085 0.019 321.822);
--foreground: oklch(0.983 0.005 319.996);
--muted: oklch(0.267 0.01 96.584);
--muted-foreground: oklch(0.705 0.007 96.288);
--popover: oklch(0.085 0.019 321.822);
--popover-foreground: oklch(0.983 0.005 319.996);
--card: oklch(0.085 0.019 321.822);
--card-foreground: oklch(0.983 0.005 319.996);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.235 0.082 319.817);
--primary-foreground: oklch(0.751 0.138 320.098);
--secondary: oklch(0.301 0.05 96.573);
--secondary-foreground: oklch(0.777 0.138 96.224);
--accent: oklch(0.3 0.046 178.444);
--accent-foreground: oklch(0.776 0.128 177.675);
--destructive: oklch(0.647 0.177 44.647);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.235 0.082 319.817);
--chart-1: oklch(0.235 0.082 319.817);
--chart-2: oklch(0.301 0.05 96.573);
--chart-3: oklch(0.3 0.046 178.444);
--chart-4: oklch(0.343 0.059 96.439);
--chart-5: oklch(0.235 0.085 319.759);
}