I have a 2 column CSS-only grid which works, however it causes excess space beneath both columns.
.
If I remove inline-block from each cell the excess space is not so bad however this is needed to prevent the grid wrapping. I presumed the issue was with vertical-align, adding this appears to have made no difference though. Is there any way of preventing this excess space?
.columns {
-webkit-column-gap: 1.5em;
-moz-column-gap: 1.5em;
column-gap: 1.5em;
-webkit-column-fill: auto;
-moz-column-fill: auto;
column-fill: auto;
}
.columns__cell {
break-inside: avoid-column;
column-break-inside: avoid;
display: inline-block;
vertical-align: top;
width: 100%;
}
.columns--2 {
-moz-column-count: 2;
-webkit-column-count: 2;
column-count: 2;
}
Structure:
<div class="column column--2">
<!-- repeated -->
<div class="widget__item poll column__cell">
<div class="widget__head clearfix">
***
</div>
<div class="widget__body">
***
</div>
</div>
<!-- repeated -->
</div>