.menu-button { background-color: purple; display: inline-block; width: 2.5em; height: 2.5em; line-height: 2.5em; text-align: center; font-size: 1rem; position: relative; display: inline-block; } div.menu-button > span { color:white; } .menu { max-height: 100vh; //transition: max-height 0.2s; overflow: hidden; box-shadow: 0 0 20px rgba(0,0,0,.3); position: absolute; top: 3rem; right:0; } .card { padding:0.5rem; min-width: 10rem; overflow: hidden; } .username { white-space: nowrap; font-weight: 500; font-size: 1.2rem; line-height: 1.2rem; } .card-body { text-align: left; } .hidden { max-height: 0; }