You can do it as following:
In your css:
In the following, add two more properties
.main-nav li {
padding:5px;
text-align:center;
}
In the following, change property:
.active{
height:20px;
}
And as @Tadit Dash said, it is recommended to use bootstrap.