* {
  box-sizing: border-box;
  margin: 0;
}

html,
body {
  width: 100%;
  height: 100%;
  overflow: hidden;
}

.beach {
  position: absolute;
  top: 70px; /* Top bar */
  left: 0;
  width: 100svw;
  height: calc(100vh - 70px);
  overflow: hidden;
}

.beach img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: fill;
}
/*dirtybeach*/
.dirtybeach {
  opacity: 1; /* 透明度を少し下げることで下の画像が見える */
}

/*midbeach*/
.midbeach {
  opacity: 0;
}

/*cleanbeach1*/
.cleanbeach {
  opacity: 0;
}

.gabage {
  width: 30px;
  opacity: 1;
  position: absolute;
}

.wood {
  width: 90px;
  opacity: 1;
  position: absolute;
}

.InsectNet {
  z-index: 1;
  transition-duration: 500ms;
}

.audio {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 100;
}

#waterCanvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 9;
}

.particletext {
  font-size: 20px;
  font-family: "Rounded M+", sans-serif;
  font-weight: bold;
  color: #03a876;
  position: relative;
  white-space: nowrap;
}

.particletext.bubbles > .particle {
  opacity: 0;
  position: absolute;
  background-color: rgba(33, 243, 150, 0.5);
  border-radius: 100%;
  animation: bubbles 3s ease-in infinite;
}

@keyframes bubbles {
  0% {
    opacity: 0;
  }
  20% {
    opacity: 1;
    transform: translate(0, -20%);
  }
  100% {
    opacity: 0;
    transform: translate(0, -300%);
  }
}

.top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px;
  width: 100%;
  position: fixed;
  top: 0;
  z-index: 100;
  box-sizing: border-box;
  background-color: rgba(255, 255, 255, 0.8);
}

/* 爽やかゲージ */
#sawayakaGauge {
  flex-grow: 1;
  margin-right: 10px;
  height: 30px;
  background-color: #d3d3d3;
  border-radius: 15px;
  position: relative;
}

#gaugeFill {
  height: 100%;
  width: 0%;
  background-color: #00bfff;
  border-radius: 15px;
  transition: width 0.5s ease;
}

#gaugePercentage {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 16px;
  font-weight: bold;
  color: #fff;
}

.tools {
  display: flex;
  gap: 10px;
}

.insect-net,
.water-gun {
  width: 50px;
  height: 50px;
  cursor: pointer;
  transition: border 0.2s ease;
}

.insectNet-active,
.waterGun-active {
  border: 3px solid rgb(0, 0, 0);
}

.gunhead {
  width: 60px;
  position: absolute;
  transform-origin: center;
  z-index: 10;
  display: none;
}

.background {
  width: 100%;
  height: 100%;
}

.titleBox {
  position: absolute;
  width: 100%;
  top: 20%;
  left: 50%;
  text-align: center;
  transform: translate(-50%, -20%);
  font-size: 1.4em;
}

.selectButtons {
  display: flex;
  justify-content: space-around;
  width: 250px;
  height: 50px;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.titleButton {
  text-align: center;
  width: 100px;
  height: 50px;
  border-radius: 1000px;
  background: #fae9b8;
}

.explainModal {
  display: none; /* デフォルトでは非表示 */
  position: fixed; /* 画面に固定 */
  z-index: 1; /* 他の要素の上に表示 */
  left: 0;
  top: 0;
  width: 100%; /* 全幅 */
  height: 100%; /* 全高さ */
  overflow: auto; /* スクロール可能 */
  background-color: rgb(0, 0, 0); /* 背景色 */
  background-color: rgba(0, 0, 0, 0.4); /* 透過 */
}

/* モーダルコンテンツ */
.explain-content {
  background-color: #fefefe;
  margin: 15% auto; /* 中央に配置 */
  padding: 20px;
  border: 1px solid #888;
  width: 80%; /* 幅 */
  max-width: 300px;
}

.image_explain {
  width: 100%;
  max-width: 375px;
  border: solid 1px #000000;
}
