I've got a menu that looks something like this
<nav role="navigation" class="small--hide">
<ul class="site-nav">
<li class="has-desktop-dropdown collection-dropdown">Link 1</li>
<li>Link 2</li>
<li class="has-desktop-dropdown journal-dropdown">Link 3</li>
</ul>
</nav>
Now I want a div to show when one of the list items is hovered
<div class="desktop-dropdown collection-dropdown-menu small--hide">
<p>Some content</p>
</div>
<div class="desktop-dropdown journal-dropdown-menu small--hide">
<p>Some content</p>
</div>
The Css I've been trying to use is this:
.collection-dropdown:hover ~ .collection-dropdown-menu {
display:block;
}
.journal-dropdown:hover ~ .journal-dropdown-menu {
display:block;
}
But it's not showing the div on hover. Any ideas what I'm doing wrong?