I'd like to manipulate an elements' width by hovering and at the same time edit its neighbors elements width.
I thought I could do it like so:
.sw_2-technik:hover{
width:60%;
}
.sw_2-technik:hover .sw_2.emotionen{
width:40%;
}
Whereas the hovering of .sw_technik makes its width to 60% and .sw_2-emotionen to 40%. But that doesn't seem to work.
Do I really need to use JS for something like that?
Additional info:
the 2 containers are next to each others, like so
<div class="sw_2-technik"></div><div class="sw_2-emotionen"></div>
And I therefore also tried this code:
.sw_2-technik:hover + .emotionen{
width:40%;
}
but that doesn't work neither.