{% extends 'base.html' %}
{% load static %}

{% block title %}Add Client - webFirma{% endblock %}

{% block content %}
<div class="container mt-5">
    <div class="row justify-content-center">
        <div class="col-md-8">
            <div class="card shadow-sm">
                <div class="card-header bg-primary text-white">
                    <h4 class="mb-0">Create a New Client</h4>
                </div>
                <div class="card-body">
                    <form method="post">
                        {% csrf_token %}
                        <div class="form-floating mb-3">
                            {{ form.name }}
                            <label for="{{ form.name.id_for_label }}">Name</label>
                        </div>
                        <div class="form-floating mb-3">
                            {{ form.email }}
                            <label for="{{ form.email.id_for_label }}">Email</label>
                        </div>
                        <div class="form-floating mb-3">
                            {{ form.phone }}
                            <label for="{{ form.phone.id_for_label }}">Phone</label>
                        </div>
                        <div class="d-flex justify-content-end">
                            <a href="{% url 'clients' %}" class="btn btn-secondary me-2">Cancel</a>
                            <button type="submit" class="btn btn-primary">Save Client</button>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
</div>
<style>
    .form-floating .form-control {
        height: calc(3.5rem + 2px);
        padding: 1rem;
    }
    .form-floating > label {
        padding: 1rem;
    }
</style>
{% endblock %}