Two Different Methods
We used two methods for creating columns on this mini site.
The front page and the four columns use a slighlty different method than was used on the interior pages.
Child Containers
This is the beauty of flexbox.
You can use conventional CSS properties like float and text-align inside child containers.
The Front Page
The four columns on the front page were quite a bear using conventional CSS. Not so with flexbox.
We have 4 equal columns nested in a container division.
The CSS
div.container {
display: flex;
flex-wrap : wrap;
justify-content : space-between;
padding : 1dvw 10dvw;
}
div.container .column-front {
flex : 25%;
padding: 0 1dvw
}
The HTML
4 columns front
<div class="container">
<div class="column-front"></div>
<div class="column-front"></div>
<div class="column-front"></div>
<div class="column-front"></div>
</div>
Top