v3.22.0.1
Property and Equipment - Schedule of Property and Equipment and Classification of Depreciation (Details) - USD ($)
$ in Thousands
12 Months Ended
Dec. 31, 2021
Dec. 31, 2020
Property, Plant and Equipment [Line Items]    
Cost $ 232,872 $ 191,718
Accumulated depreciation 127,346 99,614
Net book value 105,526 92,104
Impairment charge 1,709 16,838
Depreciation 41,828 38,192
Cost of revenues    
Property, Plant and Equipment [Line Items]    
Depreciation 2,649 3,160
Sales and marketing    
Property, Plant and Equipment [Line Items]    
Depreciation 10,103 9,710
Research and development    
Property, Plant and Equipment [Line Items]    
Depreciation 20,125 19,587
General and administrative    
Property, Plant and Equipment [Line Items]    
Depreciation 8,951 5,735
Leasehold improvements    
Property, Plant and Equipment [Line Items]    
Cost 159,131 131,196
Accumulated depreciation 84,930 65,052
Net book value 74,201 66,144
Computer equipment    
Property, Plant and Equipment [Line Items]    
Cost 33,505 24,387
Accumulated depreciation 18,241 15,056
Net book value 15,264 9,331
Furniture and equipment    
Property, Plant and Equipment [Line Items]    
Cost 28,751 30,716
Accumulated depreciation 20,250 17,501
Net book value 8,501 13,215
Fulfillment robots    
Property, Plant and Equipment [Line Items]    
Cost 9,470  
Accumulated depreciation 3,888  
Net book value 5,582  
Fulfillment equipment    
Property, Plant and Equipment [Line Items]    
Cost 2,015 5,419
Accumulated depreciation 37 2,005
Net book value $ 1,978 $ 3,414