style(mail): improve email contrast matching website dark aesthetic and remove postal address

This commit is contained in:
Philipp Urbschat 2026-09-12 23:49:03 +02:00
parent 3c78add335
commit 98cf8e6fda
Signed by: Phili
SSH key fingerprint: SHA256:ZSQWnldzrYiABzOV6vTICPe0h19pTpus7sCbm2S0po0

View file

@ -31,47 +31,67 @@ class MailService {
$subject = 'Persönliche Einladung zu philippurbschat.de';
$bodyHtml = '
<div style="background-color: #020617; color: #e2e8f0; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; padding: 40px 20px; text-align: center;">
<div style="max-width: 540px; margin: 0 auto; background-color: #0b1120; border: 1px solid #1e293b; border-radius: 20px; padding: 35px 30px; text-align: left; box-shadow: 0 10px 30px rgba(0,0,0,0.5);">
<div style="font-size: 20px; font-weight: bold; color: #f8fafc; margin-bottom: 25px; letter-spacing: -0.5px;">
<span style="color: #10b981;">_</span>PhilippUrbschat
</div>
$bodyHtml = '<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="color-scheme" content="dark">
<meta name="supported-color-schemes" content="dark">
</head>
<body style="margin: 0; padding: 0; background-color: #020617; font-family: -apple-system, BlinkMacSystemFont, \'Segoe UI\', Roboto, Helvetica, Arial, sans-serif;">
<table border="0" cellpadding="0" cellspacing="0" width="100%" bgcolor="#020617" style="background-color: #020617; width: 100%; padding: 40px 15px;">
<tr>
<td align="center">
<table border="0" cellpadding="0" cellspacing="0" width="100%" style="max-width: 540px; background-color: #0b1120; border: 1px solid #1e293b; border-radius: 24px; padding: 36px 32px; box-shadow: 0 10px 30px rgba(0,0,0,0.6);" bgcolor="#0b1120">
<tr>
<td style="padding-bottom: 24px;">
<span style="font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; font-size: 20px; font-weight: 800; color: #ffffff; letter-spacing: -0.5px;">
<span style="color: #10b981;">_</span>PhilippUrbschat
</span>
</td>
</tr>
<tr>
<td>
<p style="font-size: 15px; line-height: 1.6; color: #ffffff; margin: 0 0 16px 0;">
Hallo,
</p>
<p style="font-size: 15px; line-height: 1.6; color: #e2e8f0; margin: 0 0 18px 0;">
du wurdest eingeladen, dir einen persönlichen Zugang auf <strong style="color: #ffffff;">philippurbschat.de</strong> anzulegen.
</p>
<p style="font-size: 14px; line-height: 1.6; color: #cbd5e1; margin-bottom: 18px;">
Hallo,
</p>
' . (!empty($note) ? '
<div style="background-color: #020617; border: 1px solid #1e293b; border-left: 3px solid #06b6d4; padding: 12px 16px; margin: 18px 0; border-radius: 8px; font-size: 13px; color: #cbd5e1; line-height: 1.5;">
' . htmlspecialchars($note) . '
</div>' : '') . '
<p style="font-size: 14px; line-height: 1.6; color: #cbd5e1; margin-bottom: 18px;">
du wurdest eingeladen, dir einen persönlichen Zugang auf <strong>philippurbschat.de</strong> anzulegen.
</p>
<div style="background-color: #020617; border: 1px solid #1e293b; border-radius: 12px; padding: 16px 18px; margin: 22px 0;">
<div style="font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 10px; text-transform: uppercase; letter-spacing: 1.5px; color: #94a3b8; margin-bottom: 6px;">Freigeschaltete Module:</div>
<div style="font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; font-weight: bold; color: #34d399;">' . htmlspecialchars($modulesText) . '</div>
</div>
' . (!empty($note) ? '
<div style="background-color: #020617; border-left: 3px solid #06b6d4; padding: 12px 16px; margin: 20px 0; border-radius: 4px; font-size: 13px; color: #94a3b8;">
' . htmlspecialchars($note) . '
</div>' : '') . '
<table border="0" cellspacing="0" cellpadding="0" style="margin: 28px auto 24px auto;">
<tr>
<td align="center" style="background-color: #020617; border: 2px solid #10b981; border-radius: 12px;">
<a href="' . htmlspecialchars($registerUrl) . '" target="_blank" style="display: inline-block; padding: 14px 28px; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; font-size: 13px; font-weight: 800; color: #34d399 !important; text-decoration: none !important; letter-spacing: 0.08em; text-transform: uppercase;">
<span style="color: #34d399; font-weight: 800;">Jetzt Account erstellen </span>
</a>
</td>
</tr>
</table>
<div style="background-color: #020617; border: 1px solid #1e293b; border-radius: 12px; padding: 16px; margin: 24px 0;">
<div style="font-size: 11px; text-transform: uppercase; letter-spacing: 1.5px; color: #64748b; margin-bottom: 6px;">Freigeschaltete Module:</div>
<div style="font-size: 13px; font-weight: bold; color: #10b981;">' . htmlspecialchars($modulesText) . '</div>
</div>
<div style="text-align: center; margin: 32px 0;">
<a href="' . htmlspecialchars($registerUrl) . '" style="display: inline-block; background-color: #10b981; color: #020617; font-weight: bold; text-decoration: none; padding: 14px 28px; border-radius: 12px; font-size: 14px; letter-spacing: 0.5px; text-transform: uppercase;">
Jetzt Account erstellen
</a>
</div>
<p style="font-size: 12px; line-height: 1.6; color: #64748b; margin-top: 30px; word-break: break-all;">
Falls der Button nicht funktioniert, kopiere bitte diesen Link in deinen Browser:<br>
<a href="' . htmlspecialchars($registerUrl) . '" style="color: #06b6d4; text-decoration: underline;">' . htmlspecialchars($registerUrl) . '</a>
</p>
</div>
<div style="max-width: 540px; margin: 20px auto 0; font-size: 11px; color: #475569; text-align: center;">
philippurbschat.de · Leopoldstr. 32 · 32756 Detmold
</div>
</div>';
<p style="font-size: 12px; line-height: 1.6; color: #94a3b8; margin-top: 24px; word-break: break-all;">
Falls der Button nicht funktioniert, kopiere bitte diesen Link in deinen Browser:<br>
<a href="' . htmlspecialchars($registerUrl) . '" style="color: #38bdf8; text-decoration: underline; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11px;">' . htmlspecialchars($registerUrl) . '</a>
</p>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>';
$bodyText = "Hallo,\n\n"
. "du wurdest eingeladen, dir einen persönlichen Zugang auf philippurbschat.de anzulegen.\n\n"
@ -93,45 +113,65 @@ class MailService {
$subject = 'Passwort zurücksetzen philippurbschat.de';
$bodyHtml = '
<div style="background-color: #020617; color: #e2e8f0; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; padding: 40px 20px; text-align: center;">
<div style="max-width: 540px; margin: 0 auto; background-color: #0b1120; border: 1px solid #1e293b; border-radius: 20px; padding: 35px 30px; text-align: left; box-shadow: 0 10px 30px rgba(0,0,0,0.5);">
<div style="font-size: 20px; font-weight: bold; color: #f8fafc; margin-bottom: 25px; letter-spacing: -0.5px;">
<span style="color: #06b6d4;">_</span>Passwort-Reset
</div>
$bodyHtml = '<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="color-scheme" content="dark">
<meta name="supported-color-schemes" content="dark">
</head>
<body style="margin: 0; padding: 0; background-color: #020617; font-family: -apple-system, BlinkMacSystemFont, \'Segoe UI\', Roboto, Helvetica, Arial, sans-serif;">
<table border="0" cellpadding="0" cellspacing="0" width="100%" bgcolor="#020617" style="background-color: #020617; width: 100%; padding: 40px 15px;">
<tr>
<td align="center">
<table border="0" cellpadding="0" cellspacing="0" width="100%" style="max-width: 540px; background-color: #0b1120; border: 1px solid #1e293b; border-radius: 24px; padding: 36px 32px; box-shadow: 0 10px 30px rgba(0,0,0,0.6);" bgcolor="#0b1120">
<tr>
<td style="padding-bottom: 24px;">
<span style="font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; font-size: 20px; font-weight: 800; color: #ffffff; letter-spacing: -0.5px;">
<span style="color: #22d3ee;">_</span>Passwort-Reset
</span>
</td>
</tr>
<tr>
<td>
<p style="font-size: 15px; line-height: 1.6; color: #ffffff; margin: 0 0 16px 0;">
Hallo,
</p>
<p style="font-size: 15px; line-height: 1.6; color: #e2e8f0; margin: 0 0 18px 0;">
wir haben eine Anfrage zum Zurücksetzen deines Passworts auf <strong style="color: #ffffff;">philippurbschat.de</strong> erhalten.
</p>
<p style="font-size: 14px; line-height: 1.6; color: #cbd5e1; margin-bottom: 18px;">
Hallo,
</p>
<table border="0" cellspacing="0" cellpadding="0" style="margin: 28px auto 24px auto;">
<tr>
<td align="center" style="background-color: #020617; border: 2px solid #06b6d4; border-radius: 12px;">
<a href="' . htmlspecialchars($resetUrl) . '" target="_blank" style="display: inline-block; padding: 14px 28px; font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace; font-size: 13px; font-weight: 800; color: #22d3ee !important; text-decoration: none !important; letter-spacing: 0.08em; text-transform: uppercase;">
<span style="color: #22d3ee; font-weight: 800;">Neues Passwort vergeben </span>
</a>
</td>
</tr>
</table>
<p style="font-size: 14px; line-height: 1.6; color: #cbd5e1; margin-bottom: 18px;">
wir haben eine Anfrage zum Zurücksetzen deines Passworts auf <strong>philippurbschat.de</strong> erhalten.
</p>
<div style="background-color: #020617; border: 1px solid #1e293b; border-left: 3px solid #06b6d4; border-radius: 8px; padding: 14px 16px; margin: 20px 0; font-size: 13px; color: #e2e8f0; line-height: 1.5;">
Dieser Link ist aus Sicherheitsgründen <strong style="color: #ffffff;">1 Stunde</strong> lang gültig.
</div>
<div style="text-align: center; margin: 32px 0;">
<a href="' . htmlspecialchars($resetUrl) . '" style="display: inline-block; background-color: #06b6d4; color: #020617; font-weight: bold; text-decoration: none; padding: 14px 28px; border-radius: 12px; font-size: 14px; letter-spacing: 0.5px; text-transform: uppercase;">
Neues Passwort vergeben
</a>
</div>
<p style="font-size: 12px; line-height: 1.6; color: #94a3b8; margin-top: 24px; word-break: break-all;">
Falls der Button nicht funktioniert, nutze bitte diesen Link:<br>
<a href="' . htmlspecialchars($resetUrl) . '" style="color: #38bdf8; text-decoration: underline; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11px;">' . htmlspecialchars($resetUrl) . '</a>
</p>
<p style="font-size: 12px; line-height: 1.6; color: #94a3b8; margin-bottom: 18px;">
Dieser Link ist aus Sicherheitsgründen <strong>1 Stunde</strong> lang gültig.
</p>
<p style="font-size: 12px; line-height: 1.6; color: #64748b; margin-top: 25px; word-break: break-all;">
Falls der Button nicht funktioniert, nutze bitte diesen Link:<br>
<a href="' . htmlspecialchars($resetUrl) . '" style="color: #06b6d4; text-decoration: underline;">' . htmlspecialchars($resetUrl) . '</a>
</p>
<p style="font-size: 11px; line-height: 1.6; color: #475569; margin-top: 25px; border-top: 1px solid #1e293b; padding-top: 15px;">
Wenn du diesen Reset nicht angefordert hast, kannst du diese Nachricht einfach ignorieren. Dein bisheriges Passwort bleibt unverändert gültig.
</p>
</div>
<div style="max-width: 540px; margin: 20px auto 0; font-size: 11px; color: #475569; text-align: center;">
philippurbschat.de · Leopoldstr. 32 · 32756 Detmold
</div>
</div>';
<p style="font-size: 11px; line-height: 1.6; color: #64748b; margin-top: 22px; border-top: 1px solid #1e293b; padding-top: 16px;">
Wenn du diesen Reset nicht angefordert hast, kannst du diese Nachricht einfach ignorieren. Dein bisheriges Passwort bleibt unverändert gültig.
</p>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>';
$bodyText = "Hallo,\n\n"
. "wir haben eine Anfrage zum Zurücksetzen deines Passworts auf philippurbschat.de erhalten.\n\n"