{% if current_person.signed_in? and course.enrolled? %}
  <script>
    window.location.replace('{% route course_viewer, course_id: course.id, learning_path_id: params.learning_path_id %}')
  </script>
{% else %}
  <main>
    {% include "course_green_card" %}
    {% if course.instructors and course.instructors.size > 0 %}
      {% include "course_instructor_card" %}
    {% endif %}
    {% include "course_outline" %}
    {% include "catalog_faq" %}
    {% include "course_recommended_courses" %}
    
    {% unless current_person.signed_in? %}
      {% assign banner_title = "<span class='lang-en'>How to get most out of Pipedrive?</span>
        <span class='lang-de'>Wie mache ich das meiste aus Pipedrive?</span>
        <span class='lang-es'>¿Cómo sacar el máximo provecho de Pipedrive?</span>
        <span class='lang-fr'>Comment tirer le maximum de Pipedrive ?</span>
        <span class='lang-br'>Como aproveitar o Pipedrive ao máximo?</span>"
      %}
      {% assign banner_text = "<span class='lang-en'>Welcome to Pipedrive Academy! Pipedrive Academy features CRM training videos and tutorials to help you level up your CRM and sales skills, from quick CRM courses to in-depth tutorials on specific features.</span>
        <span class='lang-de'>Willkommen bei der Pipedrive Academy! In der Pipedrive Academy finden Sie CRM-Schulungsvideos und -Lernprogramme, die Ihnen helfen, Ihre CRM- und Vertriebskenntnisse zu verbessern, von schnellen CRM-Kursen bis hin zu ausführlichen Lernprogrammen zu bestimmten Funktionen.</span>
        <span class='lang-es'>¡Bienvenido a la Academia Pipedrive! La Academia Pipedrive cuenta con videos y tutoriales de capacitación en CRM para ayudarte a subir de nivel en tus habilidades de CRM y ventas, desde cursos rápidos hasta tutoriales avanzados sobre funciones específicas.</span>
        <span class='lang-fr'>Bienvenue dans l'Académie de Pipedrive ! L'Académie de Pipedrive propose des vidéos de formation au CRM et des tutoriels pour améliorer vos compétences en vente et en relation client. Vous y trouverez aussi bien des leçons sur la GRC que des tutos approfondis sur des outils spécifiques. </span>
        <span class='lang-br'>Bem-vindo(a) à Academia do Pipedrive! A Academia do Pipedrive conta com vídeos de treinamento de CRM e tutoriais para ajudar você a melhorar suas habilidades de CRM e vendas. De cursos rápidos de CRM até tutoriais detalhados sobre recursos específicos, temos tudo aqui.</span>"
      %}
      {% assign banner_button_text = '<span class="lang-en">Start today</span>
        <span class="lang-de">Heute starten</span>
        <span class="lang-es">Empezar hoy mismo</span>
        <span class="lang-fr">Commencez dès aujourd&#39;hui</span>
        <span class="lang-br">Comece hoje mesmo</span>'
      %}
      {% assign banner_button_link = "#sso-widget" %}
      {% include "green_banner_text_bg_image" %}
    {% endunless %}
  </main>
  
  <script>
    addEventListener("DOMContentLoaded", () => {
      document.querySelector('#side-menu-courses')?.classList.add('side-menu-link-active');
      document.querySelector('.header-navigation-item[href="/app/catalog"]')?.classList.add('header-navigation-item-active');
    })
  </script>
{% endif %}
