Back to CSS

CSS Tutorial

Flexbox

Build one-dimensional layouts with flexible alignment.

Flexbox is useful for nav bars, cards, toolbars, and horizontal or vertical alignment.

It lets items share space and align predictably.

css
.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}