/* ============================================================
   Restanq — design system & shell
   Palette héritée : fond #07111e / #0d1829, accent #00BF93
   Aucun sélecteur lié à un ancien concept métier.
   ============================================================ */

:root {
  --bg: #07111e;
  --bg2: #0d1829;
  --bg3: #122036;
  --panel: #0f1c30;
  --green: #00BF93;
  --green2: #00a87e;
  --green-dim: rgba(0, 191, 147, 0.12);
  --gold: #d6b04a;
  --gold2: #e6c25a;
  --gold-ink: #3a2a05;
  --gold-dim: rgba(214, 176, 74, 0.14);
  --gold-grad: linear-gradient(135deg, #f5c451, #e0a020);
  --blue: #4da3ff;
  --amber: #f5a623;
  --red: #ff5d5d;
  --violet: #9b7bff;
  --text: #e2edf9;
  --text2: #b8cfea;
  --muted: #7f96b3;
  --line: rgba(184, 207, 234, 0.12);
  --line2: rgba(184, 207, 234, 0.22);
  --sb-w: 264px;
  --hd-h: 60px;
  --ft-h: 58px;
  --r: 10px;
  --r-lg: 14px;
  --font-display: 'Sora', sans-serif;
  --font-body: 'Outfit', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
}

[data-theme="light"] {
  --bg: #f2f5f9; --bg2: #ffffff; --bg3: #eaeff5; --panel: #ffffff;
  --green: #00997a; --green2: #00BF93; --green-dim: rgba(0,168,126,.12);
  --line: #dde5ee; --line2: #c8d4e2;
  --text: #15202e; --text2: #3c4a5c; --muted: #74829a;
  --shadow: 0 12px 30px rgba(21,32,46,.12);
}
[data-theme="light"] .header,
[data-theme="light"] .footer { background: rgba(255,255,255,.85); }
[data-theme="light"] .sidebar { background: #ffffff; }
[data-theme="light"] .hd-icon,
[data-theme="light"] .quota { background: var(--bg3); }

* { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
}
button { font-family: inherit; cursor: pointer; color: inherit; background: none; border: none; }
input, textarea, select { font-family: inherit; color: inherit; }
input:not([type="checkbox"]):not([type="radio"]):not([type="file"]), textarea, select {
  background: var(--bg); border: 1px solid var(--line2); border-radius: 8px; padding: 8px 11px; font-size: 13.5px;
}
input:not([type="checkbox"]):not([type="radio"]):not([type="file"]):focus, textarea:focus, select:focus {
  outline: none; border-color: var(--green); box-shadow: 0 0 0 2px var(--green-dim);
}
input::placeholder, textarea::placeholder { color: var(--muted); }
select option { background: var(--bg2); color: var(--text); }
a { color: inherit; text-decoration: none; }
::selection { background: var(--green-dim); }

/* ---------- Grille du shell ---------- */
.app {
  display: grid;
  grid-template-columns: var(--sb-w) 1fr;
  grid-template-rows: var(--hd-h) 1fr var(--ft-h);
  grid-template-areas:
    "logo header"
    "sidebar main"
    "sidebar footer";
  height: 100vh;
}

/* ---------- Header ---------- */
.header {
  grid-area: header; grid-column: 1 / -1;
  display: flex; align-items: center; gap: 18px;
  height: var(--hd-h); padding: 0 18px;
  background: rgba(13,24,41,.72); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
  position: relative; z-index: 30;
}
.logo { display: flex; align-items: center; gap: 9px; width: calc(var(--sb-w) - 18px); flex-shrink: 0; }
.logo-mark-light, .rq-word-light { display: none; }
[data-theme="light"] .logo-mark-dark, [data-theme="light"] .rq-word-dark { display: none; }
[data-theme="light"] .logo-mark-light, [data-theme="light"] .rq-word-light { display: inline; }

.breadcrumb { display: flex; align-items: center; gap: 7px; font-size: 13.5px; color: var(--muted); flex: 1; min-width: 0; }
.breadcrumb .crumb { color: var(--text2); white-space: nowrap; }
.breadcrumb .crumb.current { color: var(--text); font-weight: 600; }
.breadcrumb .sep { opacity: .5; }

/* flex-shrink:0 -> la zone droite (LucIA, notifications, quota, forfait, avatar)
   ne se fait plus écraser par le fil d'Ariane sur écran étroit : la cloche de
   notifications restait invisible sur les petits écrans. */
.hd-right { display: flex; align-items: center; gap: 12px; flex-shrink: 0; margin-left: auto; }
.breadcrumb { overflow: hidden; }
@media (max-width: 1180px) { .lucia-word { display: none; } .hd-right { gap: 9px; } }
@media (max-width: 1024px) { .breadcrumb { display: none; } }

/* Toggle Express / Expert */
.mode-seg { display: inline-flex; background: var(--bg3); border: 1px solid var(--line); border-radius: 8px; padding: 2px; }
.mode-opt { font-size: 12.5px; font-weight: 600; color: var(--muted); padding: 5px 11px; border-radius: 6px; transition: .15s; }
.mode-opt.is-on { background: var(--panel); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.3); }

/* Jauge de quota */
.quota { display: flex; align-items: center; gap: 8px; padding: 6px 11px; border: 1px solid var(--line); border-radius: 9px; background: var(--bg2); transition: .15s; }
.quota:hover { border-color: var(--line2); }
.quota-label { font-size: 12px; color: var(--muted); font-weight: 600; }
.quota-bar { width: 56px; height: 6px; border-radius: 4px; background: var(--bg3); overflow: hidden; }
.quota-fill { display: block; height: 100%; background: linear-gradient(90deg, var(--green2), var(--green)); border-radius: 4px; }
.quota-count { font-size: 12px; font-variant-numeric: tabular-nums; color: var(--text2); font-weight: 600; }
.quota.is-high .quota-fill { background: var(--amber); }
.quota.is-full .quota-fill { background: var(--red); }

.hd-icon { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--line); background: var(--bg2); font-size: 15px; transition: .15s; }
.hd-icon:hover { border-color: var(--line2); }
/* Bouton menu mobile : masqué sur desktop, révélé ≤900px (voir plus bas). */
.hd-burger { display: none; width: 36px; height: 36px; border-radius: 9px; border: 1px solid var(--line); background: var(--bg2); color: var(--text); font-size: 19px; line-height: 1; cursor: pointer; place-items: center; margin-right: 4px; flex-shrink: 0; }
.hd-burger:hover { border-color: var(--line2); }
/* Voile derrière le tiroir de navigation (mobile) — masqué par défaut. */
.nav-scrim { display: none; position: fixed; inset: var(--hd-h) 0 0 0; background: rgba(4,10,18,.5); z-index: 39; opacity: 0; transition: opacity .2s; }
.avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--green-dim); color: var(--green); font-weight: 700; font-size: 12.5px; border: 1px solid var(--green-dim); }

/* ---------- Popovers ---------- */
.popover { position: absolute; background: var(--panel); border: 1px solid var(--line2); border-radius: var(--r-lg); box-shadow: var(--shadow); padding: 7px; min-width: 248px; z-index: 50; }
.popover[hidden] { display: none; }
.profile-menu, .quota-menu, .notif-menu { top: calc(var(--hd-h) - 6px); right: 14px; }
.pm-who { display: flex; align-items: center; gap: 10px; padding: 9px 10px 11px; border-bottom: 1px solid var(--line); margin-bottom: 6px; }
.pm-name { font-weight: 600; font-size: 14px; }
.pm-mail { font-size: 12px; color: var(--muted); }
.pm-item { width: 100%; display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 8px; font-size: 13.5px; color: var(--text2); text-align: left; }
.pm-item:hover { background: var(--bg3); color: var(--text); }
.pm-item .ic { width: 18px; text-align: center; }
.pm-item.danger { color: var(--red); }
.pm-tag { margin-left: auto; font-size: 9.5px; font-weight: 700; letter-spacing: .04em; color: var(--amber); }
.pm-div { height: 1px; background: var(--line); margin: 6px 4px; }
.quota-menu .qm-row { display: flex; align-items: center; justify-content: space-between; padding: 9px 10px; font-size: 13px; }
.quota-menu .qm-row + .qm-row { border-top: 1px solid var(--line); }
.quota-menu .qm-sub { font-size: 11.5px; color: var(--muted); }

/* ---------- Sidebar ---------- */
.sidebar { grid-area: sidebar; background: var(--bg2); border-right: 1px solid var(--line); display: flex; flex-direction: column; padding: 12px 12px 0; overflow: hidden; }

/* Switcher boutique (style Stripe) */
.boutique-switcher { position: relative; margin-bottom: 14px; }
.bs-trigger { width: 100%; display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: var(--r); border: 1px solid var(--line); background: var(--bg3); transition: .15s; }
.bs-trigger:hover { border-color: var(--line2); }
.bs-avatar { width: 28px; height: 28px; border-radius: 7px; display: grid; place-items: center; background: var(--green-dim); color: var(--green); font-weight: 700; font-size: 11px; flex-shrink: 0; }
.bs-name { font-weight: 600; font-size: 13.5px; flex: 1; text-align: left; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bs-chevron { color: var(--muted); font-size: 11px; }
.bs-menu { top: calc(100% + 6px); left: 0; right: 0; min-width: 0; }
.bs-opt { width: 100%; display: flex; align-items: center; gap: 10px; padding: 8px 9px; border-radius: 8px; text-align: left; }
.bs-opt:hover { background: var(--bg3); }
.bs-opt.is-on { background: var(--green-dim); }
.bs-opt .bs-avatar { width: 24px; height: 24px; font-size: 10px; }
.bs-opt .nm { font-size: 13px; font-weight: 500; }
.bs-opt .dm { font-size: 11px; color: var(--muted); }
.bs-add { width: 100%; display: flex; align-items: center; gap: 8px; padding: 9px; margin-top: 4px; border-top: 1px solid var(--line); border-radius: 0 0 8px 8px; color: var(--green); font-size: 13px; font-weight: 600; }
.bs-add:hover { background: var(--green-dim); }

/* Navigation fonctionnelle */
/* padding-top : le conteneur défile (overflow-y), sans cet espace l'ombre et le
   bord supérieur du bouton Diagnostic étaient coupés net. */
.sb-nav { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 2px; padding-top: 6px; }
.sb-group-label { font-size: 10.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); padding: 14px 10px 6px; }
.sb-link { display: flex; align-items: center; gap: 11px; padding: 9px 10px; border-radius: 8px; color: var(--text2); font-size: 14px; font-weight: 500; transition: .12s; }
.sb-link:hover { background: var(--bg3); color: var(--text); }
.sb-link.is-active { background: var(--green-dim); color: var(--green); font-weight: 600; }
.sb-link .ic { width: 19px; text-align: center; font-size: 15px; flex-shrink: 0; }
.sb-link .badge { margin-left: auto; font-size: 10.5px; font-weight: 700; background: var(--bg3); color: var(--text2); padding: 1px 7px; border-radius: 20px; }
.sb-link.is-active .badge { background: var(--green); color: #04221b; }

.sb-foot { border-top: 1px solid var(--line); padding: 12px 4px; }
.sb-sector { font-size: 11.5px; color: var(--muted); display: flex; align-items: center; gap: 7px; }
.sb-sector .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); }

/* ---------- Main ---------- */
.main { grid-area: main; overflow-y: auto; padding: 26px 30px; outline: none; }
.page-head { margin-bottom: 22px; }
.page-eyebrow { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--green); margin-bottom: 7px; }
.page-title { font-family: var(--font-display); font-size: 26px; font-weight: 700; letter-spacing: -.01em; }
.page-sub { color: var(--muted); margin-top: 6px; font-size: 14.5px; max-width: 62ch; }

/* Composants génériques de contenu */
.grid { display: grid; gap: 16px; }
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px; }
.card h3 { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.card .hint { font-size: 12.5px; color: var(--muted); }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px; }
.stat .k { font-size: 12px; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .05em; }
.stat .v { font-family: var(--font-display); font-size: 32px; font-weight: 700; margin-top: 6px; }
.stat .d { font-size: 12.5px; margin-top: 4px; color: var(--muted); }
.stat .v.good { color: var(--green); } .stat .v.warn { color: var(--amber); } .stat .v.bad { color: var(--red); }

.tbl { width: 100%; border-collapse: collapse; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; }
.tbl th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; padding: 12px 16px; border-bottom: 1px solid var(--line); }
.tbl td { padding: 13px 16px; font-size: 14px; border-bottom: 1px solid var(--line); }
.tbl tr:last-child td { border-bottom: none; }
.tbl tr:hover td { background: var(--bg3); }

.chip { display: inline-flex; align-items: center; gap: 5px; font-size: 11.5px; font-weight: 600; padding: 3px 9px; border-radius: 20px; }
.chip.ok { background: var(--green-dim); color: var(--green); }
.chip.warn { background: rgba(245,166,35,.14); color: var(--amber); }
.chip.bad { background: rgba(255,93,93,.14); color: var(--red); }
.chip.neutral { background: var(--bg3); color: var(--text2); }

.empty { text-align: center; padding: 60px 20px; color: var(--muted); }
.empty .em-ic { font-size: 34px; margin-bottom: 12px; opacity: .7; }

/* Boutons */
.btn { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 13.5px; padding: 9px 16px; border-radius: 9px; transition: .15s; border: 1px solid transparent; }
.btn.primary { background: var(--green); color: #04221b; }
.btn.primary:hover { background: var(--green2); }
.btn.ghost { border-color: var(--line2); color: var(--text2); }
.btn.ghost:hover { background: var(--bg3); color: var(--text); }

/* ---------- Footer contextuel ---------- */
.footer { grid-area: footer; display: flex; align-items: center; justify-content: space-between; gap: 14px; height: var(--ft-h); padding: 0 30px; background: rgba(13,24,41,.72); backdrop-filter: blur(10px); border-top: 1px solid var(--line); }
.footer .ft-info { font-size: 12.5px; color: var(--muted); }
.footer .ft-actions { display: flex; gap: 10px; }

/* ---------- Modale & toast ---------- */
.overlay { position: fixed; inset: 0; background: rgba(4,9,18,.62); display: grid; place-items: center; z-index: 100; }
.overlay[hidden] { display: none; }
/* (La définition .modal effective est plus bas, section « Administration ».) */
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); background: var(--panel); border: 1px solid var(--line2); border-radius: 10px; padding: 12px 18px; font-size: 13.5px; box-shadow: var(--shadow); z-index: 120; }
.toast[hidden] { display: none; }

/* ---------- Mode Expert : densité accrue ---------- */
[data-uimode="expert"] .page-sub { display: none; }
[data-uimode="expert"] .main { padding: 18px 24px; }

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
  .app { grid-template-columns: 1fr; grid-template-areas: "header" "main" "footer"; }
  .logo { width: auto; }
  .hd-burger { display: grid; }
  .sidebar { position: fixed; inset: var(--hd-h) auto 0 0; width: var(--sb-w); transform: translateX(-100%); transition: .2s; z-index: 40; box-shadow: 0 0 40px rgba(0,0,0,.35); }
  .app.nav-open .sidebar { transform: none; }
  .app.nav-open .nav-scrim { display: block; opacity: 1; }
  .grid.cols-3, .grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* ---------- Liste de tâches (priorisée, pas un kanban) ---------- */
.tasklist { display: flex; flex-direction: column; gap: 12px; }
.task { display: flex; align-items: center; gap: 16px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px 18px; }
.task:hover { border-color: var(--line2); }
.task-main { flex: 1; min-width: 0; }
.task-title { font-weight: 600; font-size: 14.5px; margin-bottom: 5px; }
.task-why { font-size: 12.5px; color: var(--muted); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.task-side { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }

/* ---------- Panneau assistant (drawer droit) ---------- */
.assistant {
  position: fixed; top: var(--hd-h); right: 0; bottom: 0; width: 372px; max-width: 92vw;
  background: var(--panel); border-left: 1px solid var(--line2); box-shadow: -10px 0 40px rgba(0,0,0,.3);
  display: flex; flex-direction: column; transform: translateX(100%); transition: transform .22s ease; z-index: 60;
}
.assistant.is-open { transform: none; }
/* Les deux tiroirs (assistant + tâches) se superposent au contenu : pas de reflow */
.hd-icon.is-on { background: var(--green-dim); border-color: var(--green-dim); color: var(--green); }
.as-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.as-title { font-weight: 600; font-size: 14px; }
.as-close { width: 28px; height: 28px; border-radius: 7px; color: var(--muted); font-size: 14px; }
.as-close:hover { background: var(--bg3); color: var(--text); }
.as-log { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.as-msg { font-size: 13.5px; line-height: 1.55; padding: 11px 13px; border-radius: 12px; max-width: 88%; }
.as-msg.bot { background: var(--bg3); color: var(--text2); align-self: flex-start; border-bottom-left-radius: 4px; }
.as-msg.user { background: var(--green-dim); color: var(--text); align-self: flex-end; border-bottom-right-radius: 4px; }
.as-input { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); }
.as-input input { flex: 1; background: var(--bg); border: 1px solid var(--line2); border-radius: 9px; padding: 10px 12px; font-size: 13.5px; }
.as-input input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px var(--green-dim); }
.as-input .btn { padding: 9px 14px; }
.as-foot { padding: 9px 14px 12px; font-size: 10.5px; color: var(--muted); text-align: center; border-top: 1px solid var(--line); }

@media (max-width: 880px) {
  .app.assistant-open .main, .app.assistant-open .footer { margin-right: 0; }
  .assistant { width: 100vw; max-width: 100vw; }
}

/* ---------- Diagnostic — bouton sidebar mis en avant ---------- */
.diag-cta { display: flex; align-items: center; gap: 11px; margin: 4px 8px 14px 8px; padding: 12px 14px; flex-shrink: 0; border-radius: 12px; background: var(--gold-grad); color: var(--gold-ink); font-weight: 700; border: none; box-shadow: 0 5px 16px rgba(214,176,74,.30), inset 0 1px 0 rgba(255,255,255,.28); transition: .15s; }
.diag-cta:hover { background: var(--gold2); transform: translateY(-1px); box-shadow: 0 8px 20px rgba(214,176,74,.40), inset 0 1px 0 rgba(255,255,255,.30); }
.diag-cta.is-active { box-shadow: 0 5px 16px rgba(214,176,74,.30), 0 0 0 2px rgba(214,176,74,.9), inset 0 1px 0 rgba(255,255,255,.28); }
.diag-cta .ic { font-size: 18px; display: flex; }
.diag-cta .ic svg { width: 19px; height: 19px; }
.diag-cta .tx { line-height: 1.15; }
.diag-cta .tx small { display: block; font-size: 11px; font-weight: 500; opacity: .82; }

/* ---------- Stepper ---------- */
.stepper { max-width: 780px; }
.step-dots { display: flex; margin-bottom: 26px; }
.step-dot { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 7px; position: relative; }
.step-dot .line { position: absolute; top: 16px; left: 50%; width: 100%; height: 2px; background: var(--line); z-index: 0; }
.step-dot.done .line { background: var(--green); }
.step-dot:last-child .line { display: none; }
.step-dot .circle { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--bg3); border: 1px solid var(--line2); font-size: 13px; font-weight: 700; color: var(--muted); position: relative; z-index: 1; }
.step-dot.done .circle { background: var(--green); color: #04221b; border-color: var(--green); }
.step-dot.current .circle { border-color: var(--green); color: var(--green); }
.step-dot .lbl { font-size: 11.5px; color: var(--muted); text-align: center; max-width: 120px; }
.step-dot.current .lbl { color: var(--text); font-weight: 600; }

.step-panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 24px; }
.step-panel .sp-head { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.step-panel h2 { font-family: var(--font-display); font-size: 20px; }
.step-panel .sp-sub { color: var(--muted); font-size: 14px; margin-bottom: 18px; }
.step-badge { font-size: 10.5px; font-weight: 700; padding: 2px 9px; border-radius: 20px; }
.step-badge.free { background: var(--gold-dim); color: var(--gold2); }
.step-badge.paid { background: rgba(245,166,35,.14); color: var(--amber); }

.diag-field { display: flex; gap: 10px; margin: 6px 0 4px; }
.diag-field input { flex: 1; background: var(--bg); border: 1px solid var(--line2); border-radius: 9px; padding: 11px 13px; font-size: 14px; }
.diag-field input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px var(--green-dim); }
.diag-opt { display: flex; align-items: center; gap: 9px; padding: 8px 0; font-size: 13.5px; color: var(--text2); }
.diag-q { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 9px; margin-bottom: 7px; font-size: 13.5px; }
.diag-q.locked { opacity: .5; }
.diag-q .qmark { color: var(--green); }

.step-actions { display: flex; justify-content: space-between; gap: 12px; margin-top: 22px; }

.diag-gauge { display: flex; align-items: center; gap: 18px; margin: 8px 0 16px; }
.diag-gauge .val { font-family: var(--font-display); font-size: 44px; font-weight: 800; line-height: 1; }
.diag-gauge .val.good { color: var(--green); } .diag-gauge .val.warn { color: var(--amber); } .diag-gauge .val.bad { color: var(--red); }
.diag-gauge .leg { font-size: 13px; color: var(--muted); }
.diag-result { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); }

.step-lock { text-align: center; padding: 36px 20px; }
.step-lock .lk { font-size: 34px; margin-bottom: 12px; }
.step-lock h3 { font-size: 17px; margin-bottom: 6px; }
.step-lock p { color: var(--muted); font-size: 13.5px; max-width: 46ch; margin: 0 auto 18px; }

/* ============ Diagnostic v2 — layout deux colonnes ============ */
.diag-top { text-align: center; }
.diag-top .page-head { margin-bottom: 22px; }
.diag-top .page-sub { margin-left: auto; margin-right: auto; }
.step-dot { cursor: pointer; }

.diag-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: stretch; }
.diag-pane { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 22px; display: flex; flex-direction: column; }
.diag-pane .sp-head { margin-bottom: 4px; }
.diag-col-title { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 14px; }
.diag-placeholder { display: grid; place-items: center; min-height: 240px; flex: 1; color: var(--muted); text-align: center; font-size: 13.5px; gap: 8px; }
.diag-placeholder .ic { font-size: 30px; opacity: .6; }

/* Boutons de connexion plateformes (logos à remplacer par les officiels) */
.connect-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 4px 0 8px; }
.connect-btn { display: flex; align-items: center; gap: 9px; padding: 11px 12px; border: 1px solid var(--line2); border-radius: 10px; background: var(--bg); font-size: 13.5px; font-weight: 600; transition: .15s; }
.connect-btn:hover { border-color: var(--green); background: var(--bg3); }
.connect-btn .mk { width: 24px; height: 24px; border-radius: 6px; display: grid; place-items: center; font-size: 13px; font-weight: 800; color: #fff; flex-shrink: 0; }

/* Questions (point d'interrogation à droite) */
.diag-q { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 9px; margin-bottom: 7px; font-size: 13.5px; }
.diag-q.locked { opacity: .55; }
.diag-q .qmark { color: var(--green); font-weight: 700; }
.diag-q.locked .qmark { color: var(--amber); }

/* Bloc llms.txt (vert, mis en avant) */
.llms-block { background: linear-gradient(135deg, var(--green-dim), transparent); border: 1px solid var(--green); border-radius: 12px; padding: 16px; margin-top: 16px; text-align: center; }
.llms-block .h { font-weight: 700; color: var(--green); margin-bottom: 11px; font-size: 14.5px; }
.llms-block .note { font-size: 10.5px; font-style: italic; color: var(--muted); margin-top: 9px; }

/* Pendant neutre du bloc llms.txt : même gabarit, sans l'accent vert.
   Le llms.txt reste le livrable GEO principal ; le schema.org le complète. */
.schema-block { background: transparent; border: 1px solid var(--line2); border-radius: 12px;
  padding: 16px; margin: 0; text-align: center; display: flex; flex-direction: column; justify-content: center; }
.schema-block .h { font-weight: 700; color: var(--text); margin-bottom: 11px; font-size: 14.5px; }
.schema-block .note { font-size: 10.5px; font-style: italic; color: var(--muted); margin-top: 9px; }

/* Bouton + bannière OR (upsell PRO) */
.btn.gold { background: var(--gold-grad); color: var(--gold-ink); box-shadow: 0 6px 18px rgba(224,160,32,.28); border: none; }
.btn.gold:hover { filter: brightness(1.06); }
.gold-banner { background: linear-gradient(135deg, rgba(245,196,81,.14), rgba(224,160,32,.05)); border: 1px solid rgba(224,160,32,.45); border-radius: 12px; padding: 18px; text-align: center; margin-top: 14px; }
.gold-banner .h { font-weight: 700; margin-bottom: 12px; font-size: 14px; }

/* Liste d'actions verrouillées (cadenas à droite) */
.lock-list .lrow { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 2px; border-bottom: 1px solid var(--line); }
.lock-list .lrow:last-child { border-bottom: none; }
.lock-list .nm { font-size: 14px; font-weight: 600; }
.lock-list .ds { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.lock-list .lk { color: var(--amber); font-size: 16px; flex-shrink: 0; }

/* Dataviz (étape 2, colonne droite) */
.kpi-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.kpi { background: var(--bg3); border-radius: 10px; padding: 13px; }
.kpi .k { font-size: 10.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.kpi .v { font-family: var(--font-display); font-size: 26px; font-weight: 800; margin-top: 3px; }
.kpi .v.good { color: var(--green); } .kpi .v.warn { color: var(--amber); } .kpi .v.bad { color: var(--red); }
.bar-row { margin: 10px 0; }
.bar-row .bl { display: flex; justify-content: space-between; font-size: 12.5px; margin-bottom: 5px; color: var(--text2); }
.bar { height: 9px; border-radius: 5px; background: var(--bg3); overflow: hidden; }
.bar > span { display: block; height: 100%; border-radius: 5px; background: linear-gradient(90deg, var(--green2), var(--green)); width: 0; animation: barGrow 1s cubic-bezier(.2,.8,.2,1) forwards; }
.bar.warn > span { background: var(--amber); }
.bar.bad > span { background: var(--red); }
@keyframes barGrow { from { width: 0; } }

/* Nav stepper dans le footer */
.footer .ft-step { display: flex; align-items: center; gap: 10px; }

@media (max-width: 920px) { .diag-cols, .connect-grid, .kpi-row { grid-template-columns: 1fr; } }

/* ============ Retours UI (itération) ============ */
/* CTA toujours en #00BF93, y compris en light mode */
.btn.primary { background: #00BF93; color: #04221b; }
.btn.primary:hover { background: #03a884; }
.diag-cta { background: var(--gold-grad); }
.diag-cta:hover { filter: brightness(1.05); }

/* Barres empilées par moteur (cité / mentionné / absent) */
.sbar { display: flex; height: 16px; border-radius: 8px; overflow: hidden; background: var(--bg3); margin-top: 5px; }
.sbar > i { height: 100%; display: block; transition: width .8s cubic-bezier(.2,.8,.2,1); }
.sbar .cited { background: var(--green); } .sbar .ment { background: var(--amber); } .sbar .abs { background: #54637a; }
.sbar-row { margin: 12px 0; }
.sbar-row .bl { display: flex; justify-content: space-between; font-size: 12.5px; margin-bottom: 3px; }
.sbar-legend { display: flex; gap: 14px; font-size: 11.5px; color: var(--muted); margin-top: 12px; }
.sbar-legend span { display: flex; align-items: center; gap: 5px; }
.sbar-legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }

/* Boutons-action verrouillés (donnent envie de cliquer) */
.lockbtn-list { display: flex; flex-direction: column; gap: 9px; }
.lockbtn { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 15px; border: 1px solid var(--line2); border-radius: 10px; background: var(--bg); cursor: pointer; transition: .15s; text-align: left; width: 100%; }
.lockbtn:hover { border-color: var(--amber); background: var(--bg3); }
.lockbtn .nm { font-size: 14px; font-weight: 600; }
.lockbtn .ds { font-size: 12px; color: var(--muted); margin-top: 2px; }
.lockbtn .lk { font-size: 16px; color: var(--amber); flex-shrink: 0; }

/* Panneau "ce que vous débloquez" (engageant) */
.unlock { background: linear-gradient(160deg, rgba(245,196,81,.16), rgba(224,160,32,.04)); border: 1px solid rgba(224,160,32,.45); border-radius: var(--r-lg); padding: 22px; display: flex; flex-direction: column; gap: 14px; }
.unlock .u-crown { font-size: 30px; }
.unlock h3 { font-size: 17px; }
.unlock .u-list { display: flex; flex-direction: column; gap: 9px; }
.unlock .u-item { display: flex; align-items: center; gap: 9px; font-size: 13.5px; }
.unlock .u-item .ck { color: var(--green); font-weight: 800; }
.unlock .u-price { font-size: 13px; color: var(--muted); }
.unlock .u-price strong { color: var(--text); font-size: 20px; font-family: var(--font-display); }

/* Podium Radar */
.podium { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; align-items: end; margin: 6px 0 20px; }
.pod { background: var(--panel); border: 1px solid var(--line); border-radius: 12px 12px 0 0; padding: 16px 12px; text-align: center; }
.pod .rk { font-family: var(--font-display); font-size: 26px; font-weight: 800; }
.pod .nm { font-size: 13px; font-weight: 600; margin: 6px 0 4px; }
.pod .sc { font-size: 11.5px; color: var(--muted); }
.pod.p1 { border-color: var(--green); box-shadow: 0 -3px 0 var(--green) inset; padding-top: 28px; }
.pod.p1 .rk { color: var(--green); } .pod.p2 .rk { color: var(--text2); } .pod.p3 .rk { color: var(--amber); }

/* Donut SVG (Accueil) */
.donut-wrap { display: flex; align-items: center; gap: 18px; }
.donut { width: 108px; height: 108px; flex-shrink: 0; }
.donut .track { fill: none; stroke: var(--bg3); stroke-width: 12; }
.donut .arc { fill: none; stroke: var(--green); stroke-width: 12; stroke-linecap: round; transform: rotate(-90deg); transform-origin: 50% 50%; transition: stroke-dasharray 1s ease; }
.donut-center { font-family: var(--font-display); font-size: 22px; font-weight: 800; }

/* Réglages boutique — contrôles réels */
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.set-row:last-child { border-bottom: none; }
.set-row .lab { font-size: 14px; font-weight: 600; } .set-row .hint { font-size: 12px; color: var(--muted); margin-top: 2px; }
.set-input { background: var(--bg); border: 1px solid var(--line2); border-radius: 8px; padding: 8px 11px; font-size: 13px; min-width: 200px; }
.chips-edit { display: flex; flex-wrap: wrap; gap: 6px; }
.chip-x { background: var(--bg3); border: 1px solid var(--line2); border-radius: 16px; padding: 4px 10px; font-size: 12px; display: flex; align-items: center; gap: 6px; }
.toggle { width: 40px; height: 22px; border-radius: 12px; background: var(--bg3); position: relative; cursor: pointer; border: 1px solid var(--line2); }
.toggle.on { background: var(--green); }
.toggle::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: .15s; }
.toggle.on::after { left: 20px; }

/* Tiroir générique (Tâches) + badge header */
.drawer { position: fixed; top: var(--hd-h); right: 0; bottom: 0; width: 372px; max-width: 92vw; background: var(--panel); border-left: 1px solid var(--line2); box-shadow: -10px 0 40px rgba(0,0,0,.3); display: flex; flex-direction: column; transform: translateX(100%); transition: transform .22s ease; z-index: 60; }
.drawer.is-open { transform: none; }
.hd-badge-wrap { position: relative; }
.hd-badge { position: absolute; top: -2px; right: -2px; background: var(--green); color: #04221b; font-size: 9.5px; font-weight: 800; min-width: 15px; height: 15px; border-radius: 8px; display: grid; place-items: center; padding: 0 3px; }
.task-drawer-head { padding: 15px 16px; border-bottom: 1px solid var(--line); }
.task-drawer-head .h { font-weight: 600; font-size: 14px; }
.task-drawer-head .s { font-size: 12px; color: var(--muted); margin-top: 3px; }

/* Administration */
.overlay { position: fixed; inset: 0; background: rgba(0,0,0,.55); display: grid; place-items: center; z-index: 100; padding: 24px; overflow-y: auto; }
.overlay[hidden] { display: none; }
/* Largeur ADAPTATIVE (pas figée) : le contenu peut demander plus que 420px
   sans déborder. Hauteur plafonnée + défilement interne pour les formulaires
   longs (ex. « Nouveau produit ») qui dépassaient de l'écran. */
.modal {
  background: var(--panel); border: 1px solid var(--line2); border-radius: var(--r-lg);
  padding: 22px; box-shadow: 0 20px 60px rgba(0,0,0,.4);
  width: auto; min-width: min(420px, 90vw); max-width: min(620px, 92vw);
  max-height: calc(100vh - 48px); overflow-y: auto; overscroll-behavior: contain;
}
.modal > * { max-width: 100%; }
.modal h3 { font-size: 17px; font-family: var(--font-display); }
.warn-banner { background: rgba(245,166,35,.12); border: 1px solid rgba(245,166,35,.4); color: var(--amber); border-radius: 10px; padding: 12px 14px; font-size: 13px; margin-bottom: 16px; }
.th-search { display: flex; align-items: center; gap: 5px; font-size: 11px; color: var(--muted); font-weight: 400; }
.th-search input { width: 100%; background: var(--bg); border: 1px solid var(--line); border-radius: 6px; padding: 4px 7px; font-size: 12px; }
.search-row th { padding-top: 4px; padding-bottom: 8px; }
.admin-actions { white-space: nowrap; }
.admin-actions .btn { padding: 5px 8px; }

/* ===== Retours UI (itération) ===== */
/* Tâches dans le tiroir : carte en colonne -> le titre prend toute la largeur */
#tasksBody .task { flex-direction: column; align-items: stretch; gap: 10px; }
#tasksBody .task-side { justify-content: space-between; }
#tasksBody .task-title { overflow-wrap: anywhere; }

/* Scrollbars redessinées (sidebar, contenu, tiroirs) */
.sb-nav, .main, .as-log, .drawer .as-log {
  scrollbar-width: thin; scrollbar-color: var(--line2) transparent;
}
.sb-nav::-webkit-scrollbar, .main::-webkit-scrollbar, .as-log::-webkit-scrollbar { width: 8px; height: 8px; }
.sb-nav::-webkit-scrollbar-track, .main::-webkit-scrollbar-track, .as-log::-webkit-scrollbar-track { background: transparent; }
.sb-nav::-webkit-scrollbar-thumb, .main::-webkit-scrollbar-thumb, .as-log::-webkit-scrollbar-thumb {
  background: var(--line2); border-radius: 99px; border: 2px solid transparent; background-clip: content-box;
}
.sb-nav::-webkit-scrollbar-thumb:hover, .main::-webkit-scrollbar-thumb:hover { background: var(--muted); background-clip: content-box; }

/* Articles — boucle Radar -> génération -> verrouillage -> publication */
.art-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.art-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px; }
.art-card .src { font-size: 11px; color: var(--green); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.art-card h4 { font-size: 15px; margin: 6px 0 4px; }
.art-prompt { display: flex; gap: 8px; margin: 4px 0 18px; }
.art-prompt input { flex: 1; background: var(--bg); border: 1px solid var(--line2); border-radius: 9px; padding: 11px 13px; font-size: 13.5px; }
.lock-para { border-left: 3px solid var(--line2); padding: 8px 12px; margin: 8px 0; font-size: 13px; position: relative; border-radius: 0 8px 8px 0; }
.lock-para.locked { border-left-color: var(--green); background: rgba(0,191,147,.06); }
.lock-para .pin { float: right; cursor: pointer; font-size: 13px; opacity: .8; }
.lock-para.locked .pin { opacity: 1; }

/* Message d'authentification (page connexion) */
.auth-msg { margin: 2px 0 12px; padding: 9px 12px; border-radius: 8px; font-size: 13px; background: rgba(229,90,90,.12); border: 1px solid rgba(229,90,90,.4); color: #ff9a9a; }
.auth-msg.is-ok { background: rgba(0,191,147,.12); border-color: rgba(0,191,147,.4); color: var(--green); }

/* Écran de chargement au démarrage (vérification de session) */
#bootLoad { position: fixed; inset: 0; display: grid; place-items: center; background: var(--bg); z-index: 9999; }
.boot-spin { width: 30px; height: 30px; border-radius: 50%; border: 3px solid var(--line2); border-top-color: var(--green); margin: 0 auto; animation: bootspin .8s linear infinite; }
@keyframes bootspin { to { transform: rotate(360deg); } }

/* Roue de chargement inline (boutons en cours de traitement) */
.spin-inline { display: inline-block; width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(4,34,27,.35); border-top-color: #04221b; vertical-align: -2px; margin-right: 6px; animation: bootspin .7s linear infinite; }

/* Barre de progression de la mesure (étape 2) */
.mprogress { width: 100%; max-width: 280px; height: 8px; border-radius: 6px; background: rgba(255,255,255,.08); overflow: hidden; margin-inline: auto; }
.mprogress > i { display: block; height: 100%; background: var(--green); border-radius: 6px; transition: width .4s ease; }
body.light .mprogress { background: rgba(13,24,41,.10); }
/* Puces de sources citées */
.src-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.src-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; background: rgba(255,255,255,.06); border: 1px solid var(--line); font-size: 12.5px; }
.src-chip small { color: var(--muted); font-size: 10.5px; text-transform: uppercase; letter-spacing: .03em; }
body.light .src-chip { background: rgba(13,24,41,.04); }

/* Cases à cocher des moteurs (Configuration super-admin) */
.engine-checks { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin-top: 6px; }
.echk { display: flex; align-items: center; gap: 8px; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; background: rgba(255,255,255,.03); }
.echk:hover { border-color: var(--green); }
.echk input { accent-color: var(--green); width: 16px; height: 16px; }
.echk .enm { font-weight: 600; font-size: 13.5px; }
.echk small { margin-left: auto; font-size: 10.5px; text-transform: uppercase; letter-spacing: .03em; color: var(--muted); }
.echk small.lg { color: var(--amber); }
body.light .echk { background: rgba(13,24,41,.03); }
@media (max-width: 640px) { .engine-checks { grid-template-columns: 1fr; } }

/* Note de génération des questions (étape 2) */
.qgen-note { margin-top: 8px; font-size: 12px; color: var(--muted); background: rgba(0,191,147,.08); border: 1px solid rgba(0,191,147,.25); border-radius: 8px; padding: 7px 10px; }
.qgen-note.warn { background: rgba(214,176,74,.10); border-color: rgba(214,176,74,.30); color: var(--amber); }

/* ---------- Bouton forfait (header) ---------- */
.planbtn { display: inline-flex; align-items: center; gap: 7px; height: 34px; padding: 0 14px; border-radius: 9px; border: none; color: var(--gold-ink); background: var(--gold-grad); box-shadow: 0 5px 16px rgba(214,176,74,.32); font-size: 13px; font-weight: 700; cursor: pointer; white-space: nowrap; }
.planbtn:hover { filter: brightness(1.05); }
.planbtn .pb-spark { font-size: 12px; }

/* ---------- Modale forfaits ---------- */
#modal.modal-wide { max-width: 1340px; width: calc(100vw - 48px); }
#modal.modal-med { max-width: min(860px, 94vw); }
.plan-modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.plan-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; }
.plan-card { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 14px; padding: 18px 16px; background: var(--bg2, rgba(255,255,255,.02)); }
.plan-card.is-current { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold); }
.plan-card.is-best { border-color: var(--gold); position: relative; }
.plan-best { position: absolute; top: -10px; left: 16px; background: var(--gold); color: var(--gold-ink); font-size: 10px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; padding: 3px 9px; border-radius: 999px; }
.plan-tag { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.plan-name { font-family: var(--display, inherit); font-size: 1.5rem; font-weight: 800; margin: 2px 0 6px; }
.plan-price { font-size: 1.7rem; font-weight: 800; margin-bottom: 12px; }
.plan-price small { font-size: .8rem; font-weight: 600; color: var(--muted); margin-left: 3px; }
.plan-feats { list-style: none; padding: 0; margin: 0 0 16px; display: flex; flex-direction: column; gap: 7px; flex: 1; }
.plan-feats li { position: relative; padding-left: 20px; font-size: 12.5px; color: var(--text2, var(--muted)); }
.plan-feats li::before { content: "✓"; position: absolute; left: 0; color: var(--green); font-weight: 700; }
.plan-card .btn { width: 100%; justify-content: center; }
@media (max-width: 1200px) { .plan-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 900px) { .plan-grid { grid-template-columns: repeat(2, 1fr); } #modal.modal-wide { width: calc(100vw - 24px); } }
@media (max-width: 520px) { .plan-grid { grid-template-columns: 1fr; } }

/* Bannière d'upgrade pleine largeur (hors colonnes) + bouton pilule centré */
.gold-banner.upgrade-wide { margin-top: 18px; }
.btn.gold.upgrade-pill { display: inline-flex; width: auto; min-width: 240px; justify-content: center; padding: 15px 34px; margin: 4px auto 0; font-size: 14.5px; border-radius: 11px; }

/* ---------- Timeline (Accueil CTA + frise) ---------- */
.tl-cta { display: flex; align-items: center; justify-content: space-between; gap: 16px; background: linear-gradient(135deg, rgba(0,191,147,.12), rgba(0,191,147,.03)); border: 1px solid rgba(0,191,147,.28); border-radius: 14px; padding: 16px 20px; margin-bottom: 18px; text-decoration: none; color: var(--text); transition: .15s; }
.tl-cta:hover { border-color: var(--green); transform: translateY(-1px); }
.tl-cta-l { display: flex; align-items: center; gap: 14px; }
.tl-cta-ic { font-size: 26px; }
.tl-cta-h { font-weight: 700; font-size: 15px; }
.tl-cta-s { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.tl-cta-go { color: var(--green); font-weight: 700; font-size: 13.5px; white-space: nowrap; }

.tl-card { padding: 22px; }
.tl-track { position: relative; display: flex; gap: 8px; overflow-x: auto; padding: 6px 4px 14px; }
.tl-track::before { content: ""; position: absolute; left: 18px; right: 18px; top: 19px; height: 2px; background: var(--line2, var(--line)); }
.tl-ev { position: relative; z-index: 1; flex: 0 0 130px; display: flex; flex-direction: column; align-items: center; text-align: center; background: none; border: none; cursor: pointer; padding: 0; font-family: inherit; }
/* ---- Fiche produit : en-tête, onglets, contenu ---- */
.pf-head { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start;
  padding-bottom: 14px; border-bottom: 1px solid var(--line); margin-bottom: 0; }
.pf-back { font-size: 13px; color: var(--muted); text-decoration: none; }
.pf-back:hover { color: var(--green); }
.pf-title { font-family: var(--font-display); font-size: 21px; font-weight: 700; margin: 4px 0 2px; }
.pf-meta { font-size: 12.5px; color: var(--muted); }
.pf-head-r { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; flex-shrink: 0; }
.pf-img { width: 64px; height: 64px; border-radius: 10px; object-fit: cover;
  background: var(--bg); border: 1px solid var(--line); }
.pf-img.is-vide { display: flex; align-items: center; justify-content: center; color: var(--muted); font-size: 22px; }
.pf-tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.pf-tab { background: none; border: 0; border-bottom: 2px solid transparent; cursor: pointer;
  font-size: 14px; color: var(--muted); padding: 11px 14px; display: flex; align-items: center; gap: 7px; }
.pf-tab:hover { color: var(--text2); }
.pf-tab.is-active { color: var(--text); border-bottom-color: var(--green); }
.pf-dot { width: 7px; height: 7px; border-radius: 50%; background: #e0734f; display: inline-block; }
.pf-vue { display: grid; grid-template-columns: 220px 1fr; gap: 22px; align-items: start; margin-bottom: 8px; }
.pf-score { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.pf-score-t { font-size: 13px; color: var(--text2); line-height: 1.5; }
.pf-axes { display: grid; gap: 11px; }
.pf-axe-h { display: flex; justify-content: space-between; font-size: 12.5px; font-weight: 600; margin-bottom: 4px; }
.pf-axe-d { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.pf-h3 { margin: 22px 0 10px; font-size: 15px; }
.pf-act { display: flex; align-items: center; gap: 13px; width: 100%; text-align: left;
  padding: 13px 15px; margin-bottom: 9px; border: 1px solid var(--line2); border-radius: 11px;
  background: var(--panel); cursor: pointer; transition: .15s; }
.pf-act:hover { border-color: var(--green); background: rgba(0,191,147,.05); }
.pf-act-i { font-size: 17px; flex-shrink: 0; opacity: .8; }
.pf-act-b { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.pf-act-t { font-size: 14px; font-weight: 600; color: var(--text); }
.pf-act-q { font-size: 12.5px; color: var(--muted); }
.pf-act-g { font-size: 17px; font-weight: 700; color: var(--green); flex-shrink: 0; }
@media (max-width: 820px) { .pf-vue { grid-template-columns: 1fr; } }

/* ---- Carte produit : image, étiquette, pastille de score ---- */
.pcard-img { width: 52px; height: 52px; border-radius: 9px; object-fit: cover; flex-shrink: 0;
  background: var(--bg); border: 1px solid var(--line); }
.pcard-img.is-vide { display: flex; align-items: center; justify-content: center;
  color: var(--muted); font-size: 20px; }
.pcard-score { flex-shrink: 0; display: flex; align-items: center; }
.score-badge { display: block; }
.pcard-title { font-size: 14.5px; font-weight: 600; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pcard-meta { font-size: 12px; color: var(--muted); margin: 2px 0 7px; }

/* ---- Barre du catalogue : recherche et filtres ---- */
.cat-bar { display: flex; gap: 12px; justify-content: space-between; align-items: center;
  flex-wrap: wrap; margin-bottom: 14px; }
.cat-search { display: flex; gap: 8px; flex: 1 1 320px; min-width: 0; }
.cat-search #catQ { flex: 1 1 auto; min-width: 0; }
.cat-search #catFiltre { flex: 0 0 auto; width: 190px; }
.cat-actions { display: flex; gap: 8px; flex-wrap: wrap; }
@media (max-width: 760px) { .cat-search { flex-basis: 100%; } .cat-search #catFiltre { width: 150px; } }

/* ---- Cadenas de verrouillage des blocs ----
   Le cadenas reflète l'ÉTAT du bloc, pas l'action : vert fermé = protégé,
   rouge ouvert = modifiable. La couleur se lit avant l'icône. */
.lock-btn { font-size: 15px; line-height: 1; padding: 6px 9px; }
.lock-btn.is-locked { color: var(--green, #00BF93); border-color: rgba(0,191,147,.45); background: rgba(0,191,147,.08); }
.lock-btn.is-locked:hover { background: rgba(0,191,147,.16); }
.lock-btn.is-open { color: #e0734f; border-color: rgba(224,115,79,.45); background: rgba(224,115,79,.07); }
.lock-btn.is-open:hover { background: rgba(224,115,79,.15); }

/* ---- Monitoring : score et actions ---- */
.mon-top { display: grid; grid-template-columns: 240px 1fr; gap: 20px; align-items: start; }
.mon-score { border: 1px solid var(--line2); border-radius: 14px; padding: 22px 18px; text-align: center; background: var(--panel); }
.mon-score.mon-ok { border-color: rgba(0,191,147,.45); }
.mon-score.mon-warn { border-color: rgba(230,194,90,.45); }
.mon-score.mon-bad { border-color: rgba(224,115,79,.45); }
.mon-val { font-family: var(--font-display); font-size: 52px; font-weight: 700; line-height: 1; color: var(--text); }
.mon-val span { font-size: 18px; color: var(--muted); font-weight: 400; }
.mon-lab { font-size: 13.5px; color: var(--text2); margin-top: 8px; font-weight: 600; }
.mon-gain { font-size: 12px; color: var(--green); margin-top: 10px; font-weight: 600; }
.mon-axes { display: grid; gap: 12px; }
.mon-axe-h { display: flex; justify-content: space-between; font-size: 12.5px; font-weight: 600; margin-bottom: 5px; }
.mon-axe-d { font-size: 11.5px; color: var(--muted); margin-top: 4px; }
.mon-act { display: flex; align-items: center; gap: 14px; padding: 14px 16px; margin-bottom: 10px;
  border: 1px solid var(--line2); border-radius: 12px; background: var(--panel);
  text-decoration: none; transition: .15s; }
.mon-act:hover { border-color: var(--green); background: rgba(0,191,147,.05); }
.mon-act-n { width: 28px; height: 28px; border-radius: 50%; background: var(--green-dim); color: var(--green);
  display: grid; place-items: center; font-weight: 700; font-size: 13px; flex-shrink: 0; }
.mon-act-b { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.mon-act-t { font-size: 14.5px; font-weight: 600; color: var(--text); }
.mon-act-q { font-size: 12.5px; color: var(--text2); }
.mon-act-p { font-size: 11.5px; color: var(--muted); font-style: italic; }
.mon-act-g { font-size: 19px; font-weight: 700; color: var(--green); flex-shrink: 0; }
.mon-act-g small { font-size: 10.5px; font-weight: 400; display: block; text-align: center; color: var(--muted); }
@media (max-width: 820px) { .mon-top { grid-template-columns: 1fr; } }

/* ---- Propositions de caractéristiques ---- */
.prop-box { margin-top: 12px; padding: 12px 14px; border: 1px solid var(--line2); border-radius: 10px; background: var(--bg); }
.prop-h { font-size: 12px; font-weight: 600; color: var(--text2); margin-bottom: 8px; }
.prop-row { padding: 7px 0; border-bottom: 1px solid var(--line); }
.prop-row:last-of-type { border-bottom: 0; }
.prop-row label { display: flex; align-items: center; gap: 8px; font-size: 13px; cursor: pointer; }
.prop-row b { font-weight: 600; }
.prop-src { font-size: 11px; color: var(--muted); font-style: italic; margin: 3px 0 0 24px; }

/* ---- Attributs produits en étiquettes ---- */
.attr-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 6px; min-height: 30px;
  padding: 8px; border: 1px solid var(--line2); border-radius: 9px; background: var(--bg); }
.attr-tag { display: inline-flex; align-items: center; gap: 4px; font-size: 12px;
  background: var(--green-dim); border: 1px solid var(--green); color: var(--text);
  padding: 4px 6px 4px 9px; border-radius: 999px; }
.attr-tag b { font-weight: 600; }
.attr-tag .x { background: none; border: 0; color: var(--muted); cursor: pointer;
  font-size: 14px; line-height: 1; padding: 0 3px; }
.attr-tag .x:hover { color: #e0734f; }
.attr-suggest { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 8px; }
.attr-chip { font-size: 11.5px; background: transparent; border: 1px dashed var(--line2);
  color: var(--muted); padding: 4px 9px; border-radius: 999px; cursor: pointer; transition: .15s; }
.attr-chip:hover { border-color: var(--green); color: var(--green); border-style: solid; }

/* ---- Plafonds négociés (fiche organisation, backoffice) ---- */
.lim-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px 14px; }
.lim-field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.lim-field span { font-size: 11.5px; color: var(--muted); font-weight: 600; }
.lim-field .set-input { width: 100%; text-align: left; box-sizing: border-box; }

/* ---- Zone dangereuse (suppression de compte) ---- */
.danger-zone { border-color: rgba(224,115,79,.4); background: rgba(224,115,79,.05); }
.btn.danger { background: #e0734f; color: #fff; border: none; font-weight: 600; }
.btn.danger:hover { filter: brightness(1.07); }

/* ---- Filtres du journal d'activité (backoffice) ---- */
.act-filters { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; }
.act-filters label { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.act-filters label span { font-size: 11.5px; color: var(--muted); font-weight: 600; }
.act-filters .set-input { width: 100%; }
@media (max-width: 700px) { .act-filters { grid-template-columns: 1fr 1fr; } }

/* ---- Bandeau Timeline en tête du Dashboard ----
   Pleine largeur, encadré : l'historique reste consultable d'un coup d'oeil
   sans occuper une entrée de menu permanente. */
.tl-strip { border: 1px solid var(--line2); border-radius: 12px; padding: 14px 16px; margin-bottom: 18px; background: var(--panel); }
.tl-strip-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.tl-strip-title { font-weight: 700; font-size: 14.5px; color: var(--text); }
.tl-strip-count { font-weight: 400; font-size: 11.5px; color: var(--muted); margin-left: 8px; }
.tl-strip-cta { color: #00BF93; font-weight: 700; font-size: 13px; text-decoration: none; white-space: nowrap;
  padding: 6px 12px; border: 1px solid rgba(0,191,147,.35); border-radius: 999px; transition: .15s; }
.tl-strip-cta:hover { background: rgba(0,191,147,.12); border-color: #00BF93; }
.tl-strip-row { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 2px; }
.tl-strip-ev { display: flex; align-items: center; gap: 9px; flex: 1 1 0; min-width: 170px;
  padding: 9px 11px; border: 1px solid var(--line); border-radius: 10px; text-decoration: none; transition: .15s; }
.tl-strip-ev:hover { border-color: #00BF93; background: rgba(0,191,147,.06); }
.tl-strip-txt { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.tl-strip-lab { font-size: 12.5px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tl-strip-date { font-size: 11px; color: var(--muted); }
.tl-strip-ev .tl-delta { margin-top: 0; margin-left: auto; }
.tl-strip-empty { font-size: 12.5px; color: var(--muted); padding: 4px 0 2px; }
@media (max-width: 900px) { .tl-strip-ev { min-width: 150px; } }

.tl-dot { width: 30px; height: 30px; border-radius: 50%; background: var(--panel); border: 2px solid #34465e; display: grid; place-items: center; font-size: 14px; transition: .15s; }
.tl-ev:hover .tl-dot { border-color: var(--c); }
.tl-ev.on .tl-dot { background: var(--c); border-color: var(--c); transform: scale(1.12); }
.tl-date { font-size: 11.5px; color: var(--muted); margin-top: 9px; font-weight: 700; }
.tl-lab { font-size: 12px; color: var(--text2, var(--text)); margin-top: 3px; line-height: 1.3; }
.tl-delta { display: inline-block; margin-top: 6px; font-size: 10.5px; font-weight: 700; padding: 2px 8px; border-radius: 999px; }
.tl-delta.up { background: rgba(0,191,147,.16); color: #37d3ab; }
.tl-delta.down { background: rgba(226,75,74,.16); color: #ff7a78; }
.tl-detail { margin-top: 18px; background: var(--bg2); border: 1px solid var(--line); border-radius: 13px; padding: 18px 20px; }
.tl-d-top { display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.tl-chip { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; padding: 3px 10px; border-radius: 999px; background: color-mix(in srgb, var(--c) 18%, transparent); color: var(--c); }
.tl-d-date { font-size: 12px; color: var(--muted); }
.tl-cmp { margin-top: 12px; font-size: 13.5px; color: var(--text2, var(--text)); background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px; }
.tl-cmp .up { color: #37d3ab; font-weight: 700; }
.tl-cmp .down { color: #ff7a78; font-weight: 700; }

/* ============ Diagnostic — aération (itération) ============ */
.diag-single { max-width: 860px; margin-left: auto; margin-right: auto; }
.diag-single .sp-sub, .step-panel .sp-sub { line-height: 1.6; }
.step-panel .diag-q { margin-bottom: 10px; padding: 11px 13px; line-height: 1.45; }
.step-panel .diag-col-title { margin-top: 18px; margin-bottom: 8px; }
.step-panel .diag-col-title:first-of-type { margin-top: 4px; }

/* ============ Diagnostic — tuiles d'actions (itération UX) ============ */
.diag-summary { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin: 0 0 18px; padding: 11px 14px; border: 1px solid var(--line2); border-radius: 10px; background: var(--bg2); font-size: 13px; font-weight: 500; }
.diag-summary i { width: 4px; height: 4px; border-radius: 50%; background: var(--muted); display: inline-block; }
.diag-grp-label { display: flex; align-items: center; gap: 7px; font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); margin: 18px 0 9px; }
.diag-grp-label:first-of-type { margin-top: 4px; }
.diag-grp-label .dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; }
.diag-grp-label .dot.bad { background: #e0734f; }
.diag-grp-label .dot.warn { background: #d6b04a; }
.diag-grp-label .dot.neutral { background: var(--muted); }
.diag-tile { display: flex; align-items: center; gap: 14px; padding: 13px 16px; border: 1px solid var(--line2); border-radius: 12px; margin-bottom: 10px; background: var(--panel); transition: border-color .15s, transform .15s; }
.diag-tile:hover { border-color: var(--green); }
.diag-tile-ic { width: 42px; height: 42px; border-radius: 10px; background: var(--green-dim); display: flex; align-items: center; justify-content: center; font-size: 20px; flex-shrink: 0; }
.diag-tile-body { flex: 1; min-width: 0; }
.diag-tile-title { font-weight: 600; font-size: 14.5px; }
.diag-tile-why { color: var(--muted); font-size: 13px; margin-top: 3px; line-height: 1.45; }
.diag-tile .btn { flex-shrink: 0; white-space: nowrap; }
.diag-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 6px; }
.diag-kpi { text-align: center; padding: 16px; border: 1px solid var(--line2); border-radius: 12px; background: var(--panel); }
.diag-kpi .v { font-size: 27px; font-weight: 700; line-height: 1; }
.diag-kpi .l { color: var(--muted); font-size: 12.5px; margin-top: 6px; }
.nav-new { background: var(--green); color: #04221b; font-size: 9px; font-weight: 800; padding: 2px 6px; border-radius: 999px; margin-left: 7px; letter-spacing: .03em; text-transform: uppercase; vertical-align: middle; }
@media (max-width: 720px) { .diag-kpis { grid-template-columns: 1fr; } }

/* Chip d'état "ok" discret pour les blocs de fiche */
.chip.okmuted { background: rgba(120,140,160,.14); color: var(--muted); }

/* ============ LucIA — cartes d'action dans le panneau ============ */
/* (La définition des cartes LucIA est unifiée plus bas — voir « Cartes LucIA ».) */
.lucia-ic { width: 34px; height: 34px; border-radius: 9px; background: var(--green-dim); display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; }

/* ============ Bouton LucIA (header, pilule dorée moderne) ============ */
.lucia-btn { display: inline-flex; align-items: center; gap: 7px; height: 34px; padding: 0 13px 0 8px; border-radius: 999px; border: 1.5px solid var(--gold, #d6b04a); background: transparent; cursor: pointer; transition: background .15s, box-shadow .15s; }
.lucia-btn:hover { background: var(--gold-dim, rgba(214,176,74,.14)); box-shadow: 0 0 0 3px rgba(214,176,74,.12); }
.lucia-btn.is-on { background: var(--gold-dim, rgba(214,176,74,.2)); box-shadow: 0 0 0 3px rgba(214,176,74,.16); }
.lucia-btn .lucia-ico { display: inline-flex; align-items: center; }
.lucia-word { font-family: 'Sora', system-ui, sans-serif; font-weight: 700; font-size: 13px; letter-spacing: .03em; background: var(--gold-grad, linear-gradient(135deg, #f5c451, #e0a020)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: var(--gold, #d6b04a); }

/* Bouton "Générer" : contour + typo dorés (consomme +1 fiche du quota mensuel) */
.btn.gold-outline { background: transparent; border: 1.5px solid #d6b04a; color: #d6b04a; font-weight: 600; box-shadow: none; }
.btn.gold-outline:hover { background: rgba(214,176,74,.14); }
.btn.gold-outline:disabled { opacity: .6; }
.btn.gold-outline .spin-inline { border-color: rgba(214,176,74,.35); border-top-color: #d6b04a; }

/* ============================================================
   REFONTE UI — Dashboard + moteur de graphiques (v72)
   ============================================================ */
:root { --bg3: rgba(150,170,195,.10); }
[data-theme="light"] { --bg3: #eef2f7; }

/* ---- Tooltip graphiques ---- */
.rqc-tip { position: fixed; z-index: 9999; pointer-events: none; background: #0b1622; color: #eaf3ff;
  border: 1px solid rgba(255,255,255,.14); border-radius: 8px; padding: 6px 9px; font-size: 12px;
  box-shadow: 0 6px 20px rgba(0,0,0,.35); display: flex; flex-direction: column; gap: 1px; max-width: 240px; }
.rqc-tip .rqc-tl { color: #b9c8db; }
.rqc-tip .rqc-tv { font-weight: 700; font-family: var(--mono, monospace); }
.rqc-seg:hover { opacity: .82; }
.rqc-dot { opacity: 0; transition: opacity .12s; cursor: pointer; }
svg:hover .rqc-dot, .rqc-dot:hover { opacity: 1; }

/* ---- Légende ---- */
.rqc-legend { display: flex; flex-wrap: wrap; gap: 12px; margin: 6px 0 4px; }
.rqc-lg { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); }
.rqc-lg i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.rqc-lg b { color: var(--text); font-family: var(--mono, monospace); }

/* ---- Barres empilées (par moteur) ---- */
.rqc-sbars { display: flex; flex-direction: column; gap: 11px; margin-top: 6px; }
.rqc-sbrow { display: flex; align-items: center; gap: 10px; }
.rqc-sbname { width: 92px; flex-shrink: 0; font-size: 13px; display: inline-flex; align-items: center; gap: 7px; }
.rqc-sbname i { width: 8px; height: 8px; border-radius: 50%; }
.rqc-sbtrack { flex: 1; height: 12px; border-radius: 7px; overflow: hidden; display: flex; background: var(--bg3); }
.rqc-sb { height: 100%; transition: opacity .15s; }
.rqc-sb:hover { opacity: .8; }
.rqc-sbval { width: 38px; text-align: right; font-size: 12.5px; font-family: var(--mono, monospace); color: var(--text); }

/* ---- Barres classées (concurrents) ---- */
.rqc-rank { display: flex; flex-direction: column; gap: 9px; margin-top: 4px; }
.rqc-rrow { display: flex; align-items: center; gap: 10px; padding: 3px 6px; border-radius: 8px; }
.rqc-rrow.me { background: var(--green-dim); }
.rqc-rn { font-family: var(--mono, monospace); font-size: 11px; color: var(--muted); width: 18px; }
.rqc-rname { flex: 1; font-size: 13px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rqc-me { background: var(--green); color: #04231a; font-size: 9.5px; padding: 1px 6px; border-radius: 20px; margin-left: 7px; vertical-align: 1px; }
.rqc-rtrack { width: 34%; height: 7px; border-radius: 5px; background: var(--bg3); overflow: hidden; }
.rqc-rfill { display: block; height: 100%; border-radius: 5px; }
.rqc-rval { width: 40px; text-align: right; font-size: 12.5px; font-family: var(--mono, monospace); color: var(--text); }

/* ---- Matrice prompts × moteurs ---- */
.rqc-matrix { margin-top: 6px; overflow-x: auto; }
.rqc-mrow { display: grid; grid-template-columns: 190px repeat(5, 1fr); gap: 7px; align-items: center; margin-bottom: 7px; }
.rqc-mhead .rqc-mc { font-size: 11.5px; color: var(--muted); text-align: center; }
.rqc-mp { font-size: 12.5px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rqc-mcell { display: flex; align-items: center; justify-content: center; height: 30px; border-radius: 7px; font-weight: 700; font-size: 13px; cursor: pointer; transition: transform .1s; }
.rqc-mcell:hover { transform: scale(1.04); }

/* ---- Nuage de thèmes ---- */
.rqc-cloud { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; justify-content: center; padding: 10px 4px; line-height: 1.5; }
.rqc-cloud span { cursor: default; transition: opacity .12s; }
.rqc-cloud span:hover { opacity: .7; }

/* ---- Dashboard : hero ---- */
.dash-hero { display: flex; gap: 20px; justify-content: space-between; align-items: center; flex-wrap: wrap;
  background: linear-gradient(135deg, var(--panel), var(--bg2, var(--panel))); border: 1px solid var(--line2, var(--line));
  border-radius: 16px; padding: 22px 24px; margin-bottom: 16px; }
[data-theme="dark"] .dash-hero { background: radial-gradient(120% 140% at 0% 0%, rgba(0,191,147,.10), transparent 60%), var(--panel); }
.dash-hero-l { flex: 1; min-width: 260px; }
.dash-hi { margin: 0 0 6px; font-size: 27px; font-family: var(--head, 'Sora', sans-serif); }
.dash-sub { margin: 0; color: var(--muted); font-size: 14px; max-width: 560px; line-height: 1.6; }
.dash-hero-r { display: flex; align-items: center; gap: 16px; background: var(--bg3); border: 1px solid var(--line); border-radius: 12px; padding: 14px 18px; }
.dash-score-k { font-size: 10px; letter-spacing: .08em; color: var(--muted); }
.dash-score-v { font-weight: 700; font-size: 15px; margin: 2px 0; }
.dash-score-d { font-size: 12px; color: var(--green); }

/* ---- KPI ---- */
.dash-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 16px; }
.kpi { background: var(--panel); border: 1px solid var(--line2, var(--line)); border-radius: 14px; padding: 15px 16px; }
.kpi-top { display: flex; align-items: center; justify-content: space-between; }
.kpi-k { font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.kpi-ic { opacity: .6; font-size: 14px; }
.kpi-v { font-size: 30px; font-weight: 700; font-family: var(--head, 'Sora', sans-serif); margin: 6px 0 4px; }
.kpi-u { font-size: 16px; color: var(--muted); margin-left: 2px; }
.kpi-bot { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; }
.kpi-d { font-size: 11.5px; color: var(--muted); }
.kpi-d.up { color: var(--green); }
.kpi-d.warn { color: var(--gold2, #e6c25a); }

/* ---- Grilles dashboard ---- */
.dash-grid { display: grid; gap: 14px; margin-bottom: 16px; }
.dash-2-1 { grid-template-columns: 1.7fr 1fr; }
.dash-3 { grid-template-columns: repeat(3, 1fr); }
.dash-card { padding: 18px 20px; }
.dash-ch { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.dash-donut { display: flex; align-items: center; gap: 16px; justify-content: center; flex-wrap: wrap; }
.dash-donut .rqc-legend { flex-direction: column; gap: 8px; }
.dash-all { font-size: 12.5px; color: var(--green); cursor: pointer; white-space: nowrap; }

/* ---- Tâches prioritaires ---- */
.task-list { display: flex; flex-direction: column; }
.task-row { display: flex; align-items: center; gap: 12px; padding: 11px 4px; border-bottom: 1px solid var(--line); cursor: pointer; transition: background .12s; border-radius: 8px; }
.task-row:hover { background: var(--bg3); }
.task-row:last-child { border-bottom: 0; }
.task-ic { width: 30px; height: 30px; border-radius: 8px; background: var(--bg3); display: flex; align-items: center; justify-content: center; font-size: 14px; flex-shrink: 0; }
.task-b { flex: 1; min-width: 0; }
.task-h { font-size: 13.5px; color: var(--text); }
.task-s { font-size: 11.5px; color: var(--muted); margin-top: 1px; }
.task-imp { font-size: 10.5px; padding: 3px 9px; border-radius: 20px; white-space: nowrap; }
.task-imp.high { background: rgba(224,115,79,.16); color: #e0734f; }
.task-imp.mid { background: var(--gold-dim, rgba(230,194,90,.16)); color: var(--gold2, #e6c25a); }
.task-do { font-size: 12px; color: var(--muted); border: 1px solid var(--line2, var(--line)); border-radius: 7px; padding: 5px 12px; white-space: nowrap; }
.task-row:hover .task-do { color: var(--green); border-color: var(--green); }

@media (max-width: 1000px) {
  .dash-kpis { grid-template-columns: repeat(2, 1fr); }
  .dash-2-1, .dash-3 { grid-template-columns: 1fr; }
  .rqc-mrow { grid-template-columns: 130px repeat(5, 1fr); }
}

/* ---- Pictos ligne sidebar ---- */
.sb-link .ic, .diag-cta .ic { display: inline-flex; align-items: center; justify-content: center; }
.sb-ico { display: block; }
.sb-link .ic svg { width: 18px; height: 18px; }

/* ---- Cartes de contenus (Guides / Articles / FAQ) ---- */
.radar-banner { display: flex; align-items: center; gap: 14px; text-decoration: none;
  background: linear-gradient(120deg, rgba(139,127,240,.14), rgba(139,127,240,.05)); border: 1px solid rgba(139,127,240,.3);
  border-radius: 14px; padding: 14px 18px; margin-bottom: 16px; }
.radar-ic { width: 34px; height: 34px; border-radius: 10px; background: rgba(139,127,240,.2); color: #8b7ff0;
  display: flex; align-items: center; justify-content: center; font-size: 18px; flex-shrink: 0; }
.radar-tx { flex: 1; }
.radar-h { font-weight: 600; font-size: 14px; color: var(--text); }
.radar-s { font-size: 12.5px; color: var(--muted); margin-top: 1px; }
.radar-go { color: #8b7ff0; font-size: 13px; font-weight: 500; white-space: nowrap; }
.gcards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.gcard { display: flex; align-items: center; gap: 16px; background: var(--panel); border: 1px solid var(--line2, var(--line));
  border-radius: 14px; padding: 16px 18px; cursor: pointer; transition: border-color .15s, transform .1s; }
.gcard:hover { border-color: var(--green); transform: translateY(-1px); }
.gcard-ring { flex-shrink: 0; }
.gcard-body { flex: 1; min-width: 0; }
.gcard-badges { display: flex; gap: 7px; align-items: center; margin-bottom: 7px; }
.gcard-title { font-size: 15px; font-weight: 600; color: var(--text); margin-bottom: 10px; }
.gcard-prog { display: flex; align-items: center; gap: 10px; }
.gcard-bar { flex: 1; height: 7px; border-radius: 5px; background: var(--bg3); overflow: hidden; }
.gcard-bar > span { display: block; height: 100%; border-radius: 5px; transition: width .5s ease; }
.gcard-blocs { font-size: 11.5px; color: var(--muted); font-family: var(--mono, monospace); white-space: nowrap; }
.fmt { font-size: 11px; padding: 2px 9px; border-radius: 20px; font-weight: 500; }
.fmt-top { background: rgba(139,127,240,.16); color: #8b7ff0; }
.fmt-howto { background: var(--green-dim); color: var(--green); }
.fmt-art { background: rgba(111,177,232,.16); color: #6fb1e8; }
.fmt-faq { background: var(--gold-dim, rgba(230,194,90,.16)); color: var(--gold2, #e6c25a); }
@media (max-width: 900px) { .gcards { grid-template-columns: 1fr; } }

/* ---- Cartes produit (Catalogue) ---- */
/* Grille fluide : deux colonnes figées donnaient des cartes de 700 px sur un
   grand écran — illisibles et vides. Elle s'adapte maintenant de 1 à 4
   colonnes selon la place, avec une largeur de carte confortable. */
.pcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
@media (min-width: 1500px) { .pcards { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); } }
.pcard { display: flex; align-items: center; gap: 14px; background: var(--panel); border: 1px solid var(--line2, var(--line));
  border-radius: 14px; padding: 14px 16px; transition: border-color .15s; }
.pcard:hover { border-color: var(--green); }
.pcard-ring { flex-shrink: 0; }
.pcard-body { flex: 1; min-width: 0; }
.pcard-title { font-size: 14.5px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pcard-meta { font-size: 12px; color: var(--muted); margin: 3px 0 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pcard-meta .mono { font-family: var(--mono, monospace); }
.pcard-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.pcard-act { display: flex; gap: 5px; flex-shrink: 0; }
.ic-btn { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 8px;
  background: transparent; border: 1px solid var(--line2, var(--line)); color: var(--muted); cursor: pointer; transition: all .12s; }
.ic-btn:hover { color: var(--green); border-color: var(--green); }
.ic-btn.danger:hover { color: #e0734f; border-color: #e0734f; }
.ic16 { display: block; }
@media (max-width: 900px) { .pcards { grid-template-columns: 1fr; } }

/* ---- Refonte écrans Visibilité IA (Audit / Sources / Prompts) ---- */
.dash-1-2 { grid-template-columns: 1fr 2fr; }
.kpi-ring { margin: 6px 0 4px; }
.src-dom { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; }
.src-bar { display: inline-block; width: 70px; height: 6px; border-radius: 4px; background: var(--bg3); overflow: hidden; vertical-align: middle; margin-right: 8px; }
.src-bar > span { display: block; height: 100%; border-radius: 4px; }
.src-tbl td { vertical-align: middle; }
.mono { font-family: var(--mono, monospace); }
@media (max-width: 1000px) { .dash-1-2 { grid-template-columns: 1fr; } }

/* ---- Lignes de contenu (Articles / FAQ) ---- */
.arows { display: flex; flex-direction: column; gap: 10px; }
.arow { display: flex; align-items: center; gap: 14px; background: var(--panel); border: 1px solid var(--line2, var(--line));
  border-radius: 14px; padding: 14px 18px; cursor: pointer; transition: border-color .15s; }
.arow:hover { border-color: var(--green); }
.arow-ic { width: 36px; height: 36px; border-radius: 9px; background: var(--bg3); color: var(--green);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.faq-ic { color: var(--gold2, #e6c25a); }
.ic18 { display: block; }
.arow-body { flex: 1; min-width: 0; }
.arow-meta { font-size: 11.5px; color: var(--muted); }
.arow-title { font-size: 14.5px; font-weight: 600; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.arow-score { display: flex; align-items: center; gap: 8px; width: 150px; flex-shrink: 0; }
.arow-bar { flex: 1; height: 6px; border-radius: 4px; background: var(--bg3); overflow: hidden; }
.arow-bar > span { display: block; height: 100%; border-radius: 4px; }
.arow-compl { width: 120px; flex-shrink: 0; font-size: 12px; text-align: right; }
.arow-go { font-size: 12.5px; color: var(--muted); border: 1px solid var(--line2, var(--line)); border-radius: 8px; padding: 6px 12px; white-space: nowrap; flex-shrink: 0; }
.arow:hover .arow-go { color: var(--green); border-color: var(--green); }
@media (max-width: 900px) {
  .arow-score, .arow-compl { display: none; }
}

/* ---- Légende de courbe cliquable (toggle série) ---- */
.rqc-linewrap { width: 100%; }
.rqc-clg { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 8px; }
.rqc-clg-i { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--text); cursor: pointer; user-select: none; transition: opacity .12s; }
.rqc-clg-i i { width: 10px; height: 10px; border-radius: 3px; }
.rqc-clg-i.off { opacity: .38; text-decoration: line-through; }
.rqc-clg-i:hover { opacity: .8; }
.rqc-s { transition: opacity .2s; }

/* ---- Tâches : kanban 3 colonnes ---- */
.kanban { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; align-items: start; }
.kcol { background: transparent; }
.kcol-head { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 10px; padding: 0 2px; }
.kdot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.kcount { margin-left: auto; font-size: 11px; color: var(--muted); background: var(--bg3); border-radius: 20px; padding: 1px 8px; }
.kcol-body { display: flex; flex-direction: column; gap: 10px; }
.kcard { background: var(--panel); border: 1px solid var(--line2, var(--line)); border-radius: 12px; padding: 13px 14px; cursor: pointer; transition: border-color .15s, transform .1s; }
.kcard:hover { border-color: var(--green); transform: translateY(-1px); }
.kcard-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.ksrc { font-size: 11px; font-weight: 500; color: var(--sc); position: relative; padding-left: 14px; }
.ksrc::before { content: ''; position: absolute; left: 0; top: 50%; transform: translateY(-50%); width: 8px; height: 8px; border-radius: 2px; background: var(--sc); }
.kimp { font-size: 10.5px; padding: 2px 8px; border-radius: 20px; }
.kimp.high { background: rgba(224,115,79,.16); color: #e0734f; }
.kimp.mid { background: var(--gold-dim, rgba(230,194,90,.16)); color: var(--gold2, #e6c25a); }
.kimp.low { background: var(--bg3); color: var(--muted); }
.ktitle { font-size: 13.5px; font-weight: 600; color: var(--text); line-height: 1.35; margin-bottom: 5px; }
.ksub { font-size: 12px; color: var(--muted); line-height: 1.4; }
.kdone { margin-top: 8px; font-size: 12px; color: var(--green); font-weight: 500; }
@media (max-width: 900px) { .kanban { grid-template-columns: 1fr; } }

/* ---- Flou derrière les popups ---- */
.overlay { background: rgba(6,12,22,.5); backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px); }

/* ---- Bouton gold plein (Générer) ---- */
.btn.gold { background: var(--gold-grad, linear-gradient(135deg,#f5c451,#e0a020)); color: var(--gold-ink, #3a2a05); border: 0; font-weight: 600; }
.btn.gold:hover { filter: brightness(1.05); }
.btn.gold:disabled { opacity: .7; }

/* ---- Éditeur de contenu (anti-régression) ---- */
.fiche-head2 { margin-bottom: 16px; }
.fiche-tabs { display: inline-flex; gap: 8px; }
.ftab { font-size: 13px; padding: 8px 16px; border-radius: 10px; border: 1px solid var(--line2, var(--line)); background: transparent; color: var(--muted); cursor: pointer; transition: all .12s; }
.ftab:hover { color: var(--text); }
.ftab.is-active { background: var(--green-dim); border-color: var(--green); color: var(--green); font-weight: 600; }
.fiche-layout { display: grid; grid-template-columns: 1fr 300px; gap: 18px; align-items: start; }
.fiche-main { min-width: 0; }
.fiche-side { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 14px; }
.side-card { padding: 16px 18px; }
.side-h { font-size: 14px; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.side-h2 { font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 12px; }
.side-txt { font-size: 12.5px; color: var(--muted); line-height: 1.5; margin: 0 0 14px; }
.side-counts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
.side-c { background: var(--bg3); border-radius: 10px; padding: 12px; text-align: center; }
.side-n { font-size: 24px; font-weight: 700; font-family: var(--head, 'Sora', sans-serif); }
.side-l { font-size: 11px; color: var(--muted); margin-top: 2px; }
.side-quota { font-size: 11px; color: var(--muted); text-align: center; margin-top: 8px; }
.side-cita { display: flex; align-items: center; gap: 14px; }
.side-cita .hint { font-size: 12px; line-height: 1.4; }
.lg-list { display: flex; flex-direction: column; gap: 8px; }
.lg-i { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.lg-i i { width: 9px; height: 9px; border-radius: 3px; flex-shrink: 0; }
@media (max-width: 1000px) { .fiche-layout { grid-template-columns: 1fr; } .fiche-side { position: static; } }

/* ---- Diff (Comparer & publier) : tableau ---- */
.diff-warn { display: flex; align-items: flex-start; gap: 12px; background: rgba(224,115,79,.10); border: 1px solid rgba(224,115,79,.4);
  border-radius: 12px; padding: 13px 16px; margin-bottom: 14px; font-size: 13px; color: var(--text); line-height: 1.5; }
.diff-warn-ic { color: #e0734f; font-size: 16px; flex-shrink: 0; }
.diff-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.diff-table thead th { text-align: left; padding: 12px 16px; font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); font-weight: 500; border-bottom: 1px solid var(--line2, var(--line)); background: var(--bg3); }
.diff-table td { padding: 14px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.diff-table tr:last-child td { border-bottom: 0; }
.diff-bloc { width: 190px; }
.diff-name { font-weight: 600; color: var(--text); margin-bottom: 6px; }
.diff-tags { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; }
.diff-cell { color: var(--muted); line-height: 1.5; }
.diff-hl { background: rgba(230,194,90,.07); color: var(--text); }
.diff-mod .diff-name { color: var(--text); }

/* ---- Diagnostic : sous-labels stepper ---- */
.step-sub { display: block; font-size: 11px; margin-top: 3px; }
.step-sub.free { color: var(--green); }
.step-sub.paid { color: var(--gold2, #e6c25a); }

/* ---- Menu Quota (barres) ---- */
.quota-menu { width: 300px; padding: 16px; }
.qm-head { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.qm-plan { font-size: 10px; background: var(--gold-dim, rgba(230,194,90,.16)); color: var(--gold2, #e6c25a); padding: 2px 8px; border-radius: 20px; }
.qm-bar-row { margin-bottom: 12px; }
.qm-bl { display: flex; justify-content: space-between; font-size: 12.5px; margin-bottom: 5px; color: var(--text); }
.qm-bl .mono { color: var(--muted); }
.qm-bar { height: 7px; border-radius: 5px; background: var(--bg3); overflow: hidden; }
.qm-bar > span { display: block; height: 100%; border-radius: 5px; transition: width .5s; }
.qm-foot { font-size: 11.5px; color: var(--muted); margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.qm-link { color: var(--green); cursor: pointer; }

/* ---- Menu Notifications ---- */
.notif-menu { width: 340px; padding: 6px; max-height: 440px; overflow-y: auto; }
.nm-head { display: flex; align-items: center; justify-content: space-between; padding: 10px 12px 8px; }
.nm-head > span { font-size: 14px; font-weight: 600; }
.nm-read { background: none; border: 0; color: var(--green); font-size: 12px; cursor: pointer; }
.nm-item { display: flex; gap: 11px; padding: 11px 12px; border-radius: 10px; cursor: default; align-items: flex-start; position: relative; }
.nm-item:hover { background: var(--bg3); }
.nm-item.unread::after { content: ''; position: absolute; left: 4px; top: 50%; width: 5px; height: 5px; border-radius: 50%; background: var(--green); transform: translateY(-50%); }
.nm-ic { width: 32px; height: 32px; border-radius: 9px; display: flex; align-items: center; justify-content: center; font-size: 14px; flex-shrink: 0; }
.nm-b { flex: 1; min-width: 0; }
.nm-t { font-size: 13px; font-weight: 600; color: var(--text); }
.nm-s { font-size: 12px; color: var(--muted); line-height: 1.4; margin-top: 1px; }
.nm-when { font-size: 10.5px; color: var(--muted); white-space: nowrap; flex-shrink: 0; }

/* ---- Panneau LucIA (assistant proactif) ---- */
.as-who { display: flex; align-items: center; gap: 10px; }
.as-ico { width: 34px; height: 34px; border-radius: 10px; background: rgba(245,196,81,.14); display: flex; align-items: center; justify-content: center; }
.as-meta { line-height: 1.2; }
.as-name { font-size: 15px; font-weight: 700; font-family: var(--head, 'Sora', sans-serif); }
.as-sub { font-size: 11.5px; color: var(--muted); }
.as-send { width: 38px; height: 38px; border-radius: 10px; background: transparent; border: 1px solid var(--line2, var(--line)); color: var(--green); font-size: 15px; cursor: pointer; flex-shrink: 0; transition: all .12s; }
.as-send:hover { background: var(--green-dim); border-color: var(--green); }
/* ---- Cartes LucIA ----
   Le panneau est étroit : disposition en grille (icône | contenu) où la
   colonne de texte est contrainte à `minmax(0, 1fr)`. Sans cette contrainte,
   un titre long (ex. « Vous êtes absent sur "…" ») pousse la carte au-delà
   du panneau au lieu de passer à la ligne. */
.lucia-card { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px 11px;
  background: var(--panel); border: 1px solid var(--line2, var(--line)); border-radius: 12px;
  padding: 12px 13px; margin: 0 12px 10px; align-items: start; }
.lucia-card .lucia-ic { width: 34px; height: 34px; border-radius: 9px; background: var(--green-dim);
  display: flex; align-items: center; justify-content: center; font-size: 16px; flex-shrink: 0; }
.lucia-body { min-width: 0; }
/* Le texte revient à la ligne au lieu de déborder : pas de nowrap, et les
   mots très longs (URL, référence produit) sont coupés si nécessaire. */
.lucia-title { font-size: 13.5px; font-weight: 600; color: var(--text); line-height: 1.35;
  white-space: normal; overflow-wrap: anywhere; word-break: break-word; }
.lucia-why { font-size: 12px; color: var(--muted); line-height: 1.45; margin: 3px 0 0;
  white-space: normal; overflow-wrap: anywhere; }
/* Le bouton occupe la 2e colonne, sous le texte, aligné à gauche. */
.lucia-go { grid-column: 2; justify-self: start; font-size: 12.5px; padding: 6px 14px;
  white-space: nowrap; max-width: 100%; }

/* ---- Bouton d'action des cartes kanban ---- */
.kbtn { margin-top: 10px; width: 100%; font-size: 12px; padding: 6px 10px; border-radius: 8px;
  background: transparent; border: 1px solid var(--line2, var(--line)); color: var(--muted); cursor: pointer; transition: all .12s; }
.kbtn:hover { color: var(--green); border-color: var(--green); }

/* ---- Panneau « Pourquoi pas cité » (diagnostic causal) ---- */
.why-box { background: var(--panel); border: 1px solid var(--line2, var(--line)); border-radius: 12px; padding: 14px 16px; margin-top: 4px; }
.why-box.ok { border-color: var(--green); background: var(--green-dim); }
.why-h { font-size: 13.5px; font-weight: 600; color: var(--text); display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.why-list { display: flex; flex-direction: column; gap: 2px; }
.why-row { display: flex; align-items: flex-start; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); }
.why-row:first-child { border-top: 0; }
.why-sev { flex-shrink: 0; width: 22px; height: 22px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 11px; }
.why-sev.bad { background: rgba(224,115,79,.16); color: #e0734f; }
.why-sev.warn { background: var(--gold-dim, rgba(230,194,90,.16)); color: var(--gold2, #e6c25a); }
.why-sev.neutral { background: var(--bg3); color: var(--muted); }
.why-b { flex: 1; min-width: 0; }
.why-t { font-size: 13px; font-weight: 600; color: var(--text); }
.why-d { font-size: 12px; color: var(--muted); line-height: 1.45; margin-top: 2px; }
.why-go { flex-shrink: 0; font-size: 11.5px; padding: 5px 10px; border-radius: 7px; background: transparent;
  border: 1px solid var(--line2, var(--line)); color: var(--muted); cursor: pointer; white-space: nowrap; transition: all .12s; }
.why-go:hover { color: var(--green); border-color: var(--green); }

/* ---- Modale d'export ---- */
.exp-head { display: flex; align-items: center; gap: 10px; }
.exp-tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line2, var(--line)); }
.exp-tab { font-size: 12.5px; padding: 8px 14px; background: transparent; border: 0; border-bottom: 2px solid transparent;
  color: var(--muted); cursor: pointer; transition: all .12s; }
.exp-tab:hover { color: var(--text); }
.exp-tab.is-active { color: var(--green); border-bottom-color: var(--green); font-weight: 600; }
.exp-img { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--text); margin-bottom: 10px; cursor: pointer; }
.exp-code { width: 100%; min-height: 240px; max-height: 42vh; font-family: var(--mono, monospace); font-size: 11.5px;
  line-height: 1.55; background: var(--bg3); border: 1px solid var(--line2, var(--line)); border-radius: 10px;
  padding: 12px; color: var(--text); resize: vertical; white-space: pre; overflow: auto; }

/* ---- Radar de marché ---- */
.rd-sec { margin-bottom: 26px; }
.rd-sech { display: flex; align-items: baseline; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.rd-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.rd-card { background: var(--panel); border: 1px solid var(--line2, var(--line)); border-radius: 14px; padding: 15px 16px; display: flex; flex-direction: column; }
.rd-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 9px; }
.rd-tag { font-size: 10.5px; padding: 2px 9px; border-radius: 20px; font-weight: 500; white-space: nowrap; }
.rd-tag.prod { background: rgba(139,127,240,.16); color: #8b7ff0; }
.rd-tag.cont { background: var(--green-dim); color: var(--green); }
.rd-proof { font-size: 10.5px; color: var(--muted); white-space: nowrap; cursor: help; }
.rd-label { font-size: 15px; font-weight: 600; color: var(--text); line-height: 1.35; margin-bottom: 5px; }
.rd-why { font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.rd-ev { font-size: 11.5px; color: var(--muted); font-style: italic; margin-top: 8px; padding-left: 9px; border-left: 2px solid var(--line2, var(--line)); }
.rd-act { display: flex; gap: 8px; align-items: center; margin-top: 12px; }
.rd-dismiss { font-size: 12px; background: none; border: 0; color: var(--muted); cursor: pointer; padding: 6px 2px; }
.rd-dismiss:hover { color: var(--text); text-decoration: underline; }
.rd-go { margin-left: auto; font-size: 12.5px; padding: 7px 13px; }

/* ---- ROI IA ---- */
.roi-install { padding: 22px 24px; }
.roi-install code { background: var(--bg3); padding: 1px 5px; border-radius: 4px; font-family: var(--mono, monospace); font-size: 12px; }
.roi-note { display: flex; align-items: center; gap: 8px; background: var(--gold-dim, rgba(230,194,90,.1)); border: 1px solid var(--gold2, #e6c25a);
  border-radius: 10px; padding: 11px 14px; font-size: 13px; color: var(--text); margin-bottom: 16px; }
.roi-missed { border-color: rgba(224,115,79,.4); margin-top: 16px; }
.roi-est { display: flex; align-items: baseline; gap: 10px; margin-top: 6px; }
.roi-est-v { font-size: 30px; font-weight: 700; font-family: var(--head, 'Sora', sans-serif); color: #e0734f; }

/* ---- Découverte de questions ---- */
.disc-list { max-height: 46vh; overflow-y: auto; display: flex; flex-direction: column; gap: 4px; }
.disc-row { display: flex; align-items: flex-start; gap: 11px; padding: 11px 12px; border-radius: 10px; cursor: pointer; transition: background .12s; }
.disc-row:hover { background: var(--bg3); }
.disc-row input { margin-top: 3px; flex-shrink: 0; }
.disc-b { flex: 1; min-width: 0; }
.disc-q { font-size: 13.5px; color: var(--text); line-height: 1.4; }
.disc-m { display: flex; align-items: center; gap: 8px; margin-top: 4px; flex-wrap: wrap; }

/* ---- Pare-feu anti-régression ---- */
.reg-alert { display: flex; gap: 14px; align-items: flex-start; background: rgba(224,115,79,.10);
  border: 1px solid rgba(224,115,79,.45); border-radius: 12px; padding: 14px 16px; margin-bottom: 16px; }
.reg-ic { color: #e0734f; font-size: 18px; flex-shrink: 0; }
.reg-b { flex: 1; }
.reg-h { font-weight: 600; font-size: 14px; color: var(--text); margin-bottom: 8px; }
.reg-list { display: flex; flex-direction: column; gap: 5px; }
.reg-row { font-size: 13px; color: var(--text); }
.reg-arrow { font-family: var(--mono, monospace); font-size: 11.5px; color: #e0734f; background: rgba(224,115,79,.12); padding: 1px 7px; border-radius: 5px; margin-left: 6px; }

/* ---- Analyse Shopping IA (fiche produit) ---- */
.shop-run { padding: 18px 20px; margin-bottom: 14px; }
.shop-ok, .shop-ko { padding: 16px 20px; margin-bottom: 14px; }
.shop-ok { border-color: var(--green); background: var(--green-dim); }
.shop-ko { border-color: rgba(224,115,79,.45); background: rgba(224,115,79,.08); }
.shop-vh { font-size: 15px; font-weight: 600; color: var(--text); }
.shop-eng { padding: 12px 0; border-bottom: 1px solid var(--line); }
.shop-eng:last-child { border-bottom: 0; }
.shop-eng-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.shop-dot { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; }
.shop-dot.ok { background: var(--green); }
.shop-dot.ko { background: #e0734f; }
.shop-desc { font-size: 13px; color: var(--muted); font-style: italic; margin-top: 6px; padding-left: 10px; border-left: 2px solid var(--line2, var(--line)); }
.shop-facts { border-color: rgba(224,115,79,.45); margin-bottom: 14px; }
.fact-row { display: grid; grid-template-columns: 110px 1fr 1fr; gap: 12px; align-items: center; padding: 11px 0; border-top: 1px solid var(--line); }
.fact-f { font-size: 12.5px; font-weight: 600; color: var(--text); text-transform: capitalize; }
.fact-claim { font-family: var(--mono, monospace); font-size: 13px; color: #e0734f; text-decoration: line-through; }
.fact-real { font-family: var(--mono, monospace); font-size: 13px; color: var(--green); font-weight: 600; }
.shop-comp { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.shop-comp:last-child { border-bottom: 0; }
.miss-chips { display: flex; flex-wrap: wrap; gap: 7px; }
@media (max-width: 800px) { .fact-row { grid-template-columns: 1fr; gap: 4px; } }

/* ---- Rapports périodiques ---- */
.rep-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.rep-card { padding: 16px 18px; cursor: pointer; transition: border-color .15s, transform .1s; }
.rep-card:hover { border-color: var(--green); transform: translateY(-1px); }
.rep-top { display: flex; align-items: center; gap: 7px; margin-bottom: 9px; flex-wrap: wrap; }
.rep-per { font-size: 10.5px; padding: 2px 9px; border-radius: 20px; background: var(--bg3); color: var(--muted); }
.rep-new { font-size: 10px; padding: 2px 8px; border-radius: 20px; background: var(--green); color: #04231a; font-weight: 600; margin-left: auto; }
.rep-title { font-size: 15.5px; font-weight: 600; color: var(--text); margin-bottom: 5px; text-transform: capitalize; }
.rep-head { font-size: 12.5px; color: var(--muted); line-height: 1.45; }
.rep-alert { display: flex; align-items: center; gap: 12px; background: rgba(224,115,79,.10); border: 1px solid rgba(224,115,79,.4);
  border-radius: 11px; padding: 12px 15px; margin-bottom: 8px; }
.rep-alert-ic { color: #e0734f; font-size: 17px; flex-shrink: 0; }
.rep-alert-t { font-size: 13.5px; font-weight: 600; color: var(--text); }
.rep-alert .why-go { margin-left: auto; }

/* ---------- Réputation ---------- */
.rep-sent-bar { display:flex; height:16px; border-radius:8px; overflow:hidden; background:var(--bg3,#0d1829); }
.rep-sent-bar span { display:block; height:100%; }
.rep-sent-leg { display:flex; gap:16px; flex-wrap:wrap; margin-top:8px; font-size:12px; color:var(--text2,#8a97a5); }
.rep-sent-leg i { display:inline-block; width:10px; height:10px; border-radius:2px; margin-right:5px; vertical-align:middle; }
.rep-theme { margin-bottom:12px; }
.rep-theme-h { display:flex; justify-content:space-between; align-items:center; font-size:13px; margin-bottom:5px; }
.rep-src { display:flex; gap:8px; flex-wrap:wrap; }
.rep-conc { display:flex; flex-direction:column; gap:8px; }
.rep-conc-row { display:flex; gap:10px; align-items:flex-start; }
.ck-canal { margin-bottom:10px; }
.ck-canal-h { display:flex; justify-content:space-between; font-size:12px; margin-bottom:4px; }
.nav-beta { margin-left:auto; font-size:10px; font-weight:600; text-transform:uppercase; letter-spacing:.4px;
  color:#0d1829; background:var(--gold2,#e6c25a); border-radius:5px; padding:1px 6px; }
/* Admin — édition boutique */
.adm-bo { display:flex; gap:12px; align-items:flex-end; padding:10px 0; border-bottom:1px solid var(--line); flex-wrap:wrap; }
.adm-bo:last-of-type { border-bottom:none; }
.adm-bo-fields { display:flex; gap:12px; flex:1; min-width:260px; }
.adm-bo-fields label { display:flex; flex-direction:column; gap:4px; font-size:11.5px; color:var(--muted); font-weight:600; flex:1; }
.adm-bo-actions { display:flex; gap:8px; align-items:center; }
/* Dashboard — onglets */
.dash-tabs { display:flex; gap:8px; margin:0 0 18px; border-bottom:1px solid var(--line); }
.dash-tab { background:none; border:none; padding:9px 4px; margin-right:14px; font-size:14px; font-weight:600;
  color:var(--muted); cursor:pointer; border-bottom:2px solid transparent; }
.dash-tab.is-active { color:var(--text); border-bottom-color:var(--green,#00BF93); }
.dash-tab:hover { color:var(--text); }
.vrow { display:flex; gap:10px; align-items:center; padding:7px 8px; border-radius:8px; cursor:pointer; font-size:13px; }
.vrow:hover { background:rgba(255,255,255,.03); }
