JSFiddle - React, Tailwind, and code Playground

by luka kupunia

HTML

<div class="box">
  <div class="heading">Lisi Lake <span></span></div>
  <div class="img">
  <span></span>
    <img src="https://picsum.photos/500/300" alt="">
  </div>
  <div class="down">2018 <span></span></div>
  <div class="p">Lorem ipsum dolor sit amet, consectetur adipisicing elit. Consequuntur cum fuga, nemo sunt molestias, optio, animi pariatur, nihil veniam nam voluptatem enim provident esse? Quam similique, a deleniti explicabo qui! <span></span></div>
</div>
<div class="box">
  <div class="heading">Shopping Card<span></span></div>
  <div class="img">
  <span></span>
    <img src="https://picsum.photos/500/400" alt="">
  </div>
  <div class="down">Best Shoes Best Shoe Best <span></span></div>
  <div class="p">Lorem ipsum dolor sit amet, consectetur adipisicing elit. Consequuntur cum fuga, nemo sunt molestias, optio, animi pariatur, nihil veniam nam voluptatem enim provident esse? Quam similique, a deleniti explicabo qui! <span></span></div>
</div>
<div class="box">
  <div class="heading">Shopping Card<span></span></div>
  <div class="img">
  <span></span>
    <img src="https://picsum.photos/500/400" alt="">
  </div>
  <div class="down">Best Shoes Best Shoe Best <span></span></div>
  <div class="p">Lorem ipsum dolor sit amet, consectetur adipisicing elit. Consequuntur cum fuga, nemo sunt molestias, optio, animi pariatur, nihil veniam nam voluptatem enim provident esse? Quam similique, a deleniti explicabo qui! <span></span></div>
</div>
<div class="box">
  <div class="heading">Shopping Card<span></span></div>
  <div class="img">
  <span></span>
    <img src="https://picsum.photos/500/400" alt="">
  </div>
  <div class="down">Best Shoes Best Shoe Best <span></span></div>
  <div class="p">Lorem ipsum dolor sit amet, consectetur adipisicing elit. Consequuntur cum fuga, nemo sunt molestias, optio, animi pariatur, nihil veniam nam voluptatem enim provident esse? Quam similique, a deleniti explicabo qui! <span></span></div>
</div>

CSS

body {
  margin: 0;
  background: black;
}
* {
  box-sizing: border-box;
  color: white;
}
div.box {
  width: 300px;
  display: inline-block;
  margin: 20px;
}
div.heading {
  font-size: 24px;
  font-weight: bold;
  padding: 20px;
  padding-left: 0px;
  position: relative;
  display: inline-block;
  -webkit-clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
  clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
  animation: one 1s cubic-bezier(0.82, 0.04, 0.25, 1) forwards;
}
div.heading span {
  position: absolute;
  width: 100%;
  height: calc(100% - 40px);
  background: #844e84;
  top: 20px;
  left: 0;
  animation: two 1s forwards 1.3s;
}
div.img {
  width: 100%;
  padding-top: 60%;
  position: relative;
  -webkit-clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
  clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
  animation: one 1s cubic-bezier(0.82, 0.04, 0.25, 1)  forwards 0.1s;
}
div.img span {
  position: absolute;
  width: 100%;
  height: 100%;
  background: #844e84;
  top: 0;
  left:0;
  z-index: 2;
  animation: two 1s forwards 1.3s;
}
img {
  position: absolute;
  width: 100%;
  height: auto;
  top: 0;
}
div.down {
  font-size: 22px;
  padding: 10px;
  padding-left: 0;
  position: relative;
  display: inline-block;
  -webkit-clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
  clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
  animation: one 1s cubic-bezier(0.82, 0.04, 0.25, 1) forwards 0.2s;
}
div.down span {
  position: absolute;
  width: 100%;
  height: calc(100% - 20px);
  background: #844e84;
  top: 10px;
  left: 0;
  animation: two 1s forwards 1.3s;
}
div.p {
  position: relative;
  font-size: 14px;
  -webkit-clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
  clip-path: polygon(0 0, 0 0, 0 100%, 0 100%);
  animation: one 1s cubic-bezier(0.82, 0.04, 0.25, 1) forwards 0.3s;
}
div.p span {
  position: absolute;
  width: 100%;
  height: 100%;
  background: #844e84;
  top: 0;
  left:0;
  z-index: 2;
  animation: two 1s forwards 1.3s;
}

@keyframes one {
  from {
-webkit-clip-path:...