* {
  padding: 0;
  margin: 0;
  box-sizing: border-box;
  font-family: 'Poppins', sans-serif;
}

.card-wrapper {
  width: 1010px;
  height: 682px;
  display: flex;
  justify-content: center;
  align-items: center;
}

body {
  background-color: #fff;
  display: flex;
  height: 100vh;
  justify-content: center;
  align-items: center;
  width: 100%;
  overflow: hidden;
}
.card {
  width: 640px;
  height: 400px;
  -webkit-perspective: 1200px;
  perspective: 1200px;
  transition: transform 1.2s;
}
.card.flipped {
  transform: rotate(-5deg);
}
.card.flipped .outside {
  transform: rotateY(-150deg);
}

.outside,
.inside {
  height: 100%;
  width: 50%;
  position: absolute;
  left: 50.1%;
}
.inside {
  background: linear-gradient(to right, #e7e7e7, #ffffff 30%);
  line-height: 3;
  padding: 0 20px;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  left: 50%;
}
.outside {
  -webkit-transform-style: preserve-3d;
  transform-style: preserve-3d;
  z-index: 1;
  transform-origin: left;
  transition: 2s;
  cursor: pointer;
}
.front,
.back {
  height: 100%;
  width: 100%;
  position: absolute;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  transform: rotateX(0deg);
  border: 1px solid rgba(0, 0, 0, 0.8);
}
.front {
  display: flex;
  height: 100%;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  background-color: #f79bb4;
}

.back {
  transform: rotateY(180deg);
  background: linear-gradient(to left, #e7e7e7, #ffffff 30%);
  padding: 10px;
}
.outside p {
  font-size: 90px;
  text-align: center;
  letter-spacing: 0;
  color: #fff;
  font-weight: 900;
  line-height: 90px;
  opacity: 0;
  transition: 1s;
}

.outside p.visible {
  opacity: 1;
}

.outside p + p {
  margin-top: -10px;
}

.inside h1 {
  font-size: 32px;
  line-height: 42px;
}

.inside p {
  position: relative;
  font-size: 12px;
  line-height: 20px;
  top: 50px;
}

.front,
.back,
.inside {
  border: 1px solid rgba(0, 0, 0, 0.1);
  box-shadow: rgba(0, 0, 0, 0.2) 0px 4px 12px;
}

.mom {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

@media screen and (min-width: 901px) {
  .card-wrapper {
    transform: scale(1.3);
  }
}

@media screen and (min-width: 1001px) {
  .card-wrapper {
    transform: scale(1.5);
  }
}

@media screen and (max-width: 900px) {
  .card-wrapper {
    transform: scale(1.2);
  }
}

@media screen and (max-width: 800px) {
  .card-wrapper {
    transform: scale(1);
  }
}

@media screen and (max-width: 700px) {
  .card-wrapper {
    transform: scale(0.85);
  }
}

@media screen and (max-width: 600px) {
  .card-wrapper {
    transform: scale(0.7);
  }
}

@media screen and (max-width: 500px) {
  .card-wrapper {
    transform: scale(0.6);
  }
}

@media screen and (max-width: 400px) {
  .card-wrapper {
    transform: scale(0.5);
  }
}
