Having trouble with background images for sections of a page

I’ve so far been able to use a background image for a section if I set the width to 100%. However, I have trouble whenever I try to use a background image with a specific width/height, like in the Tea Cozy project. For example, the image won’t center, even with these style:

background-image: url(“./images/img-locations-background.jpg”);
background-repeat: no-repeat;
background-position: center center;
background-size: cover;

Any tips/help would be appreciated. Thanks in advance!

I figured out the solution, for anyone who is curious: margins have to be set to get the background image to behave.