:root {
  --nuit: #12203a;
  --nuit-2: #1b2d4f;
  --or: #c9a74d;
  --or-fonce: #9c7f2e;
  --or-clair: #f2e6c4;
  --charbon: #535353;
  --papier: #faf6ec;
  --encre: #1d2433;
  --gris: #6b7280;
  --ligne: #e5e0d4;
  --rouge: #b42318;
  --vert: #157f3b;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--papier); color: var(--encre); font-size: 16px; line-height: 1.45;
}
[hidden] { display: none !important; }
.marque { font-weight: 700; letter-spacing: .02em; display: flex; align-items: center; gap: .4em; }
.lampe { color: var(--or); }

/* Connexion */
.connexion { min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 30% 20%, var(--nuit-2), var(--nuit)); padding: 1rem; }
.carte-connexion { background: #fff; border-radius: 14px; padding: 2rem; width: 100%; max-width: 380px;
  box-shadow: 0 20px 50px rgba(0,0,0,.3); position: relative; }
.carte-connexion .marque { color: var(--nuit); margin-bottom: .5rem; }
.carte-connexion h1 { font-size: 1.3rem; margin: 0 0 1.2rem; color: var(--nuit); }
.carte-connexion label { display: block; margin-bottom: .9rem; font-size: .9rem; color: var(--gris); }
.carte-connexion input { display: block; width: 100%; margin-top: .3rem; }
.carte-connexion .lien-langue { position: absolute; top: 1rem; right: 1rem; color: var(--nuit); }

input, select { font: inherit; padding: .6rem .7rem; border: 1px solid var(--ligne); border-radius: 8px; background: #fff; color: var(--encre); width: 100%; }
input:focus, select:focus { outline: 2px solid var(--or); outline-offset: 1px; }

.btn { display: inline-block; font: inherit; font-weight: 600; border: 0; border-radius: 8px; padding: .65rem 1.1rem; cursor: pointer; text-decoration: none; text-align: center; }
.btn-or { background: var(--or); color: var(--nuit); }
.btn-or:hover { background: #d8b866; }
.btn-discret { background: transparent; color: inherit; border: 1px solid currentColor; }
.btn-petit { padding: .25rem .6rem; font-size: .8rem; font-weight: 500; }
.lien-langue { background: none; border: 0; font: inherit; font-size: .85rem; font-weight: 700; cursor: pointer; color: inherit; white-space: nowrap; }
.erreur { color: var(--rouge); min-height: 1.2em; font-size: .9rem; }
.msg { min-height: 1.2em; font-size: .9rem; margin: 0; align-self: center; }
.msg.ok { color: var(--vert); } .msg.ko { color: var(--rouge); }

/* Entete et onglets */
.entete { background: var(--nuit); color: #fff; display: flex; justify-content: space-between; align-items: center; padding: .8rem 1.2rem; }
.entete-droite { display: flex; gap: .8rem; align-items: center; }
.onglets { background: var(--nuit-2); display: flex; overflow-x: auto; padding: 0 .6rem; }
.onglets button { background: none; border: 0; color: #cfd6e4; font: inherit; padding: .8rem 1rem; cursor: pointer; white-space: nowrap; border-bottom: 3px solid transparent; }
.onglets button.actif { color: #fff; border-bottom-color: var(--or); }

main { max-width: 1100px; margin: 0 auto; padding: 1.2rem; }
.bloc { background: #fff; border: 1px solid var(--ligne); border-radius: 12px; padding: 1.2rem; margin-bottom: 1.2rem; }
.bloc h2 { font-size: 1.05rem; margin: 0 0 .8rem; color: var(--nuit); }
.bloc.centre { text-align: center; }
.bloc.centre .btn { margin: .4rem; }
.aide { color: var(--gris); font-size: .88rem; margin: -.3rem 0 .8rem; }
.periode { margin-bottom: .8rem; color: var(--gris); }

.tuiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; margin-bottom: 1.2rem; }
.tuile { background: #fff; border: 1px solid var(--ligne); border-radius: 12px; padding: 1rem; }
.tuile span { display: block; font-size: .85rem; color: var(--gris); }
.tuile strong { display: block; font-size: 1.35rem; margin-top: .2rem; color: var(--nuit); }
.tuile strong.neg { color: var(--rouge); }

.grille-form { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; align-items: end; }
.grille-form label { font-size: .85rem; color: var(--gris); }
.grille-form label span { display: block; margin-bottom: .25rem; }
.grille-form .large { grid-column: span 2; }

.defile { overflow-x: auto; }
.tableau { width: 100%; border-collapse: collapse; font-size: .92rem; }
.tableau th, .tableau td { padding: .5rem .6rem; border-bottom: 1px solid var(--ligne); text-align: left; vertical-align: top; }
.tableau th { font-size: .8rem; color: var(--gris); font-weight: 600; }
.tableau .num { text-align: right; white-space: nowrap; }
.tableau tr.annule td { color: var(--gris); text-decoration: line-through; }
.tableau tr.inverse td { color: var(--gris); font-style: italic; }
.vide { color: var(--gris); text-align: center; padding: 1rem; }
.liste-avenir { margin: 0; padding-left: 1.2rem; color: var(--gris); }

.cartes-liens { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.carte-lien { background: #fff; border: 1px solid var(--ligne); border-top: 4px solid var(--or); border-radius: 12px; padding: 1.1rem; display: flex; flex-direction: column; }
.carte-lien h3 { margin: 0 0 .3rem; color: var(--nuit); font-size: 1rem; }
.carte-lien p { color: var(--gris); font-size: .9rem; flex: 1; margin: 0 0 .9rem; }
.carte-lien .btn.desactive { opacity: .45; pointer-events: none; }

.pied { text-align: center; color: var(--gris); font-size: .78rem; padding: 1.5rem 1rem 2rem; }
.chargement { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; background: var(--papier); color: var(--gris); font-size: 2rem; }

@media (max-width: 760px) {
  .tuiles, .grille-form, .cartes-liens { grid-template-columns: 1fr 1fr; }
  .grille-form .large { grid-column: span 2; }
  main { padding: .8rem; }
}
@media (max-width: 460px) {
  .tuiles, .cartes-liens { grid-template-columns: 1fr; }
}

/* Marque GenieBooks : logo, creme, or et marine */
.logo-connexion { display: block; width: 150px; height: auto; margin: 0 auto 1rem; }
.carte-connexion h1 { text-align: center; font-family: Georgia, "Times New Roman", serif; }
.carte-connexion { background: var(--papier); box-shadow: 0 20px 50px rgba(0,0,0,.3), inset 0 6px 0 var(--or); }
.entete { background: var(--papier); color: var(--nuit); border-bottom: 3px solid var(--or); padding: .55rem 1rem; }
.entete .marque { gap: .6em; font-family: Georgia, "Times New Roman", serif; font-size: 1.15rem; }
.entete .marque small { display: block; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; font-size: .62rem; letter-spacing: .28em; text-transform: uppercase; color: var(--or-fonce); font-weight: 700; }
.logo-entete { width: 38px; height: auto; }
.entete .btn-discret { color: var(--nuit); }
.bloc h2, .carte-lien h3 { font-family: Georgia, "Times New Roman", serif; }
.tuile strong { color: var(--nuit); }
.tuile { border-left: 4px solid var(--or); }
.carte-lien { border-top-color: var(--or); }

/* Listes en cartes sur mobile : le montant reste toujours visible */
@media (max-width: 640px) {
  .tableau.liste thead { display: none; }
  .tableau.liste, .tableau.liste tbody { display: block; }
  .tableau.liste tr { display: grid; grid-template-columns: 1fr auto; gap: .15rem .8rem; padding: .75rem 0; border-bottom: 1px solid var(--ligne); }
  .tableau.liste td { border: 0; padding: 0; }
  .tableau.liste td:nth-child(1) { grid-column: 1; grid-row: 1; font-size: .78rem; color: var(--gris); }
  .tableau.liste td:nth-child(5) { grid-column: 2; grid-row: 1; font-weight: 700; color: var(--nuit); font-size: 1rem; }
  .tableau.liste td:nth-child(2) { grid-column: 1; grid-row: 2; font-weight: 600; }
  .tableau.liste td:nth-child(6) { grid-column: 2; grid-row: 2; text-align: right; }
  .tableau.liste td:nth-child(3) { grid-column: 1; grid-row: 3; font-size: .8rem; color: var(--gris); }
  .tableau.liste td:nth-child(4) { grid-column: 2; grid-row: 3; font-size: .8rem; color: var(--gris); text-align: right; }
  .tableau.liste td.vide { grid-column: 1 / -1; }
  .defile { overflow: visible; }
}

/* Redevances et du a l'actionnaire */
.tuile-cle { background: var(--nuit); border-color: var(--nuit); }
.tuile-cle span { color: var(--or-clair); }
.tuile-cle strong, .tuile-cle strong.neg { color: #fff; }
.carte-auteur { border: 1px solid var(--ligne); border-left: 4px solid var(--or); border-radius: 10px; padding: 1rem; margin-bottom: .8rem; }
.carte-auteur h3 { margin: 0 0 .6rem; font-family: Georgia, "Times New Roman", serif; color: var(--nuit); }
.trio { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; margin-bottom: .8rem; }
.trio span { display: block; font-size: .78rem; color: var(--gris); }
.trio strong { font-size: 1.05rem; color: var(--nuit); }
.trio div:last-child strong { color: var(--or-fonce); }
.barre { margin: .2rem 0 .5rem; height: 10px; background: var(--or-clair); border-radius: 99px; overflow: hidden; }
.barre i { display: block; height: 100%; background: var(--or); }
.solde-ligne { display: flex; justify-content: space-between; align-items: baseline; background: var(--or-clair); border-radius: 10px; padding: .7rem 1rem; margin-bottom: .8rem; }
.solde-ligne strong { font-size: 1.3rem; color: var(--nuit); }
#form-rembours { margin-top: 1rem; }

/* Auteurs et seuil */
.choix-auteur { display: flex; gap: .8rem; align-items: flex-end; flex-wrap: wrap; }
.choix-auteur label { flex: 1; min-width: 200px; font-size: .9rem; color: var(--gris); }
textarea { font: inherit; padding: .6rem .7rem; border: 1px solid var(--ligne); border-radius: 8px; background: #fff; color: var(--encre); width: 100%; resize: vertical; }
.grille-form .aide.large { margin: 0; }
.alerte { background: #fff4d6; border: 1px solid var(--or); color: var(--nuit); border-radius: 10px; padding: .7rem 1rem; margin-bottom: .8rem; font-size: .9rem; }
.alerte.rouge { background: #fdecea; border-color: var(--rouge); color: var(--rouge); }
.barre i.orange { background: #d98a1c; }
.barre i.rouge { background: var(--rouge); }

/* Recherche, a faire, outils */
.barre-recherche { position: sticky; top: 0; z-index: 20; background: var(--papier); padding: .6rem 1rem; border-bottom: 1px solid var(--ligne); }
.barre-recherche input { max-width: 1100px; margin: 0 auto; display: block; }
.resultats { max-width: 1100px; margin: .4rem auto 0; background: #fff; border: 1px solid var(--ligne); border-radius: 10px; max-height: 60vh; overflow-y: auto; box-shadow: 0 10px 30px rgba(18,32,58,.15); }
.resultat { display: grid; grid-template-columns: auto 1fr auto; gap: .6rem; align-items: center; width: 100%; text-align: left; background: none; border: 0; border-bottom: 1px solid var(--ligne); padding: .6rem .8rem; font: inherit; cursor: pointer; color: var(--encre); }
.resultat:hover { background: var(--or-clair); }
.res-onglet { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--or-fonce); font-weight: 700; }
.res-texte { font-size: .9rem; overflow: hidden; text-overflow: ellipsis; }
.titre-outils { display: flex; justify-content: space-between; align-items: center; gap: .6rem; }
.titre-outils h2 { margin-bottom: .8rem; }
.liste-afaire { list-style: none; margin: 0; padding: 0; }
.liste-afaire li { border-bottom: 1px solid var(--ligne); }
.liste-afaire li:last-child { border-bottom: 0; }
.liste-afaire button { background: none; border: 0; font: inherit; color: var(--nuit); text-align: left; width: 100%; padding: .55rem 0 .55rem 1.4rem; cursor: pointer; position: relative; }
.liste-afaire button::before { content: ""; position: absolute; left: .2rem; top: .95rem; width: .55rem; height: .55rem; border-radius: 50%; background: var(--or); }
.bandeau-ligne { background: var(--nuit); color: #fff; border-radius: 12px; padding: .8rem 1rem; margin-bottom: 1rem; }
.bandeau-ligne strong { color: var(--or); font-family: Georgia, serif; font-size: 1.15rem; margin-right: .4rem; }
.bandeau-ligne span { color: #cfd6e4; font-size: .85rem; }

/* Deux marques : GenieBooks et GenieCards, logo et nom, cliquables */
.entete .marque { gap: .4rem; flex-wrap: wrap; }
.marque-btn { display: flex; align-items: center; gap: .5rem; background: none; border: 0; border-bottom: 3px solid transparent; padding: .2rem .4rem .25rem; cursor: pointer; font: inherit; color: inherit; text-align: left; opacity: .5; transition: opacity .15s, border-color .15s; }
.marque-btn.actif { opacity: 1; border-bottom-color: var(--or); }
.marque-btn:hover { opacity: 1; }
.marque-txt { font-family: Georgia, "Times New Roman", serif; font-size: 1.1rem; font-weight: 700; line-height: 1.1; }
.marque-txt small { display: block; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; font-size: .58rem; letter-spacing: .26em; text-transform: uppercase; color: var(--or-fonce); font-weight: 700; }
.logo-gc { width: auto; height: 26px; display: block; }
body.espace-gc .entete { background: var(--nuit); color: #fff; }
body.espace-gc .entete .marque-txt small { color: var(--or); }
body.espace-gc .entete .btn-discret, body.espace-gc .entete .lien-langue { color: #fff; }
body.espace-gc .barre-recherche { display: none; }
@media (max-width: 520px) {
  .entete { flex-wrap: wrap; row-gap: .3rem; }
  .entete-droite { margin-left: auto; }
  .marque-txt { font-size: .98rem; }
  .entete { padding: .45rem .6rem; }
  .entete-droite { gap: .5rem; }
  .entete .btn-discret { padding: .4rem .7rem; font-size: .9rem; }
}

/* ===== Habillage 2026-11 : plus vivant, meme palette marine / or / creme ===== */
:root {
  --or-vif: #e0b955;
  --or-degrade: linear-gradient(135deg, #e7c46a 0%, #c9a74d 45%, #a9862f 100%);
  --nuit-degrade: linear-gradient(135deg, #1b2d4f 0%, #12203a 60%, #0c1628 100%);
  --ombre: 0 1px 2px rgba(18,32,58,.06), 0 8px 24px rgba(18,32,58,.08);
  --ombre-forte: 0 2px 4px rgba(18,32,58,.1), 0 14px 34px rgba(18,32,58,.16);
  --vert-doux: #1f7a52;
}
body { background: radial-gradient(1200px 500px at 100% -10%, rgba(201,167,77,.16), transparent 60%), radial-gradient(900px 400px at -10% 10%, rgba(27,45,79,.07), transparent 60%), var(--papier); background-attachment: fixed; }

/* Connexion : ciel etoile */
.connexion { background:
  radial-gradient(2px 2px at 12% 18%, rgba(231,196,106,.9), transparent 60%),
  radial-gradient(1.5px 1.5px at 78% 12%, rgba(255,255,255,.8), transparent 60%),
  radial-gradient(2px 2px at 64% 72%, rgba(231,196,106,.7), transparent 60%),
  radial-gradient(1.5px 1.5px at 28% 84%, rgba(255,255,255,.6), transparent 60%),
  radial-gradient(1.5px 1.5px at 90% 58%, rgba(231,196,106,.6), transparent 60%),
  radial-gradient(800px 500px at 50% 0%, rgba(201,167,77,.22), transparent 60%),
  var(--nuit-degrade); }
.carte-connexion { border-radius: 20px; box-shadow: 0 30px 80px rgba(0,0,0,.45), inset 0 6px 0 var(--or); }

/* En-tete et onglets */
.entete { box-shadow: 0 1px 0 rgba(201,167,77,.35); }
.onglets { background: var(--nuit-degrade); padding: .45rem .6rem; gap: .3rem; scrollbar-width: none; }
.onglets::-webkit-scrollbar { display: none; }
.onglets button { border: 0; border-radius: 999px; padding: .55rem 1rem; color: #c9d3e6; font-weight: 600; transition: background .15s, color .15s; }
.onglets button:hover { background: rgba(255,255,255,.08); color: #fff; }
.onglets button.actif { background: var(--or-degrade); color: var(--nuit); box-shadow: 0 4px 14px rgba(201,167,77,.35); }

/* Blocs */
.bloc { border: 1px solid rgba(201,167,77,.22); border-radius: 18px; box-shadow: var(--ombre); padding: 1.3rem 1.35rem; }
.bloc h2 { font-size: 1.15rem; position: relative; padding-bottom: .45rem; }
.bloc h2::after { content: ""; position: absolute; left: 0; bottom: 0; width: 38px; height: 3px; border-radius: 3px; background: var(--or-degrade); }
.titre-outils h2 { margin-bottom: 1rem; }

/* Tuiles */
.tuiles { gap: .9rem; }
.tuile { position: relative; overflow: hidden; border: 1px solid rgba(201,167,77,.22); border-left: 0; border-radius: 18px; padding: 1.05rem 1.15rem 1.1rem; background: linear-gradient(160deg, #ffffff 0%, #fdf9ef 100%); box-shadow: var(--ombre); transition: transform .15s, box-shadow .15s; }
.tuile::before { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 4px; background: var(--or-degrade); }
.tuile:hover { transform: translateY(-2px); box-shadow: var(--ombre-forte); }
.tuile span { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; font-weight: 600; color: #7a7f8c; }
.tuile strong { font-size: 1.55rem; letter-spacing: -.01em; margin-top: .35rem; font-variant-numeric: tabular-nums; }
.tuile-cle { background: var(--nuit-degrade); border-color: transparent; box-shadow: 0 10px 30px rgba(18,32,58,.35); }
.tuile-cle::before { height: 100%; width: 100%; background: radial-gradient(300px 120px at 100% 0%, rgba(231,196,106,.35), transparent 70%); }
.tuile-cle span { color: var(--or-vif); position: relative; }
.tuile-cle strong, .tuile-cle strong.neg { color: #fff; position: relative; }

/* Boutons */
.btn { border-radius: 12px; transition: transform .12s, box-shadow .12s, filter .12s; }
.btn-or { background: var(--or-degrade); color: var(--nuit); box-shadow: 0 6px 18px rgba(201,167,77,.35); }
.btn-or:hover { background: var(--or-degrade); filter: brightness(1.06); transform: translateY(-1px); }
.btn-discret { border-color: rgba(18,32,58,.25); }
.btn-discret:hover { border-color: var(--or); color: var(--or-fonce); }
input, select, textarea { border-radius: 12px; border-color: #e6dfcd; background: #fffdf8; }
input:focus, select:focus, textarea:focus { outline: 0; border-color: var(--or); box-shadow: 0 0 0 4px rgba(201,167,77,.18); }

/* A faire */
#bloc-afaire { background: linear-gradient(160deg, #fffaf0 0%, #fff 70%); }
.liste-afaire button { padding: .7rem .2rem .7rem 1.8rem; font-weight: 500; border-radius: 10px; transition: background .12s; }
.liste-afaire button:hover { background: rgba(201,167,77,.12); }
.liste-afaire button::before { left: .45rem; top: 1.05rem; width: .6rem; height: .6rem; box-shadow: 0 0 0 4px rgba(201,167,77,.2); }
.liste-afaire button::after { content: "›"; position: absolute; right: .5rem; top: .55rem; color: var(--or-fonce); font-size: 1.2rem; }

/* Barres et cartes */
.barre { height: 12px; background: #f1e7cc; }
.barre i { background: var(--or-degrade); border-radius: 99px; }
.carte-auteur { border-radius: 16px; border-left-width: 5px; background: linear-gradient(160deg, #fff 0%, #fdf9ef 100%); }
.trio div:last-child strong { color: var(--or-fonce); }
.solde-ligne { background: var(--nuit-degrade); color: #fff; border-radius: 14px; }
.solde-ligne span { color: var(--or-vif); }
.solde-ligne strong { color: #fff; }
.carte-lien { border-radius: 18px; border-top: 0; box-shadow: var(--ombre); position: relative; overflow: hidden; }
.carte-lien::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: var(--or-degrade); }
.bandeau-ligne { background: var(--nuit-degrade); border-radius: 18px; box-shadow: 0 10px 30px rgba(18,32,58,.3); }

/* Listes */
.tableau th { text-transform: uppercase; letter-spacing: .05em; font-size: .72rem; }
.tableau tbody tr { transition: background .12s; }
.tableau tbody tr:hover { background: rgba(201,167,77,.07); }
.tableau .num { font-variant-numeric: tabular-nums; }
.barre-recherche { background: rgba(250,246,236,.92); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.barre-recherche input { padding-left: 2.4rem; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%239c7f2e' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") no-repeat .85rem center; }
.pied { color: #9a9486; }

@media (max-width: 460px) {
  .tuiles { grid-template-columns: 1fr 1fr; gap: .65rem; }
  .tuile { padding: .9rem .9rem 1rem; }
  .tuile strong { font-size: 1.2rem; }
  .tuile span { font-size: .68rem; }
}
.liste-afaire button { padding-right: 2rem; }
.solde-ligne { flex-wrap: wrap; gap: .3rem .8rem; }
.tableau td:first-child { overflow-wrap: anywhere; }

/* ===== Habillage 2 : tableau de bord vivant ===== */
.hero { position: relative; overflow: hidden; border-radius: 22px; padding: 1.3rem 1.3rem 1rem; margin-bottom: 1.2rem; color: #fff;
  background:
    radial-gradient(2px 2px at 8% 20%, rgba(240,210,126,.9), transparent 60%),
    radial-gradient(1.5px 1.5px at 30% 70%, rgba(255,255,255,.7), transparent 60%),
    radial-gradient(2px 2px at 88% 18%, rgba(240,210,126,.8), transparent 60%),
    radial-gradient(1.5px 1.5px at 70% 40%, rgba(255,255,255,.5), transparent 60%),
    radial-gradient(500px 220px at 100% 0%, rgba(201,167,77,.35), transparent 65%),
    radial-gradient(400px 200px at 0% 100%, rgba(31,122,82,.18), transparent 65%),
    linear-gradient(135deg, #1e3460 0%, #12203a 55%, #0b1424 100%);
  box-shadow: 0 18px 40px rgba(18,32,58,.35); }
.hero-haut { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; flex-wrap: wrap; }
.hero-salut { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: 1.45rem; font-weight: 700; }
.hero-exercice { margin: .15rem 0 0; font-size: .82rem; color: rgba(255,255,255,.65); }
.hero-exercice strong { color: rgba(255,255,255,.85); font-weight: 600; }
.hero-chiffre { text-align: right; }
.hero-chiffre span, .hero-trio span { display: block; font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: #f0d27e; font-weight: 700; }
.hero-chiffre strong { display: block; font-size: 2rem; line-height: 1.1; font-variant-numeric: tabular-nums;
  background: linear-gradient(135deg, #fff3cf 0%, #f0d27e 40%, #c9a74d 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-chiffre strong.neg { background: none; color: #ffb3a6; }
.hero-trio { display: grid; grid-template-columns: repeat(3, 1fr); gap: .6rem; margin: 1rem 0 .4rem; }
.hero-trio div { background: rgba(255,255,255,.07); border: 1px solid rgba(240,210,126,.18); border-radius: 14px; padding: .6rem .7rem; }
.hero-trio span { font-size: .62rem; color: rgba(255,255,255,.65); }
.hero-trio strong { display: block; font-size: 1.1rem; margin-top: .15rem; color: #fff; font-variant-numeric: tabular-nums; }
.hero-trio strong.neg { color: #ffb3a6; }
.hero-graphe svg { width: 100%; height: 130px; display: block; margin-top: .4rem; }
.hero-legende { display: flex; align-items: center; gap: .4rem; font-size: .72rem; color: rgba(255,255,255,.65); }
.hero-legende i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.hero-legende i.l-dep { margin-left: .8rem; background: rgba(255,255,255,.35); }
.hero-legende i.l-rev { background: linear-gradient(#f0d27e, #b8952f); }
@media (max-width: 460px) {
  .hero-salut { font-size: 1.2rem; }
  .hero-chiffre { text-align: left; }
  .hero-chiffre strong { font-size: 1.7rem; }
  .hero-trio strong { font-size: .95rem; }
}

/* Icones des tuiles */
.tuile { padding-right: 3.2rem; }
.tuile::after { content: ""; position: absolute; top: .9rem; right: .9rem; width: 34px; height: 34px; border-radius: 11px; background-repeat: no-repeat; background-position: center; background-size: 18px; }
.tuile[data-icone="rev"]::after { background-color: #e3f3ea; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f7a52' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 19V5'/%3E%3Cpath d='m5 12 7-7 7 7'/%3E%3C/svg%3E"); }
.tuile[data-icone="dep"]::after { background-color: #fbe9e5; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c2553f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 5v14'/%3E%3Cpath d='m19 12-7 7-7-7'/%3E%3C/svg%3E"); }
.tuile[data-icone="pro"]::after { background-color: #f6ecd2; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239c7f2e' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 17l6-6 4 4 8-8'/%3E%3Cpath d='M14 7h7v7'/%3E%3C/svg%3E"); }
.tuile[data-icone="red"]::after { background-color: #e6ebf3; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2312203a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 19.5V5a2 2 0 0 1 2-2h12v16H6.5a2.5 2.5 0 0 0 0 5H18'/%3E%3C/svg%3E"); }
.tuile[data-icone="cle"]::after { background-color: #f0d27e; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2312203a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 2l3 6 6 .9-4.5 4.3 1 6.3L12 16.6 6.5 19.5l1-6.3L3 8.9 9 8z'/%3E%3C/svg%3E"); }
.tuile[data-icone="act"]::after { background-color: #f6ecd2; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239c7f2e' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='8' r='4'/%3E%3Cpath d='M4 21a8 8 0 0 1 16 0'/%3E%3C/svg%3E"); }
.tuile[data-icone="rev"] strong { color: #1f7a52; }
.tuile[data-icone="dep"] strong { color: #b3452f; }
.tuile-cle::after { box-shadow: 0 0 0 4px rgba(240,210,126,.18); }

/* Repartitions en barres */
.rep-nom { position: relative; padding-bottom: 1.05rem !important; }
.rep-barre { position: absolute; left: .6rem; bottom: .45rem; height: 6px; max-width: calc(100% - .6rem); border-radius: 99px; background: linear-gradient(90deg, #e7c46a, #b8952f); }
#tb-dep-cat .rep-barre { background: linear-gradient(90deg, #e9a08f, #b3452f); }
@media (max-width: 460px) { .tuile { padding-right: .9rem; padding-top: 3.1rem; } .tuile::after { top: .7rem; left: .9rem; right: auto; width: 30px; height: 30px; } }

.liste-afaire li.cochable { display: flex; align-items: center; gap: .4rem; }
.liste-afaire li.cochable > button:first-child { flex: 1; }
.btn-fait { flex: none; background: #fff; border: 1px solid rgba(31,122,82,.35); color: #1f7a52; border-radius: 999px; padding: .3rem .7rem; font: inherit; font-size: .78rem; font-weight: 700; cursor: pointer; white-space: nowrap; }
.btn-fait:hover { background: #e3f3ea; }

/* ===== A faire : cartes par categorie ===== */
.afaire-entete { display: flex; align-items: center; gap: .6rem; }
.afaire-entete h2 { margin-bottom: .8rem; }
.afaire-nombre { margin-bottom: .8rem; min-width: 1.7rem; height: 1.7rem; padding: 0 .45rem; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center;
  background: var(--or-degrade); color: var(--nuit); font-weight: 800; font-size: .85rem; box-shadow: 0 4px 12px rgba(201,167,77,.4); }
.liste-afaire { display: grid; grid-template-columns: 1fr; gap: .6rem; }
@media (min-width: 760px) { .liste-afaire { grid-template-columns: 1fr 1fr; } }
.liste-afaire li { border: 0 !important; }
li.afaire { display: flex; align-items: center; gap: .5rem; background: #fff; border-radius: 16px; padding: .35rem .5rem .35rem .35rem;
  border: 1px solid #efe6cf !important; box-shadow: 0 1px 2px rgba(18,32,58,.05); position: relative; overflow: hidden; transition: transform .12s, box-shadow .12s; }
li.afaire::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--af-accent, var(--or)); }
li.afaire:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgba(18,32,58,.09); }
.liste-afaire button.afaire-corps { all: unset; box-sizing: border-box; flex: 1; display: flex; align-items: center; gap: .75rem; padding: .45rem .3rem .45rem .5rem; cursor: pointer; min-width: 0; }
.liste-afaire button.afaire-corps::before, .liste-afaire button.afaire-corps::after { content: none !important; }
.afaire-icone { flex: none; width: 40px; height: 40px; border-radius: 13px; background-color: var(--af-fond); background-repeat: no-repeat; background-position: center; background-size: 21px; }
.afaire-texte { display: flex; flex-direction: column; min-width: 0; }
.afaire-texte strong { font-size: .95rem; color: var(--nuit); font-weight: 700; line-height: 1.25; }
.afaire-texte small { font-size: .8rem; color: #6b7280; line-height: 1.3; margin-top: .1rem; }
.afaire-fleche { margin-left: auto; color: var(--af-accent, var(--or-fonce)); font-size: 1.4rem; font-weight: 700; padding: 0 .3rem; }
li.afaire .btn-fait { margin-right: .2rem; }
.afaire-vide { list-style: none; text-align: center; padding: 1rem; color: #1f7a52; font-weight: 600; background: #e3f3ea; border-radius: 14px; }
li.af-argent { --af-fond: #fbf1d3; --af-accent: #c9a74d; }
li.af-argent .afaire-icone { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239c7f2e' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M15 9.5c-.6-1-1.7-1.5-3-1.5-1.7 0-3 .9-3 2.2 0 3 6 1.6 6 4.6 0 1.3-1.3 2.2-3 2.2-1.4 0-2.6-.6-3.1-1.6'/%3E%3Cpath d='M12 6v2M12 16v2'/%3E%3C/svg%3E"); }
li.af-fete { --af-fond: #fff1c9; --af-accent: #e7b93e; }
li.af-fete .afaire-icone { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b8862a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 20l4-12 8 8-12 4z'/%3E%3Cpath d='M13 4l1 2M18 7l2-1M16 11l3 1M10 3v2'/%3E%3C/svg%3E"); }
li.af-legal { --af-fond: #e6ebf3; --af-accent: #1b2d4f; }
li.af-legal .afaire-icone { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2312203a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 21h18M5 21V10M19 21V10M9 21V10M15 21V10M2 10l10-6 10 6z'/%3E%3C/svg%3E"); }
li.af-fiscal { --af-fond: #e3eefb; --af-accent: #3b7cc4; }
li.af-fiscal .afaire-icone { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231b4f8a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M3 12h18M12 3c2.5 2.7 3.7 5.7 3.7 9s-1.2 6.3-3.7 9c-2.5-2.7-3.7-5.7-3.7-9S9.5 5.7 12 3z'/%3E%3C/svg%3E"); }
li.af-doc { --af-fond: #e6ebf3; --af-accent: #1b2d4f; }
li.af-doc .afaire-icone { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2312203a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 3H6a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V8z'/%3E%3Cpath d='M14 3v5h5M9 13h6M9 17h4'/%3E%3C/svg%3E"); }
li.af-colis { --af-fond: #fbe9e5; --af-accent: #d06a52; }
li.af-colis .afaire-icone { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b3452f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 8l-9-5-9 5 9 5 9-5z'/%3E%3Cpath d='M3 8v8l9 5 9-5V8M12 13v8'/%3E%3C/svg%3E"); }
li.af-recu { --af-fond: #fdeed8; --af-accent: #d98a1c; }
li.af-recu .afaire-icone { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a8650f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 3h12v18l-3-2-3 2-3-2-3 2z'/%3E%3Cpath d='M9 8h6M9 12h6'/%3E%3C/svg%3E"); }
li.af-classer { --af-fond: #eceef1; --af-accent: #8a93a1; }
li.af-classer .afaire-icone { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235b6472' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6h16M4 12h10M4 18h6'/%3E%3C/svg%3E"); }
li.af-lien { --af-fond: #e3f3ea; --af-accent: #2f9b6b; }
li.af-lien .afaire-icone { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231f7a52' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 7V3M15 7V3M7 7h10v4a5 5 0 0 1-10 0z'/%3E%3Cpath d='M12 16v5'/%3E%3C/svg%3E"); }
li.af-fete { background: linear-gradient(120deg, #fffaf0, #fff 60%); }
li.af-argent .afaire-texte small { color: var(--or-fonce); font-weight: 700; font-size: .9rem; }
.liste-afaire button.btn-fait { all: unset; box-sizing: border-box; flex: none; margin-right: .3rem; background: #fff; border: 1.5px solid rgba(31,122,82,.4); color: #1f7a52; border-radius: 999px; padding: .38rem .75rem; font-size: .8rem; font-weight: 700; cursor: pointer; white-space: nowrap; }
.liste-afaire button.btn-fait:hover { background: #e3f3ea; }
.liste-afaire button.btn-fait::before, .liste-afaire button.btn-fait::after { content: none !important; }

/* Graphe du bandeau, net */
.hero-graphe svg.graphe-net { width: 100%; height: auto; max-height: 270px; margin-top: .7rem; }
.hero-legende i.l-dep { background: linear-gradient(#f3b3a3, #c2553f); }
.hero-trio div { backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }

/* ===== Commandes a expedier ===== */
.pastille { display: inline-flex; min-width: 1.25rem; height: 1.25rem; padding: 0 .35rem; border-radius: 999px; background: #c2553f; color: #fff; font-size: .72rem; font-weight: 800; align-items: center; justify-content: center; vertical-align: 1px; }
.filtres { display: flex; gap: .4rem; margin-bottom: 1rem; }
.filtre { border: 1px solid #e6dfcd; background: #fffdf8; color: var(--nuit); border-radius: 999px; padding: .4rem .9rem; font: inherit; font-size: .85rem; font-weight: 600; cursor: pointer; }
.filtre.actif { background: var(--nuit-degrade); color: #f0d27e; border-color: transparent; }
.cmd-form { background: #fffaf0; border: 1px dashed var(--or); border-radius: 16px; padding: 1rem; margin-bottom: 1rem; }
.liste-cmd { display: grid; gap: .9rem; }
.cmd { border-radius: 18px; border: 1px solid #efe6cf; background: #fff; box-shadow: var(--ombre); padding: 1rem 1.1rem; border-left: 5px solid var(--or); }
.cmd-a_commander { border-left-color: #d98a1c; }
.cmd-commandee { border-left-color: #3b7cc4; }
.cmd-expediee { border-left-color: #1f7a52; opacity: .9; }
.cmd-annulee { border-left-color: #9aa0a6; opacity: .6; }
.cmd-urgent { border-left-color: #c2553f; background: linear-gradient(160deg, #fff4f1, #fff 60%); box-shadow: 0 0 0 2px rgba(194,85,63,.25), var(--ombre); }
.cmd-tete { display: flex; justify-content: space-between; align-items: flex-start; gap: .6rem; margin-bottom: .6rem; }
.cmd-tete strong { font-size: 1.1rem; color: var(--nuit); display: block; }
.cmd-tete small { color: #7a7f8c; font-size: .8rem; }
.cmd-statut { font-size: .72rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; padding: .3rem .6rem; border-radius: 999px; background: #fdeed8; color: #a8650f; white-space: nowrap; }
.cmd-commandee .cmd-statut { background: #e3eefb; color: #1b4f8a; }
.cmd-expediee .cmd-statut { background: #e3f3ea; color: #1f7a52; }
.cmd-urgent .cmd-statut { background: #c2553f; color: #fff; }
.cmd-livre { background: #fbf7ec; border-radius: 12px; padding: .55rem .7rem; margin-bottom: .5rem; font-weight: 600; color: var(--nuit); }
.cmd-livre > span { display: block; margin-bottom: .3rem; }
.cmd-adresse { border-top: 1px solid #f1ead8; padding-top: .5rem; margin: .4rem 0 .6rem; display: grid; gap: .15rem; }
.ligne-copie { display: grid; grid-template-columns: 7.5rem 1fr auto; align-items: center; gap: .5rem; padding: .25rem 0; border-bottom: 1px dashed #f1ead8; }
.lc-lib { font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: #8a8f9a; font-weight: 700; }
.lc-val { font-size: .92rem; color: var(--encre); overflow-wrap: anywhere; }
.btn-copier { border: 1px solid rgba(201,167,77,.5); background: #fffdf8; color: var(--or-fonce); border-radius: 999px; padding: .28rem .7rem; font: inherit; font-size: .78rem; font-weight: 700; cursor: pointer; white-space: nowrap; }
.btn-copier:hover { background: #fbf1d3; }
.btn-copier.copie { background: #e3f3ea; border-color: rgba(31,122,82,.4); color: #1f7a52; }
.cmd-adresse > .btn { justify-self: start; margin-top: .4rem; }
.cmd-actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.cmd-actions input { flex: 1; min-width: 180px; }
.cmd-actions .aide { margin: 0; flex-basis: 100%; }
.lien-discret { background: none; border: 0; color: #9a9486; font: inherit; font-size: .8rem; text-decoration: underline; cursor: pointer; margin-left: auto; }
li.af-urgent { --af-fond: #fde7e2; --af-accent: #c2553f; background: linear-gradient(120deg, #fff4f1, #fff 60%); }
li.af-urgent .afaire-texte strong { color: #a5382a; }
li.af-urgent .afaire-icone { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c2553f' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3l10 18H2z'/%3E%3Cpath d='M12 10v5M12 18h.01'/%3E%3C/svg%3E"); }
@media (max-width: 460px) { .ligne-copie { grid-template-columns: 5.6rem 1fr auto; } }
.cmd-livre .lc-val { white-space: nowrap; }
.fichiers-ebook { margin-top: .7rem; padding-top: .7rem; border-top: 1px dashed rgba(201,167,77,.4); }
.ligne-fichier { display: flex; align-items: center; justify-content: space-between; gap: .6rem; margin-top: .45rem; }
.pastille-fichier { font-size: .8rem; font-weight: 600; padding: .2rem .65rem; border-radius: 999px; }
.pastille-fichier.ok { background: #e2f4e7; color: #1f6b3a; }
.pastille-fichier.manque { background: #fdeceb; color: #a1362c; }
.ligne-fichier label.btn { cursor: pointer; }
.outils-droite { display: inline-flex; gap: .4rem; flex-wrap: wrap; justify-content: flex-end; }
.liste-avis { display: grid; gap: .7rem; }
.carte-avis { border: 1px solid rgba(201,167,77,.3); border-radius: 16px; padding: .8rem 1rem; background: #fffdf8; }
.carte-avis.statut-en_attente { border-left: 4px solid var(--or); }
.carte-avis.statut-masque { opacity: .6; }
.avis-haut { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; }
.etoiles-fixes { color: var(--or); letter-spacing: .08em; font-size: 1.05rem; }
.pastille-avis { margin-left: auto; font-size: .75rem; font-weight: 600; padding: .15rem .6rem; border-radius: 999px; background: #f3ecd9; color: var(--or-fonce); }
.pastille-avis.approuve { background: #e2f4e7; color: #1f6b3a; }
.pastille-avis.masque { background: #eee; color: #777; }
.avis-texte { margin: .5rem 0; white-space: pre-wrap; color: var(--nuit); }
.avis-actions { display: flex; gap: .4rem; flex-wrap: wrap; }
.avis-moyenne { color: var(--or-fonce); }
