/*
 * 和幸会 News - WordPress記事本文用スタイル
 * 既存News詳細ページの表示を維持しつつ、
 * .content-news 内に適用範囲を限定
 */

 html { 
    font-size: 16px;
    letter-spacing: normal; 
}

/* 共通ヘッダー調整 */
.page-header h1 {
  font-weight: inherit;
}

/* 共通フッター調整 */
footer a {
  color: inherit;
}

/* 配置指定なしの画像をエディタ表示に合わせて中央寄せ */
.content-news .wp-block-image:not(.alignleft):not(.alignright):not(.aligncenter) img {
  margin-inline: auto;
}

/* リンクの色 */
.content-news a {
    color: #085;
}

/* レイアウト・余白 */
.news-article-body :is(h2, h3, h4, h5, h6) {
  font-weight: 700;
}

.content-time {
    margin-bottom: 2rem;
}


/* ブロック間の余白をエディタ表示に合わせる */
.news-article-body > * + * {
    margin-top: 2rem;
}

.content-news ol {
    list-style-type: decimal;
    padding-left: 1.5em;
}

/* カラム内なども含め、連続する段落間の余白を確保 */
.content-news p + p {
  margin-top: 1rem;
}

/* 一覧ページの新着ラベル */
.news-meta .new {
    font: italic 12px "Times New Roman";
    color: red;
    margin-right: 8px;
}

/* ページネーション */
.navigation.pagination {
    max-width: 72rem;
    margin: 3rem auto 2rem;
    padding: 0 1rem;
}

.navigation.pagination .nav-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    row-gap: 0.5rem;
    margin-top: 2rem;
}

.navigation.pagination .page-numbers {
    display: inline-block;
    text-align: center;
    line-height: 2.5rem;
    color: var(--category-green);
    cursor: pointer;
    transition: all 0.3s ease;
    padding-inline: 1.5rem;
}

.navigation.pagination .page-numbers + .page-numbers {
    border-left: 1px solid #ddd;
}

.navigation.pagination .page-numbers.current,
.navigation.pagination a.page-numbers:hover {
    background-color: rgb(0 136 85 / 0.1);
}

@media (max-width: 480px) {
    .navigation.pagination .nav-links {
        gap: 0.25rem;
    }
}

/* アーカイブリンク */
.archive-year-wrapper {
    max-width: 72rem;
    margin: 3rem auto 2rem;
    padding: 0 1rem;
}

.archive-links {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.archive-links li {
    transition: all 0.3s ease;
}

.archive-links li + li {
    border-left: 1px solid #ddd;
}

/* 年度ナビ：旧news.cssのli:hoverを無効化 */
.archive-links li:hover {
    background-color: transparent;
}

/* リンクだけhoverさせる */
.archive-links li a:hover {
    background-color: rgb(0 136 85 / 0.1);
}

.archive-links li span {
    color: #767676;
}

.archive-links li a,
.archive-links li span {
    display: block;
    text-align: center;
    padding-inline: 1.5rem;
}

.archive-links li a {
    color: var(--category-green);
}

@media (max-width: 480px) {
    .archive-links {
        row-gap: 0.5rem;
    }

    .archive-links li a,
    .archive-links li span {
        font-size: 0.9rem;
    }
}

/* News一覧に戻る */
.news-link {
  &.news-link--back {
    & a {
      border-bottom: none;

      &::before {
        content: "";
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        height: 1px;
        background-color: #999;
        transition: left 0.3s ease;
      }

      &::after {
        content: "";
        transform: rotate(-45deg);
        left: -1px;
        bottom: 3px;
        transition: left 0.3s ease;
      }

      &:hover {
        &::before {
          left: -5px;
        }

        &::after {
          left: -6px;
        }
      }
    }
  }
}

/* 記事本文外へのfloat回り込み防止 */
.news-article-body {
  display: flow-root;
}

/* 記事内ページネーション */
.news-page-links {
  clear: both;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
  margin-top: 3rem;
}

.news-page-links .post-page-numbers {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid #00876d;
  border-radius: 50%;
  color: #00876d;
  background: transparent;
  text-decoration: none;
  font-size: 0.875rem;
  line-height: 1;
}

.news-article-body .news-page-links .post-page-numbers.current,
.news-article-body .news-page-links a.post-page-numbers:hover {
  background-color: #00876d;
  color: #fff;
}

/* プルクオートの上余白 */
.news-article-body > .wp-block-pullquote {
  margin-top: 2rem;
}

