/* Phones: show the calculator before the introduction. The HTML order (and so
   the text search engines and screen readers get) is unchanged; only the visual
   order changes, so the form is on the first screen instead of below it. */
@media (max-width: 500px) {
  .middle, .calc-first, .fg-wrap { display: flex; flex-direction: column; }
  .middle > h1 + p, .middle > h1 + p + p,
  .calc-first > h1 + br + p, .calc-first > h1 + br + p + p,
  .fg-wrap > .fg-intro, .fg-wrap > noscript { order: 2; }
  .middle > #vivenPromoMount ~ *, .calc-first > #vivenPromoMount ~ *,
  .fg-wrap > .fg-explanation, .fg-wrap > .fg-explanation ~ * { order: 3; }
  .middle > h1 + br, .calc-first > h1 + br { display: none; }
  /* Tighter GPA form spacing so the course table starts near the first screen. */
  .middle > h1 { margin-bottom: 16px; }
  .middle > h4 { margin-top: 8px; }
  .middle > .gradingSys { margin-bottom: 16px; }
  .middle > .bg-secondary.p-4 { padding: 1rem !important; }
}
