- 弹性盒模型
display: flex;
align-items: center;
justify-content: center;
- translate
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
- 相对定位
position: absolute;
top/right/bottom/left: 0;
margin: auto;
- table布局
display: table-cell;
vertical-align: middle;