Summary of Significant Accounting Policies | 2. Summary of Significant Accounting Policies Basis of Presentation —The consolidated financial statements have been prepared in U.S. dollars, in accordance with accounting principles generally accepted in the United States of America (“GAAP”). The accompanying consolidated financial statements include the accounts of the Company and its wholly owned subsidiaries. All intercompany transactions have been eliminated in consolidation. Use of Estimates —The preparation of consolidated financial statements in conformity with GAAP requires management to make estimates and assumptions that affect the reported amounts of assets and liabilities, disclosure of contingent assets and liabilities at the date of the financial statements, and the reported amounts of revenue and expenses during the reporting period. Actual results could differ from those estimates. Operating Segments —The Company operates as one operating segment. Operating segments are defined as components of an enterprise for which separate financial information is regularly evaluated by the chief operating decision makers (“CODMs”), which are the Company’s chief executive officer and chief operating officer, in deciding how to allocate resources and assess performance. The Company’s CODMs evaluate the Company’s financial information and resources and assess the performance of these resources on a consolidated basis. Since the Company operates in one operating segment, all required financial segment information can be found in the consolidated financial statements. Loss Per Share — Basic net loss per share is computed by dividing net loss by the weighted average number of common shares outstanding for the period. Diluted net loss per share is computed by giving effect to all potential dilutive common stock equivalents outstanding for the period. For purposes of this calculation, options to purchase common stock, restricted stock units (“RSUs”), the shares issuable under the Employee Stock Purchase Plan (“ESPP”), common stock warrants, and the Conversion Option of the 2022 Notes are considered to be potential common stock equivalents. A reconciliation of the denominator used in the calculation of basic and diluted loss per share is as follows: Year Ended December 31, 2018 2017 2016 (in thousands, except per share amounts) Net loss $ (63,828 ) $ (39,714 ) $ (45,562 ) Weighted-average common shares outstanding—basic 38,529 36,827 35,197 Dilutive effect of share equivalents resulting from stock options, RSUs, ESPP common stock warrants, and the Conversion Option of the 2022 Notes — — — Weighted-average common shares outstanding-diluted 38,529 36,827 35,197 Net loss per common share, basic and diluted $ (1.66 ) $ (1.08 ) $ (1.29 ) Since the Company incurred net losses for each of the periods presented, diluted net loss per share is the same as basic net loss per share. The Company’s outstanding stock options, RSUs, shares issuable under the ESPP, common stock warrants, and Conversion Option of the 2022 Notes were not included in the calculation of diluted net loss per share as the effect would be anti-dilutive. The following table contains all potentially dilutive common stock equivalents. Year Ended December 31, 2018 2017 2016 (in thousands) Options to purchase common shares 1,824 2,085 2,709 RSUs 1,732 2,315 2,264 Conversion option of the 2022 Notes 967 — — Common stock warrants 244 — — ESPP — 10 11 The Company expects to settle the principal amount of the 2022 Notes (Note 7) in cash, and therefore, the Company uses the treasury stock method for calculating any potential dilutive effect of the Conversion Option on diluted net income per share, if applicable. The Conversion Option will have a dilutive impact on net income per share when the average market price of the Company’s common stock for a given period exceeds the conversion price of the 2022 Notes of $94.77 per share. As of February 8, 2019, no holders have converted or indicated their intention to convert the 2022 Notes. Cash and Cash Equivalents —The Company considers all highly liquid investments purchased with original maturity of three months or less to be cash equivalents. Cash and cash equivalents consist of cash held in bank deposit accounts and short-term, highly-liquid investments with remaining maturities of three months or less at the date of purchase, consisting of money-market funds. Investments — Investments consist of corporate debt securities and U.S. Treasury securities. Securities having remaining maturities of more than three months at the date of purchase and less than one year from the date of the balance sheets are classified as short-term, and those with maturities of more than one year from the date of the balance sheet are classified as long-term in the consolidated balance sheets. The Company classifies its debt investments with readily determinable market values as available-for-sale. These investments are classified as investments on the consolidated balance sheets and are carried at fair market value, with unrealized gains and losses considered to be temporary in nature reported as accumulated other comprehensive loss, a separate component of stockholders’ equity. The Company reviews all investments for reductions in fair value that are other-than-temporary. When such reductions occur, the cost of the investment is adjusted to fair value through recording a loss on investments in the consolidated statements of operations. Gains and losses on investments are calculated on the basis of specific identification. Investments are considered to be impaired when a decline in fair value below cost basis is determined to be other-than-temporary. The Company periodically evaluates whether a decline in fair value below cost basis is other-than-temporary by considering available evidence regarding these investments including, among other factors: the duration of the period that, and extent to which, the fair value is less than cost basis; the financial health of, and business outlook for the issuer, including industry and sector performance and operational and financing cash flow factors; overall market conditions and trends and the Company’s intent and ability to retain its investment in the security for a period of time sufficient to allow for an anticipated recovery in market value. Once a decline in fair value is determined to be other-than-temporary, a write-down is recorded and a new cost basis in the security is established. Strategic investments — Strategic investments consist of non-controlling equity investments in privately held companies. These investments without readily determinable fair values for which the Company does not have the ability to exercise significant influence are accounted for using the measurement alternative. Under the measurement alternative, the non-marketable securities are carried at cost less any impairments, plus or minus adjustments resulting from observable price changes in orderly transactions for identical or similar investments of the same issuer. Accounts Receivable and Allowance for Doubtful Accounts —Accounts receivable are carried at the original invoiced amount less an allowance for doubtful accounts based on the probability of future collection. When management becomes aware of circumstances that may decrease the likelihood of collection to a point where a receivable is no longer probable of being collected, it records an allowance against amounts due, which reduces the receivable to the amount that management reasonably believes will be collected. For all other customers, management determines the adequacy of the allowance based on historical loss patterns, the number of days that billings are past due and an evaluation of the potential risk of loss associated with specific accounts. To date, losses resulting from uncollected receivables have not exceeded management’s expectations. The following is a roll forward of the Company’s allowance for doubtful accounts (in thousands): Balance Beginning of Period Charged to Statement of Operations Deductions (1) Balance at End of Period Allowance for doubtful accounts Year ended December 31, 2018 $ 638 $ 5,514 $ (4,835 ) $ 1,317 Year ended December 31, 2017 $ 617 $ 3,353 $ (3,332 ) $ 638 Year ended December 31, 2016 $ 371 $ 2,517 $ (2,271 ) $ 617 (1) Deductions include actual accounts written-off, net of recoveries. Restricted Cash —The Company had restricted cash of $5.6 million at December 31, 2018 and $5.1 million at December 31, 2017 related to letters of credit for it leased facilities. The following table provides a reconciliation of the cash, cash equivalents and restricted cash within the consolidated balance sheets that sum to the total of the same such amounts shown in the statement of cash flows for the year ended December 31, 2018 and 2017. December 31, 2018 December 31, 2017 (in thousands) Cash and cash equivalents $ 111,489 $ 87,680 Restricted cash 5,175 4,757 Restricted cash, included in other assets 450 347 Total cash, cash equivalents, and restricted cash $ 117,114 $ 92,784 Property and Equipment —Property and equipment are stated at cost and depreciated using the straight-line method over the estimated useful lives of the related assets. Expenditures for maintenance and repairs are charged to expense as incurred, whereas major betterments are capitalized as additions to leasehold improvements. Depreciation is recorded over the following estimated useful lives: Estimated Useful Life Employee related computer equipment 2 -3 years Computer equipment and purchased software 3 years Office equipment 5 years Furniture and fixtures 5 years Internal use software 5 years Leasehold improvements Lesser of lease Internal use software The Company capitalizes certain payroll and stock compensation costs incurred to develop functionality for certain of the Company’s internally built software platforms. The costs incurred during the preliminary stages of development are expensed as incurred. Once a piece of incremental functionality has reached the development stage certain internal costs are capitalized until the functionality is ready for its intended use. Internal use software is included within property and equipment on the balance sheet. The costs are generally amortized on a straight-line basis over an estimated useful life of approximately five years. Asset Retirement Obligations — The Company recognizes Assets Retirement Obligations (“AROs”) for any significant lease restoration obligation, if required by a lease agreement. The fair values of these AROs are recorded on a discounted basis, at the time the obligation is incurred, and accreted over time for the change in present value. Additionally, the Company capitalizes asset retirement costs by increasing the carrying amount of the related long-lived assets and depreciating these assets over their remaining useful life. The changes in these obligations during the year ending December 31, 2018 and December 31, 2017 are as follows: Year Ended December 31, 2018 2017 (in thousands) Beginning balance $ 1,191 $ 591 Additions 459 580 Accretion 92 46 Settlements — (26 ) Updates to estimated cash flows (318 ) — Ending balance $ 1,424 $ 1,191 Impairment of Long-Lived Assets —Long-lived assets are reviewed for impairment whenever events or changes in circumstances indicate that the carrying amount of the asset may not be recoverable or that the useful lives of those assets are no longer appropriate. Management considers the following potential indicators of impairment of its long-lived assets (asset group): a substantial decrease in the Company’s stock price, a significant adverse change in the extent or manner in which a long-lived asset (asset group) is being used, a significant adverse change in legal factors or in the business climate that could affect the value of the long-lived asset (asset group), an accumulation of costs significantly in excess of the amount originally expected for the acquisition or construction of a long-lived asset (asset group), and a current expectation that, more likely than not, a long lived asset (asset group) will be sold or otherwise disposed of significantly before the end of its previously estimated useful life. When such events occur, the Company compares the carrying amounts of the assets to their undiscounted expected future cash flows. If this comparison indicates that there may be an impairment, the amount of the impairment is calculated as the difference between the carrying value and fair value. For the years presented, the Company did not recognize an impairment charge. Intangible Assets — Intangible assets consist of acquired technology. We record acquired intangible assets at fair value on the date of acquisition. and amortize such assets using the straight-line method over the expected useful life of the asset. The estimated useful life of acquired technology is two to three years. The Company evaluates the useful lives of these assets on an annual basis and tests for impairment whenever events or changes in circumstances occur that could impact the recoverability of these assets. If the estimate of an intangible asset’s remaining useful life is changed, we amortize the remaining carrying value of the intangible asset prospectively over the revised remaining useful life. Goodwill —Goodwill represents the excess of cost over the fair value of the net tangible and identifiable intangible assets acquired in a business combination. The Company has no other intangible assets with indefinite useful lives. Goodwill is not subject to amortization but is monitored annually for impairment or more frequently if there are indicators of impairment. Management considers the following potential indicators of impairment: significant underperformance relative to historical or projected future operating results, significant changes in the Company’s use of acquired assets or the strategy of the Company’s overall business, significant negative industry or economic trends and a significant decline in the Company’s stock price for a sustained period. The Company performs its annual impairment test on November 30. Currently, the Company’s goodwill is evaluated at the entity level as it is determined there is only one reporting unit. When assessing goodwill for impairment the Company first performs a qualitative assessment to determine whether it is necessary to perform the two-step quantitative analysis. If the Company determines it is unlikely that our reporting unit fair value was less than its carrying value then no two-step impairment test is performed. If the Company can not make a determination based on the qualitative assessment then the Company performs a two-step impairment test. Based on the qualitive assessment performed on November 30, 2018, the Company determined it was unlikely that our reporting unit fair value was less than its carrying value and no two-step impairment test was required. There were no indicators that the Company’s goodwill had become impaired since that date, and as such, there was no impairment of goodwill as of November 30, 2018 or December 31, 2018. For the years ended December 31, 2018, 2017 and 2016, the Company did not recognize an impairment charge. Advertising Expense —The Company expenses advertising as incurred, which is included in sales and marketing expense in the accompanying consolidated statements of operations. The Company incurred $8.4 million of advertising expense in 2018, $5.5 million in 2017, and $4.2 million in 2016. Revenue Recognition — The Company generates revenue from arrangements with multiple performance obligations, which typically include subscriptions to its online software products and professional services which include on-boarding and training services. The Company’s customers do not have the right to take possession of the online software products. The Company recognizes revenue from contracts with customers using a five-step model, which is described below: • Identify the customer contract; • Identify performance obligations that are distinct; • Determine the transaction price; • Allocate the transaction price to the distinct performance obligations; and • Recognize revenue as the performance obligations are satisfied. Identify the customer contract A customer contract is generally identified when the Company and a customer have executed an arrangement that calls for the Company to grant access to its online software products and provide professional services in exchange for consideration from the customer. Identify performance obligations that are distinct A performance obligation is a promise to provide a distinct good or service or a series of distinct goods or services. A good or service that is promised to a customer is distinct if the customer can benefit from the good or service either on its own or together with other resources that are readily available to the customer, and a company’s promise to transfer the good or service to the customer is separately identifiable from other promises in the contract. The Company has determined that subscriptions for its online software products are distinct because, once a customer has access to the online software product that it purchased, the online software product is fully functional and does not require any additional development, modification, or customization. Professional services sold are distinct because the customer benefits from the on-boarding and training to make better use of the online software products it purchased. Determine the transaction price The transaction price is the amount of consideration to which the Company expects to be entitled in exchange for transferring goods or services to a customer, excluding sales taxes that are collected on behalf of government agencies. The Company estimates any variable consideration to which it will be entitled at contract inception, and reassesses at each reporting date, when determining the transaction price. The Company does not include variable consideration to the extent that it is probable that a significant reversal in the amount of cumulative revenue recognized will occur when any uncertainty associated with the variable consideration is resolved. Allocate the transaction price to the distinct performance obligations The transaction price is allocated to each performance obligation based on the relative standalone selling prices (“SSP”) of the goods or services being provided to the customer. The Company determines the SSP of its goods and services based upon the average sales prices for each type of online software product and professional services sold. In instances where there are not sufficient data points, or the selling prices for a particular online software product or professional service are disparate, the Company estimates the SSP using other observable inputs, such as similar products or services. Recognize revenue as the performance obligations are satisfied Revenues are recognized when or as control of the promised goods or services is transferred to customers. Revenue from online software products Disaggregation of Revenue The Company provides disaggregation of revenue based on geographic region (Note 8) and based on the subscription versus professional services and other classification on the consolidated statements of operations as it believes these best depict how the nature, amount, timing and uncertainty of revenue and cash flows are affected by economic factors Deferred Revenue, Deferred Commission Expense, and Accrued Expenses and Other Current Liabilities Amounts that have been invoiced are recorded in accounts receivable and deferred revenue or revenue, depending on whether the revenue recognition criteria have been met. Deferred revenue represents amounts billed for which revenue has not yet been recognized. Deferred revenue that will be recognized during the succeeding 12-month period is recorded as current deferred revenue, and the remaining portion is recorded as long-term deferred revenue. Deferred revenue during the year ended December 31, 2018 increased by $46.3 million resulting from $559.3 million of additional invoicing and was offset by revenue recognized of $513.0 million during the same period. $138.1million of revenue was recognized during the year ended December 31, 2018 that was included in deferred revenue at the beginning of the period. As of December 31, 2018, approximately $126.4 million of revenue is expected to be recognized from remaining performance obligations for contracts with original performance obligations that exceed one year. The Company expects to recognize revenue on approximately 94% of these remaining performance obligations over the next 24 months, with the balance recognized thereafter. Additional contract liabilities $1.6 million and $1.0 million were included in accrued expenses and other current liabilities on the consolidated balance sheet for the years ended December 31, 2018 and December 31, 2017. The incremental direct costs of obtaining a contract, which primarily consist of sales commissions paid for new subscription contracts, are deferred and amortized on a straight-line basis over a period of approximately one to three years. The one to three-year period has been determined by taking into consideration the type of product sold, the commitment term of the customer contract, the nature of the Company’s technology development life-cycle, and an estimated customer relationship period. Sales commissions for upgrade contracts are deferred and amortized on a straight-line basis over the remaining estimated customer relationship period of the related customer. Deferred commission expense that will be recorded as expense during the succeeding 12-month period is recorded as current deferred commission expense, and the remaining portion is recorded as long-term deferred commission expense. Deferred commission expense during the year ended December 31, 2018 increased by $22.9 million as a result of deferring incremental costs of obtaining a contract of $42.9 million and was offset by amortization of $20.0 million during the same period. Partner Commissions The Company pays its partners a commission based on the sales price for the subscription purchased. The classification of the commission paid on the Company’s consolidated statements of operations depends on who purchases the subscription. In instances where the end-customer purchases from the Company, the Company is the principal and it records the commission paid to the partner as sales and marketing expense. When the partner purchases directly from the Company (on behalf of an end-customer), the Company is the agent and it nets the consideration paid to the partner against the associated revenue it recognizes, as in these instances the Company’s customer is the partner and the Company’s remaining obligation is to the partner. The Company does not believe that it receives a tangible benefit from the commission payment to the partner. Concentrations of Credit Risk and Significant Customers —Financial instruments that potentially expose the Company to concentrations of credit risk consist primarily of cash, investments and accounts receivable. A significant portion of the Company’s cash and cash equivalents is held at four financial institutions that management believes to be of high credit quality. Although the Company deposits it cash and cash equivalents with multiple financial institutions, its deposits exceed federally insured limits. The Company’s investments consist of highly rated corporate debt securities and U.S. Treasury securities . The Company limits the amount of investments in any single issuer, except U.S. Treasuries. The Company believes that, as of December 31, 2018, its concentration of credit risk related to investments was not significant. The Company has no significant off-balance sheet risk such as foreign exchange contracts, option contracts, or other hedging arrangements. The Company generally does not require collateral from its customers and generally requires payment 30 days from the invoice date. The Company maintains an allowance for doubtful accounts based on its assessment of the collectability of accounts receivable. Credit risk arising from accounts receivable is mitigated as a result of transacting with a large number of geographically dispersed customers spread across various industries. At December 31, 2018 and 2017 there were no customers that represented more than 10% of the net accounts receivable balance. There were no customers that individually exceeded 10% of the Company’s revenue in any of the periods presented. Foreign Currency —The functional currency of the Company’s foreign subsidiaries is the local currency. Assets and liabilities denominated in a foreign currency are translated into U.S. dollars at the exchange rates in effect at the balance sheet dates; with the resulting translation adjustments directly recorded to a separate component of accumulated other comprehensive loss. Income and expense accounts are translated at the weighted-average exchange rates during the period. Foreign currency transaction gains and losses are recorded in other expense. Research and Development —Research and development expenses include payroll, employee benefits and other expenses associated with product development. Capitalized Software Development Costs —Certain payroll and stock compensation costs incurred to develop functionality for the Company’s software and internally built software platforms, as well as certain upgrades and enhancements that are expected to result in increased functionality are capitalized. The costs incurred in the preliminary stages of development are expensed as incurred. Once an application has reached the development stage, certain internal costs are capitalized until the software is substantially complete and ready for its intended use. Capitalized software development costs are amortized on a straight-line basis over their estimated useful life of two to five years. Management evaluates the useful lives of these assets on a quarterly basis and tests for impairment whenever events or changes in circumstances occur that could impact the recoverability of these assets. Capitalized software development costs, exclusive of those costs recorded within property and equipment, consisted of the following: December 31, 2018 December 31, (in thousands) Gross capitalized software development costs $ 46,169 $ 33,360 Accumulated amortization (33,423 ) (24,600 ) Capitalized software development costs, net $ 12,746 $ 8,760 The Company capitalized software development costs, exclusive of costs recorded within property and equipment, of $12.8 million in 2018, $8.2 million in 2017, and $6.4 million in 2016. Stock-based compensation costs included in capitalized software were $2.4 million in 2018, $1.6 million in 2017, and $1.2 million in 2016. Amortization of capitalized software development costs, exclusive of costs recorded within property and equipment, was $9.2 million in 2018, $6.3 million in 2017, and $5.1 million in 2016. Amortization expense is included in cost of revenue in the consolidated statements of operations. Income Taxes —Deferred tax assets and liabilities are recognized for the differences between the financial statement carrying amounts and the tax bases of existing assets and liabilities using tax rates expected to be in effect in the years in which the differences are expected to reverse. Deferred tax assets are reduced by a valuation allowance if it is more likely than not that some portion or all of the deferred tax assets will not be realized. Accounting for uncertainty in income taxes recognized in the financial statements is in accordance with accounting authoritative guidance, which prescribes a two-step process to determine the amount of tax benefit to be recognized. First, the tax position must be evaluated to determine the likelihood that it will be sustained upon external examination. If the tax position is deemed “more-likely-than-not” to be sustained, the tax position is then assessed to determine the amount of benefit to recognize in the financial statements. The amount of the benefit that may be recognized is the largest amount that has a greater than 50 percent likelihood of being realized upon ultimate settlement. Stock-Based Compensation — The Company accounts for all stock options and awards granted to employees and nonemployees using a fair value method. Stock-based compensation is recognized as an expense and is measured at the fair value of the award. The measurement date for awards is generally the date of the grant. Stock-based compensation costs are recognized as expense over the requisite service period, which is generally the vesting period for awards, on a straight-line basis for awards with only a service condition, and using the graded-method for awards with both a performance and service that were granted prior to our IPO, and on a straight-line basis for the awards that were granted following our IPO, which only have service conditions. Recent Accounting Pronouncements — Recent accounting standards not included below are not expected to have a material impact on our consolidated financial position and results of operations. Recent Accounting Pronouncements Adopted in 2018: In November 2016, the Financial Accounting Standards Board (“FASB”) issued guidance related to the presentation of restricted cash within the statement of cash flows. The guidance requires entities to show the changes in cash, cash equivalents, and restricted cash in the statement of cash flows. Entities will no longer present transfers between cash and cash equivalents and restricted cash in the statement of cash flows. The Company adopted the updated guidance as of January 1, 2018. As a result of adopting this guidance cash and cash equivalents used in investing activities increased by $521 thousand and net increase in cash, cash equivalents, and restricted cash also increased by $521 thousand for the year ended December 31, 2018. Cash and cash equivalents used in investing activities increased by $4.6 million and net increase in cash, cash equivalents, and restricted cash increased by $4.6 million for the year ended December 31, 2017 in the consolidated statements of cash flows. Cash and cash equivalents used in investing activities increased by $128 thousand and net increase in cash, cash equivalents, and restricted cash increased by $128 thousand for the year ended December 31, 2016 in the consolidated statements of cash flows. In January 2016, the FASB issued guidance that requires entities to measure equity instruments at fair value and recognize changes in fair value within the statement of operations. The Company adopted the updated guidance as of January 1, 2018. The guidance provides for electing a measurement alternative or defaulting to the fair value option for equity investments that do not have readily determinable fair values. The Company elected the measurement alternative for its equity investments in privately held companies, which are included in other assets in the accompanying consolidated balance sheets. These investments are measured at cost, less any impairment, plus or minus adjustments resulting from observable price changes in orderly transactions for the identical or a similar investment of the same issuer, which will be recorded within the statement of operations. The adoption of this guidance did not have a material impact on the consolidated financial statements. In May 2014, the FASB issued updated guidance and disclosure requirements for recognizing revenue. The new revenue recognition standard provides a five-step analysis of transactions to determine when and how revenue is recognized. The core principle is that a company should recognize revenue to depict the transfer of promised goods or services to customers in an amount that reflects the consideration to which the entity expects to be entitled in exchange for those goods or services. The standard also provides guidance on the recognition of costs related to obtaining customer contracts. The Company adopted the updated guidance as of January 1, 2018 using the modified retrospective transition method. Adoption of Updated Revenue Guidance On January 1, 2018, the Company adopted new revenue guidance using the modified retrospective method applied to those contracts which were not completed as of January 1, 2018. Results for reporting periods beginning after December 31, 2017 are presented under the new guidance, while prior period amounts are not adjusted and continue to be reported in accordan |