Center a div: 7 ways
Pick a method, change the sizes, and check if the box is really centered.
Horizontal
Vertical
I'm centered?
Box width
160px
Box height
90px
Parent height
300px
Copy CSS