@font-face {
    font-family: 'TWSixMark';
    src: url('../img/ab40a589.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'TWSixMark', 'Microsoft YaHei', 'PingFang SC', Arial, sans-serif;
    background: #f5f5f5;
    min-height: 100vh;
    color: #333;
    padding-bottom: 70px; /* 为手机版底部导航留出空间 */
    /* 优化移动端滚动体验 */
    -webkit-overflow-scrolling: touch;
    /* 防止iOS Safari自动调整字体大小 */
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 主头部包装区域 - (A+B+C+D+E)整体背景 */
.main-header-wrapper {
    position: relative;
}

/* 头部顶部区域 - (A+B+C)背景 */
.header-top-section {
    padding: 20px 0;
    position: relative;
}

.header-top-content {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    gap: 30px;
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
}

/* (A) Logo区域 */
.logo-section {
    flex-shrink: 0;
}

.header-logo {
    height: 76px !important;
    width: auto !important;
    max-height: 76px !important;
    object-fit: contain;
    display: block;
}

/* (B) 导航菜单区域 - 电脑版靠左 */
.header-nav {
    flex: 1;
    display: flex;
    align-items: center;
    position: relative;
}

.nav-menu {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    list-style: none;
    gap: 30px;
    margin: 0;
    padding: 0;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
}

.nav-menu li {
    margin: 0;
}

.nav-menu a {
    text-decoration: none;
    color: #fff;
    font-weight: bold;
    font-size: 16px;
    -webkit-transition: color 0.3s;
    -o-transition: color 0.3s;
    transition: color 0.3s;
    position: relative;
    padding: 5px 0;
}

.nav-menu a:hover,
.nav-menu .current-menu-item a,
.nav-menu .current_page_item a {
    color: #ff6b35;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: #ff6b35;
    -webkit-transition: width 0.3s;
    -o-transition: width 0.3s;
    transition: width 0.3s;
}

.nav-menu a:hover::after,
.nav-menu .current-menu-item a::after,
.nav-menu .current_page_item a::after {
    width: 100%;
}

/* (C) 时间区域 */
.datetime-section {
    color: #fff;
    font-size: 16px;
    white-space: nowrap;
    flex-shrink: 0;
}

/* (D) 倒计时区域 */
.countdown-section {
    padding: 20px 0;
    position: relative;
}

.countdown-content {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    gap: 30px;
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
    -webkit-box-pack: end;
    -ms-flex-pack: end;
    justify-content: flex-end;
}

.next-draw-info-top {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    justify-content: flex-end;
    margin-bottom: 10px;
}

.next-draw-label {
    color: #fff;
    font-size: 14px;
}

.next-draw-period {
    background: rgba(255, 107, 53, 0.1);
    color: #ff6b35;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: bold;
}

.countdown-wrapper {
    flex: 1;
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.countdown-timer {
    font-size: 32px;
    font-weight: bold;
    color: #ff6b35;
    letter-spacing: 3px;
    margin-bottom: 5px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    gap: 4px;
}

/* 倒计时数字边框样式 */
.countdown-digit {
    display: inline-block;
    background: #fff;
    border: 1px solid #d0d0d0;
    -webkit-border-radius: 8px;
    border-radius: 8px;
    padding: 8px 12px;
    min-width: 40px;
    text-align: center;
    -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08);
    font-family: 'Courier New', monospace;
    color: #333;
    font-weight: bold;
}

/* 倒计时分隔符样式 */
.countdown-separator {
    color: #ff6b35;
    font-weight: bold;
    padding: 0 4px;
    font-size: 32px;
}

.countdown-label {
    color: #fff;
    font-size: 12px;
}

/* (E) 最新一期开奖号码区域 */
.latest-draw-section {
    padding: 40px 0;
    position: relative;
    margin: 20px 0;
}

.latest-draw-content {
    text-align: center;
    color: #333;
}

.latest-draw-period {
    display: inline-block;
    background: #FFEDBE;
    color: #ff6b35;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 15px;
}

.latest-numbers {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    gap: 10px;
    -ms-flex-wrap: nowrap;
    flex-wrap: nowrap;
}

/* 号码球容器 - 确保横向排列 */
.numbers {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: horizontal;
    -webkit-box-direction: normal;
    -ms-flex-direction: row;
    flex-direction: row;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    gap: 10px;
    -ms-flex-wrap: nowrap;
    flex-wrap: nowrap;
}

.number-separator {
    font-size: 24px;
    color: #333;
    font-weight: bold;
    margin: 0 5px;
}

/* 号码球包装器（包含号码球和生肖） */
.number-ball-wrapper {
    display: -webkit-box !important;
    display: -ms-flexbox !important;
    display: flex !important;
    -webkit-box-orient: vertical !important;
    -webkit-box-direction: normal !important;
    -ms-flex-direction: column !important;
    flex-direction: column !important;
    -webkit-box-align: center !important;
    -ms-flex-align: center !important;
    align-items: center !important;
    gap: 5px !important;
    -ms-flex-negative: 0;
    flex-shrink: 0;
}

/* 开奖号码球样式 */
.number-ball {
    width: 60px;
    height: 60px;
    min-width: 60px;
    min-height: 60px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    position: relative;
    -ms-flex-negative: 0;
    flex-shrink: 0;
}

/* 生肖文字样式 */
.number-zodiac {
    font-size: 14px !important;
    color: #333 !important;
    font-weight: 500;
    text-align: center;
    white-space: nowrap;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.number-img {
    width: 60px;
    height: 60px;
    max-width: 60px;
    max-height: 60px;
    /* 兼容性：IE不支持object-fit，使用background-image替代 */
    -o-object-fit: contain;
    object-fit: contain;
    display: block;
}

.number-fallback {
    position: absolute;
    font-weight: bold;
    font-size: 18px;
    color: #333;
}

/* 實時開獎區域 */
.demo-section {
    padding: 40px 0;
    border-bottom: 1px solid #e0e0e0;
    position: relative;
    /* 去掉bg1.png，使用bg.png背景（由main-header-wrapper提供） */
    background: rgba(255, 255, 255, 0.6); /* 白色60%透明底背景 */
    z-index: 2;
}

.demo-header {
    text-align: center;
    margin-bottom: 30px;
    font-size: 18px;
    color: #333;
}

.demo-title {
    color: #333;
    font-weight: bold;
}

.demo-period-label {
    color: #333;
    margin: 0 5px;
}

.demo-period-number {
    color: #ff6b35;
    font-weight: bold;
    font-size: 18px;
    display: inline-block;
    background: #FFEDBE;
    padding: 6px 16px;
    border-radius: 20px;
    margin: 0 5px;
}

.demo-numbers-container {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 10px !important;
    flex-wrap: wrap !important;
    min-height: 120px !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.demo-number-slot {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 5px !important;
    flex-shrink: 0 !important;
}

.demo-number-ball {
    width: 60px !important;
    height: 60px !important;
    min-width: 60px !important;
    min-height: 60px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    position: relative !important;
    border-radius: 50% !important;
    transition: all 0.3s ease !important;
    box-sizing: border-box !important;
}

.demo-number-ball.waiting {
    background: #e0e0e0 !important;
    background-color: #e0e0e0 !important;
    border: 2px solid #c0c0c0 !important;
    border-radius: 50% !important;
    width: 60px !important;
    height: 60px !important;
    min-width: 60px !important;
    min-height: 60px !important;
    max-width: 60px !important;
    max-height: 60px !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1) !important;
}

.demo-waiting-char {
    font-size: 24px !important;
    color: #666 !important;
    text-align: center !important;
    display: block !important;
    font-weight: bold !important;
    line-height: 1 !important;
}

.demo-number-ball.revealed {
    border-radius: 50% !important;
    width: 60px !important;
    height: 60px !important;
    min-width: 60px !important;
    min-height: 60px !important;
    max-width: 60px !important;
    max-height: 60px !important;
    border: none !important;
}

.demo-number-ball.revealed.red {
    background: #e74c3c !important;
    background-color: #e74c3c !important;
}

.demo-number-ball.revealed.blue {
    background: #3498db !important;
    background-color: #3498db !important;
}

.demo-number-ball.revealed.green {
    background: #2ecc71 !important;
    background-color: #2ecc71 !important;
}

/* 兼容性：单独的颜色类 */
.demo-number-ball.red {
    background: #e74c3c !important;
    background-color: #e74c3c !important;
}

.demo-number-ball.blue {
    background: #3498db !important;
    background-color: #3498db !important;
}

.demo-number-ball.green {
    background: #2ecc71 !important;
    background-color: #2ecc71 !important;
}

/* 確保號碼圖片在彩色背景上可見 */
.demo-number-ball.revealed .demo-number-img {
    filter: brightness(1.1) !important;
    mix-blend-mode: normal !important;
    width: 60px !important;
    height: 60px !important;
    max-width: 60px !important;
    max-height: 60px !important;
    object-fit: contain !important;
    display: block !important;
}

.demo-number-img {
    width: 60px !important;
    height: 60px !important;
    max-width: 60px !important;
    max-height: 60px !important;
    object-fit: contain !important;
    display: block !important;
}

.demo-number-fallback {
    position: absolute !important;
    font-weight: bold !important;
    font-size: 24px !important;
    color: #fff !important;
    z-index: 1 !important;
}

.demo-number-zodiac {
    font-size: 14px !important;
    color: #333 !important;
    font-weight: 500 !important;
    text-align: center !important;
    display: none !important;
    margin-top: 5px !important;
}

.demo-number-zodiac:not(:empty) {
    display: block !important;
}

.demo-number-separator {
    font-size: 24px !important;
    color: #ff6b35 !important;
    font-weight: bold !important;
    margin: 0 5px !important;
    display: inline !important;
    line-height: 1 !important;
    vertical-align: middle !important;
}

/* 開獎動畫 */
@-webkit-keyframes numberReveal {
    0% {
        -webkit-transform: scale(0);
        transform: scale(0);
        opacity: 0;
    }
    50% {
        -webkit-transform: scale(1.2);
        transform: scale(1.2);
    }
    100% {
        -webkit-transform: scale(1);
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes numberReveal {
    0% {
        -webkit-transform: scale(0);
        transform: scale(0);
        opacity: 0;
    }
    50% {
        -webkit-transform: scale(1.2);
        transform: scale(1.2);
    }
    100% {
        -webkit-transform: scale(1);
        transform: scale(1);
        opacity: 1;
    }
}

/* (F) 开奖公告区域 */
.announcement-section {
    padding: 40px 0;
    background: #fff;
}

.section-title {
    font-size: 24px;
    color: #333;
    margin-bottom: 30px;
    text-align: center;
}

.announcement-list {
    display: grid;
    gap: 20px;
}

.announcement-item {
    background: #f8f9fa;
    border-left: 4px solid #ff6b35;
    padding: 20px;
    border-radius: 8px;
    transition: all 0.3s;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.announcement-item:hover {
    background: #e9ecef;
    transform: translateX(5px);
}

.announcement-item-content {
    flex: 1;
}

.announcement-period {
    color: #ff6b35;
    font-size: 18px;
    margin-bottom: 10px;
    font-weight: bold;
    display: inline-block;
    background: #FFEDBE;
    padding: 6px 16px;
    border-radius: 20px;
}

.announcement-date {
    color: #666;
    font-size: 14px;
    margin-bottom: 15px;
}

.announcement-numbers {
    display: flex;
    flex-direction: row;
    gap: 10px;
    flex-wrap: nowrap;
    align-items: center;
}

.replay-button {
    background: -webkit-gradient(linear, left top, right bottom, from(#ff6b35), to(#f7931e));
    background: -webkit-linear-gradient(135deg, #ff6b35 0%, #f7931e 100%);
    background: -o-linear-gradient(135deg, #ff6b35 0%, #f7931e 100%);
    background: linear-gradient(135deg, #ff6b35 0%, #f7931e 100%);
    color: white;
    padding: 10px 20px;
    -webkit-border-radius: 5px;
    border-radius: 5px;
    text-decoration: none;
    font-size: 14px;
    -webkit-transition: -webkit-transform 0.3s;
    -o-transition: transform 0.3s;
    transition: transform 0.3s;
    white-space: nowrap;
    margin-left: 15px;
    -ms-flex-negative: 0;
    flex-shrink: 0;
    /* 优化触摸体验 */
    -webkit-tap-highlight-color: rgba(255, 107, 53, 0.3);
    touch-action: manipulation;
    cursor: pointer;
    display: inline-block;
}

.replay-button:hover,
.replay-button:active {
    -webkit-transform: scale(1.05);
    -ms-transform: scale(1.05);
    transform: scale(1.05);
}

/* 页脚区域 */
.site-footer {
    margin-top: 50px;
    position: relative;
}

.footer-content {
    position: relative;
}

.footer-top {
    display: flex;
    align-items: center;
    gap: 30px;
    padding: 30px 0;
    flex-wrap: wrap;
}

/* (G) 页脚Logo区域 */
.footer-logo-section {
    flex-shrink: 0;
}

.footer-logo {
    height: 100px !important;
    width: auto !important;
    max-height: 100px !important;
    object-fit: contain;
    display: block;
}

/* (H) 公司信息区域 */
.footer-info-section {
    flex: 1;
    color: #666;
}

.company-name {
    font-size: 18px;
    font-weight: bold;
    color: #333;
    margin-bottom: 10px;
}

.copyright {
    font-size: 14px;
    margin-bottom: 8px;
}

.contact-info {
    font-size: 14px;
}


/* 手机版底部导航菜单 */
.mobile-nav {
    display: none !important;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    padding: 0;
    width: 100%;
    max-width: 100vw;
    box-sizing: border-box;
}

.mobile-nav-container {
    display: flex;
    justify-content: space-around;
    align-items: center;
    width: 100%;
    max-width: 100%;
    padding: 8px 0;
    box-sizing: border-box;
    margin: 0;
}

.mobile-nav-item {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: center;
    -ms-flex-pack: center;
    justify-content: center;
    text-decoration: none;
    color: #666;
    font-size: 11px;
    padding: 5px 4px;
    -webkit-transition: color 0.3s;
    -o-transition: color 0.3s;
    transition: color 0.3s;
    -webkit-box-flex: 1;
    -ms-flex: 1;
    flex: 1;
    min-width: 0;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    text-align: center;
    /* 优化触摸体验 */
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    cursor: pointer;
}

.mobile-nav-item.active {
    color: #ff6b35;
}

.mobile-nav-text {
    margin-top: 5px;
}

/* 主要内容区域 */
.main-content {
    padding: 40px 0;
    min-height: calc(100vh - 400px);
}

/* 视频列表样式 */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.video-item {
    background: #f8f9fa;
    border-radius: 10px;
    overflow: hidden;
    transition: transform 0.3s;
}

.video-item:hover {
    transform: scale(1.03);
}

.video-thumbnail {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 48px;
    position: relative;
    overflow: hidden;
}

.video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.video-thumbnail::after {
    content: '▶';
    position: absolute;
    font-size: 60px;
    opacity: 0.8;
    z-index: 1;
}

.video-info {
    padding: 20px;
}

.video-info h3 {
    color: #667eea;
    margin-bottom: 10px;
}

.video-info .date {
    color: #666;
    font-size: 14px;
}

/* FAQ样式 */
.faq-list {
    display: grid;
    gap: 20px;
}

.faq-item {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 25px;
    transition: all 0.3s;
}

.faq-item:hover {
    background: #e9ecef;
}

.faq-question {
    font-size: 20px;
    color: #667eea;
    margin-bottom: 15px;
    font-weight: 600;
}

.faq-answer {
    color: #666;
    line-height: 1.8;
}

/* 关于我们样式 */
.about-content {
    line-height: 2;
    color: #555;
}

.about-content p {
    margin-bottom: 20px;
}

.about-content h3 {
    color: #667eea;
    margin: 30px 0 15px 0;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.team-member {
    text-align: center;
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
}

.team-member .avatar {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    margin: 0 auto 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 36px;
}

/* 按钮样式 */
.button {
    display: inline-block;
    padding: 12px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white !important;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 500;
    transition: transform 0.3s, box-shadow 0.3s;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

/* WordPress 内容样式 */
.entry-content {
    line-height: 1.8;
}

.entry-content h1,
.entry-content h2,
.entry-content h3,
.entry-content h4 {
    color: #667eea;
    margin: 20px 0 15px 0;
}

.entry-content p {
    margin-bottom: 15px;
}

.entry-content ul,
.entry-content ol {
    margin-left: 20px;
    margin-bottom: 15px;
}

/* 响应式设计 - 手机版 */
@media (max-width: 768px) {
    body {
        padding-bottom: 70px;
        /* 防止移动端横向滚动 */
        overflow-x: hidden;
        width: 100%;
        max-width: 100vw;
    }
    
    html {
        overflow-x: hidden;
        width: 100%;
        max-width: 100vw;
    }
    
    /* 隐藏电脑版导航 */
    .header-nav {
        display: none !important;
    }
    
    /* 显示手机版底部导航 */
    .mobile-nav {
        display: flex !important;
        width: 100% !important;
        max-width: 100vw !important;
        left: 0 !important;
        right: 0 !important;
    }
    
    .mobile-nav-container {
        width: 100% !important;
        max-width: 100% !important;
        padding: 8px 2px !important;
    }
    
    .mobile-nav-item {
        font-size: 10px !important;
        padding: 4px 2px !important;
        min-width: 0 !important;
        flex: 1 1 0 !important;
    }
    
    .mobile-nav-text {
        font-size: 10px !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 100%;
    }
    
    .header-top-content {
        -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
        -ms-flex-direction: column;
        flex-direction: column;
        -webkit-box-align: start;
        -ms-flex-align: start;
        align-items: flex-start;
        gap: 15px;
    }
    
    .header-logo {
        height: 50px !important;
        max-height: 50px !important;
    }
    
    .datetime-section {
        width: 100%;
    }
    
    .countdown-content {
        -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
        -ms-flex-direction: column;
        flex-direction: column;
        -webkit-box-align: start;
        -ms-flex-align: start;
        align-items: flex-start;
        gap: 15px;
    }
    
    .countdown-wrapper {
        width: 100%;
        text-align: left !important;
        -webkit-box-align: start !important;
        -ms-flex-align: start !important;
        align-items: flex-start !important;
    }
    
    .next-draw-info-top {
        -webkit-box-pack: start !important;
        -ms-flex-pack: start !important;
        justify-content: flex-start !important;
    }
    
    .countdown-timer {
        font-size: 20px;
        gap: 3px;
        letter-spacing: 2px;
    }
    
    .countdown-digit {
        padding: 6px 8px;
        min-width: 32px;
        font-size: 20px;
        -webkit-border-radius: 4px;
        border-radius: 4px;
    }
    
    .countdown-separator {
        font-size: 20px;
        padding: 0 2px;
    }
    
    .demo-section {
        padding: 30px 0;
    }
    
    .demo-header {
        font-size: 16px;
        margin-bottom: 20px;
    }
    
    .demo-period-number {
        font-size: 16px;
        padding: 5px 12px;
    }
    
    .demo-numbers-container {
        gap: 4px !important;
        min-height: 100px !important;
        /* 确保7个球（6个号码+1个特码）能并排一行 */
        flex-wrap: nowrap !important;
        overflow-x: visible !important;
        padding: 0 5px !important;
    }
    
    /* 手机版：根据屏幕宽度动态调整号码球尺寸，确保7个球并排一行不超出屏幕 */
    .demo-number-ball {
        /* 使用clamp确保尺寸在35px-50px之间，根据屏幕宽度自适应 */
        /* 计算公式：(100vw - 48px) / 7，其中48px包括左右padding和gap */
        width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        min-width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        min-height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        max-width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        max-height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
    }
    
    .demo-number-ball.waiting {
        width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        min-width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        min-height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        max-width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        max-height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
    }
    
    .demo-waiting-char {
        font-size: clamp(14px, calc((100vw - 48px) / 7 * 0.4), 20px) !important;
    }
    
    .demo-number-ball.revealed {
        width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        min-width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        min-height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        max-width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        max-height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
    }
    
    .demo-number-img {
        width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        min-width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        min-height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        max-width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        max-height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
    }
    
    .demo-number-ball.revealed .demo-number-img {
        width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        min-width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        min-height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        max-width: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
        max-height: clamp(35px, calc((100vw - 48px) / 7), 50px) !important;
    }
    
    .demo-number-fallback {
        font-size: clamp(14px, calc((100vw - 48px) / 7 * 0.4), 20px) !important;
    }
    
    .demo-number-zodiac {
        font-size: 12px !important;
    }
    
    .demo-waiting-text {
        font-size: 10px !important;
    }
    
    .demo-number-separator {
        font-size: 20px !important;
        display: inline !important;
        margin: 0 3px !important;
        color: #ff6b35 !important;
        font-weight: bold !important;
    }
    
    .latest-draw-section {
        padding: 30px 0;
    }
    
    .latest-draw-content {
        padding: 0 10px;
    }
    
    .latest-numbers {
        gap: 4px;
        -ms-flex-wrap: nowrap;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-box-pack: center;
        -ms-flex-pack: center;
        justify-content: center;
        padding: 10px 5px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE and Edge */
        width: 100%;
        -webkit-box-sizing: border-box;
        box-sizing: border-box;
    }
    
    .latest-numbers::-webkit-scrollbar {
        display: none; /* Chrome, Safari, Opera */
    }
    
    .announcement-numbers {
        flex-wrap: nowrap !important; /* 确保7个号码并排 */
        gap: 3px !important; /* 减小gap以节省空间 */
        justify-content: center !important;
        overflow-x: hidden !important; /* 防止超出屏幕 */
        padding: 0 8px !important; /* 减小左右padding */
        box-sizing: border-box !important;
    }
    
    .numbers {
        flex-wrap: nowrap !important; /* 确保7个号码并排 */
        gap: 3px !important; /* 减小gap以节省空间 */
    }
    
    /* 根据屏幕宽度动态调整号码球尺寸，确保7个号码并排且不超出屏幕 */
    /* 使用vw单位，考虑容器padding和间距 */
    /* 计算公式：(屏幕宽度 - 左右padding - 间距总和) / 7个号码 */
    /* 减小尺寸以确保7个球不超出屏幕，考虑更小的gap和padding */
    .number-ball {
        width: clamp(28px, calc((100vw - 60px) / 7), 42px) !important;
        height: clamp(28px, calc((100vw - 60px) / 7), 42px) !important;
        min-width: clamp(28px, calc((100vw - 60px) / 7), 42px) !important;
        min-height: clamp(28px, calc((100vw - 60px) / 7), 42px) !important;
        max-width: clamp(28px, calc((100vw - 60px) / 7), 42px) !important;
        max-height: clamp(28px, calc((100vw - 60px) / 7), 42px) !important;
        flex-shrink: 0 !important; /* 防止收缩 */
    }
    
    .number-img {
        width: 100%;
        height: 100%;
        max-width: 100%;
        max-height: 100%;
        /* 兼容性：IE不支持object-fit */
        -o-object-fit: contain;
        object-fit: contain;
    }
    
    .number-zodiac {
        font-size: 11px;
    }
    
    .number-ball-wrapper {
        gap: 3px;
        flex-shrink: 0;
    }
    
    .number-separator {
        font-size: 18px;
        margin: 0 2px;
    }
    
    /* 对于更小的屏幕（小于360px），进一步缩小 */
    @media (max-width: 360px) {
        .latest-draw-content {
            padding: 0 5px;
        }
        
        .announcement-numbers {
            padding: 0 5px !important;
            gap: 2px !important;
        }
        
        .numbers {
            gap: 2px !important;
        }
        
        .number-ball {
            width: clamp(26px, calc((100vw - 50px) / 7), 36px) !important;
            height: clamp(26px, calc((100vw - 50px) / 7), 36px) !important;
            min-width: clamp(26px, calc((100vw - 50px) / 7), 36px) !important;
            min-height: clamp(26px, calc((100vw - 50px) / 7), 36px) !important;
            max-width: clamp(26px, calc((100vw - 50px) / 7), 36px) !important;
            max-height: clamp(26px, calc((100vw - 50px) / 7), 36px) !important;
        }
        
        .number-zodiac {
            font-size: 10px;
        }
        
        .number-separator {
            font-size: 14px;
            margin: 0 1px;
        }
        
        .latest-numbers {
            gap: 3px;
            padding: 10px 2px;
        }
        
        .numbers {
            gap: 3px;
        }
    }
    
    /* 对于中等屏幕（360px-480px），优化尺寸 */
    @media (min-width: 361px) and (max-width: 480px) {
        .announcement-numbers {
            padding: 0 6px !important;
            gap: 3px !important;
        }
        
        .numbers {
            gap: 3px !important;
        }
        
        .number-ball {
            width: clamp(30px, calc((100vw - 55px) / 7), 42px) !important;
            height: clamp(30px, calc((100vw - 55px) / 7), 42px) !important;
            min-width: clamp(30px, calc((100vw - 55px) / 7), 42px) !important;
            min-height: clamp(30px, calc((100vw - 55px) / 7), 42px) !important;
            max-width: clamp(30px, calc((100vw - 55px) / 7), 42px) !important;
            max-height: clamp(30px, calc((100vw - 55px) / 7), 42px) !important;
        }
    }
    
    .announcement-item {
        -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
        -ms-flex-direction: column;
        flex-direction: column;
    }
    
    .replay-button {
        margin-left: 0;
        margin-top: 15px;
        width: 100%;
        text-align: center;
    }
    
    .footer-top {
        -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
        -ms-flex-direction: column;
        flex-direction: column;
        -webkit-box-align: start;
        -ms-flex-align: start;
        align-items: flex-start;
        text-align: center;
    }
    
    .footer-logo {
        height: 100px !important;
        max-height: 100px !important;
    }
    
    .footer-info-section {
        width: 100%;
        text-align: center;
    }
    
    .video-grid {
        grid-template-columns: 1fr;
    }
    
    /* bg2.png占据整个(A)+(B)+(C)+(D)+(E)区域 - 手机版 */
    /* 添加背景色#1065E4 */
    .main-header-wrapper {
        background-image: url('../img/bg2.png') !important;
        background-color: #1065E4 !important; /* 添加背景色 */
        background-repeat: no-repeat !important;
        background-size: 100% auto !important;
        background-position: center top !important;
        position: relative;
        z-index: 1;
    }
    
    /* 去掉bg1.png，使用bg.png背景（由main-header-wrapper提供） */
    .latest-draw-section {
        position: relative;
        padding-bottom: 42px;
        z-index: 2;
    }
    
    /* 实时开奖区域背景 - 手机版 - 恢复白色透明背景 */
    .demo-section {
        background: rgba(255, 255, 255, 0.6) !important; /* 白色60%透明底背景 */
        position: relative;
        z-index: 2;
    }
}

/* API错误提示样式 */
.api-error {
    color: #d32f2f;
    padding: 15px;
    background: #ffebee;
    border-left: 4px solid #d32f2f;
    border-radius: 4px;
    margin: 10px 0;
}

/* API视频播放器样式 */
#api-video-player {
    margin: 20px 0;
}

#live-video-player {
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* 响应式设计 - 电脑版 */
@media (min-width: 769px) {
    .mobile-nav {
        display: none !important;
    }
    
    .header-nav {
        display: flex !important;
    }
    
    /* 确保Logo和导航菜单在背景图之上 */
    .logo-section,
    .header-nav {
        position: relative;
        z-index: 1;
    }
    
    .header-top-section {
        background-image: none !important;
    }
    
    
    /* bg.png占据整个(A)+(B)+(C)+(D)+(E)区域 */
    /* 电脑版不需要添加背景色，保持原样 */
    .main-header-wrapper {
        background-image: url('../img/bg.png') !important;
        background-repeat: no-repeat !important;
        background-size: 100% auto !important;
        background-position: center top !important;
        position: relative;
        z-index: 1;
    }
    
    /* 去掉bg1.png，使用bg.png背景（由main-header-wrapper提供） */
    .latest-draw-section {
        position: relative;
        padding-bottom: 42px;
        z-index: 2;
    }
    
    /* 实时开奖区域背景 - 电脑版 - 去掉bg1.png，使用白色60%透明底背景 */
    .demo-section {
        background: rgba(255, 255, 255, 0.6); /* 白色60%透明底背景 */
        position: relative;
        z-index: 2;
    }
    
    /* 倒计时区域右对齐，与时间区域对齐 */
    .countdown-content {
        justify-content: flex-end !important;
    }
    
    .countdown-wrapper {
        text-align: right !important;
    }
}
