:root {
  color-scheme: dark;
  --bg: #0b0d12;
  --bg-2: #10131a;
  --surface: #14171f;
  --surface-2: #1a1e28;
  --glass: rgba(26, 30, 40, .72);
  --line: rgba(255, 255, 255, .07);
  --line-2: rgba(255, 255, 255, .12);
  --text: #eef0f4;
  --text-2: #a3a9b6;
  --text-3: #868d9b;               /* ≥ 4,5:1 sur les cartes (accessibilité AA) */
  --accent: #338ced;
  --accent-2: #1b64be;
  --series-1: #338ced;
  --series-2: #e76624;
  --good: #0aac23;
  --good-text: #3fd25a;
  --warn: #fbb315;
  --serious: #f18a59;
  --crit: #dc3c3d;
  --crit-text: #ff7a7a;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 10px 30px rgba(0, 0, 0, .35);
  --font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  font-family: var(--font); font-size: 14px; line-height: 1.45; color: var(--text);
  background: radial-gradient(1200px 600px at 75% -10%, rgba(51, 140, 237, .10), transparent 60%),
              radial-gradient(900px 500px at -10% 110%, rgba(231, 102, 36, .06), transparent 60%), var(--bg);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
.tabnum { font-variant-numeric: tabular-nums; }

/* ---------- layout ---------- */
.app { display: grid; grid-template-columns: 236px 1fr; min-height: 100vh; }
.side {
  position: sticky; top: 0; height: 100vh; padding: 18px 12px; border-right: 1px solid var(--line);
  background: rgba(12, 14, 19, .7); backdrop-filter: blur(14px); display: flex; flex-direction: column; gap: 4px; overflow-y: auto;
}
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 10px 18px; font-weight: 800; letter-spacing: .04em; font-size: 17px; }
.brand .logo { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: linear-gradient(135deg, var(--accent), #6a4ce2); font-size: 14px; }
.brand small { font-weight: 600; font-size: 10px; color: var(--text-2); border: 1px solid var(--line-2); padding: 1px 6px; border-radius: 6px; letter-spacing: .08em; }
.nav-group { font-size: 10.5px; text-transform: uppercase; letter-spacing: .1em; color: var(--text-3); padding: 14px 12px 6px; }
.nav a, .nav span {
  display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 10px; color: var(--text-2); font-weight: 500;
  text-decoration: none; transition: background .15s, color .15s;
}
.nav a:hover { background: rgba(255, 255, 255, .04); color: var(--text); }
.nav a.active { background: rgba(51, 140, 237, .14); color: #fff; box-shadow: inset 0 0 0 1px rgba(51, 140, 237, .35); }
.nav .ico { width: 18px; text-align: center; opacity: .9; }
.nav .count { margin-left: auto; font-size: 11px; background: rgba(255, 255, 255, .08); padding: 1px 7px; border-radius: 99px; color: var(--text); }
.nav .count.hot { background: rgba(220, 60, 61, .2); color: var(--crit-text); }
.nav span.soon { opacity: .45; cursor: default; }
.nav span.soon em { margin-left: auto; font-style: normal; font-size: 10px; border: 1px solid var(--line-2); padding: 0 6px; border-radius: 6px; }
.side-foot { margin-top: auto; padding: 10px 12px; font-size: 11px; color: var(--text-3); display: flex; flex-direction: column; gap: 4px; }
.dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--text-3); margin-right: 6px; vertical-align: 1px; }
.dot.on { background: var(--good); box-shadow: 0 0 8px var(--good); }

.main { padding: 26px 30px 80px; max-width: 1360px; width: 100%; }
.topbar { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.topbar h1 { margin: 0; font-size: 28px; letter-spacing: -.02em; font-weight: 750; }
.topbar .sub { color: var(--text-2); margin-top: 4px; }
.topbar .actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- cards ---------- */
.grid { display: grid; gap: 14px; }
.g-kpi { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.g-2 { grid-template-columns: 1.35fr 1fr; }
.g-2b { grid-template-columns: 1fr 1fr; }
.g-3 { grid-template-columns: repeat(3, 1fr); }
.card {
  background: var(--glass); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px;
  backdrop-filter: blur(12px); box-shadow: var(--shadow); min-width: 0;
}
.card h3 { margin: 0 0 12px; font-size: 13px; font-weight: 650; color: var(--text-2); display: flex; align-items: center; gap: 8px; justify-content: space-between; }
.card h3 .h-left { display: flex; align-items: center; gap: 8px; }
.kpi .label { color: var(--text-2); font-size: 12px; display: flex; align-items: center; gap: 6px; }
.kpi .value { font-size: 26px; font-weight: 750; letter-spacing: -.02em; margin-top: 6px; }
.kpi .hint { color: var(--text-3); font-size: 12px; margin-top: 2px; }
.progress { height: 6px; border-radius: 99px; background: rgba(255, 255, 255, .07); margin-top: 10px; overflow: hidden; }
.progress > i { display: block; height: 100%; border-radius: 99px; background: var(--accent); }
.mt { margin-top: 14px; }
.muted { color: var(--text-2); }
.faint { color: var(--text-3); }
.small { font-size: 12px; }
.empty { color: var(--text-3); padding: 18px 4px; text-align: center; }

/* ---------- buttons & forms ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 7px; padding: 8px 13px; border-radius: 10px; border: 1px solid var(--line-2);
  background: rgba(255, 255, 255, .04); color: var(--text); cursor: pointer; font-weight: 550; white-space: nowrap; text-decoration: none;
}
.btn:hover { background: rgba(255, 255, 255, .08); text-decoration: none; }
.btn.primary { background: #1f6fd1; border-color: transparent; color: #fff; }   /* blanc sur bleu ≥ 4,9:1 */
.btn.primary:hover { background: #4598f2; }
.btn.good { background: rgba(10, 172, 35, .16); border-color: rgba(10, 172, 35, .4); color: var(--good-text); }
.btn.danger { color: var(--crit-text); border-color: rgba(220, 60, 61, .35); }
.btn.sm { padding: 5px 9px; font-size: 12px; border-radius: 8px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn.on { background: rgba(51, 140, 237, .18); border-color: rgba(51, 140, 237, .5); color: #fff; }
input[type=text], input[type=number], input[type=email], input[type=tel], input[type=password], input[type=date], input[type=month], select, textarea {
  width: 100%; padding: 9px 11px; border-radius: 10px; border: 1px solid var(--line-2); background: rgba(0, 0, 0, .25); outline: none;
}
input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(51, 140, 237, .18); }
textarea { resize: vertical; min-height: 90px; line-height: 1.5; }
select option { background: var(--surface-2); }
label.f { display: flex; flex-direction: column; gap: 5px; font-size: 12px; color: var(--text-2); }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.check { display: flex; align-items: center; gap: 8px; color: var(--text); font-size: 13px; cursor: pointer; }

/* ---------- badges ---------- */
.tag { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; padding: 2px 8px; border-radius: 99px; border: 1px solid var(--line-2); color: var(--text-2); white-space: nowrap; }
.tag.src-boamp { border-color: rgba(51, 140, 237, .4); color: #8fc1f7; }
.tag.src-permis { border-color: rgba(152, 135, 239, .45); color: #c2b8f6; }
.tag.src-b2b { border-color: rgba(0, 168, 136, .45); color: #5fd8bd; }
.tag.src-devis { border-color: rgba(231, 102, 36, .45); color: #f6a77d; }
.tag.src-manuel { color: var(--text-2); }
.score { display: inline-grid; place-items: center; min-width: 38px; height: 26px; border-radius: 8px; font-weight: 750; font-size: 12.5px; font-variant-numeric: tabular-nums; border: 1px solid var(--line-2); }
.score.hi { background: rgba(10, 172, 35, .15); border-color: rgba(10, 172, 35, .45); color: var(--good-text); }
.score.mid { background: rgba(251, 179, 21, .12); border-color: rgba(251, 179, 21, .4); color: #ffd36b; }
.score.lo { color: var(--text-3); }
.stage { font-size: 11.5px; padding: 2px 9px; border-radius: 99px; background: rgba(255, 255, 255, .06); color: var(--text-2); white-space: nowrap; }
.stage.signe { background: rgba(10, 172, 35, .16); color: var(--good-text); }
.stage.perdu, .stage.ecarte { background: rgba(220, 60, 61, .12); color: var(--crit-text); }
.stage.transmis, .stage.rdv, .stage.devis { background: rgba(51, 140, 237, .15); color: #8fc1f7; }
.status { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; padding: 3px 10px; border-radius: 99px; }
.status.good { background: rgba(10, 172, 35, .15); color: var(--good-text); }
.status.warn { background: rgba(251, 179, 21, .13); color: #ffd36b; }
.status.crit { background: rgba(220, 60, 61, .15); color: var(--crit-text); }

/* ---------- lists ---------- */
.list { display: flex; flex-direction: column; }
.item { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; padding: 11px 6px; border-top: 1px solid var(--line); cursor: pointer; border-radius: 8px; }
.item:first-child { border-top: 0; }
.item:hover { background: rgba(255, 255, 255, .03); }
.item .t { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.item .m { color: var(--text-2); font-size: 12px; display: flex; gap: 8px; flex-wrap: wrap; margin-top: 3px; align-items: center; }
.item .r { text-align: right; display: flex; flex-direction: column; gap: 4px; align-items: flex-end; }
.relance { display: grid; grid-template-columns: 22px 1fr auto; gap: 10px; padding: 10px 4px; border-top: 1px solid var(--line); align-items: start; }
.relance:first-child { border-top: 0; }
.relance .ic { font-size: 15px; line-height: 1.3; }
.relance .t { font-weight: 600; font-size: 13px; }
.relance .msg { color: var(--text-2); font-size: 12.5px; margin-top: 2px; }

table.t { width: 100%; border-collapse: collapse; font-size: 13px; }
table.t th { text-align: left; font-weight: 600; color: var(--text-3); font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; padding: 8px 8px; border-bottom: 1px solid var(--line-2); white-space: nowrap; }
table.t td { padding: 9px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.t td.n, table.t th.n { text-align: right; font-variant-numeric: tabular-nums; }
table.t tr.click { cursor: pointer; }
table.t tr.click:hover td { background: rgba(255, 255, 255, .025); }
.table-wrap { overflow-x: auto; }

/* ---------- kanban ---------- */
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(230px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 8px; }
.col { background: rgba(255, 255, 255, .02); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px; min-height: 200px; }
.col h4 { margin: 2px 4px 10px; font-size: 12px; color: var(--text-2); display: flex; justify-content: space-between; }
.kcard { background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 10px; margin-bottom: 8px; cursor: pointer; }
.kcard:hover { border-color: var(--line-2); }
.kcard .t { font-weight: 600; font-size: 12.5px; margin: 6px 0 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* ---------- fiche chantier ---------- */
.stepper { display: flex; gap: 6px; flex-wrap: wrap; }
.stepper .btn { font-size: 12px; padding: 6px 10px; }
.kv { display: grid; grid-template-columns: 130px 1fr; gap: 6px 12px; font-size: 13px; }
.kv dt { color: var(--text-3); }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.alert { border-radius: 10px; padding: 10px 12px; font-size: 13px; display: block; }
.alert.warn { background: rgba(251, 179, 21, .1); border: 1px solid rgba(251, 179, 21, .3); color: #ffd98a; }
.alert.info { background: rgba(51, 140, 237, .1); border: 1px solid rgba(51, 140, 237, .3); color: #a9cff8; }
.alert.good { background: rgba(10, 172, 35, .1); border: 1px solid rgba(10, 172, 35, .3); color: #8ee39c; }
.big-commission { font-size: 30px; font-weight: 800; letter-spacing: -.02em; color: var(--good-text); }
.pre { white-space: pre-wrap; color: var(--text-2); font-size: 13px; }

/* ---------- chart ---------- */
.chart { position: relative; }
.chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart .grid-line { stroke: rgba(255, 255, 255, .06); }
.chart .axis-text { fill: var(--text-3); font-size: 11px; }
.chart .bar-1 { fill: var(--series-1); }
.chart .bar-2 { fill: var(--series-2); }
.chart .hit { fill: transparent; cursor: default; }
.chart .hit:hover { fill: rgba(255, 255, 255, .04); }
.legend { display: flex; gap: 14px; font-size: 12px; color: var(--text-2); margin-bottom: 8px; flex-wrap: wrap; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.tooltip { position: absolute; pointer-events: none; background: #0b0d12; border: 1px solid var(--line-2); border-radius: 9px; padding: 8px 10px; font-size: 12px; box-shadow: var(--shadow); white-space: nowrap; z-index: 5; display: none; }
.hbar { display: grid; grid-template-columns: 130px 1fr 44px; gap: 10px; align-items: center; font-size: 12.5px; padding: 4px 0; }
.hbar .bar { height: 10px; border-radius: 0 4px 4px 0; background: var(--series-1); min-width: 2px; }
.hbar .lab { color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- modal, toast, login ---------- */
.modal-bg { position: fixed; inset: 0; background: rgba(0, 0, 0, .6); display: grid; place-items: center; z-index: 50; padding: 16px; backdrop-filter: blur(4px); }
.modal { width: min(640px, 100%); max-height: 90vh; overflow: auto; background: var(--surface); border: 1px solid var(--line-2); border-radius: 16px; padding: 20px; box-shadow: var(--shadow); }
.modal h2 { margin: 0 0 14px; font-size: 18px; }
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: #1f2430; border: 1px solid var(--line-2); padding: 10px 16px; border-radius: 12px; z-index: 60; box-shadow: var(--shadow); font-weight: 550; }
.toast.err { border-color: rgba(220, 60, 61, .6); color: var(--crit-text); }
.login { min-height: 100vh; display: grid; place-items: center; padding: 20px; }
.login .card { width: min(380px, 100%); padding: 28px; }
.login h1 { margin: 0 0 4px; font-size: 24px; }

.bottom-nav { display: none; }

/* ---------- mobile ---------- */
@media (max-width: 980px) {
  .g-2, .g-2b, .g-3 { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .app { grid-template-columns: 1fr; }
  .side { display: none; }
  .main { padding: 18px 14px 96px; }
  .topbar h1 { font-size: 23px; }
  .kpi .value { font-size: 22px; }
  .g-kpi { grid-template-columns: 1fr 1fr; }
  .kv { grid-template-columns: 1fr; gap: 2px; }
  .kv dt { margin-top: 6px; }
  .hbar { grid-template-columns: 96px 1fr 36px; }
  .bottom-nav {
    display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; bottom: 0; left: 0; right: 0; z-index: 40;
    background: rgba(12, 14, 19, .92); backdrop-filter: blur(14px); border-top: 1px solid var(--line); padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }
  .bottom-nav a { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 10.5px; color: var(--text-2); padding: 4px; text-decoration: none; position: relative; }
  .bottom-nav a .ico { font-size: 18px; }
  .bottom-nav a.active { color: #fff; }
  .bottom-nav a .count { position: absolute; top: 0; right: 18%; font-size: 9.5px; background: var(--crit); color: #fff; border-radius: 99px; padding: 0 5px; }
}

/* =================== Sélecteur de module =================== */
.switch { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; margin: 0 4px 8px; border-radius: 12px; background: rgba(255, 255, 255, .04); border: 1px solid var(--line); }
.switch a { text-align: center; padding: 6px 4px; border-radius: 9px; font-size: 12px; font-weight: 650; color: var(--text-2); text-decoration: none; }
.switch a.on { background: var(--accent); color: #fff; }
.gold { color: #C8A45D; }

/* =================== Thème BOX2BOX (noir & or) =================== */
.mod-bx { --accent: #C8A45D; --accent-2: #a8873f; --series-1: #C8A45D; }
.mod-bx .switch a.on { background: #C8A45D; color: #0B0B0B; }
.mod-bx .brand .logo.bx { background: #0B0B0B; color: #C8A45D; border: 1px solid #C8A45D; font-size: 11px; }
.mod-bx .nav a.active { background: rgba(200, 164, 93, .14); box-shadow: inset 0 0 0 1px rgba(200, 164, 93, .4); }
.mod-bx .btn.primary { background: #C8A45D; color: #0B0B0B; }
.mod-bx .btn.primary:hover { background: #d6b46f; }
.mod-bx .btn.on { background: rgba(200, 164, 93, .18); border-color: rgba(200, 164, 93, .55); }
.mod-bx .progress > i, .mod-bx .hbar .bar { background: #C8A45D; }
.mod-bx input:focus, .mod-bx select:focus, .mod-bx textarea:focus { border-color: #C8A45D; box-shadow: 0 0 0 3px rgba(200, 164, 93, .18); }
.mod-bx a { color: #d9bb7c; }
.mod-bx .nav a { color: var(--text-2); }
.mod-bx .nav a.active, .mod-bx .nav a:hover { color: #fff; }
.mod-bx .bottom-nav a { color: var(--text-2); } .mod-bx .bottom-nav a.active { color: #C8A45D; }
.mod-bx .switch a:not(.on) { color: var(--text-2); }
.kanban.tight { grid-auto-columns: minmax(175px, 1fr); }
.g-2 > .terminal { align-self: start; }
.mod-bx .alert.info { background: rgba(200, 164, 93, .08); border-color: rgba(200, 164, 93, .3); color: #e6cf9f; }
body:has(.mod-bx) { background: radial-gradient(1100px 560px at 80% -10%, rgba(200, 164, 93, .10), transparent 60%), radial-gradient(800px 480px at -10% 110%, rgba(200, 164, 93, .05), transparent 60%), #0a0a0b; background-attachment: fixed; }

.section-title { display: flex; justify-content: space-between; align-items: baseline; margin: 22px 0 10px; font-weight: 800; letter-spacing: .08em; font-size: 13px; color: #C8A45D; }
.g-data { grid-template-columns: repeat(5, 1fr); }
.g-team { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.data-tile .label { font-weight: 600; }
.kpi-mini { font-size: 24px; font-weight: 800; margin-top: 4px; }

/* Brief du jour façon terminal */
.terminal { background: #050506; border: 1px solid rgba(200, 164, 93, .25); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); min-width: 0; }
.term-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid rgba(255, 255, 255, .06); font-size: 12px; color: var(--text-2); }
.term-bar i { width: 10px; height: 10px; border-radius: 50%; background: #ff5f57; display: inline-block; }
.term-bar i:nth-child(2) { background: #febc2e; } .term-bar i:nth-child(3) { background: #28c840; }
.term-bar span { margin-left: 8px; font-weight: 600; }
.terminal pre { margin: 0; padding: 16px 18px 18px; font-family: var(--mono); font-size: 13.5px; line-height: 1.9; color: #d8d8d8; white-space: pre-wrap; }
.terminal pre b { color: #7cb7ff; font-weight: 700; }
.mod-bx .terminal pre b { color: #C8A45D; }
.terminal pre b.hot { color: #ff7a7a; }
.small-term pre { font-size: 11.5px; line-height: 1.7; padding: 10px 12px; }

.valid-card { display: flex; flex-direction: column; gap: 12px; }
.valid-big { display: flex; align-items: center; gap: 14px; }
.valid-big > span { font-size: 46px; font-weight: 850; color: #C8A45D; line-height: 1; }

/* Agents de l'AI TEAM */
.agent { display: flex; flex-direction: column; gap: 8px; text-decoration: none !important; color: var(--text) !important; transition: transform .15s, border-color .15s; }
.agent:hover { transform: translateY(-2px); border-color: rgba(200, 164, 93, .45); }
.agent-head { display: flex; gap: 12px; align-items: center; }
.agent-ico { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font-size: 18px; background: rgba(200, 164, 93, .12); border: 1px solid rgba(200, 164, 93, .35); color: #C8A45D; flex: none; }
.agent-name { font-weight: 750; font-size: 14px; }
.agent-state { font-size: 11.5px; color: var(--text-3); display: flex; align-items: center; gap: 6px; }
.agent .pulse { width: 7px; height: 7px; border-radius: 50%; background: var(--text-3); display: inline-block; }
.agent.on .pulse { background: var(--good); animation: pulse 1.8s infinite; }
.agent.on .agent-state { color: var(--good-text); }
.agent.wait .pulse { background: var(--warn); animation: pulse 1.2s infinite; }
.agent.wait .agent-state { color: #ffd36b; }
.agent.wait { border-color: rgba(251, 179, 21, .35); }
.agent-stat { font-size: 12.5px; color: var(--text-2); }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(10, 172, 35, .6); } 70% { box-shadow: 0 0 0 7px rgba(10, 172, 35, 0); } 100% { box-shadow: 0 0 0 0 rgba(10, 172, 35, 0); } }
@media (prefers-reduced-motion: reduce) { .agent .pulse { animation: none !important; } .agent:hover { transform: none; } }

/* Onglets, cartes de validation, timeline */
.tabs { display: flex; gap: 6px; margin-bottom: 14px; flex-wrap: wrap; }
.tabs a { padding: 7px 13px; border-radius: 99px; border: 1px solid var(--line-2); color: var(--text-2); font-weight: 600; font-size: 12.5px; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.tabs a.on { background: rgba(255, 255, 255, .08); color: var(--text); border-color: var(--accent); }
.good-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--good); display: inline-block; }
.val { margin-bottom: 14px; }
.val .kind { font-size: 11.5px; font-weight: 700; padding: 3px 9px; border-radius: 99px; background: rgba(200, 164, 93, .14); color: #e6cf9f; white-space: nowrap; }
.timeline { display: flex; flex-direction: column; gap: 10px; }
.tl-item { border-left: 2px solid var(--line-2); padding: 2px 0 2px 12px; font-size: 13px; }
.tl-item.in { border-left-color: var(--series-2); } .tl-item.out { border-left-color: #C8A45D; }
.tl-head { font-size: 12px; color: var(--text-2); margin-bottom: 2px; }
.contacts { letter-spacing: 2px; color: #C8A45D; }
textarea.mono { font-family: var(--mono); font-size: 12.5px; }
.stage.bx-gagne { background: rgba(10, 172, 35, .16); color: var(--good-text); }
.stage.bx-perdu { background: rgba(220, 60, 61, .12); color: var(--crit-text); }
.stage.bx-qualifie, .stage.bx-rdv, .stage.bx-devis { background: rgba(200, 164, 93, .15); color: #e6cf9f; }
.res { display: inline-grid; place-items: center; min-width: 18px; height: 18px; border-radius: 5px; background: rgba(255, 255, 255, .06); font-size: 10px; margin-left: 2px; color: var(--text-2); }

/* Calendrier éditorial */
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal-day { min-height: 74px; border: 1px solid var(--line); border-radius: 10px; padding: 6px; background: rgba(255, 255, 255, .015); }
.cal-day.we { background: rgba(200, 164, 93, .04); }
.cal-d { font-size: 11px; color: var(--text-3); text-transform: capitalize; margin-bottom: 4px; }
.cal-item { font-size: 11px; padding: 4px 6px; border-radius: 6px; background: rgba(200, 164, 93, .14); margin-bottom: 4px; cursor: pointer; line-height: 1.3; }
.cal-item.publie { background: rgba(10, 172, 35, .15); }

/* Étapes de production */
.steps { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.step { border: 1px solid var(--line-2); background: rgba(255, 255, 255, .02); color: var(--text-2); border-radius: 10px; padding: 8px; font-size: 12px; text-align: left; cursor: pointer; display: flex; flex-direction: column; gap: 3px; }
.step span { font-weight: 800; color: var(--text-3); }
.step em { font-style: normal; font-size: 10.5px; color: var(--text-3); }
.step.done { border-color: rgba(10, 172, 35, .4); color: var(--good-text); }
.step.cur { border-color: #C8A45D; background: rgba(200, 164, 93, .12); color: #fff; }

@media (max-width: 980px) { .g-data { grid-template-columns: repeat(3, 1fr); } .steps { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px) { .g-data { grid-template-columns: 1fr 1fr; } .cal { grid-template-columns: repeat(2, 1fr); } .valid-big > span { font-size: 38px; } }

/* =================== Module Objets (vitrine, thème menthe) =================== */
.switch.s3 { grid-template-columns: 1fr 1fr 1fr; }
.mod-ov { --accent: #3ccfa8; --accent-2: #24a885; --mint: #3ccfa8; }
.mod-ov .switch a.on { background: var(--mint); color: #06231c; }
.mod-ov .brand .logo.ov { background: linear-gradient(135deg, #3ccfa8, #1f8f73); color: #06231c; font-size: 15px; }
.mod-ov .nav a.active { background: rgba(60, 207, 168, .13); box-shadow: inset 0 0 0 1px rgba(60, 207, 168, .4); }
.mod-ov .btn.primary { background: var(--mint); color: #06231c; }
.mod-ov .btn.primary:hover { background: #5cdcb9; }
.mod-ov a { color: #7fe3c6; }
.mod-ov .nav a, .mod-ov .bottom-nav a { color: var(--text-2); }
.mod-ov .nav a.active, .mod-ov .nav a:hover { color: #fff; }
.mod-ov .bottom-nav a.active { color: var(--mint); }
.mod-ov .switch a:not(.on) { color: var(--text-2); }
.mod-ov .progress > i { background: var(--mint); }
.mod-ov input:focus, .mod-ov select:focus, .mod-ov textarea:focus { border-color: var(--mint); box-shadow: 0 0 0 3px rgba(60, 207, 168, .18); }
.mod-ov .tabs a.on { border-color: var(--mint); }
.mod-ov .step.cur { border-color: var(--mint); background: rgba(60, 207, 168, .1); color: #fff; }
.mod-ov .section-title { color: var(--mint); }
.mod-ov .alert.info { background: rgba(60, 207, 168, .07); border-color: rgba(60, 207, 168, .3); color: #b5ecdc; }
body:has(.mod-ov) { background: radial-gradient(1000px 520px at 85% -10%, rgba(60, 207, 168, .09), transparent 60%), radial-gradient(700px 420px at -10% 110%, rgba(60, 207, 168, .05), transparent 60%), #0a0c0d; background-attachment: fixed; }
.good-t { color: var(--good-text); } .warn-t { color: #ffd36b; }

/* Héros : avancement du déstockage */
.ov-hero .ov-big { font-size: 44px; font-weight: 800; letter-spacing: -.03em; line-height: 1.05; }
.ov-hero .ov-big small { font-size: 15px; font-weight: 600; color: var(--text-2); margin-left: 6px; letter-spacing: 0; }
.ov-ring { --p: 0; width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: radial-gradient(closest-side, var(--surface) 76%, transparent 77% 100%), conic-gradient(var(--mint) calc(var(--p) * 1%), rgba(255, 255, 255, .08) 0); }
.ov-ring span { font-weight: 800; font-size: 15px; }
.ov-seg { display: flex; gap: 2px; height: 12px; border-radius: 99px; overflow: hidden; margin-top: 14px; background: rgba(255, 255, 255, .05); }
.ov-seg i { display: block; min-width: 6px; }
.s-v { background: var(--mint); } .s-r { background: #fbb315; } .s-l { background: #338ced; } .s-p { background: #5b6170; }
.ov-seg-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 8px; font-size: 12px; color: var(--text-2); }
.ov-seg-legend span { display: inline-flex; align-items: center; gap: 6px; }
.ov-seg-legend i { width: 9px; height: 9px; border-radius: 3px; display: inline-block; }
.ov-seg-legend b { color: var(--text); }
.ov-kpis { grid-template-columns: repeat(5, 1fr); gap: 10px; border-top: 1px solid var(--line); padding-top: 12px; }
.ov-todo { cursor: pointer; }
.ov-todo:hover .t { color: #fff; }
.ov-todo.t-rdv .ic, .ov-todo.t-repondre .ic { background: rgba(60, 207, 168, .14); }
.ov-title { align-items: center; flex-wrap: wrap; gap: 8px; }

/* Galerie */
.ov-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); gap: 14px; }
.ov-card { padding: 0; overflow: hidden; display: flex; flex-direction: column; text-decoration: none !important; color: var(--text) !important; transition: transform .15s, border-color .15s; }
.ov-card:hover { transform: translateY(-3px); border-color: rgba(60, 207, 168, .45); }
.ov-photo { position: relative; aspect-ratio: 4 / 3; background: #1b1f27; overflow: hidden; }
.ov-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ov-ph { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; font-size: 42px; color: var(--text-3); background: repeating-linear-gradient(45deg, rgba(255,255,255,.02) 0 10px, transparent 10px 20px); }
.ov-ph small { font-size: 11.5px; }
.ov-ribbon { position: absolute; top: 10px; left: 10px; font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 99px; background: rgba(10, 12, 16, .78); backdrop-filter: blur(6px); color: #d6dae2; border: 1px solid rgba(255,255,255,.14); }
.ov-ribbon.st-en_ligne { color: #9ccaf8; border-color: rgba(51, 140, 237, .55); }
.ov-ribbon.st-reserve { color: #ffd36b; border-color: rgba(251, 179, 21, .55); }
.ov-ribbon.st-vendu { background: var(--mint); color: #06231c; border-color: transparent; }
.ov-ribbon.st-pret { color: #7fe3c6; border-color: rgba(60, 207, 168, .5); }
.ov-card:has(.st-vendu) .ov-photo img { filter: grayscale(.55) brightness(.8); }
.ov-bubble { position: absolute; top: 10px; right: 10px; font-size: 11.5px; font-weight: 700; padding: 3px 8px; border-radius: 99px; background: var(--crit); color: #fff; }
.ov-body { padding: 12px 13px 13px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.ov-body .t { font-weight: 650; font-size: 13.5px; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.6em; }
.ov-price { font-size: 19px; letter-spacing: -.01em; }
.ov-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: auto; }
.pf { font-size: 10.5px; font-weight: 800; padding: 2px 7px; border-radius: 6px; letter-spacing: .02em; }
.pf-leboncoin { background: rgba(236, 90, 19, .16); color: #ff9a62; }
.pf-facebook { background: rgba(51, 140, 237, .16); color: #8fc1f7; }
.pf-vinted, .pf-autre { background: rgba(255, 255, 255, .08); color: var(--text-2); }
.ov-add { border: 1.5px dashed var(--line-2); background: transparent; color: var(--text-2) !important; align-items: center; justify-content: center; gap: 6px; min-height: 220px; cursor: pointer; font: inherit; font-weight: 600; }
.ov-add span { font-size: 34px; color: var(--mint); }
.ov-seuil { padding: 10px 0; border-top: 1px solid var(--line); display: grid; grid-template-columns: 120px 1fr 1fr; gap: 14px; align-items: center; }
.ov-seuil:first-of-type { border-top: 0; }
.ov-meter .progress { margin-top: 5px; }
.ov-meter.warn .progress > i { background: #fbb315; }
.ov-meter.warn span { color: #ffd36b; }

/* Fiche objet */
.ov-st { font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 99px; border: 1px solid var(--line-2); color: var(--text-2); }
.ov-st.st-en_ligne { color: #9ccaf8; border-color: rgba(51, 140, 237, .5); }
.ov-st.st-reserve { color: #ffd36b; border-color: rgba(251, 179, 21, .5); }
.ov-st.st-vendu { background: var(--mint); color: #06231c; border-color: transparent; }
.ov-st.st-pret { color: #7fe3c6; border-color: rgba(60, 207, 168, .5); }
.ov-cover { border-radius: 12px; overflow: hidden; aspect-ratio: 4 / 3; background: #1b1f27; }
.ov-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ov-thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 8px; margin-top: 10px; }
.ov-thumb { position: relative; aspect-ratio: 1; border-radius: 9px; overflow: hidden; border: 2px solid transparent; }
.ov-thumb.on { border-color: var(--mint); }
.ov-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ov-thumb-a { position: absolute; inset: auto 0 0 0; display: flex; justify-content: space-between; padding: 3px; background: linear-gradient(transparent, rgba(0,0,0,.7)); }
.ov-thumb-a button, .ov-thumb-a span { background: rgba(0,0,0,.55); border: 0; color: #fff; border-radius: 6px; width: 24px; height: 22px; font-size: 12px; cursor: pointer; display: grid; place-items: center; }
.ov-thumb-a span { color: var(--mint); cursor: default; }
.ov-drop { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center; aspect-ratio: 4 / 3; border: 1.5px dashed rgba(60, 207, 168, .45); border-radius: 12px; font-size: 34px; cursor: pointer; background: rgba(60, 207, 168, .04); padding: 16px; }
.ov-drop b { font-size: 14px; }
.ov-upload { cursor: pointer; }
.ov-tips { margin: 8px 0 0; padding-left: 18px; line-height: 1.7; }
.ov-prices { display: flex; gap: 26px; flex-wrap: wrap; align-items: flex-end; }
.ov-price-big { font-size: 36px; font-weight: 800; letter-spacing: -.02em; color: var(--mint); line-height: 1.1; }
.ov-annonce { border: 1px solid var(--line); border-radius: 12px; padding: 12px; background: rgba(255,255,255,.015); }
.ov-annonce.pf-b-leboncoin { border-top: 3px solid rgba(236, 90, 19, .7); }
.ov-annonce.pf-b-facebook { border-top: 3px solid rgba(51, 140, 237, .7); }
.ov-annonce textarea { font-size: 12.5px; line-height: 1.55; }
.ov-paste { border: 1px solid rgba(60, 207, 168, .25); background: rgba(60, 207, 168, .04); border-radius: 12px; padding: 12px; margin-bottom: 12px; }
.ov-contacts { display: flex; flex-direction: column; gap: 10px; }
.ov-contact { border: 1px solid var(--line); border-radius: 12px; padding: 12px; background: var(--surface); }
.ov-contact.scam { border-color: rgba(220, 60, 61, .45); background: linear-gradient(180deg, rgba(220, 60, 61, .06), transparent 60%), var(--surface); }
.ov-msg { color: var(--text-2); font-style: italic; font-size: 13px; white-space: pre-wrap; }

@media (max-width: 980px) { .ov-kpis { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px) {
  .ov-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .ov-body { padding: 9px 10px 10px; }
  .ov-price { font-size: 16px; }
  .ov-kpis { grid-template-columns: 1fr 1fr; }
  .ov-hero .ov-big { font-size: 36px; }
  .ov-ring { width: 68px; height: 68px; }
  .ov-seuil { grid-template-columns: 1fr; gap: 6px; }
  .ov-add { min-height: 160px; }
}
.ov-top { align-items: start; }
.ov-col { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.ov-rules { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.ov-rule { border: 1px solid var(--line); border-radius: 12px; padding: 12px; background: rgba(255, 255, 255, .015); display: flex; flex-direction: column; gap: 4px; }
.ov-rule > span { font-size: 20px; }
.ov-rule b { font-size: 13px; }
.ov-annonce .row input[type=text] { flex: 1; min-width: 0; width: auto; }
@media (max-width: 980px) { .ov-rules { grid-template-columns: 1fr 1fr; } }
@media (max-width: 980px) {
  .ov-col { display: contents; }
  .ov-top .ov-hero { order: 1; } .ov-top .ov-todo-card { order: 2; } .ov-top .ov-seuils-card { order: 3; }
}
.hbar.wide { grid-template-columns: 130px 1fr 96px; }

/* =================== Cockpit QG =================== */
.qg-tiles { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.qg-hero { background: linear-gradient(135deg, rgba(51, 140, 237, .16), rgba(31, 174, 138, .08) 60%, transparent), var(--surface); }
.qg-hero .value { font-size: 34px; }
.qg-tile { text-decoration: none !important; color: var(--text) !important; border-top: 3px solid var(--c); transition: transform .15s, border-color .15s; }
.qg-tile:hover { transform: translateY(-2px); }
.qg-tile .label { display: flex; align-items: center; gap: 7px; }
.qg-tile .label i { width: 9px; height: 9px; border-radius: 3px; background: var(--c); display: inline-block; }
.qg-tile .value small, .qg-hero .value small { font-size: 13px; font-weight: 600; color: var(--text-2); }
.qg-tile .hint { line-height: 1.6; }
.qg-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 7px; vertical-align: 1px; }
.switch.s2 { grid-template-columns: 1fr 1fr; }
.qg-cols { align-items: start; }
.qg-col { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.switch a { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 980px) {
  .qg-col { display: contents; }
  .qg-o1 { order: 1; } .qg-o2 { order: 2; } .qg-o3 { order: 3; } .qg-o4 { order: 4; }
}

/* =================== Accessibilité =================== */
.skip-link { position: absolute; left: 8px; top: -60px; z-index: 100; background: #fff; color: #0b0d12 !important; padding: 8px 14px; border-radius: 8px; font-weight: 700; }
.skip-link:focus { top: 8px; }
:focus { outline: none; }
:focus-visible { outline: 2px solid #7db8f5; outline-offset: 2px; border-radius: 6px; }
.mod-bx :focus-visible { outline-color: #e2c78f; }
.mod-ov :focus-visible { outline-color: #7fe3c6; }
.switch a.on { background: #1f6fd1; }
[data-href]:focus-visible, tr[data-action]:focus-visible { outline-offset: -2px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* Transitions de page (désactivées si « réduire les animations ») */
#page > * { animation: page-in .28s ease-out both; }
#page > *:nth-child(2) { animation-delay: .03s; } #page > *:nth-child(3) { animation-delay: .06s; } #page > *:nth-child(4) { animation-delay: .09s; } #page > *:nth-child(n+5) { animation-delay: .12s; }
@keyframes page-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { #page > * { animation: none; } }

/* Sélecteur d'activités en haut de l'écran (mobile) */
.mob-switch { display: none; }
@media (max-width: 760px) {
  .mob-switch { display: flex; gap: 6px; overflow-x: auto; position: sticky; top: 0; z-index: 30; padding: 10px 14px calc(8px); margin: 0; background: rgba(11, 13, 18, .88); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); scrollbar-width: none; }
  .mob-switch::-webkit-scrollbar { display: none; }
  .mob-switch a { flex: none; padding: 6px 12px; border-radius: 99px; border: 1px solid var(--line-2); color: var(--text-2); font-size: 12.5px; font-weight: 650; text-decoration: none; white-space: nowrap; }
  .mob-switch a.on { background: #1f6fd1; border-color: transparent; color: #fff; }
  .mod-bx .mob-switch a.on { background: #C8A45D; color: #0B0B0B; }
  .mod-ov .mob-switch a.on { background: var(--mint); color: #06231c; }
}

/* =================== Jeu =================== */
.jeu-grid { grid-template-columns: 1fr 1.3fr 1fr; }
.jeu-niveau { display: flex; gap: 16px; align-items: center; background: radial-gradient(400px 200px at 0% 0%, rgba(138, 99, 232, .18), transparent 70%), var(--surface); }
.jeu-niveau > div:last-child { flex: 1; min-width: 0; }
.niv-badge { width: 74px; height: 74px; flex: none; display: grid; place-items: center; border-radius: 22px; background: conic-gradient(from 200deg, #8a63e8, #338ced, #1fae8a, #c98f22, #8a63e8); box-shadow: 0 8px 26px rgba(138, 99, 232, .35); }
.niv-badge span { width: 62px; height: 62px; border-radius: 17px; background: #14171f; display: grid; place-items: center; font-size: 28px; font-weight: 850; }
.niv-titre { font-size: 19px; font-weight: 800; margin: 2px 0 8px; }
.quete { display: grid; grid-template-columns: 10px 1fr auto; gap: 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); font-size: 13px; }
.quete:first-of-type { border-top: 0; }
.quete .progress { margin-top: 6px; }
.quete.faite .q-txt > div:first-child { color: var(--good-text); }
.q-dot { width: 8px; height: 8px; border-radius: 50%; }
.q-xp { font-size: 11.5px; color: var(--text-2); white-space: nowrap; }
.boss { background: radial-gradient(380px 180px at 100% 0%, rgba(220, 60, 61, .14), transparent 70%), var(--surface); }
.boss-pv { position: relative; height: 22px; border-radius: 8px; background: rgba(255, 255, 255, .06); overflow: hidden; }
.boss-pv i { position: absolute; inset: 0 auto 0 0; background: linear-gradient(90deg, #b8322f, #e2574c); transition: width .6s; }
.boss-pv span { position: relative; display: block; text-align: center; font-size: 12px; font-weight: 750; line-height: 22px; }
.boss.vaincu .boss-pv i { background: linear-gradient(90deg, #0aac23, #3fd25a); }
.boss-parts { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-top: 8px; font-size: 11.5px; color: var(--text-2); }
.boss-parts i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 5px; }
.badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; }
.badge { display: flex; flex-direction: column; align-items: center; gap: 4px; text-align: center; padding: 10px 6px; border-radius: 12px; border: 1px solid var(--line); opacity: .5; }
.badge.on { opacity: 1; border-color: rgba(201, 143, 34, .45); background: rgba(201, 143, 34, .07); }
.b-ico { font-size: 24px; }
.b-nom { font-size: 11.5px; line-height: 1.3; }
.niveau-puce { display: flex; gap: 10px; align-items: center; margin: 6px 12px 0; padding: 8px 10px; border-radius: 12px; border: 1px solid var(--line); text-decoration: none !important; color: var(--text) !important; font-size: 12px; }
.niveau-puce:empty { display: none; }
.niv-num { width: 28px; height: 28px; flex: none; border-radius: 9px; display: grid; place-items: center; font-weight: 850; background: linear-gradient(135deg, #8a63e8, #338ced); color: #fff; }
.niveau-puce > span:last-child { flex: 1; min-width: 0; }
.niv-bar { display: block; height: 4px; border-radius: 99px; background: rgba(255, 255, 255, .08); margin-top: 4px; overflow: hidden; }
.niv-bar i { display: block; height: 100%; background: linear-gradient(90deg, #8a63e8, #338ced); }
.confettis { position: fixed; inset: 0; width: 100vw; height: 100vh; pointer-events: none; z-index: 200; }
.celebration { position: fixed; left: 50%; top: 22%; transform: translateX(-50%); z-index: 201; display: flex; gap: 14px; align-items: center; padding: 16px 22px; border-radius: 18px; background: rgba(20, 23, 31, .96); border: 1px solid rgba(201, 143, 34, .5); box-shadow: 0 20px 60px rgba(0, 0, 0, .5); animation: cel-in .35s cubic-bezier(.2, 1.4, .4, 1) both; cursor: pointer; max-width: calc(100vw - 32px); }
.celebration.out { animation: cel-out .4s ease-in both; }
.cel-ico { font-size: 40px; }
.cel-t { font-size: 18px; font-weight: 800; }
.cel-s { color: #e6cf9f; font-weight: 700; margin-top: 2px; }
@keyframes cel-in { from { opacity: 0; transform: translate(-50%, 16px) scale(.9); } to { opacity: 1; transform: translate(-50%, 0) scale(1); } }
@keyframes cel-out { to { opacity: 0; transform: translate(-50%, -10px); } }
@media (prefers-reduced-motion: reduce) { .celebration, .celebration.out { animation: none; } }
@media (max-width: 980px) { .jeu-grid { grid-template-columns: 1fr; } }

/* =================== Accueil Chantiers : équipe d'agents + radar =================== */
.ch-title { margin-top: 4px; color: #7db8f5; }
.ch-team { grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.mod-ch .agent:hover { border-color: rgba(51, 140, 237, .5); }
.mod-ch .agent-ico { background: rgba(51, 140, 237, .12); border-color: rgba(51, 140, 237, .4); color: #7db8f5; }
.radar { width: 100%; max-width: 132px; align-self: center; margin: 2px 0; }
.r-ring { fill: none; stroke: rgba(51, 140, 237, .28); stroke-width: .6; }
.r-sweep { transform-origin: 50px 50px; animation: sweep 3.2s linear infinite; }
.blip { animation: blip 3.2s ease-out infinite; }
@keyframes sweep { to { transform: rotate(360deg); } }
@keyframes blip { 0%, 100% { opacity: .35; } 12% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .r-sweep, .blip { animation: none; } .blip { opacity: 1; } }

/* =================== Carte =================== */
.carte-wrap { padding: 0; overflow: hidden; position: relative; }
#carte { height: min(68vh, 640px); background: #0f1218; }
#carte .leaflet-tile-pane { filter: invert(1) hue-rotate(180deg) brightness(.92) contrast(.88) saturate(.6); }
.leaflet-container { font-family: var(--font); }
.leaflet-popup-content-wrapper, .leaflet-popup-tip { background: #1a1e28; color: var(--text); border: 1px solid var(--line-2); }
.leaflet-container a.leaflet-popup-close-button { color: var(--text-2); }
.leaflet-control-attribution { background: rgba(11, 13, 18, .8) !important; color: var(--text-2) !important; }
.leaflet-control-attribution a { color: #7db8f5 !important; }
.leaflet-bar a { background: #1a1e28; color: var(--text); border-color: var(--line-2); }
.pop { min-width: 190px; } .pop-t { font-weight: 750; margin-bottom: 3px; } .pop-m { color: var(--text-2); font-size: 12px; } .pop a { display: inline-block; margin-top: 6px; font-weight: 650; }
.pin { display: block; width: var(--r); height: var(--r); border-radius: 50%; background: var(--c); border: 2px solid rgba(11, 13, 18, .85); box-shadow: 0 0 0 1px var(--c); }
.pin.prospect { border-radius: 4px; transform: rotate(45deg); }
.pin.chaud { animation: pin-pulse 1.6s infinite; }
@keyframes pin-pulse { 0% { box-shadow: 0 0 0 0 var(--c); } 70% { box-shadow: 0 0 0 10px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
@media (prefers-reduced-motion: reduce) { .pin.chaud { animation: none; } }
.carte-legende { position: absolute; left: 12px; bottom: 12px; z-index: 500; display: flex; flex-wrap: wrap; gap: 6px 12px; max-width: calc(100% - 24px); padding: 8px 12px; border-radius: 10px; background: rgba(11, 13, 18, .85); border: 1px solid var(--line); }
.carte-legende i { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 5px; vertical-align: -1px; }
.carte-legende i.chaud { background: transparent; box-shadow: 0 0 0 2px #e76624; }
.carte-hors { position: absolute; top: 12px; left: 56px; right: 12px; z-index: 500; padding: 8px 12px; border-radius: 10px; background: rgba(251, 179, 21, .12); border: 1px solid rgba(251, 179, 21, .35); color: #ffd98a; }
.carte-pt { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }

/* ---- Pilotage : échéancier, verdicts, bilans ---- */
.crit-text { color: var(--crit-text); }
.mod-tag { display: inline-block; font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 999px; border: 1px solid; vertical-align: 1px; }
.mod-tag.mod-ch { color: #7db8f5; border-color: rgba(51, 140, 237, .45); background: rgba(51, 140, 237, .1); }
.mod-tag.mod-bx { color: #e2b25a; border-color: rgba(201, 143, 34, .45); background: rgba(201, 143, 34, .1); }
.mod-tag.mod-ov { color: #5fd3b2; border-color: rgba(31, 174, 138, .45); background: rgba(31, 174, 138, .1); }
.ech-tot { display: flex; flex-wrap: wrap; gap: 10px; }
.ech-t { display: flex; flex-direction: column; gap: 2px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 10px; min-width: 130px; }
.ech-t b { font-size: 18px; }
.ech-t.crit { border-color: rgba(220, 60, 61, .5); } .ech-t.crit b { color: var(--crit-text); }
.ech-t.good b { color: var(--good-text); }
.t tr.grp th { background: transparent; color: var(--text-2); font-size: 12px; text-transform: uppercase; letter-spacing: .04em; padding-top: 14px; }
.verdict-mini { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; padding: 2px 9px; border-radius: 999px; border: 1px solid var(--line); white-space: nowrap; }
.verdict-mini.performant { color: var(--good-text); border-color: rgba(46, 160, 67, .45); }
.verdict-mini.moyen { color: var(--warn-text, #e8b04a); border-color: rgba(232, 176, 74, .45); }
.verdict-mini.pas_performant { color: var(--crit-text); border-color: rgba(220, 60, 61, .45); }
.bilans td.v { white-space: nowrap; }
.tag.src-bodacc { border-color: rgba(201, 143, 34, .45); color: #e2b25a; }
.tag.src-dpe { border-color: rgba(220, 60, 61, .45); color: #ff9a8a; }
.tag.src-rnic { border-color: rgba(120, 150, 180, .5); color: #b4c6da; }
.tag.src-alerte { border-color: rgba(31, 174, 138, .45); color: #6fdcc0; }
