/* 抽奖系统样式 */
.lottery-system {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border-radius: 15px;
    padding: 25px;
    margin: 30px auto;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    border: 2px solid #00d4ff;
    max-width: 1200px;
    position: relative;
    overflow: hidden;
}

.lottery-system::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent 30%, rgba(0, 212, 255, 0.1) 50%, transparent 70%);
    animation: shine 3s infinite linear;
}

@keyframes shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

.lottery-header {
    text-align: center;
    margin-bottom: 25px;
    position: relative;
    z-index: 1;
}

.lottery-header h2 {
    color: #00d4ff;
    font-size: 28px;
    margin-bottom: 10px;
    text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.lottery-header p {
    color: #a0aec0;
    font-size: 16px;
}

.lottery-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    position: relative;
    z-index: 1;
}

@media (min-width: 992px) {
    .lottery-container {
        grid-template-columns: 1fr 1fr;
    }
}

.lottery-wheel-section {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid rgba(0, 212, 255, 0.2);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.lottery-info-section {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid rgba(0, 212, 255, 0.2);
}

/* 抽奖转盘样式 */
.wheel-container {
    position: relative;
    width: 280px;
    height: 280px;
    margin: 0 auto 25px;
}

.wheel-canvas {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 8px solid #00d4ff;
    box-shadow: 0 0 30px rgba(0, 212, 255, 0.4);
    background: white;
}

.wheel-pointer {
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 20px solid transparent;
    border-right: 20px solid transparent;
    border-top: 40px solid #ff0000;
    filter: drop-shadow(0 0 8px #ff0000);
    z-index: 10;
}

.lottery-controls {
    text-align: center;
    margin-top: 20px;
    width: 100%;
}

.lottery-btn {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    border-radius: 50px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 5px 20px rgba(245, 158, 11, 0.4);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    animation: pulse 2s infinite;
    width: 100%;
    max-width: 300px;
    justify-content: center;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); box-shadow: 0 5px 20px rgba(245, 158, 11, 0.4); }
    50% { transform: scale(1.05); box-shadow: 0 8px 25px rgba(245, 158, 11, 0.6); }
}

.lottery-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(245, 158, 11, 0.6);
}

.lottery-btn:disabled {
    background: linear-gradient(135deg, #666 0%, #888 100%);
    cursor: not-allowed;
    transform: none;
    animation: none;
    box-shadow: none;
}

/* 抽奖信息区域 */
.lottery-stats {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 25px;
}

.lottery-stat {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 15px;
    text-align: center;
    border: 1px solid rgba(0, 212, 255, 0.1);
}

.stat-number {
    font-size: 32px;
    font-weight: bold;
    color: #00d4ff;
    margin-bottom: 5px;
    text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

.stat-label {
    color: #a0aec0;
    font-size: 14px;
}

/* 概率统计区域 */
.probability-section {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    padding: 20px;
    margin-top: 25px;
}

.probability-title {
    color: #00d4ff;
    font-size: 18px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.probability-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.probability-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(0, 212, 255, 0.1);
}

.probability-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.probability-icon {
    font-size: 20px;
}

.probability-name {
    color: white;
    font-size: 14px;
}

.probability-value {
    color: #00d4ff;
    font-weight: bold;
    font-size: 14px;
    background: rgba(0, 212, 255, 0.1);
    padding: 4px 10px;
    border-radius: 20px;
}

/* 抽奖结果弹窗 */
.lottery-result-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 9999;
    align-items: center;
    justify-content: center;
}

.lottery-result-modal.active {
    display: flex;
}

.lottery-result-content {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border-radius: 20px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    text-align: center;
    border: 3px solid #00d4ff;
    box-shadow: 0 0 50px rgba(0, 212, 255, 0.5);
    animation: modalIn 0.5s ease;
    position: relative;
    overflow: hidden;
}

@keyframes modalIn {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(-50px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.result-title {
    color: #00d4ff;
    font-size: 28px;
    margin-bottom: 20px;
    position: relative;
    z-index: 1;
}

.result-icon {
    font-size: 80px;
    margin: 20px 0;
    animation: bounce 1s infinite alternate;
    position: relative;
    z-index: 1;
}

@keyframes bounce {
    from { transform: scale(1); }
    to { transform: scale(1.2); }
}

.result-prize {
    color: white;
    font-size: 24px;
    font-weight: bold;
    margin: 20px 0;
    position: relative;
    z-index: 1;
}

.result-code {
    background: rgba(0, 0, 0, 0.3);
    border: 2px dashed #00d4ff;
    border-radius: 10px;
    padding: 15px;
    margin: 20px 0;
    font-family: monospace;
    font-size: 20px;
    color: #00ff88;
    position: relative;
    z-index: 1;
}

.result-message {
    color: #a0aec0;
    margin: 15px 0;
    position: relative;
    z-index: 1;
}

.result-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 25px;
    position: relative;
    z-index: 1;
}

.result-btn {
    padding: 12px 25px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: bold;
}

.btn-copy {
    background: linear-gradient(135deg, #00d4ff 0%, #0088cc 100%);
    color: white;
}

.btn-close {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-copy:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 212, 255, 0.4);
}

.btn-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* 激活码系统增强样式 */
.activation-code-system {
    background: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
    border-radius: 15px;
    padding: 2px;
    margin: 30px auto;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    border: 2px solid #00d4ff;
    max-width: 1200px;
    position: relative;
    overflow: hidden;
}

.activation-code-system::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="20" height="20" patternUnits="userSpaceOnUse"><path d="M 20 0 L 0 0 0 20" fill="none" stroke="rgba(255,46,99,0.1)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.system-header {
    text-align: center;
    margin-bottom: 10px;
    position: relative;
    z-index: 1;
    margin-top: -5px;
}

.system-header h2 {
    color: #00d4ff;
    font-size: 28px;
    margin-bottom: 10px;
    text-shadow: 0 0 10px rgba(255, 46, 99, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.code-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 30px 0;
    position: relative;
    z-index: 1;
}

.code-stat-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 80px;
    padding: 2px;
    text-align: center;
    border: 1px solid rgba(255, 46, 99, 0.2);
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.code-stat-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 46, 99, 0.5);
    box-shadow: 0 10px 20px rgba(255, 46, 99, 0.2);
}

.code-stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #00d4ff, #ff8a00);
}

.code-stat-number {
    font-size: 36px;
    font-weight: bold;
    color: #00d4ff;
    margin-bottom: 5px;
    text-shadow: 0 0 10px rgba(255, 46, 99, 0.3);
}

.code-stat-label {
    color: #a0aec0;
    font-size: 14px;
}

/* 脚本卡片增强样式 */
.script-card {
    position: relative;
    overflow: hidden;
    transition: all 0.3s;
}

.script-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(255, 46, 99, 0.2);
}

.script-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #00d4ff, #ff8a00);
}

/* 响应式调整 */
@media (max-width: 768px) {
    /* 抽奖统计2列布局 */
    .lottery-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    /* 激活码统计2列布局 */
    .code-stats-grid {
        grid-template-columns: repeat(2, 1fr) !important;
        gap: 10px;
    }
    
    /* 抽奖转盘缩小 */
    .wheel-container {
        width: 250px;
        height: 250px;
    }
    
    /* 抽奖结果弹窗调整 */
    .result-icon {
        font-size: 60px;
    }
    
    .result-prize {
        font-size: 20px;
    }
    
    /* 统计卡片调整 */
    .lottery-stat, .code-stat-card {
        padding: 12px;
    }
    
    .stat-number, .code-stat-number {
        font-size: 28px;
    }
    
    .lottery-container {
        grid-template-columns: 1fr;
    }
}

/* 额外的统计动画样式 */
@keyframes countUp {
    from { 
        transform: translateY(10px);
        opacity: 0;
    }
    to { 
        transform: translateY(0);
        opacity: 1;
    }
}

.stat-number.animating, .code-stat-number.animating {
    animation: countUp 0.6s ease-out forwards;
    display: inline-block;
}

/* 隐藏重复栏目 */
.stats {
    display: none !important;
}

.scripts-grid:not(#system-scripts-grid) {
    display: none !important;
}