title: Close container with pure css using :target selector
body: <p>I have the following html:</p>
  
  <p>I want to apply that <code>display: none;</code> when the <code>:target</code> is encountered.</p>
  
  <p>If I don't use <code>:hover</code> that works just fine how you can check in the second example of the added fiddle, but if I add hover that is not working and I don't understand why :|</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>#test1:target {
    display: none;
  }
  #container:hover #test1 {
    display: block
  }
  #test1 {
    display: none;
    height: 50px;
    border: 1px dashed orange;
    background: green;
    padding: 10px;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;div id="container"&gt;
    HOVER ME
    &lt;div id="test1"&gt;
      &lt;a href="#test1"&gt;CLOSE ME&lt;/a&gt;
      &lt;p&gt;
        CLOSE THIS CONTENT
      &lt;/p&gt;
    &lt;/div&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p><strong><a href="http://jsfiddle.net/adzFe/2838/" rel="nofollow noreferrer">Here is the fiddle:</a></strong></p>