Use containers to keep your content legible and centered.
The container element is useful for keeping your content neatly organized towards the center of the screen. It’s typically used alongside a section element. You can add a container from the Add panel > Structure section.
In this lesson, we’ll cover:
Anatomy of a container
A container is a div block with predefined styles. It has a 940-pixel max width on larger displays to keep your content centered relative to the browser window. On smaller devices (like phones and tablets), containers extend the full width of the screen.
You can adjust the max width of a container so it will still respond to the size of your viewport but only extend to the maximum width you set.
How to use containers, sections, and div blocks
In web development, containers are often situated inside of section elements. A section, by default, is full-width. You can put a container inside the section to keep elements neatly bound towards the center. Then, you can use div blocks inside containers to organize elements using layout, spacing, size, and position.