body {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  background-color: rgb(221, 161, 207);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.container {
  height: 50vh;
  display: grid;
  place-items: center;
  margin-top: 100px;
}

.envelope-wrapper {
  position: relative;
  background-color: rgb(144, 26, 95);
  box-shadow: 0 0 40px var(--shadow-color);
  cursor: pointer;
}

.envelope {
  position: relative;
  width: 298px;
  height: 230px;
}

.envelope::before {
  content: "";
  position: absolute;
  z-index: 2;
  border-top: 130px solid rgb(189, 52, 146);
  border-right: 150px solid transparent;
  border-left: 150px solid transparent;
  top: 0;
  transform-origin: top;
  transition: all 0.5s ease-in-out 0.7s;
}

.envelope::after {
  content: "";
  position: absolute;
  z-index: 2;
  border-top: 130px solid transparent;
  border-left: 150px solid rgb(240, 94, 192);
  border-right: 150px solid rgb(240, 94, 192);
  border-bottom: 100px solid rgb(246, 105, 206);
  bottom: 0;
}

.letter {
  position: absolute;
  right: 20%;
  bottom: 0;
  width: 54%;
  height: 80%;
  background: rgb(219, 166, 216);
  transition: all 1s ease-in-out;
  padding: 20px 10px;
  box-shadow: 0 0 100px magenta;
  z-index: 0;
  opacity: 0.99;
}

.letter > .text {
  font-family: "Courier New", Courier, monospace;
  font-size: 10px;
  color: black;
  text-align: center;
  font-weight: 300;
  color: rgb(150, 35, 175);
}

.heart {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 15px;
  height: 15px;
  background: rgb(233, 169, 228);
  z-index: 4;
  transform: translate(-50%, -50%) rotate(45deg);
  transition: transform 0.5s ease-in-out 1s;
  box-shadow: 0 0 10px rgb(122, 1, 74);
  cursor: pointer;
}

.heart::before,
.heart::after {
  content: "";
  position: absolute;
  width: 15px;
  height: 15px;
  background: rgb(233, 169, 228);
  border-radius: 50%;
}

.heart::before {
  top: -7.5px;
}

.heart::after {
  right: 7.5px;
}

.flap .envelope::before {
  z-index: -10;
  transform: rotateX(180deg);
}

.flap .letter {
  bottom: 100px;
  transform: scale(1.5);
  opacity: 1;
  transition-delay: 1s;
}

.flap .heart {
  transform: rotate(90deg);
  transition-delay: 0.4s;
}

img {
  position: absolute;
  top: 0;
  width: 25%;
}
.cake-container {
  text-align: center;
  margin-top: 50px;
  display: flex;
  flex-direction: column;
}

.cake {
  position: relative;
  width: 200px;
  height: 150px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  flex-direction: column;
}

.layer {
  width: 200px;
  height: 50px;
  background: radial-gradient(circle, pink, rgb(186, 98, 155));
  border: 3px solid #d2691e;
  position: relative;
  margin-top: -3px;
}

.layer.top {
  background: radial-gradient(circle, pink, rgb(186, 98, 155));
  width: 150px;
}

.layer.middle {
  width: 180px;
}

.layer.bottom {
  width: 200px;
}

.candles {
  display: flex;
  justify-content: space-evenly;
  position: absolute;
  top: -30px;
  width: 100%;
}

.candle {
  width: 10px;
  height: 30px;
  background: white;
  position: relative;
  border-radius: 2px;
}

.flame {
  width: 10px;
  height: 10px;
  background: orange;
  position: absolute;
  top: -12px;
  left: 0;
  border-radius: 50%;
  box-shadow: 0 0 10px orange;
  animation: flicker 0.2s infinite;
}

@keyframes flicker {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.8;
    transform: scale(1.2);
  }
}

.candle.off .flame {
  display: none;
}

.message {
  font-size: 14px;
  color: #333;
  margin-top: 20px;

}

