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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    background: linear-gradient(135deg, #1a0033 0%, #330066 50%, #4d0099 100%);
    color: #fff;
    min-height: 100vh;
    overflow-x: hidden;
}

/* 容器 */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* 头部导航 */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    backdrop-filter: blur(10px);
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-icon {
    font-size: 2.5rem;
    animation: pulse 2s infinite;
}

.logo h1 {
    font-size: 1.8rem;
    font-weight: 700;
    background: linear-gradient(45deg, #ff6b6b, #ee5a24);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tagline {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

.nav {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-link {
    color: #fff;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    padding: 10px 20px;
    border-radius: 10px;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.nav-link .icon {
    font-size: 1.2rem;
}

/* 主要内容区域 */
.main-content {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 30px;
    align-items: start;
}

/* 左侧内容区域 */
.left-content {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* 游戏区域 */
.game-section {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    padding: 30px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.game-header {
    text-align: center;
    margin-bottom: 30px;
}

.game-header h2 {
    font-size: 2.2rem;
    margin-bottom: 10px;
    background: linear-gradient(45deg, #f39c12, #f1c40f);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.game-header p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.1rem;
}

/* 游戏容器 */
.game-container {
    background: #000;
    border-radius: 15px;
    padding: 20px;
    position: relative;
}

.score-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    font-size: 1.2rem;
}

#score {
    font-weight: bold;
    color: #f1c40f;
}

.sound-toggle {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #fff;
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.sound-toggle:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* 游戏iframe */
#gameFrame {
    width: 100%;
    height: 600px;
    background: #0a0a0a;
    border-radius: 10px;
    border: none;
    display: block;
}

/* 游戏控制按钮 */
.game-controls {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 20px;
}

.btn-primary, .btn-secondary {
    padding: 12px 30px;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(45deg, #e74c3c, #c0392b);
    color: #fff;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(231, 76, 60, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* 在线状态 */
.online-status {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.8);
}

.status-dot {
    width: 10px;
    height: 10px;
    background: #2ecc71;
    border-radius: 50%;
    animation: blink 2s infinite;
}

/* 故事介绍区域 */
.story-section {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    padding: 30px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.story-section h3 {
    font-size: 1.8rem;
    margin-bottom: 25px;
    text-align: center;
    background: linear-gradient(45deg, #e74c3c, #f39c12);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.story-content {
    max-width: 100%;
}

.story-header {
    text-align: center;
    margin-bottom: 25px;
}

.viral-badge {
    display: inline-block;
    background: linear-gradient(45deg, #ff4757, #ff6b6b);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 10px;
    animation: pulse 2s infinite;
}

.story-header h4 {
    font-size: 1.5rem;
    margin: 10px 0;
    color: #fff;
}

.date-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.1);
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
}

.story-text {
    line-height: 1.7;
}

.story-text p {
    margin-bottom: 18px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
}

.chris-quote {
    background: linear-gradient(45deg, #8e44ad, #9b59b6);
    border-left: 4px solid #f1c40f;
    padding: 20px;
    margin: 25px 0;
    border-radius: 0 10px 10px 0;
    font-style: italic;
    font-size: 1.1rem;
    color: #fff;
    position: relative;
}

.chris-quote::before {
    content: '"';
    font-size: 3rem;
    color: #f1c40f;
    position: absolute;
    top: -10px;
    left: 10px;
}

.viral-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin: 30px 0;
    padding: 25px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
}

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

.viral-stat .stat-number {
    display: block;
    font-size: 2rem;
    font-weight: 700;
    color: #f1c40f;
    margin-bottom: 5px;
}

.viral-stat .stat-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

.story-conclusion {
    background: rgba(46, 204, 113, 0.1);
    border: 1px solid rgba(46, 204, 113, 0.3);
    padding: 20px;
    border-radius: 15px;
    margin-top: 25px;
    font-weight: 500;
    color: #2ecc71 !important;
}

/* 统计信息区域 */
.stats-section {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    padding: 30px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.stats-section h3 {
    font-size: 1.5rem;
    margin-bottom: 25px;
    text-align: center;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-item:last-of-type {
    border-bottom: none;
}

.stat-item .stat-label {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
}

.stat-item .stat-value {
    font-size: 1.3rem;
    font-weight: 600;
}

.rating {
    color: #f1c40f;
}

/* 广告区域 */
.ad-section {
    background: linear-gradient(135deg, #8e44ad, #9b59b6);
    border-radius: 15px;
    padding: 25px;
    margin-top: 30px;
    text-align: center;
}

.ad-badge {
    background: rgba(0, 0, 0, 0.2);
    display: inline-block;
    padding: 8px 16px;
    border-radius: 20px;
    margin-bottom: 15px;
    font-size: 0.9rem;
}

.ad-section p {
    margin-bottom: 10px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.ad-chinese {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
}

.ad-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    text-decoration: none;
    padding: 12px 24px;
    border-radius: 10px;
    margin-top: 15px;
    transition: all 0.3s ease;
}

.ad-link:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateX(5px);
}

/* 动画 */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

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

/* 响应式设计 */
@media (max-width: 1024px) {
    .main-content {
        grid-template-columns: 1fr;
    }
    
    .stats-section {
        order: 2;
    }
}

@media (max-width: 768px) {
    .header {
        flex-direction: column;
        gap: 20px;
    }
    
    .nav {
        gap: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .game-header h2 {
        font-size: 1.8rem;
    }
    
    .game-controls {
        flex-direction: column;
    }
    
    .btn-primary, .btn-secondary {
        width: 100%;
    }
    
    /* 移动设备上的iframe适应 */
    #gameFrame {
        height: 400px;
    }
    
    /* 移动设备上的故事统计 */
    .viral-stats {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .story-header h4 {
        font-size: 1.2rem;
    }
    
    .chris-quote {
        padding: 15px;
        font-size: 1rem;
    }
}