title: Using CSS first-child to select first H2
body: <pre><code>&lt;!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"&gt; 
  &lt;html&gt;
  &lt;head&gt;
  &lt;style type="text/css"&gt;
  h2:first-child
  {
  background:yellow;
  } 
  &lt;/style&gt;
  &lt;/head&gt;
  &lt;body&gt;
  &lt;div class="car"&gt;
      &lt;div&gt;Something&lt;/div&gt;
      &lt;h2&gt;I want to style this&lt;/h2&gt;
      &lt;p&gt;bla bla&lt;/p&gt;
      &lt;h2&gt;I don't want to style this&lt;/h2&gt;
      &lt;p&gt;bla bla bla&lt;/p&gt;
  &lt;/div&gt;
  
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>I'm having trouble styling the first h2, "I want to style this" since I have a div right before that first h2 I can't select it, but if it weren't there it'll work. Without editing the html (and without using js of course) is there a way to select that first h2? Or is wrapping the h2's with another element like below the only way?</p>
  
  <pre><code>&lt;div class="car"&gt;
      &lt;div&gt;Something&lt;/div&gt;
  &lt;div&gt;
          &lt;h2&gt;I want to style this&lt;/h2&gt;
          &lt;p&gt;bla bla&lt;/p&gt;
          &lt;h2&gt;I don't want to style this&lt;/h2&gt;
          &lt;p&gt;bla bla bla&lt;/p&gt;
  &lt;/div&gt;
  &lt;/div&gt;
  </code></pre>