title: block <a> inside inline <li> behaviour
body: <p>The following HTML / CSS result strikes me as odd and unexpected and I'm really looking for the logic behind the way this is parsed.</p>
  
  <p>Suppose:</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false">
  <div class="snippet-code">
  <pre class="snippet-code-css lang-css prettyprint-override"><code>#nav {
    list-style-type-none
  }
  #nav li {
    display: inline;
  }
  /* make the LI's stack horizontally */
  
  #nav li a {
    display: block;
    padding: 5px;
  }
  /* display as block to add padding */</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;ul id="nav"&gt;
    &lt;li&gt;&lt;a href="#"&gt;Home&lt;/a&gt;
    &lt;/li&gt;
    &lt;li&gt;&lt;a href="#"&gt;About us&lt;/a&gt;
    &lt;/li&gt;
  &lt;/ul&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>This results in the <code>&lt;li&gt;</code>'s stacking vertically (like block elements) because of the <code>&lt;a&gt;</code>'s which are displayed as block elements. But I want the <code>&lt;li&gt;</code>'s to be stacked horizontally as I've defined them as inline elements.</p>
  
  <p>The <code>&lt;li&gt;</code>'s are displayed as inline, why does the <strong>inner</strong> element <code>&lt;a&gt;</code> affect it?</p>