/* ===========================================================================
   Content primitives
   =========================================================================== */

.stack { display: flex; flex-direction: column; gap: 24px }
.row   { display: flex; align-items: center; gap: 12px }
.row--wrap { flex-wrap: wrap }
.spacer { margin-left: auto }

/* The design's card is a solid #D4D4D4 hairline at 24px with 26/28 padding.
   This had drifted to an 8%-black border, which on white is several shades
   lighter — cards read as floating tints rather than as bordered surfaces, and
   sat inconsistently beside .panel and .table, which were already correct. */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r-card);
  padding: 26px 28px;
}
.card--flush { padding: 0; overflow: hidden }
.card__head {
  display: flex; align-items: center; gap: 12px;
  padding: 24px; border-bottom: 1px solid var(--hair);
  /* The count beside the heading drops to its own line on a phone rather than
     forcing both into a narrow column each and wrapping them side by side. */
  flex-wrap: wrap; row-gap: 2px;
}
.card__head h2 { margin: 0; font-size: 16px; font-weight: var(--weight-strong); letter-spacing: -.02em }
/* The same, for the heads that use an h3 — every one of them does. Without it
   the UA's own 1.17em margin survives inside a flex row, where margins do not
   collapse, and every card head in the voice trainer stood 103px tall for 25px
   of text. It read as a heading floating above an empty band. */
.card__head h3 { margin: 0; font-size: 16px; font-weight: var(--weight-strong); letter-spacing: -.02em }

/* A head inside a padded card must not pad again. At 26/28 on the card plus
   20/24 on the head, the heading sat 24px to the right of the paragraph under
   it and the rule it draws stopped short of both card edges — the two cards in
   the voice trainer, side by side, disagreed about where their left edge was.
   Flush cards keep the padding: there is none on the card for them to sit in. */
.card:not(.card--flush) > .card__head { padding: 0 0 16px; margin: 0 0 18px }

.h2 { margin: 0; font-size: 22px; font-weight: var(--weight-strong); letter-spacing: -.03em }
.lede { font-size: 13.5px; color: var(--muted); line-height: 1.6; margin: 6px 0 0 }
.muted { color: var(--muted) }

.grid { display: grid; gap: 18px }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)) }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)) }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)) }
