/* Internal linking: "Continue the story" boxes on topic pages and chapters, and the History topics list in the footer.
   Loaded by wp-content/novamira-sandbox/amx-internal-links.php */

/* ---------- related reading box ---------- */
.amx-prose .amx-related,
.amx-related {
  margin: 44px 0 8px;
  padding: 22px 24px 10px;
  border-top: 3px solid var(--accent, #285a8c);
  background: rgba(70, 58, 36, 0.045);
}
.amx-prose .amx-related__title,
.amx-related__title {
  margin: 0 0 6px;
  font-family: var(--amx-f-head, "Fraunces", Georgia, serif);
  font-weight: 560;
  font-size: 20px;
  line-height: 1.2;
  color: var(--ink, #1c2126);
}
.amx-related__title::before,
.amx-related__title::after { content: none !important; display: none !important; }
.amx-prose .amx-related__list,
.amx-related__list { list-style: none; margin: 0; padding: 0; }
.amx-prose .amx-related__list li,
.amx-related__list li { margin: 0; padding: 0; list-style: none; border-top: 1px solid rgba(70, 58, 36, 0.14); }
.amx-related__list li:first-child { border-top: 0; }
.amx-related__list li::before,
.amx-related__list li::marker { content: none !important; }
.amx-prose .amx-related__link,
.amx-related__link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 2px 16px;
  padding: 12px 0;
  color: var(--ink, #1c2126);
  text-decoration: none;
  background: none;
}
.amx-related__kind {
  grid-column: 1;
  font-family: var(--ui, Arial, sans-serif);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent, #285a8c);
}
.amx-related__name {
  grid-column: 1;
  font-family: var(--amx-f-quote, "Fraunces", Georgia, serif);
  font-size: 17px;
  line-height: 1.3;
}
.amx-related__go {
  grid-column: 2;
  grid-row: 1 / span 2;
  color: var(--accent-ink, #1b3d63);
  font-size: 18px;
  transition: transform 180ms ease;
}
.amx-related__link:hover .amx-related__name,
.amx-related__link:focus-visible .amx-related__name { text-decoration: underline; text-underline-offset: 3px; }
.amx-related__link:hover .amx-related__go { transform: translateX(3px); }
.amx-related__link:focus-visible { outline: 2px solid var(--accent, #285a8c); outline-offset: 2px; }
@media (max-width: 600px) {
  .amx-prose .amx-related, .amx-related { margin-top: 36px; padding: 18px 16px 6px; }
  .amx-related__name { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) { .amx-related__go { transition: none; } }

/* ---------- footer: History topics beside Explore the site ---------- */
.amx-footer__heading--topics { margin-top: 0; }
@media (min-width: 861px) {
  .amx-footer__grid:has(.amx-footer__menu--topics) { grid-template-columns: minmax(0, 5fr) minmax(0, 5fr) minmax(0, 3fr); }
}
.amx-footer__nav:has(.amx-footer__menu--topics) {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  grid-template-rows: auto 1fr;
  grid-auto-flow: column;
  column-gap: clamp(20px, 3vw, 40px);
  align-content: start;
}
.amx-footer__menu--topics a { line-height: 1.3; }
