/* ========================================
   SIMILAR GAMES SECTION - ONE ROW FIX
   ======================================== */

.similar-games {
    margin-top: 60px;
    margin-bottom: 40px;
}

.similar-games-heading {
    color: var(--white, #ffffff) !important;
    font-size: 36px !important;
    font-weight: 800 !important;
    text-align: center !important;
    margin-bottom: 40px !important;
    text-shadow:
        0 0 20px rgba(218, 31, 21, 0.6),
        3px 3px 10px rgba(0, 0, 0, 0.9) !important;
    position: relative;
    padding-bottom: 20px;
}

.similar-games-heading::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 4px;
    background: linear-gradient(90deg, transparent, #da1f15, transparent);
    box-shadow: 0 0 20px rgba(218, 31, 21, 0.8);
}

.similar-games-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    max-width: 1400px;
    margin: 0 auto;
}

/* Ensure only one row - limit to 6 games per row */
.similar-games-row .game-content {
    flex: 0 0 calc(16.666% - 20px);
    max-width: calc(16.666% - 20px);
}

@media (max-width: 1200px) {
    .similar-games-row .game-content {
        flex: 0 0 calc(20% - 20px);
        max-width: calc(20% - 20px);
    }
}

@media (max-width: 992px) {
    .similar-games-row .game-content {
        flex: 0 0 calc(25% - 20px);
        max-width: calc(25% - 20px);
    }
}

@media (max-width: 768px) {
    .similar-games-row .game-content {
        flex: 0 0 calc(33.333% - 20px);
        max-width: calc(33.333% - 20px);
    }
}

@media (max-width: 576px) {
    .similar-games-row .game-content {
        flex: 0 0 calc(50% - 20px);
        max-width: calc(50% - 20px);
    }
}

/* Fix game card icons */
.similar-games .game-content .content-image {
    width: 100% !important;
    height: auto !important;
    object-fit: contain !important;
    display: block !important;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    padding: 10px;
    transition: all 0.3s ease;
}

.similar-games .game-content:hover .content-image {
    transform: scale(1.05);
    box-shadow: 0 4px 20px rgba(218, 31, 21, 0.3);
}

/* Ensure broken images have fallback */
.similar-games .game-content .content-image[src=""],
.similar-games .game-content .content-image:not([src]) {
    background-image: url('/asset/frontend/img/logo/game.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

/* Game card hover effects */
.similar-games .game-content .content {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, rgba(26, 13, 92, 0.6) 0%, rgba(11, 0, 75, 0.8) 100%);
    border: 2px solid rgba(218, 31, 21, 0.2);
}

.similar-games .game-content .content:hover {
    border-color: rgba(218, 31, 21, 0.5);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
    transform: translateY(-5px);
}

.similar-games .game-content .content-details {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
    padding: 15px;
    text-align: center;
}

.similar-games .game-content .gameh5Span {
    color: var(--white, #ffffff) !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
    display: block;
}
