/* insights.css: /insights/ and the articles (templates/blog.html,
   blog-post.html, macros/pagination.html). Tokens only; no hex codes.
   Focus rings come from site.css. Marked floor: dates, bylines and roles are
   plain text in Public Sans (no mono, no caps, no middle dots); panels are
   set by ground (concrete on white), hairlines only as list dividers. */

/* The Insights list ------------------------------------------------------- */
.band.blog-list { padding-top: var(--space-7); }
.blog-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-8); align-items: start; }
.post-list { border-bottom: 1px solid var(--color-border); }
/* The hero already ends on a hairline, so the first row has no rule of its own. */
.post-row:first-child { border-top: 0; padding-top: 0; }
.post-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--space-3);
  padding: var(--space-6) 0;
  border-top: 1px solid var(--color-border);
}
.post-row__meta { display: flex; flex-wrap: wrap; gap: 0 var(--space-5); margin: 0; font-size: var(--fs-small); line-height: 1.5; color: var(--color-text-muted); }
.post-row__title { font-size: var(--fs-h3); line-height: 1.15; margin: 0 0 var(--space-3); max-width: 40ch; text-wrap: balance; }
.post-row__title a { display: inline-block; padding-block: 12px; margin-block: -12px; color: var(--color-text-heading); text-decoration: none; }
.post-row__title a:hover,
.post-row__title a:focus-visible { color: var(--color-link); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.post-row__text { margin: 0; max-width: 62ch; color: var(--color-text); }
@media (min-width: 768px) {
  .post-row { grid-template-columns: 10.5rem minmax(0, 1fr); gap: var(--space-6); padding: var(--space-7) 0; }
  .post-row:first-child { padding-top: var(--space-2); }
  .post-row__meta { flex-direction: column; gap: 2px; padding-top: .3em; }
}
/* Phones: the title reads larger than its 18 px summary. */
@media (max-width: 767.98px) { .post-row__title { font-size: 1.375rem; } }

/* Side panel: who writes these, and the feed */
.blog-aside__panel { padding: var(--space-6); }
.blog-aside__panel .eyebrow { margin-bottom: var(--space-4); }
.blog-aside__who { display: flex; align-items: center; gap: var(--space-4); margin-bottom: var(--space-4); }
.blog-aside__photo { flex: none; width: 64px; height: 64px; border-radius: 50%; object-fit: cover; background: var(--color-surface-muted); }
.blog-aside__name { font-size: var(--fs-h4); line-height: 1.2; margin: 0 0 var(--space-1); }
.blog-aside__role { text-wrap: balance; margin: 0; font-size: var(--fs-small); line-height: 1.4; color: var(--color-text-muted); }
.blog-aside__text { margin: 0 0 var(--space-4); color: var(--color-text); }
.blog-aside__link { margin: 0; }
.blog-aside__feed { margin: var(--space-5) 0 0; color: var(--color-text-muted); }
@media (min-width: 992px) {
  .blog-layout { grid-template-columns: minmax(0, 1fr) 19rem; gap: var(--space-9); }
  .blog-aside { position: sticky; top: calc(var(--nav-h) + var(--space-6)); padding-top: var(--space-2); }
}

/* Pager -------------------------------------------------------------------- */
.blog-pager {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: var(--space-4);
  margin-top: var(--space-7);
}
.blog-pager__side--next { text-align: right; }
.blog-pager__pages { display: flex; gap: var(--space-2); list-style: none; margin: 0; padding: 0; }
.blog-pager__page {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 var(--space-3);
  border-radius: var(--radius);
  background: var(--color-panel);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--color-link);
  text-decoration: none;
}
a.blog-pager__page:hover { color: var(--color-link-hover); text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.blog-pager__page[aria-current="page"] { background: var(--color-brand); color: var(--color-surface); }
@media (max-width: 575.98px) {
  .blog-pager { grid-template-columns: 1fr 1fr; }
  .blog-pager__pages { grid-column: 1 / -1; grid-row: 1; justify-content: center; }
}

/* The article ------------------------------------------------------------- */
.band.post-body { padding-top: var(--space-7); }
.post { max-width: 760px; min-width: 0; }
@media (min-width: 1200px) {
  .post-layout--toc { display: grid; grid-template-columns: minmax(0, 760px) minmax(0, 1fr); column-gap: var(--space-9); align-items: start; }
}

/* Byline: plain text, the name linked to /about/, the role under it. */
.post-byline {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-7);
}
.post-byline__photo { flex: none; width: 48px; height: 48px; border-radius: 50%; object-fit: cover; background: var(--color-surface-muted); }
.post-byline__text { display: flex; flex-direction: column; gap: 2px; margin: 0; line-height: 1.35; }
.post-byline__by { font-weight: 600; color: var(--color-text-heading); }
.post-byline__by a { display: inline-block; padding-block: 12px; margin-block: -12px; color: var(--color-link); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.post-byline__by a:hover { color: var(--color-link-hover); text-decoration-thickness: 2px; }
.post-byline__role { text-wrap: balance; font-size: var(--fs-small); color: var(--color-text-muted); }

.post-cover { margin: 0 0 var(--space-7); }
.post-cover img { width: 100%; border-radius: var(--radius-photo); }

/* "In this article": a closed list above the body below 1200 px, a sticky
   rail beside it from 1200 px. Only one of the two is ever displayed. */
.post-toc__list { list-style: none; margin: 0; padding: 0; }
.post-toc__list li { margin: 0; }
.post-toc__list a {
  display: inline-flex;
  align-items: center;
  min-height: var(--target-min);
  padding: 6px 0;
  color: var(--color-text-muted);
  font-size: var(--fs-small);
  line-height: 1.4;
  text-decoration: none;
}
.post-toc__list a:hover,
.post-toc__list a:focus-visible { color: var(--color-link); text-decoration: underline; text-underline-offset: 3px; }
.post-toc--inline {
  margin: 0 0 var(--space-7);
  border-radius: var(--radius);
  background: var(--color-panel);
}
.post-toc--inline summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  min-height: 48px;
  padding: var(--space-2) var(--space-4);
  font-weight: 600;
  color: var(--color-text-heading);
  cursor: pointer;
  list-style: none;
}
.post-toc--inline summary::-webkit-details-marker { display: none; }
.post-toc--inline summary::after {
  content: "";
  flex: none;
  width: 9px;
  height: 9px;
  margin-left: auto;
  border-right: 2px solid var(--color-link);
  border-bottom: 2px solid var(--color-link);
  transform: rotate(45deg) translateY(-3px);
}
.post-toc--inline[open] summary::after { transform: rotate(-135deg) translateY(-1px); }
.post-toc__count { font-size: var(--fs-small); font-weight: 400; color: var(--color-text-muted); }
.post-toc--inline nav { padding: 0 var(--space-4) var(--space-3); }
.post-toc--inline .post-toc__list a { display: flex; color: var(--color-text); }
.post-toc--inline .post-toc__list { padding-top: var(--space-2); }
.post-rail { display: none; }
@media (min-width: 1200px) {
  .post-toc--inline { display: none; }
  .post-rail { display: block; position: sticky; top: calc(var(--nav-h) + var(--space-6)); justify-self: end; width: 100%; max-width: 17.5rem; }
  .post-toc--rail { max-height: calc(100vh - var(--nav-h) - var(--space-8)); overflow-y: auto; padding-left: var(--space-5); border-left: 1px solid var(--color-border); }
  /* Stop above the cookie bar (2.4.11) */
  html.has-consent .post-toc--rail { max-height: calc(100vh - var(--nav-h) - var(--space-8) - var(--consent-h, 0px)); }
  .post-toc__heading { margin: 0 0 var(--space-3); color: var(--color-text-heading); }
  .post-toc__top { margin: var(--space-4) 0 0; font-size: var(--fs-small); }
  .post-toc__top a { display: inline-flex; align-items: center; min-height: var(--target-min); color: var(--color-text-muted); }
}

/* The body */
.post__prose h2 { font-size: clamp(1.5rem, 1vw + 1.1rem, 1.875rem); line-height: 1.15; max-width: none; margin-top: 1.8em; margin-bottom: .6em; }
.post__prose h3 { font-size: 1.375rem; line-height: 1.25; margin-top: 1.6em; margin-bottom: .4em; }
.post__prose h2 + h3 { margin-top: 1em; }
@media (max-width: 767.98px) { .post__prose h3 { font-size: 1.25rem; } }
.post__prose ol > li > strong:first-child,
.post__prose ul > li > strong:first-child { color: var(--color-text-heading); }
.post__prose table { font-size: var(--fs-small); }
.post__prose th, .post__prose td { padding-right: var(--space-4); }
.post__prose td:first-child { font-weight: 600; color: var(--color-text-heading); }
.post__prose .slot--inline { margin: var(--space-6) 0; }
/* "My answer:" paragraphs (questions-to-ask article): a concrete panel on
   the white band, no border, the words "My answer:" as a sentence-case
   teal label on their own line. */
.post__prose .post-answer {
  margin: var(--space-5) 0;
  padding: var(--space-4) var(--space-5);
  background: var(--color-panel);
  border-radius: var(--radius);
  color: var(--color-text-heading);
}
.post__prose .post-answer > strong:first-child { display: block; margin-bottom: var(--space-1); font-size: var(--fs-label); font-weight: 600; line-height: 1.4; color: var(--color-label); }

/* The related offer, at the end of the article */
.post-offer { max-width: none; margin-top: var(--space-8); }
.post-offer .eyebrow { margin-bottom: var(--space-3); }
.post-offer p:not(.eyebrow) { max-width: 60ch; }
.post-offer__link { margin: var(--space-4) 0 0; }
@media (max-width: 575.98px) {
  .post-offer { padding: var(--space-5) var(--space-5) var(--space-5) var(--space-6); }
}

/* Date and reading time (post_card, post_item): meta, not a label. */
.post-meta { margin: 0 0 var(--space-3); font-size: var(--fs-small); font-weight: 400; line-height: 1.5; color: var(--color-text-muted); }
.post-more .card__text { color: var(--color-text); }
