/* ==========================================================================
   Blog: listing page (blog/index.html) and article pages (blog/*.html)
   Loaded after style.css on blog pages only. Colours follow the About
   section: ink #0e3e2f, green #07784c, brand #00734a, lime #c4c60b,
   yellow #ffe86b, deep green #041a13.
   ========================================================================== */

/* body.dark paints the page #101010 and turns headings white; blog copy
   reads on a light page, so reset both here */
body.blog-page {
  background-color: #f5f8f6 !important;
  color: #2c3a34;
}

/* ---------- Hero band: dark so the transparent fixed header stays legible */
.pf-blog-hero {
  position: relative;
  overflow: hidden;
  padding: 170px 0 70px;
  color: #ffffff;
  background:
    radial-gradient(ellipse 60% 70% at 10% 0%, rgba(0, 168, 98, .32), transparent 60%),
    radial-gradient(ellipse 50% 60% at 90% 20%, rgba(196, 198, 11, .18), transparent 60%),
    #041a13;
}

/* faint graph-paper grid, fading out towards the bottom */
.pf-blog-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent);
  mask-image: linear-gradient(to bottom, #000 30%, transparent);
  pointer-events: none;
}

.pf-blog-hero .container {
  position: relative;
  z-index: 1;
}

/* article hero leaves room for the feature image to overlap it */
.pf-blog-hero.is-article {
  padding-bottom: 160px;
}

.pf-crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 22px;
  padding: 0;
  list-style: none;
  font-size: 14px;
  color: rgba(255, 255, 255, .6);
}

.pf-crumbs li+li::before {
  content: "/";
  margin-right: 6px;
  color: rgba(255, 255, 255, .35);
}

/* style.css sets every link to 18px; blog links take their parent's size */
.pf-crumbs a,
.pf-post-card h2 a,
.pf-article a {
  font-size: inherit;
}

.pf-crumbs a {
  color: rgba(255, 255, 255, .82);
  text-decoration: none;
  transition: color .2s;
}

.pf-crumbs a:hover,
.pf-crumbs a:focus-visible {
  color: #ffe86b;
}

.pf-eyebrow {
  display: inline-block;
  margin-bottom: 18px;
  padding: 6px 14px;
  border: 1px solid rgba(255, 232, 107, .35);
  border-radius: 999px;
  background: rgba(255, 232, 107, .12);
  color: #ffe86b;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .06em;
  line-height: 1.4;
  text-transform: uppercase;
}

.pf-blog-hero h1 {
  max-width: 920px;
  margin: 0 0 18px;
  color: #ffffff;
  font-size: 46px;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -1px;
}

.pf-lede {
  max-width: 720px;
  margin: 0;
  color: rgba(255, 255, 255, .75);
  font-size: 18px;
  line-height: 1.65;
}

.pf-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: rgba(255, 255, 255, .72);
  font-size: 15px;
}

.pf-meta i {
  margin-right: 7px;
  color: #c4c60b;
}

/* ---------- Article page */
.pf-feature {
  position: relative;
  z-index: 2;
  margin-top: -120px;
}

.pf-feature img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 18px;
  box-shadow: 0 24px 60px rgba(4, 26, 19, .28);
}

.pf-article-wrap {
  padding: 56px 0 90px;
}

.pf-article {
  color: #2c3a34;
  font-size: 18px;
  line-height: 1.8;
}

.pf-article p {
  margin: 0 0 22px;
  color: #2c3a34;
}

.pf-article .pf-intro {
  color: #0e3e2f;
  font-size: 20px;
  line-height: 1.75;
}

.pf-article strong {
  color: #0e3e2f;
  font-weight: 700;
}

.pf-article h2 {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin: 48px 0 16px;
  color: #0e3e2f;
  font-size: 28px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: -.4px;
  /* clear the fixed header when jumped to from the contents list */
  scroll-margin-top: 110px;
}

.pf-num {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-top: -3px;
  border-radius: 12px;
  background: linear-gradient(135deg, #07784c, #c4c60b);
  color: #ffffff;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0;
}

.pf-conclusion {
  margin-top: 48px;
  padding: 30px 34px;
  border-left: 4px solid #07784c;
  border-radius: 0 16px 16px 0;
  background: #ffffff;
  box-shadow: 0 10px 30px rgba(14, 62, 47, .08);
}

.pf-article .pf-conclusion h2 {
  margin-top: 0;
}

.pf-article .pf-conclusion p:last-child {
  margin-bottom: 0;
}

/* key-point list: each item is a small card with a title and one line of
   copy, ticked in a green disc. style.css sizes every h3 at 45px, so the
   heading size is set explicitly here. */
.pf-article .pf-points {
  display: grid;
  gap: 14px;
  margin: 6px 0 30px;
  padding: 0;
  list-style: none;
}

.pf-points li {
  position: relative;
  padding: 18px 22px 18px 60px;
  border: 1px solid #e1eae5;
  border-radius: 14px;
  background: #ffffff;
  box-shadow: 0 6px 18px rgba(14, 62, 47, .06);
}

.pf-points li::before {
  content: "";
  position: absolute;
  left: 20px;
  top: 21px;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, #07784c, #c4c60b);
}

/* the tick, drawn as the corner of a rotated box */
.pf-points li::after {
  content: "";
  position: absolute;
  left: 29.5px;
  top: 26px;
  width: 7px;
  height: 12px;
  border: solid #ffffff;
  border-width: 0 2.5px 2.5px 0;
  transform: rotate(45deg);
}

.pf-points h3 {
  margin: 0 0 4px;
  color: #0e3e2f;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.4;
  letter-spacing: -.2px;
}

.pf-article .pf-points p {
  margin: 0;
  font-size: 16px;
  line-height: 1.65;
}

/* numbered variant (an <ol>): the disc carries the item number, no tick */
.pf-points.is-numbered {
  counter-reset: pf-point;
}

.pf-points.is-numbered li {
  counter-increment: pf-point;
}

.pf-points.is-numbered li::before {
  content: counter(pf-point);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
}

.pf-points.is-numbered li::after {
  content: none;
}

/* in-article image (chart, infographic) with a source line; the image links
   to the full-size file so phone readers can zoom into the figures */
.pf-figure {
  margin: 6px 0 30px;
}

.pf-figure a {
  display: block;
  overflow: hidden;
  border: 1px solid #e1eae5;
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(14, 62, 47, .08);
}

.pf-figure img {
  display: block;
  width: 100%;
  height: auto;
}

.pf-figure figcaption {
  margin-top: 10px;
  color: #5d6d66;
  font-size: 14px;
  line-height: 1.55;
}

/* pull quote */
.pf-quote {
  position: relative;
  margin: 8px 0 30px;
  padding: 28px 32px 26px 78px;
  border-radius: 16px;
  background:
    radial-gradient(ellipse 80% 60% at 100% 0%, rgba(196, 198, 11, .24), transparent 60%),
    linear-gradient(150deg, #00734a, #041a13);
  box-shadow: 0 16px 36px rgba(4, 26, 19, .2);
}

.pf-quote::before {
  content: "\201C";
  position: absolute;
  left: 24px;
  top: 14px;
  color: #ffe86b;
  font-size: 76px;
  font-weight: 800;
  line-height: 1;
}

.pf-article .pf-quote p {
  margin: 0 0 12px;
  color: #ffffff;
  font-size: 21px;
  font-weight: 700;
  line-height: 1.5;
}

.pf-quote cite {
  display: block;
  color: rgba(255, 255, 255, .75);
  font-size: 14px;
  font-style: normal;
  line-height: 1.5;
}

/* share row + back link under the article */
.pf-share {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 44px;
  padding-top: 28px;
  border-top: 1px solid #dde7e2;
}

.pf-share-label {
  margin-right: 4px;
  color: #0e3e2f;
  font-size: 15px;
  font-weight: 700;
}

.pf-share a.pf-share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #e3eee8;
  color: #07784c;
  font-size: 16px;
  text-decoration: none;
  transition: background-color .2s, color .2s;
}

.pf-share a.pf-share-btn:hover,
.pf-share a.pf-share-btn:focus-visible {
  background: #07784c;
  color: #ffffff;
}

.pf-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  color: #07784c;
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
}

.pf-back:hover,
.pf-back:focus-visible {
  color: #0e3e2f;
}

/* ---------- Sidebar: contents list + summit call to action */
.pf-aside {
  position: sticky;
  top: 110px;
  display: grid;
  gap: 24px;
}

.pf-toc {
  padding: 24px 26px;
  border: 1px solid #e1eae5;
  border-radius: 16px;
  background: #ffffff;
  box-shadow: 0 10px 30px rgba(14, 62, 47, .08);
}

.pf-toc-title {
  margin: 0 0 10px;
  color: #07784c;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.pf-toc ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

.pf-toc li+li {
  border-top: 1px dashed #e1eae5;
}

.pf-toc a {
  display: flex;
  gap: 10px;
  padding: 9px 0;
  color: #2c3a34;
  font-size: 15px;
  line-height: 1.45;
  text-decoration: none;
  transition: color .2s;
}

.pf-toc a span {
  flex: none;
  min-width: 16px;
  color: #07784c;
  font-weight: 800;
}

.pf-toc a:hover,
.pf-toc a:focus-visible,
.pf-toc a.is-active {
  color: #07784c;
}

.pf-toc a.is-active {
  font-weight: 700;
}

.pf-cta {
  padding: 28px 26px;
  border-radius: 16px;
  color: #ffffff;
  background:
    radial-gradient(ellipse 80% 60% at 100% 0%, rgba(196, 198, 11, .28), transparent 60%),
    linear-gradient(150deg, #00734a, #041a13);
  box-shadow: 0 16px 36px rgba(4, 26, 19, .25);
}

.pf-cta .pf-eyebrow {
  margin-bottom: 14px;
  font-size: 12px;
}

.pf-cta-title {
  margin: 0 0 10px;
  color: #ffffff;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.3;
}

.pf-cta p {
  margin: 0 0 20px;
  color: rgba(255, 255, 255, .8);
  font-size: 15px;
  line-height: 1.6;
}

.pf-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  background: #ffe86b;
  color: #0e3e2f;
  font-size: 15px;
  font-weight: 800;
  text-decoration: none;
  transition: background-color .2s, transform .2s;
}

.pf-cta-btn:hover,
.pf-cta-btn:focus-visible {
  background: #ffffff;
  color: #0e3e2f;
  transform: translateY(-2px);
}

/* ---------- Listing page */
.pf-blog-list {
  padding: 64px 0 90px;
}

.pf-post-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 28px;
}

.pf-post-card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #e1eae5;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 10px 30px rgba(14, 62, 47, .08);
  transition: transform .3s, box-shadow .3s;
}

.pf-post-card:hover,
.pf-post-card:focus-within {
  transform: translateY(-4px);
  box-shadow: 0 20px 44px rgba(14, 62, 47, .16);
}

.pf-post-img {
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: #e3eee8;
}

.pf-post-img img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s;
}

.pf-post-card:hover .pf-post-img img {
  transform: scale(1.04);
}

.pf-post-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 26px 28px 30px;
}

.pf-post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
  margin-bottom: 10px;
  color: #5d6e66;
  font-size: 14px;
}

.pf-post-meta i {
  margin-right: 6px;
  color: #07784c;
}

.pf-post-card h2 {
  margin: 0 0 12px;
  color: #0e3e2f;
  font-size: 24px;
  font-weight: 800;
  line-height: 1.3;
}

.pf-post-card h2 a {
  color: inherit;
  text-decoration: none;
}

/* the title link covers the whole card */
.pf-post-card h2 a::after {
  content: "";
  position: absolute;
  inset: 0;
}

.pf-post-card h2 a:focus-visible {
  outline: none;
}

.pf-post-card:has(h2 a:focus-visible) {
  outline: 3px solid #07784c;
  outline-offset: 3px;
}

.pf-post-card p {
  margin: 0 0 20px;
  color: #2c3a34;
  font-size: 16px;
  line-height: 1.7;
}

.pf-read {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  color: #07784c;
  font-weight: 700;
}

.pf-read i {
  transition: transform .3s;
}

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

/* newest post spans the grid, image beside the copy on desktop */
.pf-post-card.is-featured {
  grid-column: 1 / -1;
}

@media (min-width: 992px) {
  .pf-post-card.is-featured {
    flex-direction: row;
  }

  .pf-post-card.is-featured .pf-post-img {
    flex: 0 0 54%;
    align-self: flex-start;
  }

  .pf-post-card.is-featured .pf-post-body {
    justify-content: center;
    padding: 40px 44px;
  }

  .pf-post-card.is-featured h2 {
    font-size: 30px;
  }

  .pf-post-card.is-featured .pf-read {
    margin-top: 4px;
  }
}

/* ---------- Responsive */
@media (max-width: 991px) {
  .pf-blog-hero {
    padding: 130px 0 50px;
  }

  .pf-blog-hero.is-article {
    padding-bottom: 110px;
  }

  .pf-blog-hero h1 {
    font-size: 34px;
  }

  .pf-feature {
    margin-top: -80px;
  }

  .pf-aside {
    position: static;
    margin-top: 16px;
  }
}

@media (max-width: 575px) {
  .pf-blog-hero h1 {
    font-size: 28px;
    letter-spacing: -.5px;
  }

  .pf-lede {
    font-size: 16px;
  }

  .pf-article {
    font-size: 17px;
  }

  .pf-article .pf-intro {
    font-size: 18px;
  }

  .pf-article h2 {
    gap: 12px;
    font-size: 22px;
  }

  .pf-num {
    width: 36px;
    height: 36px;
    margin-top: -2px;
    font-size: 16px;
  }

  .pf-feature img {
    border-radius: 12px;
  }

  .pf-figure a {
    border-radius: 12px;
  }

  .pf-conclusion {
    padding: 22px 20px;
  }

  .pf-points li {
    padding: 16px 18px 16px 54px;
  }

  .pf-points li::before {
    left: 16px;
    top: 19px;
  }

  .pf-points li::after {
    left: 25.5px;
    top: 24px;
  }

  .pf-points h3 {
    font-size: 17px;
  }

  .pf-quote {
    padding: 64px 22px 22px;
  }

  .pf-quote::before {
    left: 20px;
    top: 10px;
  }

  .pf-article .pf-quote p {
    font-size: 19px;
  }

  .pf-post-grid {
    grid-template-columns: 1fr;
  }

  .pf-post-body {
    padding: 22px;
  }

  .pf-post-card h2 {
    font-size: 21px;
  }

  .pf-back {
    margin-left: 0;
    width: 100%;
    margin-top: 6px;
  }
}

@media (prefers-reduced-motion: reduce) {

  .pf-post-card,
  .pf-post-img img,
  .pf-read i,
  .pf-cta-btn {
    transition: none;
  }
}
