/*init*/
body,div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,code,form,fieldset,legend,input,button,textarea,p,blockquote,th,td { margin:0; padding:0; }
body { background:#fff; color:#555; font-size:14px; font-family: Verdana, Arial, Helvetica, sans-serif; }
td,th,caption { font-size:14px; }
h1, h2, h3, h4, h5, h6 { font-weight:normal; font-size:100%; }
address, caption, cite, code, dfn, em, strong, th, var { font-style:normal; font-weight:normal;}
a { color:#555; text-decoration:none; }
a:hover { text-decoration:underline; }
img { border:none; }
ol,ul,li { list-style:none; }
input, textarea, select, button { font:14px Verdana,Helvetica,Arial,sans-serif; }
table { border-collapse:collapse; }
html {overflow-y: scroll;}

.clearfix:after {content: "."; display: block; height:0; clear:both; visibility: hidden;}
.clearfix { *zoom:1; }
html{
    display: block;
}
body{
    display: block;
    background-color: #77305f;
    height: 100%;
    position: absolute;
    top: 0;
    left:0; right: 0;
    margin: 0 auto;
    overflow: hidden;
    overflow-y: auto;
}
/* game */
.game{
    margin: 0 auto;
    width: 6.4rem;
    min-height: 100%;
    background: url(../images/game-bg.png) center top no-repeat; background-size: 6.4rem 10.08rem;
    box-sizing: border-box; overflow: hidden;
}
.game .title img{width:6.4rem;}
.game .wheel-box{width:5.58rem; height:5.6rem;margin: 0 auto; position: relative;}
.game .wheel-box #wheel{width:100%; height:100%;position: absolute; border-radius: 50%; top:0; box-sizing: border-box; overflow: hidden;left:0; background: url('../images/wheel-bg.png') center center no-repeat; background-size: 100% 100%; transform-origin: center center; transition: transform 5s cubic-bezier(0.46, 0.03, 0, 0.96);}
.game .wheel-box #arrow{width:1.55rem; height:2.21rem;position: absolute; top:0; left:0; right:0; bottom:.6rem; margin: auto; z-index: 2; background: url('../images/game-arrow.png') center center no-repeat; background-size: 1.55rem 2.21rem;}
.game .luckDrawCount{text-align: center; color: #fff; font-size: .28rem;position: relative; top:-.5rem;}

/* 添加加载动画 */
.loading {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999;
    transition: opacity 0.3s ease-out;
}

.loading.hide {
    opacity: 0;
    pointer-events: none;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #77305f;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 添加转盘动画优化 */
#wheel {
    will-change: transform;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}

/* 添加响应式设计 */
@media screen and (max-width: 320px) {
    .game .wheel-box {
        width: 5rem;
        height: 5rem;
    }
}

/* 添加触摸反馈 */
#arrow {
    transition: transform 0.1s ease;
}

#arrow:active {
    transform: scale(0.95);
}

/* 模态框样式 */
.modal {
    display: none; /* 默认隐藏 */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.6); /* 稍微暗一点的背景 */
}

.modal-content {
    background: linear-gradient(135deg, #ff4e50, #f9d423); /* 喜庆的渐变背景 */
    margin: 30% auto;
    padding: 25px 20px;
    width: 85%; /* 宽度 */
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    position: relative;
    animation: modalPop 0.3s ease-out;
}

@keyframes modalPop {
    0% { transform: scale(0.8); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

#modalMessage {
    color: #fff;
    font-size: 0.5rem;
    line-height: 1.5;
    text-shadow: 0 1px 2px rgba(0,0,0,0.1);
    margin: 10px 0;
}

.close {
    position: absolute;
    right: 15px;
    top: 10px;
    color: #fff;
    float: right;
    font-size: 28px;
    font-weight: bold;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
    transition: transform 0.2s ease;
}

.close:hover,
.close:focus {
    color: #fff;
    text-decoration: none;
    cursor: pointer;
    transform: rotate(90deg);
}

/* 转盘内部样式 */
.wheel-inner {
    position: absolute;
    width: 83%;
    height: 83%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    overflow: hidden;
}

.prize-part {
    height: 100%;
    width: 50%;
    position: absolute;
    top: 0;
    left: 50%;
    transform-origin: left center;
    box-sizing: border-box;
}

.prize-bg {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

.prize-text {
    transform: translate(0, -50%) rotate(90deg);
    width: 100%;
    text-align: center;
    position: absolute;
    top: 50%;
    left: 20%;
    font-size: 0.28rem;
    padding-top: 0.3rem;
    box-sizing: border-box;
    white-space: nowrap;
    z-index: 1;
}






