<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>{{subject}}</title>
    <style>
        body {
            font-family: Arial, sans-serif;
            margin: 0;
            padding: 0;
            background-color: #f4f4f4;
        }
        .container {
            width: 100%;
            max-width: 900px;
            margin: 0 auto;
            background-color: #ffffff;
            padding: 20px;
            box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
        }
        .header {
            display: flex;
            justify-content: space-between;
            align-items: center;
        }
        .header .left {
            text-align: left;
        }
        .header .left p {
            margin: 0;
            font-size: 14px;
            color: #666666;
        }
        .header .right img {
            max-height: 120px;
        }
        h1 {
            color: #0a71af;
            font-size: 18px;
        }
        p {
            color: #363636;
            font-size: 14px;
        }
        .footer {
            border-top: #ddd solid 1px;
            margin-top: 25px;
            font-size: 11px;
            text-align: center;
            text-decoration: none;
        }

        .footer p {
            color: #999999;
        }

        .footer a {
            color: #0a71af;
            text-decoration: none;
        }

        .footer a:hover {
            color: #999999;
            text-decoration: none;
        }

        table {
            width: 100%;
            border-collapse: collapse;
        }
        th, td {
            border: 1px solid #ddd;
            padding: 8px;
            text-align: left;
            font-size: 12px;
            color: #363636;
        }
        th {
            background-color: #f2f2f2;
        }
    </style>
</head>
<body>
    <div class="container">
        <div class="header">
            <div class="left">
                <h1>{{subject}}</h1>
                <p>Le {{date}}</p>
            </div>
            <div class="right">
                <img src="{{logo_url}}" alt="Logo">
            </div>
        </div>
        <p>Bonjour {{name}},</p>
        <p>{{message}}</p>

        <table>
            <thead>
                <tr>
                    <th>Date</th>
                    <th>Titre</th>
                    <th>Type</th>
                    <th>Echéance</th>
                    <th>Attribution</th>
                    <th>Montant</th>
                </tr>
            </thead>
            <tbody>
                {{table}}
            </tbody>
        </table>

        <p>Merci,</p>
        <p>L'équipe du CSE Invent</p>
        <div class="footer">
            <p>Cet email vous a été envoyé depuis le CMS d'Invent France.</p>
            <p><a href="{{cms_url}}">{{cms_url}}</a></p>
        </div>
    </div>
</body>
</html>
