.selected-references {
  container: references / inline-size;
  margin-block: clamp(1.5rem, 3vw, 2.25rem) 0;
  scroll-margin-top: calc(var(--nav-height) + 1rem);
}

.support-content > .selected-references {
  margin-block: 1.5rem;
}

.selected-references-inner {
  display: grid;
  align-items: center;
  padding-block: 0.375rem;
  border-block: 1px solid var(--line);
}

#selected-references .selected-references-source {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-content: center;
  row-gap: 0.18rem;
  padding-block: 0.5rem;
  min-block-size: 44px;
  color: var(--navy);
  text-decoration: none;
}

.selected-references-name {
  text-align: center;
  color: var(--navy);
  font: 700 1.125rem/1.3 var(--serif);
  text-decoration: underline #a0834e 1px;
  text-underline-offset: 0.19em;
}

.selected-references-label {
  text-wrap: balance;
  color: var(--muted);
  font: 500 0.8125rem/1.4 var(--sans);
}

#selected-references .selected-references-more {
  display: inline-flex;
  align-items: center;
  justify-self: end;
  gap: 0.38em;
  min-block-size: 44px;
  color: var(--burgundy);
  font: 600 0.875rem/1.3 var(--sans);
  text-decoration: none;
}

#selected-references .selected-references-source:is(:hover, :focus-visible) .selected-references-name,
#selected-references .selected-references-more:is(:hover, :focus-visible) {
  color: var(--burgundy);
  text-decoration: underline;
  text-underline-offset: 0.19em;
}

#selected-references a:focus-visible {
  outline: 2px solid var(--burgundy);
  outline-offset: 2px;
}

@container references (min-width: 43rem) {
  .selected-references-inner {
    grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
    column-gap: clamp(0.875rem, 2cqi, 2rem);
    padding-block: 0.75rem;
  }

  #selected-references .selected-references-source {
    align-self: stretch;
    align-content: start;
    padding-block: 0;
  }

  .selected-references-name {
    font-size: clamp(1.125rem, 2.5cqi, 1.1875rem);
  }

  .selected-references-label {
    justify-self: center;
    max-inline-size: 32ch;
  }
}
