@charset "UTF-8";
/* ------------------------------
相関図モーダル（js/chart_modal.js とセット）
------------------------------ */
/* クリック範囲 */
#chart .chartMap {
  position: relative;
  display: block;
  max-width: 100% !important;
  container-type: inline-size; /* 枠線の太さを画像の表示幅に合わせて計算するため */
}
#chart .chartMap img {
  display: block;
  width: 100%;
  margin: 0; /* 共通CSSの下余白(5px)があると、ラッパーが画像より高くなりクリック範囲が縦にずれる */
}
#chart .chartMap__btn {
  position: absolute;
  margin: 0;
  padding: 0;
  background: transparent;
  border: none;
  /* 相関図の枠線：元画像1600px幅で太さ10px・外側の角丸10px。表示幅に合わせて同じ比率で描く */
  --frame: calc(100cqw * 10 / 1600);
  border-radius: var(--frame);
  box-sizing: border-box;
  cursor: pointer;
  transition: box-shadow .2s, background-color .2s;
}
#chart .chartMap__btn:hover,
#chart .chartMap__btn:focus-visible {
  /* border は太さが整数pxに切り捨てられるため、端数まで正確に描ける inset の box-shadow で枠を重ねる */
  box-shadow: inset 0 0 0 var(--frame) #D4AF37;
  background-color: rgba(255, 255, 255, .12);
  outline: none;
}
#chart .chartMap__note {
  margin: 10px 0 0;
  font-size: 1em;
  text-align: center;
  color: #fff;
}

/* モーダル */
.chartModal {
  position: fixed;
  inset: 0;
  z-index: 2147483000; /* 共通ヘッダー・ページトップボタンより前面 */
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(0, 0, 0, .75);
  opacity: 0;
  visibility: hidden;
  /* 閉じるとき：フェードアウトが終わってから非表示にする */
  transition: opacity .3s, visibility 0s .3s;
}
.chartModal.is-open {
  opacity: 1;
  visibility: visible;
  /* 開くとき：すぐ表示扱いにして、「×」にフォーカスを移せるようにする */
  transition: opacity .3s, visibility 0s;
}
html.chartModal-lock {
  overflow: hidden;
}
.chartModal__box {
  position: relative;
  display: flex;
  gap: 24px;
  width: 100%;
  max-width: 760px;
  max-height: 100%;
  overflow-y: auto;
  padding: 32px;
  background: #1F1008;
  border: 2px solid #D4AF37;
  box-shadow: inset 10px 10px 50px rgba(255, 236, 0, 0.12);
  box-sizing: border-box;
  color: #fff;
}
.chartModal__close {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;  /* 押しやすいようにタップ範囲を広げる */
  height: 56px;
  padding: 0;
  background: none;
  border: none;
  font-size: 48px;
  line-height: 1;
  color: #fff;
  cursor: pointer;
}
.chartModal__photo {
  flex: 0 0 300px;
}
.chartModal__photo img {
  display: block;
  width: 100%;
  height: auto;
  outline: 1px solid rgba(212, 175, 55, .6);
}
.chartModal__txt {
  flex: 1;
  min-width: 0;
}
.chartModal__txt p {
  margin: 0;
}
.chartModal__tag {
  display: inline-block;
  margin-bottom: 18px !important; /* 下の名前のルビと詰まらないように */
  padding: 4px 12px;
  background: #A87E3A;
  color: #fff;
  font-size: 1.1em;
  font-weight: bold;
  line-height: 1.5;
}
.chartModal__role {
  font-family: serif;
  font-size: 1.8em;
  font-weight: bold;
  line-height: 1.3;
}
.chartModal__role .chartModal__pre {
  margin-right: 0.2em;
  font-size: 0.8em;
}
.chartModal__role .chartModal__age {
  margin-left: 0.1em;
  font-size: 0.8em;
  font-weight: normal;
}
.chartModal__role ruby rt {
  font-size: 0.4em;
  font-weight: normal;
  letter-spacing: 0.05em;
}
.chartModal__role .chartModal__sp {
  display: inline-block;
  width: 0.4em;
}
.chartModal__actor {
  margin-top: 4px !important;
  padding-bottom: 12px;
  border-bottom: 2px solid #D4AF37;
  font-size: 1.2em;
  font-weight: bold;
  color: #D4AF37;
}
.chartModal__profile {
  margin-top: 14px !important;
  line-height: 1.8;
}

@media screen and (max-width: 768px) {
  .chartModal__box {
    display: block;
    padding: 44px 20px 24px;
  }
  .chartModal__photo {
    width: 80%;
    margin: 0 auto 16px;
  }
  .chartModal__role {
    font-size: 1.5em;
  }
  .chartModal__tag {
    font-size: 1em;
  }
  #chart .chartMap__note {
    font-size: 0.9em;
  }
}
