@charset "utf-8";
/* ブロックエディタで作った固定ページ・投稿の本文スタイル（E-3・2026-09-08）
 *
 * 既存ページの本文は page-*.php に直書きで .wp-block-* を持たないため、この CSS は既存表示に影響しない。
 * 読み込みは header.php が「本文がブロックのページ」だけで行う（判定は functions.php の nubow_has_block_content）。
 * そのため CSS 側では body クラスに依存しない。body.has-block-content は JS や将来の分岐用に付けてあるだけ。
 * 幅は #page .main-content の 1400px を本文向けに 900px へ絞る。数値は css/page.css の変数に合わせる。
 */

#page .main-content {
  max-width: 900px;
  font-size: var(--font-size-md);
  line-height: 2;
}

/* 見出し ------------------------------------------------------------------ */
#page .main-content h2 {
  font-size: var(--font-size-2xl);
  font-weight: 700;
  line-height: 1.6;
  margin: 2.4em 0 0.8em;
  padding-bottom: 0.4em;
  border-bottom: 1px solid #DBD5CF;
}

#page .main-content h3 {
  font-size: var(--font-size-xl);
  font-weight: 700;
  line-height: 1.6;
  margin: 2em 0 0.6em;
}

#page .main-content h4 {
  font-size: var(--font-size-lg);
  font-weight: 500;
  line-height: 1.6;
  margin: 1.6em 0 0.5em;
  color: #5C4636;
}

#page .main-content > *:first-child {
  margin-top: 0;
}

/* 本文・リスト ------------------------------------------------------------ */
#page .main-content p {
  font-size: var(--font-size-md);
  line-height: 2;
  margin: 0 0 1.4em;
}

#page .main-content ul,
#page .main-content ol {
  margin: 0 0 1.4em;
  padding-left: 1.4em;
  font-size: var(--font-size-md);
}

#page .main-content ul { list-style: disc; }
#page .main-content ol { list-style: decimal; }
#page .main-content li { line-height: 2; margin-bottom: 0.3em; }

#page .main-content a {
  color: #5d548f;
  text-decoration: underline;
}

#page .main-content strong { font-weight: 700; }

/* 画像・図版 -------------------------------------------------------------- */
#page .main-content .wp-block-image {
  margin: 2em 0;
}

#page .main-content .wp-block-image img {
  width: 100%;
  height: auto;
  border-radius: 8px;
}

#page .main-content figcaption {
  font-size: var(--font-size-xs);
  color: #5C4636;
  margin-top: 0.6em;
  text-align: center;
}

/* 引用・区切り ------------------------------------------------------------ */
#page .main-content .wp-block-quote {
  margin: 2em 0;
  padding: 16px 20px;
  background: #faf8f3;
  border: 1px solid #e6e0d4;
  border-radius: 8px;
}

#page .main-content .wp-block-quote p:last-child { margin-bottom: 0; }

#page .main-content .wp-block-separator {
  margin: 3em auto;
  border: 0;
  border-top: 1px solid #DBD5CF;
}

/* 表 ---------------------------------------------------------------------- */
#page .main-content .wp-block-table {
  margin: 2em 0;
  overflow-x: auto;
}

#page .main-content .wp-block-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--font-size-sm);
}

#page .main-content .wp-block-table th,
#page .main-content .wp-block-table td {
  /* display は css/page.css の `@media (max-width:1199px) #page table td {display:block}`（既存の
     独自テーブルを縦積みにする指定）を打ち消すために、メディアクエリの外で明示する。
     セレクタの詳細度がこちらの方が高いので幅に依らず勝つ */
  display: table-cell;
  border: 1px solid #DBD5CF;
  padding: 12px 14px;
  line-height: 1.8;
  text-align: left;
  vertical-align: top;
}

#page .main-content .wp-block-table th {
  background: #faf8f3;
  font-weight: 500;
  white-space: nowrap;
}

/* ボタン ------------------------------------------------------------------ */
#page .main-content .wp-block-buttons {
  margin: 2.4em 0;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

#page .main-content .wp-block-button__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 0 32px;
  border-radius: 50px;
  background: #998675;
  color: #FFF;
  font-size: var(--font-size-md);
  font-weight: 700;
  text-decoration: none;
  box-shadow: 3px 3px 10px 0 rgba(0, 0, 0, 0.2);
}

#page .main-content .is-style-outline .wp-block-button__link {
  background: transparent;
  color: #5C4636;
  border: 1px solid #998675;
  box-shadow: none;
}

/* カラム・グループ・幅 ---------------------------------------------------- */
#page .main-content .wp-block-columns {
  margin: 2em 0;
  gap: 32px;
}

#page .main-content .wp-block-group {
  margin: 2em 0;
}

#page .main-content .alignwide {
  max-width: 1100px;
  margin-left: calc((100% - 1100px) / 2);
  margin-right: calc((100% - 1100px) / 2);
}

#page .main-content .alignfull {
  max-width: none;
}

#page .main-content .aligncenter { text-align: center; }

@media screen and (max-width: 767px) {
  #page .main-content {
    max-width: none;
  }
  #page .main-content .wp-block-columns {
    gap: 20px;
  }
  #page .main-content .alignwide,
  #page .main-content .alignfull {
    max-width: none;
    margin-left: 0;
    margin-right: 0;
  }
  #page .main-content .wp-block-button__link {
    width: 100%;
  }
  #page .main-content .wp-block-table th,
  #page .main-content .wp-block-table td {
    padding: 10px 12px;
  }
  #page .main-content .wp-block-table {
    -webkit-overflow-scrolling: touch;
  }
  #page .main-content .wp-block-table table {
    min-width: 480px;
  }
}
