Total consulting related fees associated with BSA/AML compliance matters were $796,000 for the second quarter of 2021, compared to $661,000 in the first quarter of 2021 and $214,000 in the second quarter of 2020. Legal fees related to the BSA/AML compliance matters were $592,000 for the second quarter of 2021 compared to $290,000 for the second quarter of 2020. No legal fees related to the BSA/AML compliance matters were recorded in the first quarter of 2021.
Income Taxes
Income tax expense was $2.7 million for the second quarter of 2021, $2.5 million for the first quarter of 2021 and $539,000 for the second quarter of 2020. The effective tax rates were 18.70% for the second quarter of 2021, 19.87% for the first quarter of 2021 and 19.95% for the second quarter of 2020. The differences between the federal statutory rate of 21% and the effective tax rates were largely attributable to permanent differences primarily related to tax exempt interest income and bank-owned life insurance earnings.
Balance Sheet Highlights
Loans
Loans excluding loans held for sale were $2.7 billion at June 30, 2021, $2.9 billion at March 31, 2021 and $2.9 billion at June 30, 2020. The decrease from March 31, 2021 to June 30, 2021 and the decrease from June 30, 2020 to June 30, 2021 were both primarily due to higher loan paydowns versus loan originations.
The decrease in loans was impacted by the Company’s participation in the PPP under the Coronavirus Aid, Relief and Economic Security Act, or CARES Act, which facilitates loans to small businesses. PPP loans, net of deferred fees and unearned discounts, were $179.1 million at June 30, 2021, $268.8 million at March 31, 2021 and $323.7 million at June 30, 2021. During the second quarter of 2021, $20.4 million of PPP loans were originated and payments totaling $110.4 million were received. During the first quarter of 2021, $122.3 million of PPP loans were originated and payments totaling $123.4 million were received.
In support of customers impacted by the COVID-19 pandemic, the Company offered relief through payment deferrals during 2020 and the first and second quarters of 2021. As of June 30, 2021, the Company had 9 loans subject to such deferral arrangements with total outstanding principal balances of $20.5 million, compared to 16 loans totaling $34.3 million as of March 31, 2021 and 689 loans totaling $545.0 million at June 30, 2020.
Deposits and Borrowings
Total deposits were $3.4 billion at June 30, 2021, $3.4 billion at March 31, 2021 and $3.3 billion at June 30, 2020. The increase in deposits of $32.0 million between March 31, 2021 and June 30, 2021 was due to net deposit inflows of $96.7 million in interest-bearing accounts, partially offset by net deposit outflows of $64.6 million in non-interest-bearing accounts. The increase in deposits of $162.6 million between June 30, 2020 and June 30, 2021 was due to net deposit inflows of $119.5 million and $43.0 million in interest-bearing accounts and noninterest-bearing accounts, respectively.
The Company defines total borrowings as the total of repurchase agreements, Federal Home Loan Bank advances and notes payable. Total borrowings were $50.0 million, $50.0 million and $52.5 million at June 30, 2021, March 31, 2021 and June 30, 2020, respectively.
Capital
At June 30, 2021, the Company continued to be well capitalized and maintained strong capital ratios under bank regulatory requirements. The Company’s total risk-based capital ratio was 17.72% at June 30, 2021, compared to 17.00% at March 31, 2021 and 16.56% at June 30, 2020. The Company’s tier 1 leverage ratio was 11.63% at June 30, 2021, compared to 11.90% at March 31, 2021 and 11.96% at June 30, 2020. The Company’s total shareholders’ equity to total assets ratio was 13.68% at June 30, 2021, 13.54% at March 31, 2021 and 13.77% at June 30, 2020.
The ratio of tangible equity to tangible assets was 11.84% at June 30, 2021, 11.67% at March 31, 2021 and 11.84% at June 30, 2020. Tangible equity to tangible assets is a non-GAAP financial measure. The most directly comparable financial measure calculated in accordance with United States generally accepted accounting principles, or GAAP, to tangible equity to tangible assets is total shareholders’ equity to total assets. See the table captioned “Non-GAAP to