Flush a buffered markdown table as a column-aligned block. Computes the
max display width per column, pads every cell accordingly, renders with
│/┼/─ box chars in muted gray. Inline markdown inside cells is
honoured.
Width-aware variant. When max_width > 0 and the table can’t fit at its
natural column widths, fall back to a flat key/value record format
(header: cell per line, blank line between rows) so no information is
lost to per-cell truncation. max_width = 0 keeps box-table rendering
at natural widths regardless of size.
Render one complete line with block- and inline-level markdown applied.
Returns None if the line should be omitted from output (e.g., a fence
marker ``` that toggles code-block state but isn’t itself visible text).
Width-aware variant of render_line. When max_width > 0, a flushed
table’s column widths are capped so every line fits the budget — otherwise
wrap_cells_to_width downstream chops long rows and shatters the table’s
border structure. max_width = 0 keeps legacy behaviour.