/* ==========================================================================
   MAIN TWO-COLUMN LAYOUT - Modern Visual Upgrade
   Mobile: stacked
   Desktop (768px+): Game sidebar left + Config panel right
   Matches builder-layout styling for consistency
   ========================================================================== */

.fps-main-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(1.5rem, 3vw, 2rem);
    align-items: start;
}

@media (min-width: 768px) {
    .fps-main-layout {
        grid-template-columns: 260px 1fr;
    }
}

@media (min-width: 1024px) {
    .fps-main-layout {
        grid-template-columns: 300px 1fr;
    }
}

@media (min-width: 1200px) {
    .fps-main-layout {
        grid-template-columns: 320px 1fr;
    }
}

/* ==========================================================================
   LEFT: GAME SIDEBAR
   ========================================================================== */

.fps-game-sidebar {
    display: flex;
    flex-direction: column;
    gap: clamp(1rem, 2vw, 1.25rem);
}

@media (max-width: 767px) {
    .fps-game-sidebar {
        display: none;
    }
}

@media (min-width: 768px) {
    .fps-game-sidebar {
        position: sticky;
        top: 80px;
    }
}

/* ==========================================================================
   GAME CARD - Clean, modern design
   ========================================================================== */

.fps-game-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg, 12px);
    padding: clamp(1rem, 2.5vw, 1.5rem);
    position: relative;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.fps-game-card:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

/* Release Badge (positioned inside cover, top-left) */
.game-release-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    padding: 0.25rem 0.5rem;
    background: var(--bg-secondary);
    border: 1px solid var(--accent);
    border-radius: 4px;
    font-size: 0.625rem;
    font-weight: 600;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.03em;
    z-index: 2;
}

/* Game Cover */
.game-cover-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 3/4;
    border-radius: 8px;
    overflow: hidden;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    padding: 0;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

.game-cover-wrapper:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    border-color: var(--accent);
}

.game-cover-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.game-cover-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: var(--text-muted);
}

.game-cover-hover {
    position: absolute;
    inset: 0;
    background: var(--bg-overlay);
    backdrop-filter: blur(4px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    opacity: 0;
    transition: opacity 0.2s;
    color: var(--text-primary);
    font-size: 0.8125rem;
    font-weight: 500;
}

.game-cover-wrapper:hover .game-cover-hover {
    opacity: 1;
}

/* Game Card Info */
.game-card-info {
    margin-top: clamp(0.75rem, 1.5vw, 1rem);
}

.game-info-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.game-icon {
    width: 24px;
    height: 24px;
    border-radius: 4px;
    object-fit: cover;
    flex-shrink: 0;
}

.game-icon-placeholder {
    width: 24px;
    height: 24px;
    border-radius: 4px;
    background: var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    flex-shrink: 0;
}

.game-name {
    font-size: clamp(0.875rem, 1.5vw, 1rem);
    font-weight: 600;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Change Game Button */
.btn-change-game {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: clamp(0.75rem, 1.25vw, 0.8125rem);
    cursor: pointer;
    padding: 0;
    transition: color 0.2s;
}

.btn-change-game:hover {
    color: var(--accent);
}

.change-dot {
    width: 6px;
    height: 6px;
    background: var(--success);
    border-radius: 50%;
    box-shadow: 0 0 6px rgba(var(--success-rgb), 0.5);
}

/* ==========================================================================
   TWITCH VIEWERS CARD - Clean design
   ========================================================================== */

.twitch-viewers-card {
    display: none;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg, 12px);
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.twitch-viewers-card:hover {
    border-color: var(--twitch-purple, #9146FF);
    box-shadow: 0 4px 16px rgba(145, 70, 255, 0.15);
    transform: translateY(-2px);
}

@media (min-width: 768px) {
    .twitch-viewers-card {
        display: flex;
    }
}

/* ==========================================================================
   MOBILE GAME HEADER (Compact side-by-side)
   Only visible on mobile, hidden on desktop
   ========================================================================== */

.fps-mobile-game-header {
    display: flex;
    gap: clamp(0.75rem, 2vw, 1rem);
    margin-bottom: clamp(1rem, 2vw, 1.25rem);
    align-items: flex-start;
}

@media (min-width: 768px) {
    .fps-mobile-game-header {
        display: none;
    }
}

.mobile-game-cover {
    position: relative;
    width: 100px;
    min-width: 100px;
    aspect-ratio: 3/4;
    border-radius: 8px;
    overflow: hidden;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    cursor: pointer;
    padding: 0;
    transition: transform 0.2s, border-color 0.2s;
}

.mobile-game-cover:hover {
    transform: scale(1.02);
    border-color: var(--accent);
}

.mobile-release-badge {
    position: absolute;
    top: 6px;
    left: 6px;
    padding: 0.2rem 0.4rem;
    background: var(--bg-secondary);
    border: 1px solid var(--accent);
    border-radius: 4px;
    font-size: 0.5625rem;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.02em;
    z-index: 2;
}

.mobile-cover-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.mobile-cover-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: var(--text-muted);
}

.mobile-game-info {
    flex: 1;
    min-width: 0;
}

.mobile-game-title {
    font-size: clamp(1.125rem, 3vw, 1.375rem);
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 0.375rem;
    line-height: 1.2;
}

.mobile-game-subtitle {
    font-size: clamp(0.75rem, 2vw, 0.8125rem);
    color: var(--text-secondary);
    margin: 0 0 0.625rem;
    line-height: 1.4;
}

.mobile-change-game {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 0.5rem 0.75rem;
    color: var(--text-primary);
    font-size: 0.75rem;
    cursor: pointer;
    transition: border-color 0.2s, transform 0.2s;
}

.mobile-change-game:hover {
    border-color: var(--accent);
    transform: translateY(-1px);
}

.mobile-change-game .change-dot {
    width: 6px;
    height: 6px;
    background: var(--success);
    border-radius: 50%;
    box-shadow: 0 0 6px rgba(var(--success-rgb), 0.5);
}

.mobile-change-game .change-text {
    color: var(--text-muted);
    margin-left: 0.25rem;
}

/* Mobile Game Meta (simplified layout) */
.mobile-game-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.mobile-game-icon {
    width: 20px;
    height: 20px;
    border-radius: 4px;
    object-fit: cover;
    flex-shrink: 0;
}

.mobile-game-name {
    font-size: clamp(0.75rem, 2vw, 0.8125rem);
    font-weight: 500;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mobile-change-btn {
    margin-left: auto;
    padding: 0.375rem 0.625rem;
    background: var(--accent);
    border: none;
    border-radius: 6px;
    color: var(--bg-primary);
    font-size: clamp(0.625rem, 1.5vw, 0.6875rem);
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    transition: opacity 0.15s, transform 0.15s;
}

.mobile-change-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.twitch-icon {
    flex-shrink: 0;
    color: var(--twitch-purple, #9146FF);
}

.twitch-label {
    font-size: clamp(0.75rem, 1.25vw, 0.8125rem);
    color: var(--text-secondary);
    white-space: nowrap;
}

.twitch-count {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    margin-left: auto;
    font-size: clamp(0.8125rem, 1.4vw, 0.875rem);
    font-weight: 600;
    color: var(--text-primary);
}

.twitch-count svg {
    color: var(--text-muted);
}
