/* The articles and their index (apps/site/articles/articles.ts, SEO-3), on top of landing.css and
   unidade.css (breadcrumb, H1, sections, example cards, play buttons, call to action): the running
   text, its lists, the byline, the index's cards. Tokens only (apps/site/src/tokens.css). One
   breakpoint, layout.wide-min (900px — a media query cannot read a custom property). */

.article-head {
  margin-top: var(--space-4);
}

.article-meta {
  margin-top: var(--space-2);
  color: var(--color-text-muted);
  font-size: var(--type-callout-size);
  line-height: var(--type-callout-line);
  font-weight: var(--type-callout-weight);
}

.article-page .lead {
  margin-top: var(--space-6);
}

.article-section > p,
.article-section > .article-list,
.article-section > .entries {
  max-width: var(--layout-column-max);
  margin-top: var(--space-4);
}

.article-list {
  margin-top: var(--space-4);
  padding-left: var(--space-5);
  list-style: disc;
}

ol.article-list {
  list-style: decimal;
}

.article-list li + li {
  margin-top: var(--space-2);
}

.article-page strong {
  font-weight: var(--type-body-strong-weight);
}

.article-page .faq-item h3 {
  font-size: var(--type-body-size);
  line-height: var(--type-body-line);
}

/* Links inside the text and the lists: the body's colour, underlined, a touch target's height. */
.article-list a,
.article-more a {
  display: inline-flex;
  align-items: center;
  min-height: var(--size-touch-min);
}

.article-units {
  display: grid;
  gap: var(--layout-card-gap);
  margin-top: var(--space-5);
}

/* The index */

.article-cards {
  display: grid;
  gap: var(--layout-card-gap);
  margin-top: var(--space-8);
}

/* The question hub's themes: a heading over each group of cards (SEO-6b) */
.index-group .article-cards {
  margin-top: var(--space-5);
}

.article-card {
  padding: var(--layout-card-padding);
}

.article-card :is(h2, h3) {
  font-family: var(--type-heading-font);
  font-weight: var(--type-heading-weight);
  font-size: var(--type-heading-size);
  line-height: var(--type-heading-line);
  letter-spacing: var(--type-heading-tracking);
}

.article-card :is(h2, h3) a {
  color: var(--color-text);
}

.article-card p {
  margin-top: var(--space-2);
  max-width: var(--layout-column-max);
}

/* The word pages (SEO-7, apps/site/words/words.ts): the answer in a card with its clip buttons,
   the facts under it, the A–Z links of the hub, the lists of linked words. */

.word-answer {
  margin-top: var(--space-6);
}

.word-page .word-answer .lead {
  margin-top: 0;
}

.word-page .unit-link {
  margin-top: var(--space-4);
}

.word-letters {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-6);
}

.word-letters a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: var(--size-touch-min);
  min-height: var(--size-touch-min);
  border-radius: var(--radius-lg);
  background: var(--color-surface);
  font-weight: var(--type-body-strong-weight);
  text-decoration: none;
}

.word-index {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, var(--size-web-unit-card-min)), 1fr));
  gap: var(--space-2) var(--layout-card-gap);
  margin-top: var(--space-4);
}

.word-index a {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 var(--space-2);
  min-height: var(--size-touch-min);
}

.word-index a [lang] {
  color: var(--color-text-muted);
}

/* layout.wide-min */
@media (min-width: 900px) {
  .article-units {
    grid-template-columns: 1fr 1fr;
  }

  .article-cards {
    grid-template-columns: 1fr 1fr;
  }
}
