/* ============================================================
   NEWS / COLUMN ARCHIVE
   Reference layout adapted to the Sayama Construction identity.
   ============================================================ */

.news-page {
  --news-ink: #161e29;
  --news-text: #3e4642;
  --news-muted: #77807b;
  --news-line: #dce8e0;
  --news-surface: #eef8f1;
  --news-green-dark: #087b3c;
  background: #fff;
  color: var(--news-ink);
}

.news-page .page {
  overflow: hidden;
}

.news-page .header__logo-light {
  display: none;
}

.news-page .header__logo-dark {
  display: block;
}

.news-page main {
  position: relative;
}

.news-container {
  width: min(1320px, calc(100% - 48px));
  margin-inline: auto;
}

.eyebrow {
  margin: 0;
  font-family: var(--font-en);
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .16em;
}

.eyebrow--green {
  color: var(--brand);
}

/* ---------- Page hero ---------- */

.news-hero {
  position: relative;
  isolation: isolate;
  min-height: 520px;
  padding: 178px 24px 106px;
  overflow: hidden;
  display: grid;
  place-items: center;
  color: #fff;
  text-align: center;
  background:
    radial-gradient(circle at 13% 76%, rgba(255,255,255,.09) 0 92px, transparent 93px),
    radial-gradient(circle at 83% 25%, rgba(255,255,255,.07) 0 180px, transparent 181px),
    linear-gradient(118deg, #08793b 0%, #0da44f 52%, #18b866 100%);
}

.news-hero::before,
.news-hero::after,
.news-hero__accent {
  content: "";
  position: absolute;
  z-index: -1;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 50%;
  pointer-events: none;
}

.news-hero::before {
  top: 132px;
  left: -120px;
  width: 430px;
  height: 430px;
}

.news-hero::after {
  right: -160px;
  bottom: -260px;
  width: 610px;
  height: 610px;
}

.news-hero__accent {
  top: 120px;
  right: 19%;
  width: 170px;
  height: 320px;
  border-radius: 100%;
  transform: rotate(42deg);
  background: rgba(255,255,255,.055);
}

.news-hero__inner {
  position: relative;
  z-index: 1;
  width: min(720px, 100%);
}

.news-hero .eyebrow {
  color: rgba(255,255,255,.78);
}

.news-hero h1 {
  margin-top: 24px;
  font-size: clamp(44px, 5vw, 68px);
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: .04em;
}

.news-hero__inner > p:last-of-type {
  margin-top: 24px;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.9;
}

/* ---------- Breadcrumb ---------- */

.breadcrumb {
  background: #fff;
  border-bottom: 1px solid var(--news-line);
}

.breadcrumb ol {
  width: min(1320px, calc(100% - 48px));
  min-height: 64px;
  margin-inline: auto;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  color: var(--news-muted);
  font-size: 13px;
}

.breadcrumb li {
  display: inline-flex;
  align-items: center;
}

.breadcrumb li + li::before {
  content: "/";
  margin-right: 10px;
  color: #aeb8b2;
}

.breadcrumb a {
  transition: color .2s ease;
}

.breadcrumb a:hover {
  color: var(--brand);
}

/* ---------- Archive shell ---------- */

.news-archive {
  padding: 88px 0 128px;
  background:
    radial-gradient(circle at 0 16%, rgba(13,164,79,.06) 0 240px, transparent 241px),
    var(--news-surface);
}

.news-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 312px;
  gap: 48px;
  align-items: start;
}

.archive-head {
  margin-bottom: 40px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
}

.archive-head h2 {
  margin-top: 14px;
  font-size: clamp(30px, 3vw, 42px);
  font-weight: 900;
  line-height: 1.35;
}

/* ---------- Post cards ---------- */

.post-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px 22px;
}

.post-card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(18,67,39,.1);
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 10px 28px rgba(8,60,31,.07);
  transition: transform .25s ease, box-shadow .25s ease;
}

.post-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 18px 38px rgba(8,60,31,.13);
}

.post-card > a {
  display: flex;
  height: 100%;
  flex-direction: column;
}

.post-card__thumb {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #dcebe1;
}

.post-card__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .45s ease;
}

.post-card:hover .post-card__thumb img {
  transform: scale(1.045);
}

.post-card__thumb > span {
  position: absolute;
  top: 14px;
  left: 14px;
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--brand);
  color: #fff;
  font-family: var(--font-en);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
}

.post-card__body {
  flex: 1;
  padding: 22px 20px 24px;
  display: flex;
  flex-direction: column;
}

.post-card__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
  color: var(--news-muted);
  font-size: 12px;
  font-weight: 700;
}

.post-card__meta span {
  padding: 5px 10px;
  border-radius: 999px;
  background: rgba(13,164,79,.09);
  color: var(--brand);
}

.post-card h3 {
  margin-top: 18px;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.7;
  color: var(--news-ink);
}

.post-card__body > p {
  margin-top: 14px;
  color: var(--news-text);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.8;
}

.post-card__more {
  margin-top: auto;
  padding-top: 24px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--brand);
  font-family: var(--font-en);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
}

.post-card__more i {
  font-style: normal;
  transition: transform .2s ease;
}

.post-card:hover .post-card__more i {
  transform: translateX(4px);
}

/* ---------- Pagination ---------- */

.pagination {
  margin-top: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
}

.pagination a,
.pagination span {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid var(--news-line);
  border-radius: 50%;
  background: #fff;
  color: var(--news-text);
  font-size: 13px;
  font-weight: 700;
}

.pagination a:hover,
.pagination .is-current {
  border-color: var(--brand);
  background: var(--brand);
  color: #fff;
}

.pagination .is-disabled {
  opacity: .35;
  pointer-events: none;
}

/* ---------- Sidebar ---------- */

.news-sidebar {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.sidebar-widget {
  overflow: hidden;
  border: 1px solid rgba(18,67,39,.1);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(8,60,31,.055);
}

.widget-head {
  padding: 20px 22px 18px;
  border-bottom: 1px solid var(--news-line);
  background: linear-gradient(135deg, var(--brand), #17b866);
  color: #fff;
}

.widget-head p {
  font-family: var(--font-en);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .16em;
  opacity: .76;
}

.widget-head h2 {
  margin-top: 6px;
  font-size: 18px;
  font-weight: 700;
}

.category-widget ul {
  padding: 8px 20px 14px;
  list-style: none;
}

.category-widget li + li {
  border-top: 1px solid var(--news-line);
}

.category-widget a {
  padding: 15px 2px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--news-text);
  font-size: 14px;
  font-weight: 700;
}

.category-widget a span::before {
  content: "›";
  margin-right: 9px;
  color: var(--brand);
  font-size: 18px;
}

.category-widget b {
  min-width: 28px;
  height: 28px;
  padding-inline: 6px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--news-surface);
  color: var(--brand);
  font-size: 11px;
}

.recent-widget ol,
.popular-widget ol {
  padding: 8px 20px 18px;
  list-style: none;
}

.recent-widget li + li,
.popular-widget li + li {
  border-top: 1px solid var(--news-line);
}

.recent-widget a {
  padding: 14px 0;
  display: grid;
  grid-template-columns: 82px 1fr;
  gap: 13px;
  align-items: center;
}

.recent-widget img {
  width: 82px;
  aspect-ratio: 4 / 3;
  border-radius: 7px;
  object-fit: cover;
}

.recent-widget time {
  color: var(--news-muted);
  font-size: 10px;
  font-weight: 700;
}

.recent-widget h3,
.popular-widget h3 {
  margin-top: 5px;
  color: var(--news-ink);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.55;
}

.popular-widget a {
  position: relative;
  padding: 14px 0;
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 13px;
  align-items: center;
}

.popular-widget img {
  width: 72px;
  aspect-ratio: 1;
  border-radius: 7px;
  object-fit: cover;
}

.popular-widget__rank {
  position: absolute;
  top: 8px;
  left: -7px;
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #c8a139;
  color: #fff;
  font-family: var(--font-en);
  font-size: 11px;
  font-weight: 700;
}

.sidebar-recruit {
  position: relative;
  isolation: isolate;
  min-height: 250px;
  padding: 34px 28px;
  overflow: hidden;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-end;
  color: #fff;
  background:
    linear-gradient(155deg, rgba(4,58,28,.18), rgba(4,58,28,.72)),
    url("../assets/shared/shared-recruit-ph.jpg") center / cover;
}

.sidebar-recruit::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(8,123,60,.15), rgba(8,123,60,.88));
}

.sidebar-recruit p {
  font-family: var(--font-en);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .16em;
}

.sidebar-recruit h2 {
  margin-top: 12px;
  font-size: 21px;
  font-weight: 700;
  line-height: 1.55;
}

.sidebar-recruit span {
  margin-top: 22px;
  padding-bottom: 4px;
  border-bottom: 1px solid rgba(255,255,255,.7);
  font-size: 13px;
  font-weight: 700;
}

/* ---------- Sidebar / WordPressウィジェット ----------
   「外観 > ウィジェット」でお知らせサイドバーに置かれたブロックウィジェット
   （検索・最近の投稿など）を、上のテーマ既定ウィジェットと同じ見た目にそろえる。 */

.news-sidebar .widget_block > *,
.news-sidebar .widget_block .wp-block-group,
.news-sidebar .widget_block .wp-block-group__inner-container {
  margin: 0;
  padding: 0;
}

/* 見出し（最近の投稿など）と検索ラベルを、緑グラデーションのヘッダー帯にする */
.news-sidebar .widget_block :is(h1, h2, h3, h4),
.news-sidebar .wp-block-search__label {
  display: block;
  margin: 0;
  padding: 20px 22px 18px;
  border-bottom: 1px solid var(--news-line);
  background: linear-gradient(135deg, var(--brand), #17b866);
  color: #fff;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.45;
}

/* ヘッダー帯の英字ラベル（.widget-head p 相当）。
   対応ブラウザだけで表示される装飾なので、非対応でも崩れない。 */
.news-sidebar .widget_block :is(h1, h2, h3, h4)::before,
.news-sidebar .wp-block-search__label::before {
  display: block;
  margin-bottom: 6px;
  font-family: var(--font-en);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .16em;
  opacity: .76;
}

.news-sidebar .wp-block-search__label::before {
  content: "SEARCH";
}

.news-sidebar .sidebar-widget:has(.wp-block-latest-posts) :is(h1, h2, h3, h4)::before {
  content: "RECENT POSTS";
}

.news-sidebar .sidebar-widget:has(.wp-block-categories) :is(h1, h2, h3, h4)::before {
  content: "CATEGORY";
}

.news-sidebar .sidebar-widget:has(.wp-block-archives) :is(h1, h2, h3, h4)::before {
  content: "ARCHIVE";
}

/* ---- 検索 ---- */

.news-sidebar .wp-block-search {
  margin: 0;
}

.news-sidebar .wp-block-search__inside-wrapper {
  padding: 18px 20px 20px;
  display: flex;
  gap: 8px;
  align-items: stretch;
}

.news-sidebar .wp-block-search__input {
  min-width: 0;
  flex: 1 1 auto;
  padding: 11px 14px;
  border: 1px solid rgba(18,67,39,.16);
  border-radius: 9px;
  background: var(--news-surface);
  color: var(--news-text);
  font-size: 13px;
  transition: border-color .2s ease, background-color .2s ease, box-shadow .2s ease;
}

.news-sidebar .wp-block-search__input::placeholder {
  color: var(--news-muted);
}

.news-sidebar .wp-block-search__input:focus {
  outline: none;
  border-color: var(--brand);
  background: #fff;
  box-shadow: 0 0 0 3px rgba(13,164,79,.14);
}

.news-sidebar .wp-block-search__button {
  flex: 0 0 auto;
  margin: 0;
  padding: 11px 18px;
  border: 0;
  border-radius: 9px;
  background: var(--brand);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
  cursor: pointer;
  transition: background-color .25s ease;
}

.news-sidebar .wp-block-search__button:hover {
  background: #0b8f45;
}

/* ---- 最近の投稿 ---- */

.news-sidebar .wp-block-latest-posts__list {
  margin: 0;
  padding: 8px 20px 18px;
  list-style: none;
}

.news-sidebar .wp-block-latest-posts__list li {
  display: flex;
  flex-direction: column-reverse;  /* マークアップ上は日付が後ろなので反転させて上に出す */
  align-items: flex-start;
  gap: 5px;
  padding: 14px 0;
}

.news-sidebar .wp-block-latest-posts__list li + li {
  border-top: 1px solid var(--news-line);
}

.news-sidebar .wp-block-latest-posts__post-date {
  color: var(--news-muted);
  font-family: var(--font-en);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .04em;
}

.news-sidebar .wp-block-latest-posts__post-title {
  position: relative;
  padding-left: 15px;
  color: var(--news-ink);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.55;
  text-decoration: none;
  transition: color .2s ease;
}

.news-sidebar .wp-block-latest-posts__post-title::before {
  content: "›";
  position: absolute;
  top: -1px;
  left: 0;
  color: var(--brand);
  font-size: 16px;
}

.news-sidebar .wp-block-latest-posts__post-title:hover {
  color: var(--brand);
}

/* ---- カテゴリー / アーカイブ（今後追加された場合の受け皿） ---- */

.news-sidebar .widget_block :is(.wp-block-categories, .wp-block-archives) {
  margin: 0;
  padding: 8px 20px 14px;
  list-style: none;
}

.news-sidebar .widget_block :is(.wp-block-categories, .wp-block-archives) li + li {
  border-top: 1px solid var(--news-line);
}

.news-sidebar .widget_block :is(.wp-block-categories, .wp-block-archives) a {
  padding: 14px 2px;
  display: block;
  color: var(--news-text);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.news-sidebar .widget_block :is(.wp-block-categories, .wp-block-archives) a:hover {
  color: var(--brand);
}

/* ---------- Tablet ---------- */

@media (max-width: 1100px) {
  .news-layout {
    grid-template-columns: minmax(0, 1fr) 280px;
    gap: 32px;
  }

  .post-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ---------- Mobile ---------- */

@media (max-width: 768px) {
  .news-container {
    width: 100%;
    padding-inline: 15px;
  }

  .news-page .header__logo-light {
    display: none;
  }

  .news-hero {
    min-height: 410px;
    padding: 126px 15px 72px;
  }

  .news-hero::before {
    top: 150px;
    left: -145px;
    width: 320px;
    height: 320px;
  }

  .news-hero::after {
    right: -190px;
    bottom: -220px;
    width: 430px;
    height: 430px;
  }

  .news-hero__accent {
    top: 105px;
    right: 10%;
    width: 100px;
    height: 220px;
  }

  .news-hero h1 {
    margin-top: 18px;
    font-size: 42px;
  }

  .news-hero__inner > p:last-of-type {
    margin-top: 18px;
    font-size: 14px;
    line-height: 1.8;
  }

  .breadcrumb ol {
    width: 100%;
    min-height: 56px;
    padding: 12px 15px;
    font-size: 11px;
  }

  .news-archive {
    padding: 56px 0 80px;
  }

  .news-layout {
    grid-template-columns: 1fr;
    gap: 56px;
  }

  .archive-head {
    margin-bottom: 28px;
  }

  .archive-head h2 {
    margin-top: 10px;
    font-size: 30px;
  }

  .post-list {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .post-card__body {
    padding: 20px 18px 22px;
  }

  .post-card h3 {
    font-size: 17px;
  }

  .post-card__body > p {
    font-size: 13px;
  }

  .pagination {
    margin-top: 40px;
  }

  .pagination a,
  .pagination span {
    width: 38px;
    height: 38px;
  }

  .news-sidebar {
    gap: 22px;
  }

  .sidebar-recruit {
    min-height: 230px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .post-card,
  .post-card__thumb img,
  .post-card__more i {
    transition: none;
  }
}
