Building a small brand palette from one blue
Most palettes start with one colour somebody already likes. Say it is #3b82f6, a clear mid blue, and the variable name is brand. The page shows the blue on top with its rgb() and hsl() values, and under it three rows: tints, shades and harmonies. The CSS box below holds all fourteen colours as custom properties, starting with --brand: #3b82f6.
The tints are the blue mixed with white. At 20 percent white it is #629bf8, still clearly the brand blue but softer. At 80 percent it is #d8e6fd, pale enough to sit behind dark text as the background of an information banner. The shades go the other way. At 20 percent black the blue becomes #2f68c5, a natural hover colour for a button, and at 80 percent it is #0c1a31, close to navy and useful for dark headers.
The harmonies give accent colours. The complement of this blue is #f6af3b, an orange, which is the classic choice for a call to action that must stand out from a blue page. The analogous colours, #3bdff6 and #523bf6, are a cyan and a violet that sit comfortably next to the brand blue in a chart. The triadic pair, #f63b82 and #82f63b, a pink and a lime green, are louder: they work as small highlights and badly as large fills.
Pasting the block into a stylesheet gives every component one source of truth. A button can use background: var(--brand) and switch to var(--brand-shade-20) on hover. A light theme can use var(--brand-tint-80) for selected rows. When the brand colour changes next year, typing the new value here and pasting the new block updates every one of them.
There are limits to keep in mind. The tints and shades are linear sRGB mixes, which is what CSS and Sass do; perceptual colour spaces such as OKLCH would give more even steps in lightness, and this page does not use them. The harmonies follow the HSL wheel, so two colours with the same HSL lightness can look very different in brightness. And nothing here checks contrast. Run any pair you plan to put text on through a contrast checker before you build with it.