/* ===== オープニング・イントロ演出（黒背景・欧文のみ／文字出現） ===== */

html.as-intro-lock, html.as-intro-lock body { overflow: hidden; }

#as-intro {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  opacity: 1;
  transition: opacity 0.9s ease;
}
#as-intro.is-hidden { opacity: 0; pointer-events: none; }

/* 中央ビネット（ほのかに締める） */
.as-intro-grad {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 55%, rgba(0,0,0,0.5) 100%);
}

/* 地名（欧文のみ） */
.as-intro-place {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}
.as-ip-en {
  display: flex;
  font-family: 'Noto Serif JP', serif;
  font-size: clamp(1.4rem, 5vw, 2.6rem);
  letter-spacing: 0.5em;
  padding-left: 0.5em; /* 字間の末尾分を相殺して中央に見せる */
  font-weight: 400;
  color: #fff;
  line-height: 1;
}
/* 1文字ずつ出現（上品にフェード＋微上昇） */
.as-ip-en .ch {
  display: inline-block;
  opacity: 0;
  transform: translateY(0.35em);
  animation: ipChar 0.7s cubic-bezier(.22,.61,.36,1) forwards;
}
.as-ip-en .ch.sp { width: 0.3em; }
.as-ip-1 .ch { animation-delay: calc(0.25s + var(--i) * 0.06s); }
.as-ip-2 .ch { animation-delay: calc(1.95s + var(--i) * 0.06s); }

/* 単語ごとに退場（次の単語へ） */
.as-ip-1 { animation: ipOut 0.55s ease 1.55s forwards; }
.as-ip-2 { animation: ipOut 0.55s ease 3.4s forwards; }

@keyframes ipChar {
  from { opacity: 0; transform: translateY(0.35em); filter: blur(4px); }
  to   { opacity: 1; transform: translateY(0); filter: blur(0); }
}
@keyframes ipOut {
  from { opacity: 1; transform: translateY(0); }
  to   { opacity: 0; transform: translateY(-0.14em); }
}

/* Reduce Motion時：大きな動きはせず、単語ごとのシンプルなフェードで必ず動かす */
@media (prefers-reduced-motion: reduce) {
  .as-ip-en .ch { animation: none; opacity: 1; transform: none; filter: none; }
  .as-ip-1 { animation: ipFadeSeq 1.7s ease forwards 0.1s; }
  .as-ip-2 { opacity: 0; animation: ipFadeSeq 1.7s ease forwards 1.85s; }
}
@keyframes ipFadeSeq {
  0%   { opacity: 0; }
  18%  { opacity: 1; }
  80%  { opacity: 1; }
  100% { opacity: 0; }
}
