<div class="container">
<div class="row">
<div class="yellow col-sm-12 hidden-md hidden-lg"></div>
<div class="blue col-sm-4 col-md-4"></div>
<div class="yellow col-md-8"></div>
<div class="red col-sm-8 col-md-8"></div>
</div>
</div>
<div class="container">
<div class="row">
<div class="blue col-sm-4 col-md-4">
</div>
<div class="yellow col-sm-12 col-md-8">
</div>
<div class="red col-sm-8 col-md-8">
</div>
</div>
</div>