Loans and allowance for loan losses (Details 8) - USD ($)
$ in Thousands
Sep. 30, 2017
Jun. 30, 2017
Dec. 31, 2016
Sep. 30, 2016
Jun. 30, 2016
Dec. 31, 2015
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance $ 3,243 $ 3,267 $ 3,373 $ 3,419 $ 3,523 $ 3,562
Allowance Individually Evaluated for Impairment 327   335      
Allowance Collectively Evaluated for Impairment 2,916   3,038      
Loans Ending Balance 347,002   337,100      
Loans Individually Evaluated for Impairment 15,574   15,441      
Loans Collectively Evaluated for Impairment 331,428   321,659      
Residential [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 38 38 41 43 31 30
Allowance Individually Evaluated for Impairment 0   0      
Allowance Collectively Evaluated for Impairment 38   41      
Loans Ending Balance 6,327   6,770      
Loans Individually Evaluated for Impairment 0   0      
Loans Collectively Evaluated for Impairment 6,327   6,770      
Commercial [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 175 213 300 276 259 291
Allowance Individually Evaluated for Impairment 2   9      
Allowance Collectively Evaluated for Impairment 173   291      
Loans Ending Balance 28,721   27,092      
Loans Individually Evaluated for Impairment 561   581      
Loans Collectively Evaluated for Impairment 28,160   26,511      
Commercial Real Estate [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 1,000 974 1,076 1,236 1,204 1,695
Allowance Individually Evaluated for Impairment 21   86      
Allowance Collectively Evaluated for Impairment 979   990      
Loans Ending Balance 140,057   133,099      
Loans Individually Evaluated for Impairment 7,610   7,840      
Loans Collectively Evaluated for Impairment 132,447   125,259      
Home equity lines [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 247 $ 250 271 $ 264 $ 259 $ 448
Allowance Individually Evaluated for Impairment 4   0      
Allowance Collectively Evaluated for Impairment 243   271      
Loans Ending Balance 20,595   20,691      
Loans Individually Evaluated for Impairment 739   703      
Loans Collectively Evaluated for Impairment 19,856   19,988      
Construction and Land Development Commercial [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 213   341      
Allowance Individually Evaluated for Impairment 2   9      
Allowance Collectively Evaluated for Impairment 211   332      
Loans Ending Balance 35,048   33,862      
Loans Individually Evaluated for Impairment 561   581      
Loans Collectively Evaluated for Impairment 34,487   33,281      
Owner Occupied [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 524   611      
Allowance Individually Evaluated for Impairment 21   86      
Allowance Collectively Evaluated for Impairment 503   525      
Loans Ending Balance 71,834   66,021      
Loans Individually Evaluated for Impairment 5,434   5,604      
Loans Collectively Evaluated for Impairment 66,400   60,417      
Non-Owner Occupied [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 434   406      
Allowance Individually Evaluated for Impairment 0   0      
Allowance Collectively Evaluated for Impairment 434   406      
Loans Ending Balance 61,831   57,944      
Loans Individually Evaluated for Impairment 2,176   2,236      
Loans Collectively Evaluated for Impairment 59,655   55,708      
Multifamily [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 39   56      
Allowance Individually Evaluated for Impairment 0   0      
Allowance Collectively Evaluated for Impairment 39   56      
Loans Ending Balance 6,114   8,824      
Loans Individually Evaluated for Impairment 0   0      
Loans Collectively Evaluated for Impairment 6,114   8,824      
Farmland [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 3   3      
Allowance Individually Evaluated for Impairment 0   0      
Allowance Collectively Evaluated for Impairment 3   3      
Loans Ending Balance 278   310      
Loans Individually Evaluated for Impairment 0   0      
Loans Collectively Evaluated for Impairment 278   310      
First Deed of Trust [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 459   447      
Allowance Individually Evaluated for Impairment 62   144      
Allowance Collectively Evaluated for Impairment 397   303      
Loans Ending Balance 54,820   54,791      
Loans Individually Evaluated for Impairment 4,733   5,064      
Loans Collectively Evaluated for Impairment 50,087   49,727      
Second Deed of Trust [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 45   136      
Allowance Individually Evaluated for Impairment 5   90      
Allowance Collectively Evaluated for Impairment 40   46      
Loans Ending Balance 6,293   5,768      
Loans Individually Evaluated for Impairment 680   709      
Loans Collectively Evaluated for Impairment 5,613   5,059      
Consumer Real Estate [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 751   854      
Allowance Individually Evaluated for Impairment 71   234      
Allowance Collectively Evaluated for Impairment 680   620      
Loans Ending Balance 81,708   81,250      
Loans Individually Evaluated for Impairment 6,152   6,476      
Loans Collectively Evaluated for Impairment 75,556   74,774      
Commercial and industrial loans (except those secured by real estate) [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 445   223      
Allowance Individually Evaluated for Impairment 233   6      
Allowance Collectively Evaluated for Impairment 212   217      
Loans Ending Balance 40,647   39,390      
Loans Individually Evaluated for Impairment 1,248   544      
Loans Collectively Evaluated for Impairment 39,399   38,846      
Guaranteed student loans [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 99   158      
Allowance Individually Evaluated for Impairment 0   0      
Allowance Collectively Evaluated for Impairment 99   158      
Loans Ending Balance 47,643   47,398      
Loans Individually Evaluated for Impairment 0   0      
Loans Collectively Evaluated for Impairment 47,643   47,398      
Consumer And Other [Member]            
Financing Receivable, Allowance for Credit Losses [Line Items]            
Allowance Ending Balance 735   721      
Allowance Individually Evaluated for Impairment 0   0      
Allowance Collectively Evaluated for Impairment 735   721      
Loans Ending Balance 1,899   2,101      
Loans Individually Evaluated for Impairment 3   0      
Loans Collectively Evaluated for Impairment $ 1,896   $ 2,101