{% extends "base.html" %} {% load custom_filters static time_filters %} {% block content %}
{% include "partials/info_box.html" %}

Drop Campaigns - {{ grouped_drops|length }} game{{ grouped_drops|length|pluralize }}

{% if grouped_drops %} {% for game, drops_list in grouped_drops.items %} {# Retain card structure for layout, replace table with list #}
{% if game and game.box_art_url %} {{ game.display_name|default:'Game name unknown' }} box art {% else %} {% if game %}{{ game.display_name }}{% else %}Unknown Game{% endif %} box art {% endif %}

{% if game %} {{ game.display_name|default:'Unknown Game' }} {% if game.slug %} - Twitch {% endif %} {% else %} Drops without an associated Game {% endif %}

{% if drops_list %}
    {% for drop in drops_list %}
  • {# Add margin between list items #} {{ drop.name|default:'Unknown Drop' }} (Requires {{ drop.required_minutes_watched|minutes_to_hours }})
    Campaign: {{ drop.campaign.name|truncatechars:40|default:'N/A' }} {# Adjusted truncate #} {% if drop.campaign.details_url != drop.campaign.account_link_url and drop.campaign.account_link_url %} | Link {% endif %}
    Ends in: {{ drop.campaign.end_at|timeuntil }} {% if drop.benefits.exists %}
    Benefits:
      {% for benefit in drop.benefits.all %}
    • {% if benefit.image_asset_url %} {{ benefit.name|default:'Unknown Benefit' }} {% endif %} {{ benefit.name|truncatechars:25|default:'Unknown Benefit' }} {# Wrap text in small #}
    • {% endfor %}
    {% endif %} {# Removed hr, using li margin instead #}
  • {% endfor %}
{% else %}

No active drops found for this game currently.

{% endif %}
{% empty %} {% endfor %} {% else %} {% endif %}
{% endblock content %}