{% extends '@SyliusCore/Email/layout.html.twig' %}

{% block subject %}
    {{ 'sylius.email.password_reset.subject'|trans({}, null, localeCode)|raw }}
{% endblock %}

{% block content %}
    {% if sylius_bundle_loaded_checker('SyliusShopBundle') %}
        {% set url = sylius_channel_url(path('sylius_shop_password_reset', { 'token': user.passwordResetToken, '_locale': localeCode }), channel) %}
    {% endif %}
    <div style="text-align: center; margin-bottom: 30px;">
        <div style="font-size: 24px;">
            {{ 'sylius.email.password_reset.hello'|trans({}, null, localeCode) }} <strong>{{ user.username }}</strong><br>
        </div>
        {% if sylius_bundle_loaded_checker('SyliusShopBundle') %}
            {{ 'sylius.email.password_reset.to_reset_your_password'|trans({}, null, localeCode) }}:
        {% else %}
            {{ 'sylius.email.password_reset.to_reset_your_password_token'|trans({}, null, localeCode) }}:
        {% endif %}
    </div>

    <div style="text-align: center;">
        {% if sylius_bundle_loaded_checker('SyliusShopBundle') %}
        <a href="{{ url|raw }}" style="display: inline-block; text-align: center; background: #1abb9c; padding: 18px 28px; color: #fff; text-decoration: none; border-radius: 3px;">
            {{ 'sylius.email.password_reset.reset_your_password'|trans({}, null, localeCode) }}
        </a>
        {% else %}
            {{ 'sylius.email.password_reset.token'|trans({}, null, localeCode) }}: {{ user.passwordResetToken }}
        {% endif %}
    </div>
{% endblock %}
