<!-- templates/participants/results.html -->
{% extends "base.html" %}
{% block title %}Resultados · Trafoking{% endblock %}
{% block content %}

<h2 class="text-3xl font-bold mb-8 text-[color:var(--brand-yellow)]">Ranking</h2>

<table class="hero-appear">
  <thead><tr><th>#</th><th>Grupo</th><th>Puntuación</th></tr></thead>
  <tbody>
    {% for p in participants %}
      <tr class="text-center">
        <td>{{forloop.counter}}</td>
        <td class="font-semibold">{{p.group_name}}</td>
        <td>{{p.score|floatformat:2}}</td>
      </tr>
    {% empty %}
      <tr><td colspan="3">Sin participantes todavía.</td></tr>
    {% endfor %}
  </tbody>
</table>

<a href="{% url 'participant_new' %}" class="btn btn-primary mt-10">
  Añadir más grupos
</a>

{% endblock %}
