CSS Primer For the AI Era

A vocabulary for shaping interfaces with AI

User Tools

Site Tools


vocabulary:css_visual_vocabulary:spatial_contrast

Spatial Contrast

— the difference in spacing, openness,
and density between elements

Spatial contrast is the contrast of space
— how much room elements have around them,
and how tightly or loosely they sit together.

It is the difference between:

  • open vs. compressed
  • generous vs. tight
  • airy vs. dense

Spatial contrast is not decoration.
It is structure expressed through
breathing room
.


What spatial contrast does

  • Creates grouping — elements with small gaps feel related
  • Creates separation — larger gaps signal a new idea or section
  • Shapes hierarchy — important elements get more space
  • Sets tone — open layouts feel calm; tight layouts feel efficient
  • Controls rhythm — spacing patterns create predictable pacing

Spatial contrast is how
the layout speaks
without color or typography
.


The main forms of spatial contrast

  • Gap contrast — small vs. large spacing between siblings
  • Margin contrast — separation between sections
  • Padding contrast — comfort inside containers
  • Density contrast — tight vs. open regions
  • Whitespace contrast — intentional emptiness

Each one expresses a different kind of spatial difference.


How we describe spatial contrast when working with AI

These phrases give AI clear, predictable direction:

“Increase spatial contrast between these sections.”
“Tighten the spacing between these siblings.”
“Give this element more internal space.”
“Reduce spatial contrast to keep the layout compact.”
“Use spacing to express hierarchy.”

This turns spacing from guesswork
into intention
.


Why spatial contrast matters

Spatial contrast is the foundation of:

  • Hierarchy — space signals importance
  • Rhythm — spacing patterns create pace
  • Density — openness vs. tightness
  • Tone — calm vs. energetic layouts

Without spatial contrast,
everything sits with the same
weight and presence
.


Tony de Araujo —New York | Lisbon


vocabulary/css_visual_vocabulary/spatial_contrast.txt · Last modified: by editor