/* news.css — ニュース一覧（archive.php）・ニュース詳細（single.php）
   お知らせ一覧の行（.news-list / .news-item / .news-cat）と下層ページの見出しは common.css
   並び：ベース → 768px以下 → 480px以下 */

/* ============ 一覧 ============ */
.news-archive__inner { display: grid; grid-template-columns: 240px 1fr; gap: clamp(40px, 6vw, 96px); align-items: start; }
.news-archive__inner > * { min-width: 0; }   /* 横スクロールするカテゴリで列幅が広がらないように */

.news-filter { position: sticky; top: calc(var(--header-h) + 32px); }
.news-filter__label { margin-bottom: 16px; font-family: var(--font-en); font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.news-filter ul { display: grid; gap: 4px; }
.news-filter a {
  position: relative; display: block;
  padding: 10px 0 10px 24px;
  font-weight: 600; letter-spacing: .06em;
  transition: color .3s var(--ease);
}
.news-filter a::before {
  content: ""; position: absolute; left: 0; top: 50%;
  width: 12px; height: 2px; background: var(--line);
  transition: width .3s var(--ease), background-color .3s var(--ease);
}
.news-filter a:hover, .news-filter a[aria-current] { color: var(--accent); }
.news-filter a:hover::before, .news-filter a[aria-current]::before { width: 16px; background: var(--accent); }

.pagination { margin-top: 56px; }
.pagination ul { display: flex; justify-content: center; gap: 8px; }
.pagination__item {
  display: grid; place-items: center;
  width: 48px; height: 48px;
  font-family: var(--font-en); font-weight: 600;
  border: 1px solid var(--line); border-radius: 50%;
  transition: background-color .3s var(--ease), border-color .3s var(--ease), color .3s var(--ease);
}
a.pagination__item:hover { border-color: var(--ink); }
.pagination__item[aria-current] { color: #fff; background: var(--ink); border-color: var(--ink); }
.pagination__item.is-disabled { color: var(--line); }

/* ============ 詳細 ============ */
.page-head--sm { padding-bottom: clamp(32px, 4vw, 48px); }
.page-head--sm .page-head__en { font-size: clamp(48px, 6vw, 80px); }

.post__article { width: min(100% - var(--gutter) * 2, 880px); margin-inline: auto; }
.post__header { padding-bottom: 32px; border-bottom: 1px solid var(--ink); }
.post__meta { display: flex; align-items: center; gap: 16px; }
.post__meta time { font-family: var(--font-en); font-weight: 500; color: var(--muted); }
.post__meta .news-cat { transition: color .3s var(--ease), background-color .3s var(--ease); }
.post__meta .news-cat:hover { color: #fff; background: var(--accent); border-color: var(--accent); }
.post__title {
  margin-top: 20px;
  font-size: clamp(24px, 3vw, 36px); font-weight: 700; line-height: 1.6; letter-spacing: .06em;
  color: var(--ink);
}
.post__thumb { margin-top: 48px; aspect-ratio: 16 / 9; overflow: hidden; }
.post__thumb img { width: 100%; height: 100%; object-fit: cover; }

/* 本文（WPのブロックエディタの出力にもそのまま効く書き方） */
.entry-content { margin-top: 48px; line-height: 2; }
.entry-content > * + * { margin-top: 1.6em; }
.entry-content h2 {
  margin-top: 2.8em; padding-bottom: 16px;
  font-size: clamp(20px, 2.2vw, 26px); font-weight: 700; line-height: 1.6; letter-spacing: .06em;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
  position: relative;
}
.entry-content h2::after { content: ""; position: absolute; left: 0; bottom: -1px; width: 48px; height: 2px; background: var(--accent); }
.entry-content h3 {
  margin-top: 2.4em; padding-left: 16px;
  font-size: 19px; font-weight: 700; line-height: 1.6; letter-spacing: .06em;
  color: var(--ink);
  border-left: 3px solid var(--accent);
}
.entry-content a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.entry-content a:hover { text-decoration: none; }
.entry-content ul, .entry-content ol { padding: 24px 32px; background: var(--paper-2); }
.entry-content ul li { position: relative; padding-left: 20px; }
.entry-content ul li::before { content: ""; position: absolute; left: 0; top: .95em; width: 8px; height: 2px; background: var(--accent); }
.entry-content ol { list-style: decimal; padding-left: 52px; }
.entry-content li + li { margin-top: 6px; }
.entry-content blockquote {
  margin-inline: 0; padding: 28px 32px;
  color: var(--ink); font-weight: 500;
  border-left: 3px solid var(--ink); background: var(--paper-2);
}
.entry-content img { margin-inline: auto; }
.entry-content figcaption { margin-top: 8px; font-size: 13px; color: var(--muted); text-align: center; }
.entry-content table { width: 100%; border-collapse: collapse; border-top: 1px solid var(--ink); }
.entry-content th, .entry-content td { padding: 16px 20px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.entry-content th { width: 30%; font-weight: 700; color: var(--ink); background: var(--paper-2); }

/* 前後の記事 */
.post-nav {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px;
  margin-top: 80px; padding-top: 40px; border-top: 1px solid var(--line);
}
.post-nav__item { display: grid; gap: 4px; min-width: 0; }
.post-nav__next { text-align: right; }
.post-nav__label { font-family: var(--font-en); font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); transition: color .3s var(--ease); }
.post-nav__prev .post-nav__label::before { content: "← "; }
.post-nav__next .post-nav__label::after { content: " →"; }
.post-nav__title { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 14px; font-weight: 500; transition: color .3s var(--ease); }
a.post-nav__item:hover .post-nav__label, a.post-nav__item:hover .post-nav__title { color: var(--accent); }
.post-nav__back {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; padding: 0 32px;
  font-weight: 600; letter-spacing: .08em;
  border: 1px solid var(--ink); border-radius: 999px;
  transition: background-color .3s var(--ease), color .3s var(--ease);
}
.post-nav__back:hover { color: #fff; background: var(--ink); }

/* ============ 768px以下 ============ */
@media (max-width: 768px) {
  .news-archive__inner { grid-template-columns: 1fr; gap: 32px; }
  .news-filter { position: static; }
  .news-filter__label { display: none; }
  .news-filter ul { display: flex; gap: 8px; overflow-x: auto; margin-inline: calc(var(--gutter) * -1); padding-inline: var(--gutter); scrollbar-width: none; }
  .news-filter ul::-webkit-scrollbar { display: none; }
  .news-filter a { flex: none; padding: 8px 20px; font-size: 14px; white-space: nowrap; border: 1px solid var(--line); border-radius: 999px; }
  .news-filter a::before { display: none; }
  .news-filter a[aria-current] { color: #fff; background: var(--ink); border-color: var(--ink); }
  .pagination { margin-top: 40px; }
  .pagination__item { width: 44px; height: 44px; }

  .post__thumb { margin-top: 32px; }
  .entry-content { margin-top: 32px; }
  .entry-content ul, .entry-content ol { padding: 20px; }
  .entry-content ol { padding-left: 40px; }
  .entry-content blockquote { padding: 20px; }
  .entry-content th, .entry-content td { display: block; width: 100%; padding: 12px 16px; }
  .entry-content th { border-bottom: 0; }

  .post-nav { grid-template-columns: 1fr 1fr; margin-top: 56px; }
  .post-nav__back { grid-column: 1 / -1; grid-row: 2; }
}

/* ============ 480px以下 ============ */
@media (max-width: 480px) {
  .post-nav__title { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
}
