/* CRM Formation 3D — identité MaxiVizion, verre dépoli, clair + sombre */
:root {
  --fond: #f4f2f8;
  --fond-2: #ebe8f2;
  --texte: #14131a;
  --doux: #5d5a6b;
  --tres-doux: #8d8a99;
  --verre: rgba(255, 255, 255, .58);
  --verre-fort: rgba(255, 255, 255, .82);
  --bord: rgba(20, 19, 26, .08);
  --bord-fort: rgba(20, 19, 26, .14);
  --reflet: rgba(255, 255, 255, .9);
  --ombre: 0 1px 2px rgba(20, 19, 26, .04), 0 12px 40px -12px rgba(40, 20, 60, .18);
  --champ: rgba(255, 255, 255, .7);
  --a1: #f2a93b; --a2: #ff6a1f; --a3: #e03a86;
  --degrade: linear-gradient(120deg, var(--a1), var(--a2) 50%, var(--a3));
  --s-nouveau: #d98a12; --s-contacte: #ff6a1f; --s-discussion: #e03a86; --s-client: #10a36b; --s-perdu: #8d8a99;
  --rayon: 18px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --mono: 'JetBrains Mono', ui-monospace, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --fond: #0a0b10; --fond-2: #11121a; --texte: #f2f0f7; --doux: #a5a2b3; --tres-doux: #6f6c7d;
    --verre: rgba(28, 28, 40, .52); --verre-fort: rgba(30, 30, 44, .86);
    --bord: rgba(255, 255, 255, .08); --bord-fort: rgba(255, 255, 255, .16); --reflet: rgba(255, 255, 255, .12);
    --ombre: 0 1px 2px rgba(0, 0, 0, .3), 0 18px 50px -16px rgba(0, 0, 0, .7);
    --champ: rgba(255, 255, 255, .05);
    --s-nouveau: #f2a93b; --s-client: #34d399; --s-perdu: #7d7a8c;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --fond: #0a0b10; --fond-2: #11121a; --texte: #f2f0f7; --doux: #a5a2b3; --tres-doux: #6f6c7d;
  --verre: rgba(28, 28, 40, .52); --verre-fort: rgba(30, 30, 44, .86);
  --bord: rgba(255, 255, 255, .08); --bord-fort: rgba(255, 255, 255, .16); --reflet: rgba(255, 255, 255, .12);
  --ombre: 0 1px 2px rgba(0, 0, 0, .3), 0 18px 50px -16px rgba(0, 0, 0, .7);
  --champ: rgba(255, 255, 255, .05);
  --s-nouveau: #f2a93b; --s-client: #34d399; --s-perdu: #7d7a8c;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; background: var(--fond); color: var(--texte);
  font: 15px/1.45 'Archivo', system-ui, sans-serif; -webkit-font-smoothing: antialiased;
  transition: background .4s var(--ease), color .4s var(--ease);
}
[hidden] { display: none !important; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; }

/* Fond vivant */
.fond { position: fixed; inset: 0; overflow: hidden; z-index: -1; pointer-events: none; }
.fond i { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .55; will-change: transform; }
.fond .b1 { width: 52vw; height: 52vw; left: -14vw; top: -18vw; background: radial-gradient(circle, var(--a1), transparent 68%); animation: flotte 26s var(--ease) infinite alternate; }
.fond .b2 { width: 46vw; height: 46vw; right: -12vw; top: 10vh; background: radial-gradient(circle, var(--a3), transparent 68%); animation: flotte 32s var(--ease) infinite alternate-reverse; opacity: .4; }
.fond .b3 { width: 40vw; height: 40vw; left: 30vw; bottom: -22vw; background: radial-gradient(circle, var(--a2), transparent 68%); animation: flotte 29s var(--ease) infinite alternate; opacity: .32; }
@keyframes flotte { to { transform: translate3d(6vw, 5vh, 0) scale(1.12); } }

/* Verre */
.verre {
  background: var(--verre);
  -webkit-backdrop-filter: blur(26px) saturate(180%); backdrop-filter: blur(26px) saturate(180%);
  border: 1px solid var(--bord); box-shadow: inset 0 1px 0 var(--reflet), var(--ombre);
}
.degrade { background: var(--degrade); -webkit-background-clip: text; background-clip: text; color: transparent; }
.doux { color: var(--doux); }

/* Marque */
.marque { display: flex; align-items: center; gap: 10px; font-weight: 600; letter-spacing: -.01em; white-space: nowrap; }
.marque.grande { font-size: 13px; text-transform: uppercase; letter-spacing: .18em; color: var(--doux); }
.prisme { width: 22px; height: 22px; flex: none; background: var(--degrade); clip-path: polygon(50% 6%, 96% 92%, 4% 92%); filter: drop-shadow(0 2px 8px rgba(255, 106, 31, .5)); }

/* Boutons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 42px; padding: 0 18px;
  border-radius: 999px; border: 1px solid var(--bord-fort); background: var(--champ); font-weight: 600;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), background .2s;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: scale(.97); }
.btn.principal { border: 0; color: #fff; background: var(--degrade); background-size: 160% 100%; box-shadow: 0 8px 24px -8px rgba(255, 106, 31, .7), inset 0 1px 0 rgba(255, 255, 255, .35); transition: transform .2s var(--ease), background-position .6s var(--ease), box-shadow .2s; }
.btn.principal:hover { background-position: 100% 0; box-shadow: 0 12px 30px -8px rgba(224, 58, 134, .7), inset 0 1px 0 rgba(255, 255, 255, .35); }
.btn.principal span { font-size: 20px; line-height: 0; margin-top: -2px; }
.btn.petit { height: 34px; padding: 0 14px; font-size: 13.5px; }
.btn.danger { color: #e5484d; }
.icone-btn { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--bord); background: var(--champ); display: grid; place-items: center; transition: transform .3s var(--ease); }
.icone-btn:hover { transform: rotate(18deg); }
.icone-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
:focus-visible { outline: 2px solid var(--a2); outline-offset: 2px; }

/* Connexion — texte à gauche, mur de vrais rendus Paris 3D à droite */
.connexion { position: fixed; inset: 0; z-index: 30; display: grid; grid-template-columns: minmax(420px, 46fr) 54fr; grid-template-rows: minmax(0, 1fr); background: var(--fond); overflow: hidden; }
.cx-gauche { position: relative; z-index: 2; display: flex; flex-direction: column; justify-content: space-between; padding: clamp(28px, 4vw, 56px) clamp(28px, 5vw, 80px); }
.cx-centre { max-width: 600px; }
.cx-sur { margin: 0 0 18px; font-family: var(--mono); font-size: 12px; letter-spacing: .22em; text-transform: uppercase; color: var(--a2); display: flex; align-items: center; gap: 12px; }
.cx-sur::before { content: ''; width: 28px; height: 1px; background: currentColor; }
.cx-titre { margin: 0; font-size: clamp(44px, 5vw, 84px); line-height: .95; letter-spacing: -.045em; font-weight: 800; }
.cx-titre .degrade { padding-right: .05em; }
.cx-texte { margin: 22px 0 40px; font-size: 17px; line-height: 1.55; color: var(--doux); max-width: 30em; }
.cx-label { display: block; font-size: 12.5px; font-weight: 600; color: var(--doux); margin: 0 0 10px 4px; }
.cx-champ { display: flex; align-items: center; gap: 8px; padding: 7px 7px 7px 22px; border-radius: 999px; background: var(--champ); border: 1px solid var(--bord-fort); box-shadow: inset 0 1px 0 var(--reflet), var(--ombre); transition: border-color .25s, box-shadow .25s; max-width: 460px; }
.cx-champ:focus-within { border-color: color-mix(in srgb, var(--a2) 65%, transparent); box-shadow: 0 0 0 5px color-mix(in srgb, var(--a2) 15%, transparent), var(--ombre); }
.cx-champ input { flex: 1; min-width: 0; height: 48px; border: 0; background: none; outline: none; font-family: var(--mono); font-size: 16px; letter-spacing: .3em; text-transform: uppercase; }
.cx-champ input::placeholder { color: var(--tres-doux); letter-spacing: .12em; }
.cx-go { flex: none; width: 50px; height: 50px; border-radius: 50%; border: 0; display: grid; place-items: center; color: #fff; background: var(--degrade); background-size: 180% 100%; box-shadow: 0 10px 26px -8px rgba(255, 106, 31, .75), inset 0 1px 0 rgba(255, 255, 255, .35); transition: transform .3s var(--ease), background-position .5s var(--ease); }
.cx-go:hover { transform: scale(1.06); background-position: 100% 0; }
.cx-go:active { transform: scale(.94); }
.cx-go svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; transition: transform .3s var(--ease); }
.cx-go:hover svg { transform: translateX(2px); }
.cx-pied { margin: 0; font-size: 12px; color: var(--tres-doux); font-family: var(--mono); letter-spacing: .04em; }
.erreur { color: #e5484d; min-height: 1.3em; font-size: 14px; margin: 12px 0 0 6px; }
.secoue { animation: secoue .4s; }
@keyframes secoue { 25% { transform: translateX(-8px); } 50% { transform: translateX(7px); } 75% { transform: translateX(-4px); } }
@keyframes monte { from { opacity: 0; transform: translateY(18px) scale(.98); } }

.cx-mur { position: relative; min-height: 0; height: 100%; overflow: hidden; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; padding: 0 clamp(16px, 2.5vw, 36px) 0 0; align-content: center; }
.cx-col { display: grid; gap: 16px; align-content: start; }
.cx-col.decale { margin-top: -28%; }
.cx-col img { display: block; width: 100%; height: auto; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 22px; background: #15161d; }
.connexion::after { content: ''; position: absolute; inset: 0 auto 0 calc(46% - 120px); width: 240px; z-index: 1; pointer-events: none; background: linear-gradient(90deg, var(--fond), transparent); }

@media (max-width: 900px) {
  .connexion { grid-template-columns: 1fr; }
  .connexion::after { inset: 0; width: auto; background: linear-gradient(180deg, rgba(10, 11, 16, .35) 0%, rgba(10, 11, 16, .2) 30%, rgba(10, 11, 16, .92) 68%); }
  .cx-mur { position: absolute; inset: 0; gap: 10px; padding: 0 10px; align-content: start; }
  .cx-col { gap: 10px; }
  .cx-col img { border-radius: 16px; }
  .cx-gauche { color: #f2f0f7; justify-content: space-between; padding: 22px 20px calc(28px + env(safe-area-inset-bottom)); }
  .cx-gauche .marque.grande { color: rgba(255, 255, 255, .8); }
  .cx-titre { font-size: clamp(40px, 12vw, 58px); }
  .cx-texte { color: rgba(242, 240, 247, .78); margin: 16px 0 26px; font-size: 15.5px; }
  .cx-label { color: rgba(242, 240, 247, .7); }
  .cx-champ { background: rgba(20, 20, 30, .55); -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%); border-color: rgba(255, 255, 255, .16); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12); color: #fff; }
  .cx-pied { display: none; }
  .cx-champ { -webkit-backdrop-filter: none; backdrop-filter: none; background: rgba(20, 20, 30, .82); }
}

/* Barre du haut */
#app { max-width: 1240px; margin: 0 auto; padding: 14px 16px 80px; }
.barre { position: sticky; top: 12px; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 10px 10px 18px; border-radius: 999px; }
.barre-droite { display: flex; align-items: center; gap: 8px; }
.synchro { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; color: var(--doux); padding: 0 8px; }
.synchro i { width: 7px; height: 7px; border-radius: 50%; background: var(--s-client); box-shadow: 0 0 0 0 var(--s-client); animation: pouls 2.6s infinite; }
.synchro.attente i { background: var(--a1); }
.synchro.hors i { background: #e5484d; animation: none; }
@keyframes pouls { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--s-client) 60%, transparent); } 70%, 100% { box-shadow: 0 0 0 7px transparent; } }
.puce-moi { height: 38px; border-radius: 999px; border: 1px solid var(--bord); background: var(--champ); padding: 0 14px 0 5px; display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }
.menu-wrap { position: relative; }
.menu { position: absolute; right: 0; top: 46px; min-width: 240px; padding: 6px; border-radius: 16px; background: var(--verre-fort); display: grid; animation: monte .25s var(--ease) both; }
.menu-item { text-align: left; border: 0; background: none; padding: 10px 12px; border-radius: 10px; text-decoration: none; font-size: 14.5px; }
.menu-item:hover { background: var(--champ); }
.menu-item.danger { color: #e5484d; }

/* Onglets B2B / Formation */
.onglets { position: relative; display: flex; gap: 2px; padding: 4px; border-radius: 999px; background: var(--champ); border: 1px solid var(--bord); }
.onglets button { position: relative; z-index: 1; border: 0; background: none; height: 34px; padding: 0 16px; border-radius: 999px; font-weight: 600; font-size: 14px; color: var(--doux); white-space: nowrap; transition: color .3s; }
.onglets button.actif { color: #fff; }
.onglets em { font-style: normal; font-family: var(--mono); font-size: 11.5px; opacity: .75; margin-left: 4px; }
.onglet-curseur { position: absolute; top: 4px; bottom: 4px; left: 0; width: 0; border-radius: 999px; background: var(--degrade); box-shadow: 0 6px 18px -6px rgba(255, 106, 31, .7); transition: transform .45s var(--ease); }

/* Fenêtre nouveau contact */
.modale { position: fixed; z-index: 60; left: 50%; top: 50%; width: min(520px, calc(100vw - 32px)); transform: translate(-50%, -50%); border-radius: 26px; padding: 26px 22px 20px; background: var(--verre-fort); display: grid; gap: 16px; animation: modale .4s var(--ease) both; }
.modale h3 { margin: 0; font-size: 22px; letter-spacing: -.025em; }
.modale-pied { display: flex; justify-content: flex-end; gap: 8px; }
@keyframes modale { from { opacity: 0; transform: translate(-50%, -46%) scale(.97); } }
.modale .champ select { appearance: none; -webkit-appearance: none; }

/* Avatars */
.avatar { width: 30px; height: 30px; flex: none; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 700; color: #fff; background: var(--degrade); text-transform: uppercase; }
.avatar.grand { width: 54px; height: 54px; font-size: 19px; border-radius: 18px; }

/* Statistiques / filtres */
.stats { display: grid; grid-template-columns: repeat(var(--nb, 7), minmax(0, 1fr)); gap: 10px; margin: 22px 0 14px; }
.stat { text-align: left; border-radius: var(--rayon); padding: 14px 14px 12px; border: 1px solid var(--bord); background: var(--verre); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); box-shadow: inset 0 1px 0 var(--reflet); position: relative; overflow: hidden; transition: transform .25s var(--ease), border-color .25s; animation: monte .6s var(--ease) both; }
.stat:hover { transform: translateY(-2px); }
.stat .n { display: block; font-size: 28px; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; line-height: 1.1; }
.stat .l { font-size: 12.5px; color: var(--doux); display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.stat .l i { width: 8px; height: 8px; border-radius: 50%; background: var(--c, var(--texte)); flex: none; }
.stat::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--c, var(--degrade)); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.stat.actif { border-color: var(--bord-fort); }
.stat.actif::after { transform: scaleX(1); }
.stat.tous { --c: var(--degrade); }
.stat.tous::after { background: var(--degrade); }

/* Outils */
.outils { display: flex; gap: 10px; align-items: center; margin-bottom: 14px; flex-wrap: wrap; }
.recherche { flex: 1 1 280px; display: flex; align-items: center; gap: 10px; height: 46px; padding: 0 16px; border-radius: 999px; }
.recherche svg { width: 18px; height: 18px; fill: none; stroke: var(--doux); stroke-width: 2; stroke-linecap: round; flex: none; }
.recherche input { flex: 1; min-width: 0; border: 0; background: none; outline: none; height: 100%; }
.select { height: 46px; border-radius: 999px; padding: 0 36px 0 16px; appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238d8a99' stroke-width='1.8' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; }
.outils .btn.principal { height: 46px; }

/* Liste */
.liste { display: grid; gap: 8px; }
.ligne {
  display: grid; grid-template-columns: 30px minmax(0, 2.2fr) minmax(0, 1.3fr) 130px 110px 92px 18px; align-items: center; gap: 14px;
  padding: 12px 16px; border-radius: var(--rayon); border: 1px solid var(--bord); background: var(--verre);
  -webkit-backdrop-filter: blur(20px) saturate(160%); backdrop-filter: blur(20px) saturate(160%);
  box-shadow: inset 0 1px 0 var(--reflet); cursor: pointer; text-align: left; width: 100%;
  transition: transform .25s var(--ease), border-color .25s, background .25s; animation: monte .5s var(--ease) both;
}
.ligne:hover { transform: translateY(-1px); border-color: var(--bord-fort); background: var(--verre-fort); }
.ligne .qui { min-width: 0; }
.ligne .qui b { display: block; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ligne .qui small, .ligne .info small { display: block; color: var(--doux); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ligne .info { min-width: 0; font-family: var(--mono); font-size: 13px; }
.ligne .info span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ligne .date { font-size: 12.5px; color: var(--tres-doux); text-align: right; white-space: nowrap; }
.ligne .fleche { color: var(--tres-doux); transition: transform .25s var(--ease); }
.ligne:hover .fleche { transform: translateX(3px); color: var(--texte); }
.ligne.nouveau-flash { animation: flash 1.6s var(--ease); }
@keyframes flash { 0% { box-shadow: 0 0 0 2px var(--a2); } 100% { box-shadow: inset 0 1px 0 var(--reflet); } }

.pastille { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 999px; font-size: 12.5px; font-weight: 600; white-space: nowrap; color: var(--c); background: color-mix(in srgb, var(--c) 13%, transparent); border: 1px solid color-mix(in srgb, var(--c) 25%, transparent); }
.pastille i { width: 6px; height: 6px; border-radius: 50%; background: var(--c); }
.relance { font-size: 12.5px; white-space: nowrap; color: var(--doux); }
.relance.retard { color: #e5484d; font-weight: 600; }
.relance.aujourdhui { color: var(--a2); font-weight: 600; }

.vide { text-align: center; padding: 70px 20px; color: var(--doux); border-radius: 24px; }
.vide b { display: block; font-size: 20px; color: var(--texte); margin-bottom: 6px; }

/* Fiche */
.voile { position: fixed; inset: 0; z-index: 40; background: rgba(8, 8, 14, .32); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); animation: apparait .3s both; }
@keyframes apparait { from { opacity: 0; } }
.fiche {
  position: fixed; z-index: 50; top: 12px; right: 12px; bottom: 12px; width: min(560px, calc(100vw - 24px));
  border-radius: 26px; background: var(--verre-fort); overflow-y: auto; overscroll-behavior: contain;
  animation: glisse .45s var(--ease) both; padding: 0 0 28px;
}
.fiche.ferme { animation: glisse-out .28s var(--ease) both; }
@keyframes glisse { from { transform: translateX(40px); opacity: 0; } }
@keyframes glisse-out { to { transform: translateX(40px); opacity: 0; } }
.fiche-tete { position: sticky; top: 0; z-index: 2; display: flex; gap: 14px; align-items: center; padding: 20px 20px 16px; background: linear-gradient(var(--verre-fort) 70%, transparent); }
.fiche-tete h2 { margin: 0; font-size: 22px; letter-spacing: -.025em; line-height: 1.15; word-break: break-word; }
.fiche-tete .sous { font-size: 13px; color: var(--doux); }
.fiche-tete .titre { flex: 1; min-width: 0; }
.etat-save { font-size: 12px; color: var(--tres-doux); white-space: nowrap; transition: color .3s; }
.etat-save.ok { color: var(--s-client); }
.fiche-corps { padding: 0 20px; display: grid; gap: 18px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }
.actions .btn { text-decoration: none; }
.actions .btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.btn[aria-disabled="true"] { opacity: .4; pointer-events: none; }

.segments { display: grid; grid-template-columns: repeat(var(--nb, 5), 1fr); gap: 4px; padding: 4px; border-radius: 16px; background: var(--champ); border: 1px solid var(--bord); position: relative; }
.segments button { border: 0; background: none; border-radius: 12px; padding: 9px 4px; font-size: 12.5px; font-weight: 600; color: var(--doux); position: relative; z-index: 1; transition: color .25s; line-height: 1.15; }
.segments button.actif { color: #fff; }
.segments .curseur { position: absolute; top: 4px; bottom: 4px; left: 4px; border-radius: 12px; background: var(--c); box-shadow: 0 6px 18px -6px var(--c); transition: transform .4s var(--ease), background .3s; }

.groupe { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.champ { display: grid; gap: 5px; }
.champ.large { grid-column: 1 / -1; }
.champ label { font-size: 12px; color: var(--doux); font-weight: 500; letter-spacing: .02em; }
.champ input, .champ select, .champ textarea { width: 100%; border: 1px solid var(--bord); background: var(--champ); border-radius: 12px; padding: 10px 12px; outline: none; transition: border-color .2s, box-shadow .2s; }
.champ input:focus, .champ select:focus, .champ textarea:focus { border-color: color-mix(in srgb, var(--a2) 60%, transparent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--a2) 14%, transparent); }
.champ textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
.champ .mono, .champ input[type="email"], .champ input[type="tel"] { font-family: var(--mono); font-size: 14px; }
.section-titre { font-size: 12px; text-transform: uppercase; letter-spacing: .14em; color: var(--tres-doux); font-weight: 600; margin: 6px 0 -6px; }
.meta { font-size: 12.5px; color: var(--tres-doux); display: grid; gap: 2px; }

.journal { display: grid; gap: 8px; }
.journal-ajout { display: flex; gap: 8px; }
.journal-ajout input { flex: 1; min-width: 0; border: 1px solid var(--bord); background: var(--champ); border-radius: 999px; padding: 0 16px; height: 40px; outline: none; }
.note { display: grid; grid-template-columns: 24px 1fr auto; gap: 10px; align-items: start; padding: 10px 12px; border-radius: 14px; background: var(--champ); border: 1px solid var(--bord); animation: monte .35s var(--ease) both; }
.note .avatar { width: 24px; height: 24px; font-size: 10px; }
.note p { margin: 0; white-space: pre-wrap; word-break: break-word; font-size: 14px; }
.note small { color: var(--tres-doux); font-size: 12px; }
.note.auto { background: none; border-style: dashed; }
.note.auto p { color: var(--doux); font-size: 13px; }
.note .suppr { border: 0; background: none; color: var(--tres-doux); padding: 0 4px; font-size: 16px; opacity: 0; transition: opacity .2s; }
.note:hover .suppr { opacity: 1; }
.pied-fiche { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; border-top: 1px solid var(--bord); padding-top: 16px; }

/* Toasts */
.toasts { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 90; display: grid; gap: 8px; justify-items: center; pointer-events: none; }
.toast { padding: 10px 18px; border-radius: 999px; background: var(--verre-fort); -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); border: 1px solid var(--bord-fort); box-shadow: var(--ombre); font-size: 14px; animation: monte .35s var(--ease) both; }
.toast.part { animation: glisse-out .3s var(--ease) both; }

/* Responsive */
@media (max-width: 1100px) { .marque-texte { display: none; } }
@media (max-width: 1000px) {
  .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .ligne { grid-template-columns: 30px minmax(0, 1fr) 130px 18px; }
  .ligne .info, .ligne .date, .ligne .relance-col { display: none; }
}
@media (max-width: 640px) {
  #app { padding: 10px 12px 80px; }
  .barre { padding: 8px 8px 8px 14px; top: 8px; }
  .barre { flex-wrap: wrap; border-radius: 26px; }
  .onglets { order: 3; width: 100%; }
  .onglets button { flex: 1; padding: 0 8px; font-size: 13.5px; }
  .synchro span { display: none; }
  .stats { display: flex; overflow-x: auto; gap: 8px; margin: 16px -12px 14px; padding: 2px 12px 6px; scroll-snap-type: x mandatory; scrollbar-width: none; }
  .stats::-webkit-scrollbar { display: none; }
  .stat { flex: 0 0 auto; min-width: 108px; padding: 10px 12px; scroll-snap-align: start; }
  .outils .select { min-width: 0; }
  .stat .n { font-size: 22px; }
  .outils .select { flex: 1 1 40%; }
  .outils .btn.principal { flex: 1 1 100%; }
  .ligne { grid-template-columns: 30px minmax(0, 1fr) auto; padding: 12px; }
  .ligne .fleche { display: none; }
  .fiche { top: auto; right: 0; left: 0; bottom: 0; width: 100%; max-height: 92vh; border-radius: 26px 26px 0 0; animation-name: monte-bas; }
  .fiche.ferme { animation-name: descend; }
  .groupe { grid-template-columns: 1fr; }
  .segments button { font-size: 11px; padding: 9px 2px; }
}
@keyframes monte-bas { from { transform: translateY(60px); opacity: 0; } }
@keyframes descend { to { transform: translateY(60px); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }
