Can text be vertically aligned above the border-top in HTML when using height:0px, similar to how it can be done below the border-bottom?
HTML:
<ul id="experiment" style="background: #FFDD00;">
<li id="test1"><span class="v-align-bot">Chocolate</span></li>
<li id="test2"><span class="v-align-top">Potato</span></li>
</ul>
CSS:
#test1 {
height: 0px;
border-bottom: 50px solid #648291; /*grey*/
}
#test2 {
height: 0px;
border-top: 50px solid #FA8723; /*orange*/
}
.v-align-bot {
vertical-align: -50px;
}
.v-align-top {
vertical-align: 50px;
}
The Chocolate aligns below the border-bottom easily. The Potato aligns above the li but the border-top follows it as well.
TL;DR: How can I properly align BUTTONS in this fiddle below?