.lemon_item{
  width: 150px;
  height: auto;
  aspect-ratio: 699 / 541;
  border-radius: 10px;
  background-image: url("/common/img/dynosaur_1.png");
  background-size: 80% 80%;
  background-position: 0 0;
  background-repeat: no-repeat;
  display: block;
  position: relative;
}
.lemon_item.anime {
  animation-name: upDown;
  animation-iteration-count: infinite;
  animation-duration: 0.15s;
  animation-direction: alternate;
  animation-timing-function: steps(5);
  transition-duration: 0.3s;
  transition-property: transform;
  transition: opacity 0.3s;
}

.lemon_item.anime:hover {
  opacity: 0.6;
}

.lemon_stage {
  position: relative;
  width: 100%;
  height: 100px;         /* ↓ 高さをコンパクトに */
  margin: 1rem 0;        /* ↓ 上下の余白も最小限に */
  display: flex;
  justify-content: center;
  align-items: flex-end;
  z-index: 0;
  overflow: hidden;      /* ↓ アニメがはみ出すのを防ぐ */
}

.lemon_stage > a {
  display: block;
  padding: 3px;
}

.lemon_wrap {
  position: absolute;
  bottom: 5px;            /* ↓ 少しだけ上に浮かせて被りを防止 */
  right: 10%;
  margin-right: 0;
  animation-fill-mode: forwards;
  animation-timing-function: linear;
  animation-duration: 7s;
  animation-iteration-count: 1;
}

.menu_coment {
  font-size: 1.5rem;
  text-align: right;
  margin-top: 0.5rem !important;  /* ← これで下との余白も最小限に */
}

.lemon_wrap[data-order="left"] {
  animation-name: GoLeft;
}
.lemon_wrap[data-order="right"] {
  animation-name: GoRight;
}

[data-order="right"] > .lemon_item {
  transform: rotateY(180deg);
}

@keyframes GoLeft {
  0% {
    right: 10%;
  }
  100% {
    right: 70%;
  }
}
@keyframes GoRight {
  0% {
    right: 80%;
  }
  100% {
    right: 10%;
  }
}

@keyframes upDown {
  0% {
    top: 0;
  }
  100% {
    top: 5px;
  }
}

@media screen and (max-width: 768px) {
  .lemon_stage {
    height: 80px;
    margin: 1rem 0;
  }

  .lemon_item {
    width: 10rem;
  }

  .lemon_wrap {
    animation-duration: 3s;
    bottom: 3px;
  }

  @keyframes GoLeft {
    0% {
      right: 10%;
    }
    100% {
      right: 70%;
    }
  }

  @keyframes GoRight {
    0% {
      right: 80%;
    }
    100% {
      right: 10%;
    }
  }
}
@media screen and (min-width: 769px) {
  .lemon_stage {
    height: 130px; /* または見切れない高さに調整 */
  }
}
