title: Prevent line break in header
body: <p>I have an h1 with line breaks. On mobile devices, there should be no line breaks.</p>
  
  <p>This code works on Chrome and iPhone but not on Firefox. So I am afraid it might not work on all devices/browsers.</p>
  
  <p>(The code snippet seems to ignore the media query).</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-css lang-css prettyprint-override"><code>h1 {
    text-align: right;
  }
  
  @media screen and (max-width: 839px) {
   h1 {
    br {
     content: "";
     &amp;:after {
      content: " ";
     }
    }
   }
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;h1&gt;This is a&lt;br&gt;header&lt;br&gt;with line breaks&lt;/h1&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>Note the spaces which get inserted by CSS when the header is on 1 line. And also the header should be able to align to right.
  How could I make this cross-browser compatible?</p>