<div class="container">
<div class="item" id="one">One</div>
<div class="item" id="two">Two</div>
<div class="item" id="three">Three has much more content than all of the others.</div>
<div class="item">Four</div>
<div class="item">Five</div>
</div>
.container {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
grid-gap: 20px;
}
#three {
grid-row: 1 / 3;
grid-column: 3 / 4;
z-index: -1;
}
#two {
grid-column: 1 / -1;
grid-row: 1 / 2;
background-color: white;
}
#one {
grid-row: 2 / 3;
grid-column: 1 / 3;
}
.item {
padding: 10px;
border: 5px solid rgb(17, 105, 121);
background-color: rgba(17, 105, 121,.1);
border-radius: 5px;
}
* { box-sizing: border-box; }
body {
font: 1.1em/1.3 Tahoma, Verdana, Segoe, sans-serif;
background-color: #fff;
color: #333;
max-width: 960px;
margin: 1em auto;
}
This Pen doesn't use any external CSS resources.
This Pen doesn't use any external JavaScript resources.