.memory-game-container {
    background: black;
    border-radius: 12px;
    padding: 10px;
    margin-top: 16px;
    max-width: full;
}


.memory-game-title {
    text-align: center;
    color: #fff;
    margin-bottom: 8px;
    font-size: 14px;
}

.memory-stats {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 8px;
    padding: 6px;
    background: black;
    border-radius: 8px;
}

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

.memory-stat-label {
    color: #999;
    font-size: 9px;
    margin-bottom: 2px;
}

.memory-stat-value {
    font-size: 14px;
    font-weight: bold;
    color: #66bb6a;
}

.memory-game-grid {
    display: grid;
    grid-template-columns: repeat(4, 60px);
    /* FIXED size */
    gap: 8px;
    justify-content: center;
    /* center grid */
    margin-bottom: 10px;
}


.memory-card {
    width: 60px;
    height: 60px;
    background: #444;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 18px;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
}


.memory-card:hover {
    background: #555;
}

.memory-card.flipped {
    background: #333;
    color: #fff;
}

.memory-card.matched {
    background: #66bb6a;
    color: #fff;
    cursor: default;
}

.memory-game-btn {
    width: 100%;
    padding: 6px;
    border: 1px solid aquamarine;
    border-radius: 8px;
    font-size: 13px;
    font-weight: bold;
    cursor: pointer;
    background: black;
    color: #fff;
}

.memory-game-btn:hover {
    background: gray;
}

.memory-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    z-index: 100;
    align-items: center;
    justify-content: center;
}

.memory-modal.show {
    display: flex;
}

.memory-modal-content {
    background: #2a2a2a;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
}

.memory-modal-content h2 {
    font-size: 20px;
    color: #fff;
    margin-bottom: 12px;
}

.memory-modal-content .memory-final-moves {
    font-size: 28px;
    font-weight: bold;
    color: #66bb6a;
    margin: 10px 0;
}

.memory-modal-content p {
    color: #999;
    margin-bottom: 15px;
    font-size: 13px;
}

.memory-modal-content button {
    background: #66bb6a;
    color: #fff;
}