{% for project in mediaProjects %}
  <h1>{{ project.title }}</h1>

  {{ project.article | md | safe }}

  <section
    id="media"
    class="media"
  >
    {% for medium in project.media %}
      <h2>{{ medium.title }}</h2>

      {% if medium.id %}
        <figure class="media-iframe-parent">
          <iframe
            class="media-iframe"
            src="https://www.youtube.com/embed/{{ medium.id }}"
            title="YouTube video player"
            frameborder="0"
            allow="autoplay; clipboard-write; encrypted-media; picture-in-picture"
            allowfullscreen
          ></iframe>
        </figure>
      {% elif medium.src %}
        <video class="media-video" controls>
          <source src="{{ medium.src }}" type="video/mp4">
          Dein Browser unterstützt leider keine Videos
        </video>
      {% endif %}
    {% endfor %}
  </section>

{% endfor %}
