<div class="parent">
  <div class="child child01">01</div>
  <div class="child child02">02</div>
  <div class="child child03">03</div>
  <div class="child child04">04</div>
  <div class="child child05">05</div>
  <div class="child child06">06</div>
  <div class="child child07">07</div>
  <div class="child child08">08</div>
  <div class="child child09">09</div>
  <div class="child child10">10</div>
</div><!-- /.parent -->
.parent {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
  flex-wrap: wrap;
  -ms-flex-pack: distribute;
  justify-content: space-around;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
}

/* 共通設定 */
.child {
  color: #fff;
  text-align: center;
  line-height: 100px;
  width: 100px;
  height: 100px;
  background-color: #777;
  margin: 10px;
}

.child01 {
  line-height: 50px;
  height: 50px;
}

.child02 {
  line-height: 30px;
  height: 30px;
  -webkit-box-ordinal-group: 2;
  -ms-flex-order: 1;
  order: 1;
}

.child03 {
  line-height: 70px;
  height: 70px;
  -webkit-box-ordinal-group: 0;
  -ms-flex-order: -1;
  order: -1;
}

.child04 {
  line-height: 40px;
  height: 40px;
}

.child05 {
  line-height: 80px;
  height: 80px;
  -webkit-box-ordinal-group: 2;
  -ms-flex-order: 1;
  order: 1;
}

.child06 {
  line-height: 60px;
  height: 60px;
  
}

.child07 {
  line-height: 90px;
  height: 90px;
  -webkit-box-ordinal-group: 0;
  -ms-flex-order: -1;
  order: -1;
}

.child08 {
  line-height: 50px;
  height: 50px;
}

.child09 {
  line-height: 70px;
  height: 70px;
}

.child10 {
  line-height: 100px;
  height: 100px;
}

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.