Brand Colors
Change your banner’s entire color scheme in six lines by overriding the three top-level color tokens.
Match the banner to your brand’s primary color without hand-picking individual buttons, borders, or text colors. Kookiok’s token system fans a single --accent hue out to buttons, focus rings, and interactive states automatically, so you only need to set three variables.
The CSS
Section titled “The CSS”/* ── Brand color override ──────────────────────────────── */.ag-banner { /* Primary brand color — used for button fills, focus rings, highlights */ --accent: #0f766e; /* teal-700 */
/* Button background (defaults to --accent, override to split them) */ --btn-fill: #0f766e;
/* Banner surface / card background */ --surface: #f0fdfa; /* teal-50 */
/* Text color on surface */ --surface-text: #134e4a; /* teal-900 */
/* Button text — must contrast with --btn-fill (WCAG AA ≥ 4.5:1) */ --btn-text: #ffffff;
/* Link / secondary accent */ --link: #0d9488; /* teal-600 */}Live preview — default (before)
Section titled “Live preview — default (before)”classic · dialog · center Live preview — brand colors (after)
Section titled “Live preview — brand colors (after)”classic · dialog · center What’s happening
Section titled “What’s happening”--accentis the primary color token. Buttons, focus outlines, checkbox ticks, and the progress indicator all reference it. Setting it cascades to all those places for free.--btn-fillcontrols button background explicitly. It defaults to--accentbut can diverge — useful if your brand uses a slightly different shade for interactive elements.--surfacesets the banner card or bar background.--surface-textis the foreground that sits on top; always set them together to maintain readable contrast.--btn-textis the label color inside primary buttons. White (#ffffff) works for dark fills; flip to a dark shade if your--btn-fillis light.--linkcontrols anchor and secondary-action text color.
None of these targets individual elements — they define the palette globally, and every component picks them up through CSS inheritance.
Variations
Section titled “Variations”Warm rose brand
.ag-banner { --accent: #e11d48; --btn-fill: #e11d48; --surface: #fff1f2; --surface-text: #4c0519; --btn-text: #ffffff; --link: #be123c;}Midnight navy brand
.ag-banner { --accent: #1e40af; --btn-fill: #1e40af; --surface: #eff6ff; --surface-text: #1e3a8a; --btn-text: #ffffff; --link: #2563eb;}Light fill with dark text (for high-visibility buttons)
.ag-banner { --accent: #854d0e; --btn-fill: #fef9c3; --surface: #fffbeb; --surface-text: #713f12; --btn-text: #713f12; --link: #92400e;}Compliance notes
Section titled “Compliance notes”The token override approach does not affect compliance scoring — it modifies visual style only. The accept and reject buttons remain equally prominent (same fill, same size), and no branding elements are touched.
Related recipes
Section titled “Related recipes”- Rounded Corners — pair brand colors with a custom border radius
- Dark Mode Override — apply a separate dark palette for
prefers-color-scheme: dark - Full Redesign — extend this into a complete restyle