/* ═══════════════════════════════════════════════════════════
   MEEWAV · LE QG — Design system v4
   Verre sombre, violet Meewav et information volontairement calme.
   ═══════════════════════════════════════════════════════════ */

:root {
  --bg: #0a0a0e;
  --bg-soft: #111116;
  --card: #17161e;
  --card-2: #1c1a25;
  --card-3: #24222e;
  --line: rgba(224, 218, 255, .085);
  --line-strong: rgba(224, 218, 255, .16);

  --text: #f4f4f6;
  --muted: #aaa7b4;
  --faint: #74717e;

  --accent: #8b6cff;
  --accent-2: #b3a1ff;
  --accent-soft: rgba(139, 108, 255, .13);
  --accent-fill: rgba(139, 108, 255, .16);
  --accent-line: rgba(139, 108, 255, .55);

  --web: #b8adff;
  --web-soft: rgba(139, 108, 255, .1);
  --web-line: rgba(139, 108, 255, .34);

  --mobile: #62d6a8;
  --mobile-soft: rgba(98, 214, 168, .1);
  --mobile-line: rgba(98, 214, 168, .38);

  --ios: #b8adff;
  --ios-soft: rgba(139, 108, 255, .1);
  --ios-line: rgba(139, 108, 255, .34);
  --android: #aaa7b4;
  --android-soft: rgba(255, 255, 255, .04);
  --android-line: rgba(255, 255, 255, .12);
  --macos: #aaa7b4;
  --macos-soft: rgba(255, 255, 255, .04);
  --macos-line: rgba(255, 255, 255, .12);
  --windows: #aaa7b4;
  --windows-soft: rgba(255, 255, 255, .04);
  --windows-line: rgba(255, 255, 255, .12);

  --pink: #ff4d6a;
  --pink-soft: rgba(255, 77, 106, .12);
  --yellow: #f7c948;
  --yellow-soft: rgba(247, 201, 72, .12);
  --violet: #b3a1ff;
  --red: #ff4d6a;
  --gold: #b3a1ff;
  --gold-2: #c4b5fd;

  --radius: 22px;
  --radius-sm: 13px;
  --radius-xs: 10px;
  --font-ui: 'Inter', -apple-system, 'SF Pro Display', 'Segoe UI', sans-serif;
  --font-display: 'Inter', -apple-system, sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', Menlo, monospace;

  --ctl: 40px;            /* hauteur standard des contrôles */
  --ctl-sm: 32px;         /* hauteur compacte */
  --pad-card: 22px;       /* marge interne des cartes */
  --shadow: 0 24px 70px -34px rgba(0, 0, 0, .95);
  --shadow-btn: 0 8px 22px -12px rgba(139, 108, 255, .55);
  --sidebar-w: 240px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { color-scheme: dark; }

body {
  font-family: var(--font-ui);
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--text);
  background:
    radial-gradient(900px 460px at 52% -12%, rgba(139, 108, 255, .11), transparent 62%),
    var(--bg);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: .022;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

::selection { background: rgba(139, 108, 255, .35); color: #fff; }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .09); border-radius: 6px; border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, .18); }

a { color: var(--accent-2); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font-family: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 8px; }

/* ── typographie ─────────────────────────────────────────── */
.eyebrow {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: .15em;
  text-transform: uppercase;
  color: var(--faint);
}

.display { font-family: var(--font-display); font-weight: 800; letter-spacing: -.02em; }
.mono { font-family: var(--font-mono); }

/* ═══════════════════════════════════════════════════════════
   ÉCRAN DE CONNEXION
   ═══════════════════════════════════════════════════════════ */
.login {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  animation: fadeIn .5s ease;
}

.login-mono {
  width: 64px; height: 64px;
  border-radius: 18px;
  display: grid; place-items: center;
  font-size: 27px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(150deg, #7c5cfc, #5335d1 75%);
  border: 1px solid rgba(179, 161, 255, .45);
  box-shadow: 0 24px 60px -22px rgba(124, 92, 252, .6), inset 0 1px 0 rgba(255, 255, 255, .22);
  margin-bottom: 28px;
}

.login h1 {
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -.025em;
}
.login h1 em { color: var(--accent-2); font-style: normal; }

.login-sub { color: var(--muted); margin: 10px 0 36px; font-size: 13.5px; }

.login-houses {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  width: 100%;
  max-width: 470px;
}

.house {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  cursor: pointer;
  text-align: left;
  color: var(--text);
  transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease;
  position: relative;
}

.house:hover {
  transform: translateY(-2px);
  border-color: var(--line-strong);
}

.house.selected {
  border-color: var(--house-color, var(--accent));
  background: linear-gradient(180deg, color-mix(in srgb, var(--house-color, #8b6cff) 8%, var(--card)), var(--card));
  box-shadow: 0 0 0 1px var(--house-color, var(--accent));
}

.house-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--house-color, var(--accent));
  box-shadow: 0 0 12px var(--house-color, var(--accent));
  margin-bottom: 26px;
}

.house-name { font-size: 17px; font-weight: 700; letter-spacing: -.01em; }
.house-role { color: var(--muted); font-size: 12px; margin-top: 2px; }

.login-pin {
  width: 100%;
  max-width: 470px;
  margin-top: 12px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 6px 6px 18px;
  display: flex;
  gap: 12px;
  align-items: center;
  animation: slideUp .25s ease;
}

.login-pin input {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: none;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 16px;
  letter-spacing: .4em;
}
.login-pin input:focus { outline: none; }
.login-pin input::placeholder { letter-spacing: .35em; color: var(--faint); }
.login-pin .btn { height: 36px; flex-shrink: 0; }

.login-error { margin-top: 14px; color: var(--pink); font-size: 12.5px; min-height: 18px; font-weight: 600; }

.login-foot { margin-top: 40px; color: var(--faint); font-size: 11.5px; letter-spacing: .04em; }

.boot-failure {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px;
  text-align: center;
}
.boot-failure .login-mono { margin-bottom: 22px; }
.boot-failure h1 { font-size: 24px; letter-spacing: -.025em; }
.boot-failure p { max-width: 520px; color: var(--muted); font-size: 12.5px; line-height: 1.65; margin: 10px 0 18px; }
.boot-failure small { max-width: 680px; color: var(--faint); font: 10px/1.5 var(--font-mono); margin-top: 16px; overflow-wrap: anywhere; }

/* ═══════════════════════════════════════════════════════════
   COQUILLE (sidebar + contenu)
   ═══════════════════════════════════════════════════════════ */
.shell { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  border-right: 1px solid var(--line);
  padding: 20px 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  position: sticky;
  top: 0;
  height: 100vh;
  background: rgba(13, 13, 16, .78);
  backdrop-filter: blur(14px);
  z-index: 10;
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 4px 10px 18px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 12px;
}

.brand-mono {
  width: 34px; height: 34px;
  border-radius: 10px;
  display: grid; place-items: center;
  font-size: 15px;
  font-weight: 800;
  color: #fff;
  background: linear-gradient(150deg, #7c5cfc, #5335d1 75%);
  border: 1px solid rgba(179, 161, 255, .4);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .2);
  flex-shrink: 0;
}

.brand-name { font-size: 12px; font-weight: 800; letter-spacing: .15em; }
.brand-sub { font-size: 10.5px; color: var(--faint); }

.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  height: 40px;
  padding: 0 12px;
  border-radius: 12px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
  background: none;
  width: 100%;
  text-align: left;
  transition: color .15s, background .15s, border-color .15s;
}

.nav-item svg { flex-shrink: 0; opacity: .9; }
.nav-item:hover { color: var(--text); background: rgba(255, 255, 255, .045); }

.nav-item.active {
  color: #fff;
  background: var(--accent-fill);
  border-color: var(--accent-line);
}
.nav-item.active svg { color: var(--accent-2); opacity: 1; }

.nav-sep {
  margin: 14px 12px 7px;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .17em;
  text-transform: uppercase;
  color: var(--faint);
}

.sidebar-foot { margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); }

.user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 12px;
  cursor: pointer;
  transition: background .15s;
}
.user-chip:hover { background: rgba(255, 255, 255, .045); }

.user-dot {
  width: 8px; height: 8px; border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 8px currentColor;
}
.user-chip-name { font-size: 12.5px; font-weight: 700; }
.user-chip-role { font-size: 10.5px; color: var(--faint); }

/* ── zone principale ─────────────────────────────────────── */
.main {
  flex: 1;
  min-width: 0;
  padding: 32px 40px 64px;
  max-width: 1260px;
}

.page-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.page-head h1 {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -.025em;
  margin-top: 6px;
}
.page-head h1 em { font-style: normal; color: var(--accent-2); }

.page-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }

.view { animation: viewIn .3s ease; }

@keyframes viewIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes slideUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ═══════════════════════════════════════════════════════════
   COMPOSANTS
   ═══════════════════════════════════════════════════════════ */
.card {
  background:
    linear-gradient(145deg, rgba(255, 255, 255, .025), transparent 46%),
    rgba(23, 22, 30, .82);
  border: 1px solid rgba(215, 207, 255, .105);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .028), var(--shadow);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.card-pad { padding: var(--pad-card); }

.card-hover { transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease; }
.card-hover:hover { transform: translateY(-2px); border-color: var(--line-strong); box-shadow: var(--shadow); }

/* boutons — hauteur unique, pill, teinte violette pour l'action */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: var(--ctl);
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--card-3);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: transform .15s, border-color .15s, background .15s, box-shadow .15s;
  white-space: nowrap;
}
.btn:hover { border-color: rgba(255, 255, 255, .24); transform: translateY(-1px); }
.btn:active { transform: none; }
.btn svg { flex-shrink: 0; }

.btn-gold {
  background: var(--accent-fill);
  border-color: var(--accent-line);
  color: #fff;
  box-shadow: var(--shadow-btn);
}
.btn-gold:hover { background: rgba(139, 108, 255, .24); border-color: rgba(139, 108, 255, .8); }

.btn-ghost { background: transparent; border-color: var(--line); }
.btn-ghost:hover { border-color: var(--line-strong); background: rgba(255, 255, 255, .04); }

.btn-danger { color: var(--pink); }
.btn-danger:hover { border-color: rgba(255, 77, 106, .5); background: var(--pink-soft); }

.btn-sm { height: var(--ctl-sm); padding: 0 14px; font-size: 12px; }

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 30px; height: 30px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: .15s;
  flex-shrink: 0;
}
.icon-btn:hover { color: var(--text); background: rgba(255, 255, 255, .07); border-color: var(--line); }
.icon-btn.danger:hover { color: var(--pink); background: var(--pink-soft); }

/* puces — micro-étiquettes majuscules, comme « EN COURS » */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 22px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
  border: 1px solid;
  white-space: nowrap;
}
.chip i {
  width: 4.5px; height: 4.5px; border-radius: 50%;
  background: currentColor;
}
.chip.web, .chip.mobile, .chip.ios,
.chip.android, .chip.macos, .chip.windows {
  color: var(--accent-2);
  background: var(--accent-soft);
  border-color: rgba(139, 108, 255, .3);
}
.chip.infrastructure { color: var(--yellow); background: var(--yellow-soft); border-color: rgba(247, 201, 72, .42); }
.chip.shared, .chip.both { color: var(--accent-2); background: var(--accent-soft); border-color: var(--accent-line); }
.chip.neutral { color: var(--muted);  background: rgba(255, 255, 255, .04); border-color: var(--line-strong); }
.chip.violet  { color: var(--violet); background: var(--accent-soft); border-color: var(--accent-line); }
.chip.red     { color: var(--pink);   background: var(--pink-soft);   border-color: rgba(255, 77, 106, .45); }
.chip.green   { color: var(--mobile); background: var(--mobile-soft); border-color: var(--mobile-line); }
.chip.blue    { color: var(--accent-2); background: var(--accent-soft); border-color: var(--accent-line); }
.chip.yellow  { color: var(--yellow); background: var(--yellow-soft); border-color: rgba(247, 201, 72, .42); }

/* champs — hauteur unique 40, rayon 13 */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field label {
  font-size: 10.5px; font-weight: 800; letter-spacing: .12em;
  text-transform: uppercase; color: var(--faint);
}
.field label b { color: var(--accent-2); font-weight: 800; }

.input, .select {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-ui);
  font-size: 13.5px;
  height: var(--ctl);
  padding: 0 14px;
  width: 100%;
  transition: border-color .15s, box-shadow .15s;
}
.textarea {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 12.5px;
  line-height: 1.6;
  padding: 12px 14px;
  width: 100%;
  min-height: 110px;
  resize: vertical;
  transition: border-color .15s, box-shadow .15s;
}
.input:focus, .select:focus, .textarea:focus {
  outline: none;
  border-color: var(--accent-line);
  box-shadow: 0 0 0 3px rgba(139, 108, 255, .14);
}
.input::placeholder, .textarea::placeholder { color: var(--faint); }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23a0a0aa' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 13px center; padding-right: 36px; cursor: pointer; }

.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* interrupteur */
.switch { position: relative; width: 40px; height: 23px; flex-shrink: 0; cursor: pointer; display: inline-block; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch i {
  position: absolute; inset: 0;
  background: var(--card-3);
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  transition: .2s;
  display: block;
}
.switch i::after {
  content: '';
  position: absolute;
  top: 2px; left: 2px;
  width: 17px; height: 17px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .45);
  transition: .2s;
}
.switch input:checked + i { background: #7c5cfc; border-color: transparent; }
.switch input:checked + i::after { left: 19px; }

/* état vide */
.empty {
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius);
  padding: 44px 28px;
  text-align: center;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.empty svg { color: var(--accent-2); opacity: .75; margin-bottom: 2px; }
.empty-title { font-size: 17px; font-weight: 700; letter-spacing: -.01em; color: var(--text); }
.empty-text { font-size: 12.5px; max-width: 380px; }

/* barre de progression — piste fine, remplissage net, knob blanc */
.bar {
  height: 6px;
  background: rgba(255, 255, 255, .08);
  border-radius: 999px;
  position: relative;
}
.bar > i {
  display: block;
  height: 100%;
  border-radius: 999px;
  transition: width .7s cubic-bezier(.22, 1, .36, 1);
  position: relative;
  min-width: 6px;
}
.bar > i::after {
  content: '';
  position: absolute;
  right: -1px; top: 50%;
  transform: translateY(-50%);
  width: 14px; height: 14px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .55);
}
.bar.gold > i   { background: #8b6cff; }
.bar.web > i, .bar.mobile > i { background: var(--accent); }

/* anneau de progression */
.ring { position: relative; width: 128px; height: 128px; }
.ring svg { transform: rotate(-90deg); }
.ring .ring-track { stroke: rgba(255, 255, 255, .07); }
.ring .ring-val { transition: stroke-dashoffset 1s cubic-bezier(.22, 1, .36, 1); }
.ring-center {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
}
.ring-pct { font-size: 29px; line-height: 1; font-weight: 800; letter-spacing: -.02em; }
.ring-pct small { font-size: 15px; color: var(--muted); font-weight: 600; }
.ring-label { font-size: 9.5px; letter-spacing: .15em; text-transform: uppercase; color: var(--faint); margin-top: 6px; font-weight: 800; }

/* ── modale ──────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(5, 5, 8, .68);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  display: grid;
  place-items: center;
  z-index: 100;
  padding: 24px;
  animation: fadeIn .18s ease;
  overflow-y: auto;
}

.modal {
  width: 100%;
  max-width: 580px;
  background: var(--card-2);
  border: 1px solid var(--line-strong);
  border-radius: 22px;
  box-shadow: 0 40px 100px -24px rgba(0, 0, 0, .9);
  animation: pop .2s cubic-bezier(.22, 1, .36, 1);
  max-height: calc(100vh - 60px);
  display: flex;
  flex-direction: column;
}
.modal.wide { max-width: 760px; }

@keyframes pop { from { opacity: 0; transform: scale(.97) translateY(8px); } to { opacity: 1; transform: none; } }

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px 0;
}
.modal-title { font-size: 19px; font-weight: 800; letter-spacing: -.02em; }
.modal-body { padding: 18px 22px; overflow-y: auto; }
.modal-foot {
  padding: 14px 22px 18px;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  border-top: 1px solid var(--line);
}

/* ── toasts ──────────────────────────────────────────────── */
#toast-root {
  position: fixed;
  bottom: 24px; right: 24px;
  display: flex; flex-direction: column; gap: 8px;
  z-index: 200;
}
.toast {
  background: var(--card-3);
  border: 1px solid var(--line-strong);
  border-left: 3px solid var(--accent);
  border-radius: 14px;
  padding: 11px 16px;
  font-size: 12.5px;
  font-weight: 600;
  box-shadow: var(--shadow);
  animation: toastIn .25s cubic-bezier(.22, 1, .36, 1);
  max-width: 340px;
  display: flex; align-items: center; gap: 10px;
}
.toast.err { border-left-color: var(--pink); }
@keyframes toastIn { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }
.toast.out { opacity: 0; transform: translateX(16px); transition: .3s; }

/* ═══════════════════════════════════════════════════════════
   VUE D'ENSEMBLE
   ═══════════════════════════════════════════════════════════ */
.hero-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 14px; margin-bottom: 14px; }

.hero-progress { display: flex; align-items: center; gap: 36px; padding: 26px 28px; flex-wrap: wrap; }
.hero-progress .rings { display: flex; gap: 28px; }
.hero-meta { flex: 1; min-width: 200px; display: flex; flex-direction: column; gap: 18px; }

.hero-global-label { display: flex; justify-content: space-between; align-items: baseline; font-size: 12px; color: var(--muted); margin-bottom: 8px; font-weight: 600; }
.hero-global-label b { font-size: 15px; color: var(--text); font-weight: 800; }

.stat-row { display: flex; gap: 28px; flex-wrap: wrap; }
.stat { display: flex; flex-direction: column; gap: 1px; }
.stat b { font-size: 21px; font-weight: 800; letter-spacing: -.02em; }
.stat span { font-size: 10px; color: var(--faint); letter-spacing: .11em; text-transform: uppercase; font-weight: 800; }

.servers-strip { display: flex; flex-direction: column; gap: 8px; padding: 20px; }
.servers-strip-title { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; padding: 0 2px; }
.server-mini {
  display: flex; align-items: center; gap: 11px;
  height: 44px;
  padding: 0 13px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: border-color .15s;
}
.server-mini:hover { border-color: var(--line-strong); }
.server-mini-name { font-weight: 700; font-size: 12.5px; }
.server-mini-role { color: var(--faint); font-size: 11px; margin-left: auto; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding-left: 10px; }

.status-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; position: relative; }
.status-dot.operational { background: var(--mobile); box-shadow: 0 0 8px var(--mobile); }
.status-dot.operational::after {
  content: ''; position: absolute; inset: -4px;
  border-radius: 50%; border: 1px solid var(--mobile);
  animation: pulse 2.4s ease-out infinite;
}
.status-dot.maintenance { background: var(--yellow); box-shadow: 0 0 8px var(--yellow); }
.status-dot.issue { background: var(--pink); box-shadow: 0 0 8px var(--pink); }
@keyframes pulse { 0% { opacity: .7; transform: scale(.6); } 100% { opacity: 0; transform: scale(1.5); } }

.dash-grid { display: grid; grid-template-columns: 1.7fr 1fr; gap: 14px; align-items: start; }

.section-title {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px var(--pad-card) 4px;
}
.section-title h2 { font-size: 16px; font-weight: 800; letter-spacing: -.01em; }

/* lignes de fonctionnalités */
.feat-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 16px;
  padding: 14px var(--pad-card);
  border-top: 1px solid var(--line);
  cursor: pointer;
  transition: background .15s;
  align-items: center;
}
.feat-row:hover { background: rgba(255, 255, 255, .025); }
.feat-name { font-weight: 700; font-size: 13.5px; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.feat-desc { grid-column: 1; color: var(--muted); font-size: 12px; }
.feat-bars { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 12px; margin-top: 10px; padding-right: 4px; }
.feat-bar-line { display: grid; grid-template-columns: 48px 1fr 38px; align-items: center; gap: 12px; }
.feat-bar-label { font-size: 9.5px; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; color: var(--faint); }
.feat-bar-pct { font-family: var(--font-mono); font-size: 11px; color: var(--muted); text-align: right; }
.feat-status { justify-self: end; }

/* fil d'activité */
.feed { display: flex; flex-direction: column; padding: 10px 0 14px; }
.feed-item {
  display: flex; gap: 12px;
  padding: 9px var(--pad-card);
  position: relative;
}
.feed-item::before {
  content: '';
  position: absolute;
  left: 32px; top: 34px; bottom: -5px;
  width: 1px;
  background: var(--line);
}
.feed-item:last-child::before { display: none; }
.feed-ico {
  width: 21px; height: 21px;
  border-radius: 7px;
  display: grid; place-items: center;
  flex-shrink: 0;
  margin-top: 1px;
  position: relative; z-index: 1;
}
.feed-ico.note    { background: var(--yellow-soft); color: var(--yellow); }
.feed-ico.agent   { background: var(--accent-soft); color: var(--accent-2); }
.feed-ico.media   { background: var(--web-soft); color: var(--web); }
.feed-ico.feature { background: var(--mobile-soft); color: var(--mobile); }
.feed-ico.server, .feed-ico.doc { background: rgba(255, 255, 255, .06); color: var(--muted); }
.feed-label { font-size: 12.5px; line-height: 1.45; }
.feed-meta { font-size: 10.5px; color: var(--faint); margin-top: 1px; }

/* ═══════════════════════════════════════════════════════════
   JOURNAL
   ═══════════════════════════════════════════════════════════ */
.toolbar {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 16px; flex-wrap: wrap;
}
.toolbar .spacer { flex: 1; }

.search-box { position: relative; }
.search-box svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--faint); pointer-events: none; }
.search-box .input { padding-left: 38px; width: 230px; border-radius: 999px; }

/* barre segmentée — conteneur sombre, pilule active teintée */
.filter-pills {
  display: inline-flex; gap: 3px; flex-wrap: wrap;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px;
  height: calc(var(--ctl) - 0px);
}
.pill {
  height: calc(var(--ctl) - 10px);
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font-size: 12px; font-weight: 600;
  cursor: pointer;
  transition: .15s;
  display: inline-flex; align-items: center;
}
.pill:hover { color: var(--text); }
.pill.active {
  background: var(--accent-fill);
  border-color: var(--accent-line);
  color: #fff;
}

.notes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 14px;
}

.note-card {
  padding: 18px 20px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}
.note-card::before {
  content: '';
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: var(--cat-color, var(--line-strong));
  opacity: .9;
}
.note-card[data-pinned="1"] { border-color: rgba(247, 201, 72, .35); }
.note-top { display: flex; align-items: center; gap: 8px; }
.note-pin { margin-left: auto; color: var(--yellow); display: inline-flex; }
.note-title { font-size: 16px; font-weight: 700; letter-spacing: -.015em; line-height: 1.35; }
.note-excerpt {
  color: var(--muted); font-size: 12.5px;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical;
  overflow: hidden;
}
.note-foot {
  display: flex; align-items: center; gap: 8px;
  margin: 6px -20px 0;
  padding: 10px 20px;
  border-top: 1px solid var(--line);
  font-size: 10.5px; color: var(--faint); font-weight: 600;
}
.note-foot .chip { margin-left: auto; }

/* rendu markdown */
.md { font-size: 13.5px; line-height: 1.7; color: var(--text); }
.md h1, .md h2, .md h3 { font-weight: 800; letter-spacing: -.015em; margin: 20px 0 8px; line-height: 1.3; }
.md h1 { font-size: 20px; } .md h2 { font-size: 16.5px; } .md h3 { font-size: 14px; }
.md h1:first-child, .md h2:first-child, .md h3:first-child { margin-top: 0; }
.md p { margin: 8px 0; color: #cfcfd6; }
.md ul, .md ol { margin: 8px 0 8px 20px; color: #cfcfd6; }
.md li { margin: 4px 0; }
.md strong { color: var(--text); font-weight: 700; }
.md em { color: var(--accent-2); }
.md code {
  font-family: var(--font-mono); font-size: 11.5px;
  background: var(--bg-soft); border: 1px solid var(--line);
  border-radius: 6px; padding: 1.5px 6px;
  color: #c4b5fd;
}
.md pre {
  background: var(--bg-soft); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 14px 16px;
  overflow-x: auto; margin: 12px 0;
}
.md pre code { background: none; border: none; padding: 0; color: #8fe3d0; font-size: 12px; line-height: 1.65; }
.md blockquote {
  border-left: 3px solid var(--accent-line);
  padding: 3px 0 3px 14px; margin: 12px 0;
  color: var(--muted); font-style: italic;
}
.md table { border-collapse: collapse; margin: 12px 0; width: 100%; font-size: 12.5px; }
.md th, .md td { border: 1px solid var(--line); padding: 8px 12px; text-align: left; }
.md th { background: var(--bg-soft); font-weight: 800; font-size: 9.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.md hr { border: none; border-top: 1px solid var(--line); margin: 18px 0; }

/* ═══════════════════════════════════════════════════════════
   REGISTRE DES AGENTS
   ═══════════════════════════════════════════════════════════ */
.protocol {
  padding: 20px var(--pad-card);
  margin-bottom: 16px;
  position: relative;
}
.protocol-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.protocol-head h2 { font-size: 16px; font-weight: 800; letter-spacing: -.01em; }
.protocol-steps {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px;
  margin: 16px 0;
}
.pstep { background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 14px 16px; }
.pstep b { display: flex; align-items: center; gap: 8px; font-size: 12.5px; margin-bottom: 5px; font-weight: 700; }
.pstep b .num {
  width: 20px; height: 20px; border-radius: 7px;
  background: var(--accent-fill); color: var(--accent-2);
  border: 1px solid var(--accent-line);
  display: grid; place-items: center;
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 700;
}
.pstep p { font-size: 11.5px; color: var(--muted); line-height: 1.55; }
.pstep code { font-family: var(--font-mono); font-size: 10.5px; color: #c4b5fd; }

.code-block {
  background: #0b0b0e;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 15px 17px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  line-height: 1.7;
  color: #b6b6c0;
  overflow-x: auto;
  position: relative;
  white-space: pre;
}
.code-block .c { color: #55555f; }
.code-block .k { color: #c4b5fd; }
.code-block .u { color: #6fc6ff; }
.code-copy { position: absolute; top: 10px; right: 10px; background: rgba(22, 22, 28, .85); }

/* timeline du registre */
.timeline { position: relative; padding: 4px 0; }
.log-entry {
  display: flex; gap: 15px;
  padding: 16px var(--pad-card);
  border-top: 1px solid var(--line);
  position: relative;
}
.log-rail { display: flex; flex-direction: column; align-items: center; flex-shrink: 0; width: 12px; padding-top: 5px; }
.log-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 8px currentColor; color: var(--accent); }
.log-dot.web { background: var(--web); color: var(--web); }
.log-dot.mobile { background: var(--mobile); color: var(--mobile); }
.log-dot.shared { background: var(--accent); color: var(--accent); }
.log-line { width: 1px; flex: 1; background: var(--line); margin-top: 7px; }

.log-body { flex: 1; min-width: 0; }
.log-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.log-agent {
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 600;
  color: #cabcff;
  background: var(--accent-fill);
  border: 1px solid rgba(139, 108, 255, .45);
  padding: 3px 10px; border-radius: 999px;
}
.log-time { margin-left: auto; font-size: 10.5px; color: var(--faint); white-space: nowrap; }
.log-summary { font-weight: 700; font-size: 13.5px; margin-top: 8px; line-height: 1.5; }
.log-reason { color: var(--muted); font-size: 12.5px; margin-top: 4px; line-height: 1.55; }
.log-reason b { color: var(--accent-2); font-weight: 800; }
.log-files { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 9px; }
.log-file {
  font-family: var(--font-mono); font-size: 10.5px;
  background: var(--bg-soft); border: 1px solid var(--line);
  padding: 3px 9px; border-radius: 8px; color: var(--muted);
}
.log-details-toggle {
  margin-top: 9px;
  background: none; border: none; cursor: pointer;
  color: var(--accent-2); font-size: 11.5px; font-weight: 700;
  padding: 0;
}
.log-details-toggle:hover { color: #fff; }
.log-details { margin-top: 8px; }
.log-del { position: absolute; top: 14px; right: 14px; opacity: 0; transition: opacity .15s; }
.log-entry:hover .log-del { opacity: 1; }

/* ═══════════════════════════════════════════════════════════
   ARCHITECTURE
   ═══════════════════════════════════════════════════════════ */
.topo { padding: 26px; margin-bottom: 14px; overflow-x: auto; }
.topo svg { display: block; margin: 0 auto; min-width: 640px; }

.archi-grid { display: grid; grid-template-columns: 272px 1fr; gap: 14px; align-items: start; }
.doc-list { display: flex; flex-direction: column; padding: 10px; gap: 2px; }
.doc-list-head { padding: 6px 8px 12px; display: flex; flex-direction: column; gap: 10px; }
.doc-list-head .doc-new { width: 100%; }
.doc-item {
  padding: 11px 12px;
  border-radius: var(--radius-xs);
  cursor: pointer;
  border: 1px solid transparent;
  transition: .15s;
}
.doc-item:hover { background: rgba(255, 255, 255, .04); }
.doc-item.active { background: var(--accent-fill); border-color: var(--accent-line); }
.doc-item.active .doc-item-title { color: #fff; }
.doc-item-title { font-weight: 600; font-size: 12.5px; line-height: 1.35; }
.doc-item-meta { font-size: 10px; color: var(--faint); margin-top: 3px; }
.doc-view { padding: 26px 30px; min-height: 420px; }
.doc-view-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; flex-wrap: wrap; }
.doc-view-head h2 { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
.doc-meta { font-size: 11px; color: var(--faint); margin-top: 3px; }

.edit-tabs { display: inline-flex; gap: 3px; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 999px; padding: 3px; }
.edit-tab { border: 1px solid transparent; background: none; color: var(--muted); font-size: 11.5px; font-weight: 600; height: 28px; padding: 0 13px; border-radius: 999px; cursor: pointer; transition: .15s; display: inline-flex; align-items: center; }
.edit-tab.active { background: var(--accent-fill); border-color: var(--accent-line); color: #fff; }

/* ═══════════════════════════════════════════════════════════
   MÉDIAS
   ═══════════════════════════════════════════════════════════ */
.dropzone {
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius);
  padding: 34px 24px;
  text-align: center;
  cursor: pointer;
  transition: .2s;
  margin-bottom: 16px;
  color: var(--muted);
}
.dropzone:hover, .dropzone.over {
  border-color: var(--accent-line);
  background: var(--accent-soft);
  color: var(--text);
}
.dropzone svg { color: var(--accent-2); margin-bottom: 8px; }
.dropzone b { color: var(--text); font-weight: 700; }
.dropzone small { display: block; margin-top: 4px; font-size: 11px; color: var(--faint); }

.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 14px;
}
.media-card { overflow: hidden; cursor: pointer; padding: 0; }
.media-thumb {
  aspect-ratio: 4 / 3;
  background: var(--bg-soft);
  position: relative;
  overflow: hidden;
}
.media-thumb img, .media-thumb video {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .4s ease;
  display: block;
}
.media-card:hover .media-thumb img,
.media-card:hover .media-thumb video { transform: scale(1.035); }
.media-badge {
  position: absolute; top: 10px; left: 10px;
  background: rgba(8, 8, 11, .74);
  backdrop-filter: blur(6px);
  border-radius: 999px; padding: 4px 11px;
  font-size: 9px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  display: flex; align-items: center; gap: 5px;
  border: 1px solid var(--line-strong);
}
.media-info { padding: 12px 15px; }
.media-title { font-weight: 700; font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.media-meta { display: flex; align-items: center; justify-content: space-between; margin-top: 5px; font-size: 10.5px; color: var(--faint); }

/* visionneuse */
.lightbox { max-width: 900px; }
.lightbox-media { background: #08080b; border-radius: 14px; overflow: hidden; display: grid; place-items: center; margin-bottom: 16px; }
.lightbox-media img { max-width: 100%; max-height: 62vh; display: block; }
.lightbox-media video { max-width: 100%; max-height: 62vh; width: 100%; }

/* ═══════════════════════════════════════════════════════════
   SERVEURS
   ═══════════════════════════════════════════════════════════ */
.servers-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.server-card { padding: var(--pad-card); display: flex; flex-direction: column; gap: 13px; position: relative; }
.server-head { display: flex; align-items: flex-start; gap: 12px; padding-right: 34px; }
.server-ico {
  width: 40px; height: 40px;
  border-radius: 12px;
  background: var(--accent-fill);
  border: 1px solid rgba(139, 108, 255, .4);
  display: grid; place-items: center;
  color: var(--accent-2);
  flex-shrink: 0;
}
.server-name { font-size: 17px; font-weight: 800; letter-spacing: -.015em; }
.server-role { color: var(--muted); font-size: 11.5px; margin-top: 2px; }
.server-host {
  font-family: var(--font-mono); font-size: 10.5px; color: var(--muted);
  background: var(--bg-soft); border: 1px solid var(--line);
  height: 26px; padding: 0 11px; border-radius: 999px;
  display: inline-flex; align-items: center; align-self: flex-start;
}
.server-desc { color: var(--muted); font-size: 12.5px; line-height: 1.6; }
.server-logs { border-top: 1px solid var(--line); margin-top: 2px; padding-top: 12px; }
.server-logs-title { font-size: 9.5px; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; color: var(--faint); margin-bottom: 6px; }
.server-log-line { font-size: 11.5px; color: var(--muted); padding: 4px 0; display: flex; gap: 8px; align-items: baseline; min-width: 0; }
.server-log-line b { color: var(--text); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.server-log-line .mono { color: var(--faint); font-size: 10px; flex-shrink: 0; }

/* ═══════════════════════════════════════════════════════════
   PARAMÈTRES
   ═══════════════════════════════════════════════════════════ */
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
.settings-card { padding: var(--pad-card); }
.settings-card h2 { font-size: 16px; font-weight: 800; letter-spacing: -.01em; margin-bottom: 16px; }

.key-row {
  display: flex; align-items: center; gap: 9px;
  padding: 10px 12px;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  margin-bottom: 7px;
  min-width: 0;
}
.key-name { font-weight: 700; font-size: 12.5px; flex-shrink: 0; }
.key-val {
  font-family: var(--font-mono); font-size: 10px; color: var(--muted);
  flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 40px;
}
.key-meta { font-size: 10px; color: var(--faint); white-space: nowrap; flex-shrink: 0; }

.swatches { display: flex; gap: 9px; flex-wrap: wrap; }
.swatch {
  width: 26px; height: 26px; border-radius: 50%;
  cursor: pointer; border: 2px solid transparent;
  transition: .15s;
}
.swatch.active { border-color: #fff; transform: scale(1.12); }

/* ═══════════════════════════════════════════════════════════
   ACCUEIL DU QG — cinq clients, une lecture simple
   ═══════════════════════════════════════════════════════════ */
.main { max-width: 1480px; }
.sidebar { overflow-y: auto; }
.nav-sep:first-of-type { margin-top: 2px; }
.nav-item { min-height: 38px; height: 38px; }
.btn, .client-snapshot, .shared-strip a, .compact-row, .attention-row, .text-link { text-decoration: none; }
.btn:hover, .client-snapshot:hover, .shared-strip a:hover, .compact-row:hover, .attention-row:hover, .text-link:hover { text-decoration: none; }

.home-head { margin-bottom: 20px; }
.home-hero {
  min-height: 312px;
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(330px, .75fr);
  gap: 20px;
  align-items: stretch;
  padding: 28px;
  margin-bottom: 14px;
  border: 1px solid rgba(179, 161, 255, .24);
  border-radius: 26px;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(520px 260px at 18% 22%, rgba(139, 108, 255, .2), transparent 68%),
    radial-gradient(380px 260px at 70% 110%, rgba(60, 224, 192, .07), transparent 70%),
    linear-gradient(145deg, rgba(31, 28, 48, .94), rgba(17, 17, 22, .97) 62%);
  box-shadow: 0 30px 90px -48px rgba(139, 108, 255, .55), inset 0 1px 0 rgba(255, 255, 255, .04);
}
.home-hero::before {
  content: '';
  position: absolute;
  width: 280px; height: 280px;
  left: -90px; bottom: -205px;
  border-radius: 50%;
  border: 42px solid rgba(179, 161, 255, .055);
  box-shadow: 0 0 0 42px rgba(179, 161, 255, .025), 0 0 0 84px rgba(179, 161, 255, .012);
  pointer-events: none;
}
.home-hero-copy {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 10px 4px 12px 8px;
}
.hero-pill {
  align-self: flex-start;
  height: 27px;
  display: inline-flex;
  align-items: center;
  padding: 0 11px;
  margin-bottom: 20px;
  border: 1px solid rgba(179, 161, 255, .32);
  background: rgba(139, 108, 255, .1);
  color: var(--accent-2);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: .14em;
}
.home-hero-copy h2 {
  font-size: clamp(31px, 3.1vw, 48px);
  line-height: 1.04;
  letter-spacing: -.045em;
  font-weight: 800;
}
.home-hero-copy h2 em { color: var(--accent-2); font-style: normal; }
.home-hero-copy p {
  max-width: 650px;
  margin-top: 18px;
  color: #b8b8c2;
  font-size: 14px;
  line-height: 1.72;
}

.attention-card {
  position: relative;
  z-index: 1;
  padding: 20px;
  background: rgba(12, 12, 16, .55);
  backdrop-filter: blur(16px);
  border-color: rgba(255, 255, 255, .1);
  display: flex;
  flex-direction: column;
}
.section-kicker {
  color: var(--faint);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .16em;
  text-transform: uppercase;
}
.attention-list { display: flex; flex-direction: column; margin: 12px 0; }
.attention-row {
  min-height: 54px;
  display: grid;
  grid-template-columns: 37px 1fr 20px;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}
.attention-row:last-child { border-bottom: none; }
.attention-row b { font-size: 24px; color: var(--text); letter-spacing: -.04em; }
.attention-row span { font-size: 12px; font-weight: 600; }
.attention-row i { justify-self: end; color: var(--faint); transition: transform .15s, color .15s; }
.attention-row:hover i { transform: translateX(3px); color: var(--text); }
.attention-row.violet b { color: var(--accent-2); }
.attention-row.coral b { color: #ff9677; }
.attention-row.teal b { color: var(--ios); }
.quiet-copy { color: var(--faint); font-size: 10.5px; line-height: 1.55; margin-top: auto; }

.clients-snapshot {
  display: grid;
  grid-template-columns: repeat(5, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.client-snapshot {
  min-width: 0;
  min-height: 194px;
  padding: 16px;
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(155deg, color-mix(in srgb, var(--platform-color) 6%, var(--card)), var(--card));
  position: relative;
  overflow: hidden;
  transition: transform .18s, border-color .18s, background .18s;
}
.client-snapshot::after {
  content: '';
  position: absolute;
  left: 14px; right: 14px; top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--platform-color), transparent);
  opacity: .55;
}
.client-snapshot:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--platform-color) 42%, transparent); }
.client-snapshot.planned { opacity: .72; filter: saturate(.65); }
.client-snapshot-top { display: flex; align-items: center; justify-content: space-between; }
.client-mark {
  width: 30px; height: 30px;
  display: grid; place-items: center;
  border-radius: 10px;
  color: var(--platform-color);
  background: color-mix(in srgb, var(--platform-color) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--platform-color) 30%, transparent);
  font-size: 12px; font-weight: 800;
}
.micro-state {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 8.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .1em;
}
.micro-state::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 8px currentColor; }
.micro-state.good { color: var(--ios); }
.micro-state.warn { color: var(--yellow); }
.micro-state.planned, .micro-state.quiet { color: var(--faint); }
.client-snapshot-name { font-size: 19px; font-weight: 800; letter-spacing: -.025em; margin-top: 18px; }
.client-snapshot-owner { color: var(--muted); font-size: 11px; margin-top: 1px; }
.client-snapshot-source {
  color: var(--faint);
  font-size: 9.5px;
  line-height: 1.5;
  margin-top: 12px;
  min-height: 30px;
  overflow-wrap: anywhere;
}
.client-snapshot-foot {
  display: flex;
  gap: 8px;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid var(--line);
  margin-top: 12px;
  padding-top: 10px;
  font-size: 9.5px;
  color: var(--faint);
}
.client-snapshot-foot b { color: var(--muted); font-weight: 700; }

.shared-strip {
  display: grid;
  grid-template-columns: 1.35fr repeat(6, minmax(100px, 1fr));
  gap: 1px;
  padding: 1px;
  margin-bottom: 14px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--line);
}
.shared-strip > a { min-width: 0; min-height: 62px; background: var(--card); color: var(--text); transition: background .15s; }
.shared-strip > a:hover { background: var(--card-2); }
.shared-strip-intro { display: flex; align-items: center; gap: 11px; padding: 12px 16px; color: var(--accent-2) !important; }
.shared-strip-intro > span { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 10px; background: var(--accent-soft); border: 1px solid var(--accent-line); }
.shared-strip b { display: block; font-size: 11.5px; }
.shared-strip small { display: block; color: var(--faint); font-size: 9.5px; margin-top: 2px; line-height: 1.35; }
.shared-service-mini { display: flex; align-items: center; gap: 9px; padding: 10px 12px; }
.shared-service-mini .micro-state { font-size: 0; }
.shared-service-mini .micro-state::before { width: 7px; height: 7px; }

.home-main-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(330px, .75fr); gap: 14px; align-items: start; }
.home-side-stack { display: grid; gap: 14px; }
.home-panel { overflow: hidden; }
.home-panel .section-title { padding: 18px 20px 14px; border-bottom: 1px solid var(--line); }
.home-panel .section-title > div { display: flex; flex-direction: column; gap: 3px; }
.home-panel .section-title h2 { font-size: 15px; }
.text-link { color: var(--muted); font-size: 10.5px; font-weight: 700; }
.text-link:hover { color: var(--text); }
.compact-list { display: flex; flex-direction: column; }
.compact-row {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 62px;
  padding: 11px 18px;
  color: var(--text);
  border-bottom: 1px solid var(--line);
  transition: background .15s;
}
.compact-row:last-child { border-bottom: none; }
.compact-row:hover { background: rgba(255, 255, 255, .025); }
.compact-row-main { min-width: 0; flex: 1; }
.compact-row-title { font-size: 12px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.compact-row-meta { color: var(--faint); font-size: 9.5px; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.panel-empty { min-height: 110px; padding: 22px; display: flex; flex-direction: column; justify-content: center; gap: 4px; }
.panel-empty b { font-size: 12.5px; }
.panel-empty span { color: var(--muted); font-size: 11px; line-height: 1.5; }

.feature-matrix { overflow-x: auto; }
.feature-matrix-head, .feature-matrix-row {
  min-width: 620px;
  display: grid;
  grid-template-columns: minmax(230px, 1fr) 150px 150px;
  gap: 14px;
  align-items: center;
  padding: 11px 20px;
}
.feature-matrix-head {
  min-height: 38px;
  color: var(--faint);
  background: rgba(255, 255, 255, .018);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .13em;
  text-transform: uppercase;
}
.feature-matrix-row { min-height: 61px; border-top: 1px solid var(--line); }
.feature-matrix-row > div { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.feature-matrix-row > div b { font-size: 12px; }
.feature-matrix-row > div small { color: var(--faint); font-size: 9.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.matrix-progress { display: flex; align-items: center; gap: 8px; }
.matrix-progress > b { color: var(--muted); font-size: 9.5px; }
.matrix-state {
  width: fit-content;
  padding: 4px 8px;
  border-radius: 999px;
  color: var(--accent-2);
  background: var(--accent-soft);
  font-size: 9px;
  font-weight: 700;
}
.matrix-state.planned { color: var(--faint); background: rgba(255, 255, 255, .035); }
.matrix-more { display: block; padding: 11px 20px; border-top: 1px solid var(--line); color: var(--accent-2); font-size: 10.5px; font-weight: 700; }
.feed-ico.diff { background: var(--accent-soft); color: var(--accent-2); }
.feed-ico.service { background: var(--yellow-soft); color: var(--yellow); }

/* ── repères communs aux pages ───────────────────────────── */
.page-intro { color: var(--muted); font-size: 12px; margin-top: 7px; max-width: 640px; }
.modal-intro { color: var(--muted); font-size: 12px; line-height: 1.65; margin-bottom: 16px; }
.detail-chips { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-bottom: 18px; }
.detail-byline { color: var(--faint); font-size: 10.5px; margin-top: 20px; }
.feature-tag, .vps-tag, .resolved-tag, .priority-mark {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 3px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: rgba(255, 255, 255, .035);
  font-size: 9.5px;
  font-weight: 700;
  line-height: 1.25;
}
.priority-mark { color: #ff9c7e; border-color: rgba(255, 138, 101, .3); background: rgba(255, 138, 101, .08); }
.resolved-tag { color: var(--ios); border-color: var(--ios-line); background: var(--ios-soft); }
.switch-line { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 12px; cursor: pointer; }
.toolbar .select { width: auto; min-width: 150px; }

/* ── journal organisé ────────────────────────────────────── */
.journal-guide, .vps-boundary {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 54px;
  padding: 12px 16px;
  margin-bottom: 14px;
  color: var(--muted);
  background: linear-gradient(90deg, var(--accent-soft), rgba(139, 108, 255, .025));
  border: 1px solid rgba(139, 108, 255, .24);
  border-radius: var(--radius-sm);
}
.journal-guide > span, .vps-boundary > span { color: var(--accent-2); flex-shrink: 0; }
.journal-guide p, .vps-boundary p { font-size: 11.5px; line-height: 1.55; }
.journal-guide b, .vps-boundary b { color: var(--text); }
.journal-toolbar { align-items: flex-start; }
.journal-toolbar .filter-pills { height: auto; min-height: var(--ctl); }
.memory-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(285px, 1fr)); gap: 12px; }
.memory-card {
  min-height: 235px;
  padding: 17px 18px 0;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  cursor: pointer;
}
.memory-card::before { content: ''; position: absolute; left: 0; top: 16px; bottom: 16px; width: 2px; background: var(--cat-color); }
.memory-card.closed { opacity: .68; }
.memory-card-head { display: flex; align-items: center; gap: 7px; }
.memory-card-head .note-pin { margin-left: auto; }
.memory-card h3 { font-size: 15.5px; line-height: 1.38; letter-spacing: -.015em; margin-top: 14px; }
.memory-card > p {
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.62;
  margin-top: 7px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.memory-tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.memory-card footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin: auto -18px 0;
  padding: 10px 18px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 9.5px;
}
.memory-detail { min-height: 110px; padding: 4px 1px; }

/* ── registre agents : observation versus intervention ───── */
.agent-protocol {
  display: grid;
  grid-template-columns: minmax(260px, .9fr) minmax(360px, 1.2fr);
  gap: 18px 24px;
  padding: 22px;
  margin-bottom: 14px;
  border: 1px solid rgba(139, 108, 255, .25);
  border-radius: 22px;
  background:
    radial-gradient(360px 180px at 0 0, rgba(139, 108, 255, .13), transparent 75%),
    var(--card);
}
.agent-protocol-copy h2 { font-size: 22px; line-height: 1.18; letter-spacing: -.025em; }
.agent-protocol-copy h2 em { color: var(--accent-2); font-style: normal; }
.agent-protocol-copy p { color: var(--muted); font-size: 11.5px; line-height: 1.65; margin-top: 10px; }
.agent-protocol-copy .hero-pill { margin-bottom: 12px; }
.agent-rules { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.agent-rules > div { min-height: 102px; padding: 12px; border: 1px solid var(--line); border-radius: 13px; background: var(--bg-soft); }
.agent-rules b { width: 22px; height: 22px; display: grid; place-items: center; border-radius: 7px; color: var(--accent-2); background: var(--accent-soft); font-family: var(--font-mono); font-size: 10px; }
.agent-rules span { display: block; color: var(--muted); font-size: 10.5px; line-height: 1.5; margin-top: 9px; }
.agent-protocol-actions { grid-column: 1 / -1; display: flex; justify-content: flex-end; gap: 8px; border-top: 1px solid var(--line); padding-top: 14px; flex-wrap: wrap; }
.mode-hint {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 10px 13px;
  margin-bottom: 14px;
  border-radius: 12px;
  font-size: 11.5px;
  line-height: 1.5;
}
.mode-hint svg { flex-shrink: 0; }
.mode-hint.read { color: var(--ios); background: var(--ios-soft); border: 1px solid var(--ios-line); }
.mode-hint.write { color: var(--accent-2); background: var(--accent-soft); border: 1px solid var(--accent-line); }
.mode-hint span { color: var(--muted); }
.mode-hint b { color: currentColor; }
.agent-toolbar { align-items: flex-start; }
.agent-ledger { overflow: hidden; }
.ledger-head { display: flex; align-items: center; justify-content: space-between; min-height: 52px; padding: 0 20px; border-bottom: 1px solid var(--line); }
.ledger-head span { font-size: 14px; font-weight: 800; }
.ledger-head b { color: var(--faint); font-size: 9.5px; text-transform: uppercase; letter-spacing: .11em; }
.agent-entry { display: grid; grid-template-columns: 28px 1fr; gap: 10px; padding: 18px 20px; border-bottom: 1px solid var(--line); }
.agent-entry:last-child { border-bottom: none; }
.agent-entry-rail { display: flex; flex-direction: column; align-items: center; color: var(--accent-2); }
.agent-entry.observation .agent-entry-rail { color: var(--ios); }
.agent-entry-rail > span { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 9px; background: currentColor; }
.agent-entry-rail > span svg { color: #0d0d10; }
.agent-entry-rail i { width: 1px; min-height: 30px; flex: 1; margin-top: 8px; background: var(--line); }
.agent-entry-body { min-width: 0; }
.agent-entry-body header { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.agent-entry-body time { margin-left: auto; color: var(--faint); font-size: 9.5px; }
.entry-kind, .agent-name {
  display: inline-flex; align-items: center; min-height: 22px; padding: 3px 8px;
  border-radius: 999px; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .07em;
}
.entry-kind.read { color: var(--ios); background: var(--ios-soft); border: 1px solid var(--ios-line); }
.entry-kind.write { color: var(--accent-2); background: var(--accent-soft); border: 1px solid var(--accent-line); }
.agent-name { color: var(--muted); background: rgba(255, 255, 255, .035); border: 1px solid var(--line); font-family: var(--font-mono); text-transform: none; }
.agent-entry h3 { font-size: 14px; line-height: 1.45; margin-top: 10px; }
.entry-reason { color: var(--muted); font-size: 11.5px; line-height: 1.6; margin-top: 5px; }
.entry-reason b { color: var(--text); }
.entry-source { display: flex; align-items: center; gap: 7px; color: var(--faint); font-size: 9.5px; margin-top: 10px; overflow-wrap: anywhere; }
.entry-files { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 9px; }
.entry-files span { padding: 4px 7px; border-radius: 7px; background: var(--bg-soft); border: 1px solid var(--line); color: var(--muted); font: 9.5px var(--font-mono); }
.entry-details { margin-top: 10px; }
.entry-details summary { width: fit-content; color: var(--accent-2); cursor: pointer; font-size: 10.5px; font-weight: 700; }
.entry-details .md { margin-top: 9px; padding: 11px 13px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg-soft); }

/* ── médiathèque par feature ─────────────────────────────── */
.media-dropzone { display: flex; align-items: center; gap: 14px; text-align: left; padding: 22px; }
.media-dropzone .dropzone-icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 13px; background: var(--accent-soft); border: 1px solid var(--accent-line); flex-shrink: 0; }
.media-dropzone svg { margin: 0; }
.media-dropzone div { flex: 1; }
.media-dropzone div span { color: var(--muted); font-size: 11.5px; }
.media-dropzone small { margin: 0; text-align: right; max-width: 230px; }
.media-library { display: flex; flex-direction: column; gap: 24px; }
.media-feature-group > header { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin: 0 3px 9px; }
.media-feature-group > header h2 { font-size: 16px; margin-top: 3px; }
.media-feature-group > header > span { color: var(--faint); font-size: 10px; }
.media-caption { color: var(--muted); font-size: 10.5px; line-height: 1.45; margin-top: 4px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.upload-file-list { max-height: 150px; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; padding: 8px; margin-bottom: 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--bg-soft); }
.upload-file-list > div { display: grid; grid-template-columns: 20px 1fr auto; align-items: center; gap: 7px; min-width: 0; padding: 5px 6px; }
.upload-file-list span { color: var(--accent-2); }
.upload-file-list b { font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.upload-file-list small { color: var(--faint); font-size: 9px; }

/* ── architecture sans ambiguïté sur le QG ───────────────── */
.topology-card { padding: 20px; margin-bottom: 14px; overflow: hidden; }
.topology-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; padding: 2px 2px 16px; border-bottom: 1px solid var(--line); }
.topology-head h2 { font-size: 17px; margin-top: 3px; }
.topology-head > span { color: var(--faint); font-size: 10.5px; max-width: 410px; text-align: right; }
.topology-flow { display: grid; grid-template-columns: minmax(220px, 1fr) 30px minmax(240px, .95fr) 30px minmax(230px, 1fr); gap: 10px; align-items: stretch; padding: 18px 0; }
.topology-column { min-width: 0; padding: 13px; background: var(--bg-soft); border: 1px solid var(--line); border-radius: 15px; }
.topology-column > label { display: block; margin-bottom: 10px; color: var(--faint); font-size: 8.5px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.topology-arrow { display: grid; place-items: center; color: var(--accent-2); font-size: 21px; }
.topology-client-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.topology-client { min-height: 52px; padding: 9px 10px; border: 1px solid rgba(179, 161, 255, .18); border-radius: 11px; background: rgba(139, 108, 255, .055); }
.topology-client b, .topology-client small { display: block; }
.topology-client b { color: var(--text); font-size: 11px; }
.topology-client small { color: var(--faint); font-size: 8.5px; margin-top: 2px; }
.topology-client.planned { opacity: .55; }
.topology-core { min-height: 154px; display: flex; flex-direction: column; justify-content: center; padding: 14px; border-radius: 12px; background: linear-gradient(145deg, var(--accent-soft), rgba(139, 108, 255, .025)); border: 1px solid var(--accent-line); }
.topology-core > b { font-size: 13px; }
.topology-core p { color: var(--muted); font-size: 10.5px; line-height: 1.55; margin-top: 6px; }
.topology-core > div { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 12px; }
.topology-core > div span { padding: 4px 8px; border-radius: 999px; color: var(--accent-2); background: rgba(13, 13, 16, .5); border: 1px solid var(--line); font-size: 9px; font-weight: 700; }
.topology-server-list { display: flex; flex-direction: column; gap: 6px; }
.topology-server-list > div { min-height: 48px; display: grid; grid-template-columns: 10px 65px 1fr; align-items: center; gap: 7px; padding: 8px 9px; border: 1px solid var(--line); border-radius: 10px; background: var(--card); }
.topology-server-list b { font: 10px var(--font-mono); }
.topology-server-list small { color: var(--faint); font-size: 8.5px; line-height: 1.35; }
.control-plane-band { display: grid; grid-template-columns: 38px 1fr auto; align-items: center; gap: 12px; padding: 15px 17px; border: 1px solid var(--accent-line); border-radius: 14px; background: linear-gradient(90deg, var(--accent-soft), rgba(139, 108, 255, .02)); }
.control-plane-mark { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 11px; color: var(--accent-2); background: rgba(139, 108, 255, .12); border: 1px solid var(--accent-line); }
.control-plane-band b { display: block; font-size: 12.5px; margin-top: 2px; }
.control-plane-band p { color: var(--muted); font-size: 10px; line-height: 1.45; margin-top: 2px; }
.no-traffic { padding: 5px 9px; border-radius: 999px; color: var(--accent-2); border: 1px solid var(--accent-line); font: 8px var(--font-mono); letter-spacing: .08em; }

/* ── VPS ─────────────────────────────────────────────────── */
.vps-boundary { margin-bottom: 14px; }
.server-card.control-server { border-color: rgba(139, 108, 255, .3); background: linear-gradient(150deg, rgba(139, 108, 255, .07), var(--card) 48%); }
.server-plane { margin-left: auto; align-self: flex-start; min-height: 20px; display: inline-flex; align-items: center; padding: 2px 7px; border-radius: 999px; font-size: 8px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.server-plane.product { color: var(--ios); background: var(--ios-soft); border: 1px solid var(--ios-line); }
.server-plane.control { color: var(--accent-2); background: var(--accent-soft); border: 1px solid var(--accent-line); }

/* pied de page discret */
.foot {
  margin-top: 56px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  display: flex; justify-content: space-between; gap: 12px;
  color: var(--faint); font-size: 10.5px; letter-spacing: .04em;
}

/* ── responsive ──────────────────────────────────────────── */
@media (max-width: 1080px) {
  .hero-grid, .dash-grid, .settings-grid, .home-main-grid { grid-template-columns: 1fr; }
  .home-hero { grid-template-columns: 1.2fr .8fr; }
  .clients-snapshot { grid-template-columns: repeat(3, 1fr); }
  .shared-strip { grid-template-columns: repeat(3, 1fr); }
  .shared-strip-intro { grid-column: 1 / -1; }
  .protocol-steps { grid-template-columns: 1fr; }
  .archi-grid { grid-template-columns: 1fr; }
  .agent-protocol { grid-template-columns: 1fr; }
  .agent-protocol-actions { grid-column: 1; }
  .topology-flow { grid-template-columns: 1fr; }
  .topology-arrow { transform: rotate(90deg); min-height: 20px; }
  .main { padding: 28px 24px 56px; }
}
@media (max-width: 780px) {
  .sidebar { width: 64px; padding: 16px 8px 12px; }
  .sidebar .brand-name, .sidebar .brand-sub, .nav-item span:last-child, .nav-sep, .user-chip-meta { display: none; }
  .brand { justify-content: center; padding-bottom: 14px; }
  .nav-item { justify-content: center; padding: 0; width: 40px; margin: 0 auto; }
  .user-chip { justify-content: center; padding: 8px 0; }
  .main { padding: 20px 16px 52px; }
  .login-houses { grid-template-columns: 1fr; }
  .hero-progress { gap: 22px; padding: 22px; }
  .home-hero { grid-template-columns: 1fr; padding: 20px; }
  .clients-snapshot { grid-template-columns: 1fr 1fr; }
  .shared-strip { grid-template-columns: 1fr 1fr; }
  .home-hero-copy h2 { font-size: 32px; }
  .agent-rules { grid-template-columns: 1fr; }
  .agent-rules > div { min-height: auto; }
  .agent-protocol-actions { justify-content: flex-start; }
  .media-dropzone { align-items: flex-start; flex-wrap: wrap; }
  .media-dropzone small { max-width: none; text-align: left; width: 100%; padding-left: 56px; }
  .control-plane-band { grid-template-columns: 38px 1fr; }
  .no-traffic { grid-column: 2; width: fit-content; }
  .topology-head { align-items: flex-start; flex-direction: column; }
  .topology-head > span { text-align: left; }
  .row-2 { grid-template-columns: 1fr; }
  .search-box .input { width: 100%; }
}
@media (max-width: 520px) {
  .clients-snapshot, .shared-strip { grid-template-columns: 1fr; }
  .home-hero { min-height: 0; }
  .home-hero-copy { padding: 4px 0; }
  .memory-grid { grid-template-columns: 1fr; }
  .toolbar .select { width: 100%; }
  .journal-toolbar .filter-pills { border-radius: 16px; width: 100%; }
  .agent-entry { padding: 15px 13px; }
  .agent-entry-body time { width: 100%; margin-left: 0; }
  .media-dropzone small { padding-left: 0; }
}

/* ═══════════════════════════════════════════════════════════
   FINITION V4 — cartes calmes, vitrines et lecture vibecoder
   ═══════════════════════════════════════════════════════════ */

/* Marques des plateformes : logos monochromes, aucune couleur parasite. */
.platform-mark {
  width: var(--mark-size, 38px);
  height: var(--mark-size, 38px);
  flex: 0 0 var(--mark-size, 38px);
  display: grid;
  place-items: center;
  color: #e7e2ff;
  background:
    radial-gradient(circle at 28% 18%, rgba(255, 255, 255, .12), transparent 42%),
    rgba(139, 108, 255, .11);
  border: 1px solid rgba(179, 161, 255, .28);
  border-radius: max(9px, calc(var(--mark-size, 38px) * .29));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08);
}
.platform-mark img {
  width: 56%;
  height: 56%;
  display: block;
  object-fit: contain;
  filter: brightness(0) invert(91%) sepia(8%) saturate(1547%) hue-rotate(202deg) brightness(105%);
}
.windows-mark {
  grid-template-columns: repeat(2, 22%);
  grid-template-rows: repeat(2, 22%);
  gap: 5%;
}
.windows-mark i { width: 100%; height: 100%; background: currentColor; border-radius: 1px; }

/* Les plateformes restent dans la même palette ; seuls leurs états varient. */
.client-snapshot {
  min-height: 218px;
  padding: 17px;
  background:
    linear-gradient(145deg, rgba(139, 108, 255, .075), transparent 48%),
    rgba(23, 22, 30, .8);
  border-color: rgba(215, 207, 255, .105);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .035), 0 24px 54px -42px #000;
}
.client-snapshot::after {
  left: 18px;
  right: 18px;
  background: linear-gradient(90deg, transparent, rgba(179, 161, 255, .7), transparent);
}
.client-snapshot:hover { border-color: rgba(179, 161, 255, .32); background-color: rgba(29, 27, 39, .92); }
.client-snapshot.planned { opacity: .66; filter: none; }
.client-snapshot-name { margin-top: 16px; }
.client-snapshot-tech { color: var(--accent-2); font-size: 10px; font-weight: 700; margin-top: 1px; }
.client-snapshot-change {
  min-height: 44px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.client-snapshot-foot { margin-top: 10px; }

.home-hero {
  min-height: 286px;
  background:
    radial-gradient(560px 300px at 15% 16%, rgba(139, 108, 255, .2), transparent 70%),
    linear-gradient(145deg, rgba(31, 28, 48, .94), rgba(15, 15, 20, .98) 68%);
  border-color: rgba(179, 161, 255, .22);
}
.attention-card {
  position: relative;
  z-index: 1;
  padding: 20px;
  border-radius: 19px;
  background: rgba(10, 10, 15, .5);
  border: 1px solid rgba(222, 216, 255, .1);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .025);
  backdrop-filter: blur(18px);
  display: flex;
  flex-direction: column;
}
.attention-row b,
.attention-row.violet b,
.attention-row.coral b,
.attention-row.teal b { color: var(--accent-2); }

.shared-foundation {
  display: grid;
  grid-template-columns: minmax(245px, .9fr) minmax(0, 2.1fr);
  gap: 1px;
  margin-bottom: 14px;
  overflow: hidden;
  background: rgba(215, 207, 255, .09);
  border: 1px solid rgba(215, 207, 255, .11);
  border-radius: 20px;
  box-shadow: var(--shadow);
}
.shared-foundation a { color: var(--text); text-decoration: none; }
.shared-foundation-intro,
.shared-foundation-items > a {
  min-height: 74px;
  background: rgba(21, 20, 28, .94);
  transition: background .16s;
}
.shared-foundation-intro:hover,
.shared-foundation-items > a:hover { background: rgba(29, 27, 39, .96); }
.shared-foundation-intro { display: flex; align-items: center; gap: 12px; padding: 14px 18px; }
.shared-foundation-intro > span {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: var(--accent-2);
  background: var(--accent-soft);
  border: 1px solid rgba(179, 161, 255, .28);
  border-radius: 12px;
}
.shared-foundation b { display: block; font-size: 11.5px; }
.shared-foundation small { display: block; color: var(--faint); font-size: 9.5px; line-height: 1.35; margin-top: 2px; }
.shared-foundation-items { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: rgba(215, 207, 255, .09); }
.shared-foundation-items > a { display: flex; align-items: center; gap: 10px; padding: 12px 14px; }
.shared-foundation-items .micro-state { font-size: 0; }
.shared-foundation-items .micro-state::before { width: 7px; height: 7px; }

.feed-ico.note,
.feed-ico.agent,
.feed-ico.media,
.feed-ico.feature,
.feed-ico.server,
.feed-ico.doc,
.feed-ico.diff,
.feed-ico.service {
  color: var(--accent-2);
  background: var(--accent-soft);
}
.note-card::before, .memory-card::before { background: var(--accent); }

/* Clients & versions */
.client-page-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 13px;
  margin-bottom: 18px;
}
.platform-card-premium {
  min-height: 350px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 15px;
  overflow: hidden;
  position: relative;
}
.platform-card-premium::after {
  content: '';
  position: absolute;
  width: 180px;
  height: 180px;
  right: -110px;
  top: -110px;
  border-radius: 50%;
  border: 28px solid rgba(139, 108, 255, .035);
  pointer-events: none;
}
.platform-card-premium.is-planned { opacity: .68; }
.platform-card-premium > header { display: flex; align-items: flex-start; gap: 11px; position: relative; z-index: 1; }
.platform-card-premium > header > div:nth-child(2) { min-width: 0; }
.platform-card-premium > header > .btn { margin-left: auto; position: relative; z-index: 2; }
.platform-card-title { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.platform-card-title h2 { font-size: 18px; letter-spacing: -.02em; }
.platform-card-premium > header p { color: var(--accent-2); font-size: 10px; font-weight: 700; margin-top: 2px; }
.platform-card-description {
  min-height: 56px;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.62;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.platform-latest {
  min-height: 99px;
  padding: 14px 15px;
  border: 1px solid rgba(179, 161, 255, .17);
  border-radius: 15px;
  background: linear-gradient(145deg, rgba(139, 108, 255, .1), rgba(139, 108, 255, .025));
}
.platform-latest.empty-source { border-color: var(--line); background: rgba(255, 255, 255, .018); }
.platform-latest b { display: block; margin-top: 6px; font-size: 12.5px; line-height: 1.45; }
.platform-latest p { color: var(--faint); font-size: 10px; line-height: 1.5; margin-top: 4px; }
.platform-card-premium > footer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: auto;
  padding-top: 13px;
  border-top: 1px solid var(--line);
}
.platform-card-premium > footer span { display: block; color: var(--faint); font-size: 9px; text-transform: uppercase; letter-spacing: .1em; }
.platform-card-premium > footer b { display: block; font-size: 11px; margin-top: 2px; }
.clients-feature-card { overflow: hidden; }
.clients-feature-card .section-title { padding-bottom: 15px; border-bottom: 1px solid var(--line); }
.clients-feature-scroll { overflow-x: auto; }
.clients-feature-table { min-width: 940px; margin: 0; }
.clients-feature-table th, .clients-feature-table td { padding: 12px 16px; border-bottom: 1px solid var(--line); }
.clients-feature-table tbody tr:last-child td { border-bottom: none; }
.clients-feature-table th { color: var(--faint); font-size: 9px; text-transform: uppercase; letter-spacing: .1em; text-align: center; }
.clients-feature-table th:first-child { text-align: left; width: 280px; }
.clients-feature-table td { text-align: center; vertical-align: middle; }
.clients-feature-table td:first-child { text-align: left; }
.clients-feature-table td:first-child b { display: block; font-size: 12px; }
.clients-feature-table td:first-child small { display: block; max-width: 360px; color: var(--faint); font-size: 9.5px; line-height: 1.45; margin-top: 3px; }
.table-platform { display: inline-flex; align-items: center; justify-content: center; gap: 7px; color: var(--muted); }
.advanced-settings { margin-top: 4px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 13px; background: rgba(255, 255, 255, .018); }
.advanced-settings summary { cursor: pointer; color: var(--muted); font-size: 11.5px; font-weight: 700; }
.advanced-settings > p { color: var(--faint); font-size: 10.5px; line-height: 1.55; margin: 10px 0 14px; }
.advanced-settings[open] summary { color: var(--accent-2); margin-bottom: 12px; }

/* Socle commun : définition pédagogique puis fiches sobres. */
.foundation-explainer {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 15px;
  align-items: center;
  padding: 20px 22px;
  margin-bottom: 28px;
  border: 1px solid rgba(179, 161, 255, .25);
  border-radius: 20px;
  background:
    radial-gradient(360px 140px at 0 0, rgba(139, 108, 255, .15), transparent 78%),
    rgba(22, 20, 31, .82);
  box-shadow: var(--shadow);
}
.foundation-explainer > span { width: 46px; height: 46px; display: grid; place-items: center; color: var(--accent-2); border-radius: 14px; background: var(--accent-soft); border: 1px solid var(--accent-line); }
.foundation-explainer h2 { font-size: 17px; letter-spacing: -.015em; }
.foundation-explainer p { max-width: 850px; color: var(--muted); font-size: 12px; line-height: 1.65; margin-top: 4px; }
.foundation-group { margin-bottom: 27px; }
.foundation-group > header { display: flex; align-items: end; justify-content: space-between; gap: 12px; margin: 0 3px 11px; }
.foundation-group > header h2 { font-size: 16px; }
.foundation-group > header p { color: var(--faint); font-size: 10.5px; margin-top: 2px; }
.foundation-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(275px, 1fr)); gap: 12px; }
.foundation-card { min-height: 260px; padding: 18px; display: flex; flex-direction: column; gap: 14px; }
.foundation-card > header { display: flex; align-items: center; gap: 10px; }
.foundation-card > header > div { min-width: 0; }
.foundation-card > header > .chip { margin-left: auto; }
.foundation-card-icon { width: 38px; height: 38px; flex-shrink: 0; display: grid; place-items: center; color: var(--accent-2); border-radius: 12px; background: var(--accent-soft); border: 1px solid rgba(179, 161, 255, .25); }
.foundation-card h3 { font-size: 15px; }
.foundation-card header small { display: block; color: var(--faint); font-size: 9.5px; margin-top: 1px; }
.foundation-card-purpose { min-height: 62px; color: var(--text); font-size: 12px; line-height: 1.65; }
.foundation-card-details { border-top: 1px solid var(--line); padding-top: 11px; }
.foundation-card-details summary { color: var(--muted); cursor: pointer; font-size: 10.5px; font-weight: 700; }
.foundation-card-details[open] summary { color: var(--accent-2); }
.foundation-card-details > div { padding-top: 9px; }
.foundation-card-details p { color: var(--muted); font-size: 10.5px; line-height: 1.55; margin-bottom: 7px; }
.foundation-card-details b { color: var(--text); }
.foundation-card > .btn { align-self: flex-start; margin-top: auto; }

/* Différences : une comparaison lisible, détails à la demande. */
.diff-toolbar { padding: 6px; background: rgba(17, 17, 22, .72); border: 1px solid var(--line); border-radius: 18px; }
.diff-toolbar .select, .diff-toolbar .input { width: auto; min-width: 150px; border-color: transparent; background-color: rgba(255, 255, 255, .028); }
.diff-toolbar .search-box-simple { min-width: 220px; flex: 1; }
.diff-toolbar .search-box-simple .input { width: 100%; }
.compare-word { color: var(--faint); font-size: 10px; font-weight: 700; }
.diff-list { display: flex; flex-direction: column; gap: 13px; }
.diff-card-simple { padding: 20px; display: flex; flex-direction: column; gap: 14px; }
.diff-card-simple > header { display: flex; align-items: flex-start; gap: 12px; }
.diff-card-simple > header > div { min-width: 0; flex: 1; }
.diff-card-chips { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 9px; }
.diff-card-simple h2 { font-size: 18px; line-height: 1.35; letter-spacing: -.02em; }
.diff-summary { max-width: 900px; color: var(--text); font-size: 12.5px; line-height: 1.68; }
.diff-sides { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.diff-side { min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: 15px; background: rgba(9, 9, 13, .32); }
.diff-side header { display: flex; align-items: center; gap: 9px; }
.diff-side header b { font-size: 11.5px; }
.diff-side p { color: var(--muted); font-size: 11.5px; line-height: 1.62; margin-top: 9px; white-space: pre-wrap; overflow-wrap: anywhere; }
.diff-more { border: 1px solid var(--line); border-radius: 13px; background: rgba(255, 255, 255, .017); }
.diff-more summary { padding: 11px 13px; color: var(--muted); cursor: pointer; font-size: 10.5px; font-weight: 700; }
.diff-more[open] summary { color: var(--accent-2); border-bottom: 1px solid var(--line); }
.diff-more > div { display: grid; gap: 8px; padding: 12px 14px; }
.diff-more p { color: var(--muted); font-size: 11px; line-height: 1.55; white-space: pre-wrap; }
.diff-more b { color: var(--text); }
.diff-technical-kind { color: var(--faint) !important; font-size: 9.5px !important; }
.diff-card-simple > footer { display: flex; align-items: center; gap: 10px; padding-top: 11px; border-top: 1px solid var(--line); }
.diff-card-simple > footer span { color: var(--faint); font-size: 9.5px; }
.diff-card-simple > footer .btn { margin-left: auto; }

/* Médiathèque : des vitrines, jamais un explorateur de fichiers. */
.media-dropzone {
  background: rgba(21, 20, 28, .55);
  border-color: rgba(179, 161, 255, .18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .025);
}
.media-catalog { display: flex; flex-direction: column; gap: 15px; }
.media-catalog-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; padding: 5px 3px 2px; }
.media-catalog-head h2 { font-size: 19px; letter-spacing: -.02em; margin-top: 3px; }
.media-catalog-head p { color: var(--muted); font-size: 11px; margin-top: 4px; }
.media-gallery-stats { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.media-gallery-stats > span { min-height: 25px; display: inline-flex; align-items: center; padding: 3px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: rgba(255, 255, 255, .025); font-size: 9.5px; font-weight: 700; }
.media-catalog-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 13px; }
.media-feature-showcase {
  min-height: 348px;
  display: flex;
  flex-direction: column;
  border-color: rgba(215, 207, 255, .11);
  background:
    linear-gradient(145deg, rgba(139, 108, 255, .06), transparent 46%),
    rgba(23, 22, 30, .88);
}
.media-feature-showcase.is-featured { grid-column: span 2; }
.media-feature-showcase-cover { aspect-ratio: 16 / 9; border-bottom: 1px solid var(--line); }
.media-feature-showcase.is-featured .media-feature-showcase-cover { aspect-ratio: 2.14 / 1; }
.media-feature-showcase-cover::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, transparent 48%, rgba(9, 8, 13, .7));
}
.media-feature-showcase-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--muted);
  background:
    radial-gradient(180px 100px at 50% 55%, rgba(139, 108, 255, .17), transparent 78%),
    linear-gradient(145deg, #17151f, #111016);
}
.media-feature-showcase-empty::before {
  content: '';
  position: absolute;
  width: 36%;
  height: 13px;
  left: 8%;
  top: 0;
  border-radius: 0 0 12px 12px;
  background: rgba(139, 108, 255, .13);
  border: 1px solid rgba(179, 161, 255, .16);
  border-top: 0;
}
.media-showcase-empty-icon { width: 52px; height: 52px; display: grid; place-items: center; color: var(--accent-2); background: var(--accent-soft); border: 1px solid var(--accent-line); border-radius: 17px; }
.media-feature-showcase-body { display: flex; flex-direction: column; flex: 1; padding: 16px 17px; }
.media-feature-showcase-topline { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.media-showcase-count { color: var(--faint); font-size: 9.5px; font-weight: 700; }
.media-feature-showcase-title { font-size: 20px; letter-spacing: -.025em; margin-top: 8px; }
.media-feature-showcase-description { min-height: 36px; }
.media-feature-showcase-footer { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 11px; margin-top: auto; border-top: 1px solid var(--line); color: var(--faint); font-size: 9.5px; }
.media-feature-showcase-footer > span:last-child { display: inline-flex; align-items: center; gap: 5px; color: var(--accent-2); font-weight: 700; }
.media-gallery { display: flex; flex-direction: column; gap: 23px; }
.media-gallery-hero { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 18px; padding: 20px 22px; background: linear-gradient(145deg, rgba(139, 108, 255, .1), rgba(23, 22, 30, .86) 52%); }
.media-gallery-copy h2 { font-size: 24px; letter-spacing: -.03em; margin-top: 3px; }
.media-gallery-copy p { color: var(--muted); font-size: 11px; line-height: 1.55; margin-top: 3px; }
.media-chronology { display: flex; flex-direction: column; gap: 25px; }
.media-date-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin: 0 3px 10px; }
.media-date-heading h3 { font-size: 15px; }
.media-date-heading span { color: var(--faint); font-size: 9.5px; }
.media-gallery-grid { grid-template-columns: repeat(auto-fill, minmax(245px, 1fr)); }
.media-card { background-color: rgba(23, 22, 30, .86); }

/* Architecture : une seule fenêtre, trois étages et le QG à côté. */
.architecture-window { max-width: 1160px; min-height: 620px; margin: 2vh auto 0; padding: 27px; }
.architecture-window .topology-head { padding: 2px 2px 19px; }
.architecture-window .topology-head h2 { font-size: 22px; letter-spacing: -.025em; }
.architecture-product-flow { grid-template-columns: minmax(250px, 1fr) 30px minmax(255px, .96fr) 30px minmax(255px, 1fr); padding: 22px 0; }
.architecture-window .topology-column { padding: 15px; border-color: rgba(215, 207, 255, .095); background: rgba(10, 10, 14, .3); }
.architecture-window .topology-column > label { margin-bottom: 12px; }
.architecture-window .topology-client-grid { gap: 7px; }
.architecture-client {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 9px;
  align-items: center;
  min-height: 64px;
  padding: 9px;
  border-color: rgba(179, 161, 255, .18);
  background: rgba(139, 108, 255, .055);
}
.architecture-client .architecture-logo-slot { grid-row: 1 / 3; display: inline-flex; }
.architecture-client b { color: var(--text); font-size: 11.5px; }
.architecture-client small { color: var(--faint); font-size: 8.5px; }
.architecture-client.planned { opacity: .52; }
.architecture-service-list { min-height: 100%; display: flex; flex-direction: column; gap: 8px; justify-content: center; padding: 10px; }
.architecture-service { padding: 13px; border: 1px solid rgba(179, 161, 255, .18); border-radius: 12px; background: rgba(10, 10, 15, .35); }
.architecture-service b { font-size: 12px; }
.architecture-service p { color: var(--muted); font-size: 10px; line-height: 1.5; margin-top: 4px; }
.architecture-server { min-height: 59px !important; grid-template-columns: 10px 66px 1fr !important; }
.architecture-server b { color: var(--text); }
.architecture-window .topology-arrow { color: rgba(179, 161, 255, .6); }
.architecture-qg { margin-top: 1px; padding: 17px 18px; border-color: rgba(179, 161, 255, .26); }
.architecture-qg .no-traffic { color: var(--muted); border-color: var(--line-strong); background: rgba(255, 255, 255, .025); }

/* Registre agent : la trace prime, les détails techniques s'effacent. */
.agent-protocol {
  background:
    radial-gradient(420px 210px at 0 0, rgba(139, 108, 255, .15), transparent 76%),
    rgba(23, 22, 30, .82);
  box-shadow: var(--shadow);
}
.agent-rules > div { background: rgba(10, 10, 14, .32); }
.agent-name { font-family: var(--font-ui); text-transform: none; }
.entry-files span, .entry-source { opacity: .78; }
.mode-hint.read { color: var(--accent-2); background: var(--accent-soft); border-color: var(--accent-line); }

/* Serveurs : le QG reste une mémoire calme, distincte du produit. */
.server-card { background-color: rgba(23, 22, 30, .84); }
.server-card.control-server { background: linear-gradient(150deg, rgba(139, 108, 255, .09), rgba(23, 22, 30, .86) 52%); }

/* ═══════════════════════════════════════════════════════════
   FINITION V5 — calme social, une seule surface à la fois
   ═══════════════════════════════════════════════════════════ */

:root {
  --ctl: 38px;
  --ctl-sm: 32px;
  --radius: 18px;
  --shadow: none;
}

body {
  background:
    radial-gradient(780px 360px at 62% -8%, rgba(139, 108, 255, .09), transparent 68%),
    radial-gradient(560px 420px at 18% 108%, rgba(88, 62, 168, .035), transparent 72%),
    #0a0a0e;
}

.main {
  width: auto;
  max-width: none;
  padding: 30px clamp(24px, 3vw, 48px) 56px;
}

.view {
  width: 100%;
  min-width: 0;
  max-width: none;
}

.page-head {
  min-height: 64px;
  align-items: center;
  margin-bottom: 20px;
}
.page-head h1 { margin-top: 3px; font-size: 27px; }
.page-intro { margin-top: 4px; line-height: 1.45; }
.card { box-shadow: none; }
.btn { height: 36px; }
.btn-sm { height: 31px; }
.textarea { font-family: var(--font-ui); font-size: 13px; }

/* Menu de filtres secondaire : absent tant qu'on ne le demande pas. */
.filter-menu { position: relative; z-index: 20; }
.filter-menu > summary { list-style: none; }
.filter-menu > summary::-webkit-details-marker { display: none; }
.filter-menu > div {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: 250px;
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: rgba(24, 22, 31, .98);
  box-shadow: 0 20px 52px -28px #000;
}
.filter-menu .select { width: 100%; min-width: 0; }

/* ── Accueil : deux réponses seulement — attention et activité. */
.home-head-simple { margin-bottom: 14px; }
.home-head-simple h1 { font-size: clamp(28px, 3vw, 38px); letter-spacing: -.04em; }
.home-head-simple .page-intro { font-size: 13px; }

.home-signals {
  min-height: 64px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  margin-bottom: 30px;
}
.home-signal {
  min-width: 0;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 9px;
  padding: 0 18px;
  color: var(--muted);
  text-decoration: none;
  border-right: 1px solid var(--line);
}
.home-signal:first-child { padding-left: 2px; }
.home-signal:last-child { border-right: 0; }
.home-signal:hover { color: var(--text); text-decoration: none; }
.home-signal b { color: var(--accent-2); font-size: 19px; letter-spacing: -.04em; }
.home-signal span { font-size: 12px; font-weight: 650; }
.home-signal i { display: inline-flex; color: var(--faint); transition: transform .16s; }
.home-signal:hover i { transform: translateX(3px); }

.home-social-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(280px, .72fr);
  gap: 46px;
  align-items: start;
}
.home-section-head {
  min-height: 54px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 7px;
}
.home-section-head.compact { min-height: 46px; }
.home-section-head h2 { margin-top: 3px; font-size: 18px; letter-spacing: -.025em; }
.home-section-head a { color: var(--muted); font-size: 10.5px; font-weight: 700; }
.home-stream-list { border-top: 1px solid var(--line); }
.home-stream-row {
  min-height: 76px;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 10px 2px;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
  transition: padding .16s, background .16s;
}
.home-stream-row:hover { padding-left: 8px; text-decoration: none; background: linear-gradient(90deg, rgba(139,108,255,.055), transparent 68%); }
.home-stream-icon {
  width: 34px; height: 34px;
  display: grid; place-items: center;
  color: var(--accent-2);
  background: var(--accent-soft);
  border-radius: 50%;
}
.home-stream-row > div { min-width: 0; }
.home-stream-row > div b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12.5px; }
.home-stream-row > div small { display: block; color: var(--faint); font-size: 9.5px; margin-top: 2px; }
.home-stream-empty { min-height: 170px; display: flex; flex-direction: column; justify-content: center; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.home-stream-empty b { font-size: 15px; }
.home-stream-empty span, .home-muted { color: var(--faint); font-size: 11px; margin-top: 3px; }

.home-social-rail {
  display: grid;
  gap: 30px;
  padding-left: 30px;
  border-left: 1px solid var(--line);
}
.home-client-list, .home-recent-list { border-top: 1px solid var(--line); }
.home-client-line {
  min-height: 53px;
  display: grid;
  grid-template-columns: 32px 1fr 8px;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  color: var(--text);
  text-decoration: none;
}
.home-client-line:hover { text-decoration: none; }
.home-client-line.planned { opacity: .46; }
.home-client-line b, .home-client-line small { display: block; }
.home-client-line b { font-size: 11.5px; }
.home-client-line small { color: var(--faint); font-size: 9px; }
.home-presence { width: 6px; height: 6px; border-radius: 50%; background: var(--faint); }
.home-presence.online { background: #62d6a8; box-shadow: 0 0 8px rgba(98,214,168,.6); }
.home-recent-row {
  min-height: 54px;
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 9px;
  align-items: center;
  border-bottom: 1px solid var(--line);
}
.home-recent-row > span { color: var(--accent-2); display: inline-flex; }
.home-recent-row b, .home-recent-row small { display: block; }
.home-recent-row b { font-size: 10.5px; line-height: 1.35; }
.home-recent-row small { color: var(--faint); font-size: 8.8px; margin-top: 2px; }

/* ── Marques : zone de sécurité nette pour Android et Windows. */
.platform-mark { overflow: hidden; }
.platform-mark img { width: 58%; height: 58%; object-fit: contain; }
.platform-mark[title="Android"] img { width: 66%; height: 66%; }
.windows-mark {
  grid-template-columns: repeat(2, 8px);
  grid-template-rows: repeat(2, 8px);
  gap: 2px;
  place-content: center;
  place-items: stretch;
}
.windows-mark i { width: auto; height: auto; }

/* ── Clients : mêmes cartes, mais à la taille d'un résumé. */
.client-page-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}
.platform-card-premium {
  min-height: 0;
  height: 176px;
  padding: 13px 14px;
  gap: 8px;
  border-radius: 16px;
  background: linear-gradient(150deg, rgba(139,108,255,.065), rgba(20,19,27,.76) 52%);
}
.platform-card-premium::after { display: none; }
.platform-card-premium.is-planned { opacity: .58; }
.platform-card-premium > header { align-items: center; gap: 9px; }
.platform-card-title { gap: 5px; }
.platform-card-title h2 { font-size: 15px; }
.platform-card-premium > header p { margin: 0; font-size: 9px; }
.platform-reference-button { margin-left: auto; width: 28px; height: 28px; font-size: 14px; letter-spacing: 1px; }
.platform-card-description { display: none; }
.platform-latest,
.platform-latest.empty-source {
  min-height: 0;
  padding: 8px 0 0;
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
}
.platform-latest > span { display: block; color: var(--faint); font-size: 8px; font-weight: 750; text-transform: uppercase; letter-spacing: .1em; }
.platform-latest b {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  margin-top: 3px;
  font-size: 10.5px;
  line-height: 1.35;
}
.platform-latest small { display: block; color: var(--faint); font-size: 8.5px; margin-top: 2px; }
.platform-latest.empty-source { display: flex; align-items: center; flex: 1; }
.platform-latest.empty-source > span { text-transform: none; letter-spacing: 0; font-size: 10px; }
.platform-card-premium > footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: auto;
  padding-top: 7px;
}
.platform-card-premium > footer span,
.platform-card-premium > footer b { display: block; margin: 0; color: var(--faint); font-size: 8.8px; letter-spacing: 0; text-transform: none; }
.platform-card-premium > footer b { color: var(--muted); }
.clients-feature-card { border-radius: 17px; }
.clients-feature-card .section-title { padding: 14px 16px 11px; }
.clients-feature-table th, .clients-feature-table td { padding: 9px 14px; }
.clients-feature-table td:first-child small { -webkit-line-clamp: 1; overflow: hidden; }

/* ── Versions : une fiche claire à la fois, comme un profil. */
.versions-page-head { margin-bottom: 14px; }
.version-tabs {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
  overflow-x: auto;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.version-tab {
  min-width: 0;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 0 12px;
  position: relative;
  color: var(--muted);
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
}
.version-tab:last-child { border-right: 0; }
.version-tab::after {
  content: '';
  position: absolute;
  right: 18%;
  bottom: -1px;
  left: 18%;
  height: 2px;
  border-radius: 999px;
  background: var(--accent-2);
  opacity: 0;
}
.version-tab > span:last-child { min-width: 0; text-align: left; }
.version-tab b, .version-tab small { display: block; }
.version-tab b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11.5px; }
.version-tab small { margin-top: 1px; color: var(--faint); font-size: 8.5px; }
.version-tab.is-planned { opacity: .54; }
.version-tab:hover { color: var(--text); background: rgba(139,108,255,.035); }
.version-tab.is-active { color: var(--text); background: rgba(139,108,255,.055); opacity: 1; }
.version-tab.is-active::after { opacity: 1; }

.version-profile { min-width: 0; }
.version-profile-hero {
  min-height: 154px;
  display: grid;
  grid-template-columns: minmax(250px, .85fr) minmax(300px, 1.2fr) auto;
  align-items: center;
  gap: 30px;
  padding: 24px 4px;
  border-bottom: 1px solid var(--line);
}
.version-profile-identity { min-width: 0; display: flex; align-items: center; gap: 15px; }
.version-profile-identity > div { min-width: 0; }
.version-profile-identity h2 { margin-top: 4px; font-size: 27px; letter-spacing: -.035em; }
.version-profile-identity p { margin-top: 2px; color: var(--muted); font-size: 10.5px; }
.version-profile-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 8.5px;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
}
.version-profile-status i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; box-shadow: 0 0 7px currentColor; }
.version-profile-status.is-active { color: var(--teal); }
.version-profile-description { max-width: 590px; color: var(--muted); font-size: 12px; line-height: 1.65; }
.version-profile-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }
.version-profile-edit { width: 34px; height: 34px; font-size: 14px; letter-spacing: 1px; }

.version-profile-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(270px, 330px);
  gap: 42px;
  padding-top: 27px;
}
.version-features > header,
.version-activity > header { margin-bottom: 10px; }
.version-features > header h2,
.version-activity > header h2 { margin-top: 3px; font-size: 18px; letter-spacing: -.025em; }
.version-features > header p { margin-top: 5px; color: var(--faint); font-size: 10.5px; }
.version-feature-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 28px;
  border-top: 1px solid var(--line);
}
.version-feature-row {
  width: 100%;
  min-width: 0;
  min-height: 70px;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 10px 3px;
  color: var(--text);
  text-align: left;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
}
.version-feature-row.is-link { cursor: pointer; }
.version-feature-row.is-link:hover { background: linear-gradient(90deg, rgba(139,108,255,.045), transparent 72%); }
.version-feature-icon {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  color: rgba(205,194,255,.72);
  border-radius: 50%;
  background: rgba(139,108,255,.075);
  transition: color .16s ease, filter .16s ease;
}
.version-feature-row.is-link:hover .version-feature-icon {
  color: #f2eeff;
  filter: drop-shadow(0 0 7px rgba(139,108,255,.54));
}
.version-feature-copy { min-width: 0; }
.version-feature-copy b, .version-feature-copy small { display: block; }
.version-feature-copy b { font-size: 11.5px; }
.version-feature-copy small { margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--faint); font-size: 9px; }
.version-feature-state {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--muted);
  font-size: 8.8px;
  font-weight: 700;
  white-space: nowrap;
}
.version-feature-state i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.version-feature-state.is-ready { color: var(--teal); }
.version-feature-state.is-progress,
.version-feature-state.is-seen,
.version-feature-state.is-check { color: var(--accent-2); }
.version-feature-state.is-blocked { color: var(--red); }
.version-feature-state.is-future { color: var(--faint); }

.version-activity {
  min-width: 0;
  padding-left: 30px;
  border-left: 1px solid var(--line);
}
.version-activity-list { border-top: 1px solid var(--line); }
.version-activity-row {
  min-height: 72px;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--line);
}
.version-activity-icon { width: 27px; height: 27px; display: grid; place-items: center; color: var(--accent-2); border-radius: 50%; background: var(--accent-soft); }
.version-activity-row b, .version-activity-row small { display: block; }
.version-activity-row b { font-size: 10.5px; line-height: 1.4; }
.version-activity-row small { margin-top: 3px; color: var(--faint); font-size: 8.8px; }
.version-activity-empty {
  min-height: 170px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.version-activity-empty > span { width: 34px; height: 34px; display: grid; place-items: center; color: var(--faint); border-radius: 50%; background: rgba(255,255,255,.025); }
.version-activity-empty b { margin-top: 10px; font-size: 12px; }
.version-activity-empty p { max-width: 260px; margin-top: 4px; color: var(--faint); font-size: 9.5px; line-height: 1.5; }
.version-diff-link {
  width: 100%;
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 2px;
  color: var(--text);
  text-align: left;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  cursor: pointer;
}
.version-diff-link:hover { background: linear-gradient(90deg, rgba(139,108,255,.045), transparent 72%); }
.version-diff-link b, .version-diff-link small { display: block; }
.version-diff-link b { font-size: 11px; }
.version-diff-link small { margin-top: 2px; color: var(--faint); font-size: 9px; }
.version-diff-link > span:last-child { color: var(--accent-2); }

.version-profile-hero-simple {
  grid-template-columns: minmax(250px, .75fr) minmax(320px, 1.25fr) 34px;
}
.version-changes { padding-top: 27px; }
.version-changes > header { margin-bottom: 12px; }
.version-changes > header h2 { margin-top: 3px; font-size: 19px; letter-spacing: -.025em; }
.version-changes > header p { margin-top: 5px; color: var(--faint); font-size: 10.5px; }
.version-change-list { border-top: 1px solid var(--line); }
.version-change-row {
  min-height: 68px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 9px 3px;
  border-bottom: 1px solid var(--line);
}
.version-change-icon {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  color: var(--accent-2);
  border-radius: 50%;
  background: var(--accent-soft);
}
.version-change-copy { min-width: 0; }
.version-change-copy small,
.version-change-copy b { display: block; }
.version-change-copy small { color: var(--faint); font-size: 8.5px; font-weight: 750; letter-spacing: .08em; text-transform: uppercase; }
.version-change-copy b { margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12.5px; line-height: 1.4; }
.version-change-row time { color: var(--faint); font-size: 9.5px; white-space: nowrap; }
.version-change-empty {
  min-height: 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.version-change-empty > span { width: 42px; height: 42px; display: grid; place-items: center; color: var(--faint); border-radius: 50%; background: rgba(255,255,255,.025); }
.version-change-empty b { margin-top: 12px; font-size: 13px; }
.version-change-empty p { max-width: 360px; margin-top: 4px; color: var(--faint); font-size: 10px; line-height: 1.55; }

/* ── Médiathèque : albums d'abord, médias uniquement après ouverture. */
.media-page-head { margin-bottom: 18px; }
.media-albums-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 17px;
}
.media-album {
  aspect-ratio: 1;
  min-width: 0;
  padding: 20px;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  color: var(--text);
  text-align: center;
  border: 1px solid rgba(179,161,255,.14);
  border-radius: 23px;
  background:
    radial-gradient(90% 75% at 50% 12%, rgba(139,108,255,.10), transparent 72%),
    rgba(20,19,27,.78);
  cursor: pointer;
  overflow: hidden;
}
.media-album-art {
  min-height: 0;
  display: grid;
  place-items: center;
  position: relative;
}
.media-album-icon {
  width: 102px; height: 102px;
  display: grid; place-items: center;
  color: rgba(205,194,255,.68);
  transition: color .18s ease, filter .18s ease;
}
.media-album:hover .media-album-icon {
  color: #f2eeff;
  filter: drop-shadow(0 0 8px rgba(139,108,255,.82)) drop-shadow(0 0 22px rgba(139,108,255,.36));
}
.media-album-info { min-width: 0; display: block; padding: 8px 2px 2px; }
.media-album-info b, .media-album-info small { display: block; }
.media-album-info b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.media-album-info small { color: var(--faint); font-size: 10.5px; margin-top: 3px; }

.media-gallery-bar {
  min-height: 68px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 9px;
}
.media-gallery-bar > div { text-align: center; }
.media-gallery-bar h1 { font-size: 22px; line-height: 1.1; }
.media-gallery-bar > div span { color: var(--faint); font-size: 9.5px; }
.media-room-types { color: var(--faint); text-align: center; font-size: 9.5px; margin: 0 0 26px; }
.media-chronology-simple { display: grid; gap: 28px; padding-top: 14px; }
.media-month > header { display: flex; align-items: baseline; gap: 8px; margin-bottom: 9px; }
.media-month > header h2 { font-size: 13px; }
.media-month > header span { color: var(--faint); font-size: 9px; }
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(176px, 1fr)); gap: 8px; }
.gallery-item { min-width: 0; padding: 0; border: 0; background: transparent; color: var(--text); text-align: left; cursor: pointer; }
.gallery-thumb {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 13px;
  background: #111116;
  border: 1px solid rgba(255,255,255,.055);
}
.gallery-thumb img, .gallery-thumb video { width: 100%; height: 100%; display: block; object-fit: cover; transition: transform .2s; }
.gallery-item:hover .gallery-thumb img, .gallery-item:hover .gallery-thumb video { transform: scale(1.025); }
.gallery-video-mark {
  position: absolute; right: 8px; bottom: 8px;
  width: 27px; height: 27px;
  display: grid; place-items: center;
  border-radius: 50%;
  color: #fff; background: rgba(7,7,10,.75);
  backdrop-filter: blur(8px);
}
.gallery-item-meta { display: block; padding: 7px 3px 0; }
.gallery-item-meta b, .gallery-item-meta small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gallery-item-meta b { font-size: 10.5px; }
.gallery-item-meta small { color: var(--faint); font-size: 8.5px; margin-top: 1px; }

.gallery-viewer { width: min(1080px, 92vw); max-height: 92vh; }
.gallery-viewer .modal-body { padding: 0; }
.gallery-viewer-body { overflow: hidden; }
.gallery-viewer-stage {
  height: min(70vh, 720px);
  display: grid;
  place-items: center;
  position: relative;
  background: #050506;
}
.gallery-viewer-stage img, .gallery-viewer-stage video { max-width: 100%; max-height: 100%; width: auto; height: auto; display: block; object-fit: contain; }
.gallery-nav {
  position: absolute; top: 50%;
  width: 42px; height: 42px;
  display: grid; place-items: center;
  transform: translateY(-50%);
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 50%;
  color: #fff; background: rgba(7,7,10,.58);
  font-size: 27px; cursor: pointer; backdrop-filter: blur(10px);
}
.gallery-nav.previous { left: 14px; }
.gallery-nav.next { right: 14px; }
.gallery-nav:disabled { display: none; }
.gallery-viewer-caption { min-height: 42px; display: flex; justify-content: space-between; align-items: center; padding: 0 18px; color: var(--faint); font-size: 9.5px; }
.gallery-upload-list { display: grid; gap: 4px; }
.gallery-upload-list > div { min-height: 42px; display: grid; grid-template-columns: 22px 1fr auto; gap: 8px; align-items: center; border-bottom: 1px solid var(--line); }
.gallery-upload-list b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.gallery-upload-list small { color: var(--faint); font-size: 9px; }

/* ── Architecture : une toile et des câbles, aucune carte dans la carte. */
.architecture-map {
  width: 100%;
  max-width: none;
  margin: 1vh 0 0;
  padding: 25px 30px 27px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background:
    radial-gradient(520px 250px at 50% 0, rgba(139,108,255,.085), transparent 72%),
    rgba(14,13,19,.74);
}
.architecture-map-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.architecture-map-head h1 { margin-top: 3px; font-size: 24px; letter-spacing: -.03em; }
.architecture-map-head p { display: flex; align-items: center; gap: 6px; color: var(--faint); font-size: 9px; }
.architecture-legend-line { width: 22px; height: 1px; display: inline-block; background: rgba(179,161,255,.5); }
.architecture-legend-line.dotted { background: repeating-linear-gradient(to right, rgba(179,161,255,.35) 0 4px, transparent 4px 8px); }
.architecture-canvas { margin-top: 20px; padding-top: 22px; overflow-x: auto; border-top: 1px solid var(--line); }
.architecture-network { --wire: rgba(179,161,255,.50); --wire-faint: rgba(179,161,255,.23); min-width: 760px; }
.architecture-clients { position: relative; display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; padding: 0 24px 46px; }
.architecture-clients::after { content: ''; position: absolute; right: 10%; bottom: 16px; left: 10%; height: 1px; background: var(--wire); }
.architecture-client-node {
  position: relative;
  min-height: 52px;
  display: grid;
  grid-template-columns: 30px auto;
  grid-template-rows: auto auto;
  align-content: center;
  justify-content: center;
  column-gap: 8px;
}
.architecture-client-node::after { content: ''; position: absolute; top: calc(100% + 7px); left: 50%; width: 1px; height: 25px; background: var(--wire); }
.architecture-client-node.is-planned { opacity: .43; }
.architecture-client-node.is-planned::after { background: repeating-linear-gradient(to bottom, var(--wire-faint) 0 4px, transparent 4px 8px); }
.architecture-client-node .platform-mark { grid-row: 1 / 3; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
.architecture-client-node .platform-mark img { width: 72%; height: 72%; }
.architecture-client-node .windows-mark { grid-template-columns: repeat(2, 7px); grid-template-rows: repeat(2, 7px); gap: 2px; }
.architecture-client-node b { align-self: end; font-size: 11.5px; }
.architecture-client-node small { color: var(--faint); font-size: 8.5px; }
.architecture-foundations { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); gap: 84px; padding: 50px 48px 0; }
.architecture-foundations::before { content: ''; position: absolute; top: 16px; right: 16.666%; left: 16.666%; height: 1px; background: var(--wire); }
.architecture-foundations::after { content: ''; position: absolute; top: -16px; left: 50%; width: 1px; height: 32px; background: var(--wire); }
.architecture-branch { position: relative; min-width: 0; }
.architecture-branch::before { content: ''; position: absolute; top: -34px; left: 50%; width: 1px; height: 34px; background: var(--wire); }
.architecture-branch::after { content: ''; position: absolute; top: -38px; left: calc(50% - 3px); width: 7px; height: 7px; border-radius: 50%; background: var(--accent-2); }
.architecture-terminal { display: flex; align-items: center; justify-content: center; gap: 9px; text-align: left; }
.architecture-terminal > i { width: 9px; height: 9px; flex: 0 0 9px; border: 2px solid var(--accent-2); border-radius: 50%; background: var(--bg); }
.architecture-terminal b, .architecture-terminal small { display: block; }
.architecture-terminal b { font-size: 12px; }
.architecture-terminal small { margin-top: 1px; color: var(--faint); font-size: 9px; }
.architecture-server-rail { position: relative; display: grid; gap: 11px; margin: 23px 0 0 50%; padding-left: 28px; list-style: none; }
.architecture-server-rail::before { content: ''; position: absolute; top: -15px; bottom: 12px; left: 0; width: 1px; background: var(--wire-faint); }
.architecture-server-rail li { position: relative; display: grid; grid-template-columns: 8px 61px 1fr; align-items: center; gap: 7px; min-width: 190px; }
.architecture-server-rail li::before { content: ''; position: absolute; top: 50%; left: -28px; width: 18px; height: 1px; background: var(--wire-faint); }
.architecture-server-rail b { font: 9px var(--font-mono); }
.architecture-server-rail small { color: var(--faint); font-size: 8.5px; }
.architecture-qg-lane { position: relative; display: grid; grid-template-columns: auto minmax(90px, 1fr) auto auto; align-items: center; gap: 14px; margin-top: 38px; padding: 34px 18px 4px; border-top: 1px dashed var(--line-strong); }
.architecture-lane-label { position: absolute; top: 8px; left: 18px; color: var(--faint); font-size: 8px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.architecture-qg-wire { height: 1px; background: repeating-linear-gradient(to right, var(--wire-faint) 0 5px, transparent 5px 10px); }
.architecture-terminal.is-qg > i { border-color: var(--accent); background: var(--accent); box-shadow: 0 0 11px rgba(139,108,255,.45); }
.architecture-qg-state { color: var(--faint); font-size: 8px; text-transform: uppercase; letter-spacing: .1em; }
.architecture-note { margin-top: 22px; color: var(--faint); font-size: 9.5px; text-align: center; }

/* ── Journal : une liste éditoriale, pas une grille de panneaux. */
.journal-toolbar-simple { min-height: 46px; margin-bottom: 10px; }
.journal-toolbar-simple .search-box .input { width: 190px; }
.memory-grid { display: block; border-top: 1px solid var(--line); }
.memory-card,
.memory-card.card {
  min-height: 0;
  padding: 16px 4px;
  display: flex;
  gap: 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}
.memory-card::before { display: none; }
.memory-card.card-hover:hover { transform: none; padding-left: 10px; background: linear-gradient(90deg, rgba(139,108,255,.04), transparent 66%); }
.memory-card h3 { margin-top: 9px; font-size: 14px; }
.memory-card > p { margin-top: 5px; font-size: 10.8px; line-height: 1.5; -webkit-line-clamp: 2; }
.memory-tags { margin-top: 8px; }
.memory-card footer { margin: 9px 0 0; padding: 0; border: 0; font-size: 9px; }

.journal-stream {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-top: 2px;
}
.journal-entry {
  min-height: 132px;
  padding: 15px 17px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  align-items: start;
  gap: 13px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 16px;
  outline: 0;
  background:
    radial-gradient(circle at 2% 0%, rgba(139,108,255,.085), transparent 27%),
    rgba(18,18,24,.56);
  box-shadow: inset 0 1px rgba(255,255,255,.018);
  cursor: pointer;
  transition: border-color .18s ease, background-color .18s ease, box-shadow .18s ease;
}
.journal-entry:hover,
.journal-entry:focus-visible {
  border-color: rgba(139,108,255,.3);
  box-shadow: inset 0 1px rgba(255,255,255,.025), 0 0 24px rgba(74,46,142,.06);
}
.journal-entry.is-closed { opacity: .72; }
.journal-entry-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(139,108,255,.3);
  border-radius: 12px;
  color: var(--accent-2);
  background: rgba(139,108,255,.11);
  box-shadow: 0 0 18px rgba(97,65,184,.08);
}
.journal-entry-main { min-width: 0; }
.journal-entry-main > header {
  min-height: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.journal-entry-labels,
.journal-entry-signals,
.journal-entry-main > footer > div {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.journal-entry-signals { justify-content: flex-end; }
.journal-entry-signals .note-pin { margin-left: 0; }
.journal-entry h2 { margin-top: 8px; font-size: 14.5px; line-height: 1.38; letter-spacing: -.015em; }
.journal-entry-main > p {
  margin-top: 5px;
  color: var(--muted);
  font-size: 11.2px;
  line-height: 1.58;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.journal-entry-main > footer {
  min-height: 24px;
  margin-top: 11px;
  padding-top: 9px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: 9.5px;
}
.journal-entry-open { color: var(--accent-2); font-size: 9.5px; font-weight: 700; }

/* ── Agents : un fil, les détails restent repliés. */
.agent-toolbar-simple { min-height: 46px; margin-bottom: 7px; }
.agent-toolbar-simple .search-box { margin-left: auto; }
.agent-toolbar-simple .search-box .input { width: 205px; }
.agent-ledger { border-top: 1px solid var(--line); }
.agent-entry { padding: 16px 3px; }
.agent-entry-rail > span { border-radius: 50%; }
.agent-entry h3 { margin-top: 7px; font-size: 13px; }
.agent-entry-meta { display: flex; align-items: center; gap: 5px; color: var(--faint); font-size: 9.5px; margin-top: 4px; }
.agent-entry-meta .chip { height: 18px; padding: 0 6px; font-size: 7.5px; }
.entry-details { margin-top: 6px; }
.entry-details > div { margin-top: 9px; padding: 11px 13px; border-left: 1px solid var(--line-strong); }
.entry-details .md { padding: 0; border: 0; background: transparent; }

/* ── Différences : un fil de décisions, lisible comme un réseau social. */
.diff-page-head { min-height: 0; margin-bottom: 14px; align-items: center; }
.diff-page-intro {
  width: 100%;
  min-width: 0;
  display: flex;
  align-items: baseline;
  gap: 15px;
}
.diff-page-intro h1 { flex: 0 0 auto; margin: 0; line-height: 1; }
.diff-page-intro p {
  max-width: none;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.3;
}
.diff-aspect-nav {
  width: auto;
  height: 32px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px;
  margin: 0;
  padding: 2px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(255,255,255,.018);
}
.diff-aspect-tab {
  min-width: 70px;
  padding: 0 11px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 8px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  text-align: left;
  font-size: 11px;
  font-weight: 750;
  transition: color .18s ease, background-color .18s ease, box-shadow .18s ease;
}
.diff-aspect-tab:hover {
  color: var(--text);
  background: rgba(139,108,255,.055);
}
.diff-aspect-tab.is-active {
  color: var(--text);
  background: rgba(139,108,255,.14);
  box-shadow: inset 0 0 0 1px rgba(166,139,255,.34), 0 0 18px rgba(99,70,180,.08);
}
.diff-toolbar {
  min-height: 36px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.diff-toolbar .select, .diff-toolbar .input { min-width: 125px; height: 32px; border-color: var(--line); background-color: rgba(255,255,255,.025); }
.diff-toolbar .search-box-simple { flex: 0 1 210px; min-width: 150px; }
.diff-toolbar-divider { width: 1px; height: 22px; margin: 0 4px; background: var(--line); }
.diff-section-nav {
  display: flex;
  align-items: center;
  gap: 3px;
  margin-top: 7px;
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
  scrollbar-width: none;
}
.diff-section-nav::-webkit-scrollbar { display: none; }
.diff-section-tab {
  height: 39px;
  padding: 0 13px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 0;
  border-bottom: 2px solid transparent;
  color: var(--faint);
  background: transparent;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
  transition: color .18s ease, border-color .18s ease, background-color .18s ease;
}
.diff-section-tab:hover { color: var(--text); background: rgba(139,108,255,.035); }
.diff-section-tab.is-active { color: var(--text); border-bottom-color: var(--accent-2); }
.diff-section-tab span {
  min-width: 20px;
  height: 19px;
  padding: 0 6px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  color: var(--muted);
  background: rgba(255,255,255,.05);
  font-size: 9px;
}
.diff-section-tab.is-active span { color: var(--accent-2); background: rgba(139,108,255,.13); }
.diff-list { gap: 0; }
.diff-feed {
  padding-top: 13px;
  display: flex;
  flex-direction: column;
  gap: 11px;
}
.diff-story {
  padding: 16px 18px 14px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 17px;
  background:
    radial-gradient(circle at 8% 0%, rgba(139,108,255,.07), transparent 31%),
    rgba(18,18,24,.58);
  box-shadow: inset 0 1px rgba(255,255,255,.018);
  transition: border-color .18s ease, background-color .18s ease, box-shadow .18s ease;
}
.diff-story:hover {
  border-color: rgba(139,108,255,.24);
  box-shadow: inset 0 1px rgba(255,255,255,.025), 0 0 24px rgba(74,46,142,.055);
}
.diff-story > header {
  min-height: 28px;
  display: grid;
  grid-template-columns: minmax(220px, auto) minmax(0, 1fr) 30px;
  align-items: center;
  gap: 10px;
}
.diff-story-platforms { display: flex; align-items: center; gap: 7px; color: var(--faint); }
.diff-story-platforms .platform-mark { border: 0; background: transparent; box-shadow: none; }
.diff-story-platforms b { color: var(--muted); font-size: 10.5px; }
.diff-story-platforms > span { font-size: 9px; }
.diff-story-tags { display: flex; align-items: center; justify-content: flex-end; gap: 5px; min-width: 0; }
.diff-story-body { margin-top: 12px; }
.diff-story h2 { font-size: 15px; line-height: 1.38; letter-spacing: -.015em; }
.diff-story .diff-summary { margin: 5px 0 0; max-width: 1040px; color: var(--muted); font-size: 11.5px; line-height: 1.58; }
.diff-decision-note {
  margin-top: 11px;
  padding: 8px 11px;
  border-left: 2px solid var(--accent);
  border-radius: 0 10px 10px 0;
  background: linear-gradient(90deg, rgba(139,108,255,.085), transparent 78%);
}
.diff-decision-note > span { color: var(--accent-2); font-size: 8.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.diff-decision-note p { margin-top: 3px; color: var(--text); font-size: 11px; line-height: 1.5; }
.diff-story .diff-more { margin: 9px 0 0; border: 0; border-radius: 0; background: transparent; }
.diff-story .diff-more summary { width: max-content; padding: 2px 0; color: var(--accent-2); }
.diff-story .diff-more[open] summary { border: 0; }
.diff-story .diff-more > div { margin-top: 8px; padding: 12px 0 0; border-top: 1px solid var(--line); }
.diff-story > footer {
  min-height: 32px;
  margin-top: 12px;
  padding-top: 11px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--line);
}
.diff-story > footer > span { color: var(--faint); font-size: 9.5px; }
.diff-story-actions { display: flex; align-items: center; justify-content: flex-end; gap: 7px; }
.diff-story-actions .btn { height: 29px; padding: 0 12px; font-size: 10px; }
.diff-decision-modal > p { margin-bottom: 16px; color: var(--muted); font-size: 12px; line-height: 1.6; }
.diff-editor-more { margin-top: 8px; }

/* ── Services partagés : des lignes simples. */
.foundation-group { margin-bottom: 28px; }
.foundation-group > header { margin: 0 2px 7px; }
.foundation-group > header h2 { color: var(--muted); font-size: 11px; text-transform: none; }
.foundation-list { border-top: 1px solid var(--line); }
.foundation-row,
.foundation-card.foundation-row {
  min-height: 74px;
  padding: 10px 3px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto 16px;
  align-items: center;
  gap: 12px;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  cursor: pointer;
  transition: padding .16s, background .16s;
}
.foundation-row:hover { padding-left: 9px; background: linear-gradient(90deg, rgba(139,108,255,.045), transparent 68%); }
.foundation-card-icon { width: 36px; height: 36px; border-radius: 50%; }
.foundation-row h3 { font-size: 12px; }
.foundation-row p { margin-top: 2px; color: var(--muted); font-size: 10.5px; line-height: 1.4; }
.foundation-row-arrow { color: var(--faint); font-size: 20px; }

/* ── VPS : quatre lignes, détails seulement après ouverture. */
.server-list { border-top: 1px solid var(--line); }
.server-row {
  min-height: 78px;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto 18px;
  align-items: center;
  gap: 12px;
  padding: 9px 3px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  transition: padding .16s, background .16s;
}
.server-row:hover { padding-left: 9px; background: linear-gradient(90deg, rgba(139,108,255,.045), transparent 68%); }
.server-row.control-server { margin-top: 16px; border-top: 1px dashed var(--line-strong); background: transparent; }
.server-row-icon { width: 36px; height: 36px; display: grid; place-items: center; color: var(--accent-2); border-radius: 50%; background: var(--accent-soft); }
.server-row b, .server-row small { display: block; }
.server-row b { font-size: 12.5px; }
.server-row small { color: var(--faint); font: 9px var(--font-mono); }
.server-row-state { display: flex; align-items: center; gap: 7px; color: var(--muted); font-size: 10px; }
.server-row-arrow { color: var(--faint); font-size: 20px; }
.server-detail-status { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 11px; }
.server-detail h3 { margin-top: 14px; font-size: 16px; }
.server-detail > p { margin-top: 6px; color: var(--muted); font-size: 11.5px; line-height: 1.6; }
.server-detail-history { margin-top: 18px; border-top: 1px solid var(--line); }
.server-detail-history h4 { padding: 12px 0 5px; font-size: 10px; color: var(--faint); }
.server-detail-history > div { padding: 8px 0; border-bottom: 1px solid var(--line); }
.server-detail-history b, .server-detail-history small { display: block; }
.server-detail-history b { font-size: 10.5px; }
.server-detail-history small { color: var(--faint); font-size: 8.5px; }

/* ── Paramètres : réglages simples sur toute la largeur disponible. */
.settings-grid {
  width: 100%;
  max-width: none;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.settings-card { min-height: 0; margin-bottom: 0; padding: 19px; border-radius: 16px; }
.settings-card:last-child { grid-column: 1 / -1; }
.settings-card h2 { margin-bottom: 15px; font-size: 15px; }
.key-val { letter-spacing: .08em; }

/* ── Survols stables : on éclaire les éléments sans les déplacer. */
.house:hover,
.card-hover:hover,
.btn:hover,
.client-snapshot:hover,
.media-album:hover .media-album-art {
  transform: none;
}

.memory-card.card-hover:hover { padding-left: 4px; }
.home-stream-row:hover { padding-left: 2px; }
.foundation-row:hover,
.server-row:hover { padding-left: 3px; }

.attention-row:hover i,
.home-signal:hover i { transform: none; }

.media-card:hover .media-thumb img,
.media-card:hover .media-thumb video,
.gallery-item:hover .gallery-thumb img,
.gallery-item:hover .gallery-thumb video { transform: none; }

@media (max-width: 1180px) {
  .client-page-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .media-albums-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .main { padding: 26px 24px 48px; }
  .diff-page-intro { align-items: flex-start; flex-direction: column; gap: 7px; }
  .home-social-layout { grid-template-columns: 1fr; gap: 30px; }
  .home-social-rail { padding-left: 0; border-left: 0; }
  .client-page-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .media-albums-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .architecture-map { padding: 20px; }
  .architecture-map-head { align-items: flex-start; flex-direction: column; gap: 6px; }
  .settings-grid { grid-template-columns: 1fr; }
  .settings-card:last-child { grid-column: auto; }
}

@media (max-width: 680px) {
  .home-signals { grid-template-columns: 1fr; }
  .home-signal { min-height: 50px; padding: 0 2px; border-right: 0; border-bottom: 1px solid var(--line); }
  .home-signal:last-child { border-bottom: 0; }
  .client-page-grid { grid-template-columns: 1fr; }
  .media-albums-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .platform-card-premium { height: 160px; }
  .gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .journal-toolbar-simple, .agent-toolbar-simple { align-items: stretch; }
  .journal-toolbar-simple .search-box, .journal-toolbar-simple .search-box .input,
  .agent-toolbar-simple .search-box, .agent-toolbar-simple .search-box .input { width: 100%; }
  .journal-entry { padding: 14px; grid-template-columns: 34px minmax(0, 1fr); gap: 11px; }
  .journal-entry-icon { width: 34px; height: 34px; border-radius: 10px; }
  .journal-entry-main > header { align-items: flex-start; flex-direction: column; gap: 7px; }
  .journal-entry-signals { justify-content: flex-start; }
  .journal-entry-main > footer { align-items: flex-start; flex-direction: column; gap: 7px; }
  .diff-story { padding: 14px; }
  .diff-story > header { grid-template-columns: minmax(0, 1fr) 30px; }
  .diff-story-platforms { grid-column: 1; }
  .diff-story-tags { grid-column: 1; grid-row: 2; justify-content: flex-start; }
  .diff-story > header > .icon-btn { grid-column: 2; grid-row: 1; }
  .diff-story > footer { align-items: flex-start; flex-direction: column; }
  .diff-story-actions { width: 100%; justify-content: flex-start; flex-wrap: wrap; }
}

@media (max-width: 1180px) {
  .shared-foundation { grid-template-columns: 1fr; }
  .shared-foundation-items { grid-template-columns: repeat(4, 1fr); }
  .media-catalog-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .architecture-product-flow { grid-template-columns: 1fr; }
}

@media (max-width: 1600px) and (min-width: 1181px) {
  .media-albums-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 820px) {
  .shared-foundation-items { grid-template-columns: 1fr 1fr; }
  .media-feature-showcase.is-featured { grid-column: span 1; }
  .media-feature-showcase.is-featured .media-feature-showcase-cover { aspect-ratio: 16 / 9; }
  .media-gallery-hero { grid-template-columns: 1fr; align-items: start; }
  .media-gallery-back { justify-self: start; }
  .diff-sides { grid-template-columns: 1fr; }
  .diff-toolbar { align-items: stretch; flex-wrap: wrap; }
  .diff-toolbar .select, .diff-toolbar .input, .diff-toolbar .search-box-simple { width: 100%; max-width: none; }
  .diff-toolbar-divider { display: none; }
  .diff-aspect-nav { width: 100%; }
  .compare-word { display: none; }
  .architecture-window { min-height: 0; margin-top: 0; padding: 19px; }
}

@media (max-width: 600px) {
  .shared-foundation-items, .media-catalog-grid { grid-template-columns: 1fr; }
  .media-catalog-head { align-items: flex-start; flex-direction: column; }
  .platform-card-premium { min-height: 0; }
  .foundation-explainer { grid-template-columns: 1fr; }
  .foundation-grid { grid-template-columns: 1fr; }
  .diff-card-simple > header { flex-direction: column; }
  .diff-card-simple > header > .btn { align-self: flex-start; }
}

@media (max-width: 1180px) {
  .version-profile-hero { grid-template-columns: minmax(240px, .85fr) minmax(280px, 1.15fr); }
  .version-profile-hero-simple { grid-template-columns: minmax(230px, .75fr) minmax(280px, 1.25fr) 34px; }
  .version-profile-actions { grid-column: 1 / -1; justify-content: flex-start; }
}

@media (max-width: 900px) {
  .version-profile-hero { grid-template-columns: 1fr; gap: 14px; padding: 22px 2px; }
  .version-profile-hero-simple { grid-template-columns: minmax(0, 1fr) 34px; }
  .version-profile-hero-simple .version-profile-description { grid-column: 1 / -1; grid-row: 2; }
  .version-profile-hero-simple .version-profile-edit { grid-column: 2; grid-row: 1; }
  .version-profile-description { max-width: none; }
  .version-profile-layout { grid-template-columns: 1fr; gap: 30px; }
  .version-activity { padding: 24px 0 0; border-top: 1px solid var(--line); border-left: 0; }
}

@media (max-width: 680px) {
  .version-tabs { display: flex; }
  .version-tab { flex: 0 0 118px; height: 58px; }
  .version-feature-list { grid-template-columns: 1fr; }
  .version-profile-actions { align-items: stretch; }
  .version-profile-actions .btn { flex: 1 1 auto; }
  .version-change-row { grid-template-columns: 32px minmax(0, 1fr); }
  .version-change-row time { grid-column: 2; margin-top: -6px; }
  .version-change-copy b { white-space: normal; }
}
