/* 游戏卡片样式 */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 10px;
    max-width: 100%;
    margin: 0 auto;
}

.game-card {
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 5px;
    overflow: hidden;
    transition: transform 0.3s;
    position: relative;
    width: 100%;
    max-width: 100%;
}

.game-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.game-card-image {
    height: 180px;
    position: relative;
}

.game-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.game-card-tag {
    position: absolute;
    top: 5px;
    right: 5px;
    background-color: rgba(255, 204, 0, 0.9);
    color: #0a5e81;
    font-size: 10px;
    font-weight: bold;
    padding: 2px 5px;
    border-radius: 3px;
}

.game-card-title {
    padding: 8px;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 推荐游戏卡片 */
.recommended-game-card {
    flex: 0 0 300px;
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 5px;
    overflow: hidden;
}

.recommended-game-image {
    height: 200px;
}

.recommended-game-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.recommended-game-title {
    padding: 8px;
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.game-card a {
    display: block;
    color: inherit;
    text-decoration: none;
}


/* 移动端适配 */
@media (max-width: 767px) {
    .games-grid {
        grid-template-columns: repeat(2, minmax(100px, 1fr));
        gap: 8px;
        padding: 0;
        width: 100%;
        box-sizing: border-box;
    }

    .game-card-image {
        height: 100px;
    }

    .game-card-title {
        padding: 6px;
        font-size: 12px;
    }

    .recommended-game-card {
        flex: 0 0 200px;
        width: 85%;
        min-width: 100px;
    }

    .recommended-game-image {
        height: 140px;
    }

    .recommended-game-title {
        padding: 6px;
        font-size: 11px;
    }
}