@import url(https://fonts.googleapis.com/css?family=Raleway:400,500,800);

body {
  margin: 0;
  height: 100vh;
  background: #222;
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: "Raleway", Arial, sans-serif;
}

.card {
  position: relative;
  width: 320px;
  height: 350px;
  background: white;
  border-radius: 4px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.card:before,
.card:after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 4px;
  background-color: white;
  transition: 0.5s;
  z-index: -1;
}

.card:hover:before {
  transform: rotate(20deg);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
}

.card:hover:after {
  transform: rotate(10deg);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.2);
}

.imgbox {
  position: absolute;
  top: 10px;
  left: 10px;
  bottom: 10px;
  right: 10px;
  background-color: #222;
  transition: 0.5s;
  z-index: 2;
}

.card:hover .imgbox {
  bottom: 80px;
}

.details {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 10px;
  height: 60px;
  text-align: center;
}

h2 {
  margin: 0;
  padding: 0;
  font-weight: 600;
  font-size: 20px;
  color: #777;
  text-transform: uppercase;
}

h2 span {
  font-weight: 500;
  font-size: 16px;
  color: #f38695;
}

img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
