/**
 * MAOSTACHE — Dashboard v0.8.3 : reprise AU PIXEL de la maquette validée.
 *
 * - Contenu : classes de la maquette, scopées sous .mdash (valeurs identiques).
 * - Shell (sidebar/topbar) : surcharge des classes .mst-* pour coller à la maquette.
 * Chargé APRÈS app.css / shell.css → prioritaire.
 */

/* ===================================================================
 * Variables (reprises de la maquette)
 * =============================================================== */
.mdash {
	--primary:#e7213a; --secondary:#0090e7; --indigo:#4f46e5; --indigo-soft:#eef0ff;
	--purple:#8b5cf6; --purple-soft:#f3effe; --green:#22c55e; --green-soft:#f0fdf4;
	--amber:#f59e0b; --amber-soft:#fffbeb; --teal:#14b8a6;
	--text:#1e293b; --text-2:#64748b; --text-3:#94a3b8;
	--border:#e9edf3; --white:#fff;
	--font-d:'Plus Jakarta Sans',sans-serif; --font-b:'Inter',system-ui,sans-serif; --font-m:'DM Mono',monospace;
	--r-md:16px; --r-pill:999px; --sh-sm:0 1px 2px rgba(16,24,40,.04),0 1px 3px rgba(16,24,40,.05);
	font-family:var(--font-b); color:var(--text);
}
.mdash svg { display:block; }

/* ---------- En-tête ---------- */
.mdash .page-head{display:flex;align-items:flex-end;justify-content:space-between;gap:16px;margin-bottom:20px}
.mdash .hello{font-family:var(--font-d);font-weight:800;font-size:26px;letter-spacing:-.03em}
.mdash .subhead{color:var(--text-2);font-size:14px;margin-top:4px}
.mdash .period{display:flex;align-items:center;gap:8px;padding:9px 14px;border-radius:11px;border:1px solid var(--border);background:#fff;font-size:13.5px;font-weight:600;color:var(--text-2);cursor:pointer}
.mdash .period svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:2}

/* ---------- Grilles ---------- */
.mdash .kpis{display:grid;grid-template-columns:repeat(5,1fr);gap:16px;margin-bottom:18px}
.mdash .row3{display:grid;grid-template-columns:1fr 1fr 1fr;gap:16px;margin-bottom:18px}
.mdash .card{background:#fff;border:1px solid var(--border);border-radius:var(--r-md);box-shadow:var(--sh-sm)}
.mdash .card.pad{padding:20px}

/* ---------- KPI ---------- */
.mdash .kpi{padding:18px}
.mdash .kpi .kh{display:flex;align-items:flex-start;gap:12px}
.mdash .kpi .ki{width:44px;height:44px;border-radius:12px;display:grid;place-items:center;flex:0 0 44px}
.mdash .kpi .ki svg{width:22px;height:22px;stroke:currentColor;fill:none;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round}
.mdash .kpi .kl{font-size:13px;color:var(--text-2);font-weight:500}
.mdash .kpi .kv{font-family:var(--font-d);font-weight:800;font-size:28px;letter-spacing:-.03em;margin-top:2px;line-height:1}
.mdash .kpi .kf{font-size:12px;margin-top:8px;font-weight:600}
.mdash .kpi .spark{display:block;margin-top:10px;height:34px;width:100%}
.mdash .kpi .spark svg{width:100%;height:34px;display:block}
.mdash .up{color:var(--green)} .mdash .muted{color:var(--text-3)}
.mdash .tint-red{background:#fef2f2;color:var(--primary)}
.mdash .tint-blue{background:#eaf5ff;color:var(--secondary)}
.mdash .tint-amber{background:var(--amber-soft);color:var(--amber)}
.mdash .tint-green{background:var(--green-soft);color:var(--green)}
.mdash .tint-purple{background:var(--purple-soft);color:var(--purple)}
.mdash .tint-indigo{background:var(--indigo-soft);color:var(--indigo)}

/* ---------- En-tête de carte ---------- */
.mdash .ch{display:flex;align-items:center;gap:10px;margin-bottom:16px}
.mdash .ch .ci{width:30px;height:30px;border-radius:9px;display:grid;place-items:center;flex:0 0 30px}
.mdash .ch .ci svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.mdash .ch h3{font-family:var(--font-d);font-weight:700;font-size:16px;letter-spacing:-.02em;margin:0}
.mdash .ch .link{margin-left:auto;font-size:13px;font-weight:600;color:var(--secondary)}
.mdash .ch .info{margin-left:auto;color:var(--text-3);display:flex;align-items:center;gap:10px}
.mdash .ch .info svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:2}
.mdash .mini-sel{font-size:12.5px;font-weight:600;color:var(--text-2);border:1px solid var(--border);border-radius:9px;padding:6px 10px}
.mdash .empty-txt{font-size:13px;color:var(--text-3);padding:6px 0}

/* ---------- Opportunités ---------- */
.mdash .op{display:flex;align-items:center;gap:14px;padding:14px 0;border-top:1px solid var(--border)}
.mdash .op:first-of-type{border-top:none}
.mdash .op .bk{color:var(--text-3)}
.mdash .op .bk svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:2}
.mdash .op .main{flex:1;min-width:0}
.mdash .tagcat{display:inline-block;font-size:11px;font-weight:700;padding:3px 9px;border-radius:7px;margin-bottom:6px}
.mdash .tag-services{background:#eaf5ff;color:var(--secondary)}
.mdash .tag-construction{background:var(--green-soft);color:#16a34a}
.mdash .tag-fournitures{background:var(--amber-soft);color:#b45309}
.mdash .op .ttl{font-weight:600;font-size:14px;color:var(--text);line-height:1.3}
.mdash .op .loc{font-size:12.5px;color:var(--text-3);margin-top:3px;display:flex;align-items:center;gap:5px}
.mdash .op .loc svg{width:13px;height:13px;stroke:currentColor;fill:none;stroke-width:2}
.mdash .op .right{text-align:right;flex:0 0 auto}
.mdash .op .amt{font-family:var(--font-d);font-weight:700;font-size:15px}
.mdash .op .dl{font-size:12px;color:var(--text-3);margin-top:3px}
.mdash .op .dl b{color:var(--primary)}

/* ---------- Anneau de score ---------- */
.mdash .ring{--p:0;--c:var(--green);width:46px;height:46px;flex:0 0 46px;border-radius:50%;display:grid;place-items:center;background:conic-gradient(var(--c) calc(var(--p)*1%),#eef1f6 0);position:relative}
.mdash .ring::before{content:"";position:absolute;inset:4px;border-radius:50%;background:#fff}
.mdash .ring span{position:relative;font-family:var(--font-d);font-weight:700;font-size:12px}

/* ---------- Candidatures ---------- */
.mdash .cand{display:flex;align-items:center;gap:14px;padding:14px 0;border-top:1px solid var(--border)}
.mdash .cand:first-of-type{border-top:none}
.mdash .cand .main{flex:1;min-width:0}
.mdash .cand .ttl{font-weight:600;font-size:14px}
.mdash .cand .sub{font-size:12.5px;color:var(--text-3);margin-top:2px}
.mdash .status{display:inline-block;font-size:11px;font-weight:700;padding:4px 10px;border-radius:var(--r-pill);margin-top:7px}
.mdash .st-prep{background:#eaf5ff;color:var(--secondary)}
.mdash .st-red{background:var(--purple-soft);color:var(--purple)}
.mdash .st-fin{background:var(--green-soft);color:#16a34a}

/* ---------- Crédits ---------- */
.mdash .cons{display:flex;gap:18px;align-items:center}
.mdash .donut{position:relative;width:150px;height:150px;flex:0 0 150px}
.mdash .donut svg{width:150px;height:150px}
.mdash .donut .center{position:absolute;inset:0;display:grid;place-items:center;text-align:center}
.mdash .donut .big{font-family:var(--font-d);font-weight:800;font-size:26px;letter-spacing:-.03em;line-height:1}
.mdash .donut .cap{font-size:11px;color:var(--text-2)}
.mdash .donut .cap2{font-size:11px;color:var(--text-3);margin-top:3px}
.mdash .legend{flex:1;display:flex;flex-direction:column;gap:11px}
.mdash .legend .lg{display:flex;align-items:center;gap:9px;font-size:13px}
.mdash .legend .dot{width:10px;height:10px;border-radius:50%;flex:0 0 10px}
.mdash .legend .lg .n{margin-left:auto;font-weight:700;font-size:13px;color:var(--text-2)}
.mdash .hint{margin-top:16px;display:flex;align-items:center;gap:12px;padding:12px 14px;border-radius:12px;background:var(--indigo-soft)}
.mdash .hint p{font-size:12.5px;color:#4338ca;font-weight:500;flex:1;margin:0}
.mdash .btn-buy2{padding:9px 14px;border-radius:10px;background:var(--purple);color:#fff;font-weight:700;font-size:12.5px;border:none;cursor:pointer;white-space:nowrap;text-decoration:none}

/* ---------- Anticipation ---------- */
.mdash .ant{display:flex;align-items:center;gap:13px;padding:13px 0;border-top:1px solid var(--border)}
.mdash .ant:first-of-type{border-top:none}
.mdash .ant .ai{width:34px;height:34px;border-radius:10px;display:grid;place-items:center;flex:0 0 34px}
.mdash .ant .ai svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:2}
.mdash .ant .main{flex:1;min-width:0}
.mdash .ant .k{font-size:12px;font-weight:700}
.mdash .ant .k.g{color:#16a34a}.mdash .ant .k.a{color:#b45309}.mdash .ant .k.b{color:var(--secondary)}
.mdash .ant .ttl{font-size:13.5px;font-weight:600;margin-top:2px}
.mdash .ant .loc{font-size:12px;color:var(--text-3);margin-top:2px}
.mdash .ant .right{text-align:right;flex:0 0 auto}
.mdash .chip{display:inline-block;font-size:10.5px;font-weight:700;padding:3px 8px;border-radius:var(--r-pill)}
.mdash .chip-g{background:var(--green-soft);color:#16a34a}
.mdash .chip-a{background:var(--amber-soft);color:#b45309}
.mdash .chip-b{background:#eaf5ff;color:var(--secondary)}
.mdash .ant .est{font-size:11.5px;color:var(--text-3);margin-top:6px}

/* ---------- Activité ---------- */
.mdash .act{display:flex;gap:12px;padding:11px 0;border-top:1px solid var(--border);align-items:center}
.mdash .act:first-of-type{border-top:none}
.mdash .act .ai{width:30px;height:30px;border-radius:9px;display:grid;place-items:center;flex:0 0 30px}
.mdash .act .ai svg{width:15px;height:15px;stroke:currentColor;fill:none;stroke-width:2}
.mdash .act .main{flex:1;min-width:0}
.mdash .act .ttl{font-size:13.5px;font-weight:600}
.mdash .act .time{font-size:11.5px;color:var(--text-3);white-space:nowrap}

/* ---------- Analytics ---------- */
.mdash .an-stats{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;margin-top:14px;padding-top:14px;border-top:1px solid var(--border)}
.mdash .an-stats .s .v{font-family:var(--font-d);font-weight:800;font-size:20px}
.mdash .an-stats .s .l{font-size:11.5px;color:var(--text-3);margin-top:2px}
.mdash .legend-inline{margin-left:auto;display:flex;gap:14px;font-size:12px;color:var(--text-2)}
.mdash .legend-inline i{display:inline-block;width:10px;height:3px;border-radius:2px;margin-right:5px;vertical-align:middle}

/* ---------- Liens de pied ---------- */
.mdash .link-row{margin-top:14px;padding-top:6px}
.mdash .link-row a{font-size:13px;font-weight:600;color:var(--secondary);display:inline-flex;align-items:center;gap:6px}
.mdash .link-row a svg{width:15px;height:15px;stroke:currentColor;fill:none;stroke-width:2}

/* ---------- Barre Compagnon ---------- */
.mdash .compagnon{display:flex;align-items:center;gap:16px;padding:16px 20px;margin-top:2px;flex-wrap:wrap}
.mdash .compagnon .cav{width:46px;height:46px;border-radius:12px;flex:0 0 46px;background:linear-gradient(160deg,#8b5cf6,#6d28d9);display:grid;place-items:center;color:#fff}
.mdash .compagnon .cav svg{width:24px;height:24px;stroke:#fff;fill:none;stroke-width:1.9}
.mdash .compagnon .ctxt .t1{font-family:var(--font-d);font-weight:700;font-size:14px}
.mdash .compagnon .ctxt .t2{font-size:12.5px;color:var(--text-2);margin-top:1px}
.mdash .compagnon .cin{flex:1;position:relative;min-width:180px;margin:0}
.mdash .compagnon .cin input{width:100%;padding:11px 44px 11px 14px;border-radius:11px;border:1px solid var(--border);background:#fbfcfe;font-family:var(--font-b);font-size:13.5px}
.mdash .compagnon .cin .send{position:absolute;right:8px;top:50%;transform:translateY(-50%);width:30px;height:30px;border-radius:9px;background:var(--purple);color:#fff;border:none;display:grid;place-items:center;cursor:pointer}
.mdash .compagnon .cin .send svg{width:16px;height:16px;stroke:#fff;fill:none;stroke-width:2}
.mdash .compagnon .cin-cta{padding:11px 16px;border-radius:11px;background:var(--purple);color:#fff;font-weight:700;font-size:13.5px;text-decoration:none}
.mdash .cactions{display:flex;gap:10px;flex-wrap:wrap}
.mdash .cbtn{display:inline-flex;align-items:center;gap:8px;padding:10px 14px;border-radius:11px;border:1px solid var(--border);background:#fff;font-family:var(--font-b);font-weight:600;font-size:13px;color:var(--text);cursor:pointer;text-decoration:none;transition:border-color .15s,transform .15s}
.mdash .cbtn:hover{border-color:var(--purple);transform:translateY(-1px)}
.mdash .cbtn svg{width:16px;height:16px;stroke:var(--purple);fill:none;stroke-width:2}
.mdash .cbtn .cost{font-size:10.5px;font-weight:700;color:var(--purple);background:var(--purple-soft);border-radius:var(--r-pill);padding:2px 7px;margin-left:2px}

.mdash .mst-result{margin-bottom:12px}

/* v0.15.2 — variantes explicites de .row3.
   Avant, chaque vue posait un `style="grid-template-columns:..."` inline,
   ce qui court-circuitait le media-query mobile (spécificité inline). */
.mdash .row3-21{grid-template-columns:2fr 1fr}
.mdash .row3-half{grid-template-columns:1fr 1fr}
.mdash .row3-full{grid-template-columns:1fr}

/* responsive */
@media(max-width:1180px){
	.mdash .kpis{grid-template-columns:repeat(2,1fr)}
	.mdash .row3,
	.mdash .row3-21,
	.mdash .row3-half{grid-template-columns:1fr}
}

/* v0.15.2 — carte utilisateur : ajout du bouton « Se déconnecter »
   inséré en bout de ligne dans la même carte, aligné avec l'avatar
   et le libellé. Sans ces règles, le bouton se calait sous le nom. */
.mst-carte-user{position:relative;padding-right:44px}
.mst-carte-logout{position:absolute;top:50%;right:8px;transform:translateY(-50%);width:32px;height:32px;border-radius:10px;display:grid;place-items:center;color:#a6adbf;background:transparent;border:1px solid transparent;transition:background .15s,color .15s,border-color .15s}
.mst-carte-logout:hover,.mst-carte-logout:focus-visible{background:rgba(231,33,58,.12);color:#ff5a6e;border-color:rgba(231,33,58,.3)}
.mst-carte-logout svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.8}

/* ===================================================================
 * SHELL — alignement sur la maquette (sidebar / topbar)
 * =============================================================== */
.mst-sidebar{width:264px;flex-basis:264px;background:#151726;color:#a6adbf;padding:18px 14px}
.mst-nav-item{padding:10px 12px;border-radius:10px;color:#a6adbf;font-weight:500;font-size:14px}
.mst-nav-item:hover{background:#1d2032;color:#fff}
.mst-nav-item.is-active,.mst-nav-item.is-active:hover{background:#4f46e5;color:#fff;box-shadow:0 6px 16px rgba(79,70,229,.35)}
.mst-nav-count{background:#2c3048;color:#c7ccdb}
.mst-nav-item.is-active .mst-nav-count{background:rgba(255,255,255,.22);color:#fff}
.mst-nav-badge{background:rgba(139,92,246,.22);color:#c4b5fd}
.mst-nav-groupe{color:#6b7186;font-size:11px;letter-spacing:.04em;text-transform:uppercase;margin:12px 6px 4px}

/* Entête de vue en double : le dashboard a déjà son « Bonjour » dans .mdash. */
.mst[data-view="dashboard"] .mst-page-head{display:none}

/* ===================================================================
 * v0.9.0 — Analyse approfondie, Analytics/Crédits, bulle de chat
 * =============================================================== */

/* ---- Résultat d'analyse (dans la vue Opportunités, hors .mdash) ---- */
.mst-analyse-res{margin-top:12px}
.mst-analyse-card{background:#fff;border:1px solid #e9edf3;border-radius:14px;padding:16px 18px;box-shadow:0 1px 3px rgba(16,24,40,.05);font-family:'Inter',system-ui,sans-serif;color:#1e293b}
.mst-analyse-card h4{font-family:'Plus Jakarta Sans',sans-serif;font-size:14px;margin:14px 0 8px;display:flex;align-items:center;gap:8px}
.mst-analyse-card h4:first-child{margin-top:0}
.mst-analyse-card .src{font-size:10.5px;font-weight:700;padding:2px 8px;border-radius:999px}
.mst-analyse-card .src.ia{background:#f3effe;color:#8b5cf6}
.mst-analyse-card .src.txt{background:#f0fdf4;color:#16a34a}
.mst-alert{border-radius:10px;padding:10px 12px;font-size:12.5px;font-weight:500;margin:8px 0}
.mst-alert.warn{background:#fffbeb;border:1px solid #fde68a;color:#92400e}
.mst-alert.info{background:#eff6ff;border:1px solid #bfdbfe;color:#1e40af}
.mst-crit{list-style:none;margin:4px 0;padding:0}
.mst-crit .mst-crit{margin-left:16px;border-left:2px solid #eef1f6;padding-left:12px;margin-top:4px}
.mst-crit li{padding:5px 0;font-size:13.5px}
.mst-crit .lib{font-weight:600}
.mst-crit .poids{font-family:'DM Mono',monospace;font-size:12px;color:#8b5cf6;margin-left:6px}
.mst-exig{list-style:none;margin:4px 0;padding:0}
.mst-exig li{font-size:12.5px;padding:5px 0;border-top:1px solid #f1f5f9}
.mst-exig li:first-child{border-top:none}
.mst-exig .tag{font-size:10px;font-weight:700;text-transform:uppercase;padding:2px 7px;border-radius:999px;margin-right:6px;background:#f1f5f9;color:#64748b}
.mst-exig .niv-eliminatoire .tag{background:#fef2f2;color:#e7213a}
.mst-exig .niv-obligatoire .tag{background:#fffbeb;color:#b45309}
.mst-analyse-docs{list-style:none;margin:4px 0;padding:0;font-size:12px;color:#64748b}
.mst-analyse-docs li{padding:3px 0}
.mst-analyse-date{font-size:13px;margin:8px 0 0}
.mst-analyse-card .muted{color:#94a3b8}
.mst-analyser svg{width:15px;height:15px}

/* ---- Barres (Analytics / Crédits) ---- */
.mdash .mst-barres{display:flex;flex-direction:column;gap:12px;margin-top:4px}
.mdash .mst-barre-l{display:grid;grid-template-columns:130px 1fr 44px;align-items:center;gap:10px;font-size:13px}
.mdash .mst-barre-l .lbl{color:#334155;font-weight:500;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.mdash .mst-barre-l .track{height:10px;background:#eef1f6;border-radius:999px;overflow:hidden}
.mdash .mst-barre-l .track i{display:block;height:100%;border-radius:999px}
.mdash .mst-barre-l .val{text-align:right;font-family:'Plus Jakarta Sans',sans-serif;font-weight:700;font-size:13px}

/* ---- Barème des coûts ---- */
.mdash .mst-bareme{width:100%;border-collapse:collapse;font-size:13.5px}
.mdash .mst-bareme th{text-align:left;font-size:11.5px;text-transform:uppercase;letter-spacing:.03em;color:#94a3b8;padding:6px 0;border-bottom:1px solid #e9edf3}
.mdash .mst-bareme td{padding:10px 0;border-bottom:1px solid #f1f5f9}
.mdash .mst-bareme tr:last-child td{border-bottom:none}
.mdash .mst-cout-pill{font-family:'DM Mono',monospace;font-size:12px;font-weight:600;color:#8b5cf6;background:#f3effe;border-radius:999px;padding:3px 10px}
.mdash .mst-inactif-bloc{display:flex;gap:14px;align-items:flex-start}

/* ---- Bulle de chat flottante ---- */
.mst-fab{position:fixed;bottom:26px;right:26px;width:58px;height:58px;border-radius:50%;background:linear-gradient(160deg,#8b5cf6,#6d28d9);color:#fff;border:none;display:grid;place-items:center;cursor:pointer;box-shadow:0 12px 28px rgba(109,40,217,.45);z-index:9998}
.mst-fab svg{width:26px;height:26px;stroke:#fff;fill:none;stroke-width:1.9}
.mst-fab-panel{position:fixed;bottom:96px;right:26px;width:340px;max-width:calc(100vw - 40px);height:440px;max-height:calc(100vh - 140px);background:#fff;border:1px solid #e9edf3;border-radius:18px;box-shadow:0 24px 48px rgba(16,24,40,.18);display:flex;flex-direction:column;overflow:hidden;z-index:9999;font-family:'Inter',system-ui,sans-serif}
.mst-fab-head{display:flex;align-items:center;gap:10px;padding:14px 16px;border-bottom:1px solid #eef1f6}
.mst-fab-avatar{width:34px;height:34px;border-radius:10px;flex:0 0 34px;background:linear-gradient(160deg,#8b5cf6,#6d28d9);display:grid;place-items:center;color:#fff}
.mst-fab-avatar svg{width:18px;height:18px;stroke:#fff;fill:none;stroke-width:1.9}
.mst-fab-head strong{font-family:'Plus Jakarta Sans',sans-serif;font-size:14px;display:block}
.mst-fab-head small{font-size:11.5px;color:#64748b}
.mst-fab-close{margin-left:auto;border:none;background:none;font-size:22px;line-height:1;color:#94a3b8;cursor:pointer}
.mst-fab-log{flex:1;overflow-y:auto;padding:14px 16px;display:flex;flex-direction:column;gap:10px;background:#f8fafc}
.mst-fab-msg{max-width:82%;padding:9px 12px;border-radius:14px;font-size:13px;line-height:1.45;white-space:pre-wrap}
.mst-fab-msg.bot{background:#fff;border:1px solid #eef1f6;color:#1e293b;align-self:flex-start;border-bottom-left-radius:4px}
.mst-fab-msg.user{background:#4f46e5;color:#fff;align-self:flex-end;border-bottom-right-radius:4px}
.mst-fab-form{display:flex;gap:8px;padding:12px 14px;border-top:1px solid #eef1f6}
.mst-fab-form input{flex:1;padding:10px 12px;border-radius:10px;border:1px solid #e9edf3;background:#fbfcfe;font-family:'Inter',system-ui,sans-serif;font-size:13px}
.mst-fab-form button{width:38px;flex:0 0 38px;border:none;border-radius:10px;background:#8b5cf6;color:#fff;display:grid;place-items:center;cursor:pointer}
.mst-fab-form button svg{width:16px;height:16px;stroke:#fff;fill:none;stroke-width:2}
.mst-fab-cta{margin:14px;padding:11px;text-align:center;border-radius:11px;background:#8b5cf6;color:#fff;font-weight:700;font-size:13.5px;text-decoration:none}

/* ---- Facturation (v0.10.0) ---- */
.mdash .mst-abo{display:flex;flex-direction:column;gap:6px}
.mdash .mst-abo-plan{font-family:'Plus Jakarta Sans',sans-serif;font-weight:800;font-size:20px;margin-right:8px}
.mdash .mst-abo-meta{font-size:13px;color:#64748b}
.mdash .mst-plans{display:grid;grid-template-columns:repeat(auto-fit,minmax(160px,1fr));gap:14px}
.mdash .mst-plan{border:1px solid #e9edf3;border-radius:14px;padding:18px;display:flex;flex-direction:column;gap:8px;background:#fff}
.mdash .mst-plan.is-courant{border-color:#8b5cf6;box-shadow:0 0 0 2px rgba(139,92,246,.12)}
.mdash .mst-plan-nom{font-family:'Plus Jakarta Sans',sans-serif;font-weight:700;font-size:16px}
.mdash .mst-plan-prix{font-size:13px;color:#64748b}
.mdash .mst-plan-prix strong{font-family:'Plus Jakarta Sans',sans-serif;font-weight:800;font-size:24px;color:#1e293b;margin-right:4px}
.mdash .mst-plan-credits{font-size:12.5px;color:#94a3b8}
.mdash .mst-plan-btn{margin-top:auto;display:inline-flex;align-items:center;justify-content:center;padding:9px 14px;border-radius:10px;background:#4f46e5;color:#fff;font-weight:700;font-size:13px;border:none;cursor:pointer;text-decoration:none}
.mdash .mst-plan-btn:hover{background:#4338ca}
.mdash .mst-plan-btn.is-courant{background:#f0fdf4;color:#16a34a;cursor:default}
.mdash .mst-plan-btn.is-ghost{background:#fff;border:1px solid #e9edf3;color:#1e293b}
.mdash .mst-cfg-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:12px}
.mdash .mst-cfg-grid label{display:flex;flex-direction:column;gap:5px;font-size:12.5px;font-weight:600;color:#475569}
.mdash .mst-cfg-grid input,.mdash .mst-cfg-grid select{padding:9px 11px;border:1px solid #e9edf3;border-radius:9px;font-family:'Inter',system-ui,sans-serif;font-size:13px;background:#fbfcfe}
.mdash code{font-family:'DM Mono',monospace;font-size:11.5px;background:#f1f5f9;padding:2px 6px;border-radius:5px;color:#475569}

/* ------------------------------------------------------------------
   Équipe & Rôles (v0.11.0 — SaaS multi-tenant)
   ------------------------------------------------------------------ */
.mdash .org-switch{display:flex;flex-direction:column;gap:5px;font-size:12px;font-weight:600;color:#475569}
.mdash .org-switch select{padding:8px 11px;border:1px solid #e9edf3;border-radius:9px;background:#fbfcfe;font-family:'Inter',system-ui,sans-serif;font-size:13px;font-weight:600;color:#1e293b}
.mdash .org-actuelle{display:flex;align-items:center;gap:14px}
.mdash .org-avatar{width:44px;height:44px;border-radius:12px;display:flex;align-items:center;justify-content:center;font-family:'Plus Jakarta Sans',sans-serif;font-weight:800;font-size:18px;color:#fff;background:linear-gradient(135deg,#6366f1,#8b5cf6);flex:0 0 auto}
.mdash .org-actuelle strong{display:block;font-family:'Plus Jakarta Sans',sans-serif;font-size:15px;color:#0f172a}
.mdash .org-actuelle small{color:#94a3b8;font-size:12px}
.mdash .org-table td{vertical-align:middle}
.mdash .mst-link{background:none;border:none;padding:0 8px;font-family:'Inter',system-ui,sans-serif;font-size:12.5px;font-weight:600;color:#4f46e5;cursor:pointer}
.mdash .mst-link:hover{text-decoration:underline}
.mdash .org-role-sel{padding:6px 9px;border:1px solid #e9edf3;border-radius:8px;background:#fbfcfe;font-size:12.5px;font-weight:600;color:#1e293b}
.mdash .org-creer{display:flex;flex-wrap:wrap;align-items:center;gap:10px;margin-top:14px}
.mdash .org-creer input,.mdash .org-creer select{padding:9px 11px;border:1px solid #e9edf3;border-radius:9px;background:#fbfcfe;font-family:'Inter',system-ui,sans-serif;font-size:13px;min-width:220px}
.mdash .org-roles-legende{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px;margin-top:18px;padding-top:16px;border-top:1px solid #f1f5f9}
.mdash .org-roles-legende div{display:flex;flex-direction:column;gap:2px}
.mdash .org-roles-legende strong{font-size:13px;color:#0f172a}
.mdash .org-roles-legende span{font-size:12px;color:#94a3b8;line-height:1.4}

/* ------------------------------------------------------------------
   Supervision plateforme (v0.13.0 — quotas & garde-fous)
   ------------------------------------------------------------------ */
.mdash .sup-kpis{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:14px}
.mdash .sup-kpi{display:flex;flex-direction:column;gap:6px}
.mdash .sup-kpi-l{font-size:12px;font-weight:600;color:#94a3b8}
.mdash .sup-kpi strong{font-family:'Plus Jakarta Sans',sans-serif;font-size:26px;font-weight:800;color:#0f172a}
.mdash .sup-warn{color:#dc2626}
.mdash .sup-table td{vertical-align:top;font-size:13px}
.mdash .sup-bar{height:6px;border-radius:999px;background:#eef2f7;overflow:hidden;margin-top:5px;max-width:120px}
.mdash .sup-bar span{display:block;height:100%;background:#4f46e5;border-radius:999px}
.mdash .sup-bar span.is-haut{background:#dc2626}
.mdash .sup-switch{display:flex;align-items:center;gap:10px;font-size:13.5px;font-weight:600;color:#1e293b;cursor:pointer}
.mdash .sup-switch input{width:18px;height:18px;accent-color:#4f46e5}
.mdash .status.st-red{display:inline-block;font-size:11px;font-weight:700;padding:4px 10px;border-radius:var(--r-pill)}

/* ==================================================================
   Correctifs d'interface v0.13.1
   ================================================================== */

/* --- Barre d'actions des cartes Opportunités ---------------------
   Trois éléments (statut, lien, bouton) sur une seule ligne sans
   retour possible : dans une carte étroite, le bouton « Analyser
   l'offre » débordait hors du cadre. Les éléments flexibles peuvent
   désormais passer à la ligne, et le bouton reste calé à droite. */
.mst-card-actions{flex-wrap:wrap;row-gap:10px;justify-content:flex-start}
.mst-card-actions .mst-statut{flex:0 1 auto;max-width:100%}
.mst-card-actions .mst-detail{flex:0 1 auto;white-space:nowrap}
.mst-card-actions .mst-analyser{margin-left:auto;flex:0 0 auto;white-space:nowrap}
.mst-card,.mst-card-actions,.mst-analyse-res,.mst-card-detail{min-width:0;max-width:100%}
.mst-card-actions>*{min-width:0}

/* Le contenu analysé ne doit jamais élargir la carte. */
.mst-analyse-res,.mst-analyse-card{overflow-wrap:anywhere;word-break:break-word}
.mst-analyse-docs li{overflow-wrap:anywhere}

/* --- Bulle de chat : fermeture -----------------------------------
   `display:flex` sur la classe l'emportait sur le `display:none` que
   le navigateur applique à [hidden] : le panneau restait visible et
   le bouton de fermeture semblait inopérant. */
.mst-fab-panel[hidden]{display:none !important}
.mst-fab-close{width:28px;height:28px;border-radius:8px;display:grid;place-items:center;transition:background .15s,color .15s}
.mst-fab-close:hover{background:#f1f5f9;color:#1e293b}

/* --- Logo et Compagnon : alignement sur la maquette validée ------- */
.mst-brand .mst-logo{width:42px;height:42px;flex:0 0 42px;border-radius:12px;
  background:linear-gradient(160deg,#2a2e45,#3a2140);color:#ff5a6e;overflow:hidden}
.mst-brand .mst-logo svg{width:26px;height:26px;stroke:currentColor;stroke-width:2.2;fill:none}
.mst-fab svg{width:28px;height:28px;stroke:#fff;stroke-width:2.1;fill:none}
.mst-fab-avatar svg{width:20px;height:20px;stroke:#fff;stroke-width:2.1;fill:none}
/* Pastille de notification du bouton flottant (comme la maquette). */
.mst-fab{position:fixed}
.mst-fab-dot{position:absolute;top:-2px;right:-2px;min-width:20px;height:20px;padding:0 5px;
  border-radius:999px;background:#e7213a;color:#fff;font-size:11px;font-weight:700;
  display:grid;place-items:center;border:2px solid #f5f7fa;font-family:'Inter',system-ui,sans-serif}

/* ==================================================================
   Correctifs d'interface v0.14.0 — cartes simplifiées et scoping global
   ================================================================== */

/* Les cartes KPI et leur grille doivent s'afficher aussi hors du wrapper
   .mdash — c'était la cause des cartes empilées verticalement sur la
   vue Opportunités, où seul le dashboard portait la classe .mdash. */
.kpis{display:grid;grid-template-columns:repeat(5,1fr);gap:16px;margin-bottom:18px}
.card{background:#fff;border:1px solid #e9edf3;border-radius:16px;box-shadow:0 1px 2px rgba(16,24,40,.04),0 1px 3px rgba(16,24,40,.05)}
.card.pad{padding:20px}
.kpi{padding:18px}
.kpi .kh{display:flex;align-items:flex-start;gap:12px}
.kpi .ki{width:44px;height:44px;border-radius:12px;display:grid;place-items:center;flex:0 0 44px}
.kpi .ki svg{width:22px;height:22px;stroke-width:1.9}
.kpi .kl{font-size:13px;color:#64748b;font-weight:500}
.kpi .kv{font-family:'Plus Jakarta Sans',sans-serif;font-weight:800;font-size:26px;letter-spacing:-.03em;margin-top:2px;line-height:1}
.kpi .kf{font-size:12px;margin-top:8px;font-weight:600}
.kpi .up{color:#22c55e}
.kpi .muted{color:#94a3b8}
.tint-red{background:#fef2f2;color:#e7213a}
.tint-blue{background:#eaf5ff;color:#0090e7}
.tint-amber{background:#fffbeb;color:#f59e0b}
.tint-green{background:#f0fdf4;color:#22c55e}
.tint-purple{background:#f3effe;color:#8b5cf6}
.tint-indigo{background:#eef0ff;color:#4f46e5}
@media(max-width:1180px){.kpis{grid-template-columns:repeat(2,1fr)}}
@media(max-width:640px){.kpis{grid-template-columns:1fr}}

/* ==================================================================
   Vue « Fiche de l'opportunité » (v0.14.0)
   ================================================================== */

/* v0.15.2 — la coque .mst-app-shell gère déjà les gouttières de la vue.
   Le plafond 1180px ci-dessous étouffait la fiche sur écran large :
   colonnes contexte à 280px minimum donnaient 3 cartes ridicules avec
   du vide autour. On laisse la fiche prendre toute la largeur utile. */
.mst-avis{width:100%;margin:0}
.mst-avis-back{margin-bottom:12px}
.mst-avis-head{display:flex;align-items:flex-start;justify-content:space-between;gap:24px;margin-bottom:20px;flex-wrap:wrap}
.mst-avis-head-l{flex:1;min-width:0}
.mst-avis-ref{font-family:'DM Mono',monospace;font-size:12px;color:#94a3b8;letter-spacing:.02em}
.mst-avis-head-l h1{font-family:'Plus Jakarta Sans',sans-serif;font-weight:800;font-size:24px;letter-spacing:-.03em;color:#0f172a;margin:6px 0 8px;line-height:1.25}
.mst-avis-acheteur{color:#475569;font-size:14px;display:flex;align-items:center;gap:8px}
.mst-avis-acheteur svg{width:16px;height:16px;stroke:#94a3b8}
.mst-avis-head-r{display:flex;align-items:center;gap:10px;flex-shrink:0}

.mst-avis-kpis{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:14px;margin-bottom:18px}
.mst-avis-kpi{background:#fff;border:1px solid #e9edf3;border-radius:14px;padding:16px 18px;display:flex;flex-direction:column;gap:5px;box-shadow:0 1px 2px rgba(16,24,40,.04)}
.mst-avis-kpi-l{font-size:11.5px;font-weight:600;color:#94a3b8;text-transform:uppercase;letter-spacing:.03em}
.mst-avis-kpi strong{font-family:'Plus Jakarta Sans',sans-serif;font-size:20px;font-weight:800;color:#0f172a}
.mst-avis-kpi small{font-size:12px;color:#64748b;font-weight:500}
.mst-avis-kpi small.is-court{color:#e7213a;font-weight:700}

.mst-avis-scoring .mst-avis-axes{display:flex;flex-wrap:wrap;gap:22px;justify-content:flex-start;padding:6px 0}
.mst-avis-synthese{margin-top:16px;padding-top:14px;border-top:1px solid #f1f5f9;color:#475569;font-size:14px;line-height:1.5;font-style:italic}

.mst-avis-contexte{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:14px;margin:18px 0}
.mst-avis-contexte .card{margin:0}
.mst-avis-sortant-nom{font-family:'Plus Jakarta Sans',sans-serif;font-size:16px;color:#0f172a;margin:0 0 6px}
.mst-avis-concs{list-style:none;padding:0;margin:0;display:flex;flex-direction:column;gap:9px}
.mst-avis-concs li{display:flex;justify-content:space-between;align-items:baseline;padding:8px 0;border-bottom:1px solid #f1f5f9;font-size:13.5px}
.mst-avis-concs li:last-child{border-bottom:none}
.mst-avis-concs small{color:#94a3b8;font-size:12px}
.mst-avis-prix{font-size:14px;color:#334155;line-height:1.6}

.mst-avis-docs{display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:10px}
.mst-avis-doc{display:flex;align-items:center;gap:10px;padding:10px 12px;border:1px solid #e9edf3;border-radius:11px;color:#1e293b;transition:border-color .15s,background .15s}
.mst-avis-doc:hover{border-color:#4f46e5;background:#fbfcfe}
.mst-avis-doc svg{width:18px;height:18px;stroke:#4f46e5;flex-shrink:0}
.mst-avis-doc span{display:flex;flex-direction:column;gap:1px;min-width:0}
.mst-avis-doc strong{font-size:13px;font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.mst-avis-doc small{font-size:11px;color:#94a3b8;text-transform:uppercase;letter-spacing:.02em}

.mst-avis-analyse-zone{margin-top:20px}
.mst-avis-cta{display:flex;align-items:center;justify-content:space-between;gap:20px;flex-wrap:wrap;background:linear-gradient(135deg,#f8fafc,#eef0ff)}
.mst-avis-cta-txt{flex:1;min-width:280px}
.mst-avis-cta h3{font-family:'Plus Jakarta Sans',sans-serif;font-size:18px;color:#0f172a;margin:0 0 8px}
.mst-avis-cta p{color:#475569;font-size:14px;line-height:1.55;margin:0 0 6px}
.mst-avis-cta .mst-btn{flex-shrink:0}
.mst-avis-cta .mst-btn svg{width:16px;height:16px}

.mst-avis-analyse{display:flex;flex-direction:column;gap:14px}
.mst-analyse-verdict{background:#fff}
.mst-verdict{display:flex;align-items:flex-start;gap:16px;padding:14px 16px;border-radius:12px;background:#f8fafc;border:1px solid #e9edf3}
.mst-verdict-tag{flex-shrink:0;font-family:'Plus Jakarta Sans',sans-serif;font-weight:800;font-size:15px;padding:8px 16px;border-radius:999px;letter-spacing:.03em}
.mst-verdict.is-go{background:#f0fdf4;border-color:#bbf7d0}
.mst-verdict.is-go .mst-verdict-tag{background:#22c55e;color:#fff}
.mst-verdict.is-mitige{background:#fffbeb;border-color:#fde68a}
.mst-verdict.is-mitige .mst-verdict-tag{background:#f59e0b;color:#fff}
.mst-verdict.is-nogo{background:#fef2f2;border-color:#fecaca}
.mst-verdict.is-nogo .mst-verdict-tag{background:#e7213a;color:#fff}
.mst-verdict ul{margin:0;padding-left:18px;color:#1e293b;font-size:14px;line-height:1.6}
.mst-verdict li{margin-bottom:4px}
.mst-analyse-actions{margin-top:12px;padding-top:12px;border-top:1px solid #f1f5f9;text-align:right}

.mst-crit{list-style:none;padding:0;margin:0;font-size:14px}
.mst-crit .mst-crit{margin:6px 0 6px 22px;padding-left:14px;border-left:2px solid #eef1f6;font-size:13.5px;color:#334155}
.mst-crit li{padding:6px 0;color:#0f172a}
.mst-crit .lib{font-weight:600}
.mst-crit .poids{background:#eef0ff;color:#4f46e5;padding:2px 8px;border-radius:999px;font-family:'DM Mono',monospace;font-size:12px;margin-left:8px;font-weight:700}

.mst-patterns{margin-top:14px;padding-top:14px;border-top:1px solid #f1f5f9;display:flex;flex-direction:column;gap:10px}
.mst-pattern{background:#f8fafc;border-radius:10px;padding:10px 12px;font-size:13px}
.mst-pattern strong{font-family:'Plus Jakarta Sans',sans-serif;color:#0f172a}
.mst-pattern p{margin:4px 0 0;color:#475569;line-height:1.5}

.mst-contraintes{list-style:none;padding:0;margin:0;display:flex;flex-direction:column;gap:12px}
.mst-contraintes li{display:flex;flex-direction:column;gap:2px;padding:10px 12px;background:#fffbeb;border-left:3px solid #f59e0b;border-radius:0 10px 10px 0;font-size:13.5px}
.mst-contraintes strong{color:#0f172a;font-family:'Plus Jakarta Sans',sans-serif}
.mst-contraintes span{color:#92400e;font-weight:600}
.mst-contraintes em{font-style:normal;font-size:12px;margin-top:3px}

.mst-blocs{list-style:none;padding:0;margin:0;display:flex;flex-direction:column;gap:12px}
.mst-blocs li{padding:14px;border-radius:12px;border:1px solid #e9edf3;background:#fff}
.mst-blocs.is-positif li{background:#f0fdf4;border-color:#bbf7d0}
.mst-blocs.is-vigilance li{background:#fef2f2;border-color:#fecaca}
.mst-blocs.is-opportunite li{background:#f3effe;border-color:#c4b5fd}
.mst-blocs strong{font-family:'Plus Jakarta Sans',sans-serif;font-size:14px;color:#0f172a;display:block;margin-bottom:6px}
.mst-blocs p{color:#334155;font-size:13.5px;line-height:1.55;margin:0 0 6px}
.mst-source{display:block;font-size:12px;color:#64748b;font-style:italic;padding-left:8px;border-left:2px solid #cbd5e1}
.mst-gravite{display:inline-block;font-size:10.5px;font-weight:700;padding:2px 7px;border-radius:999px;margin-left:6px;text-transform:uppercase;letter-spacing:.03em}
.mst-gravite.is-haute,.mst-gravite.is-eleve,.mst-gravite.is-élevé{background:#fef2f2;color:#dc2626}
.mst-gravite.is-moyenne,.mst-gravite.is-moyen{background:#fffbeb;color:#b45309}
.mst-gravite.is-faible{background:#f0fdf4;color:#16a34a}

.mst-questions{padding-left:22px;font-size:14px;color:#0f172a;line-height:1.7}
.mst-questions li{margin-bottom:6px}

.mst-analyse-docs{list-style:none;padding:0;margin:0}
.mst-analyse-docs li{display:flex;justify-content:space-between;padding:6px 0;border-bottom:1px solid #f1f5f9;font-size:13px}
.mst-analyse-docs li:last-child{border-bottom:none}

.mst-sortant-fiche{margin-top:14px;padding-top:14px;border-top:1px solid #f1f5f9;font-size:13.5px}
.mst-sortant-fiche h5{font-family:'Plus Jakarta Sans',sans-serif;font-size:13px;color:#0f172a;margin:14px 0 6px}
.mst-sortant-fiche h5:first-of-type{margin-top:0}
.mst-sortant-fiche ul{padding-left:20px;color:#334155}
.mst-sortant-fiche p{color:#334155;line-height:1.55;margin:0 0 8px}
.mst-sortant-profil{background:#f8fafc;padding:10px 12px;border-radius:10px;font-style:italic}

/* Cartes simplifiées de la liste */
.mst-card-titre-lien{color:inherit;display:block;text-decoration:none}
.mst-card-titre-lien:hover h3{color:#4f46e5}
.mst-card-score-row{display:flex;align-items:center;gap:20px;padding:14px 0;border-top:1px solid #f1f5f9;border-bottom:1px solid #f1f5f9;margin:12px 0}
.mst-score-global{flex-shrink:0}
.mst-card-facts{display:flex;flex-direction:column;gap:6px;flex:1;font-size:13px;color:#475569}
.mst-card-facts .mst-fact{display:flex;align-items:center;gap:8px}
.mst-card-facts .mst-fact svg{width:14px;height:14px;stroke:#94a3b8}
.mst-card-actions-simple{justify-content:space-between;padding-top:12px;border-top:none}
.mst-card-actions-simple .mst-btn{white-space:nowrap;text-decoration:none;display:inline-flex;align-items:center;padding:9px 16px}

/* Lien de ligne opportunité prioritaire du dashboard */
.op-lien{color:inherit;text-decoration:none;transition:background .15s}
.op-lien:hover{background:#f8fafc;border-radius:8px}

/* ---- v0.17.1 — tableau d'allotissement ------------------------------- */
.mst-lots{width:100%;border-collapse:collapse;font-size:13.5px;margin:6px 0 10px}
.mst-lots th{text-align:left;font-weight:600;color:#64748b;font-size:12px;text-transform:uppercase;letter-spacing:.04em;padding:6px 10px;border-bottom:1px solid #e2e8f0}
.mst-lots td{padding:9px 10px;border-bottom:1px solid #f1f5f9;color:#1e293b}
.mst-lots tr:last-child td{border-bottom:none}
.mst-lots .ta-r{text-align:right;font-variant-numeric:tabular-nums;font-weight:600}

/* ---- v0.19.0 — provenance, complétion, dépôt du dossier -------------- */

/* Badge de provenance.
   Discret par principe : il signale une origine, il ne réclame pas
   l'attention. Ambre plutôt que rouge — ce n'est pas une erreur, c'est une
   information à vérifier. Le curseur d'aide annonce qu'il y a quelque chose
   à lire au survol, sans quoi personne ne survole. */
.mst-badge-ia{display:inline-flex;align-items:center;gap:4px;margin-left:6px;padding:1px 7px;border-radius:999px;
	background:#fffbeb;border:1px solid #fde68a;color:#b45309;
	font-family:'Inter',sans-serif;font-size:10.5px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;
	cursor:help;vertical-align:middle;white-space:nowrap}
.mst-badge-ia:hover{background:#fef3c7;border-color:#fcd34d}

/* Bandeau de complétion.
   Deux blocs sur une ligne : ce qui manque à gauche, l'action à droite. Le
   fond bleu très pâle le distingue d'une alerte : rien n'est cassé, il y a
   simplement une donnée absente et un moyen d'aller la chercher. */
.mst-completion{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap;
	margin-top:14px;padding:14px 18px;border-radius:14px;
	background:#f8fafc;border:1px solid #e2e8f0}
.mst-completion>div{display:flex;flex-direction:column;gap:2px;min-width:0}
.mst-completion strong{font-family:'Plus Jakarta Sans',sans-serif;font-size:14px;color:#0f172a}
.mst-completion .empty-txt{font-size:12.5px;line-height:1.4}
.mst-completion button{flex-shrink:0}

#mst-completion-res{margin-top:10px}

/* Zone de dépôt.
   La bordure pointillée dit « posez quelque chose ici » sans texte
   supplémentaire. L'état de survol change la couleur ET le fond : sur un
   écran d'ordinateur portable en plein jour, la seule bordure ne se voit
   pas pendant un glisser-déposer. */
.mst-depot{margin-top:16px;padding:20px;border-radius:14px;text-align:center;
	border:2px dashed #cbd5e1;background:#fbfcfe;transition:border-color .18s,background .18s}
.mst-depot.survol{border-color:#0090e7;background:#eff6ff}
.mst-depot p{margin:0 0 4px;color:#334155;font-size:13.5px}
.mst-depot p.empty-txt{font-size:12.5px}
.mst-depot .mst-link{font-size:13.5px}

.mst-depot-etat{margin-top:12px;padding:9px 14px;border-radius:10px;font-size:13px;
	background:#eff6ff;border:1px solid #bfdbfe;color:#075985}
.mst-depot-etat.ko{background:#fef2f2;border-color:#fecaca;color:#b91c1c}
.mst-depot-etat.ok{background:#f0fdf4;border-color:#bbf7d0;color:#15803d}

/* Référence copiable.
   Le pointillé sous le texte est le seul indice qu'un mot est cliquable
   sans ressembler à un lien — un vrai souligné laisserait croire qu'on
   quitte la page. */
.mst-copiable{cursor:pointer;border-bottom:1px dashed #94a3b8;transition:color .15s,border-color .15s}
.mst-copiable:hover{color:#0090e7;border-bottom-color:#0090e7}

/* Pièce déposée : le lien de retrait reste en retrait, littéralement. */
.mst-piece-suppr{color:#94a3b8;font-size:12.5px}
.mst-piece-suppr:hover{color:#e7213a}

/* ===================================================================
 * v0.20.0 — Collision de nom avec l'administration WordPress
 *
 * wp-admin définit sa propre classe `.card` dans common.css, servie par
 * load-styles.php sur TOUTES les pages d'administration :
 *
 *     .card { min-width:255px; max-width:520px; margin-top:20px; … }
 *
 * Nos cartes portent le même nom. Notre feuille redéfinit le fond, la
 * bordure et l'ombre, mais ne déclarait ni largeur ni marge — donc les
 * valeurs de WordPress passaient. D'où les deux défauts visibles en
 * recette : des cartes figées à 520 px dans une colonne de 1591 px, et
 * des écarts verticaux irréguliers (20 px de WordPress qui s'ajoutaient
 * ou se substituaient aux 18 px voulus selon les blocs).
 *
 * Ce n'est pas un réglage esthétique, c'est une neutralisation. Elle est
 * volontairement placée en fin de feuille et portée par `.mst` pour
 * l'emporter sur la règle de WordPress sans dépendre de l'ordre de
 * chargement.
 * =============================================================== */
.mst .card{position:static;min-width:0;max-width:none;margin:0;box-sizing:border-box}

/* Rythme vertical unique. Les marges adjacentes fusionnent, donc un bloc
   qui porte déjà sa propre marge basse ne double pas l'écart. */
.mst .mdash > * + *{margin-top:18px}
.mst .mdash > .page-head + *{margin-top:0}

/* ===================================================================
 * v0.20.0 — Fiche technique
 * =============================================================== */

/* Deux colonnes. Le seuil est haut (1240 px) volontairement : sous cette
   largeur, la colonne latérale tombe à ~280 px et les libellés se
   coupent en trois lignes — mieux vaut alors une seule colonne. */
.mst-avis-corps{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:18px;align-items:start}
.mst-avis-principal{min-width:0}
.mst-avis-principal > * + *{margin-top:18px}
.mst-avis-lateral{position:sticky;top:18px;min-width:0}

@media (max-width:1240px){
	.mst-avis-corps{grid-template-columns:1fr}
	.mst-avis-lateral{position:static}
}

/* Les sections de la fiche s'organisent d'elles-mêmes selon la place.
   auto-fit et non auto-fill : une seule section restante doit occuper
   toute la largeur au lieu de laisser trois colonnes vides — c'est
   exactement le défaut d'alignement relevé en recette. */
.mst-ft-grille{display:grid;grid-template-columns:repeat(auto-fit,minmax(320px,1fr));gap:18px 28px;margin-top:6px}

.mst-ft-sec{min-width:0}
.mst-ft-sec-t{display:flex;align-items:center;gap:9px;padding-bottom:8px;margin-bottom:4px;border-bottom:1px solid #eef2f7}
.mst-ft-sec-t h4{font-family:'Plus Jakarta Sans',sans-serif;font-size:13px;font-weight:800;color:#0f172a;margin:0;letter-spacing:-.01em;flex:1}
.mst-ft-sec-i{width:26px;height:26px;border-radius:8px;display:grid;place-items:center;flex-shrink:0}
.mst-ft-sec-i svg{width:14px;height:14px;stroke-width:2;fill:none}
.mst-ft-sec-n{font-family:'DM Mono',monospace;font-size:11px;color:#94a3b8;flex-shrink:0}

.mst-ft{width:100%;border-collapse:collapse;font-size:13.5px;table-layout:fixed}
.mst-ft th{width:44%;text-align:left;font-weight:500;color:#64748b;padding:7px 10px 7px 0;vertical-align:top;
	border-bottom:1px solid #f5f7fa;word-break:break-word;hyphens:auto}
.mst-ft td{padding:7px 0;vertical-align:top;color:#1e293b;border-bottom:1px solid #f5f7fa;word-break:break-word}
.mst-ft tr:last-child th,.mst-ft tr:last-child td{border-bottom:none}
.mst-ft strong{font-weight:600;color:#0f172a}

/* Une ligne inconnue s'efface sans disparaître : elle doit rester
   lisible pour dire « l'acheteur n'a pas publié ça », sans capter
   l'attention au détriment des lignes qui portent une valeur. */
.mst-ft tr.is-vide th{color:#a8b3c2}
.mst-ft-nc{color:#a8b3c2;font-style:italic;cursor:help}
.mst-ft-note{display:block;margin-top:3px;font-size:12px;color:#94a3b8;line-height:1.45}

/* Badge de source. L'icône seule pour les valeurs relevées dans une
   pièce ou reconstituées ; « IA » écrit en toutes lettres quand c'est un
   modèle qui a relu le PDF — la distinction change la confiance. */
.mst-badge-src{display:inline-flex;align-items:center;gap:3px;margin-left:6px;padding:1px 5px;border-radius:999px;
	font-family:'Inter',sans-serif;font-size:10px;font-weight:700;letter-spacing:.05em;text-transform:uppercase;
	cursor:help;vertical-align:middle;white-space:nowrap;border:1px solid transparent}
.mst-badge-src svg{width:11px;height:11px;stroke-width:2.2;fill:none}
.mst-badge-src.is-ia{background:#fffbeb;border-color:#fde68a;color:#b45309}
.mst-badge-src.is-doc{background:#eff6ff;border-color:#bfdbfe;color:#0369a1}
.mst-badge-src.is-moteur{background:#f5f3ff;border-color:#ddd6fe;color:#6d28d9}
.mst-badge-src:hover{filter:brightness(.97)}

/* Divergence : les deux valeurs restent visibles, celle du dossier
   marquée comme telle. On ne tranche pas à la place de qui signe. */
.mst-ft-div{display:inline-block;margin-left:6px;padding:1px 7px;border-radius:6px;cursor:help;
	background:#fef2f2;border:1px solid #fecaca;color:#b91c1c;font-size:12px;font-weight:600}

.mst-ft-pied{margin-top:16px;padding-top:12px;border-top:1px solid #f1f5f9;font-size:12.5px}

.mst-ft-resume .mst-ft th{width:46%;font-size:12.5px}
.mst-ft-resume .mst-ft td{font-size:13px}
.mst-ft-lien{display:inline-flex;margin-top:14px;text-decoration:none}

/* Teal manquait alors que la vue d'avis l'utilisait déjà pour
   l'allotissement : le bloc s'affichait sans teinte de fond. */
.tint-teal{background:#effcf9;color:#0d9488}
.mdash .tint-teal{background:#effcf9;color:var(--teal)}
