Is there a way to link the hover effect from one class to another in CSS?
I'm trying to achieve this without disrupting the individual hover effects of each class:
HTML
<a href="#" class="button1">Button 1</a>
<a href="#" class="button2">Button 2</a>
CSS
.button1 {
background: black;
padding: 5px 10px;
text-decoration: none;
color: white;
&:hover {
background: red;
}
}
.button2 {
background: blue;
padding: 5px 10px;
text-decoration: none;
color: white;
&:hover {
// How can I link the hover effect of button1 here?
}
}