I think it would help to analyze what happens with the ANSI codes emitted by the program. I’m pretty sure that r1Style.Render("Alice") etc. emit a reset code after the string and diagStyle only reverts the background to blue outside the box rendered by JoinVertical. I would also test what happens when you align right or center.
Anyway, how I’d try to fix it:
Pad the strings with spaces.
Use a lipgloss table instead of JoinVertical, styled with blue background and no borders.
You could also submit a lipgloss issue with this example. It is more intuitive to have transparent padding in JoinVertical, although in the light of my hypothesis above it may not be trivial to implement.
Notice for anyone who landed here with similar issue:
Reason why it does not work is because Lipgloss library is 2D only.
Stacking styles over other is simply not implemented. Logic for overlapping content is absent. If you plan to create dialog over dialogs TUI then you are either on your own or rather move elsewhere..