        body {
            background-color: #f5f5f5;
            font-family: "Microsoft YaHei", sans-serif;
            padding-top: 0;
            /* 防止浏览器记住滚动位置 */
            scroll-behavior: auto;
            overscroll-behavior: contain;
        }
        
        /* 网站头部导航栏样式 */
        .site-header {
            background: #f5f5f5;
            padding: 5px 0;
            margin-bottom: 5px;
        }
        
        .header-content {
            background: linear-gradient(135deg, #d81e06 0%, #ff3333 100%);
            border-radius: 8px;
            box-shadow: 0 2px 4px rgba(0,0,0,0.1);
            padding: 6px 10px;
            margin: 0;
            position: relative;
        }
        
        
        /* 刮奖按钮样式 */
.scratch-btn {
    background: linear-gradient(135deg, #e91e63 0%, #f06292 100%);
    color: white;
    border: none;
    border-radius: 20px;
    padding: 6px 16px;
    font-size: 14.4px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(233, 30, 99, 0.4);
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.scratch-btn:hover {
    background: linear-gradient(135deg, #f06292 0%, #e91e63 100%);
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(233, 30, 99, 0.6);
}

.scratch-btn:active {
    transform: translateY(0);
}

.scratch-btn .icon {
    font-size: 14px;
}

/* 刮刮卡弹窗样式 */
.scratch-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 80px;
    z-index: 1000;
}

.scratch-modal {
    background: white;
    border-radius: 15px;
    width: 700px;
    max-width: 95vw;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.scratch-header {
    background: linear-gradient(135deg, #e91e63 0%, #f06292 100%);
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.scratch-header h3 {
    margin: 0;
    font-size: 18px;
}

.scratch-close {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s;
}

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

.scratch-close:focus {
    outline: none;
}

.scratch-content {
    padding: 20px;
}

.scratch-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    font-size: 14px;
}

.scratch-issue {
    color: #333;
    font-weight: bold;
}

.scratch-countdown {
    color: #e91e63;
    font-weight: bold;
}

.scratch-area {
    position: relative;
    margin: 20px auto 15px auto;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

#scratchCanvas {
    border: 2px solid #ddd;
    border-radius: 8px;
    cursor: crosshair;
    display: block;
    position: relative;
    z-index: 2;
}

.scratch-result {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    border-radius: 8px;
    z-index: 0;
    background: white;
}

.lottery-numbers {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 5px;
}

.lottery-numbers .ball-large,
.lottery-numbers .number-circle-medium,
.lottery-numbers .ball-small {
    transform: scale(0.8);
}

/* 刮奖区域数字样式 */
.scratch-lottery-numbers {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
}

.scratch-number {
    display: inline-block;
    width: 42px;
    height: 42px;
    line-height: 42px;
    text-align: center;
    border-radius: 50%;
    background: none;
    color: #333;
    font-weight: bold;
    font-size: 20px;
    border: 2px solid #333;
}

.scratch-sum {
    display: inline-block;
    width: 42px;
    height: 42px;
    line-height: 42px;
    text-align: center;
    border-radius: 50%;
    background: none;
    font-weight: bold;
    font-size: 20px;
    border: 2px solid;
}

/* 刮奖区域总和数字不同颜色的边框 */
.scratch-sum-red {
    color: #d81e06;
    border-color: #d81e06;
}

.scratch-sum-blue {
    color: #10aeff;
    border-color: #10aeff;
}

.scratch-sum-green {
    color: #07c160;
    border-color: #07c160;
}

.scratch-sum-gray {
    color: #888888;
    border-color: #888888;
}

.scratch-equals {
    font-size: 22px;
    font-weight: bold;
    color: #333;
    margin: 0 5px;
}

.waiting-text,
.drawing-text {
    color: #666;
    font-size: 16px;
    font-weight: bold;
}

.drawing-text {
    color: #e91e63;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.scratch-buttons {
    text-align: center;
    border-top: 1px solid #eee;
    margin-top: 15px;
    padding-top: 15px;
}

.scratch-buttons .scratch-btn {
    min-width: 100px;
    max-width: 120px;
    background: linear-gradient(135deg, #e91e63 0%, #f06292 100%);
    box-shadow: 0 2px 6px rgba(233, 30, 99, 0.4);
    text-align: center;
    display: inline-block;
    padding: 8px 16px;
}

.scratch-buttons .scratch-btn:hover {
    background: linear-gradient(135deg, #f06292 0%, #e91e63 100%);
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(233, 30, 99, 0.6);
}

.refresh-btn {
    background: linear-gradient(135deg, #e91e63 0%, #f06292 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
}

.refresh-btn:hover {
    background: linear-gradient(135deg, #f06292 0%, #e91e63 100%);
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(233, 30, 99, 0.3);
}

/* 移动端适配 */
@media (max-width: 768px) {
    .scratch-modal {
        width: 380px;
        margin: 10px;
    }
    
    .scratch-header {
        padding: 10px 15px;
    }
    
    .scratch-header h3 {
        font-size: 16px;
        margin: 0;
    }
    
    .scratch-content {
        padding: 10px 15px;
    }
    
    .scratch-info {
        flex-direction: column;
        gap: 3px;
        text-align: center;
        margin-bottom: 10px;
        font-size: 13px;
    }
    
    .scratch-area {
        margin: 10px auto 10px auto;
    }
    
    #scratchCanvas {
        width: 320px;
        height: 240px;
    }
    
    .scratch-buttons {
        margin-top: 10px;
        padding-top: 10px;
    }
    
    .scratch-buttons .scratch-btn {
        font-size: 13px;
        padding: 6px 12px;
        min-width: 80px;
        max-width: 100px;
    }
}

.site-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: white;
}

.site-logo:hover {
    color: white;
    text-decoration: none;
}

.logo-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ff4444 0%, #d81e06 50%, #aa1505 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 8px;
    box-shadow: 0 4px 12px rgba(216, 30, 6, 0.4), inset 0 -5px 10px rgba(0,0,0,0.2);
    position: relative;
}

.logo-icon::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 12px;
    width: 15px;
    height: 8px;
    background: rgba(255,255,255,0.3);
    border-radius: 50%;
    filter: blur(4px);
}

.logo-icon .logo-text {
    font-size: 24px;
    font-weight: bold;
    color: white;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
    font-family: Arial, sans-serif;
}

.site-title {
    font-size: 16px;
    font-weight: bold;
    margin: 0;
    color: white;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

.header-info {
    text-align: right;
    color: rgba(255,255,255,0.9);
    font-size: 16px;
}

html {
    /* 确保页面刷新后从顶部开始 */
    scroll-behavior: auto;
}
.brief-card {
    display: none;
    background-color: #fff;
    padding: 0;
    text-align: center;
    margin-bottom: 8px;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    overflow: hidden;
}
.brief-card.show {
    display: block;
}
.brief-card a {
    display: block;
}
.brief-card img {
    width: 100%;
    height: auto;
    display: block;
    cursor: pointer;
    object-fit: contain;
    object-position: center;
}

@media (max-width: 576px) {
    .brief-card {
        margin-bottom: 6px;
        border-radius: 4px;
    }
}
.lottery-card {
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    padding: 15px;
    margin-bottom: 10px;
}
.nav-tabs .nav-link {
    font-weight: bold;
    color: #555;
    border: none;
    border-bottom: 3px solid transparent;
}
.nav-tabs .nav-link.active {
    color: #d81e06;
    background: transparent;
    border-bottom: 3px solid #d81e06;
}
.countdown {
    font-size: 1.2rem;
    font-weight: bold;
    color: #d81e06;
}
.ball {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    border-radius: 50%;
    color: white;
    font-weight: bold;
    margin: 0 5px;
}
.red-ball {
    background-color: #d81e06;
}
.green-ball {
    background-color: #07c160;
}
.blue-ball {
    background-color: #10aeff;
}
.result-table {
    width: 100%;
    font-size: 0.9rem;
}
.result-table th {
    background-color: #f8f9fa;
    text-align: center;
    padding: 8px;
}
.result-table td {
    text-align: center;
    padding: 8px;
    border-bottom: 1px solid #eee;
}
.result-table tr:hover {
    background-color: #f8f9fa;
}
.unopened-container {
    background-color: #fff;
    border-radius: 5px;
    padding: 10px;
    margin-top: 15px;
}
.unopened-row {
    display: flex;
    margin-bottom: 6px;
    align-items: center;
}
.unopened-item {
    flex: 1;
    text-align: center;
    padding: 6px;
    border-radius: 3px;
    background-color: #f8f9fa;
    margin: 0 2px;
    font-size: 14.4px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.unopened-type {
    font-weight: bold;
    color: #333;
    text-align: center;
    font-size: 14.4px;
    margin-bottom: 4px;
}
.unopened-count {
    font-weight: bold;
    font-size: 14.4px;
    text-align: center;
}
.footer-seo {
    background-color: #fff;
    padding: 15px;
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-top: 20px;
}
.seo-keywords {
    text-align: center;
    color: #666;
    font-size: 0.9rem;
    line-height: 1.6;
}
.pagination {
    justify-content: center;
    margin-top: 20px;
}
.animate-ball {
    animation: rotate 2s infinite linear;
    opacity: 0.8;
}
@keyframes rotate {
    0% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(180deg); }
    100% { transform: translateY(0) rotate(360deg); }
}
.blur-text {
    filter: blur(3px);
    opacity: 0.7;
}
.unopened-header {
    display: flex;
    margin-bottom: 8px;
    font-weight: bold;
}
.unopened-header-item {
    flex: 1;
    text-align: center;
    padding: 3px;
    background-color: #f0f0f0;
    border-radius: 3px;
    margin: 0 2px;
    font-size: 11px;
}

/* 已开统计 - 期数选择按钮组（与未开期数布局对齐） */
.freq-tabs {
    display: flex;
    gap: 4px;
    margin-bottom: 10px;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.freq-tabs::-webkit-scrollbar { display: none; }
.freq-tab {
    flex: 1 1 0;
    padding: 7px 10px;
    border: 1px solid #dee2e6;
    background: #fff;
    color: #495057;
    border-radius: 7px;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    text-align: center;
}
.freq-tab:hover {
    background: #fff5f5;
    border-color: #d81e06;
    color: #d81e06;
}
.freq-tab.active {
    background: linear-gradient(135deg, #d81e06 0%, #ff3333 100%);
    color: #fff;
    border-color: #d81e06;
    box-shadow: 0 2px 6px rgba(216, 30, 6, 0.35);
}
.spinning {
    animation: ballScroll 0.8s infinite ease-in-out;
    opacity: 0.8;
}
@keyframes ballScroll {
    0% { 
        transform: translateY(0px);
        opacity: 0.8;
    }
    25% { 
        transform: translateY(-15px);
        opacity: 0.5;
    }
    50% { 
        transform: translateY(0px);
        opacity: 0.8;
    }
    75% { 
        transform: translateY(15px);
        opacity: 0.5;
    }
    100% { 
        transform: translateY(0px);
        opacity: 0.8;
    }
}
        
/* 数字圆形底色样式 */
.number-circle {
    display: inline-block;
    width: 35px;
    height: 35px;
    line-height: 35px;
    text-align: center;
    border-radius: 50%;
    color: white;
    font-weight: bold;
    margin: 0 2px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.12);
}
        
/* 手机端小号数字圆形底色样式（与大小单双保持一致，对齐参考站 www 的 num-ball） */
.number-circle-small {
    display: inline-block;
    width: 26px;
    height: 26px;
    line-height: 26px;
    text-align: center;
    border-radius: 50%;
    color: #fff;
    font-weight: 800;
    margin: 0 2px;
    font-size: 13.5px;
    vertical-align: middle;
    box-shadow: 0 2px 5px rgba(0,0,0,0.12);
}

/* 开奖区基本球样式 */
.ball-large {
    display: inline-block;
    width: 32px;
    height: 32px;
    line-height: 32px;
    text-align: center;
    border-radius: 50%;
    color: white;
    font-weight: bold;
    margin: 0 2px;
    font-size: 14px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.12);
}

/* 开奖区=号后的数字（与=号前保持一致） */
.number-circle-medium {
    display: inline-block;
    width: 32px;
    height: 32px;
    line-height: 32px;
    text-align: center;
    border-radius: 50%;
    color: white;
    font-weight: bold;
    margin: 0 2px;
    font-size: 14px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.12);
}

/* 开奖区后面的大小单双样式 */
.ball-small {
    display: inline-block;
    width: 32px;
    height: 32px;
    line-height: 32px;
    text-align: center;
    border-radius: 50%;
    color: white;
    font-weight: bold;
    margin: 0 2px;
    font-size: 14px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.12);
}

/* 开奖区和开奖号码分页=号前的数字全部蓝色（渐变底色对齐 www） */
.number-blue-all {
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
}

/* 红色数字: 1,2,7,8,12,13,18,19,23,24 */
.number-red {
    background: linear-gradient(135deg, #ef4444, #dc2626);
}

/* 蓝色数字: 3,4,9,10,14,15,20,25,26 */
.number-blue {
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
}

/* 绿色数字: 5,6,11,16,17,21,22,27 */
.number-green {
    background: linear-gradient(135deg, #22c55e, #16a34a);
}

/* 0和超出范围的数字使用灰色 */
.number-gray {
    background: linear-gradient(135deg, #94a3b8, #64748b);
}

/* 总和走势样式（对齐 www 的 trend-red/green：渐变 + 圆角 + 更大 padding） */
.trend-red {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    font-weight: bold;
    padding: 2px 6px;
    margin: 1px;
    font-size: 10.5px;
    display: inline-block;
    min-width: 16px;
    text-align: center;
    border-radius: 5px;
}

.trend-green {
    background: linear-gradient(135deg, #22c55e, #16a34a);
    color: white;
    font-weight: bold;
    padding: 2px 6px;
    margin: 1px;
    font-size: 10.5px;
    display: inline-block;
    min-width: 16px;
    text-align: center;
    border-radius: 5px;
}

/* 椭圆形状（双字横向显示） */
.trend-oval {
    border-radius: 8px;
    padding: 2px 7px;
    min-width: 20px;
}

/* 圆形形状（单字），与其他列保持相同大小 */
.trend-circle {
    border-radius: 50%;
    width: 20px;
    height: 20px;
    line-height: 16px;
    padding: 2px;
    min-width: 20px;
    font-size: 10px;
}

/* 双字组合横向显示 */
.trend-double {
    border-radius: 6px;
    padding: 2px 3px;
    min-width: 24px;
    white-space: nowrap;
    font-size: 10px;
}
        
/* 间隔行样式 */
.interval-row {
    background-color: #f8f9fa;
    border-top: 2px solid #dee2e6;
    border-bottom: 1px solid #dee2e6;
}

.interval-row td {
    padding: 4px 2px;
    font-size: 9px;
    color: #6c757d;
    text-align: center;
    vertical-align: middle;
}
        
        /* 手机端表格优化 */
        @media (max-width: 768px) {
            .result-table {
                font-size: 0.75rem;
            }
            .result-table th,
            .result-table td {
                padding: 4px 2px;
            }
            .ball {
                width: 24px;
                height: 24px;
                line-height: 24px;
                font-size: 11px;
                margin: 0 1px;
            }
        }
        
        /* 屏幕阅读器专用样式 */
        .sr-only {
            position: absolute !important;
            width: 1px !important;
            height: 1px !important;
            padding: 0 !important;
            margin: -1px !important;
            overflow: hidden !important;
            clip: rect(0, 0, 0, 0) !important;
            white-space: nowrap !important;
            border: 0 !important;
        }

        /* ===== 全局间距压缩（桌面端+手机端，与 py 保持同样紧凑度） ===== */
        /* 桌面端：略微压缩容器/分页/底部 SEO 顶边距 */
        .pagination { margin-top: 8px; }
        .unopened-container { margin-top: 10px; padding: 10px; }
        .footer-seo { margin-top: 12px; padding: 12px; }

        /* 手机端：全面压缩所有间距，对齐 py 的紧凑布局 */
        @media (max-width: 768px) {
            /* === 主容器与导航区 === */
            .main-content-wrap { margin-top: 2px !important; margin-bottom: 4px !important; }
            .main-content-wrap > nav { margin-bottom: 4px !important; }
            .breadcrumb { margin-bottom: 4px !important; }
            .tab-content { padding: 8px 6px !important; }
            .tab-content > nav { margin-top: 6px !important; }
            .pagination { margin-top: 4px !important; }

            /* === 头部 + 推广位 === */
            .brief-card { margin-bottom: 4px; }
            .site-header { padding: 2px 0 !important; margin-bottom: 2px !important; }
            .header-content { padding: 6px 12px !important; }

            /* === 开奖卡片内部：从 mb-1/mb-2/py-1 到所有子元素 === */
            .lottery-card { padding: 8px 10px !important; margin-bottom: 4px !important; }
            .lottery-card .mb-1 { margin-bottom: 3px !important; }
            .lottery-card .mb-2 { margin-bottom: 4px !important; }
            .lottery-card .py-1 { padding-top: 2px !important; padding-bottom: 2px !important; margin-top: 2px !important; }
            .lottery-card #lotteryResult { margin-top: 2px !important; }
            .lottery-card #intervalInfo { margin-top: 2px !important; font-size: 0.72rem !important; white-space: nowrap !important; overflow: hidden; }

            /* === 表格与走势列 === */
            .result-table { font-size: 0.68rem; }
            .result-table th, .result-table td { padding: 3px 2px; }
            .result-table th { font-size: 0.66rem; white-space: nowrap; }
            .issue-cell { font-size: 0.7rem; white-space: nowrap; }
            .trend-red, .trend-green { padding: 2px 5px; font-size: 9.5px; min-width: 15px; border-radius: 5px; }
            .trend-oval { padding: 2px 6px; min-width: 16px; border-radius: 7px; }
            .trend-double { padding: 2px 3px; min-width: 20px; font-size: 9px; border-radius: 5px; }
            .number-circle-small { width: 23px; height: 23px; line-height: 23px; font-size: 12px; padding: 0; }
            .ball { width: 26px; height: 26px; line-height: 26px; font-size: 11.5px; margin: 0 2px; }
            .ball-large { width: 30px; height: 30px; line-height: 30px; font-size: 13px; }

            /* === 导航标签：5个Tab强制一行显示 === */
            .nav-tabs { flex-wrap: nowrap !important; overflow-x: auto; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
            .nav-tabs::-webkit-scrollbar { display: none; }
            .nav-tabs .nav-item { flex: 1 1 0; white-space: nowrap; }
            .nav-tabs .nav-link { padding: 0.32rem 0.28rem; font-size: 0.72rem; margin-right: 1px; margin-left: 1px; text-align: center; }

            /* === 分页控件：强制一行显示，压缩尺寸 === */
            .pagination { flex-wrap: nowrap !important; gap: 0 !important; }
            .pagination .page-item .page-link,
            .pagination .page-item span.page-link { font-size: 10.5px !important; padding: 3px 5px !important; }

            /* === 未开期数 === */
            .unopened-item { font-size: 12.8px !important; padding: 5px 3px; }
            .unopened-type { font-size: 12.8px; margin-bottom: 3px; }
            .unopened-count { font-size: 12.8px; }
            .unopened-header-item { font-size: 10.5px; padding: 3px; }
            .unopened-container { margin-top: 8px !important; padding: 8px !important; }
            .unopened-row { margin-bottom: 4px !important; }
            .unopened-header { margin-bottom: 6px !important; }

            /* === 已开统计 - 期数选择 === */
            .freq-tab { padding: 5px 8px; font-size: 11.5px; }
            .freq-tabs { margin-bottom: 6px; }

            /* === 标题 / Logo / 倒计时尺寸 === */
            .site-title { font-size: 14px; }
            .logo-icon { width: 42px; height: 42px; }
            .logo-icon .logo-text { font-size: 17px; }
            .countdown { font-size: 1rem; }

            /* === 底部 SEO / 友情链接 / 版权 === */
            .footer-seo { margin-top: 8px !important; padding: 10px !important; }
            .friend-links { margin-top: 8px !important; margin-bottom: 4px !important; }
            .copyright { margin-top: 8px !important; margin-bottom: 4px !important; }

            /* === 刮刮卡弹窗（覆盖早期碎片规则） === */
            .scratch-modal { width: 390px; margin: 10px; border-radius: 14px; }
            .scratch-header { padding: 11px 16px; }
            .scratch-header h3 { font-size: 16px; margin: 0; }
            .scratch-content { padding: 12px 16px; }
            .scratch-info { flex-direction: column; gap: 4px; text-align: center; margin-bottom: 12px; font-size: 13px; }
            .scratch-area { margin: 12px auto; }
            #scratchCanvas { width: 330px; height: 250px; }
            .scratch-buttons { margin-top: 11px; padding-top: 11px; }
            .scratch-buttons .scratch-btn { font-size: 13px; padding: 7px 13px; min-width: 84px; max-width: 105px; }
        }
