/* Layout: sidebar sombre + zone de travail claire ; cartes pour les chiffres, tableaux nus pour les listes. */
:root {
  --ink: #0f1b2d;
  --ink-2: #1a2a42;
  --ink-text: #dfe7f2;
  --ink-mute: #8ea0b8;
  --bg: #f1f4f3;
  --surface: #ffffff;
  --surface-2: #f6f8f7;
  --line: #dde4e2;
  --text: #14202e;
  --mute: #5d6b7a;
  --brand: #0b7a5a;
  --brand-2: #0a6349;
  --brand-soft: #dff3ea;
  --gold: #e3a71b;
  --gold-soft: #fbf0d3;
  --red: #c8372d;
  --red-soft: #fbe3e0;
  --blue: #2563a8;
  --blue-soft: #e0ecf8;
  --amber: #b86e00;
  --amber-soft: #fdecd0;
  --violet: #6a4fb3;
  --violet-soft: #ebe5f8;
  --shadow: 0 1px 2px rgba(15, 27, 45, .05), 0 6px 20px rgba(15, 27, 45, .05);
  --font-display: 'Sora', 'Segoe UI', system-ui, sans-serif;
  --font-body: 'Public Sans', 'Segoe UI', system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0b1320; --surface: #121e30; --surface-2: #17263b; --line: #243650; --text: #e6edf6; --mute: #9aabbf;
    --brand: #2bbf8e; --brand-2: #4fd2a5; --brand-soft: #123a30; --gold-soft: #3a2f10; --red: #ff7a6e; --red-soft: #3d1b19;
    --blue: #7db4f0; --blue-soft: #14304f; --amber: #f0b254; --amber-soft: #3b2a0c; --violet: #b3a0ee; --violet-soft: #2a2250;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 6px 20px rgba(0,0,0,.3); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0b1320; --surface: #121e30; --surface-2: #17263b; --line: #243650; --text: #e6edf6; --mute: #9aabbf;
  --brand: #2bbf8e; --brand-2: #4fd2a5; --brand-soft: #123a30; --gold-soft: #3a2f10; --red: #ff7a6e; --red-soft: #3d1b19;
  --blue: #7db4f0; --blue-soft: #14304f; --amber: #f0b254; --amber-soft: #3b2a0c; --violet: #b3a0ee; --violet-soft: #2a2250;
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 6px 20px rgba(0,0,0,.3); color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { height: 100%; }
body { background: var(--bg); color: var(--text); font-family: var(--font-body); font-size: 14px; line-height: 1.45; margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 600; margin: 0; letter-spacing: -.01em; text-wrap: balance; }
a { color: var(--brand); }
.num { font-variant-numeric: tabular-nums; }
.mute { color: var(--mute); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ---------- Coque ---------- */
#app { min-height: 100%; }
.shell { display: grid; grid-template-columns: 252px minmax(0, 1fr); min-height: 100vh; }
.side { background: var(--ink); color: var(--ink-text); position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 0 0 12px; overflow-y: auto; }
.side::before { content: ""; display: block; height: 4px; background: linear-gradient(90deg, #ce1126 0 33.3%, #fcd116 33.3% 66.6%, #009460 66.6%); flex: none; }
.brand { display: flex; gap: 12px; align-items: center; padding: 20px 20px 18px; }
.brand-mark { width: 38px; height: 38px; border-radius: 10px; background: var(--gold); color: var(--ink); display: grid; place-items: center; font-family: var(--font-display); font-weight: 600; font-size: 15px; flex: none; }
.brand-name { font-family: var(--font-display); font-weight: 600; font-size: 16px; color: #fff; line-height: 1.15; }
.brand-by { font-size: 11.5px; color: var(--ink-mute); margin-top: 2px; }
.nav { display: flex; flex-direction: column; gap: 2px; padding: 4px 12px; }
.nav button { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; background: none; border: 0; color: var(--ink-text); padding: 10px 12px; border-radius: 10px; cursor: pointer; font-weight: 500; }
.nav button:hover { background: var(--ink-2); }
.nav button.on { background: var(--ink-2); color: #fff; box-shadow: inset 3px 0 0 var(--gold); }
.nav svg { width: 19px; height: 19px; flex: none; opacity: .9; }
.nav .badge-n { margin-left: auto; background: var(--gold); color: var(--ink); font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 99px; }
.side-foot { margin-top: auto; padding: 14px 16px 4px; border-top: 1px solid #ffffff14; display: grid; gap: 10px; }
.side-foot label { font-size: 12px; color: var(--ink-mute); }
.side-foot select { width: 100%; background: var(--ink-2); color: #fff; border: 1px solid #ffffff22; border-radius: 8px; padding: 8px 10px; }
.me { display: flex; align-items: center; gap: 10px; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--brand); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 12px; flex: none; }
.me small { display: block; color: var(--ink-mute); font-size: 11.5px; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { display: flex; align-items: center; gap: 12px; padding: 12px 28px; background: var(--surface); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; flex-wrap: wrap; }
.topbar .t-title { font-family: var(--font-display); font-weight: 600; font-size: 15px; margin-right: auto; display: flex; align-items: center; gap: 10px; min-width: 0; }
.btn.menu-btn { display: none; }
.demo-chip { font-family: var(--font-body); font-size: 12px; font-weight: 500; background: var(--surface-2); color: var(--mute); border: 1px solid var(--line); padding: 2px 8px; border-radius: 6px; }
.sync { display: inline-flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 600; padding: 5px 11px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface-2); cursor: pointer; }
.sync i { width: 8px; height: 8px; border-radius: 50%; background: var(--brand); display: inline-block; }
.sync.pending { background: var(--amber-soft); color: var(--amber); border-color: transparent; }
.sync.pending i { background: var(--amber); }
.sync.off { background: var(--red-soft); color: var(--red); border-color: transparent; }
.sync.off i { background: var(--red); }
.page { padding: 26px 28px 60px; max-width: 1360px; width: 100%; margin: 0 auto; display: grid; gap: 22px; align-content: start; }
.page-head { display: flex; gap: 14px; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; }
.page-head h1 { font-size: 24px; }
.page-head p { margin: 4px 0 0; color: var(--mute); }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.grow { flex: 1 1 auto; }

/* ---------- Composants ---------- */
.btn { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--text); padding: 8px 16px; border-radius: 10px; cursor: pointer; font-weight: 500; font-size: 13.5px; white-space: nowrap; }
.btn:hover { background: var(--surface-2); }
.btn.primary { background: var(--brand); color: #fff; border-color: transparent; }
.btn.primary:hover { background: var(--brand-2); }
:root[data-theme="dark"] .btn.primary { color: #06231a; }
.btn.gold { background: var(--gold); color: var(--ink); border-color: transparent; }
.btn.sm { padding: 6px 11px; font-size: 12.5px; border-radius: 8px; }
.btn.danger { color: var(--red); }
.btn svg { width: 16px; height: 16px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); min-width: 0; }
.card-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 16px 18px 0; flex-wrap: wrap; }
.card-h h2 { font-size: 15px; }
.card-b { padding: 14px 18px 18px; }
.grid { display: grid; gap: 16px; }
.g-kpi { grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.g-kpi6 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 700px) { .g-kpi6 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.g-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 430px), 1fr)); }
.g-dash { grid-template-columns: minmax(0, 1fr) minmax(0, 1.7fr); }
@media (max-width: 1100px) { .g-dash { grid-template-columns: minmax(0, 1fr); } }
.g-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }
.kpi { padding: 16px 18px; display: grid; gap: 6px; }
.kpi .k-l { color: var(--mute); font-size: 13px; font-weight: 500; }
.kpi .k-v { font-family: var(--font-display); font-size: 28px; font-weight: 600; letter-spacing: -.01em; line-height: 1.1; overflow-wrap: anywhere; }
.kpi .k-v small { font-size: 13px; font-weight: 500; color: var(--mute); margin-left: 4px; }
.kpi .k-s { font-size: 12px; color: var(--mute); }
.up { color: var(--brand); font-weight: 500; }
.down { color: var(--red); font-weight: 500; }
.seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--line); border-radius: 11px; padding: 3px; gap: 2px; flex-wrap: wrap; }
.seg button { border: 0; background: none; padding: 7px 13px; border-radius: 8px; cursor: pointer; font-weight: 600; color: var(--mute); font-size: 13px; }
.seg button.on { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.seg button .cnt { background: var(--line); border-radius: 99px; padding: 0 7px; font-size: 11.5px; margin-left: 5px; }
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 99px; font-size: 12px; font-weight: 600; white-space: nowrap; background: var(--surface-2); color: var(--mute); }
.b-green { background: var(--brand-soft); color: var(--brand); }
.b-gold { background: var(--gold-soft); color: var(--amber); }
.b-red { background: var(--red-soft); color: var(--red); }
.b-blue { background: var(--blue-soft); color: var(--blue); }
.b-violet { background: var(--violet-soft); color: var(--violet); }
.b-gray { background: var(--surface-2); color: var(--mute); border: 1px solid var(--line); }
.tbl-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { text-align: left; font-size: 12px; color: var(--mute); font-weight: 500; padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--surface); position: sticky; top: 0; }
td { padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tbody tr:last-child td { border-bottom: 0; }
tr.click { cursor: pointer; }
tr.click:hover td { background: var(--surface-2); }
td.r, th.r { text-align: right; }
.cname { font-weight: 600; }
.cmeta { color: var(--mute); font-size: 12px; }
.empty { padding: 36px 18px; text-align: center; color: var(--mute); }
.tools { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.input, .select, .textarea { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px; min-width: 0; width: 100%; }
.input:focus, .select:focus, .textarea:focus { outline: 2px solid var(--brand); outline-offset: -1px; border-color: transparent; }
.tools .input.search { flex: 1 1 240px; width: auto; }
.tools .select { width: auto; flex: 0 1 170px; }
.textarea { min-height: 72px; resize: vertical; }
.form { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; }
.form .full { grid-column: 1 / -1; }
.fld { display: grid; gap: 5px; align-content: start; min-width: 0; }
.fld > label { font-size: 12.5px; font-weight: 600; color: var(--mute); }
.fld .err { color: var(--red); font-size: 12px; }
.req::after { content: " *"; color: var(--red); }

.overlay { position: fixed; inset: 0; background: rgba(8, 15, 28, .55); display: grid; place-items: center; padding: 16px; z-index: 100; overflow-y: auto; }
.modal { background: var(--surface); border-radius: 16px; width: min(760px, 100%); max-height: calc(100vh - 32px); display: flex; flex-direction: column; box-shadow: 0 30px 80px rgba(0,0,0,.35); }
.modal.sm { width: min(520px, 100%); }
.modal-h { display: flex; justify-content: space-between; align-items: center; padding: 18px 22px; border-bottom: 1px solid var(--line); gap: 12px; }
.modal-h h2 { font-size: 17px; }
.modal-b { padding: 20px 22px; overflow-y: auto; }
.modal-f { padding: 14px 22px; border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; }
.x { background: none; border: 0; cursor: pointer; font-size: 22px; line-height: 1; color: var(--mute); padding: 4px 8px; border-radius: 8px; }
.x:hover { background: var(--surface-2); }
#toasts { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(18px + env(safe-area-inset-bottom, 0px)); display: grid; gap: 8px; z-index: 200; width: min(92vw, 460px); }
.toast { background: var(--ink); color: #fff; padding: 12px 16px; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,.3); border-left: 4px solid var(--gold); font-weight: 500; }
.toast.ok { border-left-color: var(--brand); }

/* Fiches, listes à clés */
.kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px 22px; }
.kv dt { font-size: 12px; color: var(--mute); font-weight: 600; margin-bottom: 2px; }
.kv dd { margin: 0; font-weight: 500; overflow-wrap: anywhere; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tabs button { background: none; border: 0; padding: 11px 16px; cursor: pointer; font-weight: 600; color: var(--mute); border-bottom: 3px solid transparent; white-space: nowrap; }
.tabs button.on { color: var(--text); border-bottom-color: var(--brand); }
.back { background: none; border: 0; color: var(--mute); cursor: pointer; font-weight: 600; padding: 0; display: inline-flex; gap: 6px; align-items: center; }
.back:hover { color: var(--text); }
.id-tag { font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace; font-size: 12px; background: var(--surface-2); border: 1px solid var(--line); padding: 2px 8px; border-radius: 6px; color: var(--mute); }
.note { padding: 11px 14px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); }
.note small { color: var(--mute); display: block; margin-bottom: 3px; }
.next { background: var(--gold-soft); border: 1px solid transparent; border-radius: 12px; padding: 14px 16px; }
.next b { display: block; font-family: var(--font-display); }
.stack { display: grid; gap: 10px; }

/* Alertes */
.alerts { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.alert { display: flex; gap: 12px; align-items: center; padding: 13px 14px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); cursor: pointer; text-align: left; width: 100%; }
.alert:hover { border-color: var(--brand); }
.alert .n { font-family: var(--font-display); font-weight: 600; font-size: 22px; min-width: 32px; text-align: center; color: var(--text); }

/* Graphiques */
.bars { display: grid; gap: 11px; }
.bar-row { display: grid; grid-template-columns: 104px minmax(0, 1fr) 118px; gap: 12px; align-items: center; }
.bar-row .lbl { font-weight: 500; }
.bar-track { height: 12px; background: var(--surface-2); border-radius: 6px; overflow: hidden; }
.bar-fill { height: 100%; background: var(--brand); border-radius: 6px; min-width: 3px; }
.bar-row .val { text-align: right; font-weight: 500; font-variant-numeric: tabular-nums; }
.svgc text { fill: var(--mute); font-size: 11px; font-family: var(--font-body); }
.svgc .grid-l { stroke: var(--line); stroke-width: 1; }

/* Réseau */
.net-layout { display: grid; grid-template-columns: 290px minmax(0, 1fr); gap: 16px; align-items: start; }
.w-list { display: grid; gap: 6px; max-height: 620px; overflow-y: auto; padding: 10px; }
.w-item { display: grid; gap: 2px; text-align: left; border: 1px solid transparent; background: none; padding: 10px 12px; border-radius: 10px; cursor: pointer; }
.w-item:hover { background: var(--surface-2); }
.w-item.on { background: var(--brand-soft); border-color: var(--brand); }
.flow { display: grid; justify-items: center; gap: 4px; }
.flow .stepn { width: min(340px, 100%); border-radius: 12px; padding: 11px 16px; text-align: center; font-weight: 700; background: var(--surface-2); border: 1px solid var(--line); cursor: default; }
.flow .stepn.usine { background: var(--ink); color: #fff; border-color: transparent; letter-spacing: .06em; }
.flow .stepn.g { background: var(--brand-soft); color: var(--brand); border-color: transparent; }
.flow .stepn.d { background: var(--blue-soft); color: var(--blue); border-color: transparent; }
.flow .stepn.p { background: var(--gold-soft); color: var(--amber); border-color: transparent; }
.flow .stepn.f { background: var(--violet-soft); color: var(--violet); border-color: transparent; }
.flow .stepn small { display: block; font-weight: 500; opacity: .85; margin-top: 1px; }
.flow .arr { color: var(--mute); font-size: 18px; line-height: 1; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: 1px solid var(--line); background: var(--surface); border-radius: 99px; padding: 5px 12px; cursor: pointer; font-size: 12.5px; font-weight: 500; }
.chip:hover { border-color: var(--brand); }
.stat-pill { display: grid; gap: 2px; padding: 12px 14px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); text-align: left; cursor: pointer; }
.stat-pill b { font-family: var(--font-display); font-size: 22px; }
.stat-pill.on { border-color: var(--brand); background: var(--brand-soft); }
.net-svg { width: 100%; height: auto; display: block; }
.net-svg .node { cursor: pointer; }
.net-svg text { font-family: var(--font-body); }

/* Mode terrain */
.field { display: grid; gap: 14px; max-width: 760px; margin: 0 auto; }
.big-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; }
.big { display: grid; gap: 8px; justify-items: start; padding: 22px 20px; border-radius: 16px; border: 1px solid var(--line); background: var(--surface); cursor: pointer; text-align: left; box-shadow: var(--shadow); min-height: 118px; }
.big:hover { border-color: var(--brand); }
.big svg { width: 30px; height: 30px; color: var(--brand); }
.big b { font-family: var(--font-display); font-size: 17px; }
.big span { color: var(--mute); font-size: 12.5px; }
.big.accent { background: var(--brand); color: #fff; border-color: transparent; }
.big.accent svg, .big.accent span { color: #fff; }
.big.accent span { opacity: .85; }
.vis-card { display: flex; gap: 12px; align-items: center; justify-content: space-between; padding: 13px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); flex-wrap: wrap; }
.time { font-family: var(--font-display); font-weight: 700; font-size: 17px; min-width: 56px; }

/* Connexion */
.login { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); }
.login-art { background: var(--ink); color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: flex-start; position: relative; overflow: hidden; }
.swatches { display: flex; gap: 8px; align-items: flex-end; margin-top: auto; margin-bottom: 40px; max-width: 560px; }
.sw { flex: 1; min-width: 0; background: #fff; border-radius: 10px; padding: 6px 6px 8px; display: grid; gap: 8px; box-shadow: 0 8px 24px rgba(0,0,0,.25); }
.sw i { display: block; height: 96px; border-radius: 6px; }
.sw:nth-child(even) i { height: 120px; }
.sw span { color: #1f2a37; font-size: 11px; line-height: 1.25; padding: 0 2px; }
.sw span b { display: block; font-weight: 600; }
.login-art::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 5px; background: linear-gradient(90deg, #ce1126 0 33.3%, #fcd116 33.3% 66.6%, #009460 66.6%); }
.login-art h1 { font-size: clamp(28px, 3.4vw, 40px); line-height: 1.12; font-weight: 600; max-width: 20ch; }
.login-art p { color: var(--ink-mute); max-width: 38ch; font-size: 16px; }
.login-form { display: grid; place-items: center; padding: 32px 20px; }
.login-box { width: min(400px, 100%); display: grid; gap: 16px; }
.demo-acc { display: grid; gap: 8px; }
.demo-acc button { text-align: left; display: flex; gap: 10px; align-items: center; justify-content: space-between; padding: 10px 12px; border: 1px dashed var(--line); background: var(--surface); border-radius: 10px; cursor: pointer; }
.demo-acc button:hover { border-color: var(--brand); }
.mobnav { display: none; }
.hide-sm { }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12.5px; color: var(--mute); }
.legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; margin-right: 6px; }

@media (max-width: 1000px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .side { position: fixed; z-index: 90; left: 0; top: 0; width: 280px; transform: translateX(-102%); transition: transform .2s; }
  .side.open { transform: none; box-shadow: 0 0 0 100vmax rgba(8, 15, 28, .5); }
  .btn.menu-btn { display: inline-flex; }
  .net-layout { grid-template-columns: minmax(0, 1fr); }
  .w-list { max-height: 260px; }
  .login { grid-template-columns: minmax(0, 1fr); }
  .login-art { padding: 28px 20px; gap: 24px; }
  .sw i { height: 56px; } .sw:nth-child(even) i { height: 68px; } .sw span { display: none; }
  .login-art h1 { max-width: none; }
}
@media (max-width: 640px) {
  .swatches { display: none; }
  .page { padding: 18px 16px 90px; }
  .topbar { padding: 10px 16px; }
  .hide-sm { display: none !important; }
  .bar-row { grid-template-columns: 78px minmax(0, 1fr) 96px; gap: 8px; font-size: 12.5px; }
  .kpi .k-v { font-size: 23px; }
  .modal-b { padding: 16px; } .modal-h, .modal-f { padding-left: 16px; padding-right: 16px; }
  .mobnav { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; background: var(--surface); border-top: 1px solid var(--line); z-index: 30; padding-bottom: env(safe-area-inset-bottom, 0px); }
  .mobnav button { background: none; border: 0; padding: 9px 2px 8px; display: grid; justify-items: center; gap: 3px; font-size: 11px; color: var(--mute); font-weight: 600; cursor: pointer; }
  .mobnav button.on { color: var(--brand); }
  .mobnav svg { width: 21px; height: 21px; }
  #toasts { bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
}
@media (prefers-reduced-motion: reduce) { .side { transition: none; } }
/* Impression du rapport courant : retirer la navigation et les commandes. */
@media print {
  .side, .topbar, .mobnav, .page-head .row, #toasts, .overlay, #rp-grid > nav { display: none !important; }
  .main { margin-left: 0 !important; }
  .page { padding: 0 !important; }
  #rp-grid { display: block !important; }
  .card { box-shadow: none !important; break-inside: avoid; }
  .tbl-wrap { overflow: visible !important; }
  body { background: white !important; }
}

.sub-banner { padding: 10px 18px; font-weight: 600; font-size: 13.5px; background: var(--amber-soft); color: var(--amber); }
.sub-banner.red { background: var(--red-soft); color: var(--red); }

/* Carte Abonnement : la date d'accès est l'information principale. */
.sub-sum { display: flex; gap: 24px 48px; align-items: flex-end; flex-wrap: wrap; }
.sub-date { font-family: var(--font-display); font-size: 26px; font-weight: 600; line-height: 1.15; }
.sub-meta { display: flex; gap: 12px 32px; flex-wrap: wrap; margin: 0; }
.sub-meta dt { color: var(--mute); font-size: 12px; }
.sub-meta dd { margin: 2px 0 0; font-weight: 500; }
