I have a setup for displaying information as the user hovers over a specific element. When the specific element is hovered over, the information will appear in an adjacent div depending on which div the user hovers over. Here's the HTML...
#emp-node:hover+#emp-details {
opacity: 1;
}
.node-details {
opacity: 0;
}
<div class="half interactions">
<div id="nodes">
<div id="emp-node" class="node">EMPATHY</div>
<div id="def-node" class="node">DEFINE</div>
<div id="id-node" class="node">IDEATE</div>
<div id="por-node" class="node">PROTOTYPE</div>
<div id="test-node" class="node">TESTING</div>
</div>
<div id="node-text">
<div id="emp-details" class="node-details">1</div>
<div id="def-details" class="node-details">2</div>
<div id="id-details" class="node-details">3</div>
<div id="por-details" class="node-details">4</div>
<div id="test-details" class="node-details">5</div>
</div>
</div>
The node-details are set to an opacity of 0. When I hover over emp-node I would like emp-details to show, and the same pattern for the other divs. Here's the CSS...
#emp-node:hover + #emp-details { opacity: 1; }
I believe my issue is with the selector. I know that I need to use one but I've tried them all to no avail. Can some help me figure out how to get this to work properly? Do I need to restructure my HTML or is there a solution?
Thanks is advance.