{% form_theme form with app_form_themes() only %}

<div {{ attributes }}>
    {{ form_start(form, {
        attr: {
            class: 'mt-5 grid gap-4',
            'data-model': 'on(input)|*',
            'data-action': 'live#action:prevent',
            'data-live-action-param': 'submitResetPassword',
            novalidate: 'true'
        }
    }) }}
        <div class="grid gap-2">
            {{ form_label(form.plainPassword, null, {'label_attr': {'class': 'text-sm font-medium text-[#382d28]'}}) }}
            {{ form_widget(form.plainPassword, {'attr': {
                class: 'h-12 bg-white px-5 text-[#201917] placeholder:text-[#9f8b72] ring-1 ring-inset ring-[#e3d6c2] focus:ring-1 focus:ring-inset focus:ring-[#9d7c47]',
                'data-action': 'blur->live#action',
                'data-live-action-param': 'validatePasswords'
            }}) }}
            <div class="text-sm text-red-600">{{ form_errors(form.plainPassword) }}</div>
        </div>
        <div class="grid gap-2">
            {{ form_label(form.passwordConfirmation, null, {'label_attr': {'class': 'text-sm font-medium text-[#382d28]'}}) }}
            {{ form_widget(form.passwordConfirmation, {'attr': {
                class: 'h-12 bg-white px-5 text-[#201917] placeholder:text-[#9f8b72] ring-1 ring-inset ring-[#e3d6c2] focus:ring-1 focus:ring-inset focus:ring-[#9d7c47]',
                'data-action': 'blur->live#action',
                'data-live-action-param': 'validatePasswords'
            }}) }}
            <div class="text-sm text-red-600">{{ form_errors(form.passwordConfirmation) }}</div>
            <div class="text-sm text-red-600">{{ form_errors(form) }}</div>
        </div>
        <button
            type="submit"
            class="inline-flex min-h-12 items-center justify-center bg-[#201917] px-6 text-sm font-medium uppercase tracking-[0.24em] text-white transition hover:bg-[#9d7c47] disabled:cursor-not-allowed disabled:bg-[#b7ac9d]"
            {% if not this.canSubmit %}disabled{% endif %}
        >
            {{ 'security.reset_password.submit'|trans }}
        </button>
        <div class="hidden">{{ form_rest(form) }}</div>
    {{ form_end(form) }}
</div>
