/**index.wxss**/ .container{ background: url('https://minipro.luochunlvshi.com/uploads/image/shouyebeijing.png') no-repeat; background-size: 100% auto; position: relative; height:100vh; width:100%; } .backImage { width: 100%; /* 根据需要设置宽度 */ height: 100%; /* 高度自动 */ position: absolute; /* 绝对定位 */ top: 0; left: 0; z-index: -1; /* 确保图片在其他内容下方 */ } .joinActivity{ width: 657rpx; height: 159rpx; } .btn{ /* background: url('https://minipro.luochunlvshi.com/uploads/images/btn.png') no-repeat; */ background-color: #FF3838; border-radius: 60rpx; background-size: 100% 100%; height:70rpx; line-height:70rpx; text-align:center; width:280rpx; color:#FFE5C0; font-size:32rpx; letter-spacing:10px; margin-top:50rpx; text-indent: 10px; border: 2px solid #FDC87A; margin-right: 30rpx; } .btn:nth-child(2){ margin-right: 0; }