/* Kalbe — portail prêteur (Sened).
   Charte Kalbe v2.4 + planches « éléments web » : Encre, Blanc, Nuage, un accent Océan,
   le vert et le rouge pour les états seulement. Titres en Poppins (repli d'Aeonik Pro),
   texte courant en Bricolage Grotesque, chiffres en Inter tabulaire. */

/* Aeonik Pro Light (CoType Foundry, licence commerciale fournie par Kalbe : héberger avec le site, jamais dans
   un dépôt public). Nom de famille propre pour ne jamais servir de faux gras aux titres. */
@font-face {
  font-family: 'Kalbe Aeonik Light';
  src: url('fonts/aeonik-pro-light.woff') format('woff');
  font-weight: 300;
  font-style: normal;
  font-display: block;
  ascent-override: 75%;
  descent-override: 25%;
  line-gap-override: 0%;
}

:root {
  --encre: #171718;
  --encre-survol: #393A42;
  --encre-presse: #494B54;
  --texte: #14181B;
  --ardoise: #66717A;
  --acier: #8C969D;
  --brume: #E4EAF0;
  --brume-fort: #D5DDE5;
  --nuage: #F4F7FB;
  --nuage-fort: #EBF0F6;
  --glace: #EDF6FB;
  --blanc: #FFFFFF;
  --ocean: #4086B9;
  --ocean-survol: #3576A6;
  --cyan: #00C4FF;
  --nuit: #001622;
  --rouge: #D93A3F;
  --rouge-survol: #C2323A;
  --vert-texte: #0F7A37;

  --info: #2D74A8;      --info-fond: #EDF6FB;
  --succes: #2A6B44;    --succes-fond: #EBF7F0;
  --attente: #85621E;   --attente-fond: #FBF3E3;
  --danger: #A63A3B;    --danger-fond: #FBEEEE;
  --neutre: #3F4650;    --neutre-fond: #E9EBF0;

  --f-titre: 'Aeonik Pro', Poppins, system-ui, sans-serif;
  --f-ui: Poppins, system-ui, sans-serif;
  --f-marque: 'Kalbe Aeonik Light', Poppins, system-ui, sans-serif;
  --f-texte: 'Bricolage Grotesque', system-ui, sans-serif;
  --f-chiffre: Inter, system-ui, sans-serif;

  --r-badge: 999px;
  --r-interne: 12px;
  --r-champ: 14px;
  --r-bloc: 18px;
  --r-surface: 24px;

  --ombre-1: 0 1px 2px rgba(16, 24, 40, .04), 0 1px 3px rgba(16, 24, 40, .05);
  --ombre-2: 0 10px 28px rgba(16, 24, 40, .08), 0 2px 6px rgba(16, 24, 40, .04);
  --ombre-3: 0 24px 56px rgba(16, 24, 40, .16);
  --anneau: 0 0 0 3px rgba(0, 196, 255, .35);

  --sidebar: 264px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--nuage);
  color: var(--texte);
  font: 500 15px/1.55 var(--f-texte);
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: inherit; }
img, svg { display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4, p { margin: 0; }
:focus-visible { outline: none; box-shadow: var(--anneau); }
::selection { background: rgba(0, 196, 255, .22); }

.icon { width: 20px; height: 20px; flex: none; }
.icon--16 { width: 16px; height: 16px; }
.icon--24 { width: 24px; height: 24px; }
.money { white-space: nowrap; }
.num, .money { font-family: var(--f-chiffre); font-variant-numeric: tabular-nums; font-feature-settings: 'tnum' 1; }
.muted { color: var(--ardoise); }
.small { font-size: 13px; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.stack > * + * { margin-top: 16px; }
.stack-sm > * + * { margin-top: 8px; }
.row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.row--between { justify-content: space-between; }
.grow { flex: 1 1 auto; min-width: 0; }

/* ---------- Logo et verrouillage ---------- */
.logo { color: var(--encre); height: 30px; width: calc(30px * 3.3711); }
.logo--blanc { color: var(--blanc); }
/* Sous-marque : le wordmark puis le descripteur en Aeonik Pro Light, calé sur la hauteur du K et sur sa
   ligne de base, à un quart de la largeur du K (charte, planche « Sous-marques »).
   Mesures prises sur le logo : K = 97,5 % de la hauteur du logo, base du K à 98,1 % (1,9 % au-dessus du bas),
   largeur du K = 0,859 × sa hauteur. Aeonik Pro Light : capitales 0,700 em.
   - Corps : 0,975 H / 0,700 = 1,393 H (capitales = hauteur du K).
   - Ligne de base : alignement par la base (align-items: baseline). Le logo, sans texte, a pour base son bord
     bas ; on le descend de 1,9 % de H pour que la base du K tombe sur celle du descripteur. Indépendant des
     métriques de la police, donc identique dans tous les navigateurs (Safari ignore ascent-override).
   - Écart : 0,25 × 0,859 × 0,975 H = 0,209 H. */
.lockup { --h: 30px; display: inline-flex; align-items: baseline; gap: calc(var(--h) * .209); text-decoration: none; color: var(--encre); }
.lockup .logo { height: var(--h); width: calc(var(--h) * 3.3711); color: inherit; flex: none; position: relative; top: calc(var(--h) * .019); }
.lockup__desc { font: 300 calc(var(--h) * 1.393)/.7 var(--f-marque); letter-spacing: 0; white-space: nowrap; color: inherit; }
.lockup--blanc { color: var(--blanc); }
.lockup--sm { --h: 24px; } /* 81 px de large : minimum de la charte web (80 px) */
.lockup--md { --h: 26px; }

/* ---------- Coquille ---------- */
.shell { display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); min-height: 100vh; }
.sidebar {
  position: sticky; top: 0; height: 100vh;
  display: flex; flex-direction: column;
  background: var(--blanc); border-right: 1px solid var(--brume);
  padding: 24px 16px 16px;
}
.sidebar__brand { padding: 4px 8px 20px; }
.lender {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; margin: 0 0 20px;
  background: var(--nuage); border-radius: var(--r-interne);
}
.lender__mark {
  width: 32px; height: 32px; border-radius: 10px; flex: none;
  display: grid; place-items: center;
  background: var(--encre); color: var(--blanc);
  font: 600 13px/1 var(--f-ui);
}
.lender__label { font: 600 11px/1.2 var(--f-ui); letter-spacing: .08em; text-transform: uppercase; color: var(--ardoise); }
.lender--logo { flex-direction: column; align-items: flex-start; gap: 10px; padding: 12px 14px; }
.lender__logo { display: block; max-width: 100%; max-height: 44px; width: auto; height: auto; object-fit: contain; }
.lender__name { font: 600 14px/1.25 var(--f-ui); color: var(--encre); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.nav { flex: 1 1 auto; overflow-y: auto; margin: 0 -4px; padding: 0 4px; }
.nav__section { font: 600 11px/1 var(--f-ui); letter-spacing: .08em; text-transform: uppercase; color: var(--acier); padding: 18px 12px 8px; }
.nav__section:first-child { padding-top: 0; }
.nav__link {
  display: flex; align-items: center; gap: 12px;
  height: 42px; padding: 0 12px; margin-bottom: 2px;
  border-radius: var(--r-interne);
  font: 500 14px/1 var(--f-ui); color: var(--ardoise); text-decoration: none;
  transition: background .15s, color .15s;
}
.nav__link:hover { background: var(--nuage); color: var(--encre); }
.nav__link.is-active { background: var(--nuage-fort); color: var(--encre); font-weight: 600; }
.nav__link .icon { width: 20px; height: 20px; }
.nav__count {
  margin-left: auto; min-width: 22px; height: 22px; padding: 0 7px;
  display: inline-grid; place-items: center; border-radius: var(--r-badge);
  background: var(--encre); color: var(--blanc);
  font: 600 12px/1 var(--f-chiffre); font-variant-numeric: tabular-nums;
}
.me { display: flex; align-items: center; gap: 12px; padding: 14px 8px 4px; border-top: 1px solid var(--brume); margin-top: 12px; }
.avatar {
  width: 36px; height: 36px; border-radius: 50%; flex: none;
  display: grid; place-items: center;
  background: var(--brume); color: var(--encre);
  font: 600 13px/1 var(--f-ui); letter-spacing: .02em;
}
.avatar--sm { width: 30px; height: 30px; font-size: 11.5px; }
.me__name { font: 600 14px/1.3 var(--f-ui); color: var(--encre); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.me__role { font-size: 12.5px; color: var(--ardoise); }

.topbar, .scrim { display: none; }
.main { min-width: 0; padding: 36px 40px 72px; }
.main__inner { max-width: 1240px; margin: 0 auto; }

/* ---------- Titres de page ---------- */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px 24px; flex-wrap: wrap; margin-bottom: 28px; }
.eyebrow { display: inline-flex; align-items: center; gap: 6px; font: 600 12px/1 var(--f-ui); letter-spacing: .08em; text-transform: uppercase; color: var(--ardoise); text-decoration: none; margin-bottom: 12px; }
a.eyebrow:hover { color: var(--encre); }
.page-title { font: 700 30px/1.15 var(--f-titre); letter-spacing: -.02em; color: var(--encre); }
.page-title__second { display: block; color: var(--acier); }
.page-sub { margin-top: 8px; max-width: 720px; color: var(--ardoise); font-size: 15px; }
.page-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- Boutons : capsules pleines, Poppins 600 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 48px; padding: 0 24px;
  border: 1px solid transparent; border-radius: var(--r-badge);
  font: 600 14px/1 var(--f-ui); text-decoration: none; white-space: nowrap;
  cursor: pointer; transition: background .15s, border-color .15s, color .15s, box-shadow .15s;
}
.btn .icon { width: 18px; height: 18px; }
.btn--md { height: 40px; padding: 0 18px; font-size: 13.5px; }
.btn--sm { height: 32px; padding: 0 14px; font-size: 13px; gap: 6px; }
.btn--sm .icon { width: 16px; height: 16px; }
.btn--block { width: 100%; }
.btn--icon { width: 40px; padding: 0; }
.btn--primary { background: var(--encre); color: var(--blanc); }
.btn--primary:hover { background: var(--encre-survol); }
.btn--primary:active { background: var(--encre-presse); }
.btn--accent { background: var(--ocean); color: var(--blanc); }
.btn--accent:hover { background: var(--ocean-survol); }
.btn--secondary { background: var(--blanc); color: var(--encre); border-color: var(--brume-fort); }
.btn--secondary:hover { background: var(--nuage); }
.btn--ghost { background: transparent; color: var(--encre); }
.btn--ghost:hover { background: var(--nuage-fort); }
.btn--danger { background: var(--rouge); color: var(--blanc); }
.btn--danger:hover { background: var(--rouge-survol); }
.btn--ghost-danger { background: transparent; color: var(--rouge); }
.btn--ghost-danger:hover { background: var(--danger-fond); }
.btn--on-dark { background: var(--blanc); color: var(--encre); }
.btn--on-dark:hover { background: #E9ECEF; }
.btn[disabled], .btn.is-disabled { background: #BBBBBB; border-color: transparent; color: var(--blanc); cursor: not-allowed; }

.link { color: var(--encre); font-weight: 600; text-decoration: none; border-bottom: 1px solid var(--brume-fort); }
.link:hover { border-color: var(--encre); }
.link-arrow { display: inline-flex; align-items: center; gap: 6px; font: 600 13.5px/1 var(--f-ui); color: var(--encre); text-decoration: none; }
.link-arrow:hover .icon { transform: translateX(2px); }
.link-arrow .icon { transition: transform .15s; width: 16px; height: 16px; }

/* ---------- Champs : 56 px, rayon 14, filet Brume, anneau Cyan ---------- */
.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.label { font: 600 13px/1.2 var(--f-ui); color: var(--ardoise); }
.help { font-size: 12.5px; line-height: 1.45; color: var(--ardoise); }
.field-error, .form-error-list { font-size: 12.5px; color: var(--rouge); margin: 0; padding: 0; list-style: none; }
.input, .select, .textarea {
  width: 100%; height: 56px; padding: 0 16px;
  background: var(--blanc); color: var(--texte);
  border: 1px solid var(--brume); border-radius: var(--r-champ);
  font: 500 15px/1.3 var(--f-texte);
  transition: border-color .15s, box-shadow .15s;
  -webkit-appearance: none; appearance: none;
}
.input::placeholder, .textarea::placeholder { color: var(--acier); }
.input:hover, .select:hover, .textarea:hover { border-color: var(--brume-fort); }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--ocean); box-shadow: var(--anneau); }
.input--md, .select--md { height: 44px; border-radius: var(--r-interne); font-size: 14px; }
.input--sm, .select--sm { height: 36px; border-radius: 10px; font-size: 13.5px; padding: 0 12px; }
.input.num { font-family: var(--f-chiffre); }
.textarea { height: auto; min-height: 96px; padding: 14px 16px; resize: vertical; line-height: 1.5; }
.select {
  padding-right: 44px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' fill='none' stroke='%2366717A' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; background-size: 18px;
}
.select--sm { padding-right: 36px; background-position: right 10px center; background-size: 16px; }
.input-wrap { position: relative; }
.input-wrap > .icon { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--ardoise); pointer-events: none; }
.input-wrap > .input { padding-left: 46px; }
.input-wrap--md > .icon { left: 14px; width: 18px; height: 18px; }
.input-wrap--md > .input { padding-left: 40px; }
.is-invalid { border-color: var(--rouge) !important; }

.check { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; font-size: 14.5px; }
.check input { width: 18px; height: 18px; accent-color: var(--ocean); margin: 0; }

.switch { display: flex; align-items: center; justify-content: space-between; gap: 16px; cursor: pointer; }
.switch input { position: absolute; opacity: 0; pointer-events: none; }
.switch__track { position: relative; width: 46px; height: 28px; flex: none; border-radius: 999px; background: var(--brume-fort); transition: background .15s; }
.switch__track::after { content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: var(--blanc); box-shadow: var(--ombre-1); transition: transform .18s; }
.switch input:checked + .switch__track { background: var(--ocean); }
.switch input:checked + .switch__track::after { transform: translateX(18px); }
.switch input:focus-visible + .switch__track { box-shadow: var(--anneau); }
.switch > span:first-child { flex: 1 1 auto; min-width: 0; }
.switch__title { font: 600 14.5px/1.3 var(--f-ui); color: var(--encre); }

.form-grid { display: grid; gap: 20px; grid-template-columns: repeat(12, minmax(0, 1fr)); }
.span-12 { grid-column: span 12; } .span-8 { grid-column: span 8; } .span-6 { grid-column: span 6; }
.span-9 { grid-column: span 9; } .span-5 { grid-column: span 5; }
.span-4 { grid-column: span 4; } .span-3 { grid-column: span 3; } .span-2 { grid-column: span 2; }
.form-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--brume); }

/* Choix en tuiles (décision) */
.choices { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.choice { position: relative; display: flex; align-items: center; gap: 14px; padding: 16px 18px; background: var(--blanc); border: 1px solid var(--brume); border-radius: var(--r-champ); cursor: pointer; transition: border-color .15s, background .15s, box-shadow .15s; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice__mark { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; flex: none; }
.choice__title { display: block; font: 600 15px/1.3 var(--f-ui); color: var(--encre); }
.choice__sub { display: block; margin-top: 2px; font-size: 13.5px; color: var(--ardoise); }
.choice__radio { width: 20px; height: 20px; flex: none; border-radius: 50%; border: 1.5px solid var(--brume-fort); background: var(--blanc); transition: border-color .15s, box-shadow .15s; }
.choice:hover { border-color: var(--brume-fort); background: #FBFCFE; }
.choice:has(input:checked) { border-color: var(--ocean); background: var(--glace); }
.choice:has(input:checked) .choice__radio { border: 6px solid var(--ocean); }
.choice:has(input:focus-visible) { box-shadow: var(--anneau); }
.choice--approve .choice__mark { background: var(--succes-fond); color: var(--succes); }
.choice--reject .choice__mark { background: var(--danger-fond); color: var(--danger); }

/* Décision : bloc clair, surélevé (niveau 2), l'action principale de la page. */
.decision { margin-bottom: 20px; box-shadow: var(--ombre-2); border-color: transparent; }
.decision__head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 20px 24px; border-bottom: 1px solid var(--brume); }
.decision__icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: var(--nuage); color: var(--encre); flex: none; }
.decision__foot { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--brume); }
.decision__foot .muted { display: inline-flex; align-items: center; gap: 6px; }

/* ---------- Badges : capsule 26 px, fond pâle, texte foncé ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  height: 26px; padding: 0 10px; border-radius: var(--r-badge);
  font: 600 12px/1 var(--f-ui); white-space: nowrap; vertical-align: middle;
  background: var(--neutre-fond); color: var(--neutre);
}
.badge--dot::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge .icon { width: 14px; height: 14px; }
.badge--success { background: var(--succes-fond); color: var(--succes); }
.badge--warning { background: var(--attente-fond); color: var(--attente); }
.badge--danger { background: var(--danger-fond); color: var(--danger); }
.badge--info, .badge--primary { background: var(--info-fond); color: var(--info); }
.badge--secondary, .badge--light { background: var(--neutre-fond); color: var(--neutre); }
.badge--ink { background: var(--encre); color: var(--blanc); }
.badge--outline { background: var(--blanc); border: 1px solid var(--brume); color: var(--neutre); }
.badge--lg { height: 30px; padding: 0 12px; font-size: 13px; }

/* ---------- Bandeaux d'alerte ---------- */
.alert { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: var(--r-champ); font-size: 14.5px; line-height: 1.5; }
.alert .icon { margin-top: 1px; }
.alert__title { font: 600 14.5px/1.4 var(--f-ui); }
.alert--success { background: var(--succes-fond); color: var(--succes); }
.alert--warning { background: var(--attente-fond); color: var(--attente); }
.alert--danger, .alert--error { background: var(--danger-fond); color: var(--danger); }
.alert--info { background: var(--info-fond); color: var(--info); }
.alert__body { color: var(--texte); }
.flashes { display: grid; gap: 10px; margin-bottom: 24px; }

/* ---------- Blocs : rayon 18, filet Brume ---------- */
.block { background: var(--blanc); border: 1px solid var(--brume); border-radius: var(--r-bloc); }
.block__body { padding: 24px; }
.block__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 20px 24px; border-bottom: 1px solid var(--brume); }
.block__head--plain { border-bottom: 0; padding-bottom: 4px; }
.block__title { display: flex; align-items: center; gap: 10px; font: 600 16px/1.3 var(--f-ui); color: var(--encre); }
.block__title .icon { color: var(--ardoise); }
.block__sub { font-size: 13.5px; color: var(--ardoise); margin-top: 2px; }
.block--ink { background: var(--encre); border-color: var(--encre); color: var(--blanc); }
.block--ink .block__head { border-color: rgba(255, 255, 255, .1); }
.block--ink .block__title, .block--ink .block__title .icon { color: var(--blanc); }
.block--ink .block__sub, .block--ink .muted { color: var(--acier); }
.block--soft { background: var(--nuage); border-color: transparent; }

.grid { display: grid; gap: 20px; }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid--main { grid-template-columns: minmax(0, 1fr) 360px; align-items: start; }
.kpi-grid { display: grid; gap: 16px; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.section { margin-top: 20px; }
.bleed { margin-left: -24px; margin-right: -24px; }
.bleed .table th:first-child, .bleed .table td:first-child { padding-left: 24px; }

/* ---------- Chiffres clés ---------- */
.kpi { display: flex; flex-direction: column; gap: 14px; padding: 20px 22px; background: var(--blanc); border: 1px solid var(--brume); border-radius: var(--r-bloc); text-decoration: none; color: inherit; transition: box-shadow .15s, border-color .15s; }
a.kpi:hover { box-shadow: var(--ombre-2); border-color: transparent; }
.kpi__top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.kpi__label { font: 500 13.5px/1.3 var(--f-ui); color: var(--ardoise); }
.kpi__icon { width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center; background: var(--nuage); color: var(--encre); flex: none; }
.kpi__value { font: 700 28px/1.1 var(--f-chiffre); font-variant-numeric: tabular-nums; letter-spacing: -.01em; color: var(--encre); }
.kpi__value small { font-size: 15px; font-weight: 600; color: var(--ardoise); margin-left: 4px; }
.kpi__meta { font-size: 13px; color: var(--ardoise); }
.kpi--ink { background: var(--encre); border-color: var(--encre); }
.kpi--ink .kpi__label, .kpi--ink .kpi__meta { color: var(--acier); }
.kpi--ink .kpi__value { color: var(--blanc); }
.kpi--ink .kpi__icon { background: rgba(255, 255, 255, .08); color: var(--cyan); }
.kpi__value.is-danger { color: var(--rouge); }
/* Carte « Nuit » : le chiffre clé, le K en lumière dans l'angle (charte : cyan sur fond sombre seulement). */
.kpi--nuit { position: relative; overflow: hidden; isolation: isolate; background: linear-gradient(135deg, #07344C, #000B12); border-color: transparent; color: var(--blanc); }
.kpi--nuit > :not(.kpi__k) { position: relative; z-index: 1; }
.kpi--nuit .kpi__label { color: #C9D3DA; font-weight: 600; }
.kpi--nuit .kpi__value { color: var(--cyan); font-size: 36px; }
.kpi--nuit .kpi__meta { display: flex; align-items: center; gap: 8px; color: var(--acier); }
a.kpi--nuit:hover { box-shadow: var(--ombre-2); }
a.kpi--nuit:hover .kpi__k-line { stroke-width: 2.2; }
.kpi__k { position: absolute; z-index: 0; top: -34px; right: -62px; height: 210px; width: auto; aspect-ratio: 190 / 230; pointer-events: none; }
.kpi__k-band { fill: none; stroke: rgba(0, 196, 255, .2); stroke-width: 9; stroke-linejoin: round; }
.kpi__k-line { fill: none; stroke: var(--cyan); stroke-width: 1.6; stroke-linejoin: round; }

.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.stat { padding: 18px 24px; }
.stat + .stat { border-left: 1px solid var(--brume); }
.stat__label { font: 500 13px/1.3 var(--f-ui); color: var(--ardoise); }
.stat__value { margin-top: 6px; font: 700 20px/1.2 var(--f-chiffre); font-variant-numeric: tabular-nums; color: var(--encre); }

/* ---------- Tableaux ---------- */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 14.5px; }
.table th {
  padding: 12px 16px; text-align: left; white-space: nowrap;
  font: 600 11.5px/1.2 var(--f-ui); letter-spacing: .07em; text-transform: uppercase; color: var(--ardoise);
  background: var(--nuage); border-bottom: 1px solid var(--brume);
}
.table th:first-child { padding-left: 24px; }
.table th:last-child { padding-right: 24px; }
.table td { padding: 14px 16px; border-bottom: 1px solid var(--brume); vertical-align: middle; }
.table td:first-child { padding-left: 24px; }
.table td:last-child { padding-right: 24px; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr { transition: background .12s; }
.table--hover tbody tr:hover { background: #F9FBFD; }
.table tr[data-href] { cursor: pointer; }
.table td.num, .table th.num { text-align: right; white-space: nowrap; }
.table--compact td { padding-top: 10px; padding-bottom: 10px; }
.table--plain th { background: transparent; }
.block > .table-wrap:first-child .table thead th:first-child { border-top-left-radius: var(--r-bloc); }
.block > .table-wrap:first-child .table thead th:last-child { border-top-right-radius: var(--r-bloc); }
.ref { font: 600 13.5px/1.2 var(--f-chiffre); letter-spacing: .01em; color: var(--encre); text-decoration: none; white-space: nowrap; }
a.ref:hover { text-decoration: underline; text-underline-offset: 3px; }
.who { display: flex; align-items: center; gap: 12px; min-width: 0; }
.who__name { font: 600 14px/1.3 var(--f-ui); color: var(--encre); }
.who__sub { font-size: 12.5px; color: var(--ardoise); }
.row-go { color: var(--acier); }
tr:hover .row-go { color: var(--encre); }
.truncate { max-width: 280px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- Listes de définitions ---------- */
.dl { display: grid; grid-template-columns: auto 1fr; margin: 0; }
.dl dt, .dl dd { padding: 11px 0; border-bottom: 1px solid var(--brume); margin: 0; }
.dl dt { color: var(--ardoise); font-size: 14px; padding-right: 16px; }
.dl dd { text-align: right; font-weight: 500; color: var(--encre); min-width: 0; overflow-wrap: anywhere; }
.dl > :nth-last-child(-n+2) { border-bottom: 0; }
.dl--stacked { grid-template-columns: 1fr; }
.dl--stacked dd { text-align: left; padding-top: 0; }

/* ---------- Puces de filtre ---------- */
.chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
.chip { display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--brume); background: var(--blanc); font: 500 13.5px/1 var(--f-ui); color: var(--ardoise); text-decoration: none; white-space: nowrap; transition: background .15s, color .15s, border-color .15s; }
.chip:hover { color: var(--encre); border-color: var(--brume-fort); }
.chip.is-active { background: var(--encre); border-color: var(--encre); color: var(--blanc); }
.chip__count { font: 600 12px/1 var(--f-chiffre); color: inherit; opacity: .7; }

.toolbar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; padding: 16px 24px; border-bottom: 1px solid var(--brume); }

/* ---------- États vides ---------- */
.empty { text-align: center; padding: 48px 24px; }
.empty__icon { width: 52px; height: 52px; border-radius: 16px; margin: 0 auto 14px; display: grid; place-items: center; background: var(--nuage); color: var(--ardoise); }
.empty__title { font: 600 15px/1.3 var(--f-ui); color: var(--encre); }
.empty__text { margin-top: 4px; color: var(--ardoise); font-size: 14px; }

/* ---------- Pagination ---------- */
.pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 20px; }
.pager__pages { display: flex; gap: 6px; flex-wrap: wrap; }
.pager__page { min-width: 38px; height: 38px; padding: 0 10px; border-radius: 999px; display: inline-grid; place-items: center; font: 600 13.5px/1 var(--f-chiffre); color: var(--encre); text-decoration: none; border: 1px solid var(--brume); background: var(--blanc); }
.pager__page:hover { border-color: var(--brume-fort); background: var(--nuage); }
.pager__page.is-current { background: var(--encre); border-color: var(--encre); color: var(--blanc); }
.pager__page.is-disabled { color: var(--acier); pointer-events: none; }

/* ---------- Score ---------- */
.score { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.score__value { font: 700 44px/1 var(--f-chiffre); font-variant-numeric: tabular-nums; letter-spacing: -.02em; color: var(--encre); }
.score__value small { font-size: 16px; font-weight: 600; color: var(--ardoise); margin-left: 4px; letter-spacing: 0; }
.meter { position: relative; height: 8px; border-radius: 999px; background: var(--brume); overflow: hidden; }
.meter__bar { position: absolute; inset: 0 auto 0 0; border-radius: 999px; background: linear-gradient(90deg, var(--ocean), #68C1EA); }
.meter--mini { height: 6px; width: 64px; }
.score__meter { flex: 1 1 220px; min-width: 200px; }
.score__scale { position: relative; height: 12px; margin-top: 8px; font: 500 12px/1 var(--f-chiffre); color: var(--acier); }
.score__scale span { position: absolute; top: 0; transform: translateX(-50%); }
.score__scale span:first-child { transform: none; }
.score__scale span:last-child { transform: translateX(-100%); }
.score-cell { display: flex; align-items: center; gap: 10px; }
.score-cell .num { font-weight: 600; min-width: 34px; }
.criterion td { background: var(--nuage); font: 600 12px/1.2 var(--f-ui); letter-spacing: .06em; text-transform: uppercase; color: var(--ardoise); padding-top: 10px; padding-bottom: 10px; }
.pts { font: 600 14px/1 var(--f-chiffre); font-variant-numeric: tabular-nums; white-space: nowrap; }
.pts--plus { color: var(--vert-texte); }
.pts--minus { color: var(--rouge); }
.pts--zero { color: var(--acier); }

/* ---------- Frise ---------- */
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 18px 26px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ''; position: absolute; left: 5px; top: 7px; width: 9px; height: 9px; border-radius: 50%; background: var(--blanc); border: 2px solid var(--ocean); }
.timeline li::after { content: ''; position: absolute; left: 10px; top: 20px; bottom: 0; width: 1px; background: var(--brume); }
.timeline li:last-child::after { display: none; }
.timeline li:first-child::before { background: var(--ocean); }
.timeline__title { font: 600 14px/1.35 var(--f-ui); color: var(--encre); }
.timeline__meta { font-size: 12.5px; color: var(--ardoise); }

.notes { display: grid; gap: 12px; }
.note { padding: 14px 16px; border-radius: var(--r-champ); background: var(--nuage); }
.note__meta { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--ardoise); margin-bottom: 6px; }
.note__author { font: 600 13px/1 var(--f-ui); color: var(--encre); }

.doc { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--brume); }
.doc:last-child { border-bottom: 0; }
.doc__icon { width: 38px; height: 38px; border-radius: 12px; background: var(--nuage); display: grid; place-items: center; color: var(--ardoise); flex: none; }

/* Paliers */
.ladder { display: flex; align-items: stretch; gap: 0; }
.ladder__step { flex: 1 1 0; padding: 16px; border: 1px solid var(--brume); background: var(--blanc); position: relative; }
.ladder__step + .ladder__step { border-left: 0; }
.ladder__step:first-child { border-radius: var(--r-champ) 0 0 var(--r-champ); }
.ladder__step:last-child { border-radius: 0 var(--r-champ) var(--r-champ) 0; }
.ladder__label { font: 600 11px/1 var(--f-ui); letter-spacing: .08em; text-transform: uppercase; color: var(--ardoise); }
.ladder__value { margin-top: 8px; font: 700 18px/1.1 var(--f-chiffre); font-variant-numeric: tabular-nums; color: var(--encre); }
.ladder__bar { margin-top: 12px; height: 4px; border-radius: 999px; background: linear-gradient(90deg, var(--ocean), #68C1EA); }
.rules { display: grid; gap: 14px; }
.rule { display: flex; gap: 12px; align-items: flex-start; }
.rule__icon { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; background: var(--nuage); color: var(--encre); flex: none; }
.rule__title { font: 600 14px/1.35 var(--f-ui); color: var(--encre); }
.rule__text { font-size: 13.5px; color: var(--ardoise); }

/* Offres */
.offer { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px 24px; align-items: start; }
.bands { display: flex; gap: 8px; flex-wrap: wrap; }
.band { display: inline-flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: var(--r-interne); background: var(--nuage); font-size: 13.5px; }
.band__fee { font: 600 13px/1 var(--f-chiffre); color: var(--encre); padding-left: 10px; border-left: 1px solid var(--brume-fort); }
.band.is-off { opacity: .55; text-decoration: line-through; }
.bands-table td { padding: 10px 12px; }
.bands-table td:first-child { padding-left: 0; }
.bands-table td:last-child { padding-right: 0; }

/* ---------- Pages d'authentification ---------- */
.auth { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); min-height: 100vh; background: var(--blanc); }
.auth__brand { position: relative; overflow: hidden; background: linear-gradient(135deg, #07344C, #000B12); color: var(--blanc); padding: 48px 56px; display: flex; flex-direction: column; justify-content: space-between; }
.auth__k { position: absolute; right: -40%; top: -8%; height: 116%; width: auto; aspect-ratio: 340.14 / 396; color: rgba(255, 255, 255, .05); pointer-events: none;
  -webkit-mask-image: linear-gradient(90deg, transparent 40%, #000 72%); mask-image: linear-gradient(90deg, transparent 40%, #000 72%); }
.auth__k--line { fill: none; color: transparent; stroke: rgba(0, 196, 255, .34); stroke-width: 1.2; stroke-dasharray: 2 7; stroke-linecap: round; }
.auth__head { position: relative; display: flex; align-items: center; gap: 12px; }
.auth__pitch { position: relative; max-width: 600px; }
.auth__title { font: 700 44px/1.08 var(--f-titre); letter-spacing: -.02em; }
.auth__title span { display: block; color: var(--acier); }
.auth__text { margin-top: 20px; font-size: 16px; line-height: 1.6; color: #B8C2CA; max-width: 470px; }
.auth__points { position: relative; display: grid; gap: 18px; margin: 36px 0 0; padding: 0; list-style: none; }
.auth__points li { display: flex; gap: 14px; align-items: flex-start; }
.auth__point-icon { width: 36px; height: 36px; border-radius: 11px; flex: none; display: grid; place-items: center; background: rgba(0, 196, 255, .08); border: 1px solid rgba(0, 196, 255, .22); color: var(--cyan); }
.auth__point-title { display: block; font: 600 14.5px/1.35 var(--f-ui); color: var(--blanc); }
.auth__point-text { display: block; margin-top: 2px; font-size: 14px; line-height: 1.5; color: #9FAAB3; }
.auth__foot { position: relative; font-size: 13px; color: var(--acier); }
.auth__panel { display: flex; align-items: center; justify-content: center; padding: 48px 24px; }
.auth__card { width: 100%; max-width: 420px; }
.auth__card .page-title { font-size: 28px; }
.auth__mobile-logo { display: none; margin-bottom: 32px; }

/* ---------- Responsive ---------- */
@media (max-width: 1180px) {
  .grid--4, .kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--main { grid-template-columns: minmax(0, 1fr); }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--brume); }
}
@media (max-width: 960px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .sidebar { position: fixed; z-index: 40; left: 0; top: 0; width: 288px; transform: translateX(-100%); transition: transform .22s ease, box-shadow .22s; box-shadow: none; }
  .shell.is-open .sidebar { transform: none; box-shadow: var(--ombre-3); }
  .scrim { display: block; position: fixed; inset: 0; z-index: 30; background: rgba(0, 22, 34, .38); opacity: 0; pointer-events: none; transition: opacity .2s; }
  .shell.is-open .scrim { opacity: 1; pointer-events: auto; }
  .topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; position: sticky; top: 0; z-index: 20; height: 64px; padding: 0 16px; background: var(--blanc); border-bottom: 1px solid var(--brume); }
  .main { padding: 24px 16px 56px; }
  .page-title { font-size: 26px; }
  .grid--2, .grid--3 { grid-template-columns: minmax(0, 1fr); }
  .auth { grid-template-columns: minmax(0, 1fr); }
  .auth__brand { display: none; }
  .auth__mobile-logo { display: block; }
  .span-9, .span-8, .span-6, .span-5, .span-4, .span-3, .span-2 { grid-column: span 12; }
  .offer { grid-template-columns: minmax(0, 1fr); }
  .ladder { flex-direction: column; }
  .ladder__step + .ladder__step { border-left: 1px solid var(--brume); border-top: 0; }
  .ladder__step:first-child { border-radius: var(--r-champ) var(--r-champ) 0 0; }
  .ladder__step:last-child { border-radius: 0 0 var(--r-champ) var(--r-champ); }
}
@media (max-width: 640px) {
  .grid--4, .kpi-grid { grid-template-columns: minmax(0, 1fr); }
  .stats { grid-template-columns: minmax(0, 1fr); }
  .stat + .stat { border-left: 0; border-top: 1px solid var(--brume); }
  .choices { grid-template-columns: minmax(0, 1fr); }
  .block__body { padding: 20px 16px; }
  .bleed { margin-left: -16px; margin-right: -16px; }
  .block__head { padding: 16px; }
  .decision__head { padding: 16px; }
  .table th:first-child, .table td:first-child { padding-left: 16px; }
  .table th:last-child, .table td:last-child { padding-right: 16px; }
  .toolbar { padding: 12px 16px; }
  .hide-sm { display: none; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }

/* Erreurs de formulaire Symfony (liste par défaut) */
.alert__body ul { margin: 0; padding-left: 18px; }
.field ul { margin: 0; padding: 0; list-style: none; font-size: 12.5px; color: var(--rouge); }
