Feature: Weekly digest email As an author I want weekly emails with real stats So that I trust the platform analytics Scenario: Digest uses session count not zeros Given an author has chat sessions in the last 7 days When the weekly digest is generated Then chat_count must be greater than zero Feature: Link click funnel As an author I want link clicks counted in the funnel So that conversion metrics are accurate Scenario: Track click writes analytics event Given a visitor clicks a purchase link When track-click is called Then an AnalyticsEvent with link_clicked is recorded Feature: Book lifecycle As an author I want to deactivate books So that inactive titles are excluded from RAG Scenario: Deactivated book excluded from retrieval Given a book is marked inactive When a visitor asks about that book Then RAG must not retrieve its chunks Feature: Auth token rotation As an author I want refresh tokens rotated on logout So that stolen tokens cannot be reused Scenario: Refresh after logout returns 401 Given an author logs out When they try to refresh with the old cookie Then the API returns 401 Feature: Q&A CSV import As an author I want HTML stripped from imported answers So that the widget is safe from XSS Scenario: Script tags removed on import Given a CSV row contains a script tag in the answer When the row is imported Then the stored answer has no script tags