CONSOLIDATED STATEMENTS OF CASH FLOWS - USD ($)
$ in Thousands
12 Months Ended
Dec. 31, 2019
Dec. 31, 2018
Dec. 31, 2017
Cash flows from operating activities      
Net income $ 171,957 $ 107,927 $ 22,050
Adjustments to reconcile net income to net cash provided by operating activities:      
Net realized investment gains (45) (57) (208)
Loss from change in fair value of warrant liability 8,657 1,397 4,105
Depreciation and amortization 9,299 7,811 6,663
Net amortization of premium on investment securities 1,252 1,519 1,599
Amortization of debt discount and debt issuance costs 1,011 3,390 1,473
Deferred income taxes 45,082 25,927 31,102
Share-based compensation expense 13,031 12,557 9,484
Changes in operating assets and liabilities:      
Premiums receivable (10,078) (10,828) (11,451)
Accrued investment income (1,137) (1,482) (791)
Prepaid expenses (472) (1,090) (160)
Deferred policy acquisition costs, net (13,132) (8,915) (7,816)
Other assets (8,831) 1,304 (1,547)
Unearned premiums (22,251) (4,273) 10,260
Reserve for insurance claims and claim expenses 10,941 4,050 5,760
Reinsurance balances, net (1,022) 560 (274)
Accounts payable and accrued expenses 3,888 6,064 (2,486)
Net cash provided by operating activities 208,150 145,861 67,763
Cash flows from investing activities      
Purchase of short-term investments (230,362) (257,916) (131,196)
Purchase of fixed-maturity investments, available-for-sale (290,533) (356,337) (219,079)
Proceeds from maturity of short-term investments 244,921 221,685 170,278
Proceeds from redemptions, maturities and sale of fixed-maturity investments, available-for-sale 91,575 179,978 95,435
Software and equipment (9,956) (8,060) (8,510)
Net cash used in investing activities (194,355) (220,650) (93,072)
Cash flows from financing activities      
Proceeds from issuance of common stock related to public offering, net of issuance costs 0 79,165 0
Proceeds from issuance of common stock related to employee equity plans 21,748 12,857 7,103
Proceeds from issuance of common stock related to warrant exercises 0 321 183
Taxes paid related to net share settlement of equity awards (18,248) (9,722) (8,582)
Proceeds from senior note, net 0 149,250 0
Repayments of term loan (1,500) (147,375) (1,500)
Payments of debt issuance/modification costs 0 (3,609) (445)
Net cash provided by (used in) financing activities 2,000 80,887 (3,241)
Net increase (decrease) in cash, cash equivalents and restricted cash 15,795 6,098 (28,550)
Cash, cash equivalents and restricted cash, beginning of period 25,294 19,196 47,746
Cash, cash equivalents and restricted cash, end of period 41,089 25,294 19,196
Supplemental disclosures of cash flow information      
Interest paid 10,691 12,093 13,355
Income taxes (refunded) paid $ (64) $ 867 $ 1,220