I am trying to decrease the vertical distance between my google logo and the google search bar but am having trouble

I want the spacing between my google image log and the search bar to be basically zero, but I am having a difficult time reducing the spacing between those two divs.https://codepen.io/noblegas/pen/VwYWXzp

In your HTML you have given the image a scale class. In you CSS you have assigned: margin-bottom: 100px in your .scale. That is why there is ‘extra space’ between the image and the search bar.

1 Like

If you want to remove the white space (i.e. making the image smaller) as opposed to the removing some of the red background (i.e. the space between the two elements) you will have to crop the image in Photoshop (or similar).

1 Like

I now have another problem. I am trying to get my navbar to be fixed with the Justify content:space between property. I can get it so that the space-between property works and I can get it so that the fixed property works, but I cannot get it to where both the navbar is at position fixed and space between. Because when I attempt to fixed my navbar with the position:fixed property, my links are all aligned at flex-start. https://codepen.io/noblegas/pen/VwYWXzp

If you want to use position: fixed you can also set a .navbar width of 100vw (or 100%).
Otherwise you can use position: sticky which is quite handy (and you don’t have to specify the width).

Does that fix what you meant by justify the contents? I assume so, otherwise I am wondering why you have your links in two groups of divs (nav-links-one and nav-links-two). Also note that you aren’t styling either of these classes (or nav-link-one , nav-link-two ), if you are not going to use the class, it is better to delete it to increase your code readability.