Web page with animated nav underlines
HTML
<nav>
<a href>Home</a>
<a href>About</a>
<a href>Descriptions</a>
<a href>Tools & Settings</a>
<a href>Contact</a>
</nav>
<section>
<p>I’m Adam Schwartz, co-founder of <a href="https://eager.io" target="_blank">Eager</a> and freelance <a href="/music/" pushstate-link-setup="">film composer</a>. Prior to Eager I was a principal software engineer at <a href="http://hubspot.com" target="_blank">HubSpot</a>. I’m a huge proponent of open-source software and maintain a number of <a href="/projects/" pushstate-link-setup="">projects</a>.</p><p>I’ve been writing <a href="/music/" pushstate-link-setup="">music</a> for over a decade and hope to one day score major motion pictures. Recently I composed the opening music for Al Jazeera America’s news show <em><a href="https://web.archive.org/web/20160827025554/http://america.aljazeera.com/watch/shows/inside-story.html" target="_blank">Inside Story</a></em> which aired nightly at 6:30PM ET from 2013–2016.</p>
</section>
CSS
html, body {
min-height: 100%;
min-width: 100%;
margin: 0;
padding: 0;
}
html {
box-sizing: border-box;
font: normal normal 300 1.1875em / 1.5 Avenir, "Avenir Next", sans-serif;
}
* {
box-sizing: inherit;
}
@media (max-width: 600px) {
html {
font-size: 3vw;
}
}
nav {
margin-bottom: 3vw;
}
body {
padding: 10vw 3vw;
display: flex;
align-items: center;
justify-content: center;
flex-flow: column;
}
a {
text-decoration: none;
position: relative;
color: blue;
cursor: pointer;
}
a::after {
position: absolute;
content: "";
height: .1em;
top: 100%;
background: currentColor;
z-index: -1;
left: 0;
right: 0;
transform: scaleX(0);
transition: transform .5s cubic-bezier(.95, .05, .795, .035);
}
a:hover::after {
transition-timing-function: cubic-bezier(.19, 1, .22, 1);
transform: scaleX(1);
}