/* 龙腾联盟 全能网页版 - 手机自适应增强 UI */
:root {
    --bg-color: #050a1a;
    --card-bg: #0d152b;
    --accent-gold: #f3c623;
    --accent-cyan: #00d2ff;
    --text-main: #e0e6ed;
    --text-dim: #94a3b8;
    --win-green: #10b981;
    --lose-red: #ef4444;
}

* {
    margin: 0; padding: 0; box-sizing: border-box;
    font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: var(--bg-color);
    color: var(--text-main);
    min-height: 100vh;
    padding: 15px;
    line-height: 1.5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
}

/* 主内容区域 */
.main-content {
    width: 100%;
}

/* 左侧图片 */
.left-image {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.left-image img {
    width: 100px;
    height: auto;
    filter: drop-shadow(0 0 10px rgba(243, 198, 35, 0.5));
    max-width: 100%;
    object-fit: contain;
}

/* 顶部导航与 Logo */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    flex-wrap: wrap;
    gap: 15px;
    position: relative;
    z-index: 2;
}

.logo {
    font-size: 22px;
    font-weight: 800;
    background: linear-gradient(to right, var(--accent-gold), var(--accent-cyan));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-controls {
    display: flex; 
    gap: 10px;
    flex-wrap: wrap;
}

.nav-select-group {
    display: flex;
    align-items: center;
    gap: 5px;
}

.nav-label {
    font-size: 13px;
    color: var(--text-dim);
    white-space: nowrap;
}

.nav-select {
    background: #1e293b;
    color: var(--text-main);
    border: 1px solid rgba(255,255,255,0.1);
    padding: 6px 10px;
    border-radius: 6px;
    outline: none;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.3s;
}

/* 游戏信息显示 */
.game-name {
    font-size: 24px;
    font-weight: bold;
    color: #9e6118;
    /*text-shadow: 0 0 10px rgba(24, 125, 141, 0.5);*/
    display: inline-block;
}

.game-icon {
    width: 80px;
    height: 70px;
    margin-right: 15px;
    vertical-align: middle;
    filter: drop-shadow(0 0 5px rgba(243, 198, 35, 0.5));
}

.top-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.game-name-with-icon {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-right: 15px;
    height: 100%;
}

.draw-numbers {
    display: flex; 
    gap: 6px;
    align-items: center;
}

/* 官网按钮样式 */
.official-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    background: linear-gradient(135deg, rgba(243, 198, 35, 0.1), rgba(243, 198, 35, 0.05));
    color: #ffffff;
    border: 1px solid #ffffff;
    padding: 6px 15px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 700;
    transition: all 0.3s;
    white-space: nowrap;
}

.official-btn:hover {
    background: #7f0000;
    color: #ffffff;
    box-shadow: 0 0 15px rgba(243, 198, 35, 0.3);
}

/* 主面板布局 */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 20px;
}

.card {
    background: rgba(255,255,255,0.1);
    
    /*background: var(--card-bg);*/
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    border: 1px solid rgba(255,255,255,0.05);
}

.card-title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--accent-gold);
    display: flex;
    align-items: center;
    gap: 8px;
}

/* 开奖信息看板 */
.draw-banner {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: stretch;
    margin-bottom: 20px;
    background: url('../img/1.png') no-repeat center center;
    background-size: cover;
    position: relative;
    z-index: 2;
    padding: 20px;
    min-height: 100px;
}

.draw-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
   
    z-index: 1;
}

.draw-banner > * {
    position: relative;
    z-index: 2;
}

.info-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 15px 0;
}



.info-line {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-top: 5px;
    padding-top: 5px;
    border-top: 2px solid rgba(255,255,255,0.1);
}

.period-info {
    text-align: left;
    margin: 0;
    width: 45%;
}

.period-info .label { color: #000000; font-size: 13px; }
.period-info .val { font-size: 24px; font-weight: 800; color: #9e6118;padding-top: 5px; /* 设置元素内部上边距为20像素 */
padding-bottom: 5px; /* 设置元素内部下边距为20像素 */}

.draw-numbers {
    display: flex; 
    gap: 6px;
    align-items: center;
    
}

.num-ball {
    width: 40px; height: 40px;
    background: linear-gradient(135deg, #334155, #0f172a);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 18px; font-weight: 800; color: #ffffff;
    border: 2px solid rgba(243, 198, 35, 0.3);
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    transition: all 0.5s;
    animation: ballPop 0.5s ease-out forwards;
}

/* 当前期号与倒计时部分 */
.current-period-section {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    margin: 0;
    width: 45%;
}

.combined-info {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 20px;
}

.next-period {
    text-align: left;
}

.period-text {
    display: block;
    font-size: 14px;
    color: #000000;
    margin-bottom: 5px;
}

.next-period-number {
    font-size: 24px;
    font-weight: 800;
    color: #9e6118;
}

.countdown {
    text-align: left;
}

.countdown-label {
    display: block;
    font-size: 14px;
    color: #000000;
    margin-bottom: 5px;
}

.countdown-timer {
    font-size: 24px;
    font-weight: 900;
    color: #9e6118;
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
    text-shadow: 1px 1px 0 rgba(0,0,0,0.3);
}

@keyframes ballPop {
    0% { transform: scale(0) rotate(-180deg); opacity: 0; }
    100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

/* 开奖结果显示 */
.current-draw {
    text-align: center;
    margin: 20px 0;
}

.current-period-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--accent-gold);
    margin-bottom: 10px;
}

.num-ball.new {
    border-color: #ffffff;
    box-shadow: 0 0 12px #000000;
}

/* 预测显示 */
.prediction-area {
    text-align: center;
    padding: 15px 0;
}

.target-val { font-size: 28px; font-weight: 800; margin: 8px 0; }

.prediction-box {
    background: rgba(0, 210, 255, 0.08);
    border: 2px dashed var(--accent-cyan);
    padding: 15px;
    border-radius: 10px;
    margin: 15px 0;
}

.pred-nums {
    font-size: 42px;
    letter-spacing: 8px;
    font-weight: 900;
    color: var(--accent-gold);
    text-shadow: 0 0 15px rgba(243, 198, 35, 0.4);
}

/* 统计卡片 */
.stat-row {
    display: flex; justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    font-size: 14px;
}

.win-tag { color: var(--win-green); font-weight: 800; }
.lose-tag { color: var(--lose-red); font-weight: 800; }

/* 概率表格 */
.prob-table { width: 100%; margin-top: 15px; }
.prob-row { display: flex; align-items: center; margin-bottom: 10px; gap: 10px; }
.prob-name { width: 45px; font-size: 13px; font-weight: 700; }
.prob-bar-bg { flex-grow: 1; height: 8px; background: #1e293b; border-radius: 4px; overflow: hidden; }
.prob-bar-fill { height: 100%; background: linear-gradient(to right, var(--accent-cyan), var(--win-green)); transition: width 1s; }
.prob-val { width: 55px; text-align: right; font-size: 12px; color: var(--accent-gold); }

/* 历史记录样式 */
.history-container {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.history-item {
    display: grid;
    /* 电脑端采用弹性比例，拉开间距 */
    grid-template-columns: 1.8fr 1.5fr 1.2fr 1.5fr 1.2fr;
    padding: 15px 10px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    font-size: 14px;
    align-items: center;
}

.history-header {
    background: rgba(255,255,255,0.02);
    font-weight: 700;
    color: var(--accent-gold);
}

.history-item div { white-space: nowrap; text-align: center; }
.pred-tag { color: var(--accent-gold); font-weight: 700; }

.smart-tip {
    margin-top: 15px; padding: 12px;
    background: rgba(243, 198, 35, 0.05);
    border-left: 4px solid var(--accent-gold);
    font-size: 13px;
}

/* --- 手机端适配关键媒体查询 --- */
@media (max-width: 768px) {
    body { padding: 10px; }
    
    .main-content {
        width: 100%;
        padding: 0;
    }
    
    header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .nav-controls {
        width: 100%;
        flex-direction: column;
        gap: 10px;
    }
    
    .nav-select-group {
        width: 100%;
        justify-content: space-between;
    }
    
    .nav-select {
        flex-grow: 1;
        max-width: 70%;
    }

    .official-btn {
        width: 100%;
        justify-content: center;
        margin-top: 5px;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .draw-banner {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    /* 移动端样式，不影响桌面端 */
    .info-line {
        flex-direction: column;
        gap: 5px;
        align-items: flex-start;
        text-align: left;
    }
    
    .period-info {
        width: 100%;
    }
    
    .current-period-section {
        width: 100%;
        justify-content: flex-start;
    }
    
    .combined-info {
        align-items: flex-start;
        gap: 5px;
    }
    
    .top-section {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
    
    .current-period-section {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
        text-align: left;
    }
    
    .combined-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .next-period {
        text-align: left;
    }
    
    .countdown {
        text-align: left;
    }
    
    .game-name-with-icon {
        flex-direction: row;
        align-items: center;
        margin-right: 0;
        margin-bottom: 10px;
    }
    
    .game-icon {
        width: 40px;
        height: 40px;
        margin-right: 10px;
        margin-bottom: 0;
    }
    
    .period-info {
        text-align: left;
        margin-right: 0;
        margin-bottom: 0;
    }
    
    .draw-numbers {
        justify-content: center;
        width: 100%;
    }

    .pred-nums {
        font-size: 32px;
        letter-spacing: 5px;
    }

    .num-ball {
        width: 36px; height: 36px;
        font-size: 16px;
    }

    /* 手机端保持固定宽度以支持横向滚动 */
    .history-item {
        grid-template-columns: 130px 100px 80px 110px 90px;
        font-size: 12px;
        min-width: 510px;
    }
}

@keyframes blink {
    0% { opacity: 1; }
    50% { opacity: 0.4; }
    100% { opacity: 1; }
}
