← Colors in interface design

Using Ginger (#B06500) in Interface Design: Scale, Buttons and Dark Mode

A working design system from Ginger #B06500: a 50 to 950 scale, button states with contrast, a dark-mode version, an accessible link color and the CSS to paste in.

Ginger (#B06500) is a medium, moderately saturated brown. As an interface color it has a clear personality: it is light enough that dark labels read better than white ones, which makes it better as a surface, a highlight or a data color than as a button. This guide shows how to build a working interface from it: a full scale, every button state, a dark-mode version, a link color that passes, and the CSS to paste in.

A scale built from Ginger

A single color is not enough for an interface. You need lighter steps for surfaces and borders and darker steps for text and hover states. This 50 to 950 scale keeps the hue and saturation of Ginger and moves only the lightness. The step closest to Ginger keeps its exact value.

StepHexContrast on whiteBest text on it
50#FFF5EC1.07:1#111111
100#FCE7D51.19:1#111111
200#F8D3B31.40:1#111111
300#ECB4821.83:1#111111
400#D6904C2.64:1#111111
500#BD711B3.78:1#111111
600#B065004.46:1#000000
700#7F49087.34:1#FFFFFF
800#62360210.25:1#FFFFFF
900#49270013.34:1#FFFFFF
950#2C140017.39:1#FFFFFF

Button states

Interactive elements need to look different when you hover, press and disable them, and each state still has to be readable. These values are made from Ginger itself, so the button stays in family.

StateBackgroundLabelLabel contrast
Default#B06500#0000004.70:1
Hover#A65F00#FFFFFF4.93:1
Pressed#9D5A00#FFFFFF5.39:1
Disabled#E5D6CE#6B72803.41:1

Disabled controls are exempt from WCAG contrast rules, but they still need to be recognizable, so the label is kept dark enough to read. For keyboard focus, use an outline of Ginger (#B06500), which reaches 3 to 1 against a white page, the minimum for interface parts.

Dark mode

On a near-black page (#0F1115), Ginger reaches 4.23:1 (AA large). That is not enough for text, so lighten it. Caramel (#B76B10) is the closest lightness of the same hue that reaches 4.5 to 1.

Links and text

Ginger on white reaches only 4.46:1, which is not enough for text. For links and small headings use Ginger (#A8651B), the closest shade that reaches 4.5 to 1, and keep Ginger itself for fills and large display type.

Surfaces and borders

Tints of Ginger make quiet surfaces that feel connected to the brand without competing with it. Snow (#FBF9F8) works as a card or page tint, and Bride (#F1E8E5) as a border or divider.

The CSS

CSS variablescss
:root {
  --brand: #B06500;
  --brand-hover: #A65F00;
  --brand-active: #9D5A00;
  --on-brand: #000000;
  --brand-surface: #FBF9F8;
  --brand-border: #F1E8E5;
  --brand-text: #A8651B;
  --focus-ring: #B06500;
}

@media (prefers-color-scheme: dark) {
  :root {
    --brand: #B76B10;
    --brand-text: #B76B10;
  }
}

A short checklist

  1. Use Ginger for the one action you most want people to take.
  2. Put #000000 text on it and check that the ratio stays above 4.5 to 1.
  3. Use the scale for hover, pressed, border and surface colors rather than inventing new ones.
  4. Define a separate dark-mode value and test it on a dark page.
  5. Never use the color as the only signal: add an icon, a label or an underline.