@charset "utf-8";

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
}

body {
  display: flex;
  flex-direction: column;
  align-items: center;
}

#test {
  position: relative;
  width: 100%;
  height: 100vh; /* ← これが大事！ */
  overflow: hidden; /* はみ出し防止（必要に応じて） */
}

/*
.box {
  line-height: 80px;
  height: 80px;
  width: 80px;
  border: 1px solid gray;
}

.box.drop {
  position: absolute;
  top: 40px;
  left: 40px;
  background: url("Band_house.jpg");
  line-height: 80px;
  height: 180px;
  width: 180px;
  background-size: contain;
  border: 1px solid gray;
}
*/


.box.drag {
  background-color: skyblue;
  background: url("pon.jpg");
  background-size: cover;
  background-position: 50% 10%;
}


#dropZone {
    position: relative;  /* 相対位置にして、子要素の位置を基準にする */
    display: flex;
    justify-content: center;  /* 横中央 */
    align-items: center;      /* 縦中央 */
    width: 180px;  /* 画像のサイズに合わせる */
    height: 180px; /* 画像のサイズに合わせる */
}

#centralImage {
    display: block; /* 画像をブロック要素として扱う */
    max-width: 100%; /* 親要素を越えないようにする */
    max-height: 100%;
}

.box.dragging {
  background-color: skyblue;
  opacity: 0.5;
}



/* ちりばめる画像（共通クラス） */
.car, .dog {
  width: 10%;      /* 親要素の幅に対して10% */
  height: auto;    /* 縦横比を維持 */
  position: absolute;
  z-index: 10;
}