{% if field.type == 'BooleanField' %}
{# Checkbox with Bootstrap 5 form-check structure #}
{{ field(class="form-check-input" + (" is-invalid" if field.errors else ""), disabled=disabled) }}
{{ field.label(class="form-check-label") }}
{% if field.errors %}
{% for error in field.errors %}
{{ error }}
{% endfor %}
{% endif %}
{% elif field.type == 'RadioField' %}
{# Radio buttons with Bootstrap 5 form-check structure #}
{{ field.label(class="form-label") }}
{% for subfield in field %}