/* ==========================================================================
   GNC SG — Taxonomy term pages (category / goal landings)
   ==========================================================================
   No design exists for these; they are built to match the listing pages they
   sit alongside, so a visitor arriving from search lands somewhere that looks
   like the rest of the site.
   ========================================================================== */

.term-page__header {
  margin-bottom: var(--space-8);
}

.term-page__title {
  font-size: var(--font-size-3xl);
  margin-bottom: var(--space-3);
}

/* The intro is the page's reason to rank — give it a readable measure rather
   than letting it run the full grid width. */
.term-page__intro {
  max-width: var(--container-narrow);
  font-size: var(--font-size-base);
  line-height: var(--line-height-relaxed);
  color: var(--color-text-muted);
}

.term-page__intro p {
  margin-bottom: var(--space-4);
}

.term-page__intro p:last-child {
  margin-bottom: 0;
}

/* Core's taxonomy_term view uses the "unformatted" style, so its rows arrive as
   a flat run of divs rather than a grid. The template wraps them in .grid-3col;
   each row then has to stop being a block and become a grid cell, or the cards
   inside stretch the full width one under the other. */
.term-page__grid > .views-row {
  display: flex;
  flex-direction: column;
}

.term-page__grid > .views-row > * {
  flex: 1;
}

@media (max-width: 767px) {
  .term-page__header {
    margin-bottom: var(--space-6);
  }

  .term-page__title {
    font-size: var(--font-size-xl);
  }
}
