Detention is a shadcn/ui theme built around a deep purple primary color (#51275d) with deep teal accents (#275d51). The light mode uses a neutral background (#ffffff). Dark mode keeps the deep purple primary (#51275d) on a neutral background (#070208).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #070208black |
| Foreground | #000000black | #f9f5faghostwhite |
| Card | #fcfcfcsnow | #0a040cblack |
| Card foreground | #000000black | #fbf8fcghostwhite |
| Popover | #fcfcfcsnow | #0a040cblack |
| Popover foreground | #000000black | #fbf8fcghostwhite |
| Primary | #51275ddarkslateblue | #51275ddarkslateblue |
| Primary foreground | #e3cdeagainsboro | #e3cdeagainsboro |
| Secondary | #5d5127darkolivegreen | #5d5127darkolivegreen |
| Secondary foreground | #eae3cdantiquewhite | #eae3cdantiquewhite |
| Muted | #e9e4d2gainsboro | #2d2716black |
| Muted foreground | #746e58dimgray | #a7a18brosybrown |
| Accent | #275d51darkslategray | #275d51darkslategray |
| Accent foreground | #ffffffwhite | #ffffffwhite |
| Destructive | #953a09saddlebrown | #d9540dchocolate |
| Destructive foreground | #ffffffwhite | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #51275ddarkslateblue | #51275ddarkslateblue |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 21.00:1 | AAA |
| Text on card | 20.54:1 | AAA |
| Primary button | 7.88:1 | AAA |
| Secondary button | 6.12:1 | AA |
| Muted text | 4.01:1 | AA Large |
| Accent | 7.53:1 | AAA |
| Destructive | 7.25:1 | AAA |
| Text on background | 19.04:1 | AAA |
| Text on card | 19.29:1 | AAA |
| Primary button | 7.88:1 | AAA |
| Secondary button | 6.12:1 | AA |
| Muted text | 5.72:1 | AA |
| Accent | 7.53:1 | AAA |
| Destructive | 4.02:1 | AA Large |
Paste this into your globals.css to use Detention in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0 0 0);
--muted: oklch(0.918 0.024 92.897);
--muted-foreground: oklch(0.537 0.034 93.118);
--popover: oklch(0.992 0 161.565);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.992 0 161.565);
--card-foreground: oklch(0 0 0);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.354 0.102 317.789);
--primary-foreground: oklch(0.875 0.046 318.277);
--secondary: oklch(0.437 0.062 92.777);
--secondary-foreground: oklch(0.916 0.031 92.951);
--accent: oklch(0.439 0.062 175.727);
--accent-foreground: oklch(1 0 180);
--destructive: oklch(0.469 0.134 42.788);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.354 0.102 317.789);
--chart-1: oklch(0.354 0.102 317.789);
--chart-2: oklch(0.437 0.062 92.777);
--chart-3: oklch(0.439 0.062 175.727);
--chart-4: oklch(0.471 0.067 92.746);
--chart-5: oklch(0.354 0.108 317.707);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.106 0.023 320.168);
--foreground: oklch(0.974 0.008 318.322);
--muted: oklch(0.275 0.031 93.102);
--muted-foreground: oklch(0.707 0.032 93.027);
--popover: oklch(0.121 0.026 319.907);
--popover-foreground: oklch(0.983 0.005 318.325);
--card: oklch(0.121 0.026 319.907);
--card-foreground: oklch(0.983 0.005 318.325);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.354 0.102 317.789);
--primary-foreground: oklch(0.875 0.046 318.277);
--secondary: oklch(0.437 0.062 92.777);
--secondary-foreground: oklch(0.916 0.031 92.951);
--accent: oklch(0.439 0.062 175.727);
--accent-foreground: oklch(1 0 180);
--destructive: oklch(0.614 0.181 42.014);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.354 0.102 317.789);
--chart-1: oklch(0.354 0.102 317.789);
--chart-2: oklch(0.437 0.062 92.777);
--chart-3: oklch(0.439 0.062 175.727);
--chart-4: oklch(0.471 0.067 92.746);
--chart-5: oklch(0.354 0.108 317.707);
}