Можно рассмотреть дополнительный слой над фоном, где вы применяете белую или черную окраску, чтобы сделать фон светлее или темнее:
a {
display:inline-block;
padding:10px;
color:#fff;
position:relative;
z-index:0;
}
.red {
background:red;
}
.blue {
background:blue;
}
.green {
background:green;
}
.light:before,
.dark:before {
content:"";
position:absolute;
z-index:-1;
top:0;
left:0;
right:0;
bottom:0;
background:rgba(255,255,255,0.3);
opacity:0;
}
.dark:before {
background:rgba(0,0,0,0.3);
}
a:hover::before {
opacity:1;
}
<a class="red light" href="">some text here</a>
<a class="red dark" href="">some text here</a>
<a class="blue light" href="">some text here</a>
<a class="blue dark" href="">some text here</a>
<a class="green light" href="">some text here</a>
<a class="green dark" href="">some text here</a>
Аналогичная идея без псевдоэлемента
a {
display:inline-block;
padding:10px;
color:#fff;
}
.red {
background:red;
}
.blue {
background-color:blue;
}
.green {
background:green;
}
.light {
background-image:linear-gradient(rgba(255,255,255,0.3),rgba(255,255,255,0.3));
}
.dark {
background-image:linear-gradient(rgba(0,0,0,0.3),rgba(0,0,0,0.3));
}
.light,
.dark {
background-size:0 0;
}
a:hover {
background-size:100% 100%;
}
<a class="red light" href="">some text here</a>
<a class="red dark" href="">some text here</a>
<a class="blue light" href="">some text here</a>
<a class="blue dark" href="">some text here</a>
<a class="green light" href="">some text here</a>
<a class="green dark" href="">some text here</a>