
.games-list {
            display: flex;
            flex-wrap: wrap;
            gap: 2rem;
            justify-content: center;
            margin: 2rem 30rem;
        }
        .game-card {
            border: 1px solid #ccc;
            border-radius: 8px;
            padding: 1rem;
            width: 300px;
            background: #fafafa;
            box-shadow: 0 2px 8px rgba(0,0,0,0.05);
            text-align: center;
            cursor: pointer;
            transition: box-shadow 0.2s;
        }
        .game-card:hover {
            box-shadow: 0 4px 16px rgba(0,0,0,0.10);
        }
        .modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-backdrop.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: white;
    border-radius: 8px;
    padding: 20px;
    position: relative;
    width: 80%;
    height: 80%;
    max-width: none;
    max-height: none;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.modal-close {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #666;
    z-index: 1001;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.modal-frame {
    flex: 1;
    width: 100%;
    border: none;
    border-radius: 4px;
    margin-top: 10px;
}

#modalTitle {
    margin: 0 0 10px 0;
    padding-right: 40px; /* Space for close button */
    font-size: 1.5em;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        height: 85%;
        padding: 15px;
    }
    
    #modalTitle {
        font-size: 1.2em;
    }
}

@media (max-width: 480px) {
    .modal-content {
        width: 98%;
        height: 90%;
        padding: 10px;
    }
}