Brandfine Docs
WordPress

Theme the widget

The Brandfine widget is scoped under .bf-widget and driven by ~25 CSS custom properties. Brand it with one CSS rule.

The widget's visual surface is theme-agnostic by design — every selector is scoped under .bf-widget, and every color, radius, font size, and shadow is exposed as a CSS custom property. To brand the widget for your site, override the variables you care about. No theme override file, no !important wars.

Add a CSS snippet to your theme's customizer, a Custom CSS plugin, or your child theme's stylesheet. Example — match a warm clay / sage brand:

.bf-widget {
  --bf-color-primary: #c2654e;
  --bf-color-primary-hover: #a85439;
  --bf-color-accent: #2e5a6b;
  --bf-radius: 16px;
}

That's the entire customization for most cases.

All available variables

Colors

VariableDefaultWhat it colors
--bf-color-primary#0B1F2ASubmit button background, selected calendar day, focused state
--bf-color-primary-fg#ffffffText on the primary color
--bf-color-primary-hover#1a3543Submit button hover
--bf-color-accent#2E5A6BFocus ring, calendar dots, status pill
--bf-color-text#0B1F2ABody text
--bf-color-text-muted#6b7280Secondary text (subtitles, fineprint)
--bf-color-border#e5e7ebDefault border
--bf-color-border-strong#d1d5dbHover-state border
--bf-color-surface#ffffffCard background
--bf-color-surface-soft#f9fafbLighter "rest" surface (empty state)
--bf-color-surface-hover#f3f4f6Hover state for clickable cells
--bf-color-error#b91c1cError icons, required-field marker
--bf-color-warning#92400eBanner warnings (e.g. "slot taken")
--bf-color-success#047857Success-card icon

Each surface color has a matching *-bg for tinted backgrounds.

Typography

VariableDefaultNotes
--bf-font-familysystem stackInherits from your theme if you want — set to inherit.
--bf-font-size14pxBase body size
--bf-font-size-sm12pxHints, labels
--bf-font-size-lg18pxWidget title
--bf-line-height1.5Base line height

Layout

VariableDefaultNotes
--bf-radius12pxOuter card radius
--bf-radius-sm8pxInputs, slot buttons, internal elements
--bf-radius-full999pxPills, icon buttons
--bf-shadowsubtleCard shadow
--bf-max-width520pxWidget caps at this width — set higher for wider hero placements
--bf-pad22pxOuter padding
--bf-gap12pxDefault vertical gap
--bf-gap-lg20pxSection gap

Dark mode

The widget respects prefers-color-scheme: dark automatically. When the visitor's OS is in dark mode AND your theme doesn't pin a color scheme, the widget palette inverts to a dark surface.

To force light mode (e.g. you have a dark hero that needs the widget to stay light):

<div class="bf-widget bf-widget--force-light" ...>

(Pass align="center" etc. via the shortcode — to add classes, use a wrapper div around [brandfine_appointments] or a Code block.)

To force dark mode unconditionally, override the variables yourself in CSS — there's no built-in --force-dark modifier.

Examples

Soft pastel / Mediterranean

.bf-widget {
  --bf-color-primary: #2e5a6b;
  --bf-color-accent: #c2654e;
  --bf-color-surface: #f1ece3;
  --bf-color-surface-soft: #ebe5d8;
  --bf-color-border: rgba(11, 31, 42, 0.12);
  --bf-radius: 18px;
}

Bold high-contrast

.bf-widget {
  --bf-color-primary: #ff6b00;
  --bf-color-primary-hover: #e95f00;
  --bf-color-accent: #ff6b00;
  --bf-color-text: #111111;
  --bf-radius: 6px;
}

Match the page typography exactly

.bf-widget {
  --bf-font-family: inherit;
}

Defensive resets

The widget already resets the following on its root to avoid unwanted inheritance from your theme:

  • font-family, font-size, line-height (set by the variables above, default to neutral system stack)
  • color, text-align
  • box-sizing: border-box (on the root and every descendant)

If your theme bleeds something else (e.g. letter-spacing applied to all elements), open an issue and we'll add a defensive reset for it.

On this page