/* 情侣游戏样式 */
.game-card {
    margin-bottom: 30px;
    padding: 15px;
}

.game-content {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 20px;
    padding: 40px 30px;
    text-align: center;
    color: white;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.game-content::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: rotate(45deg);
    transition: all 0.6s ease;
    opacity: 0;
}

.game-content:hover::before {
    opacity: 1;
    transform: rotate(45deg) translate(50%, 50%);
}

.game-content:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.game-icon {
    font-size: 60px;
    margin-bottom: 20px;
    color: rgba(255, 255, 255, 0.9);
}

.game-content h3 {
    font-size: 24px;
    margin-bottom: 15px;
    font-weight: 600;
}

.game-content p {
    font-size: 16px;
    margin-bottom: 25px;
    opacity: 0.9;
    line-height: 1.5;
}

.game-btn {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 12px 30px;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.game-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
    transform: scale(1.05);
}

/* 不同游戏卡片的渐变色 */
.game-card:nth-child(1) .game-content {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
}

.game-card:nth-child(2) .game-content {
    background: linear-gradient(135deg, #4834d4 0%, #686de0 100%);
}

.game-card:nth-child(3) .game-content {
    background: linear-gradient(135deg, #ff9ff3 0%, #f368e0 100%);
}

.game-card:nth-child(4) .game-content {
    background: linear-gradient(135deg, #54a0ff 0%, #2e86de 100%);
}

/* 游戏模态框 */
.game-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.game-modal-content {
    background-color: #fefefe;
    margin: 2% auto;
    padding: 20px;
    border-radius: 15px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.game-close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 20px;
    top: 15px;
    z-index: 1001;
}

.game-close:hover {
    color: #000;
}

/* 排行榜样式 */
.leaderboard {
    margin-top: 20px;
}

.game-leaderboard {
    margin-bottom: 30px;
}

.game-leaderboard h4 {
    color: #667eea;
    margin-bottom: 15px;
    font-size: 18px;
    font-weight: 600;
}

.score-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 10px;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.score-item:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.player-name {
    font-weight: 600;
    color: #495057;
}

.score {
    color: #667eea;
    font-weight: 600;
}

.play-count {
    color: #6c757d;
    font-size: 14px;
}

/* 每日问答样式 */
.daily-question {
    text-align: center;
    padding: 30px;
}

.question-text {
    font-size: 20px;
    color: #495057;
    margin-bottom: 30px;
    line-height: 1.6;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 15px;
    border-left: 5px solid #667eea;
}

.answer-section {
    margin-bottom: 25px;
}

.answer-section h4 {
    color: #667eea;
    margin-bottom: 15px;
}

.answer-input {
    width: 100%;
    padding: 15px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-size: 16px;
    resize: vertical;
    min-height: 100px;
    transition: border-color 0.3s ease;
}

.answer-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.submit-answer {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 10px;
}

.submit-answer:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.3);
}

/* 记忆游戏样式 */
.memory-game {
    text-align: center;
    padding: 20px;
}

.game-info {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 10px;
}

.memory-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    max-width: 400px;
    margin: 0 auto;
}

.memory-card {
    aspect-ratio: 1;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: white;
    transition: all 0.3s ease;
    user-select: none;
}

.memory-card:hover {
    transform: scale(1.05);
}

.memory-card.flipped {
    background: white;
    color: #667eea;
    border: 2px solid #667eea;
}

.memory-card.matched {
    background: linear-gradient(135deg, #00d2d3 0%, #54a0ff 100%);
    cursor: default;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .game-content {
        padding: 30px 20px;
    }
    
    .game-icon {
        font-size: 50px;
    }
    
    .game-content h3 {
        font-size: 20px;
    }
    
    .memory-grid {
        grid-template-columns: repeat(3, 1fr);
        max-width: 300px;
    }
    
    .game-modal-content {
        width: 95%;
        margin: 5% auto;
        padding: 15px;
    }
    
    .score-item {
        flex-direction: column;
        text-align: center;
        gap: 5px;
    }
}

/* 动画效果 */
@keyframes cardFlip {
    0% { transform: rotateY(0deg); }
    50% { transform: rotateY(90deg); }
    100% { transform: rotateY(0deg); }
}

.memory-card.flipping {
    animation: cardFlip 0.6s ease-in-out;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.game-btn:active {
    animation: pulse 0.3s ease-in-out;
}

/* 爱情测试样式 */
.love-quiz {
    text-align: center;
    padding: 30px;
}

.quiz-progress {
    margin-bottom: 30px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transition: width 0.3s ease;
}

.progress-text {
    color: #6c757d;
    font-size: 14px;
}

.quiz-options {
    display: grid;
    gap: 15px;
    margin-top: 30px;
}

.quiz-option {
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px solid transparent;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
    line-height: 1.5;
}

.quiz-option:hover {
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.1);
}

.quiz-result {
    padding: 30px;
    text-align: center;
}

.result-score {
    font-size: 48px;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 20px;
}

.result-title {
    font-size: 28px;
    font-weight: 600;
    color: #495057;
    margin-bottom: 15px;
}

.result-description {
    font-size: 18px;
    color: #6c757d;
    line-height: 1.6;
    margin-bottom: 30px;
}

/* 现有回答样式 */
.existing-answer {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    border: 2px solid #2196f3;
    border-radius: 10px;
    padding: 20px;
    margin-bottom: 15px;
    font-size: 16px;
    line-height: 1.6;
    color: #1565c0;
    text-align: left;
}

/* 加载和错误状态 */
.loading, .error {
    text-align: center;
    padding: 40px;
    font-size: 18px;
}

.loading {
    color: #667eea;
}

.error {
    color: #dc3545;
}

/* 拼图游戏特定样式 */
.puzzle-game {
    text-align: center;
    padding: 20px;
}

.puzzle-tile {
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}
