*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body{
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
.container{
    position: relative;
    height: 420px;
    width: 320px;
    background-image:url('img/img.jpg');
    background-size: cover;
    background-position: center;
    border-radius: 12px;
    box-shadow: 0 15px 25px rgba(0,0,0,0.1);
    cursor: pointer;
}
.container .heart{
    position: absolute;
    font-size: 40px;
    color: red;
    transform: translate(-50%,-50%);
    opacity: 0;
}
.heart.active{
    animation: anim 0.8s linear forwards;
}
@keyframes anim{
 30%{
    opacity: 1;
    font-size: 80px;
 }
 50%{
    opacity: 1;
    font-size: 60px;
 }
 70%{
    opacity: 1;
    font-size: 70px;
 }
  80%{
    opacity: 1;
    font-size: 60px;
 }
  90%{
    opacity: 1;
    font-size: 60px;
 }
}