<?php

declare(strict_types=1);

require_once __DIR__ . '/layout.php';

function iav_welcome_email(string $displayName, string $dashboardUrl): string
{
    $safeName = htmlspecialchars($displayName, ENT_QUOTES | ENT_SUBSTITUTE, 'UTF-8');
    $body = "<p>Hello {$safeName},</p><p>Your Instant AI Virtuals account is ready. You can now access your dashboard and manage your profile.</p>";

    return iav_mail_layout('Welcome to Instant AI Virtuals', $body, 'Open dashboard', $dashboardUrl);
}
