/* ==========================================================================
   AXION WAN PULSE — supervision des liens internet
   Même charte que SONOS x SPOTIFY.
   Feuille de styles unique, sans étape de compilation.
   ========================================================================== */

@font-face {
  font-family: "Schibsted Grotesk";
  src: url("../fonts/schibsted-grotesk-latin-wght-normal.woff2") format("woff2");
  font-weight: 400 900;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Schibsted Grotesk";
  src: url("../fonts/schibsted-grotesk-latin-ext-wght-normal.woff2") format("woff2");
  font-weight: 400 900;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --night: #0f1b33;
  --night-2: #172644;
  --night-3: #22345a;
  --mist: #edf1f6;
  --surface: #ffffff;
  --surface-2: #f6f8fb;
  --line: #dfe5ee;
  --line-strong: #c9d2df;
  --ink: #13213a;
  --ink-2: #44546e;
  --muted: #6b7a92;
  --accent: #2f5bea;
  --accent-ink: #2149cc;
  --accent-soft: #e8eeff;

  --ok: #14a672;
  --ok-soft: #e3f6ee;
  --warn: #d9890b;
  --warn-soft: #fdf3e1;
  --bad: #d63c3c;
  --bad-soft: #fde9e9;
  --idle: #8d9bb0;
  --idle-soft: #eef1f6;

  --radius-lg: 18px;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(15, 27, 51, .06), 0 8px 24px -12px rgba(15, 27, 51, .18);
  --shadow-pop: 0 24px 60px -20px rgba(15, 27, 51, .45);
  --side: 252px;
  --font: "Schibsted Grotesk", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--mist);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent-ink); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; letter-spacing: -.01em; }
p { margin: 0; }
img { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
.tally b, output, time, .facts dd, table.data td, .overview-sub { font-variant-numeric: tabular-nums; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.icon { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon.fill { fill: currentColor; stroke: none; }

/* ---------- Structure ---------- */

.app { display: grid; grid-template-columns: var(--side) 1fr; min-height: 100vh; }

.side {
  position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column;
  background: var(--night);
  color: #c9d4e8;
  padding: 26px 18px 18px;
}
.brand { display: flex; align-items: center; gap: 12px; padding: 0 8px 26px; color: #fff; }
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 40px; height: 40px; border-radius: 12px;
  display: grid; place-items: center;
  background: linear-gradient(160deg, #3b6bff, #2246c7);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.25);
}
.brand-mark .bars { display: flex; align-items: flex-end; gap: 3px; height: 18px; }
.brand-mark .bars i { width: 3px; border-radius: 2px; background: #fff; }
.brand-mark .bars i:nth-child(1) { height: 8px; }
.brand-mark .bars i:nth-child(2) { height: 18px; }
.brand-mark .bars i:nth-child(3) { height: 12px; }
.brand-mark .bars i:nth-child(4) { height: 15px; }
.brand-name { font-weight: 700; font-size: 16px; letter-spacing: -.01em; line-height: 1.15; }
.brand-sub { display: block; white-space: nowrap; font-weight: 450; font-size: 12.5px; color: #8fa0c0; letter-spacing: 0; }

.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: 10px;
  color: #b9c6de; font-weight: 500;
  transition: background .15s, color .15s;
}
.nav a:hover { background: var(--night-2); color: #fff; text-decoration: none; }
.nav a.active { background: var(--night-3); color: #fff; }
.nav a.active .icon { color: #7fa0ff; }
.nav .count {
  margin-left: auto; min-width: 22px; padding: 1px 7px; border-radius: 99px;
  background: var(--bad); color: #fff; font-size: 12px; font-weight: 650; text-align: center;
}
.nav-sep { height: 1px; background: rgba(255,255,255,.07); margin: 14px 8px; }

.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: 12px; }
.demo-flag {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 12px; border-radius: 12px;
  background: rgba(229, 154, 18, .12); color: #f3c470; font-size: 13px; line-height: 1.4;
}
.demo-flag .icon { width: 16px; height: 16px; margin-top: 1px; }
.me { display: flex; align-items: center; gap: 10px; padding: 10px 8px 0; border-top: 1px solid rgba(255,255,255,.07); }
.avatar {
  width: 34px; height: 34px; border-radius: 50%; flex: none;
  display: grid; place-items: center;
  background: var(--night-3); color: #fff; font-size: 13px; font-weight: 650;
}
.me-name { color: #fff; font-weight: 550; font-size: 14px; line-height: 1.2; }
.me-role { color: #8fa0c0; font-size: 12.5px; }
.me form { margin-left: auto; }
.icon-btn {
  width: 34px; height: 34px; border-radius: 10px; border: 0;
  display: grid; place-items: center; cursor: pointer;
  background: transparent; color: inherit;
}
.icon-btn:hover { background: rgba(255,255,255,.08); }

.page-main { min-width: 0; padding: 34px 40px 56px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 26px; }
.page-head h1 { font-size: 28px; font-weight: 700; }
.page-head .lede { color: var(--muted); margin-top: 6px; }
.head-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.back { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-weight: 500; margin-bottom: 10px; }
.back .icon { width: 16px; height: 16px; }

/* ---------- Boutons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px; border-radius: 10px;
  border: 1px solid var(--line-strong); background: var(--surface);
  color: var(--ink); font-weight: 600; font-size: 14.5px;
  cursor: pointer; white-space: nowrap;
  transition: background .15s, border-color .15s, box-shadow .15s, transform .05s;
}
.btn:hover { background: var(--surface-2); text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn .icon { width: 17px; height: 17px; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-ink); }
.btn-danger { color: var(--bad); }
.btn-danger:hover { background: var(--bad-soft); border-color: #f2b8b8; }
.btn-danger-solid { background: var(--bad); border-color: var(--bad); color: #fff; }
.btn-danger-solid:hover { background: #bd3030; }
.btn-ghost { border-color: transparent; background: transparent; }
.btn-ghost:hover { background: var(--idle-soft); }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13.5px; border-radius: 8px; }
.btn[disabled], .btn.is-busy { opacity: .55; pointer-events: none; }
.actions { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; }

/* ---------- Panneaux ---------- */

.panel {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); box-shadow: var(--shadow);
}
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 22px 0; }
.panel-head h2 { font-size: 16.5px; font-weight: 650; }
.panel-head .hint { color: var(--muted); font-size: 13.5px; }
.panel-body { padding: 18px 22px 22px; }
.stack { display: flex; flex-direction: column; gap: 22px; }

/* ---------- États ---------- */

.pill {
  display: inline-flex; align-items: center; gap: 7px;
  height: 26px; padding: 0 11px 0 9px; border-radius: 99px;
  font-size: 13px; font-weight: 600; white-space: nowrap;
  background: var(--idle-soft); color: var(--ink-2);
}
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--idle); }
.st-playing .pill, .pill.st-playing { background: var(--ok-soft); color: #0b7a53; }
.st-playing .pill::before, .pill.st-playing::before { background: var(--ok); box-shadow: 0 0 0 3px rgba(20,166,114,.18); }
.st-recovering .pill, .st-stopped .pill, .pill.st-recovering, .pill.st-stopped { background: var(--warn-soft); color: #9a5f00; }
.st-recovering .pill::before, .st-stopped .pill::before, .pill.st-recovering::before, .pill.st-stopped::before { background: var(--warn); }
.st-down .pill, .pill.st-down { background: var(--bad-soft); color: #b02a2a; }
.st-down .pill::before, .pill.st-down::before { background: var(--bad); }
.st-paused .pill, .pill.st-paused { background: var(--accent-soft); color: var(--accent-ink); }
.st-paused .pill::before, .pill.st-paused::before { background: var(--accent); }

/* ---------- Tableau de bord ---------- */

.overview {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 28px; align-items: center;
  padding: 26px 30px; margin-bottom: 26px;
  background: var(--night); color: #fff; border-radius: var(--radius-lg);
  position: relative; overflow: hidden;
}
.overview::after {
  content: ""; position: absolute; right: -60px; top: -80px; width: 320px; height: 320px; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(59,107,255,.35), transparent);
  pointer-events: none;
}
.overview-title { font-size: 30px; font-weight: 700; letter-spacing: -.02em; }
.overview-title .of { color: #8fa0c0; font-weight: 500; }
.overview-sub { color: #aebbd4; margin-top: 6px; display: flex; align-items: center; gap: 8px; }
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 rgba(20,166,114,.6); animation: ping 2s infinite; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(20,166,114,.55); } 70% { box-shadow: 0 0 0 10px rgba(20,166,114,0); } 100% { box-shadow: 0 0 0 0 rgba(20,166,114,0); } }
.tally { display: flex; gap: 10px; position: relative; z-index: 1; }
.tally div {
  min-width: 112px; padding: 12px 16px; border-radius: 14px;
  background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.08);
}
.tally b { display: block; font-size: 24px; font-weight: 700; line-height: 1.1; }
.tally span { color: #aebbd4; font-size: 13px; }
.tally .t-ok b { color: #4fd6a2; }
.tally .t-warn b { color: #ffbe55; }
.tally .t-off b { color: #c6d1e4; }

.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.segmented { display: inline-flex; padding: 4px; gap: 2px; border-radius: 12px; background: #e1e7f0; }
.segmented button, .segmented a {
  border: 0; background: transparent; height: 34px; padding: 0 14px; border-radius: 9px;
  font-weight: 600; font-size: 14px; color: var(--ink-2); cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
}
.segmented a:hover { text-decoration: none; }
.segmented .on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(15,27,51,.12); }
.segmented .n { font-size: 12px; color: var(--muted); font-weight: 600; }
.search {
  display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; width: 260px;
  border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); color: var(--muted);
}
.search input { border: 0; outline: 0; background: transparent; width: 100%; color: var(--ink); }

/* ---------- Fiche club ---------- */

.club-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 24px; }
.club-head h1 { font-size: 30px; font-weight: 700; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.club-head .lede { color: var(--muted); margin-top: 6px; display: flex; gap: 14px; flex-wrap: wrap; }
.club-head .lede span { display: inline-flex; align-items: center; gap: 6px; }
.club-head .lede .icon { width: 15px; height: 15px; }
.club-layout { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(320px, 1fr); gap: 22px; align-items: start; }

.notice {
  display: flex; align-items: center; gap: 14px; padding: 14px 18px; margin: 0 26px 22px; border-radius: 12px;
  background: var(--accent-soft); color: var(--accent-ink); font-weight: 550;
}
.notice .grow { flex: 1; }
.notice.warn { background: var(--warn-soft); color: #8a5500; }
.notice.bad { background: var(--bad-soft); color: #a32626; }
.notice .icon { width: 20px; height: 20px; }

.facts { display: grid; grid-template-columns: auto 1fr; gap: 10px 18px; font-size: 14px; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; font-weight: 550; text-align: right; }

.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { display: grid; grid-template-columns: 74px 12px 1fr; gap: 10px; font-size: 13.5px; padding: 7px 0; }
.timeline time { color: var(--muted); font-size: 12.5px; padding-top: 1px; }
.timeline .tl-dot { width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; background: var(--idle); }
.timeline .lv-success .tl-dot { background: var(--ok); }
.timeline .lv-warning .tl-dot { background: var(--warn); }
.timeline .lv-danger .tl-dot { background: var(--bad); }
.timeline .src { color: var(--muted); }

/* ---------- Tables ---------- */

.table-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: 14.5px; }
table.data th { text-align: left; font-weight: 600; color: var(--muted); font-size: 13px; padding: 14px 18px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.data td { padding: 14px 18px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.data tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover td { background: var(--surface-2); }
table.data .num { text-align: right; }
table.data .center { text-align: center; }
.cell-main { font-weight: 650; color: var(--ink); }
.cell-sub { color: var(--muted); font-size: 13px; }
.row-actions { display: flex; gap: 6px; justify-content: flex-end; }
.status-ok { color: var(--ok); font-weight: 600; }
.status-off { color: var(--muted); }
.pager { display: flex; justify-content: center; gap: 6px; padding: 18px; }
.pager a, .pager span { min-width: 36px; height: 36px; padding: 0 10px; border-radius: 9px; display: grid; place-items: center; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); font-weight: 600; font-size: 14px; }
.pager .on { background: var(--ink); border-color: var(--ink); color: #fff; }
.pager a:hover { text-decoration: none; background: var(--surface-2); }

/* ---------- Formulaires ---------- */

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.form-grid .full { grid-column: 1 / -1; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label, .field .label { font-weight: 600; font-size: 14px; }
.field .help { color: var(--muted); font-size: 13px; }
.input, select.input, textarea.input {
  height: 42px; padding: 0 13px; border: 1px solid var(--line-strong); border-radius: 10px;
  background: var(--surface); outline: none; width: 100%;
  transition: border-color .15s, box-shadow .15s;
}
textarea.input { height: auto; min-height: 90px; padding: 10px 13px; resize: vertical; }
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(47,91,234,.15); }
.input[readonly] { background: var(--surface-2); color: var(--ink-2); }
.input-group { display: flex; gap: 8px; }
.input-group .input { flex: 1; }
.field-error { color: var(--bad); font-size: 13px; font-weight: 550; }
.errors { padding: 12px 16px; border-radius: 12px; background: var(--bad-soft); color: #a32626; font-size: 14px; margin-bottom: 18px; }
.errors ul { margin: 6px 0 0; padding-left: 18px; }

.switch { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; padding: 14px 0; border-top: 1px solid var(--line); }
.switch:first-child { border-top: 0; padding-top: 0; }
.switch b { display: block; font-weight: 600; }
.switch span { color: var(--muted); font-size: 13.5px; }
.toggle { position: relative; width: 44px; height: 26px; flex: none; }
.toggle input { opacity: 0; width: 0; height: 0; position: absolute; }
.toggle i { position: absolute; inset: 0; border-radius: 99px; background: #cdd5e1; cursor: pointer; transition: background .2s; }
.toggle i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .2s; }
.toggle input:checked + i { background: var(--ok); }
.toggle input:checked + i::after { transform: translateX(18px); }
.toggle input:focus-visible + i { outline: 2px solid var(--accent); outline-offset: 2px; }

.checks { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.check { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-weight: 500; font-size: 14px; }
.check input { width: 17px; height: 17px; accent-color: var(--accent); }

.settings-layout { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 24px; align-items: start; }
.tabs-v { display: flex; flex-direction: column; gap: 4px; position: sticky; top: 24px; }
.tabs-v a { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 11px; color: var(--ink-2); font-weight: 550; }
.tabs-v a:hover { background: #e3e9f2; text-decoration: none; }
.tabs-v a.on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.tabs-v a.on .icon { color: var(--accent); }
.form-foot { display: flex; justify-content: center; gap: 10px; padding: 18px 22px; border-top: 1px solid var(--line); background: var(--surface-2); border-radius: 0 0 var(--radius-lg) var(--radius-lg); }
.copy-line { display: flex; gap: 8px; }
.copy-line .input { font-size: 13.5px; }
.callout { padding: 14px 16px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); font-size: 14px; color: var(--ink-2); }
.callout b { color: var(--ink); }
.callout.warn { background: var(--warn-soft); border-color: #f4d9a6; color: #7a4c00; }

/* ---------- Connexion ---------- */

.auth { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; background: var(--surface); }
.auth-art {
  background: var(--night); color: #fff; padding: 48px 56px;
  display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden;
}
.auth-art .brand { padding: 0; }
.auth-art h1 { font-size: 40px; font-weight: 700; letter-spacing: -.025em; max-width: 13ch; line-height: 1.1; }
.auth-art p { color: #aebbd4; max-width: 40ch; margin-top: 14px; font-size: 16px; }
.auth-art small { color: #6f82a6; }
.auth-form { display: grid; place-items: center; padding: 40px; }
.auth-form form { width: 100%; max-width: 380px; display: flex; flex-direction: column; gap: 16px; }
.auth-form h2 { font-size: 26px; font-weight: 700; }
.auth-form .lede { color: var(--muted); margin-top: -8px; }
.auth-form .btn { height: 46px; }
.remember { display: flex; align-items: center; gap: 8px; color: var(--ink-2); font-size: 14px; }
.remember input { width: 16px; height: 16px; accent-color: var(--accent); }

/* ---------- Modales et toasts maison ---------- */

.modal-root { position: fixed; inset: 0; z-index: 50; display: none; }
.modal-root.open { display: grid; place-items: center; padding: 20px; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(15, 27, 51, .55); backdrop-filter: blur(2px); animation: fade .15s ease-out; }
.modal {
  position: relative; width: 100%; max-width: 460px; max-height: calc(100vh - 40px); overflow: auto;
  background: var(--surface); border-radius: 18px; box-shadow: var(--shadow-pop);
  animation: pop .18s ease-out;
}
.modal.wide { max-width: 680px; }
.modal-head { display: flex; align-items: flex-start; gap: 14px; padding: 22px 24px 0; }
.modal-icon { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; flex: none; background: var(--accent-soft); color: var(--accent); }
.modal-icon.danger { background: var(--bad-soft); color: var(--bad); }
.modal-icon.warn { background: var(--warn-soft); color: var(--warn); }
.modal-icon .icon { width: 21px; height: 21px; }
.modal-head h3 { font-size: 18px; font-weight: 700; margin-top: 2px; }
.modal-head p { color: var(--ink-2); margin-top: 6px; font-size: 14.5px; }
.modal-close { margin-left: auto; color: var(--muted); }
.modal-close:hover { background: var(--idle-soft); color: var(--ink); }
.modal-body { padding: 20px 24px; }
.modal-foot { display: flex; justify-content: center; gap: 10px; padding: 16px 24px 22px; }
.modal-foot .btn { min-width: 130px; }
.choice-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.choice { height: 44px; border-radius: 10px; border: 1px solid var(--line-strong); background: var(--surface); font-weight: 600; cursor: pointer; }
.choice:hover { border-color: var(--accent); color: var(--accent-ink); }
.choice.on { background: var(--accent); border-color: var(--accent); color: #fff; }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(.98); } }

.toasts { position: fixed; right: 24px; bottom: 24px; z-index: 60; display: flex; flex-direction: column; gap: 10px; align-items: flex-end; pointer-events: none; }
.toast {
  pointer-events: auto; display: flex; align-items: flex-start; gap: 12px; max-width: 420px;
  padding: 14px 16px; border-radius: 14px; background: var(--night); color: #fff;
  box-shadow: var(--shadow-pop); font-size: 14.5px; animation: slide .2s ease-out;
}
.toast .icon { width: 19px; height: 19px; margin-top: 1px; }
.toast.success .icon { color: #4fd6a2; }
.toast.error .icon { color: #ff8a8a; }
.toast.info .icon { color: #8fb0ff; }
.toast.out { opacity: 0; transform: translateY(6px); transition: .25s; }
@keyframes slide { from { opacity: 0; transform: translateY(10px); } }

.spinner { width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.skeleton { background: linear-gradient(90deg, #eef1f6, #f6f8fb, #eef1f6); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: 10px; }
@keyframes shimmer { to { background-position: -200% 0; } }

.mobile-bar { display: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; }
}

/* ==========================================================================
   Version mobile (n'affecte pas l'affichage ordinateur)
   ========================================================================== */
@media (max-width: 1180px) and (min-width: 861px) {
  .club-layout { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .app { grid-template-columns: 1fr; padding-bottom: 72px; }
  .side { display: none; }
  .mobile-bar {
    display: flex; position: sticky; top: 0; z-index: 30; align-items: center; justify-content: space-between;
    padding: 12px 16px; background: var(--night); color: #fff;
  }
  .mobile-bar .brand { padding: 0; }
  .mobile-bar .brand-mark { width: 34px; height: 34px; border-radius: 10px; }
  .mobile-nav {
    display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
    background: var(--surface); border-top: 1px solid var(--line); padding: 6px 4px calc(6px + env(safe-area-inset-bottom));
  }
  .mobile-nav a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; color: var(--muted); font-size: 11.5px; font-weight: 600; }
  .mobile-nav a.active { color: var(--accent); }
  .mobile-nav a:hover { text-decoration: none; }
  .mobile-nav .icon { width: 21px; height: 21px; }
  .page-main { padding: 20px 16px 32px; }
  .page-head, .club-head { flex-direction: column; align-items: stretch; gap: 14px; }
  .page-head h1, .club-head h1 { font-size: 24px; }
  .head-actions { justify-content: center; }
  .overview { grid-template-columns: 1fr; padding: 22px; gap: 18px; }
  .overview-title { font-size: 24px; }
  .tally { display: grid; grid-template-columns: repeat(3, 1fr); }
  .tally div { min-width: 0; padding: 10px 12px; }
  .toolbar { flex-direction: column; align-items: stretch; }
  .segmented { overflow-x: auto; max-width: 100%; }
  .segmented button, .segmented a { white-space: nowrap; flex: none; }
    .overview-sub { align-items: flex-start; }
  .overview-sub .live-dot { margin-top: 8px; }
  .search { width: 100%; }
  .club-layout { grid-template-columns: 1fr; }
  .notice { margin: 0 16px 18px; }
  .settings-layout { grid-template-columns: 1fr; }
  .tabs-v { position: static; flex-direction: row; overflow-x: auto; }
  .tabs-v a { white-space: nowrap; }
  .form-grid, .checks { grid-template-columns: 1fr; }
  .auth { grid-template-columns: 1fr; }
  .auth-art { padding: 32px 24px; }
  .auth-art h1 { font-size: 30px; }
  .ecg { height: 70px; margin-top: 24px; }
  .choice-list { grid-template-columns: repeat(2, 1fr); }
  .toasts { left: 16px; right: 16px; bottom: 84px; align-items: stretch; }
  .hide-mobile { display: none !important; }
}
@media (min-width: 861px) { .mobile-nav { display: none; } }

/* Pastille de niveau dans le journal */
.lvl { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 10px; background: var(--idle); vertical-align: 1px; }
.lvl-success { background: var(--ok); }
.lvl-warning { background: var(--warn); }
.lvl-danger { background: var(--bad); }

/* Accès multi-clubs */
.access-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.access-chip { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: 7px; font-size: 12.5px; font-weight: 600; white-space: nowrap; vertical-align: middle; }
.access-chip.control { background: var(--accent-soft); color: var(--accent-ink); }
.access-chip.view { background: var(--idle-soft); color: var(--ink-2); }
.club-head h1 .access-chip { font-size: 13px; height: 26px; }
.access-list { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 12px; max-height: 300px; overflow-y: auto; }
.access-row { display: grid; grid-template-columns: minmax(0, 1fr) 170px; gap: 12px; align-items: center; padding: 8px 12px; border-top: 1px solid var(--line); cursor: default; }
.access-row:first-child { border-top: 0; }
.access-row b { font-weight: 600; font-size: 14px; }
.access-row small { display: block; color: var(--muted); font-size: 12.5px; }
.access-row .input { height: 36px; }
.access-quick { display: flex; justify-content: center; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.t-btn[disabled], input[type=range][disabled] { opacity: .35; cursor: not-allowed; }
@media (max-width: 860px) { .access-row { grid-template-columns: minmax(0, 1fr) 140px; } }

.switch b { color: var(--ink); }

/* ==========================================================================
   AXION WAN PULSE — éléments propres à la supervision des liens
   ========================================================================== */

/* Logo : tracé de pouls */
.pulse-mark { width: 24px; height: 24px; fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.mobile-bar .pulse-mark { width: 21px; height: 21px; }
.ecg { width: 100%; height: 120px; margin-top: 40px; overflow: visible; }
.ecg path { fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.ecg-base { stroke: rgba(126,160,255,.18); }
.ecg-run { stroke: #7ea0ff; stroke-dasharray: 160 1400; animation: ecg 2.8s linear infinite; filter: drop-shadow(0 0 6px rgba(126,160,255,.6)); }
@keyframes ecg { from { stroke-dashoffset: 160; } to { stroke-dashoffset: -1240; } }

/* États */
.pill.st-up, .st-up .pill { background: var(--ok-soft); color: #0b7a53; }
.pill.st-up::before, .st-up .pill::before { background: var(--ok); box-shadow: 0 0 0 3px rgba(20,166,114,.18); }
.pill.st-unstable { background: var(--warn-soft); color: #9a5f00; }
.pill.st-unstable::before { background: var(--warn); }
.pill.st-maintenance { background: var(--accent-soft); color: var(--accent-ink); }
.pill.st-maintenance::before { background: var(--accent); }
.tally .t-bad b { color: #ff8a8a; }

.state-dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; background: var(--idle); vertical-align: middle; flex: none; }
.sd-up { background: var(--ok); box-shadow: 0 0 0 4px rgba(20,166,114,.16); }
.sd-down { background: var(--bad); box-shadow: 0 0 0 0 rgba(214,60,60,.55); animation: alarm 1.6s infinite; }
.sd-unstable { background: var(--warn); box-shadow: 0 0 0 4px rgba(217,137,11,.16); }
.sd-maintenance { background: var(--accent); box-shadow: 0 0 0 4px rgba(47,91,234,.14); }
.sd-unknown, .sd-off, .sd-none { background: #c3ccd9; }
@keyframes alarm { 0% { box-shadow: 0 0 0 0 rgba(214,60,60,.55); } 70% { box-shadow: 0 0 0 9px rgba(214,60,60,0); } 100% { box-shadow: 0 0 0 0 rgba(214,60,60,0); } }

/* Battements : un trait par contrôle */
.beats { display: flex; align-items: flex-end; gap: 2px; height: 20px; }
.beat { display: inline-block; width: 4px; height: 100%; border-radius: 2px; background: #e3e8f0; }
.beat.b2 { background: var(--ok); }
.beat.b1 { background: var(--warn); height: 70%; }
.beat.b0 { background: var(--bad); height: 45%; }
.beats-lg { height: 34px; gap: 3px; }
.beats-lg .beat { flex: 1; width: auto; max-width: 12px; }
.legend { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 6px 16px; margin-top: 14px; color: var(--muted); font-size: 13px; }
.legend span { display: inline-flex; align-items: center; gap: 7px; }
.legend .beat { height: 13px; width: 5px; }
.legend .sep { color: var(--line-strong); }

/* Centre de contrôle */
.pulse-table td { padding: 13px 12px; }
.pulse-table th { padding-left: 12px; padding-right: 12px; }
.pulse-table th:first-child, .pulse-table td:first-child { padding-left: 18px; }
.pulse-table th:last-child, .pulse-table td:last-child { padding-right: 18px; }
.pulse-table tr.row-down td { background: #fff7f7; }
.pulse-table tr.row-down:hover td { background: #fdeeee; }
.pulse-table .cell-main { display: block; }
.pulse-table td.num { white-space: nowrap; }
.pulse-table .c-client { min-width: 150px; }
.pulse-table .c-sub { min-width: 175px; }
@media (max-width: 1500px) and (min-width: 861px) { .pulse-table .beats .beat:nth-child(-n+12) { display: none; } }
.pulse-table .c-ip { white-space: nowrap; }
.pulse-table .c-ip.is-host { white-space: normal; max-width: 150px; }
.nas-table .c-health { min-width: 150px; }
.nas-table .c-sub { min-width: 150px; }
@media (max-width: 1500px) and (min-width: 861px) { .pulse-table .c-last { display: none; } .pulse-table .c-client { min-width: 130px; } .pulse-table .c-sub { min-width: 160px; } .pulse-table td, .pulse-table th { padding-left: 9px; padding-right: 9px; } }
.cell-strong { font-weight: 550; color: var(--ink); }
.cell-strong .role-tag { margin-left: 4px; }
.txt-warn { color: #9a5f00 !important; font-weight: 600; }
.txt-accent { color: var(--accent-ink) !important; font-weight: 550; }
.link-btn { white-space: nowrap; display: inline-flex; align-items: center; gap: 5px; margin-top: 4px; padding: 3px 9px 3px 7px; border-radius: 7px; border: 0; cursor: pointer; background: var(--bad); color: #fff; font-size: 12.5px; font-weight: 600; }
.link-btn:hover { background: #bd3030; }
.link-btn .icon { width: 14px; height: 14px; }
.mono { font-family: ui-monospace, "Cascadia Mono", "Segoe UI Mono", Consolas, monospace; font-size: 13.5px; letter-spacing: -.01em; }
.rtt-bad { color: var(--warn); font-weight: 600; }
.since-bad { color: var(--bad); font-weight: 600; }
.ack-line { color: var(--ink-2); font-size: 12.5px; }
.quick { display: flex; justify-content: center; gap: 6px; }
.qbtn {
  width: 38px; height: 32px; border-radius: 8px; border: 1px solid var(--line-strong); background: var(--surface);
  display: grid; place-items: center; cursor: pointer; color: var(--ink-2); transition: background .15s, border-color .15s, color .15s;
}
.qbtn:hover { background: var(--surface-2); color: var(--ink); text-decoration: none; }
.qbtn .icon { width: 17px; height: 17px; }
.qbtn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.qbtn.primary:hover { background: var(--accent-ink); }
.qbtn.on { background: var(--accent-soft); border-color: #c5d3fb; color: var(--accent-ink); }
.qbtn.danger { background: var(--bad); border-color: var(--bad); color: #fff; }
.qbtn.danger:hover { background: #bd3030; }
.qbtn.is-busy { opacity: .55; pointer-events: none; }
.qbtn[disabled] { opacity: .35; pointer-events: none; }

/* Bandeau des coupures (toutes les pages) */
.outage {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 16px; align-items: center;
  padding: 16px 20px; margin-bottom: 22px; border-radius: var(--radius-lg);
  background: linear-gradient(120deg, #b52a2a, #d63c3c); color: #fff; box-shadow: 0 14px 34px -18px rgba(181,42,42,.8);
}
.outage.probe { background: linear-gradient(120deg, #8a5500, #d9890b); }
.outage.calm { background: var(--night-2); box-shadow: var(--shadow); }
.outage-icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: rgba(255,255,255,.16); }
.outage-icon .icon { width: 22px; height: 22px; }
.outage.alarm .outage-icon { animation: blink 1.2s ease-in-out infinite; }
@keyframes blink { 50% { background: rgba(255,255,255,.34); } }
.outage h2 { font-size: 16.5px; font-weight: 700; }
.outage ul { list-style: none; margin: 6px 0 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.outage li { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-size: 14px; color: rgba(255,255,255,.92); }
.outage li a { color: #fff; font-weight: 650; }
.outage li .muted { color: rgba(255,255,255,.72); }
.outage li .ack { font-size: 12.5px; padding: 1px 8px; border-radius: 99px; background: rgba(255,255,255,.18); }
.outage-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.outage .btn { background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.28); color: #fff; }
.outage .btn:hover { background: rgba(255,255,255,.24); }
.outage .btn-light { background: #fff; color: #a32626; border-color: #fff; }
.outage .btn-light:hover { background: #fdeaea; }

/* Pied du menu : état du superviseur et notifications */
.sup-card { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 12px; background: rgba(255,255,255,.05); border: 1px solid rgba(255,255,255,.07); }
.sup-card b { display: block; color: #fff; font-size: 13.5px; font-weight: 600; line-height: 1.25; }
.sup-card small { color: #8fa0c0; font-size: 12.5px; }
.sup-dot { width: 9px; height: 9px; border-radius: 50%; flex: none; background: var(--ok); animation: ping 2s infinite; }
.sup-card.is-late .sup-dot { background: var(--warn); animation: none; }
.sup-card.is-down .sup-dot { background: var(--bad); animation: none; }
.notif-btn {
  display: flex; gap: 10px; align-items: center; width: 100%; padding: 11px 12px; border-radius: 12px; cursor: pointer;
  border: 1px dashed rgba(127,160,255,.45); background: rgba(47,91,234,.12); color: #b8caff; font-size: 13px; font-weight: 550; text-align: left;
}
.notif-btn:hover { background: rgba(47,91,234,.22); }
.notif-btn .icon { width: 16px; height: 16px; }

/* Clients */
.search-form { flex: 1; max-width: 420px; }
.search-form .search { width: 100%; }
.sub-line { display: flex; align-items: center; gap: 8px; min-height: 26px; white-space: nowrap; }
.sub-line + .sub-line { margin-top: 4px; }
.role-tag { display: inline-flex; align-items: center; height: 20px; padding: 0 7px; border-radius: 6px; font-size: 11.5px; font-weight: 650; background: var(--idle-soft); color: var(--ink-2); letter-spacing: .01em; vertical-align: middle; }
.role-tag.secours { background: var(--warn-soft); color: #8a5500; }
.src-chip { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: 7px; font-size: 12px; font-weight: 600; background: var(--idle-soft); color: var(--ink-2); white-space: nowrap; }
.src-chip.crm { background: var(--accent-soft); color: var(--accent-ink); }
.club-head h1 .pill { font-size: 13px; }
.club-head .lede .src-chip { height: 22px; }

/* Fiche d'un abonnement */
.link-card { overflow: hidden; position: relative; }
.link-card::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--idle); }
.link-card.st-up::before { background: var(--ok); }
.link-card.st-down::before { background: var(--bad); }
.link-card.st-unstable::before { background: var(--warn); }
.link-card.st-maintenance::before { background: var(--accent); }
.link-card.st-down { border-color: #f1c4c4; }
.lc-head { display: flex; align-items: center; gap: 14px; padding: 20px 22px 16px 26px; }
.lc-title { flex: 1; min-width: 0; }
.lc-title h2 { font-size: 18px; font-weight: 700; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.lc-title p { color: var(--muted); font-size: 14px; margin-top: 3px; }
.lc-notice { margin: 0 22px 16px 26px; }
.lc-notice .btn { background: #fff; }
.lc-body { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 26px; padding: 4px 22px 20px 26px; }
.lc-facts { font-size: 13.5px; gap: 8px 14px; align-content: start; }
.lc-facts dd .cell-sub { margin-left: 6px; font-family: var(--font); font-size: 12px; }
.lc-pulse { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line); }
.lc-pulse-head { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.lc-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 4px; }
.lc-stats div { padding: 8px 10px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); text-align: center; }
.lc-stats b { display: block; font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums; }
.lc-stats span { color: var(--muted); font-size: 12px; }
.lc-notes { margin: -6px 22px 18px 26px; padding: 10px 14px; border-radius: 10px; background: var(--surface-2); color: var(--ink-2); font-size: 13.5px; white-space: pre-line; }
.lc-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; padding: 14px 22px; border-top: 1px solid var(--line); background: var(--surface-2); }
.lc-actions form { display: contents; }
.danger-zone { display: flex; justify-content: center; }

/* Import depuis AXION PILOT */
.pick-tools { display: flex; gap: 10px; align-items: center; margin-bottom: 12px; }
.pick-tools .search { flex: 1; width: auto; }
.pick-list { border: 1px solid var(--line); border-radius: 12px; max-height: 360px; overflow-y: auto; }
.pick-row { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 9px 14px; border-top: 1px solid var(--line); cursor: pointer; }
.pick-row:first-child { border-top: 0; }
.pick-row:hover { background: var(--surface-2); }
.pick-row input { width: 17px; height: 17px; accent-color: var(--accent); }
.pick-row b { font-weight: 600; font-size: 14px; }
.pick-row small { display: block; color: var(--muted); font-size: 12.5px; }
.pick-row.is-done { cursor: default; color: var(--muted); }
.pick-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; color: var(--muted); font-size: 13px; }
.pick-empty { padding: 30px; text-align: center; color: var(--muted); }

/* Paramètres */
.sup-status { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; gap: 16px; align-items: center; margin-top: 22px; }
.sup-status b { display: block; font-size: 13px; }
.sup-status span { font-size: 13.5px; }
.txt-ok { color: var(--ok); font-weight: 600; }
.txt-bad { color: var(--bad); font-weight: 600; }

@media (max-width: 860px) {
  .outage { grid-template-columns: auto minmax(0, 1fr); padding: 14px 16px; }
  .outage-actions { grid-column: 1 / -1; }
  .lc-head { padding: 16px 16px 12px 20px; flex-wrap: wrap; }
  .lc-body { grid-template-columns: 1fr; padding: 4px 16px 16px 20px; gap: 16px; }
  .lc-notice, .lc-notes { margin-left: 16px; margin-right: 16px; }
  .sup-status { grid-template-columns: 1fr; }
  .search-form { max-width: none; }
  /* Centre de contrôle : une carte par lien sur téléphone */
  .tally:has(> :nth-child(4)) { grid-template-columns: repeat(2, 1fr); }
  .pulse-table thead { display: none; }
  .pulse-table, .pulse-table tbody { display: block; }
  .pulse-table tr { display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; grid-template-areas: "st cl rtt" "st sub sub" "st ip ip" "st q q"; gap: 6px 12px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
  .pulse-table tr[hidden] { display: none; }
  .pulse-table tr:last-child { border-bottom: 0; }
  table.data.pulse-table td { display: block; padding: 0; border: 0; background: none !important; }
  .pulse-table .hide-mobile { display: none; }
  .pulse-table .c-state { grid-area: st; padding-top: 4px; }
  .pulse-table .c-client { grid-area: cl; min-width: 0; }
  .pulse-table .c-rtt { grid-area: rtt; }
  .pulse-table .c-sub { grid-area: sub; }
  .pulse-table .c-sub .cell-strong { white-space: normal; }
  .pulse-table .c-ip { grid-area: ip; }
  .pulse-table .c-quick { grid-area: q; }
  .pulse-table .quick { justify-content: flex-start; margin-top: 4px; }
  .pulse-table tr.row-down { background: #fff7f7; }
}
@media (max-width: 1400px) and (min-width: 861px) { .pulse-table .c-avail { display: none; } }

/* ==========================================================================
   Supervision des NAS Synology
   ========================================================================== */
.section-title { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 650; color: var(--ink-2); margin: 4px 0 -6px; }
.section-title .icon { width: 18px; height: 18px; color: var(--accent); }
.stack > .section-title:not(:first-child) { margin-top: 10px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin: 30px 0 14px; }
.section-head h2 { display: flex; align-items: center; gap: 10px; font-size: 19px; font-weight: 700; }
.section-head h2 .icon { width: 20px; height: 20px; color: var(--accent); }
.section-head .lede { color: var(--muted); }
.empty-sm { padding: 30px 24px; }

.kind-tag { display: inline-flex; align-items: center; height: 20px; padding: 0 7px; border-radius: 6px; font-size: 11.5px; font-weight: 700; letter-spacing: .03em; background: var(--night); color: #fff; vertical-align: middle; }
.lc-title h2 .kind-tag { height: 22px; }

.health-badge { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px 0 8px; border-radius: 99px; font-size: 13px; font-weight: 600; white-space: nowrap; background: var(--idle-soft); color: var(--ink-2); }
.health-badge .icon { width: 15px; height: 15px; }
.health-badge.h-ok { background: var(--ok-soft); color: #0b7a53; }
.health-badge.h-warning { background: var(--warn-soft); color: #9a5f00; }
.health-badge.sm { height: 20px; padding: 0 8px; font-size: 11.5px; margin-left: 6px; }
.state-dot.sm { width: 9px; height: 9px; }
.sd-unknown { background: #c3ccd9; }

.diag-chip { display: inline-flex; align-items: flex-start; gap: 6px; margin-top: 5px; padding: 3px 9px 3px 7px; border-radius: 7px; font-size: 12.5px; font-weight: 650; line-height: 1.35; max-width: 240px; }
.diag-chip .icon { margin-top: 1px; flex: none; }
.diag-chip .icon { width: 14px; height: 14px; }
.diag-chip.d-wan { background: #fff1d6; color: #8a5500; }
.diag-chip.d-nas { background: var(--bad-soft); color: #a32626; }
.diag-line { display: block; margin-top: 2px; }

.vol-row { display: flex; flex-direction: column; gap: 6px; }
.vol-top { display: flex; justify-content: space-between; gap: 10px; font-size: 13.5px; }
.vol-top b { font-weight: 600; }
.bar, .mini-bar { height: 8px; border-radius: 99px; background: #e3e8f0; overflow: hidden; }
.mini-bar { height: 6px; width: 110px; margin-bottom: 4px; }
.bar i, .mini-bar i { display: block; height: 100%; border-radius: inherit; background: var(--ok); }
.bar i.is-warn, .mini-bar i.is-warn { background: var(--warn); }
.bar i.is-bad, .mini-bar i.is-bad { background: var(--bad); }
.raid-list { display: flex; flex-wrap: wrap; gap: 6px; }
.raid-chip { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; border-radius: 7px; font-size: 12.5px; font-weight: 600; background: var(--ok-soft); color: #0b7a53; }
.raid-chip.r-degraded { background: var(--bad-soft); color: #a32626; }
.raid-chip.r-rebuilding { background: var(--warn-soft); color: #8a5500; }
.raid-chip.r-unknown { background: var(--idle-soft); color: var(--ink-2); }

.nas-disks { margin: 0 22px 18px 26px; border: 1px solid var(--line); border-radius: 12px; }
.nas-disks table.data { font-size: 13.5px; }
.nas-disks table.data th, .nas-disks table.data td { padding: 9px 14px; }
.smart { font-weight: 600; }
.smart.s-normal, .smart.s-cache { color: var(--ok); }
.smart.s-warning { color: var(--warn); }
.smart.s-failing { color: var(--bad); }
.smart.s-unknown, .smart.s-sleeping { color: var(--muted); }

.install-steps { margin: 0 0 14px; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: var(--ink-2); }
.install-steps b { color: var(--ink); }
.script-box textarea.input { font-size: 12px; line-height: 1.45; background: var(--night); color: #d6e0f5; border-color: var(--night); white-space: pre; overflow-wrap: normal; overflow-x: auto; resize: vertical; }

@media (max-width: 860px) {
  .section-head { flex-direction: column; align-items: flex-start; gap: 4px; }
  .nas-disks { margin: 0 16px 16px 20px; }
  .pulse-table .c-health { grid-area: ip; }
}
@media (max-width: 1500px) and (min-width: 861px) { .pulse-table .c-client { min-width: 120px; } .diag-chip { max-width: 190px; } }

/* Liens externes (IP WAN, QuickConnect) */
.ext-link { color: inherit; display: inline-flex; align-items: center; gap: 4px; border-bottom: 1px dashed transparent; }
.ext-link:hover { color: var(--accent-ink); text-decoration: none; border-bottom-color: currentColor; }
.ext-link .icon { width: 12px; height: 12px; opacity: .45; flex: none; }
.ext-link:hover .icon { opacity: 1; }
.c-ip .ext-link { display: inline; }
.c-ip .ext-link .icon { vertical-align: -1px; margin-left: 3px; }
.lc-title h2 .ext-link .icon { width: 14px; height: 14px; }
