/* ─────────────────────────────────────────────────────────────────────────
   Page: Blog index (Figma 2225:964 desktop / 2282:4871 mobile)

   Mobile first: the 360 frame (px 20). From lg: the 1440 frame — px 150,
   one 109 gap between header, title, categories, grid and footer.
   Royal #183a73 (active pill, mobile pill border) is not an @theme token:
   scoped here.
   ───────────────────────────────────────────────────────────────────────── */

.section-blog-hero,
.section-blog-categories,
.section-blog-grid {
  --color-blog-royal: #183a73;

  padding-inline: 1.25rem; /* 20 */
}

/* ── Title ──────────────────────────────────────────────────────────────── */
.section-blog-hero {
  padding-top: 2.5rem; /* 40 below the header */
}

.section-blog-hero__title {
  margin: 0;
  font-size: 2.5rem; /* 40 */
  line-height: 2.8125rem; /* 45 */
  letter-spacing: -0.016em;
  text-align: center;
}

/* ── Categories ─────────────────────────────────────────────────────────── */
.section-blog-categories {
  padding-top: 1.5rem; /* 24 */
}

.section-blog-categories__label {
  display: none; /* not in the mobile frame */
  margin: 0;
  font-size: 1.375rem; /* 22 */
  line-height: 1.9375rem; /* 31 */
  letter-spacing: -0.016em;
}

/* One row that scrolls sideways, edge to edge */
.section-blog-categories__list {
  display: flex;
  gap: 0.625rem; /* 10 */
  margin: 0 -1.25rem;
  padding: 0 1.25rem;
  overflow-x: auto;
  list-style: none;
  scrollbar-width: none;
}

.section-blog-categories__list::-webkit-scrollbar {
  display: none;
}

.section-blog-categories__list li {
  flex: none;
}

.section-blog-categories__pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.625rem 1rem; /* 10 / 16 */
  border: 0.09375rem solid var(--color-blog-royal); /* 1.5 */
  border-radius: var(--radius-pill);
  background-color: transparent;
  color: var(--color-blog-royal);
  font-family: var(--font-primary);
  font-size: 0.75rem; /* 12 */
  font-weight: 600;
  line-height: 0.975rem; /* 15.6 */
  letter-spacing: -0.016em;
  white-space: nowrap;
  cursor: pointer;
  transition:
    background-color 0.2s ease,
    color 0.2s ease;
}

.section-blog-categories__pill[aria-pressed="true"] {
  background-color: var(--color-blog-royal);
  color: var(--color-white);
}

/* ── Grid ───────────────────────────────────────────────────────────────── */
.section-blog-grid {
  padding-top: 2.5rem; /* 40 */
  padding-bottom: 5.625rem; /* 90 above the footer */
}

.section-blog-grid__list {
  display: grid;
  gap: 2.875rem; /* 46 */
  margin: 0;
  padding: 0;
  list-style: none;
}

.section-blog-grid__item[hidden] {
  display: none;
}

.section-blog-grid__card {
  display: flex;
  flex-direction: column;
  gap: 1.375rem; /* 22 */
}

.section-blog-grid__photo {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 320 / 210;
  object-fit: cover;
  border-radius: 1.25rem; /* 20 */
}

.section-blog-grid__meta {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.625rem; /* 10 */
}

.section-blog-grid__tag {
  display: inline-flex;
  align-items: center;
  padding: 0.375rem 0.875rem; /* 6 / 14 */
  border-radius: var(--radius-pill);
  font-size: 0.75rem; /* 12 */
  line-height: 0.975rem; /* 15.6 */
  letter-spacing: -0.016em;
}

.section-blog-grid__text {
  display: flex;
  flex-direction: column;
  gap: 1rem; /* 16 */
}

.section-blog-grid__date {
  display: block;
  font-size: 1.125rem; /* 18 */
  line-height: 1.4375rem; /* 23 */
  letter-spacing: -0.016em;
}

.section-blog-grid__title {
  margin: 0;
  font-size: 1.375rem; /* 22 */
  line-height: 1.7875rem; /* 28.6 */
  letter-spacing: -0.016em;
}

.section-blog-grid__title a {
  color: inherit;
  text-decoration: none;
}

.section-blog-grid__title a:hover {
  color: var(--color-green);
}

.section-blog-grid__empty {
  margin: 0;
  font-size: 1.125rem;
  line-height: 1.4375rem;
}

/* ── Desktop: the 1440 frame ────────────────────────────────────────────── */
@media (width >= 64rem) {
  .section-blog-hero,
  .section-blog-categories,
  .section-blog-grid {
    padding-inline: 9.375rem; /* 150 */
  }

  .section-blog-hero {
    padding-top: 6.8125rem; /* 109 below the header */
  }

  .section-blog-hero__title {
    font-size: 4.375rem; /* 70 */
    line-height: 4.375rem; /* 70 */
    letter-spacing: -0.024em;
  }

  .section-blog-categories {
    padding-top: 6.8125rem; /* 109 */
  }

  .section-blog-categories__label {
    display: block;
  }

  /* Pills 43 below the label's top (31 line + 12); Figma widths */
  .section-blog-categories__list {
    flex-wrap: wrap;
    gap: 0.8125rem; /* ~13 */
    margin: 0.75rem 0 0;
    padding: 0;
    overflow: visible;
  }

  .section-blog-categories__pill {
    height: 4.375rem; /* 70 */
    padding: 0.625rem;
    border-color: var(--color-navy);
    color: var(--color-navy);
    font-size: 1.125rem; /* 18 */
    line-height: 1.4375rem; /* 23 */
  }

  .section-blog-categories__pill[aria-pressed="true"] {
    border-color: var(--color-blog-royal);
  }

  .section-blog-categories__pill--all {
    width: 7.5rem; /* 120 */
  }

  .section-blog-categories__pill--boards {
    width: 11.25rem; /* 180 */
  }

  .section-blog-categories__pill--managers {
    width: 18.125rem; /* 290 */
  }

  .section-blog-categories__pill--pros {
    width: 18.75rem; /* 300 */
  }

  .section-blog-categories__pill--accountants {
    width: 12.375rem; /* 198 */
  }

  .section-blog-grid {
    padding-top: 6.8125rem; /* 109 */
    padding-bottom: 6.8125rem; /* 109 above the footer */
  }

  .section-blog-grid__list {
    grid-template-columns: 1fr 1fr;
    gap: 3.375rem; /* 54 */
  }

  /* Card 519 tall: the photo takes what the text leaves (310 at 1440) */
  .section-blog-grid__card {
    height: 32.4375rem; /* 519 */
  }

  .section-blog-grid__photo {
    flex: 1 0 0;
    min-height: 0;
    aspect-ratio: auto;
  }

  .section-blog-grid__meta {
    gap: 1.375rem; /* 22 */
  }

  .section-blog-grid__tag {
    padding: 0.3125rem 2.375rem; /* 5 / 38 */
    font-size: 0.8125rem; /* 13 */
    line-height: 1.9375rem; /* 31 */
  }

  .section-blog-grid__text {
    gap: 1.375rem; /* 22 */
  }

  .section-blog-grid__date {
    min-height: 2.25rem; /* box 36 */
    font-size: 1.375rem; /* 22 */
    line-height: 1.9375rem; /* 31 */
  }

  .section-blog-grid__title {
    font-size: 1.875rem; /* 30 */
    line-height: 2.0625rem; /* 33 */
  }
}
