title: .class a:hover vs .class:hover a
body: <p>Couldn't find an answer to something I've been wondering about.</p>
  
  <p>Is there a difference between <code>.class2 a:hover {}</code> and <code>.class2:hover a {}</code>? Or a preference for one over the other?</p>
  
  <p>I've been using <code>.class2 a:hover {}</code> to alter anchors on anchor hover (ie: anchor text color), but when I wanted to alter the div that held the anchor as well (ie: anchor color and div background-color both change on hover), I had to use <code>.class2:hover a {}</code> for it to work. In doing so, I got confused as to the difference because between the two as they are written so similarly.</p>
  
  <p>Thanks!</p>
  
  <p><strong>EDIT</strong><br>
  Edited the question to be more clear. Thanks for untwisting my brain :)</p>