What is CSS Flexbox?
A CSS layout model that provides efficient arrangement of items within a container, handling alignment, distribution, and spacing.
Flexbox simplifies one-dimensional layouts (row or column). Key container properties: display: flex, flex-direction, justify-content (main axis alignment), align-items (cross axis), gap, and flex-wrap. Item properties: flex-grow, flex-shrink, flex-basis, and order.
Common patterns include centering (justify-content: center; align-items: center), equal spacing (justify-content: space-between), responsive navigation bars, and card layouts. Flexbox replaced many float and positioning hacks with clean, predictable layout behavior.