/* ==========================================================================
   WassaSMS — Feuille de styles du prototype (preview)
   En-tête : tokens.css importé/intégré tel quel (socle de marque).
   Puis : système de composants + styles de pages (marketing, login, app).
   ========================================================================== */

/* ---- Polices (Google Fonts) -------------------------------------------- */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@500;600;700;800&family=Inter:wght@400;500;600;700&display=swap');

:root {
  /* === 1. COULEURS — Marque (charte WASSA v1) === */
  --color-gold:            #FF8A00;   /* Orange WASSA — CTA / accents / état actif */
  --color-gold-hover:      #E67A00;
  --color-gold-soft:       #FFD2A1;
  --color-gold-tint:       #FFF1E0;
  --color-ink:             #0B2345;   /* Bleu nuit WASSA — texte fort, navigation */
  --color-ink-soft:        #1E3A5F;
  --color-graphite:        #071A33;   /* Graphite — footer, UI sombre */

  /* === 2. COULEURS — Sémantiques === */
  --color-success:         #1E7A52;
  --color-success-soft:    #E4F2EB;
  --color-success-hover:   #176343;
  --color-error:           #DC2626;
  --color-error-soft:      #FCE9E9;
  --color-error-hover:     #B91C1C;
  --color-warning:         #FF8A00;
  --color-warning-soft:    #FFF1E0;
  --color-info:            #1E5C99;
  --color-info-soft:       #E5EEF8;

  /* === 3. Fonds & surfaces === */
  --color-paper:           #F6F8FB;   /* Gris clair WASSA — fond de page */
  --color-surface:         #FFFFFF;
  --color-surface-sunken:  #EEF2F7;

  /* === 4. Gris neutres (froids) === */
  --color-neutral-50:      #F4F6FA;
  --color-neutral-100:     #E9EDF3;
  --color-neutral-200:     #D7DEE8;
  --color-neutral-300:     #B7C0CF;
  --color-neutral-400:     #94A0B2;
  --color-neutral-500:     #6B7689;
  --color-neutral-600:     #4B5870;
  --color-neutral-700:     #33415A;
  --color-neutral-800:     #1A2C49;
  --color-neutral-900:     #0B2345;

  /* === 5. Rôles applicatifs === */
  --color-bg:              var(--color-paper);
  --color-bg-elevated:     var(--color-surface);
  --color-text:            var(--color-ink);
  --color-text-muted:      var(--color-neutral-600);
  --color-text-subtle:     var(--color-neutral-500);
  --color-text-on-gold:    #FFFFFF;
  --color-text-on-ink:     var(--color-paper);
  --color-border:          var(--color-neutral-200);
  --color-border-strong:   var(--color-neutral-300);
  --color-focus-ring:      rgba(255, 138, 0, 0.40);
  --color-primary:         var(--color-gold);
  --color-primary-hover:   var(--color-gold-hover);

  /* === 6. Typographie — familles === */
  --font-display: 'Montserrat', 'Arial', 'Calibri', sans-serif;
  --font-sans:    'Inter', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  --font-mono:    ui-monospace, 'SFMono-Regular', Menlo, 'Cascadia Mono', monospace;
  --weight-regular:  400;
  --weight-medium:   500;
  --weight-semibold: 600;
  --weight-bold:     700;
  --weight-extra:    800;

  /* === 7. Échelle fluide === */
  /* Échelle agrandie (~1.25×) pour un contenu plus lisible. */
  --text-xs:    clamp(0.90rem, 0.88rem + 0.13vw, 0.98rem);
  --text-sm:    clamp(1.03rem, 0.99rem + 0.19vw, 1.13rem);
  --text-base:  clamp(1.18rem, 1.13rem + 0.25vw, 1.28rem);
  --text-md:    clamp(1.33rem, 1.25rem + 0.38vw, 1.50rem);
  --text-lg:    clamp(1.56rem, 1.44rem + 0.63vw, 1.88rem);
  --text-xl:    clamp(1.94rem, 1.69rem + 1.25vw, 2.56rem);
  --text-2xl:   clamp(2.44rem, 2.00rem + 2.13vw, 3.56rem);
  --text-3xl:   clamp(3.06rem, 2.38rem + 3.38vw, 4.81rem);
  --text-display: clamp(3.10rem, 2.20rem + 4.40vw, 5.50rem);
  --leading-tight:   1.12;
  --leading-snug:    1.28;
  --leading-normal:  1.55;
  --leading-relaxed: 1.7;
  --tracking-tight:  -0.02em;
  --tracking-normal: 0;
  --tracking-wide:   0.04em;
  --tracking-caps:   0.08em;

  /* === 8. Espacements === */
  --space-0:0; --space-1:0.25rem; --space-2:0.5rem; --space-3:0.75rem;
  --space-4:1rem; --space-5:1.25rem; --space-6:1.5rem; --space-8:2rem;
  --space-10:2.5rem; --space-12:3rem; --space-16:4rem; --space-20:5rem; --space-24:6rem;
  --container-sm:640px; --container-md:860px; --container-lg:1100px; --container-xl:1320px;

  /* === 9. Rayons === */
  --radius-xs:4px; --radius-sm:8px; --radius-md:12px; --radius-lg:16px;
  --radius-xl:24px; --radius-2xl:32px; --radius-pill:999px; --radius-full:50%;

  /* === 10. Ombres === */
  --shadow-xs:  0 1px 2px rgba(31, 29, 26, 0.06);
  --shadow-sm:  0 1px 3px rgba(31, 29, 26, 0.08), 0 1px 2px rgba(31, 29, 26, 0.05);
  --shadow-md:  0 4px 12px rgba(31, 29, 26, 0.08), 0 2px 4px rgba(31, 29, 26, 0.05);
  --shadow-lg:  0 10px 28px rgba(31, 29, 26, 0.10), 0 4px 8px rgba(31, 29, 26, 0.05);
  --shadow-xl:  0 24px 56px rgba(31, 29, 26, 0.14), 0 8px 16px rgba(31, 29, 26, 0.06);
  --shadow-focus: 0 0 0 3px var(--color-focus-ring);
  --shadow-gold:  0 6px 18px rgba(200, 144, 42, 0.28);

  /* === 11. Bordures === */
  --border-width:1px; --border-width-strong:2px;
  --border-hairline:1px solid var(--color-border);

  /* === 12. Z-index === */
  --z-base:0; --z-raised:10; --z-sticky:100; --z-header:200; --z-dropdown:300;
  --z-overlay:400; --z-modal:500; --z-popover:600; --z-toast:700; --z-tooltip:800;

  /* === 13. Motion === */
  --ease-standard:   cubic-bezier(0.2, 0, 0, 1);
  --ease-emphasized: cubic-bezier(0.3, 0, 0, 1);
  --ease-out:        cubic-bezier(0.16, 1, 0.3, 1);
  --duration-instant:80ms; --duration-fast:140ms; --duration-base:220ms; --duration-slow:360ms;
  --transition-colors: color var(--duration-fast) var(--ease-standard),
                       background-color var(--duration-fast) var(--ease-standard),
                       border-color var(--duration-fast) var(--ease-standard);
  --transition-base:   all var(--duration-base) var(--ease-standard);
}

@media (prefers-reduced-motion: reduce) {
  :root {
    --duration-instant:0ms; --duration-fast:0ms; --duration-base:0ms; --duration-slow:0ms;
  }
}

/* ==========================================================================
   RESET / BASE
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  color: var(--color-text);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
}

/* Atmosphère : grain papier subtil sur le fond global */
body.has-grain::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.5;
  background-image:
    radial-gradient(circle at 18% 20%, rgba(200,144,42,0.06), transparent 42%),
    radial-gradient(circle at 88% 8%, rgba(200,144,42,0.05), transparent 38%);
  /* Isole l'overlay fixe sur sa propre couche GPU → plus de repaint à chaque frame de scroll
     (corrige le défilement « rigide/saccadé »). */
  transform: translateZ(0);
  will-change: transform;
  backface-visibility: hidden;
}

/* Défilement fluide global (momentum tactile + ancrage doux déjà actif sur <html>). */
body { -webkit-overflow-scrolling: touch; }

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
/* Jamais de soulignement au survol/focus (neutralise le legacy Bootstrap). */
a:hover, a:focus, a:active, .nav-item:hover, .nav-item:focus { text-decoration: none !important; }
button { font-family: inherit; cursor: pointer; }
ul { list-style: none; padding: 0; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  letter-spacing: var(--tracking-tight);
  color: var(--color-ink);
  font-optical-sizing: auto;
}

:focus-visible {
  outline: none;
  box-shadow: var(--shadow-focus);
  border-radius: var(--radius-xs);
}

::selection { background: var(--color-gold-soft); color: var(--color-ink); }

.mono { font-family: var(--font-mono); font-feature-settings: "tnum"; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* ==========================================================================
   LAYOUT HELPERS
   ========================================================================== */
.container { width: 100%; max-width: var(--container-xl); margin-inline: auto; padding-inline: var(--space-6); }
.container--lg { max-width: var(--container-lg); }
.container--md { max-width: var(--container-md); }
.section { padding-block: clamp(3.5rem, 2rem + 6vw, 7rem); }
.eyebrow {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-size: var(--text-xs); font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-caps); text-transform: uppercase;
  color: var(--color-gold-hover);
}
.eyebrow::before {
  content: ""; width: 22px; height: 2px; border-radius: var(--radius-pill);
  background: linear-gradient(90deg, var(--color-gold), transparent);
}
.section__head { max-width: 56ch; margin-bottom: var(--space-12); }
.section__head h2 { font-size: var(--text-2xl); margin-top: var(--space-3); }
.section__head p { color: var(--color-text-muted); font-size: var(--text-md); margin-top: var(--space-4); }
.lead { font-size: var(--text-md); color: var(--color-text-muted); line-height: var(--leading-relaxed); }

/* ==========================================================================
   BOUTONS
   ========================================================================== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2);
  min-height: 44px; padding: var(--space-3) var(--space-6);
  font-family: var(--font-sans); font-size: var(--text-sm); font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-wide);
  border: 1px solid transparent; border-radius: var(--radius-md);
  transition: var(--transition-colors), transform var(--duration-fast) var(--ease-standard), box-shadow var(--duration-base) var(--ease-standard);
  white-space: nowrap; user-select: none;
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 18px; height: 18px; flex: none; }

.btn--primary { background: var(--color-gold); color: var(--color-ink); box-shadow: var(--shadow-xs); }
.btn--primary:hover { background: var(--color-gold-hover); color: var(--color-paper); box-shadow: var(--shadow-gold); }

.btn--secondary { background: var(--color-ink); color: var(--color-paper); }
.btn--secondary:hover { background: var(--color-ink-soft); box-shadow: var(--shadow-md); }

.btn--ghost { background: transparent; color: var(--color-ink); border-color: var(--color-border-strong); }
.btn--ghost:hover { background: var(--color-gold-tint); border-color: var(--color-gold-soft); }

.btn--danger { background: var(--color-error); color: #fff; }
.btn--danger:hover { background: var(--color-error-hover); }

.btn--block { width: 100%; }
.btn--lg { min-height: 52px; padding: var(--space-4) var(--space-8); font-size: var(--text-base); }
.btn--sm { min-height: 36px; padding: var(--space-2) var(--space-4); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.5; pointer-events: none; }

.link-arrow {
  display: inline-flex; align-items: center; gap: var(--space-2);
  font-weight: var(--weight-semibold); color: var(--color-ink);
  border-bottom: 1.5px solid var(--color-gold-soft); padding-bottom: 2px;
  transition: var(--transition-colors);
}
.link-arrow:hover { border-color: var(--color-gold); color: var(--color-gold-hover); }
.link-arrow svg { width: 16px; height: 16px; transition: transform var(--duration-base) var(--ease-out); }
.link-arrow:hover svg { transform: translateX(3px); }

/* ==========================================================================
   CARTES & BADGES
   ========================================================================== */
.card {
  background: var(--color-surface);
  border: var(--border-hairline);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--space-6);
}
.card--interactive { transition: var(--transition-base); }
.card--interactive:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); border-color: var(--color-gold-soft); }

.badge {
  display: inline-flex; align-items: center; gap: var(--space-2);
  padding: var(--space-1) var(--space-3); border-radius: var(--radius-pill);
  font-size: var(--text-xs); font-weight: var(--weight-semibold);
  letter-spacing: var(--tracking-wide); line-height: 1.4;
}
.badge svg { width: 13px; height: 13px; flex: none; }
.badge--delivered { background: var(--color-success-soft); color: var(--color-success); }
.badge--failed    { background: var(--color-error-soft);   color: var(--color-error); }
.badge--stored    { background: var(--color-neutral-100);  color: var(--color-neutral-700); }
.badge--pending   { background: var(--color-warning-soft); color: var(--color-gold-hover); }
.badge--info      { background: var(--color-info-soft);    color: var(--color-info); }

/* ==========================================================================
   INPUTS / FORMULAIRES
   ========================================================================== */
.field { display: flex; flex-direction: column; gap: var(--space-2); margin-bottom: var(--space-5); }
.field label { font-size: var(--text-sm); font-weight: var(--weight-semibold); color: var(--color-ink); }
.input, .textarea, .select {
  width: 100%; min-height: 44px; padding: var(--space-3) var(--space-4);
  font-family: var(--font-sans); font-size: var(--text-base); color: var(--color-ink);
  background: var(--color-surface); border: 1px solid var(--color-border-strong);
  border-radius: var(--radius-md); transition: var(--transition-colors), box-shadow var(--duration-fast) var(--ease-standard);
}
.input::placeholder { color: var(--color-neutral-400); }
.input:focus, .textarea:focus, .select:focus {
  outline: none; border-color: var(--color-gold); box-shadow: var(--shadow-focus);
}
.field--error .input { border-color: var(--color-error); }
.field__hint { font-size: var(--text-sm); color: var(--color-text-muted); }
.field__error { font-size: var(--text-sm); color: var(--color-error); }

.input-icon { position: relative; }
.input-icon svg { position: absolute; left: var(--space-4); top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--color-neutral-400); pointer-events: none; }
.input-icon .input { padding-left: calc(var(--space-4) * 2 + 18px); }

.check { display: inline-flex; align-items: center; gap: var(--space-2); font-size: var(--text-sm); color: var(--color-text-muted); cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--color-gold); }

/* ==========================================================================
   HEADER MARKETING
   ========================================================================== */
.site-header {
  position: sticky; top: 0; z-index: var(--z-header);
  background: rgba(250, 247, 240, 0.82);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--duration-base) var(--ease-standard), box-shadow var(--duration-base) var(--ease-standard);
}
.site-header.is-scrolled { border-bottom-color: var(--color-border); box-shadow: var(--shadow-sm); }
.site-header__inner { display: flex; align-items: center; gap: var(--space-8); height: 72px; }
.brand { display: inline-flex; align-items: center; }
.brand img { height: 34px; width: auto; }
.site-nav { display: flex; align-items: center; gap: var(--space-2); margin-left: auto; }
.site-nav a {
  padding: var(--space-2) var(--space-3); font-size: 1.05rem; font-weight: var(--weight-medium);
  color: var(--color-text-muted); border-radius: var(--radius-sm); transition: var(--transition-colors);
}
.site-nav a:hover { color: var(--color-ink); background: var(--color-gold-tint); }
.header-actions { display: flex; align-items: center; gap: var(--space-3); }
.header-actions .login-link { font-size: var(--text-sm); font-weight: var(--weight-semibold); color: var(--color-ink); padding: var(--space-2) var(--space-3); }
.header-actions .login-link:hover { color: var(--color-gold-hover); }
.nav-toggle { display: none; align-items: center; justify-content: center; width: 44px; height: 44px; border: 1px solid var(--color-border-strong); border-radius: var(--radius-md); background: var(--color-surface); }
.nav-toggle svg { width: 22px; height: 22px; }

/* ==========================================================================
   HERO
   ========================================================================== */
.hero { position: relative; overflow: hidden; padding-block: clamp(3rem, 1.5rem + 7vw, 6.5rem); }
.hero__bg {
  position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(120% 90% at 78% -10%, rgba(200,144,42,0.16), transparent 55%),
    radial-gradient(80% 70% at -5% 110%, rgba(30,122,82,0.07), transparent 55%);
}
.hero__bg::after {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--color-border) 1px, transparent 1px),
    linear-gradient(90deg, var(--color-border) 1px, transparent 1px);
  background-size: 64px 64px;
  -webkit-mask-image: radial-gradient(70% 60% at 70% 30%, #000, transparent 75%);
          mask-image: radial-gradient(70% 60% at 70% 30%, #000, transparent 75%);
  opacity: 0.35;
}
.hero__inner { position: relative; z-index: 1; display: grid; grid-template-columns: 1.15fr 0.85fr; gap: var(--space-12); align-items: center; }
.hero__title { font-size: var(--text-display); letter-spacing: -0.03em; }
.hero__title .accent { color: var(--color-gold); font-style: italic; font-weight: 500; }
.hero__sub { margin-top: var(--space-6); max-width: 52ch; font-size: var(--text-md); color: var(--color-text-muted); line-height: var(--leading-relaxed); }
.hero__cta { display: flex; flex-wrap: wrap; gap: var(--space-4); margin-top: var(--space-8); }
.hero__meta { display: flex; flex-wrap: wrap; gap: var(--space-6); margin-top: var(--space-10); padding-top: var(--space-6); border-top: var(--border-hairline); }
.hero__meta-item { display: flex; flex-direction: column; gap: 2px; }
.hero__meta-item strong { font-family: var(--font-display); font-size: var(--text-xl); color: var(--color-ink); letter-spacing: var(--tracking-tight); }
.hero__meta-item span { font-size: var(--text-sm); color: var(--color-text-muted); }

/* Mockup téléphone du hero */
.hero__visual { position: relative; display: flex; justify-content: center; }
.phone {
  width: min(300px, 80%); background: var(--color-ink); border-radius: 36px;
  padding: 12px; box-shadow: var(--shadow-xl); position: relative;
}
.phone::before { content: ""; position: absolute; top: 18px; left: 50%; transform: translateX(-50%); width: 70px; height: 6px; border-radius: var(--radius-pill); background: rgba(255,255,255,0.18); }
.phone__screen { background: var(--color-paper); border-radius: 26px; padding: var(--space-5) var(--space-4) var(--space-6); min-height: 440px; display: flex; flex-direction: column; gap: var(--space-3); }
.phone__top { display: flex; align-items: center; gap: var(--space-2); padding-bottom: var(--space-3); border-bottom: var(--border-hairline); margin-top: var(--space-4); }
.phone__top .dot { width: 34px; height: 34px; border-radius: var(--radius-full); background: var(--color-gold-tint); display: grid; place-items: center; color: var(--color-gold-hover); font-family: var(--font-display); font-weight: 700; font-size: var(--text-sm); }
.phone__top .who { font-size: var(--text-sm); font-weight: var(--weight-semibold); }
.phone__top .who span { display: block; font-size: var(--text-xs); font-weight: var(--weight-regular); color: var(--color-text-muted); }
.sms-bubble { background: var(--color-surface); border: var(--border-hairline); border-radius: var(--radius-lg) var(--radius-lg) var(--radius-lg) 4px; padding: var(--space-3) var(--space-4); font-size: var(--text-sm); box-shadow: var(--shadow-xs); }
.sms-bubble .src { display: block; font-size: var(--text-xs); font-weight: 700; color: var(--color-gold-hover); letter-spacing: var(--tracking-wide); margin-bottom: 2px; }
.sms-bubble .time { display: block; margin-top: var(--space-2); font-size: 0.66rem; color: var(--color-neutral-400); }
.phone__dlr { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); padding: var(--space-3) var(--space-4); background: var(--color-success-soft); border-radius: var(--radius-md); font-size: var(--text-xs); color: var(--color-success); font-weight: var(--weight-semibold); }

/* ==========================================================================
   BANDEAU CONFIANCE
   ========================================================================== */
.trust { padding-block: var(--space-12); border-block: var(--border-hairline); background: var(--color-surface); }
.trust__label { text-align: center; font-size: var(--text-sm); color: var(--color-text-muted); max-width: 60ch; margin-inline: auto; margin-bottom: var(--space-8); }
.trust__logos { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: var(--space-3) var(--space-6); }
.client-chip {
  display: inline-flex; align-items: center; gap: var(--space-2);
  padding: var(--space-2) var(--space-5); border-radius: var(--radius-pill);
  background: var(--color-paper); border: var(--border-hairline);
  font-family: var(--font-display); font-weight: var(--weight-semibold); font-size: var(--text-base);
  letter-spacing: var(--tracking-tight); color: var(--color-ink-soft);
}
.client-chip::before { content: ""; width: 7px; height: 7px; border-radius: var(--radius-full); background: var(--color-gold); }

/* ==========================================================================
   VALEURS (4 blocs)
   ========================================================================== */
.values { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-5); }
.value { position: relative; padding: var(--space-6); background: var(--color-surface); border: var(--border-hairline); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.value__num { font-family: var(--font-mono); font-size: var(--text-xs); color: var(--color-gold-hover); letter-spacing: var(--tracking-wide); }
.value h3 { font-size: var(--text-lg); margin: var(--space-3) 0 var(--space-2); }
.value p { font-size: var(--text-sm); color: var(--color-text-muted); line-height: var(--leading-relaxed); }

/* ==========================================================================
   FONCTIONNALITÉS (grille de cartes)
   ========================================================================== */
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5); }
.feature { padding: var(--space-6); }
.feature__icon {
  width: 48px; height: 48px; border-radius: var(--radius-md);
  display: grid; place-items: center; margin-bottom: var(--space-5);
  background: var(--color-gold-tint); color: var(--color-gold-hover);
  border: 1px solid var(--color-gold-soft);
}
.feature__icon svg { width: 24px; height: 24px; }
.feature h3 { font-size: var(--text-lg); margin-bottom: var(--space-2); }
.feature p { font-size: var(--text-sm); color: var(--color-text-muted); line-height: var(--leading-relaxed); }

/* ==========================================================================
   COMMENT ÇA MARCHE
   ========================================================================== */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-8); position: relative; }
.step { position: relative; }
.step__num {
  width: 56px; height: 56px; border-radius: var(--radius-full);
  display: grid; place-items: center; margin-bottom: var(--space-5);
  font-family: var(--font-display); font-weight: var(--weight-bold); font-size: var(--text-lg);
  color: var(--color-ink); background: var(--color-gold); box-shadow: var(--shadow-gold);
}
.step h3 { font-size: var(--text-lg); margin-bottom: var(--space-2); }
.step p { font-size: var(--text-sm); color: var(--color-text-muted); line-height: var(--leading-relaxed); }
.step:not(:last-child)::after {
  content: ""; position: absolute; top: 28px; left: calc(56px + var(--space-4)); right: calc(-1 * var(--space-8) + var(--space-2));
  height: 2px; background: repeating-linear-gradient(90deg, var(--color-gold-soft) 0 8px, transparent 8px 16px);
}

/* ==========================================================================
   TARIFS
   ========================================================================== */
.pricing { display: grid; grid-template-columns: 1.1fr 1fr; gap: var(--space-6); align-items: stretch; }
.price-card { display: flex; flex-direction: column; padding: var(--space-8); }
.price-card--feature { background: var(--color-ink); color: var(--color-paper); border-color: var(--color-ink); position: relative; overflow: hidden; }
.price-card--feature::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(120% 80% at 110% -10%, rgba(200,144,42,0.30), transparent 55%);
}
.price-card--feature > * { position: relative; z-index: 1; }
.price-card--feature h3 { color: var(--color-paper); }
.price-tag { display: flex; align-items: baseline; gap: var(--space-2); margin: var(--space-4) 0; }
.price-tag .amount { font-family: var(--font-display); font-size: var(--text-2xl); font-weight: var(--weight-bold); letter-spacing: var(--tracking-tight); }
.price-card--feature .price-tag .amount { color: var(--color-gold-soft); }
.price-tag .unit { font-size: var(--text-sm); color: var(--color-text-muted); }
.price-card--feature .price-tag .unit { color: var(--color-neutral-300); }
.price-list { display: flex; flex-direction: column; gap: var(--space-3); margin: var(--space-4) 0 var(--space-6); }
.price-list li { display: flex; align-items: flex-start; gap: var(--space-3); font-size: var(--text-sm); color: var(--color-text-muted); }
.price-card--feature .price-list li { color: var(--color-neutral-200); }
.price-list svg { width: 18px; height: 18px; flex: none; margin-top: 2px; color: var(--color-success); }
.price-card--feature .price-list svg { color: var(--color-gold-soft); }
.price-card .btn { margin-top: auto; }
.price-note { font-size: var(--text-sm); color: var(--color-text-muted); margin-top: var(--space-6); text-align: center; }

/* ==========================================================================
   FAQ (accordéon)
   ========================================================================== */
.faq { max-width: var(--container-md); margin-inline: auto; }
.faq__item { border-bottom: var(--border-hairline); }
.faq__item summary {
  display: flex; align-items: center; justify-content: space-between; gap: var(--space-4);
  padding: var(--space-5) 0; cursor: pointer; list-style: none;
  font-family: var(--font-display); font-size: var(--text-lg); color: var(--color-ink); font-weight: var(--weight-semibold);
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__icon { flex: none; width: 28px; height: 28px; border-radius: var(--radius-full); display: grid; place-items: center; border: 1px solid var(--color-border-strong); transition: var(--transition-base); }
.faq__icon svg { width: 16px; height: 16px; }
.faq__item[open] .faq__icon { background: var(--color-gold); border-color: var(--color-gold); transform: rotate(45deg); }
.faq__answer { padding: 0 0 var(--space-6); color: var(--color-text-muted); font-size: var(--text-base); line-height: var(--leading-relaxed); max-width: 64ch; }

/* ==========================================================================
   CTA FINAL
   ========================================================================== */
.cta-final { position: relative; overflow: hidden; border-radius: var(--radius-2xl); background: var(--color-ink); color: var(--color-paper); padding: clamp(2.5rem, 1.5rem + 4vw, 4.5rem); text-align: center; }
.cta-final::before { content: ""; position: absolute; inset: 0; background: radial-gradient(90% 120% at 50% -20%, rgba(200,144,42,0.32), transparent 60%); }
.cta-final::after {
  content: ""; position: absolute; inset: 0; opacity: 0.25;
  background-image: linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  -webkit-mask-image: radial-gradient(60% 60% at 50% 0%, #000, transparent 80%);
          mask-image: radial-gradient(60% 60% at 50% 0%, #000, transparent 80%);
}
.cta-final > * { position: relative; z-index: 1; }
.cta-final h2 { color: var(--color-paper); font-size: var(--text-2xl); }
.cta-final p { color: var(--color-neutral-300); margin: var(--space-4) auto var(--space-8); max-width: 48ch; font-size: var(--text-md); }

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer { background: var(--color-surface); border-top: var(--border-hairline); padding-block: var(--space-16) var(--space-8); margin-top: var(--space-12); }
.footer-grid { display: grid; grid-template-columns: 1.6fr repeat(4, 1fr); gap: var(--space-8); }
.footer-brand img { height: 32px; margin-bottom: var(--space-4); }
.footer-brand p { font-size: var(--text-sm); color: var(--color-text-muted); max-width: 32ch; line-height: var(--leading-relaxed); }
.footer-col h4 { font-family: var(--font-sans); font-size: var(--text-xs); text-transform: uppercase; letter-spacing: var(--tracking-caps); color: var(--color-neutral-500); margin-bottom: var(--space-4); }
.footer-col ul { display: flex; flex-direction: column; gap: var(--space-3); }
.footer-col a, .footer-col li { font-size: var(--text-sm); color: var(--color-text-muted); transition: var(--transition-colors); }
.footer-col a:hover { color: var(--color-gold-hover); }
.footer-bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-4); margin-top: var(--space-12); padding-top: var(--space-6); border-top: var(--border-hairline); font-size: var(--text-sm); color: var(--color-text-muted); }
.footer-legal { display: flex; flex-wrap: wrap; gap: var(--space-5); }

/* ==========================================================================
   LOGIN (split layout)
   ========================================================================== */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth__form-side { display: flex; flex-direction: column; padding: var(--space-8) clamp(1.5rem, 1rem + 4vw, 5rem); }
.auth__form-side .brand { margin-bottom: auto; }
.auth__form-side .brand img { height: 36px; }
.auth__card { width: 100%; max-width: 420px; margin-block: var(--space-12); align-self: center; }
.auth__card h1 { font-size: var(--text-2xl); }
.auth__card .sub { color: var(--color-text-muted); margin-top: var(--space-3); margin-bottom: var(--space-8); }
.auth__row { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); margin-bottom: var(--space-6); }
.auth__row a { font-size: var(--text-sm); font-weight: var(--weight-semibold); color: var(--color-gold-hover); }
.auth__foot { margin-top: auto; padding-top: var(--space-8); font-size: var(--text-sm); color: var(--color-text-muted); }
.auth__foot a { font-weight: var(--weight-semibold); color: var(--color-ink); border-bottom: 1.5px solid var(--color-gold-soft); }
.auth__signup { margin-top: var(--space-6); text-align: center; font-size: var(--text-sm); color: var(--color-text-muted); }
.auth__signup a { font-weight: var(--weight-semibold); color: var(--color-ink); border-bottom: 1.5px solid var(--color-gold-soft); }

.auth__brand-side {
  position: relative; overflow: hidden; color: var(--color-paper);
  background: var(--color-ink); display: flex; flex-direction: column; justify-content: space-between;
  padding: clamp(2rem, 1rem + 4vw, 4rem);
}
.auth__brand-side::before { content: ""; position: absolute; inset: 0; background: radial-gradient(100% 80% at 90% 0%, rgba(200,144,42,0.30), transparent 55%), radial-gradient(80% 70% at -10% 100%, rgba(30,122,82,0.16), transparent 55%); }
.auth__brand-side::after {
  content: ""; position: absolute; inset: 0; opacity: 0.22;
  background-image: linear-gradient(rgba(255,255,255,0.06) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.06) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(80% 80% at 80% 20%, #000, transparent 80%);
          mask-image: radial-gradient(80% 80% at 80% 20%, #000, transparent 80%);
}
.auth__brand-side > * { position: relative; z-index: 1; }
.auth__brand-logo img { height: 38px; }
.auth__brand-quote { font-family: var(--font-display); font-size: var(--text-xl); line-height: var(--leading-snug); letter-spacing: var(--tracking-tight); color: var(--color-paper); max-width: 22ch; background: transparent; border: 0; padding: 0; margin: 0; }
.auth__brand-quote .accent { color: var(--color-gold-soft); font-style: italic; }
.auth__proof { display: flex; flex-direction: column; gap: var(--space-5); }
.auth__proof-stats { display: flex; gap: var(--space-8); }
.auth__proof-stats .stat strong { display: block; font-family: var(--font-display); font-size: var(--text-xl); color: var(--color-gold-soft); letter-spacing: var(--tracking-tight); }
.auth__proof-stats .stat span { font-size: var(--text-sm); color: var(--color-neutral-300); }
.auth__proof-clients { display: flex; flex-wrap: wrap; gap: var(--space-2) var(--space-4); font-size: var(--text-sm); color: var(--color-neutral-300); font-family: var(--font-display); }
.auth__proof-clients span { opacity: 0.85; }

/* ==========================================================================
   APP — SHELL (sidebar + topbar)
   ========================================================================== */
body.app { background: var(--color-surface-sunken); }
.app-shell { display: grid; grid-template-columns: 300px 1fr; min-height: 100vh; }

.sidebar {
  position: sticky; top: 0; height: 100vh; align-self: start;
  display: flex; flex-direction: column; gap: var(--space-2);
  background: var(--color-ink); color: var(--color-neutral-300);
  padding: var(--space-5) var(--space-4); overflow-y: auto;
  z-index: var(--z-sticky);
}
.sidebar__brand { display: flex; align-items: center; gap: var(--space-3); padding: var(--space-2) var(--space-2) var(--space-5); }
.sidebar__brand .mark { width: 38px; height: 38px; border-radius: var(--radius-sm); background: var(--color-surface); padding: 5px; box-shadow: var(--shadow-sm); }
.sidebar__brand .name { font-family: var(--font-display); font-weight: var(--weight-bold); font-size: var(--text-md); color: var(--color-paper); letter-spacing: var(--tracking-tight); }
.sidebar__brand .name b { color: var(--color-gold); font-weight: var(--weight-bold); }
.sidebar__brand .sidebar__logo { height: 30px; width: auto; }

.sidebar__cta { margin-bottom: var(--space-4); }
.sidebar__cta .btn { width: 100%; }

.nav-section { margin-top: var(--space-4); }
.nav-section__label { font-size: 0.92rem; text-transform: uppercase; letter-spacing: var(--tracking-caps); color: var(--color-neutral-500); padding: 0 var(--space-3) var(--space-2); font-weight: var(--weight-semibold); }
.nav-item {
  display: flex; align-items: center; gap: var(--space-3);
  padding: var(--space-3) var(--space-3); border-radius: var(--radius-md);
  font-size: 1.4rem; font-weight: var(--weight-medium); color: var(--color-neutral-300);
  transition: var(--transition-colors); position: relative;
}
.nav-item svg { width: 26px; height: 26px; flex: none; opacity: 0.85; }
.nav-item:hover { background: transparent; }
.nav-item.is-active { background: rgba(200,144,42,0.16); color: var(--color-paper); }
.nav-item.is-active::before { content: ""; position: absolute; left: 0; top: 8px; bottom: 8px; width: 3px; border-radius: var(--radius-pill); background: var(--color-gold); }
.nav-item.is-active svg { color: var(--color-gold); opacity: 1; }
.nav-item .tag { margin-left: auto; font-size: 0.6rem; background: var(--color-gold); color: var(--color-ink); padding: 1px 7px; border-radius: var(--radius-pill); font-weight: var(--weight-bold); }
.sidebar__foot { margin-top: auto; padding-top: var(--space-4); }
.nav-item--muted { color: var(--color-neutral-500); }

/* zone principale */
.app-main { display: flex; flex-direction: column; min-width: 0; }

.topbar {
  position: sticky; top: 0; z-index: var(--z-sticky);
  display: flex; align-items: center; gap: var(--space-4);
  height: 64px; padding-inline: var(--space-6);
  background: rgba(255,255,255,0.85); backdrop-filter: blur(12px) saturate(140%);
  border-bottom: var(--border-hairline);
}
.topbar__menu-btn { display: none; align-items: center; justify-content: center; width: 42px; height: 42px; border: 1px solid var(--color-border-strong); border-radius: var(--radius-md); background: var(--color-surface); }
.topbar__menu-btn svg { width: 22px; height: 22px; }
.topbar__search { position: relative; flex: 1; max-width: 360px; }
.topbar__search svg { position: absolute; left: var(--space-3); top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--color-neutral-400); }
.topbar__search input { width: 100%; height: 42px; padding-left: calc(var(--space-3) * 2 + 18px); border: 1px solid var(--color-border); border-radius: var(--radius-pill); background: var(--color-surface-sunken); font-size: var(--text-sm); }
.topbar__search input:focus { outline: none; border-color: var(--color-gold); box-shadow: var(--shadow-focus); background: var(--color-surface); }
.topbar__right { margin-left: auto; display: flex; align-items: center; gap: var(--space-4); }

.balance {
  display: flex; align-items: center; gap: var(--space-3);
  padding: var(--space-2) var(--space-4); border-radius: var(--radius-pill);
  background: var(--color-gold-tint); border: 1px solid var(--color-gold-soft);
}
.balance__icon { width: 30px; height: 30px; border-radius: var(--radius-full); background: var(--color-gold); display: grid; place-items: center; color: var(--color-ink); }
.balance__icon svg { width: 17px; height: 17px; }
.balance__data { line-height: 1.2; }
.balance__data .credits { font-family: var(--font-mono); font-weight: var(--weight-medium); font-size: var(--text-sm); color: var(--color-ink); }
.balance__data .equiv { font-size: var(--text-xs); color: var(--color-gold-hover); }
.balance__recharge { font-size: var(--text-xs); font-weight: var(--weight-semibold); color: var(--color-gold-hover); padding-left: var(--space-3); border-left: 1px solid var(--color-gold-soft); }

.account-menu { display: flex; align-items: center; gap: var(--space-3); padding: var(--space-1) var(--space-2); border-radius: var(--radius-pill); transition: var(--transition-colors); }
.account-menu:hover { background: var(--color-surface-sunken); }
.account-menu .avatar { width: 38px; height: 38px; border-radius: var(--radius-full); background: var(--color-ink); color: var(--color-gold-soft); display: grid; place-items: center; font-family: var(--font-display); font-weight: var(--weight-bold); font-size: var(--text-sm); }
.account-menu .who { line-height: 1.25; }
.account-menu .who strong { font-size: var(--text-sm); font-weight: var(--weight-semibold); display: block; }
.account-menu .who span { font-size: var(--text-xs); color: var(--color-text-muted); }
.account-menu .caret { width: 16px; height: 16px; color: var(--color-neutral-400); }

/* contenu app */
.app-content { padding: var(--space-8) var(--space-6) var(--space-12); max-width: 1280px; width: 100%; margin-inline: auto; }
.page-head { margin-bottom: var(--space-8); }
.page-head__welcome { font-size: var(--text-xs); text-transform: uppercase; letter-spacing: var(--tracking-caps); color: var(--color-gold-hover); font-weight: var(--weight-semibold); }
.page-head h1 { font-size: var(--text-2xl); margin-top: var(--space-2); }
.page-head p { color: var(--color-text-muted); margin-top: var(--space-2); }
/* Tableau de bord : titre réduit (-25%), "Bonjour X" sur la même ligne, en-tête resserré. */
.page-head--tight { margin-bottom: var(--space-5); }
.page-head--tight p { margin-top: var(--space-1); }
.page-head--dash { margin-bottom: var(--space-4); }
.page-head--dash h1 { font-size: calc(var(--text-2xl) * 0.75); margin-top: 0; }
.page-head--dash p { margin-top: var(--space-1); }
.page-head__hello { font-family: var(--font-sans); font-size: var(--text-base); font-weight: var(--weight-regular);
  color: var(--color-text-muted); letter-spacing: 0; text-transform: none; margin-left: var(--space-3); white-space: nowrap; }

/* grille KPI */
.kpi-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: var(--space-5); margin-bottom: var(--space-8); }
.kpi { background: var(--color-surface); border: var(--border-hairline); border-radius: var(--radius-lg); padding: var(--space-5); box-shadow: var(--shadow-sm); }
.kpi__label { display: flex; align-items: center; gap: var(--space-2); font-size: var(--text-sm); color: var(--color-text-muted); font-weight: var(--weight-medium); }
.kpi__label svg { width: 16px; height: 16px; color: var(--color-gold-hover); }
.kpi__value { font-family: var(--font-display); font-size: var(--text-2xl); font-weight: var(--weight-bold); letter-spacing: var(--tracking-tight); margin-top: var(--space-3); }
.kpi__value .unit { font-size: var(--text-sm); font-family: var(--font-sans); font-weight: var(--weight-medium); color: var(--color-text-muted); margin-left: var(--space-1); }
.kpi__trend { display: inline-flex; align-items: center; gap: 4px; margin-top: var(--space-2); font-size: var(--text-xs); font-weight: var(--weight-semibold); color: var(--color-success); }
.kpi__trend svg { width: 13px; height: 13px; }

/* carte solde (KPI proéminent) */
.kpi--balance { background: var(--color-ink); color: var(--color-paper); border-color: var(--color-ink); position: relative; overflow: hidden; }
.kpi--balance::before { content: ""; position: absolute; inset: 0; background: radial-gradient(120% 90% at 110% -20%, rgba(200,144,42,0.32), transparent 55%); }
.kpi--balance > * { position: relative; z-index: 1; }
.kpi--balance .kpi__label { color: var(--color-neutral-300); }
.kpi--balance .kpi__label svg { color: var(--color-gold-soft); }
.kpi--balance .kpi__value { color: var(--color-gold-soft); }
.kpi--balance .kpi__sub { font-size: var(--text-sm); color: var(--color-neutral-300); margin-top: var(--space-1); }
.kpi--balance .kpi__sub b { color: var(--color-paper); font-family: var(--font-mono); }
.kpi--balance .btn { margin-top: var(--space-4); }

/* progression circulaire taux */
.donut { width: 56px; height: 56px; }
.donut__track { fill: none; stroke: var(--color-neutral-100); stroke-width: 6; }
.donut__val { fill: none; stroke: var(--color-success); stroke-width: 6; stroke-linecap: round; transform: rotate(-90deg); transform-origin: center; }
.kpi__rate { display: flex; align-items: center; gap: var(--space-4); margin-top: var(--space-3); }
.kpi__rate .num { font-family: var(--font-display); font-size: var(--text-2xl); font-weight: var(--weight-bold); }

/* actions rapides */
.quick-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-4); margin-bottom: var(--space-8); }
.quick-action { display: flex; align-items: center; gap: var(--space-4); padding: var(--space-4) var(--space-5); background: var(--color-surface); border: var(--border-hairline); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); transition: var(--transition-base); }
.quick-action:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); border-color: var(--color-gold-soft); }
.quick-action__icon { width: 44px; height: 44px; border-radius: var(--radius-md); display: grid; place-items: center; background: var(--color-gold-tint); color: var(--color-gold-hover); border: 1px solid var(--color-gold-soft); flex: none; }
.quick-action__icon svg { width: 22px; height: 22px; }
.quick-action__text strong { display: block; font-size: var(--text-sm); font-weight: var(--weight-semibold); color: var(--color-ink); }
.quick-action__text span { font-size: var(--text-xs); color: var(--color-text-muted); }
.quick-action .arrow { margin-left: auto; color: var(--color-neutral-400); transition: transform var(--duration-base) var(--ease-out); }
.quick-action:hover .arrow { transform: translateX(3px); color: var(--color-gold-hover); }
.quick-action .arrow svg { width: 18px; height: 18px; }

/* panneau analytique (2 col) */
.app-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: var(--space-5); align-items: stretch; }
.app-grid > .panel { display: flex; flex-direction: column; }
.app-grid > .panel > .panel__body { flex: 1 1 auto; }
.panel { background: var(--color-surface); border: var(--border-hairline); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); overflow: hidden; }
.panel__head { display: flex; align-items: center; justify-content: space-between; gap: var(--space-4); padding: var(--space-5) var(--space-6); border-bottom: var(--border-hairline); }
.panel__head h2 { font-size: var(--text-lg); }
.panel__head a { font-size: var(--text-sm); font-weight: var(--weight-semibold); color: var(--color-gold-hover); }
.panel__body { padding: var(--space-5) var(--space-6); }

/* mini graphique barres CSS/SVG */
.chart { display: flex; align-items: flex-end; gap: var(--space-3); height: 180px; padding-top: var(--space-4); }
.chart__col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: var(--space-2); height: 100%; justify-content: flex-end; }
.chart__bars { display: flex; align-items: flex-end; gap: 3px; width: 100%; height: 100%; justify-content: center; }
.chart__bar { width: 11px; border-radius: var(--radius-xs) var(--radius-xs) 0 0; transition: height var(--duration-slow) var(--ease-out); }
.chart__bar--sent { background: var(--color-gold-soft); }
.chart__bar--delivered { background: var(--color-gold); }
.chart__label { font-size: var(--text-xs); color: var(--color-text-muted); }
.chart-legend { display: flex; gap: var(--space-5); margin-top: var(--space-5); font-size: var(--text-xs); color: var(--color-text-muted); }
.chart-legend span { display: inline-flex; align-items: center; gap: var(--space-2); }
.chart-legend i { width: 11px; height: 11px; border-radius: 3px; display: inline-block; }

/* table d'activité */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: var(--text-sm); }
.table th { text-align: left; padding: var(--space-3) var(--space-4); font-size: var(--text-xs); text-transform: uppercase; letter-spacing: var(--tracking-wide); color: var(--color-neutral-500); font-weight: var(--weight-semibold); border-bottom: var(--border-hairline); white-space: nowrap; }
.table td { padding: var(--space-4); border-bottom: var(--border-hairline); vertical-align: middle; }
.table tr:last-child td { border-bottom: none; }
.table tbody tr { transition: background-color var(--duration-fast) var(--ease-standard); }
.table tbody tr:hover { background: var(--color-surface-sunken); }
.table .campaign { font-weight: var(--weight-semibold); color: var(--color-ink); }
.table .campaign small { display: block; font-weight: var(--weight-regular); color: var(--color-text-muted); font-size: var(--text-xs); }
.table .num { font-family: var(--font-mono); }
.table .sender { display: inline-flex; align-items: center; gap: var(--space-2); }
.table .sender::before { content: ""; width: 6px; height: 6px; border-radius: var(--radius-full); background: var(--color-gold); }

/* liste compacte (panneau latéral) */
.mini-list { display: flex; flex-direction: column; gap: var(--space-4); }
.mini-list__item { display: flex; align-items: center; gap: var(--space-3); }
.mini-list__icon { width: 36px; height: 36px; border-radius: var(--radius-md); display: grid; place-items: center; flex: none; }
.mini-list__icon svg { width: 18px; height: 18px; }
.mini-list__icon--ok { background: var(--color-success-soft); color: var(--color-success); }
.mini-list__icon--warn { background: var(--color-warning-soft); color: var(--color-gold-hover); }
.mini-list__icon--info { background: var(--color-info-soft); color: var(--color-info); }
.mini-list__text { min-width: 0; }
.mini-list__text strong { display: block; font-size: var(--text-sm); font-weight: var(--weight-semibold); }
.mini-list__text span { font-size: var(--text-xs); color: var(--color-text-muted); }
.mini-list__meta { margin-left: auto; font-family: var(--font-mono); font-size: var(--text-xs); color: var(--color-text-muted); white-space: nowrap; }

/* drawer overlay (mobile) */
.scrim { display: none; position: fixed; inset: 0; background: rgba(31,29,26,0.5); backdrop-filter: blur(2px); z-index: var(--z-overlay); }
.scrim.is-open { display: block; }

/* ==========================================================================
   ANIMATIONS D'ENTRÉE (échelonnées)
   ========================================================================== */
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes growBar { from { height: 0; } }

.reveal { opacity: 0; animation: rise var(--duration-slow) var(--ease-out) forwards; }
.reveal-1 { animation-delay: 0.05s; }
.reveal-2 { animation-delay: 0.13s; }
.reveal-3 { animation-delay: 0.21s; }
.reveal-4 { animation-delay: 0.29s; }
.reveal-5 { animation-delay: 0.37s; }
.reveal-6 { animation-delay: 0.45s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; animation: none; }
  .chart__bar { transition: none; }
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 1024px) {
  .hero__inner { grid-template-columns: 1fr; gap: var(--space-10); }
  .hero__visual { order: -1; }
  .phone { width: min(260px, 70%); }
  .values { grid-template-columns: repeat(2, 1fr); }
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
  .app-grid { grid-template-columns: 1fr; }
  .kpi-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 880px) {
  .site-nav, .header-actions .login-link, .header-actions .btn--ghost { display: none; }
  .nav-toggle { display: inline-flex; }
  .auth { grid-template-columns: 1fr; }
  .auth__brand-side { display: none; }
  .pricing { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; gap: var(--space-10); }
  .step:not(:last-child)::after { display: none; }
  .quick-actions { grid-template-columns: 1fr; }

  /* app : sidebar en drawer */
  .app-shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed; top: 0; left: 0; width: 300px; height: 100vh;
    transform: translateX(-100%); transition: transform var(--duration-base) var(--ease-standard);
    z-index: var(--z-modal); box-shadow: var(--shadow-xl);
  }
  .sidebar.is-open { transform: translateX(0); }
  .topbar__menu-btn { display: inline-flex; }
  .balance__recharge { display: none; }
}

@media (max-width: 640px) {
  .values { grid-template-columns: 1fr; }
  .features-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .kpi-grid { grid-template-columns: 1fr; }
  .container { padding-inline: var(--space-4); }
  .topbar__search { display: none; }
  .account-menu .who { display: none; }
  .hero__meta { gap: var(--space-5); }
  .balance__data .equiv { display: none; }
}

/* ==========================================================================
   Refonte 2026 — Durcissement contre le CSS legacy (contexte app `body.app`)
   Le thème legacy (Bootstrap/essentials) applique un clearfix
   `::before/::after { content:" "; display:table }` sur les <section>.
   Dans un conteneur `display:grid`, ces pseudo-éléments deviennent des items
   de grille FANTÔMES qui décalent les cartes (KPI sur 2 rangées, panneaux
   désalignés). On les neutralise sur nos conteneurs de mise en page.
   ========================================================================== */
body.app .kpi-grid::before,      body.app .kpi-grid::after,
body.app .app-grid::before,      body.app .app-grid::after,
body.app .quick-actions::before, body.app .quick-actions::after,
body.app .app-shell::before,     body.app .app-shell::after,
body.app .app-main::before,      body.app .app-main::after,
body.app .topbar::before,        body.app .topbar::after,
body.app .topbar__right::before, body.app .topbar__right::after,
body.app .kpi::before,           body.app .kpi::after {
  content: none !important;
  display: none !important;
}

/* Le thème legacy (landing page) impose `section { padding: 80px 0 }` + un
   border-bottom : ~160px d'espace vide vertical par bloc. On neutralise dans la
   zone de contenu app ; l'espacement est géré par les marges du design system. */
body.app .app-content > section,
body.app .app-content > div {
  padding: 0 !important;
  border-bottom: 0 !important;
}
/* Espacement vertical cohérent et compact entre les blocs du tableau de bord. */
body.app .app-content > section,
body.app .app-content > .kpi-grid {
  margin-bottom: var(--space-6) !important;
}
body.app .app-content > section:last-child { margin-bottom: 0 !important; }
/* Gaps horizontaux resserrés sur les rangées actions rapides + activité/DLR. */
body.app .quick-actions { gap: var(--space-2) !important; }
body.app .app-grid { gap: var(--space-3) !important; }

/* Typographie 2026 — DM Serif Display (titres) n'a qu'une graisse : on coupe la
   synthèse de graisse pour éviter le faux-gras (les graisses absentes retombent
   sur la vraie graisse disponible). DM Sans/DM Mono ont leurs vraies graisses. */
html, body { font-synthesis: none; }

/* ==========================================================================
   Refonte 2026 — Vague 2 : loader pro, tables modernisées (GridView legacy),
   couche d'animations d'interaction.
   ========================================================================== */

/* ---- 1. Loader professionnel (remplace les gifs) ----------------------- */
.wsx-loader { display:flex; flex-direction:column; align-items:center; justify-content:center;
  gap:var(--space-4); padding:var(--space-10) var(--space-6); min-height:180px; width:100%; text-align:center; }
.wsx-loader--inline { flex-direction:row; min-height:0; padding:var(--space-3); gap:var(--space-3); }
.wsx-loader__spinner { width:46px; height:46px; border-radius:var(--radius-full);
  border:3.5px solid var(--color-gold-tint); border-top-color:var(--color-gold);
  animation:wsx-spin .8s cubic-bezier(0.5,0.15,0.4,0.85) infinite; }
.wsx-loader--inline .wsx-loader__spinner { width:22px; height:22px; border-width:2.5px; }
.wsx-loader__label { font-family:var(--font-sans); font-size:var(--text-sm); color:var(--color-text-muted); }
@keyframes wsx-spin { to { transform:rotate(360deg); } }
@media (prefers-reduced-motion: reduce){ .wsx-loader__spinner{ animation-duration:1.6s; } }

/* ---- 2. Tables modernisées : GridView Yii + tables app ----------------- */
body.app .grid-view { background:var(--color-surface); border:var(--border-hairline);
  border-radius:var(--radius-lg); box-shadow:var(--shadow-sm); overflow:hidden; }
body.app .grid-view > table, body.app table.table { width:100%; border-collapse:collapse !important;
  margin:0; font-size:var(--text-sm); background:transparent; }
body.app .grid-view thead > tr > th, body.app table.table > thead > tr > th {
  background:var(--color-gold-tint); color:var(--color-ink); font-family:var(--font-sans);
  font-size:var(--text-xs); font-weight:var(--weight-semibold); text-transform:uppercase;
  letter-spacing:var(--tracking-wide); padding:var(--space-3) var(--space-4) !important;
  border:0 !important; border-bottom:1px solid var(--color-gold-soft) !important;
  white-space:nowrap; vertical-align:middle; }
body.app .grid-view thead th a { color:var(--color-ink); }
body.app .grid-view > table > tbody > tr > td, body.app table.table > tbody > tr > td {
  padding:var(--space-3) var(--space-4) !important; border:0 !important;
  border-bottom:var(--border-hairline) !important; vertical-align:middle;
  color:var(--color-ink-soft); background:transparent; }
body.app .grid-view > table > tbody > tr:last-child > td { border-bottom:0 !important; }
body.app .table-bordered, body.app .table-bordered > tbody > tr > td,
body.app .table-bordered > thead > tr > th { border-left:0 !important; border-right:0 !important; border-top:0 !important; }
body.app .table-striped > tbody > tr:nth-of-type(odd) > td { background:transparent; }
body.app .grid-view tbody > tr, body.app table.table tbody > tr {
  transition:background-color var(--duration-fast) var(--ease-standard); }
body.app .grid-view tbody > tr:hover, body.app table.table tbody > tr:hover { background:var(--color-gold-tint) !important; }
body.app .grid-view tbody > tr:hover td { color:var(--color-ink); }
body.app .grid-view .summary { padding:var(--space-3) var(--space-4); font-size:var(--text-xs);
  color:var(--color-text-muted); border-bottom:var(--border-hairline); }
body.app .grid-view .empty { padding:var(--space-8); text-align:center; color:var(--color-text-muted); }
body.app .pagination { display:flex; flex-wrap:wrap; gap:var(--space-1); list-style:none;
  padding:var(--space-3) var(--space-4); margin:0; justify-content:flex-end; }
body.app .pagination > li > a, body.app .pagination > li > span { display:inline-flex; align-items:center;
  justify-content:center; min-width:32px; height:32px; padding:0 var(--space-2); border:var(--border-hairline);
  border-radius:var(--radius-sm); background:var(--color-surface); color:var(--color-ink-soft);
  font-size:var(--text-sm); text-decoration:none; transition:var(--transition-colors); }
body.app .pagination > li > a:hover { background:var(--color-gold-tint); border-color:var(--color-gold-soft); }
body.app .pagination > .active > a, body.app .pagination > .active > span {
  background:var(--color-ink); color:var(--color-paper); border-color:var(--color-ink); }

/* ---- 3. Animations d'interaction --------------------------------------- */
body.app .app-content { animation:fade var(--duration-base) var(--ease-out) both; }
body.app .kpi, body.app .quick-action { transition:transform var(--duration-base) var(--ease-out),
  box-shadow var(--duration-base) var(--ease-out), border-color var(--duration-fast) var(--ease-standard); }
body.app .kpi:hover { transform:translateY(-3px); box-shadow:var(--shadow-md); }
body.app .quick-action:hover { transform:translateY(-3px); box-shadow:var(--shadow-md); border-color:var(--color-gold-soft); }
body.app .quick-action:hover .arrow { transform:translateX(4px); color:var(--color-gold-hover); }
body.app .panel { transition:box-shadow var(--duration-base) var(--ease-out); }
body.app .panel:hover { box-shadow:var(--shadow-md); }
.btn:active { transform:translateY(1px) scale(0.99); }
body.app .nav-item { transition:background-color var(--duration-fast) var(--ease-standard),
  color var(--duration-fast) var(--ease-standard), transform var(--duration-base) var(--ease-out); }
body.app .nav-item:not(.is-active):hover { transform:none; }
body.app .panel__head a { transition:color var(--duration-base) var(--ease-out); padding-bottom:1px; }
body.app input:not([type=checkbox]):not([type=radio]):not([type=submit]):focus,
body.app select:focus, body.app textarea:focus { outline:none;
  border-color:var(--color-gold) !important; box-shadow:0 0 0 3px var(--color-gold-tint) !important; }
@media (prefers-reduced-motion: reduce){
  body.app .kpi:hover, body.app .quick-action:hover, body.app .nav-item:hover { transform:none; }
}

/* ---- Menu « Mon compte » (dropdown topbar) ----------------------------- */
.account { position:relative; }
.account-menu .caret { transition:transform var(--duration-base) var(--ease-out); }
.account.is-open .caret { transform:rotate(180deg); }
.account-dropdown { position:absolute; top:calc(100% + 10px); right:0; width:300px; max-width:calc(100vw - 32px);
  background:var(--color-surface); border:var(--border-hairline); border-radius:var(--radius-lg);
  box-shadow:var(--shadow-lg); padding:var(--space-4); z-index:var(--z-dropdown);
  transform-origin:top right; animation:acct-in var(--duration-base) var(--ease-out); }
.account-dropdown[hidden] { display:none; }
@keyframes acct-in { from { opacity:0; transform:translateY(-6px) scale(0.98); } to { opacity:1; transform:none; } }
.account-dropdown__head { display:flex; align-items:center; gap:var(--space-3);
  padding-bottom:var(--space-3); margin-bottom:var(--space-3); border-bottom:var(--border-hairline); }
.avatar--lg { width:46px; height:46px; font-size:var(--text-md); flex:none;
  border-radius:var(--radius-full); background:var(--color-ink); color:var(--color-gold-soft);
  display:grid; place-items:center; font-family:var(--font-display); font-weight:var(--weight-bold); }
.account-dropdown__id { min-width:0; }
.account-dropdown__id strong { display:block; font-family:var(--font-sans); font-weight:var(--weight-semibold);
  color:var(--color-ink); font-size:var(--text-sm); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.account-badge { display:inline-block; margin-top:3px; font-size:var(--text-xs); font-weight:var(--weight-semibold);
  color:var(--color-gold-hover); background:var(--color-gold-tint); padding:1px var(--space-2); border-radius:var(--radius-pill); }
.account-dropdown__info { margin:0 0 var(--space-3); display:grid; gap:var(--space-2); }
.account-dropdown__info > div { display:flex; align-items:baseline; justify-content:space-between; gap:var(--space-4); }
.account-dropdown__info dt { font-size:var(--text-xs); color:var(--color-text-muted); flex:none; }
.account-dropdown__info dd { margin:0; font-size:var(--text-sm); color:var(--color-ink); text-align:right; word-break:break-word; }
.account-dropdown__info .account-solde { font-family:var(--font-mono); font-weight:var(--weight-medium); color:var(--color-gold-hover); }
.account-dropdown__recharge { justify-content:center; margin-bottom:var(--space-2); }
.account-dropdown__foot { border-top:var(--border-hairline); padding-top:var(--space-2); margin-top:var(--space-2); }
.account-dropdown__foot a { display:flex; align-items:center; gap:var(--space-3); padding:var(--space-2) var(--space-3);
  border-radius:var(--radius-md); font-size:var(--text-sm); color:var(--color-ink-soft); transition:var(--transition-colors); }
.account-dropdown__foot a svg { width:18px; height:18px; flex:none; }
.account-dropdown__foot a:hover { background:var(--color-error-soft); color:var(--color-error); }

/* ---- Wizard d'envoi (stepper + compose 2 panneaux + aperçu) ------------ */
.wizard-steps { display:flex; align-items:center; list-style:none; padding:0; margin:0 0 var(--space-6); }
.wizard-steps li { display:flex; align-items:center; gap:var(--space-2); font-size:var(--text-sm);
  color:var(--color-text-muted); white-space:nowrap; }
.wizard-steps li:not(:last-child) { flex:1; }
.wizard-steps li:not(:last-child)::after { content:""; flex:1; height:1.5px; background:var(--color-border);
  margin:0 var(--space-3); min-width:20px; }
.wizard-steps__num { width:28px; height:28px; border-radius:var(--radius-full); display:grid; place-items:center;
  font-weight:var(--weight-semibold); font-size:var(--text-sm); background:var(--color-surface);
  border:1.5px solid var(--color-border-strong); color:var(--color-text-muted); flex:none;
  transition:var(--transition-colors); }
.wizard-steps li.is-active { color:var(--color-ink); font-weight:var(--weight-semibold); }
.wizard-steps li.is-active .wizard-steps__num { background:var(--color-gold); border-color:var(--color-gold); color:var(--color-ink); }
.wizard-steps li.is-done { color:var(--color-ink-soft); }
.wizard-steps li.is-done .wizard-steps__num { background:var(--color-ink); border-color:var(--color-ink); color:var(--color-gold-soft); }

.compose { display:grid; grid-template-columns:minmax(0,1fr) 350px; gap:var(--space-6); align-items:start; }
.compose__aside { position:sticky; top:var(--space-6); display:grid; gap:var(--space-5); }
.sms-phone { background:var(--color-ink); border-radius:30px; padding:var(--space-3); box-shadow:var(--shadow-lg); }
.sms-phone__notch { width:42%; height:6px; background:var(--color-neutral-700); border-radius:var(--radius-full); margin:2px auto var(--space-2); }
.sms-phone__screen { background:var(--color-surface-sunken); border-radius:20px; padding:var(--space-4); min-height:280px;
  display:flex; flex-direction:column; gap:var(--space-2); }
.sms-phone__sender { font-size:var(--text-xs); color:var(--color-text-muted); text-align:center; margin-bottom:var(--space-2); }
.sms-bubble { background:var(--color-surface); border:var(--border-hairline); border-radius:16px 16px 16px 5px;
  padding:var(--space-3) var(--space-4); font-size:var(--text-sm); line-height:1.5; color:var(--color-ink);
  max-width:88%; align-self:flex-start; white-space:pre-wrap; word-break:break-word; box-shadow:var(--shadow-xs); }
.sms-bubble:empty::before { content:"Votre message apparaîtra ici…"; color:var(--color-text-muted); font-style:italic; }
.recap { background:var(--color-surface); border:var(--border-hairline); border-radius:var(--radius-lg);
  box-shadow:var(--shadow-sm); padding:var(--space-5); }
.recap h3 { font-size:var(--text-md); margin-bottom:var(--space-3); }
.recap__row { display:flex; justify-content:space-between; align-items:baseline; padding:var(--space-2) 0;
  border-bottom:var(--border-hairline); font-size:var(--text-sm); }
.recap__row:last-of-type { border-bottom:0; }
.recap__row dt { color:var(--color-text-muted); margin:0; }
.recap__row dd { margin:0; font-family:var(--font-mono); color:var(--color-ink); }
.recap__cost { margin-top:var(--space-3); padding-top:var(--space-3); border-top:2px solid var(--color-gold-soft);
  display:flex; justify-content:space-between; align-items:baseline; }
.recap__cost .label { font-weight:var(--weight-semibold); color:var(--color-ink); }
.recap__cost .amount { font-family:var(--font-display); font-size:var(--text-xl); color:var(--color-gold-hover); }
.recap__note { margin:var(--space-3) 0 0; font-size:var(--text-xs); color:var(--color-text-muted); }
@media (max-width:960px){ .compose { grid-template-columns:1fr; } .compose__aside { position:static; } }

/* ---- Page de contact --------------------------------------------------- */
.contact-page { padding:var(--space-12) 0 var(--space-16); }
.contact-page .page-head { margin-bottom:var(--space-8); }
.contact-grid { display:grid; grid-template-columns:1.4fr 1fr; gap:var(--space-6); align-items:start; }
.contact-aside { display:grid; gap:var(--space-5); }
.contact-card { background:var(--color-surface); border:var(--border-hairline); border-radius:var(--radius-lg);
  box-shadow:var(--shadow-sm); padding:var(--space-6); }
.contact-card .form-group { margin-bottom:var(--space-4); }
.contact-card label { font-size:var(--text-sm); font-weight:var(--weight-semibold); color:var(--color-ink);
  display:block; margin-bottom:var(--space-2); }
.contact-card .form-control, .contact-page input[type=text], .contact-page textarea {
  width:100%; padding:var(--space-3) var(--space-4); border:var(--border-hairline); border-radius:var(--radius-md);
  font-family:var(--font-sans); font-size:var(--text-base); color:var(--color-ink); background:var(--color-surface);
  transition:border-color var(--duration-base) var(--ease-standard), box-shadow var(--duration-base) var(--ease-standard); }
.contact-card .form-control:focus, .contact-page input[type=text]:focus, .contact-page textarea:focus {
  outline:none; border-color:var(--color-gold); box-shadow:0 0 0 3px var(--color-gold-tint); }
.contact-card .help-block { color:var(--color-error); font-size:var(--text-xs); margin-top:var(--space-1); }
.contact-page .captcha-row { display:flex; gap:var(--space-3); align-items:center; }
.contact-page .captcha-row img { border:var(--border-hairline); border-radius:var(--radius-sm); }
.contact-info h3 { font-size:var(--text-md); margin-bottom:var(--space-2); }
.contact-info a:not(.btn) { color:var(--color-gold-hover); font-weight:var(--weight-semibold); }
.contact-muted { color:var(--color-text-muted); font-size:var(--text-sm); }
@media (max-width:760px){ .contact-grid { grid-template-columns:1fr; } }

/* ---- Responsive : tableaux scrollables horizontalement sur mobile ------ */
/* `.grid-view` clippe (overflow:hidden) pour les coins arrondis ; sur petit
   écran on autorise le défilement horizontal pour ne pas couper les colonnes. */
@media (max-width:760px){
  body.app .grid-view { overflow-x:auto; -webkit-overflow-scrolling:touch; }
  body.app .grid-view > table { min-width:560px; }
  body.app .wizard-steps { font-size:var(--text-xs); }
  body.app .wizard-steps li:not(:last-child)::after { min-width:10px; margin:0 var(--space-2); }
}

/* ==========================================================================
   Harmonisation charte WASSA v1 — orange (#FF8A00) réservé aux CTA et états
   actifs ; texte fort, chiffres et liens en bleu nuit ; surfaces claires.
   (Bloc final : prime sur les usages "or comme texte" hérités.)
   ========================================================================== */

/* Bouton primaire : orange + texte BLANC (charte §8). */
.btn--primary, .btn--primary:hover { color: #FFFFFF; }

/* Tableaux : en-tête gris clair + texte bleu nuit, survol gris clair (pas d'orange). */
body.app .grid-view thead > tr > th, body.app table.table > thead > tr > th {
  background: var(--color-surface-sunken); color: var(--color-ink);
  border-bottom: 1px solid var(--color-border-strong) !important;
}
body.app .grid-view tbody > tr:hover, body.app table.table tbody > tr:hover { background: var(--color-surface-sunken) !important; }

/* Chiffres forts, soldes, taux et liens : bleu nuit (orange = action uniquement). */
.value__num,
.price-tag .amount, .price-card .amount,
.recap__cost .amount,
.kpi__rate .num,
.account-dropdown__info .account-solde,
.balance__data .credits,
.panel__head a, .contact-info a:not(.btn) { color: var(--color-ink); }

/* Footer (graphite) selon la charte. */
.site-footer { background: var(--color-graphite); }

/* Soulignement de lien : accent orange conservé au survol. */
.panel__head a:hover { color: var(--color-gold-hover); }

/* Échelle agrandie : éviter que quelques chiffres-clés ne se coupent. */
.kpi__rate, .kpi__rate .num { white-space: nowrap; }
.hero__meta { row-gap: var(--space-4); }

/* Icônes modernisées (shim wassasms-icons.js) : on masque l'ancien glyphe
   Font Awesome/Glyphicon (::before) et on dimensionne le SVG injecté. */
.wsx-ico { display: inline-flex; align-items: center; justify-content: center; line-height: 0; }
.wsx-ico::before { content: "" !important; display: none !important; }
.wsx-ico svg { width: 1em; height: 1em; }

/* ---- Sélecteur de langue (drapeaux FR/EN) ------------------------------ */
.lang-switch { display:inline-flex; align-items:center; gap:2px; padding:3px; border-radius:var(--radius-full);
  background:var(--color-surface-sunken); border:var(--border-hairline); }
.lang-switch__btn { display:inline-flex; align-items:center; gap:var(--space-2); padding:5px var(--space-3);
  border-radius:var(--radius-full); color:var(--color-text-muted); font-size:var(--text-sm);
  font-weight:var(--weight-semibold); text-decoration:none; line-height:1; transition:var(--transition-base); }
.lang-switch__btn:hover { color:var(--color-ink); background:var(--color-surface); }
.lang-switch__btn.is-active { color:var(--color-ink); background:var(--color-surface); box-shadow:var(--shadow-sm); }
.lang-switch__flag { display:inline-flex; width:20px; height:14px; border-radius:3px; overflow:hidden;
  box-shadow:0 0 0 1px rgba(0,0,0,.08); }
.lang-switch__flag svg { width:100%; height:100%; display:block; object-fit:cover; }
.lang-switch__code { letter-spacing:.02em; }
.lang-switch-fixed { position:fixed; top:16px; right:16px; z-index:60; }
@media (max-width:560px){ .lang-switch__code { display:none; } }

/* ---- Dialogue moderne : toasts + animations aux moments clés ----------- */
.wsx-toasts { position:fixed; top:18px; right:18px; z-index:1000; display:flex; flex-direction:column;
  gap:10px; max-width:min(92vw, 380px); pointer-events:none; }
.wsx-toast { pointer-events:auto; display:flex; align-items:flex-start; gap:10px; padding:12px 14px;
  border-radius:var(--radius-lg); background:var(--color-surface); box-shadow:var(--shadow-md);
  border:var(--border-hairline); border-left:4px solid var(--color-ink);
  opacity:0; transform:translateX(22px) scale(.98); transition:opacity .28s var(--ease-out), transform .28s var(--ease-out); }
.wsx-toast.is-in { opacity:1; transform:none; }
.wsx-toast.is-out { opacity:0; transform:translateX(22px) scale(.98); }
.wsx-toast--success { border-left-color:var(--color-success); }
.wsx-toast--error   { border-left-color:var(--color-error); }
.wsx-toast--warning { border-left-color:var(--color-gold); }
.wsx-toast__ic { flex:none; width:22px; height:22px; color:var(--color-ink-soft); }
.wsx-toast--success .wsx-toast__ic { color:var(--color-success); }
.wsx-toast--error .wsx-toast__ic   { color:var(--color-error); }
.wsx-toast--warning .wsx-toast__ic { color:var(--color-gold-hover); }
.wsx-toast__ic svg { width:22px; height:22px; }
.wsx-toast__msg { flex:1; font-size:var(--text-sm); color:var(--color-ink); line-height:1.45; }
.wsx-toast__x { flex:none; border:none; background:transparent; font-size:18px; line-height:1;
  color:var(--color-text-muted); cursor:pointer; padding:0 2px; }
.wsx-toast__x:hover { color:var(--color-ink); }
/* utilitaires d'animation coordonnée (validation, lancement) */
@keyframes wsx-pop { 0%{transform:scale(1)} 35%{transform:scale(1.06)} 70%{transform:scale(.985)} 100%{transform:scale(1)} }
.wsx-pop { animation:wsx-pop .45s var(--ease-out); }
@keyframes wsx-launch { 0%{transform:translateY(0) scale(1);opacity:1} 55%{transform:translateY(-10px) scale(1.03)}
  100%{transform:translateY(-64px) scale(.55);opacity:0} }
.wsx-launch { animation:wsx-launch .7s var(--ease-out) forwards; }
@media (prefers-reduced-motion: reduce) { .wsx-pop, .wsx-launch { animation:none; } .wsx-toast { transition:opacity .2s; } }

/* ---- Assistant IA (wizard d'envoi) ------------------------------------- */
.ai-assist { border:1.5px solid var(--color-gold-soft); background:var(--color-gold-tint);
  border-radius:var(--radius-lg); padding:var(--space-4); margin-bottom:var(--space-5); }
.ai-assist__bar { display:flex; align-items:center; justify-content:space-between; gap:var(--space-3);
  margin-bottom:var(--space-3); }
.ai-assist__brand { display:inline-flex; align-items:center; gap:var(--space-2); font-weight:var(--weight-semibold);
  color:var(--color-ink); }
.ai-assist__brand svg { width:18px; height:18px; color:var(--color-gold-hover); }
.ai-assist__credits { font-size:var(--text-sm); font-weight:var(--weight-semibold); color:var(--color-gold-hover);
  background:var(--color-surface); border-radius:var(--radius-full); padding:2px var(--space-3); }
.ai-assist__row { display:flex; gap:var(--space-2); }
.ai-assist__brief { flex:1; min-width:0; padding:var(--space-3) var(--space-4); border:var(--border-hairline);
  border-radius:var(--radius-md); font-family:var(--font-sans); font-size:var(--text-base); color:var(--color-ink);
  background:var(--color-surface); }
.ai-assist__brief:focus { outline:none; border-color:var(--color-gold); box-shadow:0 0 0 3px var(--color-gold-tint); }
.ai-assist__tools { display:flex; flex-wrap:wrap; gap:var(--space-2); margin-top:var(--space-3); }
.ai-assist__msg { margin:var(--space-3) 0 0; font-size:var(--text-sm); color:var(--color-ink-soft); min-height:1.2em;
  white-space:pre-line; }
.ai-assist__msg.is-err { color:var(--color-error); }

/* ---- Recharge (montants + moyens de paiement) -------------------------- */
.amount-chips { display:flex; flex-wrap:wrap; gap:var(--space-3); }
.amount-chip { padding:var(--space-3) var(--space-5); border:1.5px solid var(--color-border-strong);
  border-radius:var(--radius-md); background:var(--color-surface); color:var(--color-ink); font-family:var(--font-sans);
  font-weight:var(--weight-semibold); font-size:var(--text-base); cursor:pointer; transition:var(--transition-base); }
.amount-chip span { color:var(--color-text-muted); font-weight:var(--weight-medium); font-size:var(--text-sm); }
.amount-chip:hover { border-color:var(--color-gold-soft); }
.amount-chip.is-selected { border-color:var(--color-gold); background:var(--color-gold-tint); }
.amount-custom { margin-top:var(--space-5); }
.amount-custom label { display:block; font-size:var(--text-sm); font-weight:var(--weight-semibold); margin-bottom:var(--space-2); }
.amount-custom input { width:100%; max-width:320px; padding:var(--space-3) var(--space-4); border:var(--border-hairline);
  border-radius:var(--radius-md); font-family:var(--font-sans); font-size:var(--text-base); color:var(--color-ink); }
.amount-custom input:focus { outline:none; border-color:var(--color-gold); box-shadow:0 0 0 3px var(--color-gold-tint); }
.pay-methods { display:grid; grid-template-columns:repeat(auto-fit, minmax(190px, 1fr)); gap:var(--space-4); }
.pay-method { display:flex; align-items:center; gap:var(--space-4); text-align:left; padding:var(--space-4) var(--space-5);
  border:1.5px solid var(--color-border-strong); border-radius:var(--radius-lg); background:var(--color-surface);
  cursor:pointer; transition:var(--transition-base); }
.pay-method:hover { border-color:var(--color-gold-soft); }
.pay-method.is-selected { border-color:var(--color-gold); background:var(--color-gold-tint); }
.pay-method__icon { width:44px; height:44px; flex:none; border-radius:var(--radius-md); display:grid; place-items:center;
  background:var(--color-surface-sunken); color:var(--color-ink); }
.pay-method__icon svg { width:22px; height:22px; }
.pay-method__text { display:flex; flex-direction:column; min-width:0; }
.pay-method__text strong { font-size:var(--text-base); color:var(--color-ink); }
.pay-method__text small { font-size:var(--text-sm); color:var(--color-text-muted); }
.pay-method__check { margin-left:auto; width:24px; height:24px; flex:none; border-radius:var(--radius-full); display:grid;
  place-items:center; background:var(--color-gold); color:#fff; opacity:0; transform:scale(0.6); transition:var(--transition-base); }
.pay-method__check svg { width:15px; height:15px; }
.pay-method.is-selected .pay-method__check { opacity:1; transform:scale(1); }
.recharge-summary { max-width:520px; }
/* Wizard de recharge : colonne unique centrée, compacte (une étape visible) */
.recharge-wizard { max-width:640px; margin:0 auto; }
.recharge-wizard .wizard-steps { margin-bottom:var(--space-5); }
.recharge-wizard .panel__body { padding:var(--space-5) var(--space-6); }
.wz-pane { animation:wz-fade var(--duration-base) var(--ease-out); }
.wz-pane[hidden] { display:none; }
@keyframes wz-fade { from { opacity:0; transform:translateY(4px); } to { opacity:1; transform:none; } }
.wz-nav { display:flex; align-items:center; gap:var(--space-3); margin-top:var(--space-5); }
.wz-nav .btn--primary { margin-left:auto; }
.wz-confirm-line { display:flex; justify-content:space-between; align-items:center; gap:var(--space-3);
  padding:var(--space-3) 0; border-bottom:var(--border-hairline); }
.wz-confirm-line:last-of-type { border-bottom:0; }
.wz-confirm-line span:first-child { color:var(--color-text-muted); }
.wz-confirm-line strong { font-family:var(--font-mono); color:var(--color-ink); font-weight:var(--weight-semibold); }
@media (max-width:680px){ .pay-methods { grid-template-columns:1fr; } }
.pay-result { width:72px; height:72px; border-radius:var(--radius-full); display:grid; place-items:center; margin:0 auto; }
.pay-result svg { width:38px; height:38px; }
.pay-result--ok { background:var(--color-success-soft); color:var(--color-success); }
.pay-result--err { background:var(--color-error-soft); color:var(--color-error); }
.pay-result--pending { background:var(--color-gold-tint); color:var(--color-gold-hover); }

/* ---- Bulle de support flottante (assistant IA — ossature) -------------- */
.wsx-support { position:fixed; right:20px; bottom:20px; z-index:var(--z-toast); font-family:var(--font-sans); }
.wsx-support__launcher { width:60px; height:60px; border-radius:var(--radius-full); border:none; background:var(--color-gold);
  color:#fff; box-shadow:var(--shadow-lg); cursor:pointer; display:grid; place-items:center; transition:var(--transition-base); }
.wsx-support__launcher:hover { background:var(--color-gold-hover); transform:translateY(-2px); }
.wsx-support__launcher svg { width:26px; height:26px; }
.wsx-support__launcher .ic-close { display:none; }
.wsx-support.is-open .wsx-support__launcher .ic-open { display:none; }
.wsx-support.is-open .wsx-support__launcher .ic-close { display:block; }
.wsx-support__panel { position:absolute; right:0; bottom:74px; width:360px; max-width:calc(100vw - 32px);
  max-height:min(560px, calc(100vh - 110px)); background:var(--color-surface); border:var(--border-hairline);
  border-radius:var(--radius-lg); box-shadow:var(--shadow-lg); display:flex; flex-direction:column; overflow:hidden;
  animation:acct-in var(--duration-base) var(--ease-out); }
.wsx-support__panel[hidden] { display:none; }
.wsx-support__head { display:flex; align-items:center; gap:var(--space-3); padding:var(--space-4) var(--space-5);
  background:var(--color-ink); color:var(--color-paper); }
.wsx-support__avatar { width:38px; height:38px; flex:none; border-radius:var(--radius-full); background:rgba(255,255,255,0.12);
  display:grid; place-items:center; color:var(--color-gold-soft); }
.wsx-support__avatar svg { width:20px; height:20px; }
.wsx-support__title { display:flex; flex-direction:column; line-height:1.2; min-width:0; }
.wsx-support__title strong { font-size:var(--text-base); }
.wsx-support__title span { font-size:var(--text-xs); color:var(--color-neutral-300); }
.wsx-support__x { margin-left:auto; background:none; border:none; color:var(--color-neutral-300); cursor:pointer; }
.wsx-support__x svg { width:20px; height:20px; }
.wsx-support__body { padding:var(--space-5); overflow-y:auto; flex:1; }
.wsx-support__intro { font-size:var(--text-sm); color:var(--color-text-muted); margin-bottom:var(--space-4); line-height:1.5; }
.wsx-label { display:block; font-size:var(--text-xs); font-weight:var(--weight-semibold); color:var(--color-ink); margin:var(--space-3) 0 var(--space-1); }
.wsx-input { width:100%; padding:var(--space-3) var(--space-4); border:var(--border-hairline); border-radius:var(--radius-md);
  font-family:var(--font-sans); font-size:var(--text-base); color:var(--color-ink); }
.wsx-input:focus { outline:none; border-color:var(--color-gold); box-shadow:0 0 0 3px var(--color-gold-tint); }
.wsx-otp { text-align:center; letter-spacing:0.4em; font-size:var(--text-lg); font-family:var(--font-mono); }
.wsx-textlink { display:block; margin:var(--space-3) auto 0; background:none; border:none; color:var(--color-text-muted);
  font-size:var(--text-sm); cursor:pointer; }
.wsx-support__msg { font-size:var(--text-sm); margin-top:var(--space-3); min-height:1em; }
.wsx-support__msg.is-ok { color:var(--color-success); }
.wsx-support__msg.is-err { color:var(--color-error); }
.wsx-chat { display:flex; flex-direction:column; gap:var(--space-3); }
.wsx-msg { max-width:85%; padding:var(--space-3) var(--space-4); border-radius:14px; font-size:var(--text-sm); line-height:1.5; white-space:pre-wrap; }
.wsx-msg--bot { align-self:flex-start; background:var(--color-surface-sunken); color:var(--color-ink); border-bottom-left-radius:4px; }
.wsx-msg--me { align-self:flex-end; background:var(--color-gold); color:#fff; border-bottom-right-radius:4px; }
.wsx-typing { color:var(--color-text-muted); }
.wsx-support__foot { display:flex; gap:var(--space-2); padding:var(--space-3) var(--space-4); border-top:var(--border-hairline); }
.wsx-support__foot[hidden] { display:none; }
.wsx-support__foot .wsx-input { flex:1; }
.wsx-send { flex:none; width:42px; border:none; border-radius:var(--radius-md); background:var(--color-gold); color:#fff;
  cursor:pointer; display:grid; place-items:center; }
.wsx-send svg { width:18px; height:18px; }
@media (max-width:480px){ .wsx-support__panel { width:calc(100vw - 32px); } }

/* ── Menu latéral en accordéon animé (Lot 3.4) ───────────────────────────── */
.nav-section__toggle { display:flex; align-items:center; gap:var(--space-2); width:100%;
  background:none; border:0; padding:0 var(--space-3); margin:0 0 var(--space-2); color:inherit; font:inherit;
  text-align:left; cursor:pointer; -webkit-appearance:none; }
.nav-section__toggle .nav-section__label { margin:0; padding:0; flex:1; }
.nav-section__chevron { width:13px; height:13px; flex:none; opacity:.55;
  transition:transform var(--duration-base) var(--ease-out); }
.nav-section.is-collapsed .nav-section__chevron { transform:rotate(-90deg); }
.nav-section__toggle:hover .nav-section__chevron { opacity:.9; }
/* Animation de hauteur fluide sans calcul JS (grid 1fr → 0fr). */
.nav-section__items { display:grid; grid-template-rows:1fr;
  transition:grid-template-rows var(--duration-base) var(--ease-out); }
.nav-section.is-collapsed .nav-section__items { grid-template-rows:0fr; }
.nav-section__items-inner { overflow:hidden; min-height:0; display:flex; flex-direction:column; gap:2px; }

/* ── Sélecteur de canal d'envoi (Lot 3.1) ────────────────────────────────── */
.channel-picker { display:flex; flex-wrap:wrap; gap:var(--space-3); margin:0 0 var(--space-5); }
.channel-card { flex:1 1 120px; min-width:120px; display:flex; flex-direction:column; align-items:center;
  gap:6px; padding:var(--space-4) var(--space-2); border:1.5px solid var(--color-border);
  border-radius:var(--radius-lg); background:var(--color-surface); cursor:pointer; position:relative;
  text-align:center; transition:border-color var(--duration-base) var(--ease-out), background var(--duration-base) var(--ease-out); }
.channel-card svg { width:26px; height:26px; color:var(--color-ink-soft); }
.channel-card__name { font-size:var(--text-sm); font-weight:var(--weight-semibold); color:var(--color-ink); }
.channel-card.is-active { border-color:var(--color-gold); background:var(--color-gold-tint); box-shadow:var(--shadow-xs); }
.channel-card.is-active svg { color:var(--color-gold); }
.channel-card.is-soon { cursor:not-allowed; opacity:.55; }
.channel-card__badge { position:absolute; top:-9px; right:8px; font-size:.58rem; font-weight:var(--weight-bold);
  background:var(--color-ink); color:var(--color-gold-soft); padding:1px 7px; border-radius:var(--radius-pill);
  text-transform:uppercase; letter-spacing:.04em; }

/* ── Nettoyage intelligent de la liste de destinataires (Lot 3.2) ────────── */
.list-clean { display:flex; align-items:center; gap:var(--space-3); flex-wrap:wrap; margin:var(--space-2) 0 var(--space-4); }
.list-clean__stats { font-size:var(--text-sm); color:var(--color-text-muted); }
.list-clean__stats b { color:var(--color-ink); font-weight:var(--weight-semibold); }
.list-clean .btn svg { width:16px; height:16px; }

/* ── Rapport IA de campagne (Lot 3.3) ────────────────────────────────────── */
.ai-report { margin-top:var(--space-5); border:1px solid var(--color-border); border-radius:var(--radius-lg);
  background:var(--color-surface); padding:var(--space-5); }
.ai-report__head { display:flex; align-items:center; gap:var(--space-3); justify-content:space-between; flex-wrap:wrap; }
.ai-report__title { display:flex; align-items:center; gap:8px; font-weight:var(--weight-semibold); color:var(--color-ink); }
.ai-report__title svg { width:20px; height:20px; color:var(--color-gold); }
.ai-report__msg { font-size:var(--text-sm); color:var(--color-text-muted); margin:var(--space-3) 0 0; }
.ai-report__msg.is-err { color:#c0392b; }
.ai-report__stats { display:flex; gap:var(--space-5); flex-wrap:wrap; margin:var(--space-4) 0 0; }
.ai-report__stat { font-size:var(--text-xs); color:var(--color-text-muted); text-transform:uppercase; letter-spacing:.04em; }
.ai-report__stat b { display:block; font-size:var(--text-lg); color:var(--color-ink); font-family:var(--font-mono); letter-spacing:0; text-transform:none; }
.ai-report__body { margin-top:var(--space-4); white-space:pre-wrap; line-height:1.6; color:var(--color-ink);
  border-top:1px solid var(--color-border); padding-top:var(--space-4); }

/* ── Boutons de soumission des formulaires : CTA orange WASSA, à droite, surélevés, plus gros/larges ── */
/* Aligne à droite le groupe contenant le bouton d'envoi. */
body.app form .form-group:has(> [type="submit"]),
body.app .messages-form .form-group:has(> [type="submit"]),
body.app form .form-group:has(> .btn-success),
body.app form .form-group:has(> .btn-primary[type="submit"]) { text-align: right !important; }

/* Le bouton lui-même : orange logo, surélevé, plus gros et plus large. */
body.app form [type="submit"].btn,
body.app .form-group [type="submit"].btn,
body.app .form-group .btn-success[type="submit"],
body.app .form-group .btn-primary[type="submit"] {
  float: none !important;
  width: auto !important;
  display: inline-flex !important; align-items: center; justify-content: center; gap: 10px;
  min-width: 240px;
  background: var(--color-gold) !important;
  color: #FFFFFF !important;
  border: 0 !important;
  border-radius: var(--radius-md) !important;
  padding: 16px 48px !important;
  font-size: 1.1rem !important; font-weight: 700 !important; line-height: 1.1;
  box-shadow: var(--shadow-gold) !important;
  transition: transform .15s var(--ease-out), box-shadow .2s var(--ease-out), background .2s var(--ease-out);
}
body.app form [type="submit"].btn:hover,
body.app .form-group [type="submit"].btn:hover {
  background: var(--color-gold-hover) !important;
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(255, 138, 0, 0.40) !important;
}
body.app form [type="submit"].btn:active,
body.app .form-group [type="submit"].btn:active { transform: translateY(0); box-shadow: var(--shadow-gold) !important; }

/* ── Alerte inline moderne (remplace les popups Growl/flash) ───────────────── */
.wsx-alert { display: flex; align-items: flex-start; gap: var(--space-3);
  padding: var(--space-4) var(--space-5); border-radius: var(--radius-md);
  border: 1px solid var(--color-border); background: var(--color-surface);
  box-shadow: var(--shadow-xs); margin: 0 0 var(--space-5);
  font-size: var(--text-sm); line-height: 1.5; color: var(--color-ink); }
.wsx-alert__icon { flex: none; width: 22px; height: 22px; }
.wsx-alert__icon svg { width: 22px; height: 22px; }
.wsx-alert--info    { border-left: 4px solid var(--color-gold); }
.wsx-alert--info    .wsx-alert__icon { color: var(--color-gold); }
.wsx-alert--success { border-left: 4px solid #16a34a; }
.wsx-alert--success .wsx-alert__icon { color: #16a34a; }
.wsx-alert--warning { border-left: 4px solid #d97706; }
.wsx-alert--warning .wsx-alert__icon { color: #d97706; }
.wsx-alert b { font-weight: var(--weight-semibold); }

/* Illustration "communication à l'ère de l'IA" du panneau marque (login). */
.auth__brand-art { width: 100%; max-width: 400px; margin: var(--space-5) auto var(--space-6); }
.auth__brand-art svg { width: 100%; height: auto; display: block; }
@media (max-width: 980px) { .auth__brand-art { display: none; } }

/* ── Menu campagne « bloom » : 1 orbe → 3 options animées au survol/focus ─── */
.send-fan { position: relative; max-width: 820px; margin: 0 auto; padding: var(--space-6) 0 var(--space-4); text-align: center; }
.send-fan__glow { position: absolute; inset: 0 0 auto; height: 220px; pointer-events: none;
  background: radial-gradient(55% 70% at 50% 25%, rgba(255,138,0,0.14), transparent 70%); }
.send-fan__trigger { position: relative; z-index: 2; display: inline-flex; flex-direction: column; align-items: center;
  gap: var(--space-3); background: none; border: 0; padding: 0; cursor: pointer; }
.send-fan__orb { position: relative; width: 96px; height: 96px; border-radius: var(--radius-full); display: grid; place-items: center;
  background: linear-gradient(135deg, #FF8A00, #FFB861); color: #fff; box-shadow: var(--shadow-gold);
  transition: transform .45s var(--ease-out), box-shadow .3s; }
.send-fan__orb svg { width: 44px; height: 44px; }
.send-fan__orb::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--color-gold);
  opacity: .5; animation: sf-ring 2.6s ease-out infinite; }
@keyframes sf-ring { 0% { transform: scale(1); opacity: .5; } 100% { transform: scale(1.55); opacity: 0; } }
.send-fan__hint { font-size: var(--text-sm); color: var(--color-text-muted); font-weight: var(--weight-semibold); }
.send-fan:hover .send-fan__orb, .send-fan:focus-within .send-fan__orb { transform: translateY(-6px) scale(.9); }
.send-fan:hover .send-fan__hint, .send-fan:focus-within .send-fan__hint { opacity: 0; }

.send-fan__options { position: relative; z-index: 1; margin-top: var(--space-6);
  display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5); }
.send-fan__option { display: flex; flex-direction: column; align-items: center; gap: var(--space-3);
  padding: var(--space-6) var(--space-4); background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); color: var(--color-ink); text-align: center;
  opacity: 0; transform: translateY(30px) scale(.9); pointer-events: none;
  transition: opacity .45s var(--ease-out), transform .45s var(--ease-out), box-shadow .25s, border-color .25s; }
.send-fan:hover .send-fan__option, .send-fan:focus-within .send-fan__option { opacity: 1; transform: none; pointer-events: auto; }
.send-fan:hover .send-fan__option:nth-child(1), .send-fan:focus-within .send-fan__option:nth-child(1) { transition-delay: .06s; }
.send-fan:hover .send-fan__option:nth-child(2), .send-fan:focus-within .send-fan__option:nth-child(2) { transition-delay: .14s; }
.send-fan:hover .send-fan__option:nth-child(3), .send-fan:focus-within .send-fan__option:nth-child(3) { transition-delay: .22s; }
.send-fan__option:hover { transform: translateY(-6px) scale(1.02) !important; box-shadow: var(--shadow-lg); border-color: var(--color-gold); }
.send-fan__ic { width: 58px; height: 58px; border-radius: var(--radius-md); display: grid; place-items: center;
  background: var(--color-gold-tint); color: var(--color-gold); transition: background .25s, color .25s; }
.send-fan__ic svg { width: 28px; height: 28px; }
.send-fan__option:hover .send-fan__ic { background: var(--color-gold); color: #fff; }
.send-fan__option h4 { font-family: var(--font-display); font-size: var(--text-md); margin: 0; color: var(--color-ink); }
.send-fan__option p { font-size: var(--text-xs); color: var(--color-text-muted); margin: 0; }
@media (max-width: 720px) { .send-fan__options { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { .send-fan__orb::after { animation: none; }
  .send-fan__option { transition: opacity .2s; transform: none; } }

/* ── Modal réutilisable (dialogue pro, accessible) ────────────────────────── */
.wsx-modal-backdrop { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: var(--space-4);
  background: rgba(11, 35, 69, 0.55); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px);
  opacity: 0; animation: wsx-bd-in .18s var(--ease-out) forwards; }
@keyframes wsx-bd-in { to { opacity: 1; } }
.wsx-modal-backdrop.is-closing { animation: wsx-bd-out .15s forwards; }
@keyframes wsx-bd-out { to { opacity: 0; } }
.wsx-modal { width: 100%; max-width: 460px; background: var(--color-surface); border-radius: var(--radius-lg);
  box-shadow: 0 24px 60px rgba(11, 35, 69, 0.28); padding: var(--space-6);
  transform: translateY(14px) scale(.96); animation: wsx-modal-in .26s var(--ease-out) forwards; }
@keyframes wsx-modal-in { to { transform: none; } }
.wsx-modal__head { display: flex; align-items: flex-start; gap: var(--space-3); margin-bottom: var(--space-3); }
.wsx-modal__ic { flex: none; width: 44px; height: 44px; border-radius: var(--radius-md); display: grid; place-items: center;
  background: var(--color-gold-tint); color: var(--color-gold); }
.wsx-modal__ic svg { width: 24px; height: 24px; }
.wsx-modal__ic--danger { background: #FEE2E2; color: #DC2626; }
.wsx-modal__title { font-family: var(--font-display); font-size: var(--text-lg); color: var(--color-ink); margin: 0; }
.wsx-modal__body { color: var(--color-text-muted); font-size: var(--text-sm); line-height: 1.55; margin: 0 0 var(--space-5); }
.wsx-modal__actions { display: flex; gap: var(--space-3); justify-content: flex-end; flex-wrap: wrap; }

/* ── Anciennes alertes Bootstrap → look inline moderne partout (.wsx-alert) ── */
body.app .alert {
  display: flex !important; align-items: flex-start; gap: var(--space-3);
  padding: var(--space-4) var(--space-5) !important; border-radius: var(--radius-md) !important;
  border: 1px solid var(--color-border) !important; border-left-width: 4px !important;
  background: var(--color-surface) !important; box-shadow: var(--shadow-xs);
  margin: 0 0 var(--space-5) !important; font-size: var(--text-sm) !important; line-height: 1.55 !important;
  color: var(--color-ink) !important; font-weight: var(--weight-regular) !important;
  text-align: left !important; float: none !important; width: auto !important;
}
body.app .alert-info    { border-left-color: var(--color-gold) !important; }
body.app .alert-success { border-left-color: #16a34a !important; }
body.app .alert-warning { border-left-color: #d97706 !important; }
body.app .alert-danger  { border-left-color: #DC2626 !important; }
body.app .alert b { font-weight: var(--weight-semibold) !important; }
body.app .alert .fa, body.app .alert .glyphicon, body.app .alert svg { color: var(--color-gold); }

/* Bouton destructif (modale de confirmation de suppression). */
.btn--danger { background: #DC2626; color: #fff; box-shadow: var(--shadow-xs); }
.btn--danger:hover { background: #B91C1C; color: #fff; box-shadow: var(--shadow-md); }

/* ══ Revue formulaires & éléments : inputs, états, Select2, boutons, GridView (charte) ══ */

/* Champs de saisie (hors boutons portant .form-control) */
body.app .form-group { margin-bottom: var(--space-5); }
body.app .control-label, body.app .form-group > label, body.app .field label {
  display: block; font-size: var(--text-sm); font-weight: var(--weight-semibold);
  color: var(--color-ink); margin-bottom: var(--space-2); }
body.app .form-control:not(.btn) {
  width: 100%; min-height: 46px; padding: 11px 14px; font-family: var(--font-sans);
  font-size: var(--text-base); color: var(--color-ink); background: var(--color-surface);
  border: 1.5px solid var(--color-border); border-radius: var(--radius-md);
  box-shadow: none; transition: border-color .18s var(--ease-out), box-shadow .18s var(--ease-out); }
body.app textarea.form-control { min-height: 120px; line-height: 1.55; resize: vertical; }
body.app .form-control:not(.btn)::placeholder { color: #9aa6b2; }
body.app .form-control:not(.btn):focus {
  outline: none; border-color: var(--color-gold); box-shadow: 0 0 0 3px rgba(255,138,0,0.16); }
body.app .form-control:not(.btn)[disabled], body.app .form-control:not(.btn)[readonly] {
  background: var(--color-surface-sunken); opacity: .85; cursor: not-allowed; }

/* États de validation */
body.app .has-error .form-control:not(.btn) { border-color: #DC2626; }
body.app .has-error .form-control:not(.btn):focus { box-shadow: 0 0 0 3px rgba(220,38,38,0.15); }
body.app .has-error .control-label, body.app .has-error label { color: #DC2626; }
body.app .help-block { font-size: var(--text-xs); margin-top: var(--space-1); color: var(--color-text-muted); }
body.app .has-error .help-block { color: #DC2626; }
body.app .help-block-error:empty { display: none; }
body.app .has-success .form-control:not(.btn) { border-color: #16a34a; }

/* Select2 (kartik) */
body.app .select2-container .select2-selection--single,
body.app .select2-container .select2-selection--multiple {
  min-height: 46px !important; border: 1.5px solid var(--color-border) !important;
  border-radius: var(--radius-md) !important; box-shadow: none !important;
  background: var(--color-surface) !important; padding: 5px 8px; display: flex; align-items: center; flex-wrap: wrap; }
body.app .select2-container--open .select2-selection,
body.app .select2-container--focus .select2-selection {
  border-color: var(--color-gold) !important; box-shadow: 0 0 0 3px rgba(255,138,0,0.16) !important; }
body.app .select2-selection__rendered { color: var(--color-ink) !important; padding-left: 4px !important; }
body.app .select2-dropdown { border: 1.5px solid var(--color-border) !important; border-radius: var(--radius-md) !important;
  box-shadow: var(--shadow-lg); overflow: hidden; }
body.app .select2-results__option--highlighted { background: var(--color-gold) !important; color: var(--color-ink) !important; }
body.app .select2-selection__choice { background: var(--color-gold-tint) !important;
  border: 1px solid var(--color-gold-soft) !important; border-radius: var(--radius-sm) !important; color: var(--color-ink) !important; }
body.app .select2-search__field { min-height: 30px !important; }

/* FileInput (kartik) */
body.app .file-caption-main .form-control:not(.btn) { min-height: 46px; }
body.app .btn-file, body.app .fileinput-remove, body.app .fileinput-upload { border-radius: var(--radius-md) !important; }

/* Palette des boutons Bootstrap legacy → charte WASSA (≠ .btn--* maison) */
body.app .btn { border-radius: var(--radius-md); font-weight: var(--weight-semibold); transition: background .2s, box-shadow .2s, transform .12s; }
body.app .btn-success { background: var(--color-gold) !important; color: #fff !important; border: 0 !important; box-shadow: var(--shadow-xs); }
body.app .btn-success:hover { background: var(--color-gold-hover) !important; color: #fff !important; box-shadow: var(--shadow-md); }
body.app .btn-primary { background: var(--color-ink) !important; color: #fff !important; border: 0 !important; }
body.app .btn-primary:hover { background: var(--color-ink-soft) !important; color: #fff !important; }
body.app .btn-danger { background: #DC2626 !important; color: #fff !important; border: 0 !important; }
body.app .btn-danger:hover { background: #B91C1C !important; }
body.app .btn-default, body.app .btn-info { background: var(--color-surface) !important; color: var(--color-ink) !important;
  border: 1.5px solid var(--color-border) !important; }
body.app .btn-default:hover, body.app .btn-info:hover { border-color: var(--color-gold-soft) !important; background: var(--color-gold-tint) !important; }

/* GridView — colonne d'actions en boutons-icônes propres */
body.app .grid-view .action-column, body.app td.action-column { white-space: nowrap; text-align: right; }
body.app .grid-view .action-column a { display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; margin-left: 4px; border-radius: var(--radius-sm); color: var(--color-ink-soft);
  border: 1px solid transparent; transition: background .18s, color .18s, border-color .18s; }
body.app .grid-view .action-column a:hover { background: var(--color-gold-tint); color: var(--color-gold-hover); border-color: var(--color-gold-soft); }
body.app .grid-view .action-column a svg { width: 18px; height: 18px; }
body.app .grid-view .filters .form-control:not(.btn) { min-height: 38px; padding: 7px 10px; font-size: var(--text-sm); }

/* ══ Détail, fil d'Ariane, états vides (charte) ══ */

/* Fil d'Ariane */
.wsx-crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); list-style: none;
  padding: 0; margin: 0 0 var(--space-5); font-size: var(--text-sm); color: var(--color-text-muted); }
.wsx-crumbs li { display: inline-flex; align-items: center; gap: var(--space-2); }
.wsx-crumbs li:not(:last-child)::after { content: "›"; color: var(--color-border-strong); margin-left: var(--space-2); font-size: 1.05em; }
.wsx-crumbs a { color: var(--color-text-muted); transition: color .15s; }
.wsx-crumbs a:hover { color: var(--color-gold-hover); }
.wsx-crumbs .is-active { color: var(--color-ink); font-weight: var(--weight-semibold); }

/* DetailView (écrans de détail) */
body.app .detail-view { width: 100%; border-collapse: collapse; background: var(--color-surface);
  border: 1px solid var(--color-border); border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-sm); margin-bottom: var(--space-5); }
body.app .detail-view tr { border-bottom: 1px solid var(--color-border); }
body.app .detail-view tr:last-child { border-bottom: 0; }
body.app .detail-view th { width: 34%; text-align: left; padding: var(--space-3) var(--space-5);
  background: var(--color-surface-sunken); color: var(--color-text-muted); font-size: var(--text-sm);
  font-weight: var(--weight-semibold); vertical-align: top; }
body.app .detail-view td { padding: var(--space-3) var(--space-5); color: var(--color-ink); font-size: var(--text-sm); word-break: break-word; }
@media (max-width: 640px) { body.app .detail-view th { width: 42%; } }

/* États vides (GridView .empty + composant réutilisable .wsx-empty) */
.wsx-empty, body.app .grid-view .empty { display: flex; flex-direction: column; align-items: center;
  gap: var(--space-3); padding: var(--space-8) var(--space-5); text-align: center; color: var(--color-text-muted); }
.wsx-empty__art { width: 84px; height: 84px; border-radius: var(--radius-full); display: grid; place-items: center;
  background: var(--color-gold-tint); color: var(--color-gold); margin-bottom: var(--space-2); }
.wsx-empty__art svg { width: 40px; height: 40px; }
.wsx-empty h3 { font-family: var(--font-display); font-size: var(--text-md); color: var(--color-ink); margin: 0; }
.wsx-empty p { margin: 0; font-size: var(--text-sm); max-width: 38ch; }
.wsx-empty .btn { margin-top: var(--space-2); }

/* ══ Squelettes de chargement (skeleton screens) ══ */
@keyframes wsx-shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.wsx-skel { background: linear-gradient(90deg, #DFE5EE 25%, #F0F3F8 37%, #DFE5EE 63%);
  background-size: 200% 100%; animation: wsx-shimmer 1.3s ease-in-out infinite; border-radius: var(--radius-sm); }
.wsx-skel--title { height: 22px; width: 38%; margin-bottom: var(--space-5); border-radius: var(--radius-sm); }
.wsx-skel--text { height: 12px; margin: 8px 0; }
.wsx-skel--kpi { height: 112px; border-radius: var(--radius-lg); }
.wsx-skel--row { height: 46px; border-radius: var(--radius-sm); }
@media (prefers-reduced-motion: reduce) { .wsx-skel { animation: none; } }

/* Barre de progression de navigation (haut de page) */
.wsx-nav-progress { position: fixed; top: 0; left: 0; height: 3px; width: 0; z-index: 2000; opacity: 0;
  background: linear-gradient(90deg, var(--color-gold), #FFB861); box-shadow: 0 0 8px rgba(255,138,0,0.55);
  transition: width .3s var(--ease-out), opacity .2s; }
.wsx-nav-progress.is-active { opacity: 1; }

/* Overlay squelette pendant la navigation (recouvre le contenu sortant) */
.wsx-page-skel { position: absolute; inset: 0; z-index: 5; background: var(--color-surface-sunken);
  padding: var(--space-2) 0 0; animation: wsx-bd-in .15s var(--ease-out); }
.wsx-page-skel__kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--space-5); margin-bottom: var(--space-6); }
.wsx-page-skel__panel { background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-lg); padding: var(--space-5); display: grid; gap: var(--space-3); }
@media (max-width: 760px) { .wsx-page-skel__kpis { grid-template-columns: 1fr 1fr; } }
