html, body {
    font-family: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", Arial, sans-serif;
    overflow-x: hidden;
    width: 100%;
    margin: 0;
    padding: 0;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    min-height: 100vh;
}

/* 重置 ul 元素的默认样式 */
ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: block;
}
.header {
    height: 60px;
    line-height: 60px;
    width: 100%;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border-bottom: 2px solid #e74c3c;
}

.header .grzx {
    width: 20%;
    height: 60px;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding-left: 15px;
}

.header .grzx::before {
    content: '';
    display: block;
    width: 25px;
    height: 25px;
    background: url(../icon/grzx.png) center center no-repeat;
}

.header h1 {
    width: 60%;
    font-size: 22px;
    font-weight: 600;
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    text-align: center;
    margin: 0;
    padding: 0;
    letter-spacing: 0.5px;
}

.header .more {
    width: 20%;
    height: 60px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding-right: 15px;
}

.header .more::before {
    content: '';
    display: block;
    width: 30px;
    height: 30px;
    background: url(../icon/lujing.png) center center no-repeat;
}
.lottery-nav {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    background: #ffffff;
    padding: 2px;
    gap: 2px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #e0e0e0;
}

.lottery-nav a {
    text-decoration: none;
    text-align: center;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 5px 2px;
    background: #ffffff;
    border-radius: 6px;
    transition: all 0.2s ease;
    border: 1px solid #e8e8e8;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.nav-item:hover {
    background: #f8f9fa;
    border-color: #e74c3c;
    box-shadow: 0 2px 6px rgba(231, 76, 60, 0.15);
}

.nav-item:hover a span {
    color: #e74c3c;
}

.nav-item a img {
    display: block;
    width: 30px;
    height: 30px;
    margin: 0 auto 5px auto;
}

.nav-item a span {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #2c3e50;
    text-align: center;
    transition: color 0.2s ease;
}

.lottery-tabs {
    border-radius: 8px;
    background: #ffffff;
    margin: 2px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #e0e0e0;
    overflow: hidden;
}

.tab-bar {
    display: flex;
    justify-content: space-between;
    width: 100%;
    background: #f8f9fa;
    border-bottom: 1px solid #e0e0e0;
}

.tab-button {
    flex: 1;
    min-width: 0;
    padding: 12px 4px;
    border: none;
    background-color: transparent;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: #666666;
    transition: all 0.2s ease;
    position: relative;
}

.tab-button.active {
    color: #e74c3c;
    background: #ffffff;
    border-bottom: 2px solid #e74c3c;
    font-weight: 600;
}

.tab-button:hover:not(.active) {
    color: #e74c3c;
    background: #f0f0f0;
}

.prediction-categories {
    display: flex;
    border-radius: 6px;
    background: #f8f9fa;
    align-items: center;
    flex-wrap: nowrap;
    padding: 2px 2px;
    overflow: hidden;
    position: relative;
    margin: 2px;
    border: 1px solid #e0e0e0;
}

.prediction-categories span {
    flex: 0 0 auto;
    padding: 6px 10px;
    font-size: 15px;
    font-weight: 500;
    color: #666666;
    margin: 0 3px;
    white-space: nowrap;
    border-radius: 4px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.prediction-categories span:hover {
    background: #e0e0e0;
    color: #e74c3c;
}


.prediction-categories span:last-child {
    background: #e74c3c;
    color: #fff;
    border-radius: 4px;
    padding: 6px 0;
    position: absolute;
    right: 0px;
    top: 50%;
    transform: translateY(-50%);
    flex: 0 0 auto;
    z-index: 1;
    font-weight: 600;
}

.prediction-categories span.active {
    color: #e74c3c;
    font-weight: 600;
}

.ranking-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: block;
}

.ranking-list li {
    display: flex;
    align-items: center;
    padding: 0.8px 10px;
    height: 40px;
    font-size: 15px;
    font-weight: bold;
    border-bottom: 1px solid #eee;
}

.ranking-list li:last-child {
    border-bottom: none;
}

.rank {
    font-size: 18px;
    font-weight: bold;
    margin-right: 2px;
    width: 30px;
    text-align: center;
}

.rank img {
    width: 24px;
    height: 24px;
    vertical-align: middle;
}

.avatar {
    width: 27px;
    height: 27px;
    background-color: #ccc;
    border-radius: 50%;
    margin-right: 10px;
    overflow: hidden;
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.name {
    flex-grow: 1;
    position: relative;
    min-width: 200px;
}

.name .prediction-link {
    position: absolute;
    right: 40px;
    color: #e4393c;
    text-decoration: none;
    padding: 1px 4px;
    background-color: #fff2f0;
    border-radius: 2px;
    border: 1px solid #ffccc7;
    transition: all 0.2s ease;
    font-weight: normal;
    font-size: 15px;
    display: inline-block;
}

.name .prediction-link:hover {
    background-color: #ffe7e6;
    border-color: #e4393c;
    text-decoration: none;
    color: #d32f2f;
}

.score {
    color: red;
    font-weight: bold;
}

.score_z {
    color: #000;
    font-size: 0.8em;
    margin-left: 2px;
}

.prediction-section {
    border-radius: 8px;
    background: #ffffff;
    margin: 2px;
    padding: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    border: 1px solid #e0e0e0;
}

.prediction-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #e74c3c;
    padding-bottom: 12px;
    margin-bottom: 16px;
}

.prediction-section h2 {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
    color: #2c3e50;
}

.prediction-section h2 img {
    width: 24px;
    height: 24px;
    margin-right: 5px;
}

.section-links {
    font-size: 14px;
}

.section-links a {
    text-decoration: none;
    color: #e74c3c;
    margin-left: 10px;
    font-weight: 500;
    padding: 6px 12px;
    border-radius: 4px;
    background: #f8f9fa;
    border: 1px solid #e0e0e0;
    transition: all 0.2s ease;
}

.section-links a:hover {
    background: #e74c3c;
    color: #ffffff;
    border-color: #e74c3c;
}

.prediction-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.prediction-list li {
    padding: 2px 5px;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.2s ease;
    position: relative;
}

.prediction-list li:hover {
    background: #f8f9fa;
}

.article-item {
    position: relative;
}

.article-content {
    padding: 2px 0;
}

.article-title {
    display: block;
    font-size: 16px;
    font-weight: 500;
    color: #2c3e50;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 6px;
    transition: color 0.2s ease;
    text-decoration: none;
}

.article-title:hover {
    color: #e74c3c;
}

.article-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    color: #666666;
}

.master-name {
    font-weight: 600;
    color: #e74c3c;
    text-decoration: none;
    padding: 2px 8px;
    border-radius: 4px;
    background: linear-gradient(135deg, #fff5f5, #ffe8e8);
    border: 1px solid #ffcccb;
    transition: all 0.2s ease;
    display: inline-block;
    position: relative;
    font-size: 12px;
}

.master-name:hover {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    color: #ffffff;
    border-color: #e74c3c;
    transform: translateY(-1px);
    box-shadow: 0 2px 6px rgba(231, 76, 60, 0.3);
    text-decoration: none;
}

.master-name:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(231, 76, 60, 0.4);
}

.publish-time {
    color: #999999;
}

.article-link:hover .article-title {
    color: #e74c3c;
}

/* 中奖标识样式 */
.winner-ribbon {
    position: absolute;
    top: 8px;
    right: 8px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: #ffffff;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: bold;
    z-index: 10;
    box-shadow: 0 2px 8px rgba(238, 90, 36, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.2s ease;
}

.winner-text {
    color: #ffffff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
    letter-spacing: 0.5px;
}

/* 悬停效果 */
.article-item:hover .winner-ribbon {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(238, 90, 36, 0.5);
}

.prediction-list li:last-child {
    border-bottom: none;
}


.more-link {
    text-align: center;
    padding-top: 10px;
}

.more-link a {
    text-decoration: none;
    color: #e74c3c;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0px;
    line-height: 22.99px;
    vertical-align: top;
    padding: 10px 20px;
    border-radius: 4px;
    background: #ffffff;
    border: 1px solid #e74c3c;
    display: inline-block;
    transition: all 0.2s ease;
}

.more-link a:hover {
    background: #e74c3c;
    color: #ffffff;
}

.user-link {
    color: #000 !important;
    text-decoration: none !important;
}

/* ===== 提示弹窗样式（居中略偏下，贴合站点风格） ===== */
.notice-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
}
.notice-modal.show {
    display: flex;
}
.notice-modal .notice-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
}
.notice-modal .notice-card {
    position: relative;
    width: 92vw;
    max-width: 520px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.18);
    overflow: hidden;
    z-index: 1;
    transform: translateY(6vh);
}
.notice-modal .notice-accent {
    height: 4px;
    background: #e74c3c;
}
.notice-modal .notice-header {
    padding: 14px 16px;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.notice-modal .notice-title {
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
}
.notice-modal .notice-close {
    position: absolute;
    right: 8px;
    top: 8px;
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    color: #999;
    font-size: 22px;
    line-height: 32px;
    cursor: pointer;
}
.notice-modal .notice-body {
    padding: 12px 16px;
    color: #666;
    font-size: 14px;
    line-height: 1.7;
}
.notice-modal .notice-body p {
    margin: 0 0 8px;
}
.notice-modal .notice-body p:last-child {
    margin-bottom: 0;
}
.notice-modal .notice-footer {
    padding: 10px 16px 16px;
}
.notice-modal .notice-confirm {
    width: 100%;
    padding: 10px 14px;
    background: #e74c3c;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: 0.5px;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(231, 76, 60, 0.25);
}

@media (max-width: 640px) {
    .notice-modal {
        padding: 16px;
    }
}

@media (min-width: 767px) {
    body {
        width: 80%;
        margin: 0 auto;
    }
    /* PC端让提示弹窗严格居中（移除向下偏移） */
    .notice-modal .notice-card {
        transform: none;
        width: 520px;
    }
    .prediction-grid {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 16px;
        margin: 8px;
    }
    .prediction-grid .prediction-section {
        margin: 0; 
    }
    .top_right{
        width: 65%;
    }
}

@media (max-width: 767px) {
    .firstt-container {
        display: block;
    }
    .top_left {
        display: none;
    }
    .top_right{
        float: none;
    }
}

/* 小屏手机适配，防止排行榜中的预测按钮溢出 */
@media (max-width: 480px) {
    .name {
        min-width: 0;
    }
    .name .prediction-link {
        position: absolute;
        right: 40px;
        max-width: 70%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        font-size: 12px;
        padding: 1px 4px;
    }
    /* 让右侧区域在小屏可左右滚动，避免文字省略 */
    .top_right {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .top_right .tab-bar {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        gap: 8px;
    }
    .top_right .tab-button {
        flex: 0 0 auto;
        overflow: visible;
        text-overflow: clip;
        white-space: nowrap;
    }
}
