Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Nested Nav Clips Header and Background-Size: Cover Not Working Reply To: Nested Nav Clips Header and Background-Size: Cover Not Working

#237003
Shikkediel
Participant

Centering the text below “HIDE” is an easy one :

.hidecontainer {
width: 100%;
}

An absolute element will only be as wide as necessary, while other block level elements will default to 100%.

Likely the other issues are caused by margins. They tend to mess up layout more than they do good if overused. The border being a remedy is a clue in that direction.

Using negative top margin on the other elements could possibly fix it but I’d maybe have a second thought if they’re necessary elsewhere instead.

The initial issue would be easier to examine if there were a demo page without the adjustments to fix it.