.grid {
    display: grid;
    grid-template-rows: 
      repeat(5, 180px);
    grid-template-columns: 
      repeat(4, 1fr);
    grid-gap: 5px;
  }
  
  .item:nth-child(1) {
    grid-row: 1 / 4;
    grid-column: 1/3;
  }
  
  .item:nth-child(2) {
    grid-column: 3 / 6;
    grid-row: 1 / 3;
  }
  
  .item:nth-child(3) {
    grid-column: 4 / 4;
    grid-row: 3 / 5;
  }
  
  .item:nth-child(4) {
    grid-column: 3 / 3;
    grid-row: 3 / 5;
  }
  
  .item:nth-child(5) {
    grid-column: 1 / 3;
    grid-row: 4 / 5;
  }
  
  .item:nth-child(6) {
    grid-column: 1 / 3;
    grid-row: 5 / 5;
  }
  
  .item:nth-child(7) {
    grid-column: 3 / 6;
    grid-row: 5 / 5;
  }
  
  /* styling code */
  
  .grid {
    margin:10px auto;
    width: 90%;
  }

  .title-overlay {
      background-color: rgba(0, 0, 0, 0.5);
      padding: 10px;
      position: absolute;
      width: 100%;
      bottom: 0;
      color: #fff;
      display: flex;
  }

  .image-container {
      position: relative;
  }
  
  .grid > .item {
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
  }