{{template "base" .}}

{{define "title"}}Mein Profil{{end}}

{{define "body"}}
<div class="page-header">
    <h1 class="page-title">Mein Profil</h1>
</div>

<div class="card" style="max-width:520px;">
    <div class="card-title">{{.User.Name}}{{if .User.AltName}} / {{.User.AltName}}{{end}}</div>
    <div style="margin-top:12px; display:flex; flex-direction:column; gap:8px; font-size:15px;">
        <div><span style="color:var(--text-muted);">E-Mail</span> &nbsp; {{.User.Email}}</div>
        <div><span style="color:var(--text-muted);">Telefon</span> &nbsp; {{.User.PhoneNumber}}</div>
        <div><span style="color:var(--text-muted);">Land</span> &nbsp; {{.User.Country}}</div>
        <div><span style="color:var(--text-muted);">Adresse</span> &nbsp; {{.User.Address}}</div>
        <div><span style="color:var(--text-muted);">Geburtsdatum</span> &nbsp; {{.User.DateOfBirth.Format "02.01.2006"}}</div>
        <div><span style="color:var(--text-muted);">Mitglied seit</span> &nbsp; {{.User.Created.Format "02.01.2006"}}</div>
    </div>

    <div style="margin-top:20px; border-top:1px solid var(--border); padding-top:16px;">
        <button class="btn btn--danger"
                hx-delete="/users/{{.User.ID}}"
                hx-confirm="Konto wirklich unwiderruflich löschen?">Konto löschen</button>
    </div>
</div>
{{end}}
