<style>
.container {
  font-size: 100px;
}
img {
  background-color: blue;
  width: 20px;
  height: 20px;
}
.narrowfloat {
  float: left;
  width: 10px;
  height: 20px;
  background-color: green;
}
.widefloat {
  float: left;
  width: 100px;
  height: 25px;
  background-color: green;
}
</style>
<div class="container"><div class="narrowfloat"></div><img><br><div class="widefloat"></div></div>
