<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Deploy /etc/hosts File - {{ file.title }}</title>
    <style>
        body { font-family: Arial, sans-serif; background: #f1f1f1; padding: 20px; }
        .container { max-width: 600px; margin: 0 auto; background: #fff; padding: 20px; border-radius: 8px; box-shadow: 0 0 10px #ccc; }
        h1 { text-align: center; }
        form { margin-top: 20px; }
        .host-list { margin: 20px 0; }
        .host-item { margin-bottom: 10px; }
        button { padding: 10px 20px; background: #007bff; border: none; color: #fff; cursor: pointer; border-radius: 4px; display: block; margin: 0 auto; }
        button:hover { background: #0056b3; }
        .links { text-align: center; margin-top: 10px; }
        .links a { color: #007bff; text-decoration: none; }
        .links a:hover { text-decoration: underline; }
    </style>
</head>
<body>
<div class="container">
    <h1>Deploy "{{ file.title }}"</h1>
    <p>Select the hosts to which you want to deploy this file:</p>
    <form method="POST" action="">
        <div class="host-list">
            {% for host in hosts %}
            <div class="host-item">
                <label>
                    <input type="checkbox" name="hosts" value="{{ host.id }}"> {{ host.hostname }} ({{ host.type }})
                </label>
            </div>
            {% endfor %}
        </div>
        <button type="submit">Deploy</button>
    </form>
    <div class="links">
        <a href="{{ url_for('list_hosts_files') }}">Back to /etc/hosts Files</a>
    </div>
</div>
</body>
</html>