• Resolved jesuspedros

    (@jesuspedros)


    Hello,

    My home page is a static home page. Unlike the posts page, there is a big gap between the header menu and the title.

    I do not seem to find how to reduce the margin. Is there a way to do so ?

    My site is on a local server at the moment but I can send screenshots if needed.

    Thanks,

    Jesus

Viewing 4 replies - 1 through 4 (of 4 total)
  • Try this code in Appearance > Customize > Additional CSS

    
    @media (min-width: 600px) {
    	.entry-header:first-child {
    		margin-top: 6rem; 
    		margin-bottom: 4rem; 
    	}
    }
    
    
    Thread Starter jesuspedros

    (@jesuspedros)

    It works like a charm! Thanks

    Hello,

    I was also using the same code for the Miyazaki theme and it worked perfectly fine.

    But now it does not work anymore because I was accidently reentering the code without the last “}”.

    Like this:

    @media (min-width: 600px) {
    .entry-header:first-child {
    margin-top: 6rem;
    margin-bottom: 4rem;
    }
    } –> I forgot this one

    After missing this last “}”, WordPress asked me if I want to apply this CSS code even if it would break the page. I stupidly clicked on yes.

    Later, I realized that the last “}” was missing and I added it.
    But now the code does not work anymore.

    Does anyone know how I can fix it?

    Thanks in advance!
    Tiki

    Edit:
    I was able to solve the problem: the name .entry-header was no longer good, the name was changed meanwhile and I was able to adapt the CSS code so that it works now!

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Reduce top margin on home page’ is closed to new replies.