{#
Copyright 2024, 2025 New Vector Ltd.
Copyright 2021-2024 The Matrix.org Foundation C.I.C.

SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial
Please see LICENSE files in the repository root for full details.
-#}

{% extends "base.html" %}

{% block content %}
  <main class="flex flex-col justify-center gap-6">
    <header class="page-heading">
      <div class="header">
        <h1 class="title">{{ _("app.human_name") }}</h1>
        <p class="text">
          {{ _("app.technical_description", discovery_url=discovery_url) }}
        </p>
      </div>
    </header>

    {% if current_session %}
      <p class="cpd-text-body-md-regular">
        {{ _("mas.navbar.signed_in_as", username=current_session.user.username) }}
      </p>

      {{ button.link(text=_("mas.navbar.my_account"), href="/account/") }}
      {{ logout.button(text=_("action.sign_out"), csrf_token=csrf_token) }}
    {% else %}
      {{ button.link(text=_("action.sign_in"), href="/login") }}

      {% if features.password_registration %}
        {{ button.link_outline(text=_("mas.navbar.register"), href="/register") }}
      {% endif %}
    {% endif %}
  </main>
{% endblock content %}
