/* 重置样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', '微软雅黑', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 头部样式 */
.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1rem 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.8rem;
    font-weight: bold;
}

.nav ul {
    display: flex;
    list-style: none;
}

.nav ul li {
    margin-left: 2rem;
}

.nav ul li a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.nav ul li a:hover {
    color: #f0f0f0;
}

/* 主要内容区域 */
main {
    margin-top: 80px;
}

/* 英雄区域 */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 4rem 0;
    text-align: center;
}

.hero h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-top: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1rem;
    opacity: 0.8;
}

/* 预测区域 */
.prediction-section {
    padding: 4rem 0;
    background: white;
}

.prediction-section h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
    color: #333;
}

.prediction-container {
    background: #f8f9fa;
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.current-period {
    text-align: center;
    margin-bottom: 2rem;
}

.current-period h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.countdown {
    font-size: 1.2rem;
    font-weight: bold;
    color: #e74c3c;
}

.prediction-results h3 {
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.number-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 1rem;
    max-width: 600px;
    margin: 0 auto;
}

.number-item {
    background: white;
    border: 2px solid #ddd;
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    transition: all 0.3s;
}

.number-item.predicted {
    border-color: #e74c3c;
    background: #ffeaea;
    transform: scale(1.05);
}

.number-item:hover {
    border-color: #667eea;
    transform: translateY(-2px);
}

.number {
    display: block;
    font-size: 1.8rem;
    font-weight: bold;
    color: #333;
}

.probability {
    display: block;
    font-size: 0.9rem;
    color: #666;
    margin-top: 0.5rem;
}

/* 历史数据区域 */
.history-section {
    padding: 4rem 0;
    background: #f8f9fa;
}

.history-section h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
}

.history-table {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

th, td {
    padding: 1rem;
    text-align: center;
    border-bottom: 1px solid #ddd;
}

th {
    background: #667eea;
    color: white;
    font-weight: 600;
}

tr:hover {
    background: #f5f5f5;
}

/* 分析区域 */
.analysis-section {
    padding: 4rem 0;
    background: white;
}

.analysis-section h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
}

.analysis-content {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.chart-container {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    text-align: center;
    position: relative;
    height: 400px;
    width: 100%;
}

.chart-container canvas {
    width: 100% !important;
    height: 100% !important;
}

.statistics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin: 1rem 0;
}

.stat-card {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.stat-card h3 {
    margin-bottom: 1rem;
    color: #333;
    text-align: center;
}

.stat-table {
    width: 100%;
    border-collapse: collapse;
}

.stat-table th,
.stat-table td {
    padding: 0.75rem;
    text-align: center;
    border-bottom: 1px solid #ddd;
}

.stat-table th {
    background: #667eea;
    color: white;
    font-weight: 600;
}

.hot-cold-analysis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin: 1rem 0;
}

.hot-numbers,
.cold-numbers {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.hot-numbers h3,
.cold-numbers h3 {
    margin-bottom: 1rem;
    color: #333;
    text-align: center;
}

.number-list {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin: 1rem 0;
    flex-wrap: wrap;
}

.hot-number,
.cold-number {
    display: inline-block;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: bold;
    color: white;
}

.hot-number {
    background: #e74c3c;
}

.cold-number {
    background: #3498db;
}

.trend-analysis {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    margin: 1rem 0;
}

.trend-analysis h3 {
    margin-bottom: 1rem;
    color: #333;
    text-align: center;
}

.trend-points {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.trend-item {
    background: white;
    padding: 1rem;
    border-radius: 6px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.trend-item h4 {
    margin-bottom: 0.5rem;
    color: #667eea;
}

.analysis-text {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.analysis-text h3 {
    margin-bottom: 1rem;
    color: #333;
}

.analysis-text ul {
    list-style-position: inside;
}

.analysis-text li {
    margin-bottom: 0.5rem;
    padding-left: 1rem;
}

/* 关于区域 */
.about-section {
    padding: 4rem 0;
    background: #f8f9fa;
}

.about-section h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
}

.about-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.about-content p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    line-height: 1.8;
}

.features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.feature {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    text-align: center;
}

.feature h3 {
    margin-bottom: 1rem;
    color: #667eea;
}

/* 页脚 */
.footer {
    background: #333;
    color: white;
    padding: 3rem 0 1rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section ul li a:hover {
    color: white;
}

.copyright {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid #555;
    color: #ccc;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        text-align: center;
    }
    
    .nav ul {
        margin-top: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .nav ul li {
        margin: 0.5rem;
    }
    
    .stats {
        flex-direction: column;
        gap: 1rem;
    }
    
    .analysis-content {
        grid-template-columns: 1fr;
    }
    
    .number-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .features {
        grid-template-columns: 1fr;
    }
    
    main {
        margin-top: 120px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 10px;
    }
    
    .hero h2 {
        font-size: 2rem;
    }
    
    .number-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .prediction-container {
        padding: 1rem;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 使用指南区域 */
.guide-section {
    padding: 4rem 0;
    background: white;
}

.guide-section h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
    color: #333;
}

.guide-content {
    max-width: 1000px;
    margin: 0 auto;
}

.guide-item {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.guide-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.15);
}

.guide-item h3 {
    color: #667eea;
    margin-bottom: 1rem;
    font-size: 1.3rem;
    border-bottom: 2px solid #667eea;
    padding-bottom: 0.5rem;
}

.guide-item p {
    line-height: 1.7;
    color: #555;
    font-size: 1rem;
}

/* 响应式设计 - 使用指南 */
@media (max-width: 768px) {
    .guide-item {
        padding: 1.5rem;
        margin-bottom: 1rem;
    }
    
    .guide-item h3 {
        font-size: 1.2rem;
    }
    
    .guide-item p {
        font-size: 0.95rem;
    }
}

/* 弹窗样式 */
.modal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s ease-out;
}

.modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
    animation: slideIn 0.3s ease-out;
}

.modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1.5rem;
    border-radius: 12px 12px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
}

.close-btn {
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
    transition: color 0.3s;
}

.close-btn:hover {
    color: #ff6b6b;
}

.modal-body {
    padding: 2rem;
}

.modal-body p {
    margin: 1rem 0;
    font-size: 1.1rem;
    line-height: 1.6;
    color: #333;
    display: flex;
    align-items: center;
}

.modal-body p:before {
    content: "";
    display: inline-block;
    width: 24px;
    height: 24px;
    margin-right: 10px;
    font-size: 1.2rem;
}

.modal-footer {
    padding: 1.5rem 2rem 2rem;
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

.modal-btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    min-width: 120px;
}

.modal-btn.confirm {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.modal-btn.confirm:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.modal-btn.secondary {
    background: #f8f9fa;
    color: #666;
    border: 1px solid #ddd;
}

.modal-btn.secondary:hover {
    background: #e9ecef;
    transform: translateY(-1px);
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translate(-50%, -60%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

/* 响应式设计 - 弹窗 */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        max-width: 400px;
    }
    
    .modal-header {
        padding: 1rem;
    }
    
    .modal-header h3 {
        font-size: 1.3rem;
    }
    
    .modal-body {
        padding: 1.5rem;
    }
    
    .modal-body p {
        font-size: 1rem;
    }
    
    .modal-footer {
        padding: 1rem 1.5rem 1.5rem;
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .modal-btn {
        width: 100%;
        min-width: auto;
    }
}

/* 防诈宣传区域 */
.anti-fraud-section {
    padding: 4rem 0;
    background: #f8f9fa;
}

.anti-fraud-section h2 {
    text-align: center;
    margin-bottom: 2rem;
    font-size: 2rem;
    color: #333;
}

.anti-fraud-content {
    max-width: 1000px;
    margin: 0 auto;
}

.warning-box {
    background: #fff3cd;
    border: 2px solid #ffc107;
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 2rem;
    text-align: center;
}

.warning-box h3 {
    color: #856404;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.warning-box p {
    color: #856404;
    font-size: 1.1rem;
    line-height: 1.6;
}

.fraud-types {
    margin-bottom: 2rem;
}

.fraud-types h3 {
    color: #dc3545;
    margin-bottom: 1.5rem;
    text-align: center;
    font-size: 1.5rem;
}

.fraud-item {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border-left: 4px solid #dc3545;
}

.fraud-item h4 {
    color: #dc3545;
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.fraud-item p {
    color: #555;
    line-height: 1.6;
}

.prevention-tips {
    background: white;
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    border-left: 4px solid #28a745;
}

.prevention-tips h3 {
    color: #28a745;
    margin-bottom: 1.5rem;
    text-align: center;
    font-size: 1.5rem;
}

.prevention-tips ul {
    list-style: none;
    padding-left: 0;
}

.prevention-tips li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #eee;
    position: relative;
    padding-left: 2rem;
}

.prevention-tips li:before {
    content: "✓";
    color: #28a745;
    font-weight: bold;
    position: absolute;
    left: 0;
}

.report-info {
    background: #d1ecf1;
    border: 2px solid #bee5eb;
    border-radius: 8px;
    padding: 2rem;
    text-align: center;
}

.report-info h3 {
    color: #0c5460;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.report-info p {
    color: #0c5460;
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.report-info strong {
    color: #dc3545;
    font-size: 1.2rem;
}

/* 响应式设计 - 防诈宣传 */
@media (max-width: 768px) {
    .warning-box,
    .fraud-item,
    .prevention-tips,
    .report-info {
        padding: 1.5rem;
    }
    
    .warning-box h3,
    .fraud-types h3,
    .prevention-tips h3,
    .report-info h3 {
        font-size: 1.3rem;
    }
    
    .fraud-item h4 {
        font-size: 1.1rem;
    }
}