/* =====================================================================
   Blog: listing (home.php / category / tag), article cards, single-post extras
   ===================================================================== */
/* WordPress gives the blog page <body class="blog">, which the original site also used for a homepage grid. */
body.blog { display: block; }

.bp, .bp-related { --bp-line: #e7dccb; --bp-ink: #2b2118; --bp-muted: #7a6d5f; font-family: var(--ui, 'Jost', sans-serif); }
.bp .screen-reader-text { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.bp-intro { max-width: 760px; margin: 0 auto 34px; text-align: center; color: #5b5045; font-size: 17px; line-height: 1.7; }

/* ---- category buttons + search ---- */
.bp-tools { display: flex; align-items: center; gap: 20px; margin-bottom: 30px; padding-bottom: 18px; border-bottom: 1px solid var(--bp-line); }
.bp-cats { display: flex; gap: 10px; flex: 1; min-width: 0; overflow-x: auto; padding: 2px; scrollbar-width: thin; }
.bp-chip { flex: none; display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border: 1px solid var(--bp-line); border-radius: 999px; background: #fff; color: var(--bp-ink); font-size: 14.5px; font-weight: 500; text-decoration: none; transition: border-color .2s, background .2s, color .2s; }
.bp-chip span { padding: 3px 7px; border-radius: 999px; background: var(--orange-soft, #fdeed8); color: var(--orange-ink, #a8620a); font-size: 11.5px; font-weight: 600; }
.bp-chip:hover { border-color: var(--orange, #f9a94a); }
.bp-chip.is-active { background: var(--bp-ink); border-color: var(--bp-ink); color: #fff; }
.bp-chip.is-active span { background: var(--orange, #f9a94a); color: var(--bp-ink); }
.bp-search { position: relative; flex: 0 0 300px; }
.bp-search input { width: 100%; height: 46px; padding: 0 50px 0 16px; border: 1px solid var(--bp-line); border-radius: 999px; background: #fff; font: 400 15px var(--ui, sans-serif); color: var(--bp-ink); }
.bp-search input:focus { outline: 2px solid var(--orange, #f9a94a); outline-offset: 1px; }
.bp-search button { position: absolute; top: 5px; right: 5px; display: grid; place-items: center; width: 36px; height: 36px; border: 0; border-radius: 50%; background: var(--bp-ink); color: #fff; cursor: pointer; }
.bp-search button .ic { width: 16px; height: 16px; }

/* ---- article card ---- */
.bp-card { display: flex; flex-direction: column; overflow: hidden; background: #fff; border: 1px solid #ece3d6; border-radius: 12px; box-shadow: 0 4px 18px rgba(43, 33, 24, .05); transition: transform .35s var(--ease, ease), box-shadow .35s; }
.bp-card:hover { transform: translateY(-5px); box-shadow: 0 22px 44px rgba(43, 33, 24, .13); }
.bp-card__img { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: #e9dfd0; }
.bp-card__img img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease, ease); }
.bp-card:hover .bp-card__img img { transform: scale(1.06); }
.bp-flag { position: absolute; top: 16px; left: 16px; padding: 7px 13px; border-radius: 999px; background: var(--orange, #f9a94a); color: var(--bp-ink); font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.bp-card__body { display: flex; flex-direction: column; flex: 1; padding: 20px 22px 22px; }
.bp-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin: 0 0 10px; font-size: 13px; color: var(--bp-muted); }
.bp-meta > span + span { padding-left: 14px; border-left: 1px solid #e2d7c6; }
.bp-cat { font-size: 11.5px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--orange-ink, #a8620a); text-decoration: none; }
.bp-cat:hover { text-decoration: underline; }
.bp-card__title { margin: 0 0 10px; font-family: var(--head); font-size: 24px; font-weight: 600; line-height: 1.18; }
.bp-card__title a { color: var(--bp-ink); text-decoration: none; }
.bp-card__title a:hover { color: var(--orange-ink, #a8620a); }
.bp-card__text { margin: 0 0 18px; font-size: 15px; line-height: 1.6; color: #5b5045; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.bp-more { display: inline-flex; align-items: center; gap: 6px; margin-top: auto; padding-top: 14px; border-top: 1px solid #efe7db; font-size: 12.5px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--orange-ink, #a8620a); text-decoration: none; }
.bp-more .ic { width: 15px; height: 15px; transition: transform .3s; }
.bp-card:hover .bp-more .ic { transform: translateX(4px); }

/* featured (first) article */
.bp-card--big { flex-direction: row; margin-bottom: 30px; }
.bp-card--big .bp-card__img { flex: 0 0 58%; aspect-ratio: auto; min-height: 420px; }
.bp-card--big .bp-card__img img { position: absolute; inset: 0; }
.bp-card--big .bp-card__body { justify-content: center; padding: 40px 44px; }
.bp-card--big .bp-card__title { font-size: clamp(30px, 2.6vw, 40px); line-height: 1.1; }
.bp-card--big .bp-card__text { -webkit-line-clamp: 5; font-size: 16.5px; }
.bp-card--big .bp-more { align-self: flex-start; margin-top: 8px; padding: 14px 22px; border: 0; border-radius: 8px; background: var(--bp-ink); color: #fff; }
.bp-card--big .bp-more:hover { background: var(--orange, #f9a94a); color: var(--bp-ink); }

/* grid */
.bp-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }

/* ---- page numbers ---- */
.bp-pages { margin-top: 44px; }
.bp-pages .nav-links { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px; }
.bp-pages .page-numbers { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-width: 46px; height: 46px; padding: 0 14px; border: 1px solid var(--bp-line); border-radius: 10px; background: #fff; color: var(--bp-ink); font: 500 15px var(--ui, sans-serif); text-decoration: none; transition: border-color .2s, background .2s; }
.bp-pages a.page-numbers:hover { border-color: var(--orange, #f9a94a); background: var(--orange-soft, #fdeed8); }
.bp-pages .page-numbers.current { background: var(--bp-ink); border-color: var(--bp-ink); color: #fff; }
.bp-pages .page-numbers.dots { border: 0; background: none; min-width: 20px; padding: 0; }
.bp-pages .page-numbers .ic { width: 16px; height: 16px; }
.bp-pages .prev, .bp-pages .next { font-weight: 600; }
.bp-empty { text-align: center; color: var(--bp-muted); }

/* ---- single post: "Keep reading" ---- */
.bp-related { padding: 70px 0 80px; background: var(--cream, #faf6ef); border-top: 1px solid #efe7db; }
.bp-related__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 28px; }
.bp-related__head .h2 { margin: 6px 0 0; }
.bp-related .bp-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.bp-related .bp-card__title { font-size: 21px; }
.bp-related .bp-card__text { -webkit-line-clamp: 2; font-size: 14.5px; }

/* ---- responsive ---- */
@media (max-width: 1200px) {
  .bp-related .bp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1000px) {
  .bp-tools { flex-direction: column; align-items: stretch; }
  .bp-search { flex: none; }
  .bp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bp-card--big { flex-direction: column; }
  .bp-card--big .bp-card__img { flex: none; min-height: 0; aspect-ratio: 16 / 9; }
  .bp-card--big .bp-card__body { padding: 26px 26px 28px; }
}
@media (max-width: 640px) {
  .bp-cats { margin: 0 calc(var(--gutter, 16px) * -1); padding: 2px var(--gutter, 16px); }
  .bp-grid, .bp-related .bp-grid { grid-template-columns: 1fr; }
  .bp-card__title { font-size: 22px; }
  .bp-related__head { flex-direction: column; align-items: flex-start; }
  .bp-pages .prev span, .bp-pages .next span { display: none; }
}

.bp-related .bp-meta > span:last-child { display: none; }
