<div class="container mt-5">
    <div class="row justify-content-center">
        <div class="col-12 col-lg-10">
            <div class="card shadow-lg border-danger">
                <div class="card-header bg-danger text-white py-3">
                    <h3 class="mb-0 text-center">
                        <i class="bi bi-trash me-2"></i>Eliminar Grupo de Trabajo
                    </h3>
                </div>
                <div class="card-body p-4">
                    {% if messages %}
                        {% for message in messages %}
                            <div class="alert alert-{{ message.tags }} alert-dismissible fade show" role="alert">
                                {{ message }}
                                <button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
                            </div>
                        {% endfor %}
                    {% endif %}

                    <p>¿Estás seguro de que deseas eliminar al grupo <strong>{{ object.nombres }}</strong>?</p>
                    <form method="post" class="ajax-form">
                        {% csrf_token %}
                        <div class="text-end">
                            <button type="submit" class="btn btn-danger me-2">
                                <i class="bi bi-trash me-2"></i>Eliminar
                            </button>
                            <a href="{% url 'listar_subjefes' %}" class="btn btn-secondary async-link" data-url="{% url 'listar_subjefes' %}">
                                <i class="bi bi-x-circle me-2"></i>Cancelar
                            </a>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>