body {
    padding: 0;
    margin: 0;
    background-color: #000;
    overflow: hidden;
}

#unity-container {
    position: absolute
}

#unity-container.unity-desktop {
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%)
}

#unity-container.unity-mobile {
    position: fixed;
    width: 100%;
    height: 100%
}

#unity-canvas {
    background: {
            {
                {
                BACKGROUND_COLOR
            }
        }
    }

    position: relative;
    z-index: 1;
}

.unity-mobile #unity-canvas {
    width: 100%;
    height: 100%
}

#unity-warning {
    position: absolute;
    left: 50%;
    top: 5%;
    transform: translate(-50%);
    background: white;
    padding: 10px;
    display: none
}

/* 加载动画样式 */
#unity-loading {
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
}

/* 第1层：背景图 */
#unity-loading-bg {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    background: url('loadingBg.jpg') no-repeat center center;
    background-size: cover;
}

/* 第2层：半透明黑色遮罩 */
#unity-loading-overlay {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    background-color: rgba(0, 0, 0, 0.4);
}

/* 第3层：icon + 百分比文字的容器，居中叠放 */
#unity-loading-spinner {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 3;
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#unity-loading-icon {
    position: absolute;
    width: 64px;
    height: 64px;
    background: url('iconLoading.png') no-repeat center;
    background-size: contain;
    animation: rotate 1s linear infinite;
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* 百分比文字居中在圈圈内 */
#unity-loading-text {
    position: relative;
    z-index: 1;
    font-family: Arial, sans-serif;
    font-size: 12px;
    font-weight: bold;
    color: #fff;
    text-align: center;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6);
}
