Income taxes - Schedule of Valuation Allowances (Details) - USD ($) $ in Thousands |
12 Months Ended | ||
|---|---|---|---|
Dec. 31, 2022 |
Dec. 31, 2021 |
Dec. 31, 2020 |
|
| Deferred Tax Assets, Valuation Allowance [Roll Forward] | |||
| Beginning at beginning of period | $ 41,929 | $ 43,467 | $ 45,661 |
| Additions to valuation allowance | 7,228 | 6,108 | 3,719 |
| Reductions to valuation allowance | (22,818) | (7,646) | (5,913) |
| Balance at the end of the period | $ 26,339 | $ 41,929 | $ 43,467 |