@charset "UTF-8";

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

body {
  font-family: 'Hiragino Sans', 'Yu Gothic', sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

header {
  text-align: center;
  margin-bottom: 2rem;
}

main {
  padding: 2rem;
  border-radius: 20px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.2);
  text-align: center;
  min-width: 300px;
  margin: 0 20px;
}

#drawButton {
  font-size: 1.3rem;
  padding: 12px 30px;
  background: #444;
  color: white;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.2);
  margin-bottom: 2rem;
}

#drawButton:hover {
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.25);
  background: #000;
}

#drawButton:active {
  transform: translateY(0);
}

#resultDisplay {
  font-size: 1.5rem;
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  border-radius: 15px;
  background: #EEE;
  border: 2px solid #e9ecef;
}

footer {
  position: fixed;
  bottom: 20px;
  font-size: 0.9rem;
}


/* =========================
   紙吹雪
   ========================= */

.confetti {
  position: fixed;
  top: -20px;
  z-index: 9999;
  pointer-events: none;

  animation-name: confettiFall;
  animation-timing-function: linear;
  animation-fill-mode: forwards;
}


/* 紙吹雪が落ちるアニメーション */

@keyframes confettiFall {

  0% {
    transform: translateY(0) rotate(0deg);
    opacity: 1;
  }

  100% {
    transform: translateY(110vh) rotate(720deg);
    opacity: 0;
  }

}


@media (min-width: 601px) {

  header h1 {
    font-size: 2.5rem;
  }

  main {
    margin: 0;
    padding: 3rem;
  }

  #drawButton {
    font-size: 1.5rem;
    padding: 15px 40px;
  }

  #resultDisplay {
    font-size: 2rem;
  }

}
