I can't move contents of my navbar

I can’t move the contents of the navbar to the left. The only way I can do it is to set overflow-x to auto and then adjust but when the page reloads it gets back to how it was. Even playing with margin and padding doesn’t do anything. You can check it out using the link to see for yourself.

Your code so far
nav{
position:fixed;
top:0;
left:0;
border-right: 1px solid black;
width:240px;
height:100%;
overflow-y:auto;
overflow-x:auto;
white-space:nowrap;}

#navbar ul{
list-style:none;
text-align:left;
background-color:#0C9375;
margin: 50px 0px 0px 0px;
width:250px;}
nav ul li a{
text-decoration: none;
font-weight:bold;
color:#3F3838;
line-height: 40px;
width:100%;
text-align:left;
padding:10px 200px 10px 20px;
margin: 0px 0px 0px 0px;}

Your browser information:

Challenge: Build a Technical Documentation Page

Link to the challenge:
https://codepen.io/Motasim0109/pen/NWgRvNM?editors=0100

Put a padding-left:0px; on your #navbar ul will help. You could also remove the left padding on your nav ul li a if you want even less

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.