Check out example codes for "css hover affect other item". It will help you in understanding the concepts better.

Code Example 1

#container:hover ~ #cube { background-color: yellow; }

Learn ReactJs, React Native from akashmittal.com