* { font-family: monospace; } #map { height: 100vh; width: 100%; vertical-align: middle; margin-left: auto; margin-right: auto; padding: 0; } #sidebar { transition-duration: 500ms; position: absolute; width:20%; height:50%; top: 25%; right: -20%; z-index: 4000; background-color: whitesmoke; margin-left: 10px; } #sidebarText { position:relative; top: 0px; left:-50px; width: 150%; height: 8%; text-align: left; background-color: grey; } #sidebar:hover { transition-duration: 500ms; right: 0%; } body { height: 100%; width: 100%; padding:0; margin:0; }