/*
 * The changelog page (scripts/templates/changelog-page.mjs, #451). Chrome, tokens and primitives
 * are in core.css; the page shell is in article.css.
 */

@layer sections {
  .log-head {
    max-width: 46rem;
    margin-bottom: var(--space-10);
  }

  .log-title {
    margin: var(--space-2) 0 var(--space-4);
    font-size: var(--font-size-title);
    line-height: var(--line-height-tight);
    letter-spacing: var(--letter-spacing-tight);
  }

  .log-lede {
    margin: 0;
    color: var(--muted);
    line-height: var(--line-height-relaxed);
  }

  .log-month {
    max-width: 46rem;
    margin-bottom: var(--space-10);
  }

  .log-month__title {
    margin: 0 0 var(--space-4);
    font-size: var(--font-size-xl);
  }

  .log-list {
    display: grid;
    gap: var(--space-3);
    margin: 0;
    padding: 0;
    list-style: none;
  }

  /* Section, text, date: the date drops under the text on a narrow screen */
  .log-entry {
    display: grid;
    grid-template-columns: 4.5rem 1fr auto;
    gap: var(--space-1) var(--space-3);
    align-items: baseline;
    line-height: var(--line-height-normal);
  }

  .log-entry__section {
    color: var(--muted);
    font-family: var(--font-mono);
    font-size: var(--font-size-xs);
    text-transform: uppercase;
  }

  .log-entry__section[data-section='added'] {
    color: var(--accent);
  }

  .log-entry__date {
    color: var(--muted);
    font-size: var(--font-size-sm);
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
  }

  @media (max-width: 40rem) {
    .log-entry {
      grid-template-columns: 4.5rem 1fr;
    }

    .log-entry__date {
      grid-column: 2;
    }
  }
}
