@charset "utf-8";

body{
  margin: 0;
  padding: 0;

  background-color: black;
  min-height: 100vh;
  display: flex;
  justify-content: center; /* 横中央寄せ */
  z-index: 0;
}

.container {
  width: 100%;
  max-width: 640px;
  margin: 0 auto;
  padding: 0;       /* 横の余白は好みで調整 */
  box-sizing: border-box;

  background-color: rgba(0, 0, 0, 0.7);
}

@media (max-width: 640px) {
  .container {
    max-width: 100%;
  }
}


/* loader */

#loader{
  position:fixed;
  inset:0;                            /* top:0; right:0; bottom:0; left:0 */
  background: linear-gradient(
    to bottom,
    #9bd8f7 0%,
    #d5ebf7 25%,
    #e3f0f7 50%,
    #d5ebf7 75%,
    #9bd8f7 100%
  );
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:center;
  gap:20px;
  z-index:10000;                      /* ページ内で最前面に */
  transition:opacity .6s ease;        /* 後で JS で fadeOut */
}



/* シンプルな CSS スピナー例（お好みで差し替え可） */
/* ========= stylish double‑ring spinner ========= */
#loader .spinner{
  width: 72px;                 /* サイズはお好みで */
  height: 72px;
  position: relative;
}

#loader .spinner::before,
#loader .spinner::after{
  content:"";
  position:absolute;
  inset:0;                     /* 親と同サイズ */
  border-radius:50%;
  border:4px solid transparent;/* 枠線を下地に */
}

/* 外輪：明るい水色 ─ 時計回り */
#loader .spinner::before{
  border-top-color:#00b4ff;    /* 上下だけ色 */
  border-bottom-color:#00b4ff;
  animation:spin 1.2s linear infinite;
}

/* 内輪：濃い水色 ─ 反時計回り */
#loader .spinner::after{
  border-left-color:#0077ff;   /* 左右だけ色 */
  border-right-color:#0077ff;
  inset:8px;                   /* ひと回り小さく */
  animation:spinReverse 1.2s linear infinite;
}

/* 回転アニメーション */
@keyframes spin{
  to{ transform:rotate(360deg); }
}
@keyframes spinReverse{
  to{ transform:rotate(-360deg); }
}


#loader .loading-text{
  color: rgb(6, 67, 111);
  font-family:"Times New Roman",serif;
  font-weight: 1000;
  letter-spacing:2px;
  font-size: 26px;
}

/* フェードアウト時に透明＋クリック不可にする */
#loader.hide{
  pointer-events:none;
  opacity:0;
}


.loader-logo > img{
  max-width: 300px;
  max-height: 300px;

  animation:logoZoom 3s ease forwards;
}




/* top */

.top{
  width: 100%;
  position: relative;
}

.top-background{
  width: 100%;
  z-index: 990;
}
.top-background > img{
  width: 100%;
  height: auto;
  display: block;
}

.top-title{
  width: 100%;
  position: absolute;
  z-index: 992;

  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}
.top-title > img{
  width: 100%;
  height: auto;
}




/* character */

.character{
  width: 100%;
  /* height: 750px; */
  /* background-color:red; */
  position: relative;

}


.character-head{
  width: 100%;
  height: 60px;

  font-family: "Times New Roman", Times, serif;
  font-size: 26px;
  font-weight: 1000;
  color: rgba(255, 255, 255, 1);
  background-color: rgba(0, 0, 0, 0.7);

  position: relative;
  display: flex;
  align-items: center;

}

.character-heading{
  margin: 0 0 0 10px;
}
.character-head::before,
.character-head::after{
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: rgba(255, 255, 255, 1.0);
}
.character-head::before{
  top: 0;
  box-shadow: 0 4px rgba(255, 255, 255, 1.0);
}
.character-head::after{
  bottom: 0;
  box-shadow: 0 -4px rgba(255, 255, 255, 1.0);
}


.character-content{
  width: 100%;
  max-width: 1000px;        /* 任意で調整 */

  margin: 0 auto;
  padding: 4rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;               /* キャラクター同士の間隔 */


}

/* 1 キャラ分の行 */
.character-item {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  gap: 2rem;
}

.character-image img {
  /* max-width: 45%; */
  width: 130px;            /* 縦長比率を保つなら height を auto に */
  height: auto;
  border-radius: 12px;     /* 角丸 */
  border: 1px solid #ffffff;
  object-fit: cover;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15); /* 任意 */
}

.character-text {
  flex: 1;
  color: #ffffff;          /* 背景が暗い場合を想定 */
}

.character-name {
  margin: 0;
  font-size: 1.7rem;
  line-height: 1.3;
  font-weight: 1000;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  /* font-family: "Times New Roman", Times, serif; */
}
.character-name > span{
  font-size: 1.0rem;
  font-weight: 700;
}
.character-role{
  margin: 3px 0;
  font-size: 1.0rem;
  line-height: 1.3;
  font-weight: 500;

  /* font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif; */
  font-family: "Times New Roman", Times, serif;
}

.character-divider {
  width: 100%;
  height: 1px;
  border: none;
  background-color: #ffffff;
  margin: 0.5rem 0 1rem;
}

.character-description {
  margin: 0;
  font-size: 1rem;
  line-height: 1.7;

  font-family: "Times New Roman", Times, serif;
}



.character-content::after{
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: rgba(255, 255, 255, 1.0);
}
.character-content::after{
  bottom: 0;
  box-shadow: 0 -4px rgba(255, 255, 255, 1.0);
}





/* next-button */

.next-button-wrapper {
  width: 100%;
  height: 150px;
  text-align: center;
  margin: 4rem 0;          

  inset: 0;                 
  display: flex;
  justify-content: center; 
  align-items: center;     
  margin: 0;               
  pointer-events: none;   

  /* background-color: red; */
}

.next-button {
  width: 60px;
  height: 60px;

  color: white;
  border: 1px solid #ffffff;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.25s;

  pointer-events: all;

  
}

.next-button:hover {
  background: rgba(255,255,255,0.1);
}

.next-button .chevron {
  width: 28px;              /* サイズはお好みで */
  height: 28px;

  display: inline-block;
  font-size: 1.4rem;
  transform: rotate(90deg);  /* 「>>」を下向きに */
  color: #ffffff;
  pointer-events: none;
}







/* step1 */


.step1 {
  display: none;            /* 初期は隠す */
  position: relative;
  /* background-color: rgba(0, 0, 0, 0.7); */
}

/* ===== LINE風ストーリー枠 ===== */
.step1-story {
  width: 100%;
  margin-top: 50px;
  /* max-width: 640px; */
  /* margin: 0 auto; */
  padding: 1rem 0.5rem 4rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;

  /* background-color: red; */
}

/* --- ナレーション吹き出し --- */
.step1-text {
  align-self: center;
  max-width: 80%;
  padding: 0.8rem 1.2rem;
  background: rgba(0,0,0,0.6);
  color: #ffffff;
  border-radius: 20px;
  font-size: 0.95rem;
  line-height: 1.6;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 600;
}

/* --- コメント共通 --- */
.step1-comment {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  font-size: 0.95rem;
}

/* アイコンと名前 */
.step1-comment .icon {
  text-align: center;
  width: 64px;
}

.step1-comment .icon img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid #ffffff;
}

.step1-comment .icon-name {
  margin: 0.1rem 0 0;
  font-size: 0.75rem;
  color: #ffffff;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 600;
  font-size: 14px;
}

/* 吹き出し */
.comment-text {
  position: relative;
  max-width: 70%;
  padding: 0.9rem 1.1rem;
  background: white;
  color: black;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 1000;

  border-radius: 20px; /* 左アイコン用 */
  line-height: 1.6;
}

/* 吹き出しの矢印（左向き） */
.comment-text::before {
  content: '';
  position: absolute;
  left: -6px;
  top: 15px;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-right: 8px solid white;
}
/* 右寄せにする character1 用調整 */
.step1-comment.character1 {
  /* flex-direction: row-reverse; */
  justify-content: flex-end; 
}
.step1-comment.character1 .icon {
  order: 2;
}
.step1-comment.character1 .comment-text {
  background: #50db7a;
  border-radius: 20px; /* 右アイコン用 */
}
.step1-comment.character1 .comment-text::before {

  left: auto;
  right: -6px;
  border-right: none;
  border-left: 8px solid #50db7a;

}

.comment-image{
  max-width: 70%;       /* テキスト幅と同程度に収める */
  flex-shrink: 1;
}
.comment-image img{
  width: 100%;
  height: auto;
  border-radius: 14px;  /* 角を少し丸める */
  /* border: 1px solid #ffffff; */
  display: block;
}



/* step1-question */

.step1-question{
  width: 100%;
  /* background-color: red; */

}

/* ===================== ミッション枠 ===================== */
.mission-fieldset{
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;

  border: 1px solid #fff;
  padding: 1rem;             /* 上下を少し厚めに */
  margin: 2.5rem 20px;
  overflow: hidden;               /* 後述のグラデ線を切り取る */
  backdrop-filter: blur(2px);     /* 背景にほんのりガラス感（任意）*/

  
}
.mission-fieldset legend{
  font-size: 20px;
  font-weight: 700;
  font-family: "Times New Roman", Times, serif;


  padding: 0 8px;
  color: #ffffff;
  font-weight: 700;
  letter-spacing: 0.05em;
}
.mission-text{
  color: white;
  font-size: 20px;
  font-weight: 1000;
  font-family: "Times New Roman", Times, serif;
}

.answer-button-group {
  display: flex;
  justify-content: center;
  gap: 1rem;
  width: 100%;
}



/* ===================== 解答入力 ===================== */
.step1-answer{
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  max-width: 400px;  

  padding: 0 20px 30px;
  margin: 0 auto;
  align-items: center;
}
#step1Input{
  width: 100%;
  height: 44px;
  padding: 0.6rem 0.8rem;
  border: 1px solid #ffffff;
  border-radius: 6px;
  background: rgba(255,255,255,0.1);
  color: #ffffff;
  font-size: 20px;
}
#step1Input::placeholder{
  color: rgba(255,255,255,0.6);
}
#step1Submit{
  align-items: center;
  width: 40%;
  height: 44px;

  padding: 0.4rem 1.4rem;

  background: #ffffff;
  color: #000;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 20px;
  font-weight: 700;
  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
}
#step1Submit:hover{
  background: #e0e0e0;
}

.hint-button {
  display: flex;
  justify-content: center;
  align-items: center;

  width: 40%;
  height: 44px;
  padding: 0.4rem 1.4rem;
  background: #ffffff;
  color: #000;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 20px;
  font-weight: 700;
  text-decoration: none;
  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
}
.hint-button:hover {
  background: #e0e0e0;
}



.step1::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;                               /* ← これが前にないと効かない */
  width: 100%;
  height: 2px;
  background-color: rgba(255, 255, 255, 1.0);
  box-shadow: 0 -4px rgba(255, 255, 255, 1.0); /* 上方向の影 */
}




/* step2 */


.step2 {
  display: none;            /* 初期は隠す */
  position: relative;
  /* background-color: rgba(0, 0, 0, 0.7); */
}

/* ===== LINE風ストーリー枠 ===== */
.step2-story {
  width: 100%;
  margin-top: 50px;
  /* max-width: 640px; */
  /* margin: 0 auto; */
  padding: 1rem 0.5rem 4rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;

  /* background-color: red; */
}

/* --- ナレーション吹き出し --- */
.step2-text {
  align-self: center;
  max-width: 80%;
  padding: 0.8rem 1.2rem;
  background: rgba(0,0,0,0.6);
  color: #ffffff;
  border-radius: 20px;
  font-size: 0.95rem;
  line-height: 1.6;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 600;
}

/* --- コメント共通 --- */
.step2-comment {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  font-size: 0.95rem;
}

/* アイコンと名前 */
.step2-comment .icon {
  text-align: center;
  width: 64px;
}

.step2-comment .icon img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid #ffffff;
}

.step2-comment .icon-name {
  margin: 0.1rem 0 0;
  font-size: 0.75rem;
  color: #ffffff;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 600;
  font-size: 14px;
}

/* 吹き出し */
.comment-text {
  position: relative;
  max-width: 70%;
  padding: 0.9rem 1.1rem;
  background: white;
  color: black;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 1000;

  border-radius: 20px; /* 左アイコン用 */
  line-height: 1.6;
}

/* 吹き出しの矢印（左向き） */
.comment-text::before {
  content: '';
  position: absolute;
  left: -6px;
  top: 15px;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-right: 8px solid white;
}
/* 右寄せにする character1 用調整 */
.step2-comment.character1 {
  /* flex-direction: row-reverse; */
  justify-content: flex-end; 
}
.step2-comment.character1 .icon {
  order: 2;
}
.step2-comment.character1 .comment-text {
  background: #50db7a;
  border-radius: 20px; /* 右アイコン用 */
}
.step2-comment.character1 .comment-text::before {

  left: auto;
  right: -6px;
  border-right: none;
  border-left: 8px solid #50db7a;

}



/* step2-question */

.step2-question{
  width: 100%;
  /* background-color: red; */

}

/* ===================== ミッション枠 ===================== */
.mission-fieldset{
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;

  border: 1px solid #fff;
  padding: 1rem;             /* 上下を少し厚めに */
  margin: 2.5rem 20px;
  overflow: hidden;               /* 後述のグラデ線を切り取る */
  backdrop-filter: blur(2px);     /* 背景にほんのりガラス感（任意）*/

  
}
.mission-fieldset legend{
  font-size: 20px;
  font-weight: 700;
  font-family: "Times New Roman", Times, serif;


  padding: 0 8px;
  color: #ffffff;
  font-weight: 700;
  letter-spacing: 0.05em;
}
.mission-text{
  color: white;
  font-size: 20px;
  font-weight: 1000;
  font-family: "Times New Roman", Times, serif;
}

/* ===================== 解答入力 ===================== */
.step2-answer{
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  max-width: 400px;  

  padding: 0 20px 30px;
  margin: 0 auto;
  align-items: center;
}
#step2Input{
  width: 100%;
  height: 44px;
  padding: 0.6rem 0.8rem;
  border: 1px solid #ffffff;
  border-radius: 6px;
  background: rgba(255,255,255,0.1);
  color: #ffffff;
  font-size: 20px;
}
#step2Input::placeholder{
  color: rgba(255,255,255,0.6);
}
#step2Submit{
  align-items: center;
  width: 40%;
  height: 44px;

  padding: 0.4rem 1.4rem;

  background: #ffffff;
  color: #000;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 20px;
  font-weight: 700;
}
#step2Submit:hover{
  background: #e0e0e0;
}



.step2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;                               /* ← これが前にないと効かない */
  width: 100%;
  height: 2px;
  background-color: rgba(255, 255, 255, 1.0);
  box-shadow: 0 -4px rgba(255, 255, 255, 1.0); /* 上方向の影 */
}





/* step3 */


.step3 {
  display: none;            /* 初期は隠す */
  position: relative;
  /* background-color: rgba(0, 0, 0, 0.7); */
}

/* ===== LINE風ストーリー枠 ===== */
.step3-story {
  width: 100%;
  margin-top: 50px;
  /* max-width: 640px; */
  /* margin: 0 auto; */
  padding: 1rem 0.5rem 4rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;

  /* background-color: red; */
}

/* --- ナレーション吹き出し --- */
.step3-text {
  align-self: center;
  max-width: 80%;
  padding: 0.8rem 1.2rem;
  background: rgba(0,0,0,0.6);
  color: #ffffff;
  border-radius: 20px;
  font-size: 0.95rem;
  line-height: 1.6;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 600;
}

/* --- コメント共通 --- */
.step3-comment {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  font-size: 0.95rem;
}

/* アイコンと名前 */
.step3-comment .icon {
  text-align: center;
  width: 64px;
}

.step3-comment .icon img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid #ffffff;
}

.step3-comment .icon-name {
  margin: 0.1rem 0 0;
  font-size: 0.75rem;
  color: #ffffff;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 600;
  font-size: 14px;
}

/* 吹き出し */
.comment-text {
  position: relative;
  max-width: 70%;
  padding: 0.9rem 1.1rem;
  background: white;
  color: black;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 1000;

  border-radius: 20px; /* 左アイコン用 */
  line-height: 1.6;
}

/* 吹き出しの矢印（左向き） */
.comment-text::before {
  content: '';
  position: absolute;
  left: -6px;
  top: 15px;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-right: 8px solid white;
}
/* 右寄せにする character1 用調整 */
.step3-comment.character1 {
  /* flex-direction: row-reverse; */
  justify-content: flex-end; 
}
.step3-comment.character1 .icon {
  order: 2;
}
.step3-comment.character1 .comment-text {
  background: #50db7a;
  border-radius: 20px; /* 右アイコン用 */
}
.step3-comment.character1 .comment-text::before {

  left: auto;
  right: -6px;
  border-right: none;
  border-left: 8px solid #50db7a;

}



/* step3-question */

.step3-question{
  width: 100%;
  /* background-color: red; */

}

/* ===================== ミッション枠 ===================== */
.mission-fieldset{
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;

  border: 1px solid #fff;
  padding: 1rem;             /* 上下を少し厚めに */
  margin: 2.5rem 20px;
  overflow: hidden;               /* 後述のグラデ線を切り取る */
  backdrop-filter: blur(2px);     /* 背景にほんのりガラス感（任意）*/

  
}
.mission-fieldset legend{
  font-size: 20px;
  font-weight: 700;
  font-family: "Times New Roman", Times, serif;


  padding: 0 8px;
  color: #ffffff;
  font-weight: 700;
  letter-spacing: 0.05em;
}
.mission-text{
  color: white;
  font-size: 20px;
  font-weight: 1000;
  font-family: "Times New Roman", Times, serif;
}

/* ===================== 解答入力 ===================== */
.step3-answer{
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  max-width: 400px;  

  padding: 0 20px 30px;
  margin: 0 auto;
  align-items: center;
}
#step3Input{
  width: 100%;
  height: 44px;
  padding: 0.6rem 0.8rem;
  border: 1px solid #ffffff;
  border-radius: 6px;
  background: rgba(255,255,255,0.1);
  color: #ffffff;
  font-size: 20px;
}
#step3Input::placeholder{
  color: rgba(255,255,255,0.6);
}
#step3Submit{
  align-items: center;
  width: 40%;
  height: 44px;

  padding: 0.4rem 1.4rem;

  background: #ffffff;
  color: #000;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 20px;
  font-weight: 700;
}
#step3Submit:hover{
  background: #e0e0e0;
}



.step3::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;                               /* ← これが前にないと効かない */
  width: 100%;
  height: 2px;
  background-color: rgba(255, 255, 255, 1.0);
  box-shadow: 0 -4px rgba(255, 255, 255, 1.0); /* 上方向の影 */
}




/* step4 */


.step4 {
  display: none;            /* 初期は隠す */
  position: relative;
  /* background-color: rgba(0, 0, 0, 0.7); */
}

/* ===== LINE風ストーリー枠 ===== */
.step4-story {
  width: 100%;
  margin-top: 50px;

  position: relative;
  
  /* max-width: 640px; */
  /* margin: 0 auto; */
  padding: 1rem 0.5rem 4rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;

  /* background-color: red; */
}

/* --- ナレーション吹き出し --- */
.step4-text {
  align-self: center;
  max-width: 80%;
  padding: 0.8rem 1.2rem;
  background: rgba(0,0,0,0.6);
  color: #ffffff;
  border-radius: 20px;
  font-size: 0.95rem;
  line-height: 1.6;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 600;
}

.step4-fin {
  align-self: center;
  max-width: 80%;
  padding: 0.8rem 1.2rem;
  color: #ffffff;

  font-size: 2.5rem;
  line-height: 1.6;

  /* font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif; */
  font-family: "Times New Roman", Times, serif;
  font-weight: 600;
  letter-spacing: 3px;
}

/* --- コメント共通 --- */
.step4-comment {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
  font-size: 0.95rem;
}

/* アイコンと名前 */
.step4-comment .icon {
  text-align: center;
  width: 64px;
}

.step4-comment .icon img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid #ffffff;
}

.step4-comment .icon-name {
  margin: 0.1rem 0 0;
  font-size: 0.75rem;
  color: #ffffff;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 600;
  font-size: 14px;
}

/* 吹き出し */
.comment-text {
  position: relative;
  max-width: 70%;
  padding: 0.9rem 1.1rem;
  background: white;
  color: black;

  font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif;
  font-weight: 1000;

  border-radius: 20px; /* 左アイコン用 */
  line-height: 1.6;
}

/* 吹き出しの矢印（左向き） */
.comment-text::before {
  content: '';
  position: absolute;
  left: -6px;
  top: 15px;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-right: 8px solid white;
}
/* 右寄せにする character1 用調整 */
.step4-comment.character1 {
  /* flex-direction: row-reverse; */
  justify-content: flex-end; 
}
.step4-comment.character1 .icon {
  order: 2;
}
.step4-comment.character1 .comment-text {
  background: #50db7a;
  border-radius: 20px; /* 右アイコン用 */
}
.step4-comment.character1 .comment-text::before {

  left: auto;
  right: -6px;
  border-right: none;
  border-left: 8px solid #50db7a;

}

.step4-story::after{
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: rgba(255, 255, 255, 1.0);
}
.step4-story::after{
  bottom: 0;
  box-shadow: 0 -4px rgba(255, 255, 255, 1.0);
}





/* cleaer */


.clear {
  display: none;            /* 初期は隠す */
  position: relative;
  /* background-color: rgba(0, 0, 0, 0.7); */

  /* height: 300px; */
  padding-bottom: 30px;
  
}

.clear-image{
  max-width: 80%;
  margin: 3rem auto;
}
.clear-image img{
  width: 100%;
  height: auto;

  display: block;
  border-radius: 14px;
  border: 1px solid #ffffff;
  object-fit: contain;
}



/* back */

.back {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;

  padding-bottom: 50px;
}


.back-buttons{
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
}
.back-button {
  width: 200px;
  height: 50px;

  display: flex; /* ← 追加 */
  justify-content: center; /* 横方向中央 */
  align-items: center;     /* 縦方向中央 */

  padding: 14px 40px;
  border: 1px solid white;
  color: white;
  background-color: transparent;
  font-size: 16px;
  font-weight: bold;
  /* font-family: "Yu Gothic", "ヒラギノ角ゴ ProN", "メイリオ", sans-serif; */
  font-family: "Hiragino Mincho ProN", "Yu Mincho", "MS PMincho", "serif";

  letter-spacing: 2px;
  text-decoration: none;
  border-radius: 30px;
  transition: background-color 0.3s, transform 0.2s;
}
.back-button:hover {
  background-color: rgba(255, 255, 255, 0.2);
  transform: scale(1.05);
}


.clear::after{
  content: "";
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: rgba(255, 255, 255, 1.0);
}
.clear::after{
  bottom: 0;
  box-shadow: 0 -4px rgba(255, 255, 255, 1.0);
}











/* ===== 画像オーバーレイ全体 ===== */
#imageOverlay {
  position: fixed;
  inset: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(0,0,0,0.9);
  z-index: 99999;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.3s ease;
}

#imageOverlay.show {
  visibility: visible;
  opacity: 1;
}

/* 拡大表示する画像 */
#imageOverlay #overlayImg {
  max-width: 90vw;
  max-height: 90vh;
  border-radius: 14px;
  object-fit: contain;
}

/* ✕ アイコン */
#overlayClose {
  position: absolute;
  top: 16px;
  right: 20px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  line-height: 0;  
}
#overlayClose svg{
  width: 40px;             /* お好みで調整 */
  height: 40px;
  filter: drop-shadow(0 0 3px #000);
  transition: filter 0.2s;
}
#overlayClose:hover {
  filter: drop-shadow(0 0 6px #f66);
}

/* 保存ボタン */
#overlaySave{
  position: absolute;
  bottom: 16px;
  right: 20px;
  cursor: pointer;
  line-height: 0;
}
#overlaySave svg{
  width: 40px;
  height: 40px;
  filter: drop-shadow(0 0 3px #000);
  transition: filter 0.2s;
}
#overlaySave:hover svg{
  filter: drop-shadow(0 0 6px #66ff66);
}




/* ===== 正解オーバーレイ ===== */
#correctOverlay {
  position: fixed;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  background: rgba(0, 0, 0, 0.7);
  z-index: 9999;

  visibility: hidden;   /* 初期は非表示 */
  opacity: 0;
  transition: opacity 0.3s ease;

  font-family: "Times New Roman", Times, serif;
}
#correctOverlay.show {
  visibility: visible;
  opacity: 1;
}

.correct-mark {
  width: 25vmin;
  height: 25vmin;
  border: 10px solid #f13d14;  /* 緑の太い円 */
  border-radius: 50%;
  box-sizing: border-box;
  background: transparent;
  /* 真ん中に小さい点を付ける場合は下記追加も可能 */
  /* position: relative; */
}

.correct-text {
  font-size: 10vmin;
  color: #f13d14;
  font-weight: 800;
}




/* ===== 不正解オーバーレイ ===== */
#wrongOverlay{
  position: fixed;
  inset: 0;                           /* top:0 right:0 bottom:0 left:0 */
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  background: rgba(0,0,0,0.7);
  z-index: 9999;
  visibility: hidden;                 /* ← 初期は非表示 */
  opacity: 0;
  transition: opacity 0.3s ease;

  /* font-family: "Yu Gothic","ヒラギノ角ゴ ProN","メイリオ",sans-serif; */
  font-family: "Times New Roman", Times, serif;
}
#wrongOverlay.show{
  visibility: visible;
  opacity: 1;
}

/* ✕マーク本体（サイズは画面短辺×25％） */
.wrong-mark{
  position: relative;
  width: 25vmin;
  height: 25vmin;
}

/* 斜め2本の線を ::before と ::after で描く */
.wrong-mark::before,
.wrong-mark::after{
  content: '';
  position: absolute;
  top: 0; left: 50%;
  width: 12%;                 /* 線の太さ：マーク全体の 12% */
  height: 100%;
  background: #00a0ff;        /* 青い線 */
  transform-origin: center;
}
.wrong-mark::before{
  transform: translateX(-50%) rotate(45deg);
}
.wrong-mark::after{
  transform: translateX(-50%) rotate(-45deg);
}

.wrong-text{
  font-size: clamp(2.4rem, 6vw, 4rem);
  color: #00a0ff;
  font-weight: 800;
}













/* animation */


@keyframes logoZoom{
  0%   { transform:scale(1.0);   opacity:1; }
  70%  { transform:scale(1.1); opacity:1; }  /* ズーム最大 */
  100% { transform:scale(0.8); opacity:0; }  /* フェードアウト */
}

/* ========= loading text split chars ========= */
.loading-text{
  display:inline-block;
  font:700 18px/1 "Times New Roman",serif;
  letter-spacing:2px;
  color:#000;
  white-space:pre;                         /* 改行や空白をそのまま */
}
.loading-text span{
  display:inline-block;
  transform:translateY(-40px);             /* 上から落とす起点 */
  opacity:0;
  animation:letterDrop .8s ease forwards;
}
@keyframes letterDrop{
  0%   { transform:translateY(-40px); opacity:0; }
  80%  { opacity:1; }
  100% { transform:translateY(0);      opacity:1; }
}




.animation-ZoomSlideIn{
  animation: zoomSlideIn 12.0s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}
@keyframes zoomSlideIn {
  0% {
    transform: translate(-50%, -50%) scale(0.2) translateY(-200%);
    opacity: 0;
  }
  25% {
    transform: translate(-50%, -50%) scale(0.2) translateY(-200%);
    opacity: 0;
  }
  100% {
    transform: translate(-50%, -50%) scale(1) translateY(0);
    opacity: 1;
  }
}


.animation-fadeIn {
  animation: animation-fadeIn 7.0s cubic-bezier(0.33, 1, 0.68, 1) forwards;
}
@keyframes animation-fadeIn {
  0% {
    opacity: 0;
  }
  50%{
    opacity: 0.7;
  }
  100% {
    opacity: 1;
  }
}









/* canvas */

canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 4;
}



/* background */

/* .background{
  background-size: cover;      
  background-position: center;  
  background-repeat: no-repeat; 
  position: fixed;

  top: 0;
  left: 0;
  width: 100%;
  height: 100%; 
  z-index: -1;
  pointer-events: none;

} */

.background{
  position: fixed;
  top: 0;
  left: 50%;                 /* 画面中央に基準を置く */
  width: 640px;              /* ここを表示エリアと同じ幅に固定 */
  height: 100%;
  transform: translateX(-50%); /* 中央寄せ */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: -1;
  pointer-events: none;
}

.wing-background{
  background-image: url('../img/wing-play-background.png');
  /* background-color: #343434; */
}


