/*
| Blog (Step 49) - list page + article page. Everything is namespaced .bl- ; loaded only by blog.php and post.php.
| Colours follow the site: navy #0b1b2e, gold #dbaa3e / #a67815, Georgia headings.
*/
.bl-wrap { max-width: 1160px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); box-sizing: border-box; }
.bl-muted { color: #6b7b8c; }

/* ---------- list page: hero + search ---------- */
.bl-hero { padding: clamp(44px, 6vw, 72px) 0 clamp(34px, 4vw, 48px); color: #fff; background: radial-gradient(90% 140% at 12% 0%, rgba(219, 170, 62, .16), transparent 60%), linear-gradient(135deg, #0b1b2e, #12324f); }
.bl-eyebrow { margin: 0 0 12px; font-size: 12px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: #dbaa3e; }
body .bl-hero h1 { margin: 0 0 12px; max-width: 760px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(30px, 4.6vw, 46px) !important; line-height: 1.15; color: #fff; }
.bl-hero .bl-sub { margin: 0; max-width: 640px; font-size: clamp(15px, 1.6vw, 17.5px); line-height: 1.6; color: #b9c7d5; }
.bl-search { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 26px; max-width: 560px; }
.bl-search input[type="search"] { flex: 1 1 240px; min-width: 0; height: 48px; padding: 0 16px; border: 1px solid rgba(255, 255, 255, .22); border-radius: 12px; font: inherit; font-size: 15px; color: #fff; background: rgba(255, 255, 255, .08); }
.bl-search input[type="search"]::placeholder { color: #93a6b8; }
.bl-search input[type="search"]:focus { outline: 2px solid #dbaa3e; outline-offset: 1px; }
.bl-search button, .bl-search a.bl-clear { height: 48px; padding: 0 22px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 12px; font: inherit; font-size: 14.5px; font-weight: 800; cursor: pointer; text-decoration: none; }
.bl-search button { color: #1b2736; background: linear-gradient(135deg, #f5dc97, #d5a13a); }
.bl-search a.bl-clear { color: #e6edf4; background: rgba(255, 255, 255, .1); }

.bl-list { padding: clamp(28px, 4vw, 48px) 0 clamp(36px, 5vw, 64px); }
.bl-count { margin: 0 0 22px; font-size: 14px; color: #6b7b8c; }

/* featured (first) article */
.bl-featured { display: grid; grid-template-columns: 1.15fr 1fr; gap: 0; margin: 0 0 30px; overflow: hidden; border: 1px solid #e0e6ec; border-radius: 22px; background: #fff; box-shadow: 0 14px 40px rgba(11, 27, 46, .08); }
.bl-featured .bl-cover { min-height: 300px; }
.bl-featured .bl-featured-body { padding: clamp(22px, 3.4vw, 40px); display: flex; flex-direction: column; justify-content: center; gap: 4px; }
.bl-chip { display: inline-block; width: fit-content; margin-bottom: 10px; padding: 5px 12px; border-radius: 999px; font-size: 11.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: #7a560a; background: #f8ecc9; }
.bl-meta { margin: 0 0 8px; font-size: 13px; color: #7b8b9a; }
.bl-meta span + span::before { content: "·"; margin: 0 8px; }
body .bl-featured h2 { margin: 0 0 10px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(22px, 2.6vw, 30px) !important; line-height: 1.25; }
body .bl-card h2 { margin: 0 0 8px; font-family: Georgia, "Times New Roman", serif; font-size: 20px !important; line-height: 1.3; }
.bl-featured h2 a, .bl-card h2 a { color: #0b1b2e; text-decoration: none; }
.bl-featured h2 a:hover, .bl-card h2 a:hover { color: #a67815; }
.bl-excerpt { margin: 0 0 16px; font-size: 15px; line-height: 1.65; color: #4b5c6d; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.bl-read { display: inline-flex; align-items: center; gap: 8px; width: fit-content; font-size: 14.5px; font-weight: 800; color: #a67815; text-decoration: none; }
.bl-read::after { content: "→"; transition: transform .18s ease; }
.bl-read:hover::after { transform: translateX(4px); }

/* cover picture or the pattern that stands in for it */
.bl-cover { display: block; position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: linear-gradient(135deg, #0f2a44, #1d4a6b); }
.bl-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bl-cover.bl-noimg::before { content: ""; position: absolute; inset: 0; background: radial-gradient(70% 90% at 80% 10%, rgba(219, 170, 62, .35), transparent 60%), repeating-linear-gradient(135deg, rgba(255, 255, 255, .04) 0 2px, transparent 2px 16px); }
.bl-cover.bl-noimg::after { content: "Y"; position: absolute; left: 22px; bottom: 14px; font: 700 54px/1 Georgia, serif; color: rgba(219, 170, 62, .85); }

/* card grid */
.bl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 24px; }
.bl-card { display: flex; flex-direction: column; overflow: hidden; border: 1px solid #e0e6ec; border-radius: 18px; background: #fff; transition: transform .2s ease, box-shadow .2s ease; }
.bl-card:hover { transform: translateY(-3px); box-shadow: 0 16px 36px rgba(11, 27, 46, .12); }
.bl-card .bl-card-body { display: flex; flex-direction: column; flex: 1; padding: 20px 22px 22px; }
.bl-card .bl-excerpt { -webkit-line-clamp: 3; }
.bl-card .bl-read { margin-top: auto; }

.bl-empty { padding: 48px 24px; text-align: center; border: 1px dashed #cfd8e0; border-radius: 18px; background: #fbfcfd; }
body .bl-empty h2 { margin: 0 0 8px; font-family: Georgia, serif; font-size: 24px !important; color: #0b1b2e; }
.bl-empty p { margin: 0 auto 18px; max-width: 460px; color: #5e6f80; }

/* call-to-action band (list page) */
.bl-cta { margin: 0 0 clamp(36px, 5vw, 64px); padding: clamp(24px, 3.4vw, 38px); display: flex; align-items: center; justify-content: space-between; gap: 22px; flex-wrap: wrap; color: #fff; border-radius: 22px; background: linear-gradient(135deg, #0b1b2e, #12324f); }
body .bl-cta h2 { margin: 0 0 6px; font-family: Georgia, serif; font-size: clamp(21px, 2.4vw, 27px) !important; color: #fff; }
.bl-cta p { margin: 0; max-width: 560px; font-size: 15px; line-height: 1.6; color: #b9c7d5; }
.bl-cta .bl-btns, .bl-post-cta .bl-btns { display: flex; gap: 12px; flex-wrap: wrap; }
.bl-btn { display: inline-flex; align-items: center; justify-content: center; padding: 12px 22px; border-radius: 12px; font-size: 14.5px; font-weight: 800; text-decoration: none; }
.bl-btn.gold { color: #1b2736 !important; background: linear-gradient(135deg, #f5dc97, #d5a13a); box-shadow: 0 8px 20px rgba(213, 161, 58, .28); }
.bl-btn.ghost { color: #fff !important; border: 1px solid rgba(255, 255, 255, .3); }

/* ---------- article page: dark title band, cover card, article + sticky side panel ---------- */
.bl-phero { padding: clamp(28px, 4vw, 48px) 0 clamp(34px, 4.5vw, 56px); color: #fff; background: radial-gradient(90% 140% at 12% 0%, rgba(219, 170, 62, .16), transparent 60%), linear-gradient(135deg, #0b1b2e, #12324f); }
.bl-phero.has-cover { padding-bottom: clamp(96px, 10vw, 128px); }
.bl-crumbs { margin: 0 0 20px; font-size: 13.5px; color: #93a6b8; }
.bl-crumbs a { color: #f0d28a; text-decoration: none; }
.bl-crumbs a:hover { text-decoration: underline; }
.bl-crumbs span { margin: 0 7px; }
.bl-phero .bl-chip { margin-bottom: 14px; color: #f0d28a; background: rgba(219, 170, 62, .16); }
body .bl-phero h1 { max-width: 880px; margin: 0 0 14px; font-family: Georgia, "Times New Roman", serif; font-size: clamp(28px, 4.2vw, 44px) !important; line-height: 1.2; color: #fff; }
.bl-phero .bl-lede { max-width: 760px; margin: 0 0 22px; font-size: clamp(16px, 1.8vw, 18.5px); line-height: 1.65; color: #b9c7d5; }
.bl-byline { display: flex; align-items: center; gap: 12px; }
.bl-byline b { display: block; font-size: 14.5px; color: #fff; }
.bl-byline small { display: block; margin-top: 2px; font-size: 13px; color: #93a6b8; }
.bl-avatar { width: 44px; height: 44px; flex: none; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; font: 700 20px/1 Georgia, serif; color: #1b2736; background: linear-gradient(135deg, #f5dc97, #d5a13a); }

.bl-postwrap { padding-bottom: clamp(30px, 4vw, 52px); }
.bl-featured { grid-template-columns: 1.55fr 1fr; }
.bl-featured .bl-cover { aspect-ratio: auto; min-height: 340px; }
.bl-featured .bl-cover img { position: absolute; inset: 0; height: 100%; }
.bl-covercard { position: relative; z-index: 2; margin: -78px 0 38px; overflow: hidden; border-radius: 22px; background: #0b1b2e; box-shadow: 0 22px 60px rgba(11, 27, 46, .28); }
.bl-covercard img { display: block; width: 100%; height: auto; max-height: 500px; object-fit: cover; }
.bl-phero:not(.has-cover) + .bl-postwrap { padding-top: clamp(28px, 4vw, 44px); }

.bl-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: clamp(32px, 5vw, 64px); align-items: start; }
.bl-article { min-width: 0; max-width: 760px; }
.bl-side { position: sticky; top: 96px; display: grid; gap: 20px; min-width: 0; }
.bl-side .bl-toc { margin: 0; padding: 16px 18px; background: #fff; box-shadow: 0 8px 26px rgba(11, 27, 46, .06); }
.bl-toc a.is-active { color: #a67815; font-weight: 800; }
.bl-toc-inline { display: none; }

.bl-sidecta { padding: 22px 22px 24px; border-radius: 20px; color: #fff; background: radial-gradient(120% 90% at 100% 0%, rgba(219, 170, 62, .28), transparent 60%), linear-gradient(150deg, #0b1b2e, #12324f); box-shadow: 0 14px 36px rgba(11, 27, 46, .2); }
.bl-sidecta .bl-eyebrow { margin-bottom: 8px; }
body .bl-side .bl-sidecta h2 { margin: 0 0 8px; font-family: Georgia, serif; font-size: 22px !important; line-height: 1.25; color: #fff; }
.bl-sidecta p { margin: 0 0 16px; font-size: 14.5px; line-height: 1.6; color: #b9c7d5; }
.bl-sidecta p.bl-eyebrow { margin: 0 0 8px; color: #dbaa3e; font-size: 12px; }
.bl-sidecta .bl-btn { width: 100%; box-sizing: border-box; }
.bl-sideimg { display: block; width: 100%; height: auto; margin: -6px 0 16px; border-radius: 12px; }
.bl-sideshare { margin: 0; padding: 16px 18px; border: 1px solid #e0e6ec; border-radius: 16px; background: #fff; gap: 10px; }
.bl-sideshare b { flex: 0 0 100%; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: #7b8b9a; }

.bl-body { margin-top: 4px; }
.bl-pn { max-width: none; margin-top: 40px; }
.bl-progress { position: fixed; left: 0; top: 0; z-index: 250; height: 3px; width: 0; background: linear-gradient(90deg, #f5dc97, #d5a13a); transition: width .1s linear; }
.bl-toc { margin: 0 0 30px; padding: 16px 20px; border: 1px solid #e0e6ec; border-radius: 14px; background: #f7f9fb; }
.bl-toc summary { cursor: pointer; font-size: 14px; font-weight: 800; color: #0b1b2e; }
.bl-toc ol { margin: 12px 0 2px; padding-left: 20px; }
.bl-toc li { margin: 5px 0; font-size: 14.5px; }
.bl-toc a { color: #385069; text-decoration: none; }
.bl-toc a:hover { color: #a67815; text-decoration: underline; }
.bl-body { font-size: 18px; line-height: 1.8; color: #1f2f3f; overflow-wrap: anywhere; }
.bl-body p { margin: 0 0 1.15em; }
body .bl-body h2 { margin: 1.9em 0 .55em; padding-top: .2em; font-family: Georgia, "Times New Roman", serif; font-size: clamp(23px, 3vw, 29px) !important; line-height: 1.28; color: #0b1b2e; scroll-margin-top: 90px; }
body .bl-body h2::after { content: ""; display: block; width: 44px; height: 3px; margin-top: 10px; border-radius: 3px; background: #dbaa3e; }
body .bl-body h3 { margin: 1.5em 0 .4em; font-family: Georgia, "Times New Roman", serif; font-size: 21px !important; line-height: 1.3; color: #0b1b2e; }
.bl-body ul, .bl-body ol { margin: 0 0 1.2em; padding-left: 1.4em; }
.bl-body li { margin: .45em 0; padding-left: .2em; }
.bl-body a { color: #a67815; text-decoration: underline; text-underline-offset: 3px; }
.bl-body a:hover { color: #7a560a; }
.bl-body strong { color: #0b1b2e; }
.bl-body code { padding: .12em .4em; border-radius: 6px; font-size: .9em; background: #eef2f6; color: #14385a; }
.bl-body hr { margin: 2.2em 0; border: 0; border-top: 1px solid #dfe5eb; }
.bl-body blockquote { margin: 1.5em 0; padding: 14px 20px; border-left: 4px solid #dbaa3e; border-radius: 0 12px 12px 0; background: #faf6ea; color: #4a3c14; font-style: italic; }
.bl-body .bl-note { margin: 1.5em 0; padding: 15px 18px; border: 1px solid #ecd9a3; border-left: 4px solid #d6a348; border-radius: 12px; background: #fff8e6; font-size: 16px; line-height: 1.65; color: #5a4310; }
.bl-body figure { margin: 1.8em 0; }
.bl-body figure img, .bl-body > img { max-width: 100%; height: auto; border-radius: 14px; display: block; }
.bl-body figcaption { margin-top: 8px; font-size: 13.5px; text-align: center; color: #7b8b9a; }
.bl-body .bl-table { margin: 1.5em 0; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.bl-body table { width: 100%; min-width: 420px; border-collapse: collapse; font-size: 15.5px; line-height: 1.5; }
.bl-body th, .bl-body td { padding: 10px 12px; border: 1px solid #dfe5eb; text-align: left; vertical-align: top; }
.bl-body th { background: #0b1b2e; color: #fff; font-weight: 700; }
.bl-body tbody tr:nth-child(even) td { background: #f7f9fb; }
.bl-share { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 34px 0 0; padding: 18px 0; border-top: 1px solid #e0e6ec; border-bottom: 1px solid #e0e6ec; font-size: 14px; }
.bl-share b { color: #0b1b2e; }
.bl-share a, .bl-share button { display: inline-flex; align-items: center; height: 38px; padding: 0 16px; border: 1px solid #d5dde5; border-radius: 999px; font: inherit; font-size: 13.5px; font-weight: 700; color: #33475c; background: #fff; text-decoration: none; cursor: pointer; }
.bl-share a:hover, .bl-share button:hover { border-color: #dbaa3e; color: #7a560a; }
.bl-more { padding: clamp(30px, 4vw, 52px) 0 clamp(36px, 5vw, 64px); background: #f4f7fa; }
body .bl-more h2 { margin: 0 0 22px; font-family: Georgia, serif; font-size: clamp(22px, 2.6vw, 28px) !important; color: #0b1b2e; }
.bl-pn { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; max-width: 720px; margin: 34px auto 0; }
.bl-pn a { display: block; padding: 14px 18px; border: 1px solid #e0e6ec; border-radius: 14px; background: #fff; color: #0b1b2e; text-decoration: none; }
.bl-pn a small { display: block; margin-bottom: 4px; font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: #a67815; }
.bl-pn a:hover { border-color: #dbaa3e; }
.bl-pn .bl-next { text-align: right; }
.bl-search input:focus-visible, .bl-btn:focus-visible, .bl-read:focus-visible, .bl-share a:focus-visible, .bl-share button:focus-visible, .bl-cover:focus-visible { outline: 2px solid #dbaa3e; outline-offset: 3px; }

@media (max-width: 1020px) {
  .bl-layout { grid-template-columns: 1fr; gap: 28px; }
  .bl-side { position: static; }
  .bl-side .bl-toc-side { display: none; }
  .bl-toc-inline { display: block; margin-bottom: 24px; }
  .bl-article { max-width: none; }
}
@media (max-width: 860px) {
  .bl-featured { grid-template-columns: 1fr; }
  .bl-featured .bl-cover { min-height: 0; aspect-ratio: 16 / 9; }
  .bl-featured .bl-cover img { position: static; height: 100%; }
  .bl-pn { grid-template-columns: 1fr; }
  .bl-pn .bl-next { text-align: left; }
  .bl-covercard { margin-top: -60px; border-radius: 16px; }
}
@media (max-width: 560px) {
  .bl-grid { grid-template-columns: 1fr; }
  .bl-body { font-size: 17px; line-height: 1.75; }
  .bl-search button, .bl-search a.bl-clear { flex: 1 1 auto; }
  .bl-cta { text-align: left; }
  .bl-phero.has-cover { padding-bottom: 84px; }
  .bl-covercard { margin-top: -50px; margin-bottom: 26px; }
}
@media (prefers-reduced-motion: reduce) { .bl-card, .bl-read::after, .bl-progress { transition: none; } .bl-card:hover { transform: none; } }
@media print { .bl-progress, .bl-side, .bl-toc-inline, .bl-more, .bl-pn, .bl-search { display: none !important; } .bl-layout { display: block; } .bl-body { font-size: 12pt; } .bl-phero { color: #000; background: none; } body .bl-phero h1 { color: #000; } }
