:root {
  --bg: #ffdb47;
  --ink: #200000;
  --card: rgba(255, 255, 255, 0.72);
  --font-title: "Dela Gothic One", sans-serif;
  --font-body: "Zen Maru Gothic", "Hiragino Maru Gothic ProN", "Yu Gothic", sans-serif;
}

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

body {
  font-family: var(--font-body);
  font-weight: 500;
  background: var(--bg);
  color: var(--ink);
  line-height: 2;
  letter-spacing: 0.04em;
  overflow-x: hidden;
}

a {
  color: var(--ink);
}

img {
  max-width: 100%;
}

/* ============ 背景イラスト ============ */
.bg-stage {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0; /* ファーストビューでは非表示。スクロールでJSがフェードイン */
}

.bg-illust {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  height: min(78vh, 700px);
  max-width: 96vw;
  object-fit: contain;
  object-position: bottom center;
  /* 白背景・黄背景の画像を地色に馴染ませる */
  mix-blend-mode: multiply;
}

.bg-sonen {
  display: none;
}

body.is-sonen .bg-wakai {
  display: none;
}

body.is-sonen .bg-sonen {
  display: block;
}

/* ============ ファーストビュー:キャッチコピー演出 ============ */
.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem 1rem;
  position: relative;
}

.hero-catch {
  display: flex;
  flex-direction: column;
  gap: 0.4em;
  font-weight: 900;
  line-height: 1.5;
}

.catch-line {
  opacity: 0;
  transform: translateY(0.6em);
  animation: catchIn 0.4s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  font-size: clamp(1.3rem, 4.5vw, 2rem);
}

.catch-line-1 { animation-delay: 0.1s; }
.catch-line-2 { animation-delay: 0.45s; }
.catch-line-3 { animation-delay: 0.8s; }

.catch-line-4 {
  animation-delay: 1.15s;
  font-family: var(--font-title);
  font-weight: 400;
  font-size: clamp(1.7rem, 6.5vw, 3.2rem);
  margin-top: 0.3em;
  text-shadow:
    3px 3px 0 #fff,
    -3px 3px 0 #fff,
    3px -3px 0 #fff,
    -3px -3px 0 #fff;
}

@keyframes catchIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.scroll-hint {
  position: absolute;
  bottom: 1.4rem;
  left: 50%;
  transform: translateX(-50%);
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  opacity: 0;
  animation: catchIn 0.6s 1.8s forwards;
}

.scroll-hint span {
  display: block;
  width: 2px;
  height: 2.2rem;
  background: var(--ink);
  animation: scrollLine 1.6s ease-in-out infinite;
  transform-origin: top;
}

@keyframes scrollLine {
  0%   { transform: scaleY(0); }
  50%  { transform: scaleY(1); }
  100% { transform: scaleY(0); }
}

/* ============ イラスト全体を見せる余白 ============ */
.visual-spacer {
  height: 85svh; /* 若年期イラストがフェードインしきり、全体が見える区間 */
}

.finale-spacer {
  height: 100svh; /* 壮年期イラストの全体が見える区間 */
}

/* ============ メインビジュアル+タイトル ============ */
.title-view {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  text-align: center;
  padding: 9svh 1.2rem 42vh; /* 下部はイラストの見える余白 */
}

.title-view > * {
  opacity: 0;
  transform: translateY(1.2em);
  transition: opacity 0.55s ease, transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.title-view.is-revealed > * {
  opacity: 1;
  transform: translateY(0);
}

.title-view.is-revealed > *:nth-child(1) { transition-delay: 0s; }
.title-view.is-revealed > *:nth-child(2) { transition-delay: 0.15s; }
.title-view.is-revealed > *:nth-child(3) { transition-delay: 0.3s; }
.title-view.is-revealed > *:nth-child(4) { transition-delay: 0.45s; }
.title-view.is-revealed > *:nth-child(5) { transition-delay: 0.6s; }
.title-view.is-revealed > *:nth-child(6) { transition-delay: 0.75s; }

.title-logo {
  width: min(88vw, 620px);
  filter: drop-shadow(3px 3px 0 rgba(255, 255, 255, 0.9));
}

.title-kanmuri {
  margin-top: 1.4rem;
  font-weight: 900;
  font-size: clamp(0.9rem, 2.5vw, 1.15rem);
  letter-spacing: 0.3em;
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 0.15em 1.3em 0.15em 1.6em;
  background: var(--bg);
}

.title-date {
  margin-top: 1.2rem;
  font-family: var(--font-title);
  font-size: clamp(1.7rem, 6vw, 2.8rem);
  text-shadow: 2px 2px 0 #fff;
  line-height: 1.3;
}

.title-year {
  font-size: 0.55em;
  margin-right: 0.5em;
  vertical-align: 0.25em;
}

.title-dow {
  font-size: 0.45em;
  vertical-align: 0.4em;
  margin: 0 0.4em 0 0.1em;
}

.title-venue {
  font-weight: 900;
  font-size: clamp(1.05rem, 3.4vw, 1.4rem);
}

.title-stages {
  margin-top: 0.4rem;
  font-weight: 700;
  font-size: 0.95rem;
  border: 1.5px solid var(--ink);
  border-radius: 6px;
  padding: 0 0.7em;
  background: rgba(255, 255, 255, 0.6);
}

.title-hashtag {
  display: inline-block;
  margin-top: 1.1rem;
  font-weight: 900;
  font-size: clamp(1rem, 3vw, 1.25rem);
  background: var(--ink);
  color: var(--bg);
  text-decoration: none;
  border-radius: 999px;
  padding: 0.25em 1.2em;
  transition: transform 0.15s ease;
}

.title-hashtag:hover {
  transform: scale(1.06) rotate(-2deg);
}

/* ============ セクション共通 ============ */
main {
  max-width: 760px;
  margin: 0 auto;
  padding: 4rem 1.2rem;
}

.section {
  margin-bottom: 4.5rem;
}

.section-title {
  font-family: var(--font-title);
  font-weight: 400;
  font-size: clamp(1.4rem, 4.5vw, 2rem);
  text-align: center;
  margin-bottom: 1.6rem;
  text-shadow: 2px 2px 0 #fff;
}

.section-title::after {
  content: "";
  display: block;
  width: 3em;
  height: 4px;
  background: var(--ink);
  border-radius: 2px;
  margin: 0.5rem auto 0;
}

.card {
  background: var(--card);
  border: 2px solid var(--ink);
  border-radius: 18px;
  padding: 1.8rem 1.6rem;
  box-shadow: 6px 6px 0 rgba(32, 0, 0, 0.25);
}

.card p + p {
  margin-top: 1.2em;
}

.lead {
  font-weight: 700;
}

/* ============ あらすじ(スクロール固定パネル) ============ */
.story-pin {
  /* 100svh のパネル + スクロール距離。この間パネルが画面に固定される */
  height: 200svh;
  /* main の幅制限を破って全幅にする */
  width: 100vw;
  margin-left: calc(50% - 50vw);
}

.story-panel {
  position: sticky;
  top: 0;
  height: 100svh;
  overflow-y: auto;
  background: var(--bg); /* 不透明。背景イラストを完全に隠す */
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem 1.2rem;
}

.story-title {
  margin-bottom: 2rem;
}

.story-body {
  max-width: 640px;
  font-weight: 700;
  font-size: clamp(0.85rem, 2.6vw, 1.05rem);
  line-height: 2;
}

.story-body p + p {
  margin-top: 1.4em;
}

/* 見出し → 本文 の2段階表示 */
.story-title,
.story-body {
  opacity: 0;
  transform: translateY(1em);
  transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.story-title.is-shown,
.story-body.is-shown {
  opacity: 1;
  transform: translateY(0);
}

/* ============ 登場人物 ============ */
.chara-list {
  list-style: none;
  display: grid;
  gap: 1.2rem;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.chara {
  text-align: center;
  padding: 1.4rem 1rem;
}

.chara-name {
  font-weight: 900;
  font-size: 1.25rem;
  line-height: 1.4;
}

.chara-kana {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  opacity: 0.75;
}

.chara-alias {
  margin-top: 0.6rem;
  font-size: 0.9rem;
  background: var(--bg);
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  display: inline-block;
  padding: 0.05em 1em;
}

/* ============ 公演情報 ============ */
.info-list {
  display: flex;
  flex-direction: column;
  gap: 1.4rem;
}

.info-row {
  display: flex;
  gap: 1.2rem;
}

.info-row dt {
  flex: 0 0 4.5em;
  font-weight: 900;
  background: var(--ink);
  color: var(--bg);
  border-radius: 8px;
  text-align: center;
  align-self: flex-start;
  padding: 0.1em 0;
  font-size: 0.9rem;
  margin-top: 0.35em;
}

.info-row dd {
  flex: 1;
  font-weight: 700;
}

.info-sub {
  font-size: 0.85rem;
  font-weight: 500;
}

.map-placeholder {
  margin-top: 0.8rem;
  border: 2px dashed var(--ink);
  border-radius: 12px;
  padding: 2.2rem 1rem;
  text-align: center;
  font-size: 0.8rem;
  font-weight: 500;
  opacity: 0.65;
}

/* ============ 続報 ============ */
.card-next {
  text-align: center;
  background: var(--ink);
  color: #fff;
  box-shadow: 6px 6px 0 rgba(32, 0, 0, 0.25);
}

.card-next a {
  color: var(--bg);
  font-weight: 900;
}

.next-label {
  font-family: var(--font-title);
  font-size: 1.2rem;
  color: var(--bg);
  margin-bottom: 0.8rem;
}

.next-follow {
  font-size: 0.9rem;
}

/* ============ お問い合わせ ============ */
.contact-card {
  text-align: center;
}

.contact-mail {
  font-weight: 900;
  font-size: clamp(1rem, 4vw, 1.3rem);
  word-break: break-all;
}

/* ============ 出演 ============ */
.cast-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 0.6rem 1rem;
  text-align: center;
  font-weight: 900;
  font-size: 1.1rem;
}

/* ============ スタッフ ============ */
.staff-list {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.staff-row {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  font-size: 0.95rem;
}

.staff-row dt {
  flex: 0 0 11em;
  text-align: right;
  font-weight: 500;
  opacity: 0.8;
  font-size: 0.85rem;
}

.staff-row dd {
  font-weight: 700;
}

/* ============ フッター ============ */
.site-footer {
  text-align: center;
  padding: 2.5rem 1rem 2rem;
  border-top: 2px solid var(--ink);
  background: var(--bg);
}

.footer-kanmuri {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.2em;
}

.footer-logo {
  width: min(60vw, 300px);
  display: block;
  margin: 0.6rem auto 1rem;
}

/* ============ ユーティリティ ============ */
.sp {
  display: none;
}

@media (max-width: 600px) {
  .sp {
    display: inline;
  }

  .story-body {
    line-height: 1.85;
  }

  .info-row {
    flex-direction: column;
    gap: 0.4rem;
  }

  .info-row dt {
    align-self: flex-start;
    padding: 0.1em 1em;
  }
}
