Working on a school project and implemented an animated button style from w3 schools. However, I'm struggling to change the text color within the button. Being new to HTML, I would greatly appreciate any insights or suggestions on what might be going wrong here. Apologies if this is basic stuff that has already been addressed.
.button {
float: center;
display: flex;
display: inline-block;
border-radius: 10px;
background-color: #a6a6a6;
border: none;
color: #FFFFFF;
text-align: center;
font-size: 26px;
padding: 20px;
min-width: 15.96%;
transition: all 0.3s;
cursor: pointer;
margin: 5px;
text-decoration: none;
}
.button span {
cursor: pointer;
display: inline-block;
position: relative;
transition: 0.5s;
}
.button span:after {
content: '»';
position: absolute;
opacity: 0;
top: 0;
right: -20px;
transition: 0.5s;
}
.button:hover span {
padding-right: 25px;
}
.button:hover span:after {
opacity: 1;
right: 0;
}
<button class="button" style="vertical-align:middle">
<a href="first.html"><span>Home</span></button></a>
<button class="button" style="vertical-align:middle">
<a href="index.html"><span>About me</span></button></a>
<button class="button" style="vertical-align:middle">
<a href="contact.html"><span>Contact</span></button></a>
<button class="button" style="vertical-align:middle">
<a href="projects.html"><span>Projects</span></button></a>
<button class="button" style="vertical-align:middle">
<a href="resume.html"><span>Resume</span></button></a>
<button class="button" style="vertical-align:middle">
<a href="other.html"><span>Other</span></button></a>