/* Rodin Connect — feuille de style unique (mobile d'abord) */
@font-face{font-family:"Jakarta";src:url(fonts/jakarta.woff2) format("woff2");font-weight:400 800;font-display:swap}
@font-face{font-family:"Bricolage";src:url(fonts/bricolage.woff2) format("woff2");font-weight:600 800;font-display:swap}

:root{
  --navy:#0F4166;--navy-d:#0B3354;--navy-l:#1A4D78;--navy-soft:#E7EEF5;--navy-tint:#F3F7FB;
  --orange:#EE7F23;--orange-t:#A4520C;--orange-d:#7A3C07;--orange-soft:#FFF4EA;--orange-l:#F7A866;
  --ink:#1B1F24;--muted:#5B6675;--line:#E3E8EF;--line-2:#D3DAE3;--bg:#F5F7FA;--white:#fff;--grey-soft:#EEF2F6;
  --green:#1E6B3A;--green-soft:#E4F3EA;--blue:#1D5FA8;--blue-soft:#E6F0FB;--red:#B42318;--red-soft:#FDECEA;--amber:#8A4A0B;--amber-soft:#FEF1E2;
  --side-text:#B8C7D8;--r:14px;--r-lg:18px;--shadow:0 1px 2px rgba(15,65,102,.06),0 8px 24px -16px rgba(15,65,102,.25);
  --f-body:"Jakarta","Segoe UI",system-ui,-apple-system,sans-serif;--f-head:"Bricolage","Jakarta","Segoe UI",system-ui,sans-serif;
}
*,*::before,*::after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;font-family:var(--f-body);font-size:15px;line-height:1.5;color:var(--ink);background:var(--bg);-webkit-font-smoothing:antialiased}
img{max-width:100%;display:block}
a{color:var(--navy)}a:hover{color:var(--navy-d)}
h1,h2,h3,h4{margin:0;line-height:1.15;color:var(--ink)}
h1,.h1{font-family:var(--f-head);font-size:clamp(26px,3.2vw,36px);font-weight:700;letter-spacing:-.02em;color:var(--navy)}
h2,.h2{font-size:22px;font-weight:700}
.h3{font-size:17px;font-weight:700}
.h4{font-size:15px;font-weight:700}
p{margin:0}
code{font-family:ui-monospace,Menlo,Consolas,monospace;font-size:.92em;background:var(--grey-soft);padding:1px 6px;border-radius:6px}
.sr{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.muted{color:var(--muted)}.small{font-size:13px}.center{text-align:center}.nowrap{white-space:nowrap}.mt{margin-top:18px}
.t-red{color:var(--red)!important}.t-orange{color:var(--amber)!important}.t-green{color:var(--green)!important}
.inline{display:inline}
.ic{width:18px;height:18px;flex:none}
:focus-visible{outline:3px solid rgba(238,127,35,.55);outline-offset:2px}

/* ------------------------------------------------ Mise en page */
.shell{display:flex;flex-wrap:wrap;min-height:100vh}
.sidebar{flex:1 1 260px;max-width:100%;background:var(--navy-d);color:#fff;padding:22px 16px;display:flex;flex-direction:column;gap:22px}
.page{flex:999 1 560px;min-width:0;padding:28px clamp(16px,3vw,40px) 64px;display:flex;flex-direction:column;gap:22px;max-width:1500px}
.page-prof{max-width:1200px;margin:0 auto;width:100%;flex:none}
.side-head{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:0 8px}
.brand{font-family:var(--f-head);font-size:24px;font-weight:800;letter-spacing:-.01em;color:#fff;text-decoration:none}
.brand span{color:var(--orange-l)}.brand:hover{color:#fff}
.brand-dark{color:var(--navy)}.brand-dark span{color:var(--orange-t)}.brand-dark:hover{color:var(--navy)}
.brand-lg{font-size:30px}
.menu-toggle{display:none;width:44px;height:44px;border:0;border-radius:10px;background:var(--navy-l);color:#fff;align-items:center;justify-content:center;cursor:pointer}
.side-nav{display:flex;flex-direction:column;gap:3px}
.side-nav a{min-height:44px;display:flex;align-items:center;gap:12px;padding:0 12px;border-radius:10px;color:var(--side-text);font-weight:600;text-decoration:none}
.side-nav a:hover{background:rgba(255,255,255,.06);color:#fff}
.side-nav a.active{background:var(--navy-l);color:#fff;font-weight:700}
.side-nav a span{flex:1}
.count{min-width:22px;height:22px;padding:0 7px;border-radius:999px;background:var(--orange);color:var(--ink);font-size:12px;font-weight:800;display:inline-flex;align-items:center;justify-content:center}
.side-me{margin-top:auto;display:flex;align-items:center;gap:10px;padding:14px 8px 0;border-top:1px solid #1F4B72}
.me-name{display:flex;flex-direction:column;line-height:1.3;min-width:0;flex:1}
.me-name b{font-size:14px}.me-name small{font-size:12.5px;color:var(--side-text)}
.topbar .me-name small{color:var(--muted)}
.topbar{background:#fff;border-bottom:1px solid var(--line);position:sticky;top:0;z-index:20}
.topbar-in{max-width:1200px;margin:0 auto;padding:10px clamp(16px,3vw,24px);min-height:68px;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px}
.topnav{display:flex;gap:6px;flex-wrap:wrap}
.topnav a{min-height:44px;display:flex;align-items:center;gap:8px;padding:0 14px;border-radius:10px;color:var(--ink);font-weight:600;text-decoration:none}
.topnav a.active{background:var(--navy-soft);color:var(--navy);font-weight:700}
.me{display:flex;align-items:center;gap:10px}
@media (max-width:860px){
  .shell{flex-direction:column;flex-wrap:nowrap}
  .sidebar{flex:none;padding:12px 14px;gap:10px;position:sticky;top:0;z-index:30}
  .menu-toggle{display:inline-flex}
  .side-nav,.side-me{display:none}
  .sidebar.open .side-nav,.sidebar.open .side-me{display:flex}
  .page{flex:none;width:100%;padding:20px 14px 56px}
  .topnav a span{display:none}.topnav a{padding:0 12px}
  .me-name{display:none}
}

.page-head{display:flex;flex-wrap:wrap;align-items:flex-end;justify-content:space-between;gap:14px}
.page-head .actions,.actions{display:flex;flex-wrap:wrap;gap:10px}
.eyebrow{font-size:13px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--muted);margin-bottom:6px;display:block}
.eyebrow.light{color:var(--orange-l)}
.lead{font-size:16px;color:var(--muted);max-width:720px}
.crumbs{display:flex;flex-wrap:wrap;align-items:center;gap:10px;font-size:14px;color:var(--muted)}
.crumbs a{display:inline-flex;align-items:center;gap:6px;font-weight:700;text-decoration:none;min-height:32px}
.grid-2{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(380px,100%),1fr));gap:20px;align-items:start}
.grid-2.tight{gap:14px}
.grid-3{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(200px,100%),1fr));gap:14px}
.grid-2-1{display:grid;grid-template-columns:minmax(0,2fr) minmax(0,1fr);gap:20px;align-items:start}
@media (max-width:1000px){.grid-2-1{grid-template-columns:1fr}}
.layout-aside{display:flex;flex-wrap:wrap;gap:22px;align-items:flex-start}
.layout-aside>:first-child{flex:999 1 560px;min-width:0}
.layout-aside>.aside-stack{flex:1 1 300px;min-width:0}
.aside-stack{display:flex;flex-direction:column;gap:16px}
.sticky{position:sticky;top:20px}
@media (max-width:860px){.sticky{position:static}}
.stack-sm{display:flex;flex-direction:column;gap:12px}

/* ------------------------------------------------ Cartes */
.card{background:#fff;border:1px solid var(--line);border-radius:var(--r-lg);padding:22px;box-shadow:var(--shadow);display:flex;flex-direction:column;gap:14px;min-width:0}
.card.flush{padding:0;gap:0;overflow:hidden}
.card .pad,.pad{padding:18px 22px}
.card-navy{background:var(--navy);color:#fff;border-color:var(--navy)}
.card-navy h2,.card-navy h3{color:#fff}
.card-dashed{border-style:dashed;border-width:2px;box-shadow:none;background:transparent}
.muted-title{color:var(--muted);text-transform:uppercase;letter-spacing:.06em;font-size:12.5px}
.head-row{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px}
.dots{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:10px;font-size:14px;color:#C9D6E4}
.dots li{display:flex;gap:10px}.dots li::before{content:"";width:8px;height:8px;margin-top:7px;border-radius:50%;background:var(--orange);flex:none}
.dl{margin:0;display:flex;flex-direction:column;gap:10px;font-size:14px}
.dl div{display:flex;justify-content:space-between;gap:12px}.dl dt{color:var(--muted)}.dl dd{margin:0;font-weight:700;text-align:right}
.dl-row{flex-direction:row;flex-wrap:wrap;gap:24px}.dl-row div{flex-direction:column;justify-content:flex-start}.dl-row dd{text-align:left}

/* ------------------------------------------------ Boutons */
.btn{min-height:46px;display:inline-flex;align-items:center;justify-content:center;gap:8px;padding:0 20px;border-radius:12px;border:1.5px solid var(--navy);background:var(--navy);color:#fff;font:inherit;font-weight:700;font-size:15px;text-decoration:none;cursor:pointer;white-space:nowrap}
.btn:hover{background:var(--navy-d);color:#fff}
.btn-ghost{background:#fff;color:var(--navy);border-color:var(--line-2)}
.btn-ghost:hover{background:var(--navy-tint);color:var(--navy);border-color:var(--navy)}
.btn-danger{background:var(--red);border-color:var(--red)}.btn-danger:hover{background:#8f1c13}
.btn-sm{min-height:38px;padding:0 14px;font-size:14px;border-radius:10px}
.btn-lg{min-height:54px;font-size:16px}
.btn-block{width:100%}
.btn[disabled],.btn.is-busy{opacity:.6;pointer-events:none}
.btn-icon{width:44px;height:44px;border:0;border-radius:10px;background:transparent;color:var(--navy);display:inline-flex;align-items:center;justify-content:center;cursor:pointer;text-decoration:none}
.btn-icon:hover{background:var(--navy-soft)}
.btn-icon.danger{color:var(--red)}.btn-icon.danger:hover{background:var(--red-soft)}
.btn-icon.on-dark{color:var(--side-text)}.btn-icon.on-dark:hover{background:rgba(255,255,255,.08);color:#fff}
.btn-icon span{display:none}
.btn-icon[disabled]{opacity:.35;cursor:default}
.btn-icon.flip .ic{transform:rotate(180deg)}
.danger-text{color:var(--red)!important}
.link{display:inline-flex;align-items:center;gap:6px;font-weight:700;font-size:14px;min-height:36px}
.link-orange{color:var(--orange-t)}.link-orange:hover{color:var(--orange-d)}

/* ------------------------------------------------ Formulaires */
.form{gap:18px}
.field{display:flex;flex-direction:column;gap:7px;border:0;margin:0;padding:0;min-width:0}
.field>label,.field>legend{font-size:14px;font-weight:700;padding:0}
fieldset.field legend{margin-bottom:8px}
input:not([type]),input[type=text],input[type=password],input[type=email],input[type=tel],input[type=number],input[type=search],input[type=date],select,textarea{
  width:100%;min-height:48px;padding:10px 14px;border:1.5px solid var(--line-2);border-radius:12px;background:#fff;font:inherit;font-size:15px;color:var(--ink)}
textarea{min-height:90px;line-height:1.55;resize:vertical}
input:focus,select:focus,textarea:focus{border-color:var(--navy);outline:3px solid rgba(15,65,102,.12);outline-offset:0}
input[type=file]{font:inherit;font-size:14px;max-width:100%}
.input-group{display:flex;align-items:center;border:1.5px solid var(--line-2);border-radius:12px;padding-left:2px;background:#fff}
.input-group input{border:0;outline:none;min-height:46px}
.input-group:focus-within{border-color:var(--navy)}
.check{display:inline-flex;align-items:center;gap:10px;font-size:14px;min-height:40px;cursor:pointer}
.check input{width:18px;height:18px;margin:0;accent-color:var(--navy)}
.form-actions{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:12px;padding-top:6px}
.form-actions>.muted:first-child,.form-actions>.check:first-child,.form-actions>.link:first-child{margin-right:auto}
.inline-form{flex-direction:row;flex-wrap:wrap;align-items:flex-end}
.grow{flex:1 1 240px}
.radio-cards{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(210px,100%),1fr));gap:10px}
.radio-card{display:flex;gap:12px;align-items:flex-start;padding:14px 16px;border-radius:14px;border:1.5px solid var(--line-2);background:#fff;cursor:pointer}
.radio-card input{margin:3px 0 0;width:18px;height:18px;accent-color:var(--navy);flex:none}
.radio-card span{display:flex;flex-direction:column;gap:3px}
.radio-card small{color:var(--muted);font-size:13px;line-height:1.4}
.radio-card:has(input:checked){border:2px solid var(--navy);background:var(--navy-tint)}
.radio-card:has(input:checked) b{color:var(--navy)}
.seg{display:flex;flex-wrap:wrap;gap:4px;padding:4px;border-radius:12px;background:var(--line)}
.seg-btn{min-height:40px;padding:0 14px;border:0;border-radius:9px;background:transparent;font:inherit;font-size:14px;font-weight:600;color:var(--ink);cursor:pointer;text-decoration:none;display:inline-flex;align-items:center}
.seg-btn.active{background:#fff;font-weight:800;box-shadow:0 1px 3px rgba(15,65,102,.18)}
.seg-btn.st-non_traitee.active{color:var(--red)}.seg-btn.st-en_cours.active{color:var(--amber)}.seg-btn.st-traitee.active{color:var(--green)}
.seg-urgency{background:transparent;padding:0;gap:10px;display:grid;grid-template-columns:repeat(auto-fit,minmax(min(140px,100%),1fr))}
.seg-opt{min-height:50px;display:flex;align-items:center;gap:10px;padding:0 14px;border-radius:12px;border:1.5px solid var(--line-2);background:#fff;font-weight:600;cursor:pointer}
.seg-opt input{margin:0;width:18px;height:18px;accent-color:var(--navy)}
.bars{display:inline-flex;align-items:flex-end;gap:2px;height:16px}
.bars i{width:4px;border-radius:1px;background:var(--line-2)}
.bars i:nth-child(1){height:5px}.bars i:nth-child(2){height:9px}.bars i:nth-child(3){height:12px}.bars i:nth-child(4){height:16px}
.bars i.on{background:var(--navy)}
.urg-opt-urgente .bars i.on{background:var(--red)}.urg-opt-elevee .bars i.on{background:var(--orange-t)}
.seg-opt:has(input:checked){border-width:2px;border-color:var(--navy);background:var(--navy-tint)}
.urg-opt-elevee:has(input:checked){border-color:var(--orange);background:var(--orange-soft);color:var(--orange-d)}
.urg-opt-urgente:has(input:checked){border-color:var(--red);background:var(--red-soft);color:var(--red)}
.search{display:flex;align-items:center;gap:8px;min-height:46px;padding:0 12px;border:1.5px solid var(--line-2);border-radius:12px;background:#fff;color:var(--muted);flex:0 1 300px}
.search input{border:0;outline:none;min-height:42px;padding:0;background:transparent}
.search:focus-within{border-color:var(--navy)}
.sel{display:flex;flex-direction:column;gap:4px;font-size:12px;font-weight:700;color:var(--muted)}
.sel select{min-height:44px;font-weight:600;padding:8px 12px;width:auto;min-width:150px}
.recipient-box{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px;padding:14px;border-radius:14px;background:var(--bg)}
.dropzone{border:2px dashed #9FB3C8;border-radius:14px;background:var(--bg);padding:12px 14px;display:flex;flex-direction:column;gap:10px}
.dropzone label{display:flex;align-items:center;gap:12px;cursor:pointer;color:var(--navy);min-height:44px}
.dropzone label span{display:flex;flex-direction:column}
.dropzone label small{color:var(--muted);font-weight:500}
.dropzone input[type=file]{position:absolute;width:1px;height:1px;opacity:0}
.dropzone.drag{border-color:var(--navy);background:var(--navy-tint)}
.dropzone:focus-within{border-color:var(--navy)}
.dz-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px}
.dz-list li{display:flex;justify-content:space-between;gap:10px;padding:8px 10px;border-radius:10px;background:#fff;font-size:13.5px}
.dz-list li small{color:var(--muted);white-space:nowrap}
.dz-error{color:var(--red);font-size:13.5px;font-weight:600}
.counter{text-align:right}

/* ------------------------------------------------ Étiquettes */
.tag{display:inline-flex;align-items:center;gap:6px;padding:3px 9px;border-radius:7px;background:var(--grey-soft);font-size:12.5px;font-weight:700;color:var(--ink);white-space:nowrap}
.tag-type{background:var(--navy-soft);color:var(--navy)}
.urg-faible,.urg-normale{background:var(--grey-soft);color:var(--ink)}
.urg-elevee{background:var(--orange-soft);color:var(--orange-d)}
.urg-urgente{background:var(--red-soft);color:var(--red)}
.status{display:inline-flex;align-items:center;gap:6px;padding:4px 10px;border-radius:999px;font-size:13px;font-weight:700;white-space:nowrap}
.status i{width:10px;height:10px;border-radius:50%;border:2px solid currentColor;box-sizing:border-box}
.status-non_traitee{background:var(--red-soft);color:var(--red)}
.status-en_cours{background:var(--amber-soft);color:var(--amber)}.status-en_cours i{background:linear-gradient(90deg,transparent 50%,currentColor 50%)}
.status-traitee{background:var(--green-soft);color:var(--green)}.status-traitee i{background:currentColor}
.pill{display:inline-flex;align-items:center;gap:6px;padding:4px 10px;border-radius:999px;font-size:12.5px;font-weight:700;white-space:nowrap}
.pill-orange{background:var(--orange);color:var(--ink)}.pill-navy{background:var(--navy);color:#fff}
.pill-soft{background:var(--grey-soft);color:var(--muted)}.pill-green{background:var(--green-soft);color:var(--green)}
.pill-blue{background:var(--blue-soft);color:var(--blue)}.pill-red{background:var(--red-soft);color:var(--red)}
.pill-dashed{border:1.5px dashed var(--orange-t);color:var(--orange-d);background:transparent}
.note{display:inline-flex;align-items:center;justify-content:center;min-width:46px;padding:4px 10px;border-radius:999px;font-weight:800;font-size:13.5px;white-space:nowrap}
.note-excellent{background:var(--green-soft);color:var(--green)}.note-bien{background:var(--blue-soft);color:var(--blue)}
.note-passable{background:var(--amber-soft);color:var(--amber)}.note-insuffisant{background:var(--red);color:#fff}.note-none{background:var(--grey-soft);color:var(--muted)}
.tags{display:flex;flex-wrap:wrap;gap:6px;align-items:center}
.tag-removable{padding-right:2px}
.tag-x{width:24px;height:24px;border:0;border-radius:6px;background:transparent;color:var(--muted);display:inline-flex;align-items:center;justify-content:center;cursor:pointer}
.tag-x:hover{background:var(--red-soft);color:var(--red)}.tag-x .ic{width:14px;height:14px}
.niveau-chips{display:flex;flex-wrap:wrap;gap:6px}

/* ------------------------------------------------ Barres d'outils, onglets */
.toolbar{display:flex;flex-wrap:wrap;align-items:flex-end;justify-content:space-between;gap:12px}
.filters{display:flex;flex-wrap:wrap;align-items:flex-end;gap:10px}
.filters.toolbar{justify-content:flex-start}
.chips{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.chip{min-height:42px;display:inline-flex;align-items:center;gap:6px;padding:0 16px;border-radius:999px;border:1.5px solid var(--line-2);background:#fff;color:var(--ink);font:inherit;font-size:14px;font-weight:600;text-decoration:none;cursor:pointer}
.chip b{font-weight:800}
.chip.active{background:var(--navy);border-color:var(--navy);color:#fff}
.chip-red:not(.active){color:var(--red)}.chip-orange:not(.active){color:var(--amber)}.chip-green:not(.active){color:var(--green)}
.chip-check{border:1.5px solid var(--line-2);border-radius:999px;padding:0 14px;background:#fff}
.chip-check:has(input:checked){border-color:var(--navy);background:var(--navy-tint)}
.tabs{display:flex;flex-wrap:wrap;gap:6px;border-bottom:1.5px solid var(--line)}
.tabs a{min-height:44px;display:inline-flex;align-items:center;gap:8px;padding:0 14px;margin-bottom:-1.5px;border-bottom:3px solid transparent;color:var(--muted);font-weight:700;text-decoration:none}
.tabs a.active{color:var(--navy);border-bottom-color:var(--orange)}
.tabs .count{background:var(--grey-soft);color:var(--muted)}
.tabs a.active .count{background:var(--navy-soft);color:var(--navy)}
.tabs-lg a{font-size:16px;min-height:52px}
.stepper{list-style:none;margin:0;padding:0;display:flex;flex-wrap:wrap;gap:10px;font-size:14px;font-weight:600}
.stepper li{display:flex;align-items:center;gap:10px;padding:6px 16px 6px 6px;border-radius:999px;background:#fff;border:1px solid var(--line);color:var(--muted)}
.stepper b{width:28px;height:28px;border-radius:50%;background:var(--grey-soft);display:flex;align-items:center;justify-content:center}
.stepper .current{background:var(--navy);color:#fff;border-color:var(--navy)}.stepper .current b{background:var(--orange);color:var(--ink)}
.stepper .done{color:var(--green)}.stepper .done b{background:var(--green-soft)}

/* ------------------------------------------------ Messages flash */
.flash{padding:13px 16px;border-radius:12px;font-weight:600;font-size:14.5px;background:var(--navy-soft);color:var(--navy)}
.flash-success{background:var(--green-soft);color:var(--green)}
.flash-error{background:var(--red-soft);color:var(--red)}
.flash-info{background:var(--blue-soft);color:#174C86}
.flash .link{min-height:auto}
.reveal{border:2px solid var(--orange);background:var(--orange-soft);border-radius:var(--r-lg);padding:20px;display:flex;flex-direction:column;gap:12px}
.reveal h2{display:flex;align-items:center;gap:8px;color:var(--orange-d)}
.reveal ul{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px}
.reveal li{display:flex;flex-wrap:wrap;justify-content:space-between;gap:10px;padding:10px 14px;border-radius:10px;background:#fff;font-weight:600}
.reveal code{font-size:20px;font-weight:800;letter-spacing:.18em;background:var(--navy);color:#fff;padding:4px 12px}
.reveal .btn{align-self:flex-start}
.empty-state{display:flex;flex-direction:column;align-items:center;text-align:center;gap:10px;padding:48px 20px;color:var(--muted)}
.empty-state .ic{width:40px;height:40px;color:#9FB3C8}
.empty-state h2{color:var(--ink)}
.empty-state .btn{margin-top:6px}

/* ------------------------------------------------ Avatars */
.avatar{border-radius:50%;object-fit:cover;background:var(--navy-soft);color:var(--navy);display:inline-flex;align-items:center;justify-content:center;font-weight:800;flex:none;aspect-ratio:1}
.avatar-xs{width:28px;height:28px;font-size:11px}.avatar-sm{width:38px;height:38px;font-size:13px}.avatar-md{width:46px;height:46px;font-size:15px}
.avatar-lg{width:58px;height:58px;font-size:18px}.avatar-xl{width:96px;height:96px;font-size:30px;font-family:var(--f-head);box-shadow:0 0 0 4px #fff,0 0 0 6px var(--line)}
.avatar-xxl{width:140px;height:140px;font-size:44px;font-family:var(--f-head)}
.avatar-xxl .ic{width:48px;height:48px}
.avatar-zoom{padding:0;border:0;background:none;border-radius:50%;cursor:zoom-in;flex:none;display:inline-flex}
.avatar-zoom:hover .avatar{box-shadow:0 0 0 3px var(--orange)}
.sidebar .avatar{background:var(--navy-soft)}
.person{display:inline-flex;align-items:center;gap:10px;min-width:0;text-decoration:none;color:inherit;text-align:left}
.person>span{display:flex;flex-direction:column;min-width:0;line-height:1.3}
.person b{font-weight:700}.person small{color:var(--muted);font-size:12.5px;font-weight:500}
.person-hero b{font-size:22px;color:#fff}.person-hero small{color:#C9D6E4;font-size:14px}
.lightbox{position:fixed;inset:0;z-index:100;background:rgba(8,24,40,.86);display:flex;align-items:center;justify-content:center;padding:24px}
.lightbox[hidden]{display:none}
.lightbox figure{margin:0;display:flex;flex-direction:column;align-items:center;gap:14px}
.lightbox img{width:min(512px,86vw);height:auto;border-radius:18px;box-shadow:0 30px 60px -20px rgba(0,0,0,.6)}
.lightbox figcaption{color:#fff;font-weight:700;font-size:18px}
.lb-close{position:absolute;top:16px;right:16px;width:48px;height:48px;border-radius:50%;border:0;background:rgba(255,255,255,.12);color:#fff;cursor:pointer;display:flex;align-items:center;justify-content:center}

/* ------------------------------------------------ Indicateurs */
.kpis{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(190px,100%),1fr));gap:14px}
.kpi{background:#fff;border:1px solid var(--line);border-radius:16px;padding:18px;display:flex;flex-direction:column;gap:4px;text-decoration:none;color:inherit;box-shadow:var(--shadow)}
.kpi span{font-size:13.5px;font-weight:600;color:var(--muted)}
.kpi b{font-family:var(--f-head);font-size:32px;font-weight:700;color:var(--navy);line-height:1.1}
.kpi b small{font-size:16px;color:var(--muted);font-family:var(--f-body)}
.kpi>small{font-size:12.5px;color:var(--muted)}
.kpi-navy{background:var(--navy);border-color:var(--navy)}.kpi-navy span,.kpi-navy>small,.kpi-navy b small{color:#C9D6E4}.kpi-navy b{color:#fff}
.kpi-red{background:var(--red-soft);border-color:#F5C2BC}.kpi-red span,.kpi-red b,.kpi-red>small{color:var(--red)}
.kpi-red:hover{border-color:var(--red)}.kpi-red>small{text-decoration:underline;font-weight:700}

/* ------------------------------------------------ Demandes */
.board{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(300px,100%),1fr));gap:18px;align-items:start}
.board-col{background:var(--grey-soft);border-radius:18px;padding:12px;display:flex;flex-direction:column;gap:10px}
.board-col h2{display:flex;align-items:center;gap:8px;padding:4px 4px 2px;font-size:15px}
.board-empty{padding:10px 6px}
.req-card{display:flex;flex-direction:column;gap:10px;padding:15px;border-radius:14px;background:#fff;border:1px solid var(--line);text-decoration:none;color:var(--ink);transition:box-shadow .15s,border-color .15s}
.req-card:hover{border-color:var(--navy);box-shadow:var(--shadow);color:var(--ink)}
.req-card.is-relance{border:2px solid var(--orange)}
.rc-top{display:flex;justify-content:space-between;gap:8px}
.rc-title{font-weight:700;font-size:15px;line-height:1.35;display:flex;gap:8px;align-items:baseline}
.rc-who{font-size:13px}
.rc-foot{display:flex;justify-content:space-between;align-items:center;gap:8px;font-size:12.5px;color:var(--muted)}
.rc-foot>span:first-child{display:inline-flex;align-items:center;gap:4px}
.rc-foot .ic{width:14px;height:14px}
.ack{display:inline-flex;align-items:center;gap:4px;color:var(--green);font-weight:700}.ack .ic{width:14px;height:14px}
.dot{width:9px;height:9px;border-radius:50%;background:var(--orange);display:inline-block;flex:none}
.req-list{display:flex;flex-direction:column;gap:10px}
.req-row{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:14px;padding:16px 18px;border-radius:16px;background:#fff;border:1px solid var(--line);text-decoration:none;color:var(--ink)}
.req-row:hover{border-color:var(--navy);color:var(--ink)}
.req-row.is-unread{border-left-width:1px;background:var(--navy-tint)}
.rr-main{display:flex;flex-direction:column;gap:6px;flex:1 1 420px;min-width:0}
.rr-title{font-weight:700;font-size:16px;display:flex;gap:8px;align-items:baseline}
.rr-meta{font-size:14px;color:var(--muted)}
.rr-tags{display:flex;flex-wrap:wrap;gap:8px;align-items:center;font-size:13px}
.req-head{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:flex-start;gap:18px}
.req-head>div{flex:1 1 420px;display:flex;flex-direction:column;gap:10px}
.status-form fieldset{border:0;margin:0;padding:0}
.status-form legend{font-size:12px;font-weight:700;color:var(--muted);margin-bottom:6px;padding:0}
.banners{display:flex;flex-wrap:wrap;gap:10px}
.banner{flex:1 1 320px;display:flex;align-items:center;gap:10px;padding:13px 16px;border-radius:14px;font-size:14px;font-weight:600}
.banner-navy{background:var(--navy-soft);color:var(--navy)}.banner-orange{background:var(--orange-soft);color:var(--orange-d)}.banner-grey{background:#fff;border:1px solid var(--line);color:var(--muted)}
.banner a{font-weight:700}
.thread{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:18px}
.msg{display:flex;gap:12px;align-items:flex-start}
.msg.from-recipient{flex-direction:row-reverse}
.msg-body{display:flex;flex-direction:column;gap:6px;min-width:0;max-width:min(640px,88%)}
.msg.from-recipient .msg-body{align-items:flex-end}
.msg-meta{font-size:13px;color:var(--muted);display:flex;flex-wrap:wrap;gap:4px;align-items:center}
.msg-meta b{color:var(--ink)}
.bubble{padding:13px 16px;border-radius:4px 16px 16px 16px;background:var(--bg);font-size:15px;line-height:1.6;overflow-wrap:anywhere}
.msg.from-recipient .bubble{border-radius:16px 4px 16px 16px;background:var(--navy);color:#fff}
.msg.relance .bubble{background:var(--orange-soft);color:var(--ink)}
.atts{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px;width:100%}
.att{display:flex;align-items:center;gap:10px;padding:8px 8px 8px 10px;border-radius:12px;background:#fff;border:1px solid var(--line);min-width:0}
.att>span:not(.att-icon){display:flex;flex-direction:column;min-width:0;flex:1}
.att b{font-size:14px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.att small{font-size:12px;color:var(--muted)}
.att-icon{width:40px;height:40px;border-radius:10px;background:var(--navy-soft);color:var(--navy);display:flex;align-items:center;justify-content:center;flex:none}
.att-thumb img{width:56px;height:56px;border-radius:10px;object-fit:cover}
.att.locked{opacity:.8}
.composer{display:flex;flex-direction:column;gap:12px;padding-top:18px;border-top:1px solid var(--line)}
.timeline{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:12px;font-size:14px}
.timeline li{display:flex;flex-direction:column;padding-left:20px;position:relative}
.timeline li::before{content:"";position:absolute;left:0;top:6px;width:10px;height:10px;border-radius:50%;background:var(--navy)}
.timeline .tl-orange::before{background:var(--orange)}.timeline .tl-green::before{background:var(--green)}
.timeline small{color:var(--muted)}
.pick-group{display:flex;flex-direction:column;gap:12px}
.pick-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(230px,100%),1fr));gap:16px}
.pick-card{background:#fff;border:1px solid var(--line);border-radius:18px;padding:24px 20px 20px;display:flex;flex-direction:column;align-items:center;text-align:center;gap:10px;box-shadow:var(--shadow)}
.pick-card h3{font-size:17px}
.pick-card .btn{margin-top:auto}
.pick-direction .pick-card{background:var(--navy);border-color:var(--navy)}
.pick-direction .pick-card h3{color:#fff}.pick-direction .pick-card .muted{color:#C9D6E4}
.pick-direction .pick-card .btn{background:#fff;color:var(--navy);border-color:#fff}
.pill.pill-soft{max-width:100%;white-space:normal}
.pick-card[hidden],.pick-group[hidden]{display:none}
.people-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(300px,100%),1fr));gap:14px}
.person-card{display:flex;align-items:center;gap:14px;padding:16px;background:#fff;border:1px solid var(--line);border-radius:16px}
.person-card>div{flex:1;min-width:0}
.people-list{list-style:none;margin:0;padding:0;display:flex;flex-direction:column}
.people-list li{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:10px;padding:10px 0;border-bottom:1px solid var(--line)}
.people-list li:last-child{border-bottom:0}

/* ------------------------------------------------ Tableaux */
.table-wrap{overflow-x:auto;-webkit-overflow-scrolling:touch}
.table{width:100%;border-collapse:collapse;font-size:14px;min-width:640px}
.table th,.table td{padding:12px 14px;border-bottom:1px solid var(--line);text-align:left;vertical-align:middle}
.table thead th{font-size:12.5px;font-weight:700;color:var(--muted);text-transform:uppercase;letter-spacing:.04em;background:#FAFBFD;white-space:nowrap}
.table tbody tr:last-child>*{border-bottom:0}
.table th[scope=row]{font-weight:600}
.table .num{text-align:right;white-space:nowrap}
.table tfoot td,.table tfoot th{background:#FAFBFD;border-top:1.5px solid var(--line);border-bottom:0}
.actions-cell{text-align:right;white-space:nowrap}
.actions-cell .btn+.btn{margin-left:6px}
.check-col{width:44px}.check-col input{width:18px;height:18px;accent-color:var(--navy)}
.row-red{background:var(--red-soft)}.row-red th,.row-red td{color:var(--red)}
.row-muted{opacity:.6}.row-active{background:var(--navy-tint)}
.rank{font-weight:800;font-size:16px;color:var(--muted)}.rank.podium{color:var(--orange-t)}
.rank-table .avatar-zoom .avatar,.rank-table .avatar{width:46px;height:46px}
.matrix{min-width:900px}
.matrix th small{display:block;font-weight:600;text-transform:none;letter-spacing:0}
.cell-excellent{background:#EEF8F1;color:var(--green);font-weight:700}.cell-bien{background:#F0F6FD;color:var(--blue);font-weight:700}
.cell-passable{background:#FEF6EC;color:var(--amber);font-weight:700}.cell-insuffisant{background:#FDF0EE;color:var(--red);font-weight:700}
.legend-crit{flex-direction:row;flex-wrap:wrap;gap:8px 18px;font-size:13.5px;padding:14px 18px}
.legend-crit b{color:var(--orange-t)}
.rate{display:flex;align-items:center;gap:10px;min-width:140px}
.meter{flex:1;height:8px;border-radius:4px;background:var(--line);overflow:hidden;display:block;min-width:60px}
.meter span{display:block;height:100%;border-radius:4px}
.m-navy{background:var(--navy)}.m-excellent{background:var(--green)}.m-bien{background:var(--blue)}.m-passable{background:var(--orange)}.m-insuffisant{background:var(--red)}
.bulk-bar{display:flex;justify-content:flex-start}
.pager{display:flex;align-items:center;justify-content:center;gap:14px}

/* ------------------------------------------------ Évaluations */
.eval-hero{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:18px;padding:24px;border-radius:var(--r-lg);background:var(--navy);color:#fff}
.eval-hero-meta{display:flex;flex-direction:column;gap:4px;color:#C9D6E4;font-size:14px}
.eval-form{display:flex;flex-direction:column;gap:18px}
.crit-section{gap:6px}
.crit-section-head{display:flex;justify-content:space-between;align-items:center;gap:12px;padding-bottom:6px}
.crit{padding:16px 0;border-top:1px solid var(--line);display:flex;flex-direction:column;gap:10px}
.crit-head{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px}
.crit-head h3{font-size:16px;display:flex;gap:10px;align-items:baseline}
.roman{font-family:var(--f-head);font-weight:800;color:var(--orange-t);min-width:26px}
.roman.big{font-size:24px}
.score-input{display:flex;align-items:center;gap:8px;font-weight:700;color:var(--muted)}
.score-input input{width:92px;text-align:center;font-weight:800;font-size:18px;color:var(--navy)}
.score-input input.over{border-color:var(--red);color:var(--red)}
.quick{display:flex;flex-wrap:wrap;gap:6px}
.quick button{width:44px;height:40px;border-radius:10px;border:1.5px solid var(--line-2);background:#fff;font:inherit;font-weight:800;cursor:pointer;color:var(--ink)}
.quick button.on{background:var(--navy);border-color:var(--navy);color:#fff}
.subs{margin:0;padding-left:20px;display:flex;flex-direction:column;gap:3px;font-size:13.5px;color:var(--muted)}
.crit-comment summary{cursor:pointer;font-size:13px;font-weight:700;color:var(--navy);min-height:32px;display:flex;align-items:center}
.crit-comment textarea{margin-top:6px;min-height:60px}
.total-card{align-items:flex-start}
.big-note{font-family:var(--f-head);font-size:56px;font-weight:700;line-height:1;color:var(--navy)}
.big-note small{font-size:20px;color:var(--muted);margin-left:6px;font-family:var(--f-body)}
.big-excellent{color:var(--green)}.big-bien{color:var(--blue)}.big-passable{color:var(--amber)}.big-insuffisant{color:var(--red)}
.mid-note .note{font-size:18px;padding:6px 14px}
.mini-scores{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;font-size:13.5px}
.mini-scores li{display:flex;justify-content:space-between;gap:10px;padding:7px 0;border-bottom:1px solid var(--line)}
blockquote{margin:0;padding:14px 16px;border-radius:12px;background:var(--bg);font-size:14px;line-height:1.6}
.final-preview{display:flex;flex-direction:column;gap:2px;padding:14px;border-radius:12px;background:var(--navy-soft);color:var(--navy)}
.final-preview b{font-family:var(--f-head);font-size:30px}
.final-preview span,.final-preview small{font-size:12.5px;font-weight:700}
.scale{list-style:none;margin:0;flex-direction:column;gap:8px;font-size:13.5px;font-weight:600}
.scale li{display:flex;align-items:center;gap:10px}
.scale i{width:12px;height:12px;border-radius:50%}
.lv-excellent{background:var(--green)}.lv-bien{background:var(--blue)}.lv-passable{background:var(--orange)}.lv-insuffisant{background:var(--red)}
.sheet-head{flex-direction:row;flex-wrap:wrap;align-items:center;gap:24px}
.sheet-id{flex:1 1 320px;display:flex;flex-direction:column;gap:8px}
.sheet-final{display:flex;flex-direction:column;align-items:flex-start;gap:6px;min-width:190px}
.sheet-actions{display:flex;flex-direction:column;gap:8px;align-items:flex-end}
.eval-sheet-head{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:flex-start;gap:12px}
.summary{padding:14px 16px;border-radius:12px;background:var(--navy-tint);color:var(--navy);font-weight:600;line-height:1.6}
.crit-group{margin-top:8px;padding-top:12px;border-top:1.5px solid var(--line);display:flex;gap:10px}
.crit-row{display:flex;flex-direction:column;gap:8px;padding:12px 0;border-bottom:1px solid var(--line)}
.crit-row:last-of-type{border-bottom:0}
.crit-row-head{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center;gap:12px}
.crit-row-head>b{display:flex;gap:10px;align-items:baseline}
.crit-score{display:flex;align-items:center;gap:12px;min-width:220px}
.crit-note{display:flex;gap:8px;align-items:flex-start;font-size:13.5px;color:var(--navy);background:var(--navy-tint);padding:8px 12px;border-radius:10px}
.crit-edit{gap:12px}
.crit-edit-head{display:flex;flex-wrap:wrap;align-items:flex-end;gap:12px}
.w-points{width:110px}
.order{display:flex;gap:2px}
.niveau-pick{display:flex;flex-direction:column;gap:8px}
.niveau-row{display:flex;flex-wrap:wrap;align-items:center;gap:12px}
.niveau-row .check{min-width:160px}
.niveau-row input:not([type]),.niveau-row input[type=text]{flex:1 1 220px;min-height:42px}
.niveau-row.inactive{opacity:.7}
.inline-edit{display:flex;gap:8px;align-items:center}
.inline-edit input{min-height:40px;max-width:240px}
.photo-preview{display:flex;justify-content:center}
.photo-preview img{width:140px;height:140px;border-radius:50%;object-fit:cover}
.profile-head{display:flex;flex-wrap:wrap;align-items:center;gap:18px}
.checks{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px;font-size:14px}
.checks li{display:flex;align-items:center;gap:8px}
.checks .ok{color:var(--green)}.checks .ko{color:var(--red);font-weight:700}
.mini-rank{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px}
.mini-rank li{display:flex;align-items:center;gap:10px;justify-content:space-between}
.mini-rank .person{flex:1}
.rk{font-weight:800;color:var(--orange-t);width:18px}

.mini-list summary{cursor:pointer;font-weight:700;color:var(--navy);min-height:36px;display:flex;align-items:center}
.mini-list ul{list-style:none;margin:8px 0 0;padding:0;display:flex;flex-direction:column;gap:8px;max-height:260px;overflow:auto}

/* ------------------------------------------------ Graphiques */
.chart{width:100%;height:auto;display:block;overflow:visible}
.chart .grid{stroke:#E3E8EF;stroke-width:1}
.chart .val{font:700 12px var(--f-body);fill:var(--ink)}
.chart .lbl{font:600 11px var(--f-body);fill:var(--muted)}
.hbars{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:12px}
.hbars li{display:grid;grid-template-columns:minmax(120px,1.2fr) minmax(80px,2fr) auto;align-items:center;gap:12px;font-size:13.5px}
.hb-label{font-weight:600;line-height:1.3}
.hb-track{height:10px;border-radius:5px;background:var(--grey-soft);overflow:hidden}
.hb-fill{display:block;height:100%;border-radius:5px}
.hb-val{font-weight:700;white-space:nowrap;font-size:13px}
@media (max-width:520px){.hbars li{grid-template-columns:1fr auto}.hb-track{grid-column:1/-1;grid-row:2}}
.legend{list-style:none;margin:10px 0 0;padding:0;display:flex;flex-wrap:wrap;gap:8px 16px;font-size:13px;color:var(--muted)}
.legend li{display:flex;align-items:center;gap:6px}
.legend i{width:10px;height:10px;border-radius:3px}
.legend b{color:var(--ink)}
.donut{display:flex;flex-wrap:wrap;align-items:center;gap:18px}
.donut svg{width:150px;height:150px;flex:none}
.donut .legend{flex-direction:column;margin:0}
.d-big{font:700 24px var(--f-head);fill:var(--navy)}.d-sub{font:600 9px var(--f-body);fill:var(--muted)}
.stack{display:flex;height:22px;border-radius:7px;overflow:hidden;gap:2px}

/* ------------------------------------------------ Connexion */
.auth-shell{min-height:100vh;display:flex;flex-direction:column}
.auth-split{display:flex;flex-wrap:wrap;min-height:100vh}
.auth-intro{flex:1 1 480px;padding:clamp(28px,5vw,56px) clamp(24px,5vw,64px);background:var(--navy);color:#fff;display:flex;flex-direction:column;justify-content:space-between;gap:40px;position:relative;overflow:hidden}
.auth-intro::after{content:"";position:absolute;right:-180px;bottom:-200px;width:560px;height:560px;border-radius:50%;
  background:radial-gradient(circle,var(--orange) 0 60px,transparent 61px 129px,rgba(238,127,35,.9) 130px 132px,transparent 133px 199px,rgba(238,127,35,.9) 200px 202px,transparent 203px 269px,rgba(238,127,35,.9) 270px 272px,transparent 273px);opacity:.22;pointer-events:none}
.auth-copy{display:flex;flex-direction:column;gap:18px;max-width:540px;position:relative;z-index:1}
.auth-copy h1{color:#fff;font-size:clamp(32px,4.4vw,52px);line-height:1.04;text-wrap:balance}
.auth-copy p:last-child{font-size:17px;line-height:1.6;color:#C9D6E4}
.auth-steps{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:14px;position:relative;z-index:1}
.auth-steps li{display:flex;align-items:center;gap:14px}
.auth-steps b{width:36px;height:36px;border-radius:50%;background:var(--orange);color:var(--ink);display:flex;align-items:center;justify-content:center;flex:none}
.auth-panel{flex:1 1 440px;padding:40px 20px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:20px}
.auth-card{width:100%;max-width:440px;background:#fff;border:1px solid var(--line);border-radius:20px;padding:clamp(24px,4vw,40px);display:flex;flex-direction:column;gap:20px;box-shadow:0 24px 48px -28px rgba(15,65,102,.35)}
.auth-card h2,.auth-card h1{font-family:var(--f-head);font-size:30px;color:var(--navy)}
.code-boxes{border:0;margin:0;padding:0}
.code-boxes legend{font-size:14px;font-weight:700;margin-bottom:10px;padding:0}
.code-boxes div{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
.code-boxes input{height:74px;text-align:center;font-size:30px;font-weight:800;color:var(--navy);border:2px solid var(--line-2);border-radius:14px;padding:0}
.code-boxes input:focus{border-color:var(--orange);outline:4px solid rgba(238,127,35,.22)}
.code-boxes input.filled{border-color:var(--navy)}
.hint-box{display:flex;gap:10px;align-items:center;padding:14px 16px;border-radius:12px;background:var(--orange-soft);color:var(--orange-d);font-size:14px}
.auth-center{min-height:100vh;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:26px;padding:40px 18px;background:var(--navy-d)}
.auth-roles{color:var(--side-text);font-size:14px;text-align:center}

/* ------------------------------------------------ Impression */
@media print{
  .sidebar,.topbar,.no-print,.crumbs,.toolbar,.form-actions,.sheet-actions,.btn,.btn-icon{display:none!important}
  body{background:#fff}.page{padding:0}.card{box-shadow:none;break-inside:avoid}
  .reveal{border-color:#000}
}
@media (prefers-reduced-motion:reduce){*{transition:none!important}}

.participants>div>small{display:block;margin-bottom:6px;text-transform:uppercase;letter-spacing:.04em;font-size:.72rem}
.radio-cards-4{grid-template-columns:repeat(2,1fr)}@media(max-width:520px){.radio-cards-4{grid-template-columns:1fr}}
/* Mobile : barre du haut sur une ligne, filtres pleine largeur, KPI compacts */
@media (max-width:860px){
  .topbar-in{flex-wrap:nowrap;gap:6px;min-height:60px}
  .topbar .brand{font-size:20px;flex:1;min-width:0}
  .topnav{flex-wrap:nowrap;gap:2px}.topnav a{padding:0 10px}
  .me{gap:4px}
  .filters>.search{flex:1 1 100%}
  .filters>.sel{flex:1 1 calc(50% - 10px);min-width:0}
  .filters>.sel select{width:100%}
  .kpis.kpis-3,.kpis-compact{grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
  .kpis-compact .kpi{padding:12px;border-radius:12px}
  .kpis-compact .kpi b{font-size:24px}
  .kpis-compact .kpi small{display:none}
  .kpis-compact .kpi span{font-size:12.5px;line-height:1.25}
}
@media (max-width:380px){.topbar .me .avatar{display:none}}
.banner-grey{flex-wrap:wrap}
@media (min-width:1000px){.kpis-6{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media (min-width:1500px){.kpis-6{grid-template-columns:repeat(6,minmax(0,1fr))}}
/* Tableaux en cartes sur mobile (classement, professeurs) */
@media (max-width:700px){
  .table.table-cards{min-width:0}
  .table-cards thead{display:none}
  .table-cards tbody tr{display:grid;gap:8px 12px;padding:14px;border-bottom:1px solid var(--line);align-items:center}
  .table-cards tbody td,.table-cards tbody th{display:block;padding:0;border:0;text-align:left;min-width:0}
  .table-cards tbody td.num{text-align:left}
  .table-cards td[data-label]::before{content:attr(data-label);display:block;font-size:11px;font-weight:700;color:var(--muted);text-transform:uppercase;letter-spacing:.04em;margin-bottom:2px}
  .rank-table tbody tr{grid-template-columns:28px minmax(0,1fr) minmax(0,1fr);grid-template-areas:"rank who who" ". ped dir" ". final act"}
  .rank-table .rank{grid-area:rank;align-self:start;padding-top:10px}
  .rank-table tbody th{grid-area:who}.rank-table .c-ped{grid-area:ped}.rank-table .c-dir{grid-area:dir}
  .rank-table .c-final{grid-area:final}.rank-table .c-act{grid-area:act;justify-self:end}
  .profs-table tbody tr{grid-template-columns:28px minmax(0,1fr) auto;grid-template-areas:"chk who act" ". niv niv" ". code last"}
  .profs-table .c-code{grid-area:code}
  .profs-table .check-col{grid-area:chk}.profs-table tbody th{grid-area:who}.profs-table .c-niv{grid-area:niv}
  .profs-table .c-last{grid-area:last;justify-self:end;text-align:right}.profs-table .actions-cell{grid-area:act;white-space:nowrap}
}
input[type=file]{width:100%;padding:10px;border:1.5px dashed var(--line-2);border-radius:12px;background:#fff;font:inherit;font-size:14px;color:var(--muted)}
input[type=file]::file-selector-button{margin-right:12px;padding:8px 14px;border:0;border-radius:10px;background:var(--navy-soft);color:var(--navy);font:inherit;font-weight:700;cursor:pointer}
/* Codes des professeurs (liste admin + étiquettes imprimables) */
.code-tools{display:flex;flex-wrap:wrap;gap:8px;margin:-4px 0 14px}
.code-cell{display:inline-flex;align-items:center;gap:6px}
.code-val{display:inline-block;min-width:3.6em;padding:5px 10px;border-radius:9px;background:var(--navy-soft);color:var(--navy);font:700 15px/1.2 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;letter-spacing:.18em;text-align:center}
.code-val.is-shown{background:var(--orange-soft);color:var(--orange-d)}
.btn-icon.btn-icon-sm{width:32px;height:32px}
.btn-icon.btn-icon-sm svg{width:16px;height:16px}
.code-slips{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:14px}
.code-slip{background:#fff;border:1.5px dashed var(--line-2);border-radius:16px;padding:16px 18px;display:flex;flex-direction:column;gap:6px;break-inside:avoid}
.code-slip header{display:flex;flex-direction:column;font-size:12px;color:var(--muted);border-bottom:1px solid var(--line);padding-bottom:8px;margin-bottom:4px}
.code-slip header b{color:var(--navy);font-size:13px}
.code-slip h3{margin:0;font-size:17px;color:var(--navy)}
.code-slip p{margin:0;font-size:13px}
.slip-code{margin:6px 0;padding:10px;border-radius:12px;background:var(--navy);color:#fff;text-align:center;font:800 34px/1 ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;letter-spacing:.35em;text-indent:.35em}
.slip-code.slip-none{background:var(--orange-soft);color:var(--orange-d);font-family:inherit;font-size:14px;font-weight:700;line-height:1.4;letter-spacing:0;text-indent:0}
.banner-codes{flex:none;flex-wrap:wrap;margin-bottom:16px}.banner-codes>div{flex:1 1 260px;font-weight:500}.banner-codes>div b{font-weight:700}
.code-slip footer{font-size:11.5px;color:var(--muted);line-height:1.45}
@media print{
  .code-slips{grid-template-columns:repeat(3,1fr);gap:0}
  .code-slip{border-radius:0;border:1px dashed #999;padding:12px 14px}
  .slip-code{background:#fff!important;color:#000!important;border:2px solid #000;-webkit-print-color-adjust:exact;print-color-adjust:exact}
  .page-head{margin-bottom:10px}
}
