/* 基本設定用 */
.zen-maru-gothic-regular,
p,
li,
button,
a {
  font-family: "Zen Maru Gothic", sans-serif;
  font-weight: 400;
  font-style: normal;
}
.hachi-maru-pop-regular {
  font-family: "Hachi Maru Pop", cursive;
  font-weight: 400;
  font-style: normal;
}

body {
  background: #E34234;
  color: #2C2C2C;
  /* height: 100vh; */
}

/* アニメーション */
.loader {
  border: 8px solid #f3f3f3;
  border-top: 8px solid #3498db;
  border-radius: 50%;
  width: 60px;
  height: 60px;
  animation: spin 1s linear infinite;
}
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

.fade-in {
  opacity: 0;
  animation: fadeIn 0.8s forwards;
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}


/* もにょもにょ */
.omikuji-area {
  position: relative;
  text-align: center;
  margin: 0 auto;
  min-height: 100vh;
}
.omikuji-area::before {
  content: "";
  display: block;
  width: 70%;
  height: 100%;
  background: #FFFFE0;
  position: absolute;
  left: 0;
  right: 0;
  margin: auto;
}
.bg-area {
  z-index: 0;
  position: absolute;
  width: 100%;
  overflow: hidden;
  height: 100%;
}
.bg-area img:nth-child(1) {
  position: absolute;
  left: -100px;
  top: 10px;
}
.bg-area img:nth-child(2) {
  position: absolute;
  right: -100px;
  top: 50px;
}

/* メイン */
.main-contents {
  position: relative;
  z-index: 10;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  z-index: 10;
  padding: 15px 0;
}
h2 {
  color: #E34234;
  font-size: 70px;
  line-height: 1;
}
h2 br {
  display: none;
}
#image-container {
  width: 810px;
  height: 540px;
  border: 5px solid #FFD700;
  border-radius: 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  background: #fff;
}
#image-container + p {
  font-size: 12px;
}
.result-area {
  border: 5px solid #FFD700;
  border-radius: 20px;
  width: 600px;
  height: 100px;
  margin: 10px auto;
  background: #fff;
  display: flex;
  justify-content: center;
  align-items: center;
  /* flex-direction: column; */
}
.result-area > *:not(:last-child) {
  margin-right: 20px;
}
#text-container {
  color: #E34234;
  font-size: 40px;
  font-weight: bold;
}

.btn-area {
  margin: 20px auto;
}
#gacha-btn {
  display: block;
  padding: 10px 20px;
  background: #E34234;
  color: #FFD700;
  border: 2px solid #E34234;
  font-size: 20px;
  border-radius: 50px;
  position: relative;
  overflow: hidden;
  transition: .3s;
  z-index: 1;
}
#gacha-btn::before {
  content: "";
  width: 120%;
  height: 200%;
  position: absolute;
  top: -50%;
  right: 0;
  z-index: -1;
  background: #FFD700;
  border-radius: 0 100% 100% 0;
  transform: translateX(-100%);
  transition: transform ease .3s;
}
#gacha-btn:hover {
  font-weight: bold;
  color: #E34234;
}
#gacha-btn:hover::before {
  transform: translateX(10%);
}

#tweet-btn {
  display: none;
  padding: 5px 10px;
  background: #2C2C2C;
  color: #fff;
  margin-top: 5px;
  border-radius: 6px;
  font-size: 13px;
}
.fade-in #tweet-btn {
  display: block;
}

.note {
  font-size: 12px;
}
.note a {
  color: #E34234 !important;
}
.note li:not(:last-child) {
  margin-bottom: 3px;
}

/* モーダル全体 */
.modal {
  display: none; /* 初期は非表示 */
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.7);
  justify-content: center;
  align-items: center;
}

/* モーダル内の画像 */
#modal-img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 10px;
}

/* 閉じるボタン */
#modal-close {
  position: absolute;
  top: 20px;
  right: 30px;
  font-size: 40px;
  color: white;
  cursor: pointer;
}


/* sp用 */
.p-sp {
  display: none;
}
@media (max-width: 768px) {
  .p-sp {
    display: block;
  }
  .bg-area {
    height: 100vh;
  }
  .bg-area img:nth-child(1) {
    width: 60%;
    left: -20vw;
    top: 10px;
  }
  .bg-area img:nth-child(2) {
    width: 40%;
    right: -10vw;
    top: 20vh;
  }
  h2 {
    writing-mode: vertical-rl;
    text-orientation: upright;
    font-size: 46px;
    line-height: 1.5;
  }
  .main-contents {
    flex-wrap: nowrap;
  }
  #image-container {
    max-width: 90%;
    height: auto;
    aspect-ratio: 3 / 2;
  }
  #image-container img {
    width: 100%;
  }
  .result-area {
    max-width: 90%;
    min-height: 100px;
  }
}