/* Console Mode Base Styles */
.console-mode {
    margin: 0;
    padding: 0;
    overflow: hidden;
    height: 100vh;
    width: 100vw;
    background-color: #050505;
    background-image: radial-gradient(circle at top right, rgba(212, 175, 55, 0.05), transparent);
    color: white;
    font-family: 'Poppins', sans-serif;
}

.console-container {
    display: flex;
    height: 100vh;
    width: 100vw;
    position: relative;
    z-index: 5;
}

/* Left Pane: Game Scroll */
.game-list-pane {
    width: 350px;
    background: linear-gradient(to right, rgba(255, 255, 255, 0.02), transparent);
    border-right: 1px solid rgba(255, 255, 255, 0.05);
    padding: 2rem 0;
    position: relative;
    display: flex;
    flex-direction: column;
}

.vertical-scroll {
    flex-grow: 1;
    overflow-y: auto;
    padding: 0 2rem;
    scrollbar-width: none; /* Firefox */
}

.vertical-scroll::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

.console-game-card {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 12px;
    margin-bottom: 2rem;
    border: 2px solid transparent;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    background: #1a1a1c;
    position: relative;
}

.console-game-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.console-game-card.selected {
    border-color: var(--gold);
    transform: scale(1.1) translateX(15px);
    box-shadow: -10px 0 30px rgba(212, 175, 55, 0.3);
    z-index: 10;
}

.console-game-card.selected img {
    opacity: 1;
}

/* Right Pane: Details */
.details-pane {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    padding: 0;
    position: relative;
    background: radial-gradient(circle at center, rgba(15, 15, 17, 0) 0%, rgba(5, 5, 5, 0.8) 100%);
}

.console-header {
    height: 100px;
    padding: 0 4rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 3rem;
}

.logo-crop {
    height: 50px;
    width: 50px;
    overflow: hidden;
    border-radius: 12px;
    background: var(--glass);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid transparent;
    transition: var(--transition);
    cursor: pointer;
}

.logo-crop.selected {
    border-color: var(--gold);
    background: rgba(212, 175, 55, 0.1);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
    transform: scale(1.1);
}

.console-logo-img {
    height: 100%;
    width: auto;
}

.console-search-bar {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    padding: 0.8rem 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 400px;
    cursor: pointer;
    transition: var(--transition);
    color: var(--text-gray);
}

.console-search-bar.selected {
    border-color: var(--gold);
    background: rgba(212, 175, 55, 0.1);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
    color: white;
}

.profile-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.profile-btn.selected {
    border-color: var(--gold);
    background: rgba(212, 175, 55, 0.1);
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.2);
    transform: scale(1.1);
}

.user-icon {
    width: 24px;
    height: 24px;
}

.game-display {
    flex-grow: 1;
    padding: 4rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.active-title {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: -2px;
}

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

.fav-indicator {
    width: 35px;
    height: 35px;
    display: flex;
    align-items: center;
}

.description-container {
    max-width: 700px;
    max-height: 250px;
    overflow-y: auto;
    scrollbar-width: none;
    font-size: 1.1rem;
    color: var(--text-gray);
    line-height: 1.8;
}

.description-container::-webkit-scrollbar {
    display: none;
}

/* Controller Help & Hints */
.nav-hints {
    position: absolute;
    bottom: 3rem;
    right: 4rem;
    display: flex;
    gap: 2.5rem;
}

.hint-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-weight: 600;
    color: var(--text-gray);
}

.hint-icon {
    width: 32px;
    height: 32px;
}

/* Overlays */
.keyboard-overlay, .viewport-overlay, .pause-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.hidden {
    display: none !important;
}

/* Keyboard UI */
.keyboard-content {
    width: 800px;
    padding: 3rem;
}

.kb-display {
    margin-bottom: 2rem;
}

.kb-input-wrapper {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    padding: 1.5rem;
    border-radius: 12px;
    text-align: center;
}

#kb-input {
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    width: 100%;
    text-align: center;
    font-family: inherit;
    outline: none;
}

.keys-grid {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 0.8rem;
    margin-bottom: 3rem;
}

.kb-key {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.kb-key.selected {
    background: var(--gold);
    color: black;
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.5);
}

.kb-footer {
    display: flex;
    justify-content: center;
    gap: 3rem;
}

.kb-action-hint {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-weight: 600;
}

/* Controller Modal */
.controller-options {
    display: flex;
    gap: 2rem;
    margin-top: 2rem;
}

.ctrl-opt {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    padding: 2rem;
    border-radius: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    color: white;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.ctrl-opt.selected, .ctrl-opt:hover {
    border-color: var(--gold);
    background: rgba(212, 175, 55, 0.1);
    transform: translateY(-10px);
}

.ctrl-opt img {
    width: 80px;
    height: 80px;
}

/* Pause Menu */
.pause-content {
    text-align: center;
    padding: 4rem;
    width: 400px;
}

.pause-options {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin: 3rem 0;
}

.pause-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    padding: 1.2rem;
    border-radius: 12px;
    color: white;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.pause-btn.selected, .pause-btn.active {
    background: var(--gold);
    color: black;
    border-color: var(--gold);
    transform: scale(1.05);
}

/* Viewport for Iframe */
#game-frame {
    width: 100vw;
    height: 100vh;
    border: none;
}

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

@keyframes pulse {
    0% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.1); opacity: 1; box-shadow: 0 0 30px rgba(212, 175, 55, 0.4); }
    100% { transform: scale(1); opacity: 0.8; }
}

.pulsing-icon {
    animation: pulse 2s infinite ease-in-out;
    background: rgba(212, 175, 55, 0.1);
    width: 120px;
    height: 120px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 2rem;
    border: 2px solid var(--gold);
}

.large-icon {
    width: 60px;
    height: 60px;
}

.text-center {
    text-align: center;
}

.active-title, .active-title span {
    animation: fadeIn 0.5s ease-out;
}