Answer the question
In order to leave comments, you need to log in
How to align block position: absolute; in the center?
You need to make such a header screenshot.ru/87a75f16a0a8047746cf2202b561b1d8 gave the logo position: absolute; to knock it out of the flow and place it between the menu, but he does not want to become centered, even if you write
left: 50%;
margin-left: 585px;
How to put the logo block in the center? and maybe you have a better idea to implement such a hat?
Forgot to give codepen.io/anon/pen/epvPqM
Answer the question
In order to leave comments, you need to log in
You obviously made a mistake with the indent, if you want to make it in the center, then if the logo is 50x50:
left: 50%;
margin-left: -25px; /* половина ширины logo */
transform: translateX(-50%);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question