/* =========================
  下層ページ共通
========================= */

.l-page {
  padding-bottom: 80px;
}

.l-page__content {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px;
}

/* =========================
  ページヘッダー
========================= */

.page-header__inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 40px;
  align-items: center;
}

.breadcrumb {
  width: 90%;
  margin: 0 auto;
}

.page-header__title {
  position: relative;
  font-size: 32px;
  font-weight: 700;
  line-height: 1.7;
  color: var(--color-main);
  margin: 0px 0 2rem;
  padding: 0 0 0.5rem;
  width: 90%;
  margin: auto;
  margin-bottom: 1em;
}

.page-header__title .under-line {
  border-bottom: 3px solid var(--color-accent);
}

/* 
.page-header__title::after {
  position: absolute;
  content: '';
  width: 10%;
  left: 0;
  bottom: -1px;
  border-bottom: 3px solid var(--color-accent);
} */

.page-header__thumb img {
  width: 100%;
  height: 400px;
  aspect-ratio: 16 / 9;
  border-radius: 6px;
  object-fit: cover;
}

@media (max-width: 768px) {
  .page-header__inner {
    grid-template-columns: 1fr;
  }

  .page-header__title {
    font-size: 26px;
  }
}

/* =========================
  見出し
========================= */
.page-title-area {
  width: 90%;
  margin: auto;
}

.editor-content h2,
.editor-styles-wrapper h2 {
  font-size: 24px;
  /* margin: 60px 0 20px; */
  padding-left: 16px;
  border-left: 4px solid #9a8f7a;
}

.editor-content h3,
.editor-styles-wrapper h3 {
  font-size: 20px;
  margin: 40px 0 16px;
}

.editor-content h4,
.editor-styles-wrapper h4 {
  font-size: 18px;
  margin: 32px 0 12px;
}

.editor-content h5,
.editor-styles-wrapper h5 {
  font-size: 16px;
  margin: 24px 0 10px;
  font-weight: 700;
}

.editor-content h6,
.editor-styles-wrapper h6 {
  font-size: 14px;
  margin: 20px 0 8px;
  color: #666;
}

/* =========================
  セクションごとの装飾と動き（JS連携版）
========================= */

section.content-section {
  padding: 3rem 2rem;
  background-color: #fff;
  margin-top: 3rem;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

section.content-section:first-child {
  animation: fade-up-slow 1.2s ease-out forwards;
}

.js-reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1.2s ease-out, transform 1.2s ease-out;
}

.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@keyframes fade-up-slow {
  0% {
    opacity: 0;
    transform: translateY(30px);
  }

  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.editor-content h2 {
  font-size: 26px;
  padding-left: 16px;
  border-left: 5px solid var(--color-main, #9a8f7a);
  margin-bottom: 1.5rem;
}

@media (max-width: 768px) {
  section.content-section {
    padding: 2rem 1.2rem;
    margin-top: 2rem;
  }
}

/* =========================
  テキスト
========================= */

.editor-content p,
.editor-styles-wrapper p {
  line-height: 1.9;
  margin-bottom: 24px;
}

.editor-content ul,
.editor-styles-wrapper ul {
  padding-left: 1.5em;
  margin-bottom: 24px;
}

.editor-content li,
.editor-styles-wrapper li {
  margin-bottom: 8px;
}

.indent-1em {
  padding-left: 1em;
}

.wp-block-file:not(.wp-element-button) {
  font-size: 1.0em !important;
  font-weight: 600 !important;
}

/* =========================
  画像
========================= */

.editor-content figure,
.editor-styles-wrapper figure {
  margin: 40px 0;
}

.editor-content figcaption,
.editor-styles-wrapper figcaption {
  font-size: 13px;
  color: #666;
  margin-top: 8px;
  text-align: center;
}

/* =========================
  引用
========================= */

.editor-content blockquote,
.editor-styles-wrapper blockquote {
  background: #fff;
  padding: 24px;
  border-left: 4px solid #9a8f7a;
  margin: 40px 0;
}

/* =========================
  ボタン
========================= */

.wp-block-button__link {
  background: #2f3e4e;
  color: #fff;
  padding: 14px 32px;
  border-radius: 9999px;
  font-weight: 600;
}

.wp-block-button__link:hover {
  opacity: 0.85;
}

/* =========================
 Google Map
========================= */

iframe[src*="google.com/maps"] {
  width: 100%;
  max-width: 100%;
  height: 450px;
  border: 0;
}

/* =========================
  固定ページ：ファイルブロック共通制御
  （フロントページ除外）
========================= */

body.page .l-page__content object,
body.page .l-page__content embed,
body.page .l-page__content .wp-block-file__embed,
body.page .l-page__content .wp-block-file__button {
  display: none !important;
}

body.page .l-page__content .wp-block-file a[href$=".pdf"]::before {
  content: "";
  display: inline-block;
  width: 1.6em;
  height: 1.6em;
  margin-right: 0.4em;
  vertical-align: middle;
  background: url("../img/pdf.svg") no-repeat center / contain;
}

/* PDFを本文表示したい場合（例外） */
body.page .pdf-preview .wp-block-file__embed,
body.page .pdf-preview .wp-block-file__button {
  display: block;
}

/* =====================================
   archive 横並びレイアウト
===================================== */

.archive-layout {
  display: flex;
  gap: 60px;
  align-items: flex-start;
}

.archive-main {
  flex: 1;
  min-width: 0;
}

.archive-main a {
  color: var(--color-text);
}

.p-news-sidebar {
  width: 280px;
  flex-shrink: 0;
}

section.p-news-sidebar-section.p-news-sidebar-section--back a.p-news-back-button {
  background-color: #fff;
  padding: .2rem 1rem;
  border-radius: 50vw;
  border: 1px solid var(--color-accent);
}

section.p-news-sidebar-section.p-news-sidebar-section--back a.p-news-back-button:hover {
  background-color: var(--color-accent);
  color: #fff;
}

ul.p-news-archive-list {
  list-style: none;
  padding-left: 1rem;
}

.p-news-archive-list li.is-current>a {
  font-weight: 700;
  color: var(--color-main);
  position: relative;
}

.p-news-archive-list li.is-current>a::before {
  content: "";
  position: absolute;
  left: -14px;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  background: var(--color-main);
  border-radius: 50%;
}

.archive-list article.archive-card {
  padding: 1rem 2rem;
  background-color: #fff;
  margin-bottom: 20px;
  margin-top: 0;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}

.archive-list article.archive-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.archive-card__meta {
  display: flex;
  gap: 1em;
}

.archive-card time {
  font-size: .9rem;
  color: #857985;
}

.archive-card .archive-card__title {
  font-size: 1.1rem;
  transition: color 0.3s ease;
}

.archive-list article.archive-card:hover .archive-card__title {
  color: var(--color-accent);
}

/* =====================================
   ページネーション
   ===================================== */
.p-pagination {
  display: flex;
  justify-content: center;
  margin: 40px 0;
}

.p-pagination ul.page-numbers {
  display: flex;
  align-items: center;
  gap: 8px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.p-pagination ul.page-numbers li a.page-numbers:not(.prev):not(.next),
.p-pagination ul.page-numbers li span.page-numbers.current {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: #fff;
  border: 1px solid #ccc;
  color: #666;
  text-decoration: none;
  font-size: 14px;
  transition: all 0.3s ease;
}

.p-pagination ul.page-numbers li span.page-numbers.current {
  background-color: #555;
  border-color: #555;
  color: #fff;
}

.p-pagination ul.page-numbers li a.page-numbers:not(.prev):not(.next):hover {
  background-color: #f0f0f0;
  border-color: #999;
}

.p-pagination ul.page-numbers li a.prev,
.p-pagination ul.page-numbers li a.next,
.p-pagination ul.page-numbers li span.dots {
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent !important;
  border: none !important;
  width: auto !important;
  min-width: 30px;
  color: #666;
  text-decoration: none;
}

.p-pagination ul.page-numbers li a.prev,
.p-pagination ul.page-numbers li a.next {
  font-size: 20px;
  font-weight: bold;
  font-family: "serif";
}

section.section.section--blog-single {
  margin: auto;
  padding: 60px 0 0;

}

.section--blog-single .container {
  padding: 3rem 2rem;
  background-color: #fff;
  margin-bottom: 40px;
  margin-top: 0;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.section--blog-single .blog-single__meta {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
}

.section--blog-single h1.page-header__title {
  border-top: 1px solid var(--color-main);
  border-bottom: 1px solid var(--color-main);
}

.blog-single__nav {
  margin: 2rem auto;
  text-align: center;
}

@media (max-width: 900px) {

  .archive-layout {
    flex-direction: column;
  }

  .p-news-sidebar {
    width: 100%;
    margin-top: 40px;
  }
}

/* =========================
   年度まとめ表示
========================= */

.blog-article {
  margin-bottom: 80px;
}

.blog-article.content-section {
  padding: 3rem 2rem;
  background-color: var(--color-accent);
  margin-bottom: 40px;
  margin-top: 0;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.blog-article_box {
  background-color: #fff;
  padding: 3rem 2rem;
  border-radius: 8px;
}

.blog-article.content-section:first-child {
  animation: fade-up-slow 1.2s ease-out forwards;
}

.blog-article__meta {
  font-size: 14px;
  color: #777;
  margin-bottom: 8px;
}

.blog-article__title {
  font-size: 24px;
  margin-bottom: 20px;
  color: var(--color-main);
  padding-left: 16px;
  border-left: 5px solid var(--color-main, #9a8f7a);
}

.blog-article__content p {
  line-height: 1.9;
  margin-bottom: 16px;
}

.blog-article__content img {
  margin: 20px 0;
  max-width: 100%;
  height: auto;
  border-radius: 4px;
}

@media (max-width: 768px) {
  .blog-article.content-section {
    padding: 2rem 1.2rem;
  }

  .blog-article__title {
    font-size: 20px;
  }
}

/* =========================
  404
========================= */
h1.page-header__title.title-404_center {
  text-align: center;
  margin-top: 2rem;
  margin-bottom: 0;
}

.p-error-404__content {
  text-align: center;
  padding: 60px 0;
}

.p-error-404__content p {
  margin-bottom: 20px;
  font-size: 1.1rem;
  line-height: 1.8;
}

.p-error-404__btn {
  margin-top: 40px;
}

.p-error-404__btn .c-btn {
  display: inline-block;
  padding: 15px 40px;
  background: #c8161d;
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
  font-weight: bold;
}

.p-error-404__links {
  margin-top: 60px;
  border-top: 1px solid #eee;
  padding-top: 40px;
}

.p-error-404__links p {
  margin-bottom: 20px;
  font-weight: bold;
}

.p-error-404__links ul {
  list-style: none;
  padding: 0;
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.p-error-404__links ul li {
  color: #333;
  text-decoration: underline;
}