When you are new to CSS, you often encounter the situation of positioning DIV. This CSS can make the DIV automatically centered:
position: absolute; width:420px; height:230px; left :50%; top:50%;margin-left:-250px; margin-top:-100px; border: 1px solid #ccc;
Collect so you won’t forget
position: absolute; yes Absolute positioning
position:relative; is the superior element relative to the current element