JSFiddle - React, Tailwind, and code Playground

by annndrewww

HTML

<section class="top">
        <div class="wrapper-full">
          <h2 class="top-title section-title">
            Today top places to visit
          </h2>
          <div class="top-cards">
            <div class="top-card">
              <div class="top-card-pic">
                <img src="img/top/top-1.jpg" alt="NAGOYA" class="top-card-thumb">
              </div>
              <div class="top-card-stats">
                <h3 class="top-card-title">NAGOYA</h3>
                <div class="top-card-likes">
                  <span class="top-card-likes-value">
                    221
                  </span>
                </div>
                <div class="top-card-comments">
                  <span class="top-card-comments-value">
                    50
                  </span>
                </div>
              </div>
            <p class="top-card-desc"> Jump off balcony, onto stranger's head. Chase ball of string hide when guests come over. Being gorgeous with belly side up i could pee on this.</p>
            </div>
          </div>

        </div>


      </section>

CSS

.top {
  margin-bottom: 86px;
}

.top-cards {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-gap: 57px;
}

.top-title {
  margin-bottom: 54px;
}

.top-card-title {
  font-weight: 500;
  font-size: 18px;
  line-height: 24px;
  color: #000;
  margin: 0 auto 0 0;
}

.top-card-stats {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  position: absolute;
  width: 100%;
  bottom: 0;
  left: 0;
  padding: 16px 25px;
  padding-right: 910px;
}

.top-card-likes {
  font-weight: 500;
  font-size: 16px;
  line-height: 24px;
  color: #000;
  padding-right: 25px;
  background: url(../img/top/like.svg) no-repeat right;
  margin-right: 14px;
}

.top-card-comments {
  font-weight: 500;
  font-size: 16px;
  line-height: 24px;
  color: #000;
  padding-right: 23px;
  background: url(../img/top/comment.svg) no-repeat right;
}