FREEFirst project with us? Your landing page design is on the house.See the offer

Chapter 2 of 6

Client-First, classes and variables

Anyone should be able to open the project and know what a class does before they click it. The structure, the naming rules, the stacking limits and how variables fit in.

6 min readUpdated 2026-11-07
All chaptersChapter 2 of 6
  1. 01Brief and Figma handover
  2. 02Client-First, classes and variables
  3. 03Components and CMS model
  4. 04Interactions that stay fast
  5. 05Editor handover
  6. 06Pre-launch checks

The short answer

Use one written class system from the first section. For new Webflow builds, our default is Client-First, the free naming system by Finsweet: readable names, custom classes by default, and variables for any value that repeats. Set up the variables first, build a style guide page, and then build pages from those parts.

The test is simple. A new developer opens the project in a year and can tell what a class does, and what else it will change, before touching it. If a site already has a working system, that system wins. The last section before the review says when.

The page skeleton

Every page starts from the same few layers. This is the default structure in the Client-First core structure docs:

page-wrapper > main-wrapper > section_[name] > container-[size]

LayerJobOur rule
page-wrapperWraps everything on the pageStyle it lightly, if at all
main-wrapperHolds main content in a main tagNav and footer stay outside it
section_[name]Wraps one section, and holds its paddingUse a section tag and a name that says what it is, such as section_pricing
container-[size]Centres content and sets the max widthUse small, medium or large. Do not invent a fourth width for one section.

The docs also describe an alternative, with padding-global and padding-section-[size] as a separate layer. Either is fine. Pick one per project, and write down which.

Naming rules

These follow the Client-First class docs. The examples use the pattern on a made-up pricing section.

RuleWrite thisNot this
Custom classes have an underscore. The part before it is the folder.pricing-card_titleHeading 3 copy
Name what the element is, in full words.team-list_headshot-wrappertl_img-wr
Utility classes have no underscore.text-size-largetext_size_large
Word order runs general to specific.text-size-largelarge-size-text
Combo classes start with is-.button is-secondarybutton secondary-2
Name by role, not by look or by page position.pricing-card_badgepurple-box-left

Our additions: no default Webflow names such as Div Block 47 survive to launch, and folder names match the section they belong to. The folders docs say each underscore adds a nested level, and warn against nesting without a reason. One level is usually enough.

Custom class, utility or combo?

The Client-First stacking docs make custom classes the default for most elements, because they are quick to make and safe to change. Use this table to choose.

SituationUseExample
An element with its own job in a sectionA custom classpricing-card_title
The same size or style needs site-wide controlA utility on top of a custom classpricing-card_title + text-size-large
A variant that keeps most of its base stylesA combo classbutton is-secondary
A variant that shares almost nothing with its baseA new custom classcontainer-large, not container is-large
One property used once, such as position: absolutePut it on the custom classDo not make a global utility for it
Classes on one elementClient-First guidance
1 or 2Common
3Ask if it is needed
4The absolute maximum
5 or moreToo many. Make a custom class.

Decision rule Never add a style while several global classes are stacked on an element. That quietly creates a new combo class. Stop, name it on purpose, or move the style to a custom class.

Variables come before classes

The stacking docs put it simply: use variables for repeated values, and classes for sets of properties. A class can read its values from variables. So the variables go in before the first section. Webflow groups variables in collections, and its Designer API docs show that one variable can be an alias of another of a compatible type. We use that for two tiers.

TierHoldsExample namesWho uses it
BrandThe raw values from Figmapurple-500, ink-900, whiteOther variables only
RoleA job, pointing at a brand valuetext-primary, background-primary, border-subtle, button-backgroundClasses

Now a rebrand is one edit in the brand tier, and a dark section changes role values only. The names above are our convention, so write yours down and keep it.

Webflow also has variable modes, where one variable holds several values, in sets such as a theme. Automatic modes attach to a breakpoint and switch on at that size. Client-First uses this approach for spacing: its spacing docs say values live in a Layout collection, with breakpoint modes, so spacing classes adapt without extra breakpoint classes. Check the current docs for mode limits before you plan around them.

Spacing: one method per job

Spacing is where projects drift first. The spacing docs offer several methods, so agree which one does which job.

JobUseClass example
Space above and below a sectionSection padding variables, or the padding section classespadding-section-large
Even space between items in a flex or grid parentA gap classgap-medium
Space between two siblings in a stackA spacing wrapper around one of them, or an empty spacing blockmargin-bottom-medium, padding-bottom-medium
A one-off inside a componentOn that component's custom classpricing-card_title

Size names run from xxtiny to xxhuge. Map your Figma scale to those names once, and keep the mapping on the style guide page. If a design asks for a size not on the scale, ask if it is on purpose before adding one.

When to keep the system that is there

A class system is a means to an end. Mixing two is worse than keeping either.

SituationWhat to do
New build, no systemUse Client-First. Petavue runs on it, so its team can add pages from the same parts.
New pages on a site with a working style guideKeep it. On CUBE we link every colour, heading and space to their existing variables, so new pages match the rest of the site.
Small one-page siteKeep it light. Baraka Impact needed one clean class system, not a large library.
Messy inherited siteDecide in the open: clean up in stages, or rebuild. Do not start a second system in a corner.

A class review before anything ships

  • No default Webflow class names, and no names ending in numbers or "copy".
  • Each section uses the agreed skeleton and has a descriptive section_ name.
  • No element has 5 or more classes, and any with 4 has a reason.
  • Colours, type sizes and main spacing read from variables, with no hand-typed values for brand colours.
  • The style guide page shows the type, colours, buttons, spacing and main components.
  • A style change on one card updates all cards. Try it, then undo it.
  • Unused classes are reviewed and removed.

Done when Someone who did not build the site can find a section by name in the Navigator, change a button style in one place, and predict what that change will affect.

Takeaways

What to remember from chapter 2.

  • Pick one written class system from the first section. Client-First is our default for new builds.
  • Custom classes first. Add utilities where site-wide control matters, and combos only for true variants.
  • Three classes is a question. Five is a sign you need a custom class.
  • Set up variables before classes, with brand values and role values as two tiers.
  • If a working style guide already exists, build on it. Never run two systems side by side.

Your turn

Let's kook
what you krave.

Hi Kookies, I need a built on . I'd love to launch . Reach me at
or book a callSent. We reply within one working day.