<div class="article-card" data-url="{{ SITEURL }}/{{ article.url }}"
     title="Read {{ article.title|striptags }}">

  <div class="article-card__header">
    <div class="article-card__title">
      {{ article.title }}
    </div>
  </div>

  <div class="article-card-meta">
    <div class="article-card-meta__item">
      <span class="article-card-meta__value" title="{{ article.date.isoformat() }}">
        {{ article.date.strftime('%B %d, %Y') }}
      </span>
    </div>

    {% if article.authors or article.author %}
    <span class="article-card-meta__separator">•</span>
    <div class="article-card-meta__item">
      <span class="article-card-meta__value">
        {% if article.authors %}
          {% for author in article.authors %}
            {% set author_name = AUTHOR_NAMES.get(author|string|trim, author|string|trim) %}
            {% set author_url = AUTHOR_URLS.get(author|string|trim) %}
            {% if author_url %}<a href="{{ author_url }}">{{ author_name }}</a>{% else %}{{ author_name }}{% endif %}{% if not loop.last %}{% if loop.revindex == 2 %}{% if loop.length > 2 %}, and {% else %} and {% endif %}{% else %}, {% endif %}{% endif %}
          {% endfor %}
        {% else %}
          {% set author_name = AUTHOR_NAMES.get(article.author, article.author) %}
          {% set author_url = AUTHOR_URLS.get(article.author) %}
          {% if author_url %}
          <a href="{{ author_url }}">{{ author_name }}</a>
          {% else %}
          {{ author_name }}
          {% endif %}
        {% endif %}
      </span>
    </div>
    {% endif %}
  </div>

  <div class="article-card__content">
    {{ article.summary }}
  </div>

</div>
