/* style.css - 完整样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Roboto, system-ui, sans-serif;
}

body {
    background: linear-gradient(145deg, #0f1923 0%, #1a2a38 100%);
    min-height: 100vh;
    padding: 16px;
}

#app {
    max-width: 700px;
    margin: 0 auto;
}

/* ===== 顶部导航 ===== */
.top-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 18px;
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(12px);
    border-radius: 16px;
    border: 1px solid rgba(255, 215, 150, 0.1);
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}
.top-nav h1 {
    color: #f3e4c2;
    font-weight: 500;
    font-size: 1.1rem;
}
.top-nav h1 i {
    color: #e6b84c;
    margin-right: 8px;
}
.nav-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}
.nav-link-btn, .nav-live-btn, .nav-admin-btn {
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 0.75rem;
    transition: 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    text-decoration: none;
    cursor: pointer;
    border: none;
}
.nav-link-btn {
    background: rgba(100, 180, 255, 0.12);
    color: #7ab7f0;
    border: 1px solid rgba(100, 180, 255, 0.2);
}
.nav-link-btn:hover {
    background: rgba(100, 180, 255, 0.2);
}
.nav-live-btn {
    background: rgba(230, 184, 76, 0.15);
    color: #e6b84c;
    border: 1px solid rgba(230, 184, 76, 0.25);
}
.nav-live-btn:hover {
    background: rgba(230, 184, 76, 0.25);
}
.nav-admin-btn {
    background: rgba(255, 255, 255, 0.06);
    color: #aab8c5;
    border: 1px solid rgba(255, 255, 255, 0.06);
}
.nav-admin-btn:hover {
    background: rgba(255, 255, 255, 0.12);
}

/* ===== 在线人数 ===== */
.online-badge {
    text-align: center;
    color: #8fa5b5;
    font-size: 0.8rem;
    margin-bottom: 8px;
}
.online-badge i {
    color: #6fcf97;
    margin-right: 4px;
}
.online-badge span {
    color: #f3e4c2;
    font-weight: 600;
}

/* ===== 认证弹窗 ===== */
.auth-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 20px;
}
.auth-modal-content {
    background: linear-gradient(145deg, #1a2a38, #0f1923);
    border-radius: 24px;
    max-width: 440px;
    width: 100%;
    padding: 24px 28px;
    border: 1px solid rgba(255, 215, 150, 0.12);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    animation: authFadeIn 0.3s ease-out;
}
@keyframes authFadeIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}
.auth-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
}
.auth-header i {
    font-size: 1.8rem;
    color: #e6b84c;
}
.auth-header h2 {
    color: #f3e4c2;
    font-weight: 500;
    font-size: 1.2rem;
}
.auth-body {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.auth-notice {
    background: rgba(230, 184, 76, 0.08);
    border-radius: 10px;
    padding: 10px 14px;
    border-left: 3px solid #e6b84c;
}
.auth-notice p {
    color: #d4cbb8;
    font-size: 0.85rem;
    line-height: 1.5;
}
.auth-notice-detail {
    margin-top: 4px;
    font-size: 0.78rem;
    color: #aab8c5;
    padding-left: 4px;
    line-height: 1.6;
}
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.auth-form-group {
    display: flex;
    flex-direction: column;
    gap: 3px;
}
.auth-form-group label {
    color: #bdaa85;
    font-size: 0.8rem;
    font-weight: 500;
}
.auth-form-group label i {
    margin-right: 6px;
    color: #8fa5b5;
}
.auth-form-group input {
    padding: 8px 14px;
    border-radius: 25px;
    border: none;
    background: #11212e;
    color: #f0e6d6;
    font-size: 0.9rem;
    outline: 1px solid #3d5a6f;
    transition: 0.15s;
}
.auth-form-group input:focus {
    outline: 2px solid #e6b84c;
    background: #0f1923;
}
.auth-hint {
    font-size: 0.7rem;
    color: #8fa5b5;
    padding-left: 10px;
}
.auth-hint.error {
    color: #e06a6a;
}
.auth-actions {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 4px;
}
.btn-auth-submit {
    background: linear-gradient(145deg, #e6b84c, #d49e3a);
    border: none;
    padding: 10px;
    border-radius: 25px;
    color: #1a2a36;
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    transition: 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 3px 0 #a07d2a;
}
.btn-auth-submit:active {
    transform: translateY(3px);
    box-shadow: 0 0 0 #a07d2a;
}
.btn-auth-submit:hover {
    filter: brightness(1.05);
}
.btn-auth-skip {
    background: transparent;
    border: 1px solid #3d5a6f;
    padding: 6px;
    border-radius: 25px;
    color: #8fa5b5;
    font-size: 0.8rem;
    cursor: pointer;
    transition: 0.15s;
}
.btn-auth-skip:hover {
    background: rgba(255, 255, 255, 0.04);
}
.auth-footer {
    margin-top: 12px;
    text-align: center;
    color: #6a7f8f;
    font-size: 0.7rem;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    padding-top: 10px;
}

/* ===== 认证状态栏 ===== */
.auth-status-bar {
    background: rgba(46, 125, 50, 0.12);
    border-radius: 10px;
    padding: 6px 14px;
    border: 1px solid rgba(46, 125, 50, 0.2);
    margin-bottom: 8px;
}
.auth-status-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 4px;
    color: #c9d4de;
    font-size: 0.8rem;
}
.auth-status-content i {
    font-size: 0.9rem;
}
.auth-status-content strong {
    color: #f3e4c2;
}

/* ===== 抽奖次数提示 ===== */
.limit-notice {
    background: rgba(100, 180, 255, 0.08);
    border-radius: 8px;
    padding: 4px 14px;
    border: 1px solid rgba(100, 180, 255, 0.12);
    display: none;
    align-items: center;
    gap: 8px;
    color: #aab8c5;
    font-size: 0.8rem;
    margin-bottom: 8px;
    flex-wrap: wrap;
}
.limit-notice i {
    color: #7ab7f0;
}
.limit-notice strong {
    color: #f3e4c2;
}

/* ===== 转盘 ===== */
.wheel-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
}

.wheel-wrapper {
    position: relative;
    width: 100%;
    max-width: 480px;
    aspect-ratio: 1/1;
    margin: 0 auto;
}

#wheelCanvas {
    width: 100% !important;
    height: 100% !important;
    display: block;
    border-radius: 50%;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.6), inset 0 2px 10px rgba(255, 255, 255, 0.08);
    background: #1e3140;
}

.pointer {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 56px;
    height: 56px;
    background: radial-gradient(circle at 30% 30%, #f7f7f7, #c0c0c0);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5), inset 0 -3px 6px rgba(0, 0, 0, 0.2);
    font-size: 22px;
    color: #2c3e50;
    cursor: pointer;
    transition: 0.1s;
    border: 3px solid #e0b354;
    z-index: 10;
}
.pointer:active {
    transform: translate(-50%, -50%) scale(0.92);
}

.prob-indicator {
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    padding: 4px 16px;
    border-radius: 20px;
    border: 1px solid rgba(255, 215, 150, 0.1);
    font-size: 0.7rem;
    white-space: nowrap;
}
.prob-indicator .prob-label {
    color: #8fa5b5;
}
.prob-indicator .prob-value {
    color: #e6b84c;
    font-weight: 600;
}

/* ===== 控制区域 ===== */
.controls {
    margin-top: 14px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
}

.btn-spin {
    background: linear-gradient(145deg, #f7c948, #e6a82b);
    border: none;
    padding: 10px 32px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    color: #1e2a36;
    box-shadow: 0 4px 0 #a57d2a, 0 8px 18px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: 0.08s linear;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.btn-spin:active {
    transform: translateY(4px);
    box-shadow: 0 1px 0 #a57d2a;
}
.btn-spin:disabled {
    opacity: 0.5;
    transform: translateY(3px);
    box-shadow: 0 1px 0 #a57d2a;
    cursor: not-allowed;
}

.result-text {
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    padding: 6px 18px;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #f0e9d0;
    border: 1px solid #c9b382;
    min-width: 100px;
    text-align: center;
}

.wheel-info {
    margin-top: 8px;
    color: #aab8c5;
    font-size: 0.8rem;
    text-align: center;
}
.wheel-info span {
    background: rgba(255, 255, 255, 0.06);
    padding: 3px 14px;
    border-radius: 16px;
    border: 1px solid rgba(255, 215, 150, 0.08);
}

/* ===== 中奖弹窗轮播 ===== */
.winner-marquee {
    margin-top: 10px;
    background: rgba(230, 184, 76, 0.08);
    border-radius: 10px;
    padding: 6px 14px;
    border: 1px solid rgba(230, 184, 76, 0.12);
    overflow: hidden;
}
.marquee-content {
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
}
.marquee-label {
    color: #e6b84c;
    font-weight: 600;
    font-size: 0.8rem;
    flex-shrink: 0;
}
.marquee-text {
    color: #d4cbb8;
    font-size: 0.85rem;
    overflow: hidden;
    text-overflow: ellipsis;
    animation: marqueeScroll 10s linear infinite;
}
@keyframes marqueeScroll {
    0% {
        transform: translateX(100%);
        opacity: 0;
    }
    5% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateX(-100%);
        opacity: 0;
    }
}

/* ===== 中奖弹窗 ===== */
.result-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(6px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    padding: 20px;
}
.result-modal-content {
    background: linear-gradient(145deg, #1a2a38, #0f1923);
    border-radius: 24px;
    max-width: 380px;
    width: 100%;
    padding: 28px 24px;
    text-align: center;
    border: 1px solid rgba(255, 215, 150, 0.12);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    animation: authFadeIn 0.4s ease-out;
}
.result-icon {
    font-size: 3.5rem;
    margin-bottom: 8px;
}
.result-icon.win {
    animation: winBounce 0.6s ease-out;
}
@keyframes winBounce {
    0% {
        transform: scale(0);
    }
    50% {
        transform: scale(1.3);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        transform: scale(1);
    }
}
.result-modal h2 {
    color: #f3e4c2;
    font-size: 1.2rem;
    margin-bottom: 6px;
}
.result-modal p {
    color: #d4cbb8;
    font-size: 0.9rem;
}
.result-detail {
    background: rgba(230, 184, 76, 0.08);
    border-radius: 10px;
    padding: 10px 14px;
    margin: 10px 0 14px;
    border-left: 3px solid #e6b84c;
    text-align: left;
}
.result-detail p {
    color: #aab8c5;
    font-size: 0.8rem;
    margin-bottom: 2px;
}
.result-detail p:last-child {
    margin-bottom: 0;
}
.btn-result-confirm {
    background: linear-gradient(145deg, #e6b84c, #d49e3a);
    border: none;
    padding: 10px 36px;
    border-radius: 25px;
    color: #1a2a36;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: 0.15s;
    box-shadow: 0 3px 0 #a07d2a;
}
.btn-result-confirm:active {
    transform: translateY(3px);
    box-shadow: 0 0 0 #a07d2a;
}

/* ===== 响应式 ===== */
@media (max-width: 480px) {
    body {
        padding: 10px;
    }
    .top-nav {
        padding: 8px 12px;
    }
    .top-nav h1 {
        font-size: 0.95rem;
    }
    .nav-link-btn,
    .nav-live-btn,
    .nav-admin-btn {
        padding: 4px 10px;
        font-size: 0.65rem;
    }
    .pointer {
        width: 44px;
        height: 44px;
        font-size: 18px;
    }
    .btn-spin {
        padding: 8px 24px;
        font-size: 0.85rem;
    }
    .result-text {
        font-size: 0.8rem;
        padding: 4px 14px;
        min-width: 80px;
    }
    .prob-indicator {
        font-size: 0.6rem;
        padding: 2px 12px;
    }
    .auth-modal-content {
        padding: 18px 16px;
    }
    .auth-header h2 {
        font-size: 1rem;
    }
}