title: CSS solution to make drop-down element visible while focused
body: <p>I'm trying to figure out if there is any <strong>pure CSS</strong> solution to keep a drop-down element open while the input field of that element is focused? Here is an example:</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true">
  <div class="snippet-code">
  <pre class="snippet-code-css lang-css prettyprint-override"><code>div {
    width: 300px;
    line-height: 50px;
    text-align: center;
    background: #e8e8e8;
    border: 1px solid #666;
  }
  
  div:hover form {
    display: block;
  }
  
  form {
    display: none;
    padding: 0 15px;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;div&gt;Hover Me
  &lt;form class="search"&gt;
  &lt;input type="search" placeholder="What are you looking for?" autofocus&gt;
  &lt;input type="button" value="Search!"&gt;
  &lt;/form&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>The idea is to keep the form visible when the search field is focused. Because when a user starts typing the search inquiry and the mouse move out of the hover zone, the form hides, and that's very annoying.</p>
  
  <p><strong>Side-question</strong>: Is it possible to focus via CSS search input element each time a <code>&lt;div&gt;</code> is hovered?</p>