/* =====================================================================
   Al'sTutoring — système de design
   Une seule couleur de marque, dérivée du logo : #2C5AA0.
   Tout le reste est une échelle de gris neutres.
   ===================================================================== */

/* ------------------------------------------------------------------ */
/* 1. Jetons                                                           */
/* ------------------------------------------------------------------ */
:root {
  /* Couleur de marque — unique teinte du site */
  --brand-50:  #eef4fb;
  --brand-100: #d8e6f5;
  --brand-200: #b3cbe9;
  --brand-300: #82a8d8;
  --brand-400: #5382c1;
  --brand-500: #2c5aa0;   /* couleur du logo */
  --brand-600: #24497f;
  --brand-700: #1d3a66;
  --brand-800: #172d4f;
  --brand-900: #11213a;

  /* Neutres */
  --ink:        #1c2733;
  --ink-soft:   #43536a;
  --ink-muted:  #6b7c93;
  --ink-faint:  #9aa8bb;
  --line:       #e3e9f0;
  --line-strong:#cdd7e3;
  --surface:    #ffffff;
  --surface-alt:#f6f9fc;
  --surface-sunk:#eef3f8;

  /* États — utilisés uniquement pour signaler un statut, jamais en décoration */
  --ok:      #1f7a5c;
  --ok-bg:   #e8f5f0;
  --warn:    #9a6414;
  --warn-bg: #fdf3e3;
  --danger:  #a8322b;
  --danger-bg:#fbeceb;

  /* Typographie */
  --font-display: "Lora", Georgia, "Times New Roman", serif;
  --font-body: "Source Sans 3", "Source Sans Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --step--1: 0.875rem;
  --step-0:  1rem;
  --step-1:  1.125rem;
  --step-2:  1.375rem;
  --step-3:  1.75rem;
  --step-4:  2.25rem;
  --step-5:  3rem;

  /* Espacement */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;
  --space-9: 6rem;

  /* Formes */
  --radius-sm: 6px;
  --radius:    10px;
  --radius-lg: 16px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(23, 45, 79, 0.06);
  --shadow:    0 2px 8px rgba(23, 45, 79, 0.07);
  --shadow-lg: 0 12px 32px rgba(23, 45, 79, 0.10);

  --header-height: 76px;
  --content-width: 1160px;
  --prose-width: 68ch;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ------------------------------------------------------------------ */
/* 2. Réinitialisation                                                 */
/* ------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }

* { margin: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 1rem);
}

body {
  font-family: var(--font-body);
  font-size: var(--step-0);
  line-height: 1.65;
  color: var(--ink);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

img, svg, video { display: block; max-width: 100%; }
img, video { height: auto; }

input, button, textarea, select { font: inherit; color: inherit; }

button { cursor: pointer; }

a { color: var(--brand-600); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--brand-700); }

:focus-visible {
  outline: 2px solid var(--brand-500);
  outline-offset: 2px;
  border-radius: 3px;
}

::selection { background: var(--brand-100); color: var(--brand-900); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Lien d'évitement pour la navigation au clavier */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 2000;
  background: var(--brand-700);
  color: #fff;
  padding: 0.75rem 1.25rem;
  border-radius: 0 0 var(--radius) 0;
  font-weight: 600;
}
.skip-link:focus { left: 0; color: #fff; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}

/* ------------------------------------------------------------------ */
/* 3. Typographie                                                      */
/* ------------------------------------------------------------------ */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.015em;
  color: var(--ink);
  text-wrap: balance;
}

h1 { font-size: var(--step-4); }
h2 { font-size: var(--step-3); }
h3 { font-size: var(--step-2); }
h4 { font-size: var(--step-1); font-family: var(--font-body); font-weight: 700; letter-spacing: 0; }

p { max-width: var(--prose-width); }
p + p { margin-top: 0.9em; }

.lead {
  font-size: var(--step-1);
  line-height: 1.6;
  color: var(--ink-soft);
}

.muted { color: var(--ink-muted); }
.small { font-size: var(--step--1); }

.prose > * + * { margin-top: 1rem; }
.prose h2 { margin-top: 2.25rem; font-size: var(--step-2); }
.prose h3 { margin-top: 1.75rem; font-size: var(--step-1); font-family: var(--font-body); font-weight: 700; }
.prose ul, .prose ol { padding-left: 1.35rem; max-width: var(--prose-width); }
.prose li + li { margin-top: 0.4rem; }
.prose strong { font-weight: 600; color: var(--ink); }

/* ------------------------------------------------------------------ */
/* 4. Mise en page                                                     */
/* ------------------------------------------------------------------ */
.container {
  width: 100%;
  max-width: var(--content-width);
  margin-inline: auto;
  padding-inline: var(--space-5);
}

.container--narrow { max-width: 780px; }

main { flex: 1 0 auto; }

.section { padding-block: var(--space-8); }
.section--tight { padding-block: var(--space-7); }
.section--alt { background: var(--surface-alt); }
.section--sunk { background: var(--surface-sunk); }

.section-head {
  max-width: 720px;
  margin-bottom: var(--space-6);
}
.section-head--center { margin-inline: auto; text-align: center; }
.section-head p { color: var(--ink-soft); margin-top: 0.6rem; }
.section-head--center p { margin-inline: auto; }

.grid { display: grid; gap: var(--space-5); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }

.stack > * + * { margin-top: var(--space-4); }
.cluster { display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: center; }
.spread { display: flex; flex-wrap: wrap; gap: var(--space-4); align-items: center; justify-content: space-between; }

/* ------------------------------------------------------------------ */
/* 5. En-tête et navigation                                            */
/* ------------------------------------------------------------------ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: saturate(150%) blur(8px);
  border-bottom: 1px solid var(--line);
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: var(--space-5);
  min-height: var(--header-height);
}

/* Le logo est une image SVG : il ne peut être ni traduit ni reflué. */
.logo {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  line-height: 0;
}
.logo img { height: 30px; width: auto; }
.site-footer .logo img { height: 26px; }

.site-nav { margin-left: auto; }

.site-nav__list {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  list-style: none;
  padding: 0;
  margin: 0;
}

.site-nav__link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.5rem 0.7rem;
  border-radius: var(--radius-sm);
  font-size: 0.9375rem;
  font-weight: 500;
  color: var(--ink-soft);
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.15s var(--ease), background-color 0.15s var(--ease);
}
.site-nav__link:hover { color: var(--brand-600); background: var(--brand-50); }
.site-nav__link[aria-current="page"],
.site-nav__link.is-active { color: var(--brand-700); font-weight: 600; }

.has-menu { position: relative; }

.site-nav__panel {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 268px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 0.4rem;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: opacity 0.16s var(--ease), transform 0.16s var(--ease), visibility 0.16s;
}
.has-menu:hover .site-nav__panel,
.has-menu:focus-within .site-nav__panel,
.has-menu.is-open .site-nav__panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.site-nav__panel a {
  display: block;
  padding: 0.55rem 0.7rem;
  border-radius: var(--radius-sm);
  font-size: 0.9375rem;
  color: var(--ink-soft);
  text-decoration: none;
}
.site-nav__panel a:hover { background: var(--brand-50); color: var(--brand-700); }
.site-nav__panel a span { display: block; font-size: 0.8125rem; color: var(--ink-faint); margin-top: 1px; }
.site-nav__panel a:hover span { color: var(--brand-500); }

.site-header__actions { display: flex; align-items: center; gap: var(--space-3); }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  width: 42px; height: 42px;
  align-items: center; justify-content: center;
  color: var(--ink);
  font-size: 1.1rem;
}

/* ------------------------------------------------------------------ */
/* 6. Boutons                                                          */
/* ------------------------------------------------------------------ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.35rem;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.3;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.15s var(--ease), border-color 0.15s var(--ease), color 0.15s var(--ease);
}

.btn--primary { background: var(--brand-500); border-color: var(--brand-500); color: #fff; }
.btn--primary:hover { background: var(--brand-600); border-color: var(--brand-600); color: #fff; }

.btn--outline { background: transparent; border-color: var(--line-strong); color: var(--ink); }
.btn--outline:hover { border-color: var(--brand-400); background: var(--brand-50); color: var(--brand-700); }

.btn--ghost { background: transparent; border-color: transparent; color: var(--brand-600); padding-inline: 0.6rem; }
.btn--ghost:hover { background: var(--brand-50); color: var(--brand-700); }

.btn--danger { background: transparent; border-color: var(--line-strong); color: var(--danger); }
.btn--danger:hover { background: var(--danger-bg); border-color: var(--danger); }

.btn--lg { padding: 0.9rem 1.75rem; font-size: 1rem; }
.btn--sm { padding: 0.4rem 0.8rem; font-size: 0.8125rem; }
.btn--block { width: 100%; }

.btn:disabled, .btn[aria-disabled="true"] { opacity: 0.55; pointer-events: none; }
.btn.is-loading { position: relative; color: transparent !important; pointer-events: none; }
.btn.is-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 16px; height: 16px;
  border: 2px solid currentColor;
  border-top-color: transparent;
  border-radius: 50%;
  color: #fff;
  animation: spin 0.6s linear infinite;
}
.btn--outline.is-loading::after, .btn--ghost.is-loading::after { color: var(--brand-500); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ------------------------------------------------------------------ */
/* 7. Cartes et surfaces                                               */
/* ------------------------------------------------------------------ */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--space-5);
}
.card--flush { padding: 0; overflow: hidden; }
.card--raised { box-shadow: var(--shadow); }

.card__title { font-size: var(--step-1); font-family: var(--font-body); font-weight: 700; }
.card__meta { font-size: var(--step--1); color: var(--ink-muted); }
.card__body { margin-top: var(--space-3); color: var(--ink-soft); }
.card__body p { max-width: none; }
.card__foot { margin-top: var(--space-4); padding-top: var(--space-4); border-top: 1px solid var(--line); }

.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  border-radius: var(--radius-sm);
  background: var(--brand-50);
  color: var(--brand-600);
  font-size: 1.15rem;
  margin-bottom: var(--space-4);
}

/* Carte-lien de programme */
.program-card { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: inherit; transition: border-color 0.15s var(--ease); }
.program-card:hover { border-color: var(--brand-300); color: inherit; }
.program-card p { flex: 1; }

.tag-row { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-top: var(--space-4); }
.tag {
  padding: 0.2rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ink-muted);
  background: var(--surface-alt);
}

/* ------------------------------------------------------------------ */
/* 8. Badges d'état                                                    */
/* ------------------------------------------------------------------ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.6;
  white-space: nowrap;
}
.badge--neutral { background: var(--surface-sunk); color: var(--ink-soft); }
.badge--brand   { background: var(--brand-50); color: var(--brand-700); }
.badge--ok      { background: var(--ok-bg); color: var(--ok); }
.badge--warn    { background: var(--warn-bg); color: var(--warn); }
.badge--danger  { background: var(--danger-bg); color: var(--danger); }

/* ------------------------------------------------------------------ */
/* 9. Formulaires                                                      */
/* ------------------------------------------------------------------ */
.form { display: grid; gap: var(--space-4); }

.field { display: grid; gap: 0.35rem; }

.field > label,
.field-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink);
}

.field__hint { font-size: 0.8125rem; color: var(--ink-muted); }

.field__error {
  font-size: 0.8125rem;
  color: var(--danger);
  display: none;
}
.field.has-error .field__error { display: block; }
.field.has-error .input,
.field.has-error .select,
.field.has-error .textarea { border-color: var(--danger); }

.input, .select, .textarea {
  width: 100%;
  padding: 0.65rem 0.8rem;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  font-size: 0.9375rem;
  color: var(--ink);
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.input::placeholder, .textarea::placeholder { color: var(--ink-faint); }

.input:focus, .select:focus, .textarea:focus {
  outline: none;
  border-color: var(--brand-500);
  box-shadow: 0 0 0 3px var(--brand-100);
}

.input:disabled, .select:disabled, .textarea:disabled {
  background: var(--surface-sunk);
  color: var(--ink-muted);
  cursor: not-allowed;
}

.textarea { min-height: 130px; resize: vertical; line-height: 1.6; }

.select {
  appearance: none;
  padding-right: 2.25rem;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8' fill='none'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%236b7c93' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.85rem center;
}

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); }

/* Cases à cocher et boutons radio */
.check {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: var(--ink-soft);
  cursor: pointer;
}
.check input { margin-top: 0.28rem; accent-color: var(--brand-500); width: 1rem; height: 1rem; flex-shrink: 0; }
.check a { font-weight: 500; }

.check-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 0.6rem; }

.check-card {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  font-size: 0.9375rem;
  cursor: pointer;
  transition: border-color 0.15s var(--ease), background-color 0.15s var(--ease);
}
.check-card:hover { border-color: var(--brand-300); }
.check-card input { margin-top: 0.2rem; accent-color: var(--brand-500); }
.check-card:has(input:checked) { border-color: var(--brand-500); background: var(--brand-50); }

/* Champ mot de passe avec bouton de visibilité */
.password-field { position: relative; }
.password-field .input { padding-right: 2.75rem; }
.password-toggle {
  position: absolute;
  right: 0.35rem;
  top: 50%;
  transform: translateY(-50%);
  width: 34px; height: 34px;
  display: grid; place-items: center;
  background: none; border: none;
  color: var(--ink-muted);
  border-radius: var(--radius-sm);
}
.password-toggle:hover { color: var(--brand-600); background: var(--brand-50); }

/* Jauge de robustesse */
.password-meter { display: grid; gap: 0.3rem; }
.password-meter__track { display: flex; gap: 3px; }
.password-meter__bar { height: 4px; flex: 1; border-radius: 2px; background: var(--line); transition: background-color 0.2s var(--ease); }
.password-meter[data-score="1"] .password-meter__bar:nth-child(-n+1) { background: var(--danger); }
.password-meter[data-score="2"] .password-meter__bar:nth-child(-n+2) { background: var(--warn); }
.password-meter[data-score="3"] .password-meter__bar:nth-child(-n+3) { background: var(--brand-400); }
.password-meter[data-score="4"] .password-meter__bar { background: var(--ok); }
.password-meter__label { font-size: 0.8125rem; color: var(--ink-muted); }

/* Zone de dépôt de fichier */
.dropzone {
  display: grid;
  place-items: center;
  gap: 0.4rem;
  padding: var(--space-5);
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface-alt);
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s var(--ease), background-color 0.15s var(--ease);
}
.dropzone:hover, .dropzone.is-dragover { border-color: var(--brand-400); background: var(--brand-50); }
.dropzone i { font-size: 1.4rem; color: var(--brand-500); }
.dropzone__hint { font-size: 0.8125rem; color: var(--ink-muted); }
.dropzone input[type="file"] { display: none; }

.file-list { display: grid; gap: 0.4rem; margin-top: var(--space-3); }
.file-chip {
  display: flex; align-items: center; gap: 0.6rem;
  padding: 0.5rem 0.75rem;
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
}
.file-chip i { color: var(--brand-500); }
.file-chip__size { margin-left: auto; color: var(--ink-muted); font-size: 0.8125rem; }

.form-actions { display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: center; }
.form-note { font-size: 0.8125rem; color: var(--ink-muted); }

/* ------------------------------------------------------------------ */
/* 10. Messages système                                                */
/* ------------------------------------------------------------------ */
.alert {
  display: flex;
  gap: 0.7rem;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-sm);
  border: 1px solid;
  font-size: 0.9375rem;
  line-height: 1.55;
}
.alert i { margin-top: 0.2rem; flex-shrink: 0; }
.alert p { max-width: none; }
.alert--info    { background: var(--brand-50); border-color: var(--brand-200); color: var(--brand-800); }
.alert--ok      { background: var(--ok-bg); border-color: #b9dfd0; color: var(--ok); }
.alert--warn    { background: var(--warn-bg); border-color: #f0d9ae; color: var(--warn); }
.alert--danger  { background: var(--danger-bg); border-color: #eec4c1; color: var(--danger); }
.alert[hidden] { display: none; }

/* Notifications flottantes */
.toast-stack {
  position: fixed;
  bottom: var(--space-5);
  right: var(--space-5);
  z-index: 1000;
  display: grid;
  gap: 0.5rem;
  max-width: min(380px, calc(100vw - 2rem));
}
.toast {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.8rem 1rem;
  background: var(--ink);
  color: #fff;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg);
  font-size: 0.9375rem;
  animation: toast-in 0.24s var(--ease);
}
.toast--ok { background: var(--ok); }
.toast--danger { background: var(--danger); }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.empty-state {
  display: grid;
  place-items: center;
  gap: 0.5rem;
  padding: var(--space-7) var(--space-5);
  text-align: center;
  color: var(--ink-muted);
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface-alt);
}
.empty-state i { font-size: 1.6rem; color: var(--ink-faint); }
.empty-state strong { color: var(--ink); font-weight: 600; }
.empty-state p { max-width: 44ch; }

/* ------------------------------------------------------------------ */
/* 11. Tableaux                                                        */
/* ------------------------------------------------------------------ */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }

.table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; }
.table th {
  text-align: left;
  padding: 0.7rem 1rem;
  background: var(--surface-alt);
  border-bottom: 1px solid var(--line);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ink-muted);
  white-space: nowrap;
}
.table td { padding: 0.8rem 1rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: none; }
.table tbody tr:hover { background: var(--surface-alt); }
.table__actions { display: flex; gap: 0.35rem; justify-content: flex-end; }
.table__num { text-align: right; font-variant-numeric: tabular-nums; }

/* ------------------------------------------------------------------ */
/* 12. Accueil — section d'ouverture                                   */
/* ------------------------------------------------------------------ */
.hero {
  padding-block: var(--space-8) var(--space-8);
  background: linear-gradient(180deg, var(--brand-50) 0%, var(--surface) 100%);
  border-bottom: 1px solid var(--line);
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: var(--space-7);
  align-items: center;
}

.hero h1 {
  font-size: clamp(2rem, 4.4vw, 3.15rem);
  line-height: 1.08;
  letter-spacing: -0.025em;
}

.hero__lead {
  font-size: var(--step-1);
  color: var(--ink-soft);
  margin-top: var(--space-4);
  max-width: 52ch;
}

.hero__actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-6); }

.hero__proof {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-6);
  margin-top: var(--space-7);
  padding-top: var(--space-5);
  border-top: 1px solid var(--line-strong);
}
.hero__proof div { min-width: 110px; }
.hero__proof dt {
  font-family: var(--font-display);
  font-size: var(--step-3);
  font-weight: 600;
  color: var(--brand-600);
  line-height: 1;
}
.hero__proof dd { margin: 0.3rem 0 0; font-size: 0.875rem; color: var(--ink-muted); }

.hero__media {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4 / 3;
}
.hero__media img { width: 100%; height: 100%; object-fit: cover; }

/* ------------------------------------------------------------------ */
/* 13. Blocs de contenu réutilisables                                  */
/* ------------------------------------------------------------------ */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: var(--space-7);
  align-items: center;
}
.split--media-first > :first-child { order: 2; }

.steps { counter-reset: step; display: grid; gap: var(--space-4); }
.step {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-4);
  align-items: start;
}
.step::before {
  counter-increment: step;
  content: counter(step);
  display: grid;
  place-items: center;
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--brand-500);
  color: #fff;
  font-size: 0.9375rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.step h3 { font-size: var(--step-1); font-family: var(--font-body); font-weight: 700; }
.step p { color: var(--ink-soft); margin-top: 0.25rem; }

.feature-list { list-style: none; padding: 0; display: grid; gap: 0.65rem; }
.feature-list li { display: flex; gap: 0.6rem; align-items: flex-start; color: var(--ink-soft); }
.feature-list i { color: var(--brand-500); margin-top: 0.32rem; font-size: 0.8rem; flex-shrink: 0; }

.quote {
  border-left: 3px solid var(--brand-500);
  padding-left: var(--space-5);
}
.quote blockquote {
  font-family: var(--font-display);
  font-size: var(--step-2);
  line-height: 1.5;
  color: var(--ink);
  margin: 0;
}
.quote figcaption { margin-top: var(--space-4); font-size: 0.875rem; color: var(--ink-muted); }

.cta-band {
  background: var(--brand-700);
  color: #fff;
  padding-block: var(--space-8);
}
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255, 255, 255, 0.82); max-width: 58ch; }
.cta-band .btn--primary { background: #fff; border-color: #fff; color: var(--brand-700); }
.cta-band .btn--primary:hover { background: var(--brand-50); border-color: var(--brand-50); color: var(--brand-800); }
.cta-band .btn--outline { border-color: rgba(255, 255, 255, 0.45); color: #fff; }
.cta-band .btn--outline:hover { background: rgba(255, 255, 255, 0.1); border-color: #fff; color: #fff; }

/* Tarifs */
.price-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: var(--space-5); align-items: start; }
.price-card { display: flex; flex-direction: column; height: 100%; position: relative; }
.price-card--featured { border-color: var(--brand-500); border-width: 1.5px; }
.price-card__flag {
  position: absolute;
  top: -11px; left: var(--space-5);
  background: var(--brand-500);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.15rem 0.6rem;
  border-radius: var(--radius-pill);
}
.price-card__amount {
  font-family: var(--font-display);
  font-size: var(--step-4);
  font-weight: 600;
  color: var(--ink);
  line-height: 1;
  margin-block: var(--space-3);
}
.price-card__amount span { font-family: var(--font-body); font-size: var(--step--1); font-weight: 400; color: var(--ink-muted); }
.price-card .feature-list { flex: 1; margin-block: var(--space-4); }

/* Accordéon (FAQ) */
.accordion { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.accordion details + details { border-top: 1px solid var(--line); }
.accordion summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  padding: 1rem 1.25rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after {
  content: "\f078";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: 0.75rem;
  color: var(--ink-muted);
  transition: transform 0.18s var(--ease);
}
.accordion details[open] summary::after { transform: rotate(180deg); }
.accordion summary:hover { background: var(--surface-alt); }
.accordion__body { padding: 0 1.25rem 1.25rem; color: var(--ink-soft); }
.accordion__body p { max-width: none; }

/* Fil d'Ariane */
.breadcrumb { display: flex; flex-wrap: wrap; gap: 0.4rem; font-size: 0.8125rem; color: var(--ink-muted); padding-block: var(--space-4); }
.breadcrumb a { color: var(--ink-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--brand-600); text-decoration: underline; }
.breadcrumb li + li::before { content: "/"; margin-right: 0.4rem; color: var(--ink-faint); }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: 0.4rem; list-style: none; padding: 0; margin: 0; }

/* En-tête de page intérieure */
.page-head {
  padding-block: var(--space-7) var(--space-6);
  background: var(--surface-alt);
  border-bottom: 1px solid var(--line);
}
.page-head h1 { font-size: clamp(1.75rem, 3.4vw, 2.6rem); }
.page-head p { color: var(--ink-soft); margin-top: var(--space-3); font-size: var(--step-1); }

/* ------------------------------------------------------------------ */
/* 14. Pages d'authentification                                        */
/* ------------------------------------------------------------------ */
.auth {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.85fr);
  gap: var(--space-7);
  padding-block: var(--space-8);
  align-items: start;
}

.auth__panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}
.auth__panel h1 { font-size: var(--step-3); }
.auth__panel > p { color: var(--ink-soft); margin-top: var(--space-3); }
.auth__panel .form { margin-top: var(--space-5); }

.auth__aside {
  background: var(--brand-700);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}
.auth__aside h2 { color: #fff; font-size: var(--step-2); }
.auth__aside p { color: rgba(255, 255, 255, 0.82); margin-top: var(--space-3); }
.auth__aside .feature-list li { color: rgba(255, 255, 255, 0.9); }
.auth__aside .feature-list i { color: rgba(255, 255, 255, 0.7); }
.auth__aside .feature-list { margin-top: var(--space-5); }

.auth__switch {
  margin-top: var(--space-5);
  padding-top: var(--space-5);
  border-top: 1px solid var(--line);
  font-size: 0.9375rem;
  color: var(--ink-muted);
}

/* ------------------------------------------------------------------ */
/* 15. Pied de page                                                    */
/* ------------------------------------------------------------------ */
.site-footer {
  margin-top: auto;
  background: var(--brand-900);
  color: rgba(255, 255, 255, 0.72);
  padding-block: var(--space-8) var(--space-5);
  font-size: 0.9375rem;
}
.site-footer h3 {
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: var(--space-4);
}
.site-footer__grid {
  display: grid;
  grid-template-columns: 1.6fr repeat(3, 1fr);
  gap: var(--space-6);
}
.site-footer ul { list-style: none; padding: 0; display: grid; gap: 0.55rem; }
.site-footer a { color: rgba(255, 255, 255, 0.72); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer p { max-width: 40ch; }

.site-footer__contact { display: grid; gap: 0.5rem; margin-top: var(--space-4); }
.site-footer__contact div { display: flex; gap: 0.6rem; align-items: center; }
.site-footer__contact i { width: 16px; color: rgba(255, 255, 255, 0.5); font-size: 0.85rem; }

.site-footer__bottom {
  margin-top: var(--space-7);
  padding-top: var(--space-5);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  justify-content: space-between;
  align-items: center;
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.55);
}
.site-footer__legal { display: flex; flex-wrap: wrap; gap: var(--space-4); }

.payment-marks { display: flex; gap: 0.5rem; align-items: center; margin-top: var(--space-4); }
.payment-mark {
  padding: 0.25rem 0.6rem;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.8);
}

/* ------------------------------------------------------------------ */
/* 16. Adaptation aux petits écrans                                    */
/* ------------------------------------------------------------------ */
@media (max-width: 1024px) {
  .site-footer__grid { grid-template-columns: 1fr 1fr; }
  .hero__grid { gap: var(--space-6); }
}

@media (max-width: 900px) {
  :root { --header-height: 66px; }

  .nav-toggle { display: inline-flex; }

  .site-nav {
    position: fixed;
    inset: var(--header-height) 0 0 auto;
    width: min(340px, 88vw);
    background: var(--surface);
    border-left: 1px solid var(--line);
    box-shadow: var(--shadow-lg);
    padding: var(--space-5);
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform 0.22s var(--ease);
    margin-left: 0;
  }
  .site-nav.is-open { transform: translateX(0); }

  .site-nav__list { flex-direction: column; align-items: stretch; gap: 0.15rem; }
  .site-nav__link { padding: 0.7rem 0.75rem; font-size: 1rem; }

  .site-nav__panel {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border: none;
    border-left: 2px solid var(--line);
    border-radius: 0;
    margin-left: 0.75rem;
    padding-left: 0.5rem;
    min-width: 0;
    display: none;
  }
  .has-menu.is-open .site-nav__panel { display: block; }

  .site-nav__cta { margin-top: var(--space-4); }
  .site-nav__cta .btn { width: 100%; }
  .site-header__actions .btn { display: none; }

  .hero__grid, .split { grid-template-columns: 1fr; }
  .split--media-first > :first-child { order: 0; }
  .hero__media { aspect-ratio: 16 / 10; }
  .auth { grid-template-columns: 1fr; }
  .auth__aside { order: -1; }
}

@media (max-width: 640px) {
  :root { --space-8: 3rem; --space-9: 4rem; }
  .container { padding-inline: var(--space-4); }
  .field-row { grid-template-columns: 1fr; }
  .site-footer__grid { grid-template-columns: 1fr; }
  .hero__proof { gap: var(--space-5); }
  .form-actions .btn { width: 100%; }
  .toast-stack { left: var(--space-4); right: var(--space-4); bottom: var(--space-4); max-width: none; }
}

/* ------------------------------------------------------------------ */
/* 17. Impression                                                      */
/* ------------------------------------------------------------------ */
@media print {
  .site-header, .site-footer, .btn, .toast-stack, .nav-toggle { display: none !important; }
  body { background: #fff; color: #000; }
  .card, .table-wrap { border-color: #999; box-shadow: none; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 0.75em; color: #555; }
}
