Feature: Public landing page
  As a first-time visitor
  I want a public welcome page before I log in
  So that I understand what Tapir is and how to get started without hitting a login wall

  Scenario: An unauthenticated visit to the root is sent to the welcome page
    Given I am not logged in
    When I open the root path "/"
    Then I am redirected to "/welcome"

  Scenario: The welcome page invites an unauthenticated visitor to start
    Given I am not logged in
    When I open "/welcome"
    Then I see a "Get Started" call to action

  Scenario: An authenticated user on the welcome page sees their way in and out
    Given I am logged in
    When I open "/welcome"
    Then I see a link to my summaries
    And I see a way to log out

  @pending
  # Behaviour ships (logout redirects to /welcome) but is not unit-tested: logout lives in
  # the OIDC Auth impl and StubAuth has no routes to exercise it cheaply.
  Scenario: Logging out returns to the welcome page
    Given I am logged in
    When I log out
    Then I am returned to "/welcome"

  # /welcome is mounted outside the auth guard so it is reachable without a session;
  # the root and all data routes stay behind it (commits around the WelcomePage work).
