Available-for-Sale Securities and Fair Value Measurements - Fair Value Measurements (Details) - USD ($) $ in Thousands | Jun. 30, 2018 | Dec. 31, 2017 |
Recurring basis | | |
Assets | | |
Total assets measured at estimated fair value | $ 101,742 | $ 122,709 |
Recurring basis | U.S. government securities | | |
Assets | | |
Total assets measured at estimated fair value | | 9,942 |
Recurring basis | U.S. government agencies | | |
Assets | | |
Total assets measured at estimated fair value | | 9,985 |
Recurring basis | U.S. corporate notes | | |
Assets | | |
Total assets measured at estimated fair value | 3,869 | 10,866 |
Recurring basis | U.S. commercial papers | | |
Assets | | |
Total assets measured at estimated fair value | 16,447 | 29,945 |
Recurring basis | Money market funds | | |
Assets | | |
Total assets measured at estimated fair value | 81,426 | 61,971 |
Recurring basis | Quoted Prices in Active Markets for Identical Assets, Level 1 | | |
Assets | | |
Total assets measured at estimated fair value | 81,426 | 61,971 |
Recurring basis | Quoted Prices in Active Markets for Identical Assets, Level 1 | U.S. government securities | | |
Assets | | |
Total assets measured at estimated fair value | | 0 |
Recurring basis | Quoted Prices in Active Markets for Identical Assets, Level 1 | U.S. government agencies | | |
Assets | | |
Total assets measured at estimated fair value | | 0 |
Recurring basis | Quoted Prices in Active Markets for Identical Assets, Level 1 | U.S. corporate notes | | |
Assets | | |
Total assets measured at estimated fair value | 0 | 0 |
Recurring basis | Quoted Prices in Active Markets for Identical Assets, Level 1 | U.S. commercial papers | | |
Assets | | |
Total assets measured at estimated fair value | 0 | 0 |
Recurring basis | Quoted Prices in Active Markets for Identical Assets, Level 1 | Money market funds | | |
Assets | | |
Total assets measured at estimated fair value | 81,426 | 61,971 |
Recurring basis | Significant Other Observable Inputs, Level 2 | | |
Assets | | |
Total assets measured at estimated fair value | 20,316 | 60,738 |
Recurring basis | Significant Other Observable Inputs, Level 2 | U.S. government securities | | |
Assets | | |
Total assets measured at estimated fair value | | 9,942 |
Recurring basis | Significant Other Observable Inputs, Level 2 | U.S. government agencies | | |
Assets | | |
Total assets measured at estimated fair value | | 9,985 |
Recurring basis | Significant Other Observable Inputs, Level 2 | U.S. corporate notes | | |
Assets | | |
Total assets measured at estimated fair value | 3,869 | 10,866 |
Recurring basis | Significant Other Observable Inputs, Level 2 | U.S. commercial papers | | |
Assets | | |
Total assets measured at estimated fair value | 16,447 | 29,945 |
Recurring basis | Significant Other Observable Inputs, Level 2 | Money market funds | | |
Assets | | |
Total assets measured at estimated fair value | 0 | 0 |
Recurring basis | Significant Unobservable Inputs, Level 3 | | |
Assets | | |
Total assets measured at estimated fair value | 0 | 0 |
Recurring basis | Significant Unobservable Inputs, Level 3 | U.S. government securities | | |
Assets | | |
Total assets measured at estimated fair value | | 0 |
Recurring basis | Significant Unobservable Inputs, Level 3 | U.S. government agencies | | |
Assets | | |
Total assets measured at estimated fair value | | 0 |
Recurring basis | Significant Unobservable Inputs, Level 3 | U.S. corporate notes | | |
Assets | | |
Total assets measured at estimated fair value | 0 | 0 |
Recurring basis | Significant Unobservable Inputs, Level 3 | U.S. commercial papers | | |
Assets | | |
Total assets measured at estimated fair value | 0 | 0 |
Recurring basis | Significant Unobservable Inputs, Level 3 | Money market funds | | |
Assets | | |
Total assets measured at estimated fair value | 0 | 0 |
Nonrecurring basis | Debt Securities | | |
Liabilities | | |
Term B Loan | 123,750 | 243,750 |
2023 Notes | 226,525 | 241,259 |
2025 Notes | 202,146 | 205,975 |
Total fair value of liabilities | 552,421 | 690,984 |
Nonrecurring basis | Quoted Prices in Active Markets for Identical Assets, Level 1 | Debt Securities | | |
Liabilities | | |
Term B Loan | 0 | 0 |
2023 Notes | 0 | 0 |
2025 Notes | 0 | 0 |
Total fair value of liabilities | 0 | 0 |
Nonrecurring basis | Significant Other Observable Inputs, Level 2 | Debt Securities | | |
Liabilities | | |
Term B Loan | 123,750 | 243,750 |
2023 Notes | 226,525 | 241,259 |
2025 Notes | 202,146 | 205,975 |
Total fair value of liabilities | 552,421 | 690,984 |
Nonrecurring basis | Significant Unobservable Inputs, Level 3 | Debt Securities | | |
Liabilities | | |
Term B Loan | 0 | 0 |
2023 Notes | 0 | 0 |
2025 Notes | 0 | 0 |
Total fair value of liabilities | $ 0 | $ 0 |