Debt | 6. Deb t Long-term debt consisted of the following at March 31, 2018 and December 31, 2017 (in thousands): March 31, 2018 December 31, 2017 Senior secured loans (includes unamortized discount of $3,103 and $2,668 based on an imputed interest rate of 7.0% and 7.5%, at March 31, 2018 and December 31, 2017, respectively) $ 159,866 $ 111,144 Less current maturities (3,282 ) (2,301 ) Total long-term debt $ 156,584 $ 108,843 Loan and Security Agreements Sixth Amendment to Credit Facility On March 21, 2018, the Company amended and expanded its Credit Agreement dated May 14, 2015, as amended, among, inter alia , the Company, certain of its subsidiaries, and each of the lenders named in the Credit Agreement (the “Credit Facility”). The Company entered into a sixth amendment to the Credit Facility with Wells Fargo Capital Finance and CIT Bank, N.A. as joint lead arrangers, and including Goldman Sachs Bank USA, Regions Bank, and Citizens Bank, N.A. (collectively, the "Lenders"), with a Consent and Sixth Amendment to Credit Agreement (the “Sixth Amendment”). Loans The Sixth Amendment to the Credit Facility provides for a $258.7 million credit facility, including (i) a fully drawn $163.0 million term loan, (ii) a fully available $30.0 million delayed draw term loan commitment (the "DDTL"), (iii) a fully available $10.0 million revolving loan commitment, and (iv) a $55.0 million uncommitted accordion. Specifically, the Credit Facility provides for $163.7 million of term debt comprised of (i) a fully drawn U.S. term loan facility in an aggregate principal amount of $158.4 million (the “U.S. Term Loan”), (ii) a fully drawn Canadian term loan facility in an aggregate principal amount of $5.3 million (the “Canadian Term Loan” together with the U.S. and Canadian Term Loans, the “Term Loans”). In addition, the Credit Facility also provides for revolvers of $10.0 million , comprised of (i) a U.S. revolving credit facility in an aggregate principal amount of up to $9.0 million (the “U.S. Revolver”), (ii) a Canadian revolving credit facility in an aggregate principal amount of up to $1.0 million (the “Canadian Revolver” and, together with the U.S. Revolver, the “Revolver”). As of March 31, 2018 , there were no amounts drawn on its U.S. Revolver or Canadian Revolver loans outstanding under the Credit Facility, and there was $163.0 million outstanding on the Term Loans comprised of (i) $157.7 million in the U.S. Term Loans outstanding under the Credit Facility; and (ii) $5.3 million in the Canadian Term Loans outstanding under the Credit Facility. Terms of Term Loans Under the terms of the Sixth Amendment, the Term Loans are repayable, on a quarterly basis by an amount equal to 2.5% per annum on or before June 30, 2019, after which the existing 5.0% per annum is due thereafter until the facility’s maturity date of August 2, 2022. The Sixth Amendment also provides for other improvements including, among other things, (i) a favorable adjustment to decrease the overall applicable interest rate for accounts outstanding under the Credit Agreement by 50 to 150 basis points resulting in a current effective interest rate of approximately 6.15% down from the previous effective interest rate of approximately 7.1% ; (ii) a favorable adjustment to the leverage ratio to increase the amount of funded indebtedness to EBITDA (as defined in the Amendment) to 4.25 to 1.00 as of March 31, 2018, along with additional leverage ratio improvements throughout the remainder of the loan term; and (iii) a favorable increase to the recurring revenue ratio future draw condition to the delayed draw term loan facility from 1.25 :1.0 to 1.50 :1.0. Also, the maximum amount of purchase consideration payable in respect of an individual permitted acquisition is $25.0 million and in respect of all permitted acquisitions is $175.0 million . In addition, the amount of permitted indebtedness to sellers of businesses increased is $20.0 million . Terms of Delay Draw Term Loan Pursuant to the terms of the Credit Facility, the undrawn $30.0 million DDTL is to be used to finance acquisitions. The DDTL, if all or a portion is drawn, is repayable, on a quarterly basis, by an amount equal to 2.5% per annum on or before June 30, 2019, after which the existing 5.0% per annum is due thereafter until the facility’s maturity date of August 2, 2022. Terms of Revolver Loans under the Revolver are available up to the lesser of (i) $10.0 million (the “Maximum Revolver Amount”) or (ii) the maximum facility amount of $203.7 million , less the sum of any amount of Revolver usage plus the outstanding balance of the Term Loans and other uses of the capacity made under the Credit Facility (such amount, the “Credit Amount”). The Revolver provides a subfacility whereby the Company may request letters of credit (the “Letters of Credit”) in an aggregate amount not to exceed, at any one time outstanding, $0.5 million and $0.25 million , from the U.S and Canadian facilities, respectively. The aggregate amount of outstanding Letters of Credit is reserved against the credit availability under the Maximum Revolver Amount and the Credit Amount. Loans under the Revolver may be borrowed, repaid and reborrowed until August 2, 2022 (the “Maturity Date”), at which time all amounts borrowed under the Credit Facility must be repaid. Other Terms of Credit Facility At the option of the Company, U.S. loans accrue interest at a per annum rate based on (i) the U.S. base rate plus a margin ranging from 3.00% to 4.00% depending on the leverage ratio or (ii) the U.S. LIBOR rate determined in accordance with the Credit Facility (based on 1, 2, 3 or 6-month interest periods) plus a margin ranging from 4.00% to 5.00% depending on the leverage ratio. The U.S. base rate is a rate equal to the highest of (i) the federal funds rate plus a margin equal to 0.5% , the U.S. LIBOR rate for a 1-month interest period plus 1.0% , and (ii) Wells Fargo Capital Finance’s prime rate. At the option of the Company, the Canadian loans accrue interest at a per annum rate based on (i) the Canadian prime rate or the U.S. base rate plus a margin ranging from 3.00% to 4.00% depending on the leverage ratio or (ii) the U.S. LIBOR rate determined in accordance with the Credit Facility (based on 1, 2, 3 or 6-month interest periods) (or the Canadian Bankers' Acceptance ("Canadian BA") rate determined in accordance with the Credit Facility for obligations in Canadian dollars) plus a margin ranging from 4.00% to 5.00% depending on the leverage ratio. Accrued interest on the loans will be paid monthly, or, with respect to loans that are accruing interest based on the U.S. LIBOR rate or Canadian BA rate, at the end of the applicable U.S. LIBOR or Canadian BA interest rate period. Lenders are entitled to a premium (the “Prepayment Premium”) in the event of certain prepayments of the outstanding loans in place at the time of the Sixth Amendment totaling in an amount equal to $113.0 million (i) August 2, 2017 to August 1, 2018, 2.0% times the sum of (a) the Maximum Revolver Amount plus (b) the outstanding principal amount of the Term Loans and DDTL on the date immediately prior to the date of the prepayment (such sum, the “Prepayment Amount”) (ii) from August 2, 2018 to August 1, 2019, 1.0% times the Prepayment Amount and (iii) from August 2, 2019 to the Maturity Date, 0.0% times the Prepayment Amount. The Company may also be subject to prepayment fees in the case of commitment reductions of the Revolver and also may be obligated to prepay loans upon the occurrence of certain events. The Company is also obligated to pay other customary servicing fees, letter of credit fees and unused credit facility fees. The Credit Facility contains customary affirmative and negative covenants. The negative covenants limit the ability of the Company and its subsidiaries to, among other things (in each case subject to customary exceptions for a credit facility of this size and type): • Incur additional indebtedness or guarantee indebtedness of others; • Create liens on their assets; • Make investments, including certain acquisitions; • Enter into mergers or consolidations; • Dispose of assets; • Pay dividends and make other distributions on the Company’s capital stock, and redeem and repurchase the Company’s capital stock; • Enter into transactions with affiliates; and • Prepay indebtedness or make changes to certain agreements. There are certain financial covenants that became more restrictive starting March 31, 2019. If an event of default occurs, at the election of the Lenders, a default interest rate shall apply on all obligations during an event of default, at a rate per annum equal to 2.00% above the applicable interest rate. The Credit Facility permits the Company to buyback up to $10.0 million of its capital stock, subject to restrictions including a minimum liquidity requirement of $25.0 million before and after any such buyback. Interest Rate and Debt Discount Cash interest costs averaged 7.1% and 6.3% under the Credit Facility for the three months ended March 31, 2018 and for the year ended December 31, 2017 , respectively. In addition, the Company has $3.1 million and $2.7 million of unamortized debt discount associated with the Credit Facility as of March 31, 2018 and December 31, 2017 , respectively. These debt discount costs will be amortized to non-cash interest expense over the term of the Credit Facility. Debt Maturities Under the terms of the Sixth Amendment, future debt maturities of long-term debt (excluding financing costs) at March 31, 2018 are as follows (in thousands): Year ending December 31: Remaining 2018 $ 3,094 2019 6,188 2020 8,250 2021 8,250 2022 137,187 Thereafter — Total debt maturities 162,969 Less current maturities (3,282 ) Less unamortized debt discount (3,103 ) Notes Payable, less current maturities and unamortized debt discount $ 156,584 |