Quarterly report pursuant to Section 13 or 15(d)

Debt - Convertible Debt (Details)

v3.7.0.1
Debt - Convertible Debt (Details) - USD ($)
$ in Thousands
6 Months Ended
Jun. 30, 2017
May 31, 2017
May 23, 2017
Dec. 31, 2016
Convertible Debt [Abstract]        
Convertible notes payable, net $ 275,673     $ 0
Convertible Senior Notes | Convertible Senior Notes Due November 2022        
Convertible Debt [Abstract]        
Principal amount 345,000   $ 345,000  
Unamortized discount (61,497)      
Unamortized debt issuance costs (7,830)      
Convertible notes payable, net 275,673 $ 282,500    
Equity component 61,401 $ 62,500    
Interest Expense, Debt [Abstract]        
Contractual interest expense 561      
Amortization of debt discount 1,052      
Amortization of debt issuance costs 134      
Interest expense, net $ 1,747      
Effective interest rate of the liability component 5.87%