| Schedule of changes in Accumulated other comprehensive (loss) income | The following tables show the changes in Accumulated other comprehensive (loss) income (in thousands): 
|  |  |  |  |  |  |  |  |  |  |  
|  |  | Accumulated |  | Accumulated |  |  | Total |  
|  |  | foreign |  | unrealized |  |  | accumulated |  
|  |  | currency |  | gains (losses) on |  |  | other |  
|  |      | translation  |      | available-for-sale |  |  | comprehensive |  
|  |  | adjustments |  | debt securities |  |  | (loss) income |  
|  |  |  |  |  |  |  |  |  |  |  
| Balance at January 1, 2022 |   | $ |  (10,785) |  | $ |  (357) |  | $ |  (11,142) |  
| Foreign currency translation adjustments |  |  |  16,792 |  |  |  — |  |  |  16,792 |  
| Foreign currency losses on intercompany loan of a long-term investment nature, net of tax of $0 |  |  |  (13,808) |  |  |  — |  |  |  (13,808) |  
| Unrealized holding losses on available-for-sale debt securities, net of tax of $0 |  |  |  — |  |  |  (1,155) |  |  |  (1,155) |  
| Balance at March 31, 2022 |  | $ |  (7,801) |  | $ |  (1,512) |  | $ |  (9,313) |  
|  |  |  |  |  |  |  |  |  |  |  
|  |  |  |  |  |  |  |  |  |  |  
|  |  |  |  |  |  |  |  |  |  |  
|  |  |  |  |  |  |  |  |  |  |  
|  |  |  |  |  |  |  |  |  |  |  
|  |  | Accumulated |  | Accumulated |  | Total |  
|  |  | foreign |  | unrealized |  | accumulated |  
|  |  | currency |  |  gains (losses) on |  | other |  
|  |      | translation  |      | available-for-sale |  | comprehensive |  
|  |  | adjustments |  | debt securities |  | (loss) income |  
|  |  |  |  |  |  |  |  |  |  |  
| Balance at January 1, 2021 |   | $ |  (10,158) |  | $ |  110 |  | $ |  (10,048) |  
| Foreign currency translation adjustments |  |  |  (3,001) |  |  |  — |  |  |  (3,001) |  
| Foreign currency gains on intercompany loan of a long-term investment nature, net of tax of $0 |  |  |  3,048 |  |  |  — |  |  |  3,048 |  
| Unrealized holding losses on available-for-sale debt securities, net of tax of $0 |  |  |  — |  |  |  (223) |  |  |  (223) |  
| Balance at March 31, 2021 |  | $ |  (10,111) |  | $ |  (113) |  | $ |  (10,224) |  |