/* =========================
   レイアウト（メイン＋サイドバー）
========================= */
.main.page {
  background-color: var(--bg-light);
  padding: 40px 0 60px;
}

/* 中央寄せラッパー */
.wysiwyg-editor {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 15px;
}

/* PCデフォルト：2カラム */
.content-sidebar-wrapper {
  display: flex;
  align-items: flex-start;
  gap: 40px;
}

/* メインコンテンツ側 */
.contentout {
  flex: 1 1 auto;
  min-width: 0; /* はみ出し防止 */
}

/* サイドバー（PC時） */
.main.page .sidebar {
  flex: 0 0 260px;
  max-width: 260px;
}

/* -----------------------------
   タブレット（769〜1024px）
   → 2カラムのまま、少しタイトに
----------------------------- */
@media (min-width: 769px) and (max-width: 1024px) {

  .main.page {
    padding: 30px 0 50px;
  }

  .wysiwyg-editor {
    max-width: 960px;
    padding: 0 20px; /* 左右余白すこし広め */
  }

  .content-sidebar-wrapper {
    gap: 24px;
  }

  .main.page .sidebar {
    flex: 0 0 240px;
    max-width: 240px;
  }
}

/* -----------------------------
   スマホ（〜768px）
   → 縦並び＋左右16pxでそろえる
----------------------------- */
@media (max-width: 768px) {

  .main.page {
    padding: 24px 0 40px;
  }

  .wysiwyg-editor {
    max-width: 100%;
    padding: 0 16px; /* 左右に同じ余白 */
    box-sizing: border-box;
  }

  .content-sidebar-wrapper {
    flex-direction: column;
    gap: 24px;
  }

  .contentout,
  .main.page .sidebar {
    flex: 0 0 auto;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  /* テーマ側の float や margin を打ち消し */
  .main.page .sidebar {
    float: none !important;
    margin: 0 !important;
    padding: 0;  /* 余白がキツそうならここでリセット */
  }

  /* サイドバー内のカードも100%に */
  .sidebar-section {
    width: 100%;
    box-sizing: border-box;
  }
}

/* =========================
   ブログ一覧カード
========================= */

.blog-list__list-item {
  margin-bottom: 24px;
}

.blog-item {
  display: flex;
  flex-direction: column;
  background-color: #fff;
  border-radius: 12px;
  border: 1px solid var(--pink-border);
  overflow: hidden;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(233, 106, 146, 0.06);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.blog-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(233, 106, 146, 0.12);
}

/* サムネイル */
.blog-item__thumbnail {
  width: 100%;
  overflow: hidden;
  background: #fdf3f8;
}

.blog-item__thumbnail-image {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.3s ease;
}

.blog-item:hover .blog-item__thumbnail-image {
  transform: scale(1.05);
}

/* 記事コンテンツ部分 */
.blog-item__content {
  padding: 16px 16px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* タイトル */
.blog-item__title {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-main);
  margin: 0;
}

/* ボタンエリア */
.blog-item__button {
  margin-top: 4px;
  text-align: right;
}

.blog-item__button-more {
  display: inline-block;
  font-size: 0.85rem;
  padding: 6px 14px;
  border-radius: 999px;
  background-color: var(--pink-main);
  color: #fff;
  letter-spacing: 0.06em;
  text-align: center;
  transition: background-color 0.2s ease, transform 0.1s ease;
}

.blog-item:hover .blog-item__button-more {
  background-color: #e9d8c5;
  transform: translateY(-1px);
}

/* =========================
   サイドバー（アーカイブ・カテゴリ）
========================= */

.sidebar-section {
  background-color: #fff;
  border-radius: 10px;
  border: 1px solid var(--pink-border);
  padding: 18px 14px 16px;
  margin-bottom: 16px;
}

.sidebar-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--pink-main);
  border-bottom: 1px solid var(--pink-border);
  padding-bottom: 6px;
}

/* WP標準のアーカイブ・カテゴリリストを整える */
.sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-list li {
  font-size: 0.9rem;
  line-height: 1.6;
}

.sidebar-list li + li {
  margin-top: 6px;
}

/* アーカイブリンク（wp_get_archives出力） */
.sidebar-list a {
  color: var(--text-main);
  text-decoration: none;
  display: inline-block;
}

.sidebar-list a:hover {
  color: var(--pink-main);
  text-decoration: underline;
}

/* wp_list_categories のカウント部分微調整 */
.sidebar-list li a {
  margin-right: 4px;
}

.sidebar-list li span.count {
  color: var(--text-muted);
  font-size: 0.8rem;
}

/* =========================
   カラーバリエーション（必要に応じて調整OK）
========================= */
:root {
  --pink-main: #C8A88B;   /* 見出し・ボタンのメインピンク */
  --pink-light: #FBEBEE; /* 背景などに使う淡いピンク */
  --pink-border: #f3c7d9;
  --text-main: #1A3651;
  --text-muted: #888;
  --bg-light: #b35e6d0f;
}

/* =========================
   メインレイアウト
========================= */

#main_contents {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto 60px;
  padding: 50px 15px;
  display: flex;
  gap: 40px;
}

/* メインカラム */
#main_col {
  flex: 1 1 auto;
}

/* サイドバー */
.sidebar {
  flex: 0 0 260px;
}

/* スマホ時は縦並びに */
@media (max-width: 768px) {
  #main_contents {
    flex-direction: column;
    gap: 30px;
  }
  .sidebar {
    flex-basis: auto;
  }
}

/* =========================
   お知らせ本文 (single)
========================= */

.news-single {
  background-color: #fff;
  border-radius: 8px;
  border: 1px solid var(--pink-border);
  padding: 24px 20px 30px;
  margin-bottom: 40px;
  box-shadow: 0 4px 12px rgba(233, 106, 146, 0.06);
}

/* 日付 + タクソノミー */
.news-single .entry-header {
  margin-bottom: 16px;
  border-bottom: 1px solid #f3f3f3;
  padding-bottom: 10px;
}

.news-single .entry-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.news-single .entry-meta time {
  font-weight: 600;
}

.news-single .entry-meta .entry-terms {
  display: inline-block;
  margin-left: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  background-color: var(--pink-light);
  color: var(--pink-main);
  font-size: 0.8rem;
}

/* 本文 */
.news-single .entry-content {
  font-size: 0.95rem;
  line-height: 1.9;
  color: var(--text-main);
}

.news-single .entry-content p + p {
  margin-top: 1em;
}

.news-single .entry-content a {
  color: var(--pink-main);
  text-decoration: underline;
  text-decoration-thickness: 1px;
}

/* =========================
   関連お知らせ
========================= */

.related-posts.related-news {
  margin-bottom: 40px;
}

.related-posts .term-title {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 18px;
  padding-left: 10px;
  position: relative;
  color: var(--pink-main);
}

.related-posts .term-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  width: 4px;
  height: 1.4em;
  border-radius: 999px;
  background-color: var(--pink-main);
}

/* グリッドレイアウト */
.related-cases-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

@media (max-width: 900px) {
  .related-cases-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 600px) {
  .related-cases-grid {
    grid-template-columns: 1fr;
  }
}

/* 各カード */
.related-case-item {
  background-color: #fff;
  border-radius: 10px;
  border: 1px solid var(--pink-border);
  padding: 14px 14px 18px;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.related-case-thumbnail {
  margin-bottom: 10px;
}

.related-case-thumbnail img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  display: block;
}

/* タイトル */
.related-case-title {
  font-size: 0.95rem;
  margin: 4px 0 8px;
  line-height: 1.5;
}

.related-case-title .related-case-a {
  text-decoration: none;
  color: var(--text-main);
}

.related-case-title .related-case-a:hover {
  color: var(--pink-main);
}

/* 日付 */
.related-case-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* 区切り線 */
.related_hr {
  margin: 10px 0 12px;
  border: none;
  border-bottom: 1px dashed var(--pink-border);
}

/* 「詳細を見る」ボタン */
.related-case-link {
  margin-top: auto;
  text-align: right;
}

.case_btn {
  display: inline-block;
  padding: 6px 14px;
  font-size: 0.85rem;
  border-radius: 999px;
  background-color: var(--pink-main);
  color: #fff;
  text-decoration: none;
  transition: background-color 0.2s ease, transform 0.1s ease;
}

.case_btn:hover {
  background-color: #e9d8c5;
  transform: translateY(-1px);
}

/* =========================
   一覧へボタン
========================= */

.btn-center {
  text-align: center;
  margin: 80px 0 10px;
}

.btn-blue {
  display: inline-block;
  min-width: 220px;
  padding: 10px 24px;
  border-radius: 999px;
  background-color: var(--pink-main);
  color: #fff;
  font-size: 0.95rem;
  text-decoration: none;
  letter-spacing: 0.08em;
  transition: background-color 0.2s ease, box-shadow 0.2s ease, transform 0.1s ease;
}

.btn-blue:hover {
  background-color: #e9d8c5;
  box-shadow: 0 4px 10px rgba(233, 106, 146, 0.3);
  transform: translateY(-1px);
}

/* =========================
   サイドバー（最近のお知らせ）
========================= */

.sidebar-section {
  background-color: #fff;
  border-radius: 10px;
  border: 1px solid var(--pink-border);
  padding: 18px 14px;
}

.sidebar-title {
  font-size: 1.0rem;
  font-weight: 600;
  margin-bottom: 10px;
  color: var(--pink-main);
  border-bottom: 1px solid var(--pink-border);
  padding-bottom: 6px;
}

.sidebar-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-list li + li {
  margin-top: 6px;
}

.sidebar-list a {
  font-size: 0.9rem;
  color: var(--text-main);
  text-decoration: none;
  line-height: 1.5;
}

.sidebar-list a:hover {
  color: var(--pink-main);
  text-decoration: underline;
}

/* =========================
   全体の背景に少しだけピンク感
   （必要なければ削除OK）
========================= */

body.single-news {
  background-color: var(--bg-light);
}