/* 游戏大厅样式 - 优化版 */

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

body {
    font-family: 'Microsoft YaHei', '微软雅黑', Arial, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    color: #333;
    line-height: 1.6;
    min-height: 100vh;
    padding: 20px;
}

/* 游戏大厅容器 */
.lobby-container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    padding: 30px;
}

/* 页头样式 */
header {
    text-align: center;
    padding: 20px 0 40px;
    position: relative;
}

header h1 {
    font-size: 3rem;
    margin-bottom: 0.5rem;
    color: #2c3e50;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

header p {
    font-size: 1.2rem;
    color: #7f8c8d;
    margin-bottom: 1rem;
}

.auth-section {
    margin-bottom: 2rem;
}

.login-btn {
    display: inline-block;
    padding: 10px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.login-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

#user-info {
    color: #2c3e50;
    font-weight: 500;
}

#user-email {
    color: #667eea;
    font-weight: 600;
}

.logout-btn {
    margin-left: 10px;
    padding: 5px 15px;
    background: #e74c3c;
    color: white;
    border: none;
    border-radius: 15px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.logout-btn:hover {
    background: #c0392b;
    transform: translateY(-1px);
}

/* 游戏卡片网格 */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

/* 游戏卡片样式 */
.game-card {
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
    border: 1px solid #eaeaea;
}

.game-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

/* 游戏图标 */
.game-icon {
    padding: 25px 0;
    text-align: center;
    background-color: #f8f9fa;
    border-bottom: 1px solid #eaeaea;
}

.placeholder-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    font-size: 2.5rem;
    font-weight: bold;
    color: white;
}

/* 各游戏图标颜色 */
.mario-icon {
    background-color: #e74c3c;
}

.chess-icon {
    background-color: #3498db;
}

.math-icon {
    background-color: #2ecc71;
}

.thief-icon {
    background-color: #9b59b6;
}

.checkers-icon {
    background-color: #f39c12;
}

.laser-icon {
    background-color: #8e44ad;
    box-shadow: 0 0 10px #8e44ad;
}

.notes-icon {
    background-color: #27ae60;
    box-shadow: 0 0 10px rgba(39, 174, 96, 0.5);
}

.pharaoh-icon {
    background: linear-gradient(135deg, #FFD700 0%, #FFA500 100%);
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.6);
    border: 2px solid #CD7F32;
}

/* 游戏信息 */
.game-info {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.game-info h2 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: #2c3e50;
}

.game-info p {
    color: #7f8c8d;
    margin-bottom: 20px;
    flex-grow: 1;
}

/* 开始游戏按钮 */
.play-button {
    display: inline-block;
    background-color: #3498db;
    color: white;
    padding: 10px 20px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: bold;
    text-align: center;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(50, 50, 93, 0.11), 0 1px 3px rgba(0, 0, 0, 0.08);
}

.play-button:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 7px 14px rgba(50, 50, 93, 0.1), 0 3px 6px rgba(0, 0, 0, 0.08);
}

/* 页脚样式 */
footer {
    text-align: center;
    padding: 20px 0 10px;
    color: #95a5a6;
    font-size: 0.9rem;
    border-top: 1px solid #eaeaea;
    margin-top: 20px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .lobby-container {
        padding: 15px;
    }
    
    header {
        padding: 15px 0 25px;
    }
    
    header h1 {
        font-size: 2.2rem;
    }
    
    .games-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .game-info h2 {
        font-size: 1.3rem;
    }
}

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

.game-card {
    animation: fadeIn 0.5s ease-out forwards;
}

.game-card:nth-child(1) { animation-delay: 0.1s; }
.game-card:nth-child(2) { animation-delay: 0.2s; }
.game-card:nth-child(3) { animation-delay: 0.3s; }
.game-card:nth-child(4) { animation-delay: 0.4s; }