/* ============================================================
   voice-article.css — お客様の声（single voice）記事デザイン
   2026-06-11 導入。スコープは body#voice（single-voice.php）のみ。
   記事側は素のHTML＋クラス（talk / spec / subtitle / caption /
   closing-msg / credit / voice-gallery）だけで成立する。
   ============================================================ */

#voice {
  --v-ink: #2b2520;
  --v-ink-soft: #6b6259;
  --v-paper: #f7f6f1;
  --v-wood: #8a6240;
  --v-line: #e7e2d9;
  --v-serif: "Noto Serif JP", serif;
}

/* ───── タイトルまわり（テーマ出力部分の上書き） ───── */
/* ページ全体をHP共通の背景色 #f7f6f1 に合わせる（2026-06-11 オーナー指定） */
#voice { background: var(--v-paper); }

#voice h2.system-ttl-01 {
  font-family: var(--v-serif);
  font-weight: 600;
  font-size: clamp(23px, 3.6vw, 34px);
  line-height: 1.8;
  letter-spacing: 0.06em;
  text-align: center;
  color: var(--v-ink);
}

#voice .p-voice__area-wrap.single {
  justify-content: center;
  color: var(--v-ink-soft);
  letter-spacing: 0.14em;
}

/* ───── 本文（.wysiwyg） ───── */
#voice .wysiwyg {
  color: var(--v-ink);
  line-height: 2.05;
  letter-spacing: 0.03em;
  counter-reset: voice-qa;
}

/* テキスト系は680pxの読み物カラムに */
#voice .wysiwyg > p,
#voice .wysiwyg > h2,
#voice .wysiwyg > h3,
#voice .wysiwyg > ul,
#voice .wysiwyg > ol {
  max-width: 680px;
  margin-left: auto;
  margin-right: auto;
}
#voice .wysiwyg > p { margin-top: 1.8em; margin-bottom: 0; }

/* 旧記事の区切り線は非表示（見出しの余白で区切る） */
#voice .wysiwyg hr.wp-block-separator { display: none; }

/* 見出し：明朝＋自動ナンバリング */
#voice .wysiwyg > h2,
#voice .wysiwyg > h3 {
  font-family: var(--v-serif);
  font-weight: 600;
  font-size: clamp(19px, 2.6vw, 24px);
  line-height: 1.8;
  letter-spacing: 0.05em;
  margin-top: 92px;
  margin-bottom: 34px;
  color: var(--v-ink);
}
#voice .wysiwyg > h2:not(.subtitle):not(.no-num)::before,
#voice .wysiwyg > h3:not(.subtitle):not(.no-num)::before {
  counter-increment: voice-qa;
  content: counter(voice-qa, decimal-leading-zero);
  display: block;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.3em;
  color: var(--v-wood);
  margin-bottom: 10px;
}

/* サブタイトル（リード直後のキャッチ一行）：声・情緒の要素なので明朝。
   見出し/段落どちらで入れても明朝に揃える（記事間の不統一を解消） */
#voice .wysiwyg .subtitle {
  font-family: var(--v-serif);
  text-align: center;
  font-size: clamp(16px, 2.2vw, 19px);
  margin-top: 56px;
}

/* スペック行（冒頭の物件概要）：中央・小さめ */
#voice .wysiwyg p.spec {
  text-align: center;
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--v-ink-soft);
  margin-top: 0;
}
#voice .wysiwyg p.spec strong { font-weight: 500; }

/* 発言：細い木色の左線＋明朝 */
#voice .wysiwyg p.talk {
  font-family: var(--v-serif);
  border-left: 1px solid var(--v-wood);
  padding-left: 20px;
}

/* リスト：罫線区切り */
#voice .wysiwyg > ul li {
  list-style: none;
  padding: 14px 0;
  font-size: 15.5px;
  border-bottom: 1px solid var(--v-line);
}
#voice .wysiwyg > ul li:first-child { border-top: 1px solid var(--v-line); }

/* 写真：本文より一回り広く */
#voice .wysiwyg > figure.wp-block-image {
  max-width: 1080px;
  margin: 72px auto 0;
}
#voice .wysiwyg > figure.wp-block-image img {
  width: 100%;
  height: auto;
  border-radius: 4px;
}

/* 写真キャプション */
#voice .wysiwyg p.caption {
  text-align: center;
  font-size: 12.5px;
  letter-spacing: 0.1em;
  color: var(--v-ink-soft);
  margin-top: 12px;
}

/* ───── ギャラリー（Swiper共通） ───── */
#voice .voice-gallery {
  max-width: 1080px;
  margin: 72px auto 0;
}
#voice .voice-gallery .swiper { border-radius: 4px; }
/* 枠は4:3固定（スライド中の高さブレ防止）。写真は切り抜かず収める。
   縦長・横長の余白はページ背景と同色にして溶け込ませる */
#voice .voice-gallery .swiper-slide img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  background: var(--v-paper);
  display: block;
}
#voice .voice-gallery .nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  margin-top: 12px;
}
/* ギャラリーのカウンター（1 / 5）はUI・情報要素なのでゴシック（body標準を継承） */
#voice .voice-gallery .frac {
  font-size: 12.5px;
  letter-spacing: 0.18em;
  color: var(--v-ink-soft);
}
#voice .voice-gallery button.gbtn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--v-line);
  background: transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: border-color .2s ease;
  padding: 0;
}
#voice .voice-gallery button.gbtn:hover { border-color: var(--v-wood); }
#voice .voice-gallery button.gbtn:focus-visible { outline: 2px solid var(--v-wood); outline-offset: 2px; }
#voice .voice-gallery button.gbtn svg { width: 15px; height: 15px; stroke: var(--v-ink-soft); }

/* ───── 結び ───── */
#voice .wysiwyg p.closing-msg {
  font-family: var(--v-serif);
  text-align: center;
  font-size: clamp(16.5px, 2.2vw, 19px);
  line-height: 2.3;
  letter-spacing: 0.06em;
  margin-top: 100px;
  padding-top: 56px;
  position: relative;
}
#voice .wysiwyg p.closing-msg::before {
  content: "";
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 48px;
  height: 1px;
  background: var(--v-wood);
}
#voice .wysiwyg p.credit {
  text-align: center;
  font-size: 12.5px;
  letter-spacing: 0.18em;
  color: var(--v-ink-soft);
  margin-top: 56px;
}

/* ───── フェードイン（JSが.fxを付与。JS無効時は影響なし） ───── */
#voice .fx {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 1.1s ease, transform 1.1s ease;
}
#voice .fx.on { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  #voice .fx { opacity: 1; transform: none; transition: none; }
}

@media (max-width: 640px) {
  #voice .wysiwyg > h2,
  #voice .wysiwyg > h3 { margin-top: 68px; }
  #voice .wysiwyg { font-size: 15.5px; }
}
