title: Element style not allowed as child of element body in this context (<style scoped> not validating)
body: <pre><code>&lt;!DOCTYPE html&gt;
  ...
  &lt;style scoped&gt;
  /* css */
  &lt;/style&gt;
  </code></pre>
  
  <p>The w3.org validator is giving me this error:</p>
  
  <pre><code>Line 883, Column 17: Element style not allowed as child of element body in this context.
  (Suppressing further errors from this subtree.)
          &lt;style scoped&gt;...
  Contexts in which element style may be used:
  If the scoped attribute is absent: where metadata content is expected.
  If the scoped attribute is absent: in a noscript element that is a child of a head element.
  If the scoped attribute is present: where flow content is expected, but before any other flow     content other than inter-element whitespace and style elements, and not as the child of an element whose content model is transparent.
  Content model for element body:
  Flow content.
  </code></pre>
  
  <p>It is my understanding that the 'scoped' property makes it ok for the style tag to be outside the head of the document.  So why is the validator unhappy with it?</p>
  
  <p>(I'm using Wordpress and this code is produced by a plugin, which is why I can't just put it in the head.)</p>
  
  <p>EDIT:
  This doesn't validate -</p>
  
  <pre><code>&lt;!DOCTYPE html&gt;
  &lt;head&gt;
  &lt;meta charset="UTF-8"&gt;
  &lt;title&gt;title&lt;/title&gt;
  &lt;/head&gt;
  &lt;body&gt;
  &lt;script type="text/javascript"&gt;&lt;/script&gt;
  &lt;style scoped&gt;&lt;/style&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>But it does if the script tag goes after the style tag.  What is the reason for that?</p>