Dual is a shadcn/ui theme built around a near-black primary color (#010403) with muted teal accents (#a9cbc3). The light mode uses a neutral background (#ffffff). Dark mode keeps the near-black primary (#010403) on a neutral background (#030706).
| Token | Light | Dark |
|---|---|---|
| Background | #ffffffwhite | #030706black |
| Foreground | #010403black | #f9fbfamintcream |
| Card | #fcfcfcsnow | #050b09black |
| Card foreground | #000000black | #fcfdfdwhite |
| Popover | #fcfcfcsnow | #050b09black |
| Popover foreground | #000000black | #fcfdfdwhite |
| Primary | #010403black | #010403black |
| Primary foreground | #2ba687mediumseagreen | #2ba687mediumseagreen |
| Secondary | #c7d6d2lightgrey | #1f2e2adarkslategray |
| Secondary foreground | #2d3e3adarkslategray | #b3cbc5silver |
| Muted | #d1e6e1gainsboro | #192e29darkslategray |
| Muted foreground | #606665dimgray | #999f9ddarkgray |
| Accent | #a9cbc3silver | #2d4e45darkslategray |
| Accent foreground | #192925black | #cbe1dcgainsboro |
| Destructive | #bd4c14chocolate | #e96d2fchocolate |
| Destructive foreground | #ffffffwhite | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #010403black | #010403black |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 20.58:1 | AAA |
| Text on card | 20.54:1 | AAA |
| Primary button | 6.76:1 | AA |
| Secondary button | 7.52:1 | AAA |
| Muted text | 4.49:1 | AA Large |
| Accent | 8.69:1 | AAA |
| Destructive | 4.97:1 | AA |
| Text on background | 19.48:1 | AAA |
| Text on card | 19.51:1 | AAA |
| Primary button | 6.76:1 | AA |
| Secondary button | 8.31:1 | AAA |
| Muted text | 5.30:1 | AA |
| Accent | 6.73:1 | AA |
| Destructive | 6.71:1 | AA |
Paste this into your globals.css to use Dual in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(1 0 180);
--foreground: oklch(0.1 0.013 179.919);
--muted: oklch(0.908 0.024 179.1);
--muted-foreground: oklch(0.506 0.008 179.425);
--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.099 0.012 179.915);
--primary-foreground: oklch(0.652 0.115 171.769);
--secondary: oklch(0.864 0.018 179.278);
--secondary-foreground: oklch(0.348 0.023 177.787);
--accent: oklch(0.816 0.039 178.444);
--accent-foreground: oklch(0.266 0.024 177.011);
--destructive: oklch(0.56 0.158 42.342);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.099 0.012 179.915);
--chart-1: oklch(0.099 0.012 179.915);
--chart-2: oklch(0.864 0.018 179.278);
--chart-3: oklch(0.816 0.039 178.444);
--chart-4: oklch(0.886 0.015 179.386);
--chart-5: oklch(0.1 0.012 179.917);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.122 0.01 179.9);
--foreground: oklch(0.986 0.002 179.82);
--muted: oklch(0.283 0.029 176.388);
--muted-foreground: oklch(0.696 0.007 179.57);
--popover: oklch(0.139 0.012 179.853);
--popover-foreground: oklch(0.993 0.001 179.843);
--card: oklch(0.139 0.012 179.853);
--card-foreground: oklch(0.993 0.001 179.843);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.099 0.012 179.915);
--primary-foreground: oklch(0.652 0.115 171.769);
--secondary: oklch(0.285 0.021 177.592);
--secondary-foreground: oklch(0.823 0.027 178.884);
--accent: oklch(0.395 0.042 176.321);
--accent-foreground: oklch(0.892 0.025 179.061);
--destructive: oklch(0.675 0.17 44.207);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.099 0.012 179.915);
--chart-1: oklch(0.099 0.012 179.915);
--chart-2: oklch(0.285 0.021 177.592);
--chart-3: oklch(0.395 0.042 176.321);
--chart-4: oklch(0.319 0.024 177.488);
--chart-5: oklch(0.1 0.012 179.917);
}