I am new to flexbox.I need to display dynamic rows and all my columns should be aligned vertically.In the below example all my red boxes should be the same width.Can someone review the below code and let me know what am i missing?
.vc {
display: flex;
flex-direction: column;
justify-content: space-between;
}
.container {
display: flex;
}
.red {
background: orangered;
display: flex;
flex-direction: row;
}
.green {
background: yellowgreen;
}
.blue {
background: steelblue;
}
.container div {
font-size: 5vw;
padding: .5em;
color: white;
flex: 1;
}
<div class="vc">
<div class="container">
<div class="red">1
<div class="green">1a</div>
<div class="blue">1b080808098080</div>
</div>
<div class="green">2</div>
<div class="blue">3</div>
</div>
<div class="container">
<div class="red">1
<div class="green">1a</div>
<div class="blue">1b080808</div>
</div>
<div class="green">2</div>
<div class="blue">3</div>
</div>
</div>