/* Korda V116 — corrections transversales de l'espace admin : interrupteurs, lignes, survol, contraste, avatars. */
/* 1. Interrupteurs : une seule couleur d'état actif (orange d'action) partout */
html body #view-espace.sa:not(#k1):not(#k2) .kd-sw .kd-sw-t{background:#D8D8D8!important}
html body #view-espace.sa:not(#k1):not(#k2) .kd-sw[aria-checked="true"] .kd-sw-t{background:#BF4F1A!important}
html body #view-espace.sa:not(#k1):not(#k2) .kd-sw .kd-sw-t::after{background:#fff!important}
html body #view-espace.sa:not(#k1):not(#k2) .kd-sw[aria-checked="true"] .kd-sw-l{color:var(--kr-ink)!important;font-weight:600}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) .kd-sw .kd-sw-t{background:#3A4A55!important}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) .kd-sw[aria-checked="true"] .kd-sw-t{background:#E0703A!important}
html body #view-espace.sa:not(#k1):not(#k2) .sa-sw{background:#D8D8D8!important;opacity:1!important}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) .sa-sw{background:#3A4A55!important}
html body #view-espace.sa:not(#k1):not(#k2) input[type="checkbox"],html body #view-espace.sa:not(#k1):not(#k2) input[type="radio"]{accent-color:#BF4F1A}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) input[type="checkbox"],html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) input[type="radio"]{accent-color:#E0703A}
html body .kd-sw[aria-checked="true"] .kd-sw-t{background:#BF4F1A}
html[data-theme="dark"] body .kd-sw[aria-checked="true"] .kd-sw-t{background:#E0703A}
/* 2. Lignes de liste : même gabarit compact et lisible, clair comme sombre */
html body #view-espace.sa:not(#k1):not(#k2) :is(.kp-req,.kgad-it,.k104a-l>li,.kg-row,.sa-set-l>li,.k104-avc,.sa-cont-row){background:var(--kr-card)!important;color:var(--kr-ink)!important;border:1px solid var(--kr-line)!important;border-radius:12px!important;box-shadow:none;margin:0 0 8px!important;overflow:visible}
html body #view-espace.sa:not(#k1):not(#k2) .kp-req,html body #view-espace.sa:not(#k1):not(#k2) .kgad-it,html body #view-espace.sa:not(#k1):not(#k2) .k104a-l>li{padding:0!important}
html body #view-espace.sa:not(#k1):not(#k2) .kp-req-h{padding:10px 14px!important;align-items:center!important;gap:10px 14px!important;flex-wrap:nowrap!important}
html body #view-espace.sa:not(#k1):not(#k2) .kp-req-h>div:first-child{min-width:0;flex:1}
html body #view-espace.sa:not(#k1):not(#k2) .kp-req-h b{font-size:14px;line-height:1.3;font-weight:600;color:var(--kr-ink)}
html body #view-espace.sa:not(#k1):not(#k2) .kp-req small,html body #view-espace.sa:not(#k1):not(#k2) .kp-req-h small{font-size:12px;line-height:1.4;color:var(--kr-mute)!important}
html body #view-espace.sa:not(#k1):not(#k2) .kp-req .sa-cont-act{flex:none;flex-wrap:nowrap;gap:8px;align-items:center}
html body #view-espace.sa:not(#k1):not(#k2) .kp-req>.sa-cont-msg,html body #view-espace.sa:not(#k1):not(#k2) .kp-req>.kp-det,html body #view-espace.sa:not(#k1):not(#k2) .kp-req>.kp-form{margin:0 14px 12px}
html body #view-espace.sa:not(#k1):not(#k2) :is(.kp-req,.kgad-it,.k104a-l>li,.kg-row,.sa-set-l>li) .btn{min-height:34px!important;padding:0 14px!important;font-size:13px!important;border-radius:999px!important}
@media(max-width:640px){html body #view-espace.sa:not(#k1):not(#k2) .kp-req-h{flex-wrap:wrap!important}}
html body #view-espace.sa:not(#k1):not(#k2) .k104a-r{padding:10px 14px!important;color:var(--kr-ink)!important}
html body #view-espace.sa:not(#k1):not(#k2) .k104a-nm,html body #view-espace.sa:not(#k1):not(#k2) .k104a-nm small,html body #view-espace.sa:not(#k1):not(#k2) .k104a-d{color:var(--kr-ink)!important}
html body #view-espace.sa:not(#k1):not(#k2) .k104a-nm small,html body #view-espace.sa:not(#k1):not(#k2) .k104a-d{color:var(--kr-mute)!important}
html body #view-espace.sa:not(#k1):not(#k2) .k104a-ref{color:#BF4F1A!important}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) .k104a-ref{color:#E0703A!important}
html body #view-espace.sa:not(#k1):not(#k2) .k104a-det{border-top-color:var(--kr-line)!important}
html body #view-espace.sa:not(#k1):not(#k2) .k104a-q{background:var(--kr-faint)!important;color:var(--kr-ink)!important}
html body #view-espace.sa:not(#k1):not(#k2) .k104a-q span{color:var(--kr-mute)!important}
html body #view-espace.sa:not(#k1):not(#k2) .kgad-top{padding:10px 14px}
/* pastilles et zones internes en tons neutres sur fond sombre */
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) :is(.k104eq-chip,.k104a-b:not(.s-nouvelle):not(.s-acceptee),.k104-avr,.k104a-chip:not(.on)){background:var(--kr-faint)!important;color:var(--kr-ink)!important;border-color:var(--kr-line)!important}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) .k104eq-chip.h,html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) .k104a-b.s-nouvelle{background:#3A2418!important;color:#F2B08A!important}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) .k104eq-chip.l,html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) .k104a-b.s-acceptee{background:#10332F!important;color:#6FC9BB!important}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) :is(.k104eq-f label,.k104eq-pm label,.k104eq-c,.k104eq-t,.k104-avc p){color:var(--kr-ink)!important}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) :is(.k104eq-c,.k104eq-t){border-top-color:var(--kr-line)!important}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) :is(.k104eq-f input,.k104eq-f select,.k104eq-f textarea){background:var(--kr-faint)!important;color:var(--kr-ink)!important;border-color:var(--kr-line)!important}
/* 3. Survol : même relief et même ombre « Korda » sur toutes les cartes et lignes */
html body #view-espace.sa:not(#k1):not(#k2) :is(.kp-req,.kgad-it,.k104a-l>li,.kg-row,.sa-set-l>li,.k104-avc,.sa-cont-row,.kr-mc,.kr-act,.sa-card,.esp-card,.vf-row,.sa-listcard){transition:box-shadow .2s ease,transform .2s ease,border-color .2s ease}
html body #view-espace.sa:not(#k1):not(#k2) :is(.kp-req,.kgad-it,.k104a-l>li,.kg-row,.sa-set-l>li,.k104-avc,.sa-cont-row,.kr-mc,.vf-row):hover{box-shadow:0 0 0 1px rgba(0,0,0,.02),0 2px 6px rgba(0,0,0,.04),0 4px 8px rgba(0,0,0,.1)!important;transform:translateY(-2px)}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) :is(.kp-req,.kgad-it,.k104a-l>li,.kg-row,.sa-set-l>li,.k104-avc,.sa-cont-row,.kr-mc,.vf-row):hover{box-shadow:0 0 0 1px rgba(0,0,0,.2),0 4px 12px rgba(0,0,0,.45)!important;border-color:#3A4A55!important}
html body #view-espace.sa:not(#k1):not(#k2) :is(.sa-card,.esp-card,.sa-listcard):hover{box-shadow:0 0 0 1px rgba(0,0,0,.02),0 2px 6px rgba(0,0,0,.04),0 4px 8px rgba(0,0,0,.1)}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) :is(.sa-card,.esp-card,.sa-listcard):hover{box-shadow:0 0 0 1px rgba(0,0,0,.2),0 4px 12px rgba(0,0,0,.4)}
@media(prefers-reduced-motion:reduce){html body #view-espace.sa:not(#k1):not(#k2) :is(.kp-req,.kgad-it,.k104a-l>li,.kg-row,.sa-set-l>li,.k104-avc,.sa-cont-row,.kr-mc,.vf-row):hover{transform:none}}
/* 4. Avatars annonceurs : même rendu que le site public (couleur, initiales, anneau blanc) */
html body #view-espace.sa:not(#k1):not(#k2) .kr-av.kr-av-c{color:#fff!important;border:1.5px solid rgba(255,255,255,.95)!important;font-weight:650;letter-spacing:.02em;box-shadow:0 1px 2px rgba(0,0,0,.22),0 6px 14px -8px rgba(0,0,0,.5)}
/* 5. Contraste : surfaces et textes corrigés par js/149-admin-contraste.js */
html[data-theme="dark"] [data-ks]{background-color:#16232D!important;border-color:#2A3943!important}
html[data-theme="dark"] [data-ks="2"]{background-color:#1B2C38!important}
[data-kt="l"]{color:#F2F5F6!important}
[data-kt="d"]{color:#222222!important}
[data-km="l"]{color:#A3AFB6!important}
/* 6. Bouton rond « Retour » de l'en-tête : fond et flèche lisibles en mode sombre */
html[data-theme="dark"] body #k104-back{background:#15232D!important;border-color:#2A3943!important;color:#F2F5F6!important}
html[data-theme="dark"] body #k104-back:hover{background:#1B2C38!important}
/* 7. Ordre d'affichage : en-tête, salutation et bandeau de rubrique toujours en tête de page */
html body #view-espace.sa:not(#k1):not(#k2) .esp-main>#kd-head{order:-102}
html body #view-espace.sa:not(#k1):not(#k2) .esp-main>#esp-hello{order:-101}
html body #view-espace.sa:not(#k1):not(#k2) .esp-main>.kr-band{order:-100}
/* 8. Icône dans le coin coloré des cartes chiffres : lisible en mode sombre (coin clair) */
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) :is(.kr-kpi,.sa-kpi,.sa-vtile) .sa-ico{color:#0E1922!important}
/* 9. Police : tous les champs, listes, boutons et libellés de l'espace admin utilisent Figtree (plus d'ancienne police) */
html body #view-espace.sa:not(#k1):not(#k2) *:not(svg):not(svg *),
html body #view-espace.sa:not(#k1):not(#k2) :is(input,select,textarea,button,option,optgroup){font-family:"Figtree",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif!important}
/* 10. Mon compte : identité identique à celle des annonces (cercle, anneau blanc, sceau vérifié) */
html body #view-espace.sa:not(#k1):not(#k2) .esp-main>#blk-profil{order:-90}
html body #view-espace.sa:not(#k1):not(#k2) .esp-main>#blk-activite{order:-80}
html body #view-espace.sa:not(#k1):not(#k2) #espace-profil.kc-id{display:flex;flex-wrap:wrap;align-items:center;gap:20px 24px}
html body #view-espace.sa:not(#k1):not(#k2) .kc-pic{position:relative;flex:none;display:inline-block;width:88px;height:88px}
html body #view-espace.sa:not(#k1):not(#k2) .kc-pic .esp-avatar{width:88px!important;height:88px!important;font-size:28px!important;font-weight:650!important;letter-spacing:.02em;border:2px solid #fff;box-sizing:border-box;box-shadow:0 3px 8px -4px rgba(8,18,26,.5),0 0 0 1px rgba(0,0,0,.06)!important;overflow:hidden;position:relative}
html body #view-espace.sa:not(#k1):not(#k2) .kc-pic .esp-avatar img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
html body #view-espace.sa:not(#k1):not(#k2) .kc-pic .esp-avatar.kc-k{background:#E0703A!important;color:#fff!important}
html body #view-espace.sa:not(#k1):not(#k2) .kc-pic .esp-avatar.kc-k svg{width:58%;height:58%;display:block}
html[data-theme="dark"] body #view-espace.sa:not(#k1):not(#k2) .kc-pic .esp-avatar{border-color:#15232D}
html body #view-espace.sa:not(#k1):not(#k2) .kc-ck{position:absolute;right:-2px;bottom:-2px;width:30px;height:30px;display:block;filter:drop-shadow(0 1px 2px rgba(0,0,0,.25))}
html body #view-espace.sa:not(#k1):not(#k2) .kc-ck svg{width:100%;height:100%;display:block}
html body #view-espace.sa:not(#k1):not(#k2) #espace-profil .esp-id{flex:1;min-width:240px}
html body #view-espace.sa:not(#k1):not(#k2) #espace-profil .esp-name{font-size:26px!important;line-height:32px!important;font-weight:650!important;margin:0!important;color:var(--kr-ink)}
html body #view-espace.sa:not(#k1):not(#k2) #espace-profil .esp-name::before{display:none!important}
html body #view-espace.sa:not(#k1):not(#k2) .kc-off{margin:2px 0 10px;color:var(--kr-mute);font-size:14px}
html body #view-espace.sa:not(#k1):not(#k2) #espace-profil .esp-head-actions{flex:none;display:flex;gap:8px;flex-wrap:wrap}
@media(max-width:700px){html body #view-espace.sa:not(#k1):not(#k2) #espace-profil.kc-id{align-items:flex-start}html body #view-espace.sa:not(#k1):not(#k2) .kc-pic{width:72px;height:72px}html body #view-espace.sa:not(#k1):not(#k2) .kc-pic .esp-avatar{width:72px!important;height:72px!important;font-size:24px!important}}
html body #view-espace.sa:not(#k1):not(#k2)[data-pan="compte"] .esp-main{display:flex!important;flex-direction:column}
html body #view-espace.sa:not(#k1):not(#k2) #espace-profil .esp-b{display:inline-flex;align-items:center;gap:.3em;white-space:pre}
