/* Socle (la version claude.ai l'ajoutait d'elle-même) */
:root { color-scheme: light; padding-top: env(safe-area-inset-top, 0px); padding-bottom: env(safe-area-inset-bottom, 0px); }
body { margin: 0; }
img { max-width: 100%; }
[hidden] { display: none !important; }

/* Layout : barre d'onglets en haut ; à gauche la liste des clients, à droite la fiche du client avec la table du déjeuner (le client au centre, 4 places autour). */
:root {
  --bg: #f4f6f9;
  --surface: #ffffff;
  --ink: #16213a;
  --muted: #5a6479;
  --line: #dce1ea;
  --line-strong: #c3cad8;
  --accent: #2346c4;
  --accent-ink: #ffffff;
  --accent-soft: #e6ebfb;
  --host: #e0a224;
  --host-soft: #fbf1db;
  --host-ink: #6b4a05;
  --danger: #b4321f;
  --ok: #2c7a4b;
  --stripe: #e9edf5;
  --c-vert: #2f7d6b;
  --c-violet: #8a4fbf;
  --c-orange: #c2532f;
  --c-jaune: #c98810;
  --c-bleu: #2b7fc4;
  --c-olive: #5f7a24;
  --c-rose: #a8436f;
  --c-gris: #56637a;
  --font-display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --font-body: "Instrument Sans", "Helvetica Neue", "Segoe UI", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --r: 10px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0f1524; --surface: #161e31; --ink: #e8ecf5; --muted: #9ba4b9; --line: #263049; --line-strong: #36415e;
    --accent: #8ea6ff; --accent-ink: #0f1524; --accent-soft: #1e2a4d; --host: #f0bf4a; --host-soft: #3a2f14; --host-ink: #f6d68a;
    --danger: #f08a78; --ok: #6fc995; --stripe: #1b2439;
    --c-vert: #5fc0a8; --c-violet: #bd8fea; --c-orange: #f08f6c; --c-jaune: #f0bf4a; --c-bleu: #6fb4f0; --c-olive: #a9c769; --c-rose: #ea8db6; --c-gris: #9ba8c0;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0f1524; --surface: #161e31; --ink: #e8ecf5; --muted: #9ba4b9; --line: #263049; --line-strong: #36415e;
  --accent: #8ea6ff; --accent-ink: #0f1524; --accent-soft: #1e2a4d; --host: #f0bf4a; --host-soft: #3a2f14; --host-ink: #f6d68a;
  --danger: #f08a78; --ok: #6fc995; --stripe: #1b2439;
  --c-vert: #5fc0a8; --c-violet: #bd8fea; --c-orange: #f08f6c; --c-jaune: #f0bf4a; --c-bleu: #6fb4f0; --c-olive: #a9c769; --c-rose: #ea8db6; --c-gris: #9ba8c0;
  color-scheme: dark;
}

* { box-sizing: border-box; }
body { background: var(--bg); color: var(--ink); font-family: var(--font-body); font-size: 15px; line-height: 1.5; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--surface); }
h1, h2, h3 { font-family: var(--font-display); text-wrap: balance; margin: 0; letter-spacing: -0.01em; }
h1 { font-size: 2rem; line-height: 1.1; font-weight: 700; }
h2 { font-size: 1.15rem; font-weight: 600; }
h3 { font-size: 0.95rem; font-weight: 600; }
p { margin: 0; }
a { color: var(--accent); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.wrap { max-width: 1240px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }

/* Barre du haut */
.bar { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--surface); border-bottom: 1px solid var(--line); }
.bar-in { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-block: 12px; }
.brand { display: flex; flex-direction: column; gap: 1px; }
.brand-name { font-family: var(--font-display); font-weight: 700; font-size: 1.25rem; letter-spacing: -0.02em; }
.brand-club { font-size: 0.78rem; color: var(--muted); letter-spacing: 0.02em; }
.tabs { display: flex; gap: 4px; background: var(--bg); padding: 4px; border-radius: 999px; border: 1px solid var(--line); }
.tab { border: 0; background: transparent; padding: 6px 14px; border-radius: 999px; cursor: pointer; color: var(--muted); font-weight: 500; display: inline-flex; gap: 6px; align-items: center; }
.tab[aria-selected="true"] { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-strong); }
.count { font-family: var(--font-mono); font-size: 0.72rem; color: var(--muted); font-variant-numeric: tabular-nums; }

main { padding-block: 20px 48px; }

/* Boutons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid var(--line-strong); background: var(--surface); padding: 8px 14px; border-radius: 8px; cursor: pointer; font-weight: 500; white-space: nowrap; }
.btn:hover { border-color: var(--ink); }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); box-shadow: 0 1px 2px rgba(15, 25, 60, 0.18); }
.btn.primary:hover { filter: brightness(1.08); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--muted); padding: 6px 8px; }
.btn.ghost:hover { color: var(--ink); border-color: var(--line); }
.btn.danger { color: var(--danger); }
.btn.danger.armed { background: var(--danger); color: var(--surface); border-color: var(--danger); }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.btn.small { padding: 4px 10px; font-size: 0.85rem; }

.notice { border: 1px solid var(--line-strong); background: var(--surface); border-radius: var(--r); padding: 12px 14px; margin-bottom: 16px; color: var(--muted); }

/* Vue clients */
.view-clients { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 24px; align-items: start; }
.side { display: flex; flex-direction: column; gap: 12px; position: sticky; top: calc(env(safe-area-inset-top, 0px) + 84px); }
.side-label { font-family: var(--font-mono); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.client-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.client-item { width: 100%; text-align: left; border: 1px solid transparent; background: transparent; border-radius: 8px; padding: 9px 11px; cursor: pointer; display: flex; flex-direction: column; gap: 2px; }
.client-item:hover { background: var(--surface); border-color: var(--line); }
.client-item[aria-current="true"] { background: var(--surface); border-color: var(--line-strong); }
.client-item .ci-name { font-weight: 600; }
.client-item .ci-sub { font-size: 0.82rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.empty-side { color: var(--muted); font-size: 0.9rem; padding: 4px 2px; }

.pane { min-width: 0; }
.client { display: flex; flex-direction: column; gap: 18px; }
.client-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.eyebrow { font-family: var(--font-mono); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin-bottom: 6px; }
.meta { color: var(--muted); margin-top: 6px; display: flex; gap: 6px 14px; flex-wrap: wrap; }
.head-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.block { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.block-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.hint { color: var(--muted); font-size: 0.88rem; max-width: 70ch; }
.resume { font-size: 1.02rem; max-width: 72ch; }
.facts { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 3px; max-width: 72ch; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { font-size: 0.8rem; border: 1px solid var(--line-strong); border-radius: 999px; padding: 2px 10px; color: var(--muted); background: var(--surface); }
button.chip { cursor: pointer; }
button.chip[aria-pressed="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }
details summary { cursor: pointer; color: var(--muted); font-size: 0.88rem; }
details[open] summary { margin-bottom: 8px; }
.raw { white-space: pre-wrap; font-size: 0.88rem; color: var(--muted); max-height: 220px; overflow: auto; border: 1px solid var(--line); border-radius: 8px; padding: 10px; background: var(--bg); }

/* Problématiques */
.probs { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.prob { text-align: left; border: 1px solid var(--line-strong); background: var(--surface); border-radius: var(--r); padding: 12px 14px; cursor: pointer; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.prob:hover { border-color: var(--ink); }
.prob[aria-pressed="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); background: var(--accent-soft); }
.prob-title { font-weight: 600; }
.prob-why { font-size: 0.85rem; color: var(--muted); }
.cert { align-self: flex-start; font-family: var(--font-mono); font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.06em; padding: 1px 7px; border-radius: 4px; border: 1px solid var(--line-strong); color: var(--muted); }
.cert.constate { color: var(--ok); border-color: var(--ok); }
.add-prob { display: flex; gap: 8px; flex-wrap: wrap; }
.add-prob input { flex: 1 1 240px; min-width: 0; }

/* La table */
.nappe-label { font-family: var(--font-mono); font-size: 0.68rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.seat { border: 1px solid var(--line-strong); border-radius: var(--r); padding: 12px 14px; display: flex; flex-direction: column; gap: 6px; background: var(--surface); min-width: 0; }
.seat.is-host { border-color: var(--host); box-shadow: inset 0 0 0 1px var(--host); }
.seat-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.seat-name { font-weight: 600; }
.badge { font-family: var(--font-mono); font-size: 0.66rem; text-transform: uppercase; letter-spacing: 0.06em; padding: 1px 7px; border-radius: 4px; }
.badge.host { background: var(--host-soft); color: var(--host-ink); }
.seat-job { font-size: 0.82rem; color: var(--muted); }
.seat-role { font-size: 0.82rem; font-weight: 600; }
.seat-q { font-size: 0.88rem; border-top: 1px dashed var(--line-strong); padding-top: 6px; }
.seat-q span { display: block; font-family: var(--font-mono); font-size: 0.66rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.seat.free { border-style: dashed; align-items: flex-start; justify-content: center; color: var(--muted); min-height: 120px; }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: none; background: var(--c-gris); }
.dot.big { width: 12px; height: 12px; }
.dot.vert { background: var(--c-vert); } .dot.violet { background: var(--c-violet); } .dot.orange { background: var(--c-orange); } .dot.jaune { background: var(--c-jaune); }
.dot.bleu { background: var(--c-bleu); } .dot.olive { background: var(--c-olive); } .dot.rose { background: var(--c-rose); } .dot.gris { background: var(--c-gris); }
.deroule { border-top: 1px solid var(--line); padding-top: 12px; display: flex; flex-direction: column; gap: 4px; max-width: 80ch; }

.reserve { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 8px; }
.reserve li { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.reserve .r-name { display: flex; align-items: center; gap: 7px; font-weight: 600; font-size: 0.92rem; }
.reserve .r-angle { font-size: 0.86rem; color: var(--muted); }

/* Formulaires */
.form { display: flex; flex-direction: column; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.field label { font-weight: 600; font-size: 0.88rem; }
.field .help { font-size: 0.8rem; color: var(--muted); }
.field input, .field select, .field textarea, .add-prob input { border: 1px solid var(--line-strong); background: var(--surface); border-radius: 8px; padding: 8px 10px; width: 100%; }
.field textarea { resize: vertical; min-height: 84px; }
.row2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.form-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.inline-msg { font-size: 0.85rem; color: var(--muted); }
.inline-msg.err { color: var(--danger); }

/* Génération */
.gen { border: 1px solid var(--accent); background: var(--accent-soft); border-radius: var(--r); padding: 14px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.gen-text { flex: 1 1 260px; }
.pulse { width: 10px; height: 10px; border-radius: 50%; background: var(--accent); animation: pulse 1.2s ease-in-out infinite; flex: none; }
@keyframes pulse { 0%, 100% { opacity: 0.35; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .pulse { animation: none; } }

/* Vue membres */
.mem-tools { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.mem-tools input { flex: 1 1 220px; min-width: 0; border: 1px solid var(--line-strong); background: var(--surface); border-radius: 8px; padding: 8px 10px; }
.mem-filters { margin-bottom: 16px; }
.mem-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; align-items: start; }
.mem-layout.has-pane { grid-template-columns: minmax(0, 1fr) minmax(0, 440px); }
.mem-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.mem-card { text-align: left; border: 1px solid var(--line); background: var(--surface); border-radius: var(--r); padding: 12px 14px; cursor: pointer; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.mem-card:hover { border-color: var(--line-strong); }
.mem-card[aria-current="true"] { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.mem-name { font-weight: 600; display: flex; align-items: center; gap: 8px; }
.mem-job { font-size: 0.84rem; color: var(--muted); }
.mem-help { margin: 0; padding-left: 16px; font-size: 0.84rem; display: flex; flex-direction: column; gap: 2px; }
.mem-pane { position: sticky; top: calc(env(safe-area-inset-top, 0px) + 84px); max-height: calc(100vh - 110px); overflow: auto; }
.mem-also { font-size: 0.78rem; color: var(--muted); }
.cercles { display: flex; flex-direction: column; gap: 28px; min-width: 0; }
.cercle-sec { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.cercle-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 8px 16px; flex-wrap: wrap; border-bottom: 1px solid var(--line); padding-bottom: 8px; }
.cercle-head h2 { display: flex; align-items: center; gap: 9px; }
.cercle-title { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.cercle-actions { display: flex; align-items: center; gap: 10px; }
.prob-tags { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.prob-cercle { display: inline-flex; align-items: center; gap: 5px; font-size: 0.78rem; color: var(--muted); }
fieldset.field { border: 0; padding: 0; margin: 0; }
fieldset.field legend { font-weight: 600; font-size: 0.88rem; margin-bottom: 6px; padding: 0; }
.checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 4px 14px; }
.check { display: flex; align-items: center; gap: 7px; font-size: 0.9rem; cursor: pointer; padding: 3px 0; min-width: 0; }
.check input { margin: 0; flex: none; }

/* Pastilles de cercles : une par cercle, légèrement superposées */
.dots { display: inline-flex; align-items: center; flex: none; }
.dots .dot { box-shadow: 0 0 0 2px var(--surface); }
.dots .dot + .dot { margin-left: -4px; }

/* La table ronde vue du dessus */
.ronde { display: grid; grid-template-columns: minmax(0, 440px) minmax(0, 1fr); gap: 20px; align-items: center; }
.ronde-stage { position: relative; aspect-ratio: 1; width: 100%; max-width: 440px; }
.ronde-table { position: absolute; inset: 24%; border-radius: 50%; background: var(--surface); border: 1px solid var(--line-strong); box-shadow: inset 0 0 0 7px var(--stripe), inset 0 0 0 8px var(--line); display: flex; align-items: center; justify-content: center; text-align: center; padding: 9%; }
.ronde-centre { display: flex; flex-direction: column; align-items: center; gap: 5px; }
.ronde-prob { font-family: var(--font-display); font-weight: 600; font-size: 0.95rem; line-height: 1.2; }
.convive { position: absolute; transform: translate(-50%, -50%); width: 30%; display: flex; flex-direction: column; align-items: center; gap: 3px; text-align: center; background: none; border: 0; padding: 0; cursor: pointer; color: inherit; font: inherit; }
div.convive { cursor: default; }
.assiette { width: 56px; height: 56px; border-radius: 50%; background: var(--surface); border: 1px solid var(--line-strong); box-shadow: inset 0 0 0 6px var(--bg), inset 0 0 0 7px var(--line); display: flex; align-items: center; justify-content: center; font-family: var(--font-display); font-weight: 700; font-size: 0.95rem; }
.convive.is-host .assiette { border-color: var(--host); box-shadow: inset 0 0 0 6px var(--host-soft), inset 0 0 0 7px var(--host); }
.convive[aria-pressed="true"] .assiette { border-color: var(--accent); box-shadow: inset 0 0 0 6px var(--accent-soft), inset 0 0 0 7px var(--accent); }
.convive.client .assiette { background: var(--ink); color: var(--surface); box-shadow: none; border-color: var(--ink); }
.convive.libre .assiette { border-style: dashed; box-shadow: none; color: var(--muted); }
.convive-nom { font-weight: 600; font-size: 0.84rem; line-height: 1.2; display: inline-flex; align-items: center; gap: 5px; }
.convive-sub { font-size: 0.74rem; color: var(--muted); line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ronde-detail { min-width: 0; }

/* Atelier message */
.mem-progress { margin-bottom: 8px; }
.chip-sep { width: 1px; align-self: stretch; background: var(--line-strong); margin: 0 4px; }
.mem-pitch { font-size: 0.86rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mem-foot { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: auto; }
.statut { font-family: var(--font-mono); font-size: 0.66rem; text-transform: uppercase; letter-spacing: 0.06em; padding: 1px 7px; border-radius: 4px; border: 1px solid var(--line-strong); color: var(--muted); }
.statut.ok { color: var(--ok); border-color: var(--ok); }
.statut-box { display: flex; align-items: center; justify-content: space-between; gap: 8px 12px; flex-wrap: wrap; border: 1px dashed var(--line-strong); border-radius: 8px; padding: 10px 12px; font-size: 0.88rem; color: var(--muted); }
.statut-box.ok { border-style: solid; border-color: var(--ok); color: var(--ok); }
.pitch { font-family: var(--font-display); font-size: 1.05rem; font-weight: 600; line-height: 1.35; }
.mini-label { font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.08em; font-size: 0.68rem; color: var(--muted); }
.atelier { border-top: 1px solid var(--line); padding-top: 14px; display: flex; flex-direction: column; gap: 10px; }
.conseils { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.conseil { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.conseil.fait { opacity: 0.65; }
.conseil-meta { display: flex; justify-content: space-between; gap: 6px 10px; flex-wrap: wrap; align-items: center; font-size: 0.8rem; color: var(--muted); }
.conseil-actions { display: flex; gap: 2px; }
.prop-box { border: 1px solid var(--accent); background: var(--accent-soft); border-radius: var(--r); padding: 14px; display: flex; flex-direction: column; gap: 10px; }

.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(16px + env(safe-area-inset-bottom, 0px)); background: var(--ink); color: var(--surface); padding: 9px 16px; border-radius: 8px; font-size: 0.9rem; opacity: 0; pointer-events: none; transition: opacity 0.2s; max-width: calc(100% - 32px); }
.toast.show { opacity: 1; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

@media (max-width: 900px) {
  .view-clients { grid-template-columns: minmax(0, 1fr); }
  .side { position: static; }
  .mem-layout.has-pane { grid-template-columns: minmax(0, 1fr); }
  .mem-pane { position: static; max-height: none; }
}
@media (max-width: 720px) {
  .row2 { grid-template-columns: minmax(0, 1fr); }
  h1 { font-size: 1.6rem; }
  .ronde { grid-template-columns: minmax(0, 1fr); }
  .ronde-stage { max-width: 360px; margin: 0 auto; }
  .assiette { width: 44px; height: 44px; font-size: 0.82rem; }
  .convive-sub { display: none; }
}

/* Page de connexion (servie par serveur.py) */
body.connexion main { min-height: 100vh; box-sizing: border-box; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding-block: 24px; text-align: center; }
.connexion-formulaire { display: flex; flex-direction: column; gap: 10px; width: min(320px, 100%); margin-top: 20px; text-align: left; }
.connexion-formulaire label { font-weight: 600; font-size: 0.88rem; }
.connexion-formulaire input { border: 1px solid var(--line-strong); background: var(--surface); border-radius: 8px; padding: 10px 12px; font: inherit; color: inherit; }
.connexion-erreur { color: var(--danger); font-size: 0.9rem; max-width: 42ch; margin-top: 12px; }
body.connexion code { font-family: var(--font-mono); font-size: 0.85em; }
.bar-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* Annuaire : vue Liste ou Réseau */
.vue-switch { display: flex; gap: 4px; flex: none; }
.vue-btn { border: 1px solid var(--line-strong); background: var(--surface); border-radius: 999px; padding: 6px 14px; cursor: pointer; font-weight: 500; }
.vue-btn[aria-pressed="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.reseau { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.reseau-barre { display: flex; justify-content: space-between; align-items: center; gap: 8px 16px; flex-wrap: wrap; }
.legende { display: flex; gap: 6px 18px; flex-wrap: wrap; align-items: center; font-size: 0.8rem; color: var(--muted); }
.legende > span { display: inline-flex; align-items: center; gap: 7px; }
.legende-trait { display: inline-block; width: 28px; border-top: 3px solid var(--ink); }
.legende-trait.potentiel { border-top-style: dashed; }
.legende-trait.table { border-top: 3px dotted var(--muted); }
.reseau-scene { position: relative; height: clamp(420px, calc(100vh - 300px), 860px); border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); overflow: hidden; touch-action: none; }
.reseau-canvas { display: block; width: 100%; height: 100%; cursor: grab; }
.reseau-zoom { position: absolute; right: 10px; bottom: 10px; display: flex; gap: 4px; }

/* Liens d'un membre */
.liens { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.lien { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; display: flex; flex-direction: column; gap: 5px; }
.lien.sugg { border-style: dashed; flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 10px; }
.lien-haut { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.lien-nom { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; font-size: 0.92rem; }
.lien-statut { font-size: 0.8rem; color: var(--muted); }
.lien-statut.ok { color: var(--ok); }
.lien-note { font-size: 0.86rem; color: var(--muted); }
.capacite { display: inline-flex; gap: 2px; align-items: flex-end; }
.capacite .barre { width: 5px; height: 12px; border-radius: 2px; background: var(--line-strong); }
.capacite .barre.pleine { background: var(--ink); }
.suggestions { display: flex; flex-direction: column; gap: 6px; }
.lien-form { border-top: 1px dashed var(--line-strong); padding-top: 12px; gap: 10px; }
.field-label { font-weight: 600; font-size: 0.88rem; }
.pills { display: flex; gap: 4px; flex-wrap: wrap; }
.pill { min-width: 36px; border: 1px solid var(--line-strong); background: var(--surface); border-radius: 999px; padding: 4px 11px; cursor: pointer; font: inherit; font-size: 0.86rem; color: inherit; }
.pill[aria-checked="true"] { background: var(--ink); color: var(--surface); border-color: var(--ink); }

@media (max-width: 720px) {
  .reseau-scene { height: clamp(360px, 62vh, 560px); }
  .legende { font-size: 0.76rem; }
}
