body,html{ margin:0; padding:0; } .main{ height: calc(100vh); background-image: url("../images/mainBg.png"); background-size: cover; background-repeat: no-repeat; display: flex; align-items: center; justify-content: center; } .btnGroup{ display: flex; width:75%; } .btnGroup .item{ flex: 1; position: relative; } .btnGroup .item>img{ width:100%; } .btnGroup .item .text{ display: flex; display: flex; align-items: center; justify-content: center; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); } .btnGroup .item .text span{ margin-left:15px; font-family: PingFang SC; font-weight: bold; font-size: 1.6rem; color: #FFFFFF; }