templates/reset_password/request.html.twig line 1

Open in your IDE?
  1. {% extends 'baseLogin.html.twig' %}
  2. {% block title %}Mot de passe oublié — Macssolution{% endblock %}
  3. {% block styles %}
  4. <style>
  5.     .lf-card {
  6.         width: 100%;
  7.         max-width: 420px;
  8.         background: #fff;
  9.         border: 1px solid #e2e8f0;
  10.         border-radius: 20px;
  11.         box-shadow: 0 8px 40px rgba(0,0,0,0.08);
  12.         padding: 2.5rem 2.25rem;
  13.     }
  14.     .lf-header { text-align: center; margin-bottom: 2rem; }
  15.     .lf-header__icon {
  16.         width: 64px; height: 64px;
  17.         border-radius: 16px;
  18.         background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
  19.         display: flex; align-items: center; justify-content: center;
  20.         color: #fff; font-size: 1.5rem;
  21.         margin: 0 auto 1.25rem;
  22.         box-shadow: 0 4px 14px rgba(59,130,246,0.35);
  23.     }
  24.     .lf-header__title {
  25.         font-size: 1.5rem; font-weight: 700;
  26.         color: #1f2937; letter-spacing: -0.02em; margin-bottom: 0.375rem;
  27.     }
  28.     .lf-header__sub { font-size: 0.875rem; color: #64748b; line-height: 1.6; }
  29.     .lf-error {
  30.         display: flex; align-items: flex-start; gap: 0.625rem;
  31.         background: #fef2f2; border: 1px solid #fecaca; color: #dc2626;
  32.         border-radius: 10px; padding: 0.75rem 1rem;
  33.         font-size: 0.875rem; font-weight: 500; margin-bottom: 1.5rem;
  34.     }
  35.     .lf-info {
  36.         display: flex; align-items: flex-start; gap: 0.625rem;
  37.         background: #eff6ff; border: 1px solid #bfdbfe; color: #1e40af;
  38.         border-radius: 10px; padding: 0.75rem 1rem;
  39.         font-size: 0.8125rem; margin-bottom: 1.25rem; line-height: 1.5;
  40.     }
  41.     .lf-group { margin-bottom: 1.25rem; }
  42.     .lf-label {
  43.         display: block; font-size: 0.8125rem;
  44.         font-weight: 600; color: #374151; margin-bottom: 0.375rem;
  45.     }
  46.     .lf-input-wrap { position: relative; }
  47.     .lf-input-wrap i {
  48.         position: absolute; left: 0.875rem; top: 50%;
  49.         transform: translateY(-50%); color: #94a3b8;
  50.         font-size: 0.9rem; pointer-events: none;
  51.     }
  52.     .lf-input {
  53.         width: 100%; height: 46px;
  54.         padding: 0 0.875rem 0 2.5rem;
  55.         border: 1px solid #e2e8f0; border-radius: 10px;
  56.         font-size: 0.9375rem; color: #1f2937;
  57.         background: #f8fafc; font-family: inherit;
  58.         transition: all 0.2s ease; outline: none;
  59.     }
  60.     .lf-input:focus {
  61.         border-color: #3b82f6; background: #fff;
  62.         box-shadow: 0 0 0 3px rgba(59,130,246,0.12);
  63.     }
  64.     .lf-actions { display: flex; flex-direction: column; gap: 0.625rem; margin-top: 1.5rem; }
  65.     .lf-submit {
  66.         width: 100%; height: 48px;
  67.         background: linear-gradient(135deg, #1e40af 0%, #3b82f6 100%);
  68.         color: #fff; border: none; border-radius: 10px;
  69.         font-size: 0.9375rem; font-weight: 700; font-family: inherit;
  70.         cursor: pointer; display: flex; align-items: center;
  71.         justify-content: center; gap: 0.5rem;
  72.         transition: all 0.2s ease;
  73.     }
  74.     .lf-submit:hover {
  75.         transform: translateY(-1px);
  76.         box-shadow: 0 6px 20px rgba(59,130,246,0.4);
  77.     }
  78.     .lf-back {
  79.         width: 100%; height: 44px;
  80.         background: #f1f5f9; color: #64748b;
  81.         border: none; border-radius: 10px;
  82.         font-size: 0.875rem; font-weight: 600; font-family: inherit;
  83.         cursor: pointer; display: flex; align-items: center;
  84.         justify-content: center; gap: 0.5rem;
  85.         text-decoration: none; transition: all 0.2s ease;
  86.     }
  87.     .lf-back:hover { background: #e2e8f0; color: #1f2937; }
  88. </style>
  89. {% endblock %}
  90. {% block body %}
  91. <div class="lf-card">
  92.     <div class="lf-header">
  93.         <div class="lf-header__icon">
  94.             <i class="fas fa-key"></i>
  95.         </div>
  96.         <h1 class="lf-header__title">Mot de passe oublié ?</h1>
  97.         <p class="lf-header__sub">Saisissez votre email et nous vous enverrons un lien pour réinitialiser votre mot de passe.</p>
  98.     </div>
  99.     {% for flash_error in app.flashes('reset_password_error') %}
  100.         <div class="lf-error">
  101.             <i class="fas fa-exclamation-circle"></i>
  102.             <span>{{ flash_error }}</span>
  103.         </div>
  104.     {% endfor %}
  105.     <div class="lf-info">
  106.         <i class="fas fa-info-circle" style="flex-shrink:0;margin-top:2px;"></i>
  107.         <span>Un lien de réinitialisation sera envoyé à cette adresse si elle est associée à un compte.</span>
  108.     </div>
  109.     {{ form_start(requestForm) }}
  110.         <div class="lf-group">
  111.             <label class="lf-label" for="{{ requestForm.email.vars.id }}">Adresse e-mail</label>
  112.             <div class="lf-input-wrap">
  113.                 {{ form_widget(requestForm.email, {
  114.                     'attr': {'class': 'lf-input', 'placeholder': 'votre@email.com', 'autofocus': true}
  115.                 }) }}
  116.                 <i class="fas fa-envelope"></i>
  117.             </div>
  118.             {{ form_errors(requestForm.email) }}
  119.         </div>
  120.         <div class="lf-actions">
  121.             <button type="submit" class="lf-submit">
  122.                 <i class="fas fa-paper-plane"></i>
  123.                 Envoyer le lien
  124.             </button>
  125.             <a href="{{ path('app_login') }}" class="lf-back">
  126.                 <i class="fas fa-arrow-left"></i>
  127.                 Retour à la connexion
  128.             </a>
  129.         </div>
  130.     {{ form_end(requestForm) }}
  131. </div>
  132. {% endblock %}