Both is a shadcn/ui theme built around a deep purple primary color (#660f5a) with deep pink accents (#660f2f). The light mode uses a neutral background (#ffffff). Dark mode keeps the deep purple primary (#660f5a) on a purple-tinted background (#0c030b).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #0c030bblack |
| Foreground | #040104black | #f9f6f8whitesmoke |
| Card | #ffffffwhite | #0c030bblack |
| Card foreground | #040104black | #f9f6f8whitesmoke |
| Popover | #ffffffwhite | #0c030bblack |
| Popover foreground | #040104black | #f9f6f8whitesmoke |
| Primary | #660f5apurple | #660f5apurple |
| Primary foreground | #f4b4ebplum | #f4b4ebplum |
| Secondary | #460f66indigo | #460f66indigo |
| Secondary foreground | #dcb4f4thistle | #dcb4f4thistle |
| Muted | #ede2f3lavender | #170c1dblack |
| Muted foreground | #534c57darkslategray | #afa8b3darkgray |
| Accent | #660f2fmaroon | #660f2fmaroon |
| Accent foreground | #f4b4cblightpink | #f4b4cblightpink |
| Destructive | #d34c12chocolate | #ee703atomato |
| Destructive foreground | #ffffffwhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #660f5apurple | #660f5apurple |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.76:1 | AAA |
| Text on card | 20.76:1 | AAA |
| Primary button | 7.04:1 | AAA |
| Secondary button | 7.79:1 | AAA |
| Muted text | 6.62:1 | AA |
| Accent | 7.29:1 | AAA |
| Destructive | 4.35:1 | AA Large |
| Text on background | 18.92:1 | AAA |
| Text on card | 18.92:1 | AAA |
| Primary button | 7.04:1 | AAA |
| Secondary button | 7.79:1 | AAA |
| Muted text | 8.20:1 | AAA |
| Accent | 7.29:1 | AAA |
| Destructive | 7.00:1 | AAA |
Paste this into your globals.css to use Both in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.085 0.022 331.024);
--muted: oklch(0.927 0.024 313.444);
--muted-foreground: oklch(0.427 0.021 313.308);
--popover: oklch(1 0 180);
--popover-foreground: oklch(0.085 0.022 331.024);
--card: oklch(1 0 180);
--card-foreground: oklch(0.085 0.022 331.024);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.359 0.145 334.532);
--primary-foreground: oklch(0.845 0.103 331.097);
--secondary: oklch(0.315 0.141 308.858);
--secondary-foreground: oklch(0.826 0.098 312.87);
--accent: oklch(0.339 0.121 5.14);
--accent-foreground: oklch(0.834 0.08 355.183);
--destructive: oklch(0.595 0.181 39.434);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.359 0.145 334.532);
--chart-1: oklch(0.359 0.145 334.532);
--chart-2: oklch(0.315 0.141 308.858);
--chart-3: oklch(0.339 0.121 5.14);
--chart-4: oklch(0.342 0.155 308.684);
--chart-5: oklch(0.362 0.148 334.672);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.123 0.03 331.237);
--foreground: oklch(0.976 0.005 329.741);
--muted: oklch(0.179 0.036 312.294);
--muted-foreground: oklch(0.74 0.018 313.455);
--popover: oklch(0.123 0.03 331.237);
--popover-foreground: oklch(0.976 0.005 329.741);
--card: oklch(0.123 0.03 331.237);
--card-foreground: oklch(0.976 0.005 329.741);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.359 0.145 334.532);
--primary-foreground: oklch(0.845 0.103 331.097);
--secondary: oklch(0.315 0.141 308.858);
--secondary-foreground: oklch(0.826 0.098 312.87);
--accent: oklch(0.339 0.121 5.14);
--accent-foreground: oklch(0.834 0.08 355.183);
--destructive: oklch(0.687 0.17 42.126);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.359 0.145 334.532);
--chart-1: oklch(0.359 0.145 334.532);
--chart-2: oklch(0.315 0.141 308.858);
--chart-3: oklch(0.339 0.121 5.14);
--chart-4: oklch(0.342 0.155 308.684);
--chart-5: oklch(0.362 0.148 334.672);
}