Why does my background stretch to the edges on the top of the page, but not on the bottom?

Broski-AC

I'm working to edit the background at the bottom of my webpage and noticed a white border around the background that does not mirror the top portion of the webpage.

I've attempted the usual solution of including top: 0; and right: 0; I've also included background-size: cover, but that has not fixed the issue either.

Here is my CodePen so you can view the HTML and CSS. Note, I'm writing my CSS in SASS, so its a bit long.

I expect the lower background (which transitions from the dark purple to the dark pink) to stretch all the way to the edges, a la the upper background (dark pink to blue), but it instead has a weird white border around it.

Dennis Vash

The problem is that your body got 8px margin.

It's easy to notice with inspection (Ctrl+Shift+C on Chrome dev tools).

Reset it:

body {
  margin: 0
}

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

How to stretch background from top to bottom?

Why does my print always starts from page bottom instead of starting from top?

Why does my twitter boostrap page go off edges of the page?

Sidebar's background does not stretch to bottom with scroll

Why does Python run my code bottom to top?

Why does react display my functional component at the bottom of my page?

UIScreenEdgePanGestureRecognizer: top and bottom edges

Why does my header not stick to the top of my page

Why does my website load and show the bottom of the page first?

How do I make my div with a background image and no content show and extend from the top to bottom of the page?

Why does my Kivy BoxLayout not work at the top of my code but it does at the bottom?

Stretch element to bottom of page

The semantic footer at the bottom of my page has space showing the background at the top and bottom of it. How do I get rid of this? Link below

Why does dismiss modal resets my view to the top of page

Why does my contextual menu add empty space to top of page?

Fill/stretch the image to the right and bottom edges

Why does my page width only stretch to 100% with "fit-content"?

Why is my application executing top to bottom

Why does the Javascript code work at the bottom and not at the top?

Why does my div keep transitioning from bottom to top and not from center?

Bootstrap div stretch to bottom of page

Why will my background not repeat-x or stretch to full width?

Why is my footer at the top of my page?

why javascript runs when at bottom of page or sometimes from top of page

Border in layout does not stretch to bottom

Why is my footer not showing on the bottom of the page?

Why is my padding right and bottom only changing but not my top and left?

Why does the page jump to the bottom on load?

Why is there empty space at the top & bottom of my page when the UWP app runs? XAML nor Design view shows empty space