<% if params[:restricted] %>
  <h3 class="heading"><%= t(".restricted.sorry") %></h3>
  <p>
    <%= t(".restricted.work_unavailable") %>
    <%= t(".restricted.account_exists") %>
    <% if AdminSetting.current.invite_from_queue_enabled? && AdminSetting.current.creation_requires_invite? %>
      <%= t(".restricted.no_account", request_invite_link: link_to(t(".restricted.request_invite"), invite_requests_path)).html_safe %>
    <% elsif AdminSetting.current.account_creation_enabled? && !AdminSetting.current.creation_requires_invite? %>
      <%= link_to t(".restricted.signup"), signup_path %>
    <% end %>
  </p>
<% elsif params[:restricted_commenting] %>
  <h3 class="heading"><%= t(".restricted.sorry") %></h3>
  <p>
    <%= t(".restricted.commenting_unavailable") %>
    <%= t(".restricted.account_exists") %>
    <% if AdminSetting.current.invite_from_queue_enabled? && AdminSetting.current.creation_requires_invite? %>
      <%= t(".restricted.no_account", request_invite_link: link_to(t(".restricted.request_invite"), invite_requests_path)).html_safe %>
    <% elsif AdminSetting.current.account_creation_enabled? && !AdminSetting.current.creation_requires_invite? %>
      <%= link_to t(".restricted.signup"), signup_path %>
    <% end %>
  </p>
<% else %>
  <h3 class="heading"><%= t(".login.log_in") %></h3>
  <p>
    <strong><%= t(".beta_reminder.reminder") %></strong>
    <%= t(".beta_reminder.warning") %>
    <%= t(".beta_reminder.report_bugs", give_feedback_link: link_to(t(".beta_reminder.give_feedback"), feedbacks_path)).html_safe %>
  </p>
<% end %>

<div id="loginform">
  <%= render "users/sessions/passwd" %>
</div>

<p>
  <%= t(".login.forgot", reset_password_link: link_to(t(".login.reset_password"), new_user_password_path)).html_safe %>
  <% if AdminSetting.current.invite_from_queue_enabled? && AdminSetting.current.creation_requires_invite? %>
    <br \><%= t(".login.no_account", join_link: link_to(t(".login.request_invite"), invite_requests_path)).html_safe %>
  <% elsif AdminSetting.current.account_creation_enabled? && !AdminSetting.current.creation_requires_invite? %>
    <br \><%= t(".login.no_account", join_link: link_to(t(".login.create_account"), signup_path)).html_safe %>
  <% end %>
</p>
