/* A display formula wider than the screen scrolls inside its own box
   instead of widening the page on a narrow screen. */
.katex-display {
  overflow-x: auto;
  overflow-y: hidden;
}

/* KaTeX keeps a hidden copy of each formula in an absolutely positioned
   element; a scrolling box must be its containing block, or the copy of a
   formula in a wide table widens the page. */
main div[style*="overflow-x"] {
  position: relative;
}

/* On a narrow screen the theme hyphenates the words of the page; a hyphen
   added inside inline code would read as part of the code. */
main code {
  hyphens: none;
}
