Archived topic
Above Header Hook Element - Limit Width
3 replies · Started by Mary Pearson on December 1, 2021
I have created a 3 section hook element for above my header using your excellent instructions (and with Elvin's help - thank you).
The CSS is
.header-section > div {
width: calc(100% / 3);
}
But this makes it full width. I would like it to be contained.
Can you tell me please how I accomplish this?
Website is https://3.bestwebsites.ca/
Thank you.
Hi Mary,
Is this a custom HTML?
If it is, you can add grid-container to the class attribute of above-header-section div element.
This way, the same max-width with the rest of the contained contents.
Alternatively, you can just modify this CSS on your site:
.above-header-section {
display: flex;
flex-wrap: wrap;
}
To this:
.above-header-section {
display: flex;
flex-wrap: wrap;
max-width: 1200px;
margin: 0 auto;
}
Perfect! Again, many, many thanks!!!!!
No problem. :)