/* Espace sales GMB Club — DA vitrine gmb-club.com.
   Un seul orange #F97316 (hover #EA580C), navy #0e1b3c, crème #FFF7ED, cartes blanches.
   Boutons pill ; l'information (statuts) reste en texte + carré témoin, jamais en pastilles.
   Contrôles à coins carrés. Pas d'emoji, pas de tiret cadratin. */

@font-face { font-family: "Cabinet Grotesk"; src: url("/fonts/cabinet-grotesk-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Cabinet Grotesk"; src: url("/fonts/cabinet-grotesk-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Manrope"; src: url("/fonts/manrope-variable.woff2") format("woff2"); font-weight: 200 800; font-display: swap; }

:root {
  --orange: #f97316; --orange-hover: #ea580c; --navy: #0e1b3c; --creme: #fff7ed;
  --ink: #0a0a0a; --slate: #475569; --slate-light: #94a3b8; --border: #e2e8f0; --ok: #15803d; --bad: #b91c1c;
  --heading: "Cabinet Grotesk", ui-sans-serif, system-ui, sans-serif;
  --sans: "Manrope", ui-sans-serif, system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { font-family: var(--sans); background: var(--creme); color: var(--ink); min-height: 100dvh; font-size: 15px; line-height: 1.45; }
a { color: var(--orange); }
b, strong { font-weight: 700; }
code { font-family: var(--mono); font-size: .92em; background: #fff; border: 1px solid var(--border); padding: 1px 5px; }
.muted { color: var(--slate); font-size: 13.5px; }
.star { color: var(--orange); }
.danger { color: var(--bad) !important; }

/* ---------- Header ---------- */
.topbar { background: var(--navy); color: #fff; padding-top: env(safe-area-inset-top); }
.topbar-inner { max-width: 1400px; margin: 0 auto; padding: 12px 16px; display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.brand { display: flex; align-items: baseline; gap: 10px; }
.wordmark { font-family: var(--heading); font-weight: 800; font-size: 20px; letter-spacing: .2px; }
.brand-sub { font-size: 13px; color: rgba(255,255,255,.65); font-weight: 500; }
.counters { display: flex; gap: 18px; margin-left: auto; }
.counter { text-align: right; }
.counter b { display: block; font-family: var(--heading); font-weight: 800; font-size: 20px; line-height: 1.1; color: var(--orange); }
.counter span { font-size: 11px; color: rgba(255,255,255,.65); white-space: nowrap; }
.user-menu { position: relative; }
.user-btn { background: none; border: 1px solid rgba(255,255,255,.3); color: #fff; font-family: var(--sans); font-weight: 700; font-size: 13.5px; padding: 7px 14px; border-radius: 999px; cursor: pointer; }
.user-btn:hover { border-color: #fff; }
.user-drop { position: absolute; right: 0; top: calc(100% + 6px); background: #fff; border: 1px solid var(--border); z-index: 70; min-width: 220px; box-shadow: 0 8px 24px rgba(14,27,60,.15); }
.user-drop button { display: block; width: 100%; text-align: left; background: none; border: none; border-bottom: 1px solid var(--border); font-family: var(--sans); font-size: 14px; padding: 11px 14px; cursor: pointer; color: var(--ink); }
.user-drop button:last-child { border-bottom: none; }
.user-drop button:hover { background: var(--creme); }

/* ---------- Onglets ---------- */
.tabs { max-width: 1400px; margin: 0 auto; display: flex; border-bottom: 1px solid var(--border); background: var(--creme); position: sticky; top: 0; z-index: 20; overflow-x: auto; }
.tab { flex: 1; appearance: none; border: none; background: none; font-family: var(--heading); font-weight: 700; font-size: 15px; color: var(--slate); padding: 12px 10px 10px; border-bottom: 2px solid transparent; cursor: pointer; white-space: nowrap; }
.tab.active { color: var(--ink); border-bottom-color: var(--orange); }
main { max-width: 1400px; margin: 0 auto; padding: 14px 12px 40px; }

/* ---------- Contrôles ---------- */
input[type="text"], input[type="search"], input[type="email"], input[type="tel"], input[type="number"], input[type="password"],
input[type="date"], input[type="datetime-local"], input[type="file"], select, textarea {
  width: 100%; font-family: var(--sans); font-size: 16px; color: var(--ink); background: #fff; border: 1px solid var(--border);
  border-radius: 0; padding: 9px 11px; min-height: 42px;
}
@media (min-width: 640px) { input, select, textarea { font-size: 14px !important; } }
textarea { resize: vertical; line-height: 1.4; }
textarea.mono { font-family: var(--mono); font-size: 12.5px !important; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--orange); outline-offset: -1px; }
label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--slate); font-weight: 600; }
label .static { color: var(--ink); font-weight: 500; font-size: 14px; padding: 9px 0; }
.btn-pill, .btn-primary { display: inline-flex; align-items: center; justify-content: center; border-radius: 999px; padding: 8px 16px; font-family: var(--sans); font-weight: 700; font-size: 13.5px; text-decoration: none; border: none; cursor: pointer; min-height: 38px; white-space: nowrap; }
.btn-call, .btn-primary { background: var(--orange); color: #fff; }
.btn-call:hover, .btn-primary:hover { background: var(--orange-hover); }
.btn-primary:disabled { background: var(--slate-light); cursor: default; }
.btn-outline { background: #fff; color: var(--ink); border: 1px solid var(--border); }
.btn-outline:hover { border-color: var(--slate-light); }
.btn-wide { width: 100%; min-height: 44px; }
.btn-ghost { background: none; border: none; color: var(--slate); font-family: var(--sans); font-size: 13px; font-weight: 600; cursor: pointer; padding: 6px 8px; }
.btn-ghost:hover { color: var(--ink); }
.row-end { display: flex; justify-content: flex-end; gap: 8px; align-items: center; flex-wrap: wrap; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.segmented { display: inline-flex; border: 1px solid var(--border); background: #fff; }
.segmented button { background: none; border: none; border-right: 1px solid var(--border); font-family: var(--sans); font-weight: 600; font-size: 13px; padding: 8px 14px; cursor: pointer; color: var(--slate); }
.segmented button:last-child { border-right: none; }
.segmented button.on { background: var(--navy); color: #fff; }

/* ---------- Prospects : split ---------- */
.split { display: grid; grid-template-columns: 1fr; gap: 16px; }
@media (min-width: 960px) { .split { grid-template-columns: minmax(380px, 1fr) minmax(0, 1.3fr); align-items: start; } }
.filters { display: flex; flex-direction: column; gap: 8px; margin-bottom: 10px; }
.filter-row { display: flex; gap: 8px; }
.filter-row select, .filter-row input { flex: 1; min-width: 0; }
.list-meta { font-size: 13px; color: var(--slate); margin: 2px 2px 10px; }
.lead-list { display: flex; flex-direction: column; gap: 8px; }
.lead-card { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 12px 14px; cursor: pointer; }
.lead-card:hover { border-color: var(--slate-light); }
.lead-card.selected { border-color: var(--orange); box-shadow: inset 3px 0 0 var(--orange); }
.lead-head { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.lead-main { min-width: 0; }
.lead-name { font-family: var(--heading); font-weight: 700; font-size: 16px; line-height: 1.25; overflow-wrap: anywhere; }
.lead-sub { font-size: 13px; color: var(--slate); margin-top: 3px; overflow-wrap: anywhere; }
.lead-rappel { font-size: 13px; font-weight: 700; color: var(--orange); margin-top: 4px; }
.lead-rappel.due { color: var(--bad); }
.lead-side { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; flex-shrink: 0; }
.statut-txt { font-size: 12.5px; font-weight: 700; white-space: nowrap; }
.statut-swatch { display: inline-block; width: 9px; height: 9px; background: var(--statut-color, var(--slate-light)); margin-right: 7px; vertical-align: baseline; }
.empty { text-align: center; color: var(--slate); font-size: 14px; padding: 40px 16px; }

/* ---------- Fiche ---------- */
.detail-col { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 14px 16px 20px; }
@media (min-width: 960px) { .detail-col { position: sticky; top: 56px; max-height: calc(100dvh - 70px); overflow-y: auto; } }
@media (max-width: 959px) {
  .detail-col { position: fixed; inset: 0; z-index: 30; border-radius: 0; overflow-y: auto; padding-top: calc(14px + env(safe-area-inset-top)); padding-bottom: calc(24px + env(safe-area-inset-bottom)); }
  body.detail-open { overflow: hidden; }
}
.detail-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.back { padding-left: 0; }
.detail-top-actions { display: flex; gap: 4px; }
.detail-name { font-family: var(--heading); font-weight: 800; font-size: 22px; line-height: 1.15; overflow-wrap: anywhere; }
.detail-sub { font-size: 13.5px; color: var(--slate); margin-top: 4px; }
.lead-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; align-items: center; }
.detail-grid { display: grid; grid-template-columns: 1fr; gap: 10px; margin-top: 14px; }
@media (min-width: 560px) { .detail-grid { grid-template-columns: 1fr 1fr 1fr; } }
.rappel-ctl { display: flex; gap: 4px; align-items: center; }
.call-box { margin-top: 16px; border: 1px solid var(--border); padding: 12px; background: var(--creme); }
.call-title { font-family: var(--heading); font-weight: 700; font-size: 15px; margin-bottom: 8px; }
.call-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-bottom: 8px; }
.call-btn { background: #fff; border: 1px solid var(--border); font-family: var(--sans); font-weight: 700; font-size: 13px; padding: 10px 6px; cursor: pointer; color: var(--ink); min-height: 42px; border-radius: 0; }
.call-btn:hover { border-color: var(--orange); }
.call-btn.primary { background: var(--orange); border-color: var(--orange); color: #fff; }
.call-btn.primary:hover { background: var(--orange-hover); }
.info-table { margin-top: 14px; font-size: 13.5px; display: flex; flex-direction: column; gap: 3px; }
.info-table div { display: grid; grid-template-columns: 120px 1fr; gap: 10px; }
.info-table span:first-child { color: var(--slate); }
.info-table span:last-child { overflow-wrap: anywhere; }
.lead-note-form { display: flex; gap: 8px; margin-top: 14px; align-items: flex-end; }
.lead-note-form textarea { flex: 1; }
.timeline { margin-top: 12px; display: flex; flex-direction: column; gap: 6px; }
.act { border-left: 3px solid var(--border); padding: 6px 10px; font-size: 13.5px; }
.act-appel { border-left-color: var(--orange); }
.act-note { border-left-color: var(--navy); }
.act-statut { border-left-color: var(--ok); }
.act-head { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.act-head span { color: var(--slate-light); font-size: 12px; }
.act-body { white-space: pre-wrap; overflow-wrap: anywhere; margin-top: 3px; }
.note-del { background: none; border: none; color: var(--slate-light); font-size: 12px; cursor: pointer; padding: 0 2px; }
.note-del:hover { color: var(--bad); }

/* ---------- Tableau de bord ---------- */
.dash-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.section-title { font-family: var(--heading); font-weight: 800; font-size: 20px; }
.sub-title { font-family: var(--heading); font-weight: 700; font-size: 16px; margin: 22px 0 8px; }
.section-hint { font-size: 13px; color: var(--slate); margin: 6px 0 12px; max-width: 70ch; }
.table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--border); }
.tbl { border-collapse: collapse; width: 100%; font-size: 14px; }
.tbl th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .06em; color: var(--slate); padding: 10px 12px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.tbl td { padding: 9px 12px; border-bottom: 1px solid var(--border); vertical-align: top; }
.tbl tr:last-child td { border-bottom: none; }
.tbl td.num { font-variant-numeric: tabular-nums; font-family: var(--heading); font-weight: 700; font-size: 16px; }
.tbl.small { font-size: 12px; } .tbl.small td, .tbl.small th { padding: 5px 8px; white-space: nowrap; }
.tbl tr.inactive td { color: var(--slate-light); }
.row-actions { white-space: nowrap; }
.bars { display: flex; gap: 4px; align-items: flex-end; height: 120px; background: #fff; border: 1px solid var(--border); padding: 10px 10px 4px; }
.bar-col { flex: 1; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; height: 100%; gap: 4px; }
.bar-col .bar { width: 100%; max-width: 36px; background: var(--border); position: relative; display: flex; flex-direction: column; justify-content: flex-end; min-height: 2px; }
.bar-rdv { background: var(--orange); width: 100%; }
.bar-col span { font-size: 10px; color: var(--slate-light); }
.pipeline { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--border); }
.pipe-row { display: flex; justify-content: space-between; align-items: center; padding: 9px 12px; border-bottom: 1px solid var(--border); background: none; border-left: none; border-right: none; border-top: none; font-family: var(--sans); font-size: 14px; cursor: pointer; text-align: left; color: var(--ink); width: 100%; }
.pipe-row:hover { background: var(--creme); }
.pipe-row b { font-family: var(--heading); font-weight: 700; font-size: 16px; }
.pipe-row.total { cursor: default; font-weight: 700; background: var(--creme); border-bottom: none; }

/* ---------- Admin ---------- */
.admin-block { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 16px; margin-bottom: 14px; }
.inline-form { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 10px; }
.inline-form input, .inline-form select { width: auto; flex: 1; min-width: 160px; }
.form-grid { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 640px) { .form-grid { grid-template-columns: 1fr 1fr; } }
.form-grid .full { grid-column: 1 / -1; }
.result-box { margin-top: 12px; border: 1px solid var(--border); border-left: 3px solid var(--orange); padding: 10px 14px; font-size: 14px; background: var(--creme); }
.plain-list { margin: 8px 0 0 18px; display: flex; flex-direction: column; gap: 3px; font-size: 13.5px; }

/* ---------- Modale ---------- */
.modal-backdrop { position: fixed; inset: 0; background: rgba(14,27,60,.5); z-index: 80; }
.modal { position: fixed; left: 50%; top: 50%; transform: translate(-50%,-50%); background: #fff; z-index: 90; width: min(720px, calc(100vw - 24px)); max-height: calc(100dvh - 40px); overflow-y: auto; padding: 18px 18px 20px; border-radius: 14px; box-shadow: 0 16px 48px rgba(14,27,60,.3); }
.modal h3 { font-family: var(--heading); font-weight: 800; font-size: 18px; margin-bottom: 12px; }
.toast { position: fixed; bottom: calc(18px + env(safe-area-inset-bottom)); left: 50%; transform: translateX(-50%); background: var(--navy); color: #fff; font-size: 13.5px; padding: 10px 18px; border-radius: 999px; z-index: 100; max-width: 90vw; }

/* ---------- Login ---------- */
.login-body { display: flex; align-items: center; justify-content: center; padding: 20px; }
.login-box { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 28px 24px; width: min(400px, 100%); }
.login-box .brand { color: var(--navy); }
.login-box .brand-sub { color: var(--slate); }
.login-title { font-family: var(--heading); font-weight: 800; font-size: 24px; margin: 18px 0 14px; }
.login-form { display: flex; flex-direction: column; gap: 12px; }
.login-error { color: var(--bad); font-size: 13.5px; font-weight: 600; }
.login-hint { margin-top: 16px; font-size: 13px; color: var(--slate); }

/* ---------- Guide (contenu du manuel) ---------- */
.guide { display: grid; grid-template-columns: 1fr; gap: 24px; }
@media (min-width: 960px) { .guide { grid-template-columns: 230px minmax(0,1fr); gap: 40px; align-items: start; } .toc { position: sticky; top: 60px; } }
.toc { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 12px; display: flex; flex-direction: column; gap: 1px; }
.toc-title { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--slate-light); font-weight: 700; margin-bottom: 6px; padding: 0 6px; }
.toc a { display: grid; grid-template-columns: 24px 1fr; gap: 6px; align-items: baseline; text-decoration: none; color: var(--slate); padding: 5px 6px; font-size: 13.5px; line-height: 1.3; }
.toc a:hover { background: var(--creme); color: var(--ink); }
.toc a b { font-family: var(--heading); font-size: 12px; color: var(--orange); }
@media (max-width: 959px) { .toc { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px,1fr)); } .toc-title { grid-column: 1/-1; } }
.guide-body { display: flex; flex-direction: column; gap: 40px; min-width: 0; font-size: 15.5px; line-height: 1.55; }
.gsec { scroll-margin-top: 60px; min-width: 0; }
.shead { display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: baseline; border-top: 2px solid var(--navy); padding-top: 12px; margin-bottom: 14px; }
.snum { font-family: var(--heading); font-size: 13px; font-weight: 800; color: var(--orange); }
.shead h2 { font-family: var(--heading); font-weight: 800; font-size: clamp(20px, 3vw, 26px); line-height: 1.15; }
.gcontent p { max-width: 70ch; margin: 0 0 10px; }
.gcontent .lede { color: var(--slate); font-size: 16px; }
.gcontent h3 { font-family: var(--heading); font-weight: 700; font-size: 17px; margin: 22px 0 8px; }
.gcontent h4 { font-family: var(--heading); font-weight: 700; font-size: 14.5px; margin: 0 0 6px; }
.gcontent .card { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 16px 18px; }
.gcontent .card p:last-child { margin-bottom: 0; }
.gcontent .big { font-size: 17.5px; line-height: 1.5; }
.gcontent .grid2, .gcontent .grid3 { display: grid; grid-template-columns: 1fr; gap: 10px; }
@media (min-width: 640px) { .gcontent .grid2 { grid-template-columns: 1fr 1fr; } .gcontent .grid3 { grid-template-columns: repeat(3,1fr); } }
.gcontent .figs { display: grid; grid-template-columns: repeat(2,1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); }
@media (min-width: 720px) { .gcontent .figs { grid-template-columns: repeat(3,1fr); } }
.gcontent .fig { background: #fff; padding: 12px 14px; }
.gcontent .fig b { display: block; font-family: var(--heading); font-weight: 800; font-size: 26px; color: var(--orange); line-height: 1.1; }
.gcontent .fig span { font-size: 13px; color: var(--slate); }
.gcontent .script { border-left: 3px solid var(--orange); display: flex; flex-direction: column; }
.gcontent .beat { display: grid; grid-template-columns: 1fr; gap: 4px; padding: 12px 0 12px 14px; border-bottom: 1px solid var(--border); }
@media (min-width: 680px) { .gcontent .beat { grid-template-columns: 80px minmax(0,1fr); gap: 14px; } }
.gcontent .beat:last-child { border-bottom: none; }
.gcontent .t { font-family: var(--heading); font-size: 12px; font-weight: 800; color: var(--orange); padding-top: 3px; white-space: nowrap; }
.gcontent .say { font-size: 16px; border-left: 2px solid var(--slate-light); padding-left: 12px; margin: 0; }
.gcontent .say em { color: var(--slate); }
.gcontent .dir, .gcontent .why { font-size: 13px; color: var(--slate); margin: 8px 0 0; }
.gcontent .why b, .gcontent .dir b { color: var(--ink); }
.gcontent .obj { border: 1px solid var(--border); background: #fff; margin-top: 10px; }
.gcontent .obj .q { background: var(--creme); padding: 10px 14px; font-weight: 700; border-bottom: 1px solid var(--border); }
.gcontent .obj .a { padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; }
.gcontent .obj .a p { margin: 0; }
.gcontent ul.plain, .gcontent ol.plain { margin: 0 0 10px 20px; display: flex; flex-direction: column; gap: 6px; max-width: 70ch; }
.gcontent li::marker { color: var(--orange); font-weight: 700; }
.gcontent ul.tick { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.gcontent ul.tick li { display: grid; grid-template-columns: 18px 1fr; gap: 10px; }
.gcontent ul.tick li::before { content: ""; width: 12px; height: 12px; border: 1.5px solid var(--slate-light); margin-top: 5px; }
.gcontent .note { border-left: 3px solid var(--navy); background: #fff; border-top: 1px solid var(--border); border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 12px 14px; margin: 12px 0; }
.gcontent .note.warn { border-left-color: var(--bad); }
.gcontent .note.good { border-left-color: var(--ok); }
.gcontent .note p { margin: 0; } .gcontent .note p + p { margin-top: 6px; }
.gcontent .note .lab { display: block; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; font-weight: 800; margin-bottom: 4px; color: var(--navy); }
.gcontent .note.warn .lab { color: var(--bad); } .gcontent .note.good .lab { color: var(--ok); }
.gcontent .tw { overflow-x: auto; border: 1px solid var(--border); background: #fff; margin-bottom: 8px; }
.gcontent table { border-collapse: collapse; width: 100%; min-width: 480px; font-size: 14px; }
.gcontent th { text-align: left; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--slate); padding: 9px 12px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.gcontent td { padding: 9px 12px; border-bottom: 1px solid var(--border); vertical-align: top; }
.gcontent tr:last-child td { border-bottom: none; }
.gcontent td.num { font-variant-numeric: tabular-nums; white-space: nowrap; }
.gcontent .clock { display: flex; flex-direction: column; gap: 6px; }
.gcontent .slot { display: grid; grid-template-columns: 100px 1fr; gap: 12px; align-items: center; font-size: 14px; }
.gcontent .slot .h { font-weight: 700; text-align: right; color: var(--slate); font-variant-numeric: tabular-nums; font-size: 12.5px; }
.gcontent .bar { padding: 6px 10px; border-left: 3px solid var(--slate-light); background: var(--creme); }
.gcontent .bar.go { border-left-color: var(--ok); }
.gcontent .bar.stop { border-left-color: var(--bad); }
.gcontent code { font-size: .9em; }
.gcontent hr { border: none; border-top: 1px solid var(--border); margin: 18px 0; }
