/* QG Nantais · l'arrière-salle : charbon, fumée, laiton, papier vieilli. Le rouge ne sert qu'aux tampons. */
:root {
  --charbon: #100e0c;
  --fumee: #1c1915;
  --fumee-2: #28231d;
  --cuir: #3a2e22;
  --laiton: #c9a24a;
  --laiton-clair: #e2c27a;
  --papier: #ece2cc;
  --papier-2: #ddd0b3;
  --creme: #f4ecdb;
  --sepia: #8a7a63;
  --gris: #a69a86;
  --ligne: rgba(201, 162, 74, .22);
  --sang: #8e2a22;
  --ok: #6f9a5b;
  --err: #d0614f;
  --display: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --machine: 'Inter', system-ui, -apple-system, sans-serif;
  --texte: 'Inter', system-ui, -apple-system, sans-serif;
  --r: 18px;
  --r-s: 12px;
  --max: 1180px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--charbon); color: var(--creme); font: 16px/1.65 var(--texte); }
/* Grain de film, très léger */
body::after { content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 100; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.02; letter-spacing: -.01em; margin: 0 0 .45em; }
h1 { font-size: clamp(2.6rem, 6.4vw, 5rem); }
h2 { font-size: clamp(1.9rem, 3.8vw, 2.9rem); }
h3 { font-size: 1.45rem; }
h1 em, h2 em { font-style: italic; color: var(--laiton); font-weight: 600; }
p { margin: 0 0 1em; }
.surtitre { font: 600 .74rem var(--machine); letter-spacing: .16em; text-transform: uppercase; color: var(--laiton); margin-bottom: 1rem; }
.surtitre::before { content: ''; display: inline-block; width: 22px; height: 1px; background: currentColor; vertical-align: middle; margin-right: .6em; }
:focus-visible { outline: 2px solid var(--laiton-clair); outline-offset: 3px; }
::selection { background: var(--laiton); color: var(--charbon); }

/* Boutons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4em; padding: .82em 1.5em; border-radius: 999px; border: 1px solid var(--laiton); font: 600 .9rem var(--texte); letter-spacing: .04em; text-decoration: none; cursor: pointer; transition: background .2s, color .2s, box-shadow .2s; background: none; color: var(--laiton-clair); }
.btn:hover { background: rgba(201, 162, 74, .12); }
.btn-laiton { background: var(--laiton); color: var(--charbon); }
.btn-laiton:hover { background: var(--laiton-clair); }
.btn-noir { background: var(--charbon); color: var(--laiton-clair); border-color: var(--laiton); }
.btn-contour { border-color: var(--creme); color: var(--creme); }
.btn-plein { width: 100%; }
.lien-fleche { font: .9rem var(--machine); text-decoration: none; color: var(--laiton-clair); border-bottom: 1px solid var(--laiton); }
.lien-fleche::after { content: ' →'; }

/* Barre */
.barre { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .55rem clamp(16px, 4vw, 40px); background: rgba(16, 14, 12, .92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--ligne); }
.barre-logo img { width: 82px; height: auto; }
.barre nav { display: flex; align-items: center; gap: clamp(.8rem, 2vw, 1.9rem); }
.barre nav a:not(.btn) { text-decoration: none; font-weight: 500; font-size: .93rem; color: #d9cfbb; padding: .3em 0; border-bottom: 1px solid transparent; }
.barre nav a:not(.btn):hover { color: var(--creme); }
.barre nav a[aria-current] { color: var(--laiton-clair); border-color: var(--laiton); }
.barre nav .btn { padding: .55em 1.1em; font-size: .85rem; }
.burger { display: none; }
@media (max-width: 820px) {
  .burger { display: block; width: 44px; height: 44px; position: relative; cursor: pointer; }
  .burger span, .burger span::before, .burger span::after { position: absolute; left: 10px; width: 24px; height: 2px; background: var(--laiton); content: ''; }
  .burger span { top: 21px; } .burger span::before { top: -7px; left: 0; } .burger span::after { top: 7px; left: 0; }
  .barre nav { display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column; align-items: stretch; padding: 1rem 16px 1.4rem; background: var(--charbon); border-bottom: 1px solid var(--ligne); }
  #menu:checked ~ nav { display: flex; }
}

/* Hero : la porte du fond */
.hero { position: relative; overflow: hidden; padding: clamp(4.5rem, 11vw, 9rem) clamp(16px, 4vw, 40px) clamp(5.5rem, 11vw, 9rem);
  background: radial-gradient(ellipse 60% 70% at 72% 45%, rgba(201, 162, 74, .16), transparent 70%), linear-gradient(180deg, #17130f, var(--charbon)); }
.hero::before { content: ''; position: absolute; inset: -20% -30% auto auto; width: 80%; aspect-ratio: 1; background: url(/assets/Tache-2-blanc.webp) center/contain no-repeat; opacity: .05; }
.hero-in { position: relative; max-width: var(--max); margin: 0 auto; }
.hero h1 { max-width: 14ch; }
.hero-texte { max-width: 33rem; font-size: 1.1rem; color: #cfc4ae; margin: 1.5rem 0 2.2rem; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .8rem; }
.hero-tampon { position: absolute; right: clamp(-40px, 3vw, 80px); top: 50%; width: clamp(200px, 30vw, 430px); transform: translateY(-50%) rotate(-9deg); opacity: .9; filter: sepia(.5) brightness(.95); }
@media (max-width: 900px) { .hero-tampon { position: static; transform: rotate(-9deg); width: 210px; margin: 2.8rem 0 0 auto; } }

/* Chiffres : le registre */
.chiffres { display: grid; grid-template-columns: repeat(4, 1fr); max-width: var(--max); margin: -3rem auto 0; position: relative; background: var(--papier); color: var(--charbon); border-radius: 24px; overflow: hidden; box-shadow: 0 30px 60px -30px #000; }
.chiffre { padding: 1.7rem 1.5rem; border-right: 1px dashed rgba(16, 14, 12, .25); }
.chiffre:last-child { border: 0; }
.chiffre strong { display: block; font: 700 2.2rem/1 var(--display); }
.chiffre span { font: .82rem var(--machine); color: #5b4f3e; }
@media (max-width: 820px) {
  .chiffres { grid-template-columns: 1fr 1fr; margin: -2.4rem 16px 0; }
  .chiffre:nth-child(2) { border-right: 0; }
  .chiffre:nth-child(-n+2) { border-bottom: 1px dashed rgba(16, 14, 12, .25); }
}

/* Blocs */
.bloc { padding: clamp(4rem, 9vw, 7rem) clamp(16px, 4vw, 40px); }
.bloc-serre { padding-top: 1rem; }
.bloc-in { max-width: var(--max); margin: 0 auto; }
.bloc-encre { background: var(--fumee); border-block: 1px solid var(--ligne); }
.bloc-tete { display: flex; justify-content: space-between; align-items: end; gap: 1rem; flex-wrap: wrap; margin-bottom: 2.4rem; }
.deux-col { display: grid; grid-template-columns: 1fr 1.3fr; gap: clamp(2rem, 6vw, 5rem); align-items: start; }
@media (max-width: 820px) { .deux-col { grid-template-columns: 1fr; } }

.regles { list-style: none; counter-reset: r; margin: 0; padding: 0; }
.regles li { counter-increment: r; position: relative; padding: 1.3rem 0 1.3rem 4.4rem; border-top: 1px solid var(--ligne); font-size: 1.08rem; color: #d9cfbb; }
.regles li strong { color: var(--creme); }
.regles li::before { content: counter(r, upper-roman) '.'; position: absolute; left: 0; top: 1.05rem; font: italic 600 1.9rem var(--display); color: var(--laiton); }
.liste-regles { margin: 0; padding: 0; list-style: none; }
.liste-regles li { padding: 1.05rem 0 1.05rem 2rem; border-top: 1px solid var(--ligne); position: relative; color: #d9cfbb; }
.liste-regles li strong { color: var(--creme); }
.liste-regles li::before { content: '§'; position: absolute; left: 0; top: .95rem; font: 600 1.2rem var(--display); color: var(--laiton); }

.timeline { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 1.6rem; margin-top: 2.6rem; }
.timeline div { background: var(--charbon); border: 1px solid var(--ligne); border-radius: var(--r); padding: 1.3rem 1.4rem; }
.timeline time { font: italic 600 2rem var(--display); color: var(--laiton-clair); }
.timeline p { color: #c7bca6; margin-top: .35rem; }

.mosaique { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 14px; }
.mosaique a { display: block; transition: transform .25s; }
.mosaique a:hover { transform: scale(1.06); }
.mosaique .avatar { border-radius: 50%; box-shadow: 0 0 0 1px var(--laiton); filter: grayscale(1) sepia(.45) contrast(1.05) brightness(.9); transition: filter .3s; }
.mosaique a:hover .avatar { filter: none; }

.bandeau { padding: clamp(2.5rem, 6vw, 4rem) clamp(16px, 4vw, 40px); }
.bandeau-in { background: linear-gradient(110deg, var(--cuir), #2a2119); border: 1px solid var(--ligne); border-radius: 28px; padding: clamp(2rem, 5vw, 3.4rem); }
.bandeau-in { max-width: var(--max); margin-inline: auto; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; }
.bandeau h2 { margin: 0; max-width: 20ch; }

/* Avatars */
.avatar { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; border-radius: var(--r); background: var(--fumee-2); }
.avatar-vide { display: grid; place-items: center; font: italic 600 2.2rem var(--display); color: var(--laiton); }
.avatar-s { width: 42px; height: 42px; min-width: 42px; max-width: none; aspect-ratio: 1; border-radius: 50%; font-size: 1rem; flex: none; box-shadow: 0 0 0 1px var(--laiton); }

/* La famille : des dossiers */
.page-tete { padding: clamp(3.5rem, 8vw, 5.5rem) clamp(16px, 4vw, 40px) 1.8rem; }
.page-tete .intro { max-width: 46rem; font-size: 1.1rem; color: #cfc4ae; }
.page-tete .intro a { color: var(--laiton-clair); }
.filtre { width: min(420px, 100%); padding: .85em 1.3em; border: 1px solid var(--laiton); border-radius: 999px; font: .95rem var(--texte); background: var(--fumee); color: var(--creme); margin-top: .8rem; }
.filtre::placeholder { color: var(--sepia); }
.grille-membres { display: grid; grid-template-columns: repeat(auto-fill, minmax(232px, 1fr)); gap: 1.8rem 1.5rem; }
.carte { position: relative; background: var(--papier); color: var(--charbon); border-radius: var(--r); padding: 1.4rem 1.2rem 1.3rem; text-align: center; box-shadow: 0 20px 40px -26px #000; transform: rotate(var(--rot, 0deg)); transition: transform .25s, box-shadow .25s; scroll-margin-top: 90px;
  background-image: linear-gradient(180deg, rgba(255,255,255,.25), transparent 30%), radial-gradient(circle at 80% 10%, rgba(138,122,99,.18), transparent 40%); }
.carte:hover, .carte:target { transform: rotate(0) translateY(-6px); box-shadow: 0 28px 50px -24px #000; }
.carte:target { outline: 2px solid var(--laiton); outline-offset: 4px; }
.carte::before { content: 'N° ' attr(data-num); position: absolute; top: .9rem; left: 1.1rem; font: 600 .68rem var(--machine); letter-spacing: .08em; color: #7b6d57; }
.carte .avatar { width: 74%; margin: 1rem auto 1.1rem; border-radius: 50%; box-shadow: 0 0 0 4px var(--papier), 0 0 0 5px #7b6d57; filter: grayscale(1) sepia(.55) contrast(1.05); transition: filter .35s; }
.carte:hover .avatar, .carte:target .avatar { filter: none; }
.carte h2 { font-size: 1.45rem; margin: 0 0 .3rem; }
.carte h2 span { font-style: italic; font-weight: 600; }
.carte-poste { margin: 0 0 .25rem; font-weight: 600; line-height: 1.35; font-size: .95rem; }
.carte-ent { margin: 0 0 .9rem; font: .85rem var(--machine); color: #5b4f3e; }
.carte-liens { display: flex; justify-content: center; align-items: center; gap: .8rem; font-size: .82rem; }
.carte-liens a { text-decoration: none; color: #5b4f3e; }
.carte-liens a:hover { color: var(--sang); }
.carte[hidden] { display: none; }

/* Commissions, étapes */
.commissions { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.2rem; margin-top: 2.2rem; }
.commissions article { background: var(--fumee); border: 1px solid var(--ligne); border-radius: var(--r); padding: 1.7rem; }
.commissions h3 { color: var(--laiton-clair); font-style: italic; }
.commissions p { color: #c7bca6; margin: 0; }
.etapes { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.4rem; }
.etapes article { background: var(--fumee); border: 1px solid var(--ligne); border-radius: var(--r); padding: 1.9rem 1.6rem; display: flex; flex-direction: column; align-items: flex-start; }
.etapes article p { color: #c7bca6; }
.etapes h2 { font-size: 1.75rem; }
.etape-num { font: italic 600 3.2rem/1 var(--display); color: var(--laiton); margin-bottom: .5rem; }
.etapes .btn { margin-top: auto; }
.tarifs { display: grid; grid-template-columns: 1fr auto; gap: .3rem 1rem; margin: auto 0 0; padding-top: 1rem; border-top: 1px dashed var(--ligne); width: 100%; font-size: .9rem; color: #c7bca6; }
.tarifs dd { margin: 0; font-weight: 700; color: var(--laiton-clair); }

/* Pied */
.pied { background: #0b0a08; color: var(--gris); padding: 3rem clamp(16px, 4vw, 40px); font-size: .88rem; border-top: 1px solid var(--ligne); }
.pied-in { max-width: var(--max); margin: 0 auto; display: flex; flex-wrap: wrap; gap: 2rem; align-items: center; justify-content: space-between; }
.pied img { filter: sepia(.4); opacity: .85; }
.pied a { color: var(--laiton-clair); }

/* ===== Espace membre : le bureau du fond ===== */
body.espace { display: grid; grid-template-columns: 252px 1fr; min-height: 100vh; }
.side { background: #0b0a08; border-right: 1px solid var(--ligne); padding: 1.4rem 1rem; display: flex; flex-direction: column; gap: 1.4rem; position: sticky; top: 0; height: 100vh; }
.side-logo img { width: 104px; margin: 0 .4rem; filter: sepia(.35); }
.side-moi { display: flex; gap: .7rem; align-items: center; padding: .75rem; background: var(--fumee); border: 1px solid var(--ligne); border-radius: var(--r); }
.side-moi strong { display: block; font-size: .9rem; }
.side-moi span { font: .74rem var(--machine); color: var(--gris); }
.side nav { display: flex; flex-direction: column; gap: 2px; }
.side nav a, .side-bas a { text-decoration: none; padding: .62rem .9rem; border-radius: var(--r-s); font-weight: 500; font-size: .92rem; color: #cfc4ae; }
.side nav a:hover, .side-bas a:hover { background: var(--fumee); color: var(--creme); }
.side nav a[aria-current] { background: var(--fumee-2); color: var(--laiton-clair); box-shadow: inset 0 0 0 1px var(--ligne); }
.side-bas { margin-top: auto; display: flex; flex-direction: column; }
.side-bas a { font-size: .84rem; color: var(--sepia); }
.contenu { padding: clamp(1.5rem, 4vw, 3rem); max-width: 1440px; width: 100%; }
@media (max-width: 900px) {
  body.espace { grid-template-columns: 1fr; }
  .side { position: static; height: auto; padding: 1rem 16px; gap: .8rem; border-right: 0; border-bottom: 1px solid var(--ligne); }
  .side-logo img { width: 78px; }
  .side nav { flex-direction: row; overflow-x: auto; gap: 6px; padding-bottom: 4px; }
  .side nav a { white-space: nowrap; }
  .side-bas { flex-direction: row; gap: .5rem; }
  .contenu { padding: 1.5rem 16px; }
}
.ctete { margin-bottom: 1.7rem; }
.ctete h1 { font-size: clamp(2.1rem, 4.6vw, 3.2rem); margin-bottom: .2rem; }
.ctete p { color: var(--gris); margin: 0; font-family: var(--machine); font-size: .9rem; }
.ctete-ligne { display: flex; justify-content: space-between; align-items: end; gap: 1rem; flex-wrap: wrap; }
.periode select, .formulaire input, .formulaire select, .formulaire textarea, .porte-carte input {
  font: inherit; width: 100%; padding: .72em .9em; border: 1px solid #4a3f31; border-radius: var(--r-s); background: var(--charbon); color: var(--creme);
}
.periode select { width: auto; border-color: var(--laiton); color: var(--laiton-clair); border-radius: 999px; padding-inline: 1.1em; }
.formulaire input:focus, .formulaire select:focus, .formulaire textarea:focus { outline: none; border-color: var(--laiton); box-shadow: 0 0 0 3px rgba(201, 162, 74, .25); }
.actions-rapides { display: flex; flex-wrap: wrap; gap: .6rem; margin-bottom: 1.9rem; }
.actions-rapides .btn { padding: .6em 1.1em; font-size: .86rem; }

.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(165px, 1fr)); gap: 1rem; margin-bottom: 1.7rem; }
.kpi { background: var(--fumee); border: 1px solid var(--ligne); border-radius: var(--r); padding: 1.2rem 1.25rem; text-decoration: none; transition: border-color .2s, background .2s; }
.kpi:hover { border-color: var(--laiton); background: var(--fumee-2); }
.kpi strong { display: block; font: 700 2rem/1.1 var(--display); white-space: nowrap; color: var(--creme); }
.kpi span { font: .78rem var(--machine); color: var(--gris); }
.kpi-laiton { background: linear-gradient(160deg, #3b2f1f, var(--fumee)); border-color: var(--laiton); }
.kpi-laiton strong { color: var(--laiton-clair); }

.panneau { background: var(--fumee); border: 1px solid var(--ligne); border-radius: var(--r); padding: 1.6rem; }
.panneau h2 { font-size: 1.5rem; }
.panneau-encre { background: var(--papier); color: var(--charbon); border: 0; position: relative; }
.panneau-encre::after { content: 'Confidentiel'; position: absolute; top: 1.3rem; right: 1.2rem; font: 700 .66rem var(--machine); letter-spacing: .14em; text-transform: uppercase; color: var(--sang); border: 1.5px solid var(--sang); border-radius: 999px; padding: .3em .8em; transform: rotate(4deg); opacity: .85; }
.groupe { margin: 0; display: grid; }
.groupe div { display: flex; justify-content: space-between; align-items: baseline; padding: .75rem 0; border-bottom: 1px dashed rgba(16, 14, 12, .25); }
.groupe dt { font: .85rem var(--machine); color: #5b4f3e; }
.groupe dd { margin: 0; font: 700 1.5rem var(--display); }
.panneau-groupe .groupe { grid-template-columns: repeat(4, 1fr); gap: 0 1.6rem; }
.panneau-groupe .groupe div { flex-direction: column; align-items: flex-start; gap: .2rem; border-bottom: 0; border-right: 1px dashed rgba(16, 14, 12, .25); }
.panneau-groupe .groupe div:last-child { border-right: 0; }
@media (max-width: 760px) { .panneau-groupe .groupe { grid-template-columns: 1fr 1fr; } .panneau-groupe .groupe div { border-right: 0; } }
.part { margin: 1rem 0 0; font-size: .9rem; color: #5b4f3e; }

.saisie { background: var(--fumee); border: 1px solid var(--laiton); border-radius: var(--r); margin-bottom: 1.7rem; scroll-margin-top: 20px; }
.saisie summary { cursor: pointer; padding: 1.05rem 1.4rem; font: 600 1.15rem var(--display); color: var(--laiton-clair); list-style: none; display: flex; justify-content: space-between; }
.saisie summary::-webkit-details-marker { display: none; }
.saisie summary::after { content: '+'; font: 1.3rem var(--texte); }
.saisie[open] summary::after { content: '−'; }
.saisie .formulaire { padding: 0 1.3rem 1.3rem; }
.champs { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: .9rem 1rem; margin-bottom: 1.1rem; }
.formulaire label, .porte-carte label { display: flex; flex-direction: column; gap: .35rem; font: .8rem var(--machine); color: var(--gris); }
.formulaire .large { grid-column: 1 / -1; }
.formulaire-etroit { max-width: 420px; display: flex; flex-direction: column; gap: 1rem; align-items: flex-start; }

/* Le registre : tableaux sur papier */
.table-wrap { overflow-x: auto; background: var(--papier); color: var(--charbon); border-radius: var(--r); }
table.triable { width: 100%; border-collapse: collapse; font-size: .9rem; }
.triable th { text-align: left; border-bottom: 1px solid #b9a985; white-space: nowrap; }
.triable th button { all: unset; cursor: pointer; display: flex; align-items: center; gap: .35rem; padding: .9rem 1rem; font: 600 .72rem var(--machine); text-transform: uppercase; letter-spacing: .09em; }
.fleche::after { content: '↕'; color: #9c8d74; font-size: .9rem; }
th[aria-sort=ascending] .fleche::after { content: '↑'; color: var(--sang); }
th[aria-sort=descending] .fleche::after { content: '↓'; color: var(--sang); }
.triable td { padding: .8rem 1rem; border-bottom: 1px solid var(--papier-2); vertical-align: top; }
.triable tbody tr:hover { background: #e4d8bd; }
.tag { display: inline-block; padding: .2em .75em; border: 1px solid #7b6d57; border-radius: 999px; font: 600 .72rem var(--machine); white-space: nowrap; color: #5b4f3e; }
.tag-laiton { border-color: var(--sang); color: var(--sang); }
.vide { color: var(--gris); font-style: italic; }
.table-wrap + .vide, .contenu > .vide { padding: 1rem 0; }

.flash { padding: .85rem 1.2rem; border-radius: var(--r-s); margin-bottom: 1.2rem; font-size: .92rem; border: 1px solid; }
.flash-ok { background: rgba(111, 154, 91, .12); color: #a9cf96; border-color: rgba(111, 154, 91, .4); }
.flash-err { background: rgba(208, 97, 79, .12); color: #f0a394; border-color: rgba(208, 97, 79, .4); }
.flash-info { background: rgba(201, 162, 74, .12); color: var(--laiton-clair); border-color: var(--ligne); }

/* Connexion : on frappe à la porte */
body.porte { min-height: 100vh; display: grid; place-items: center; padding: 16px; background: radial-gradient(ellipse at center, rgba(201,162,74,.14), transparent 60%), var(--charbon); }
.porte-carte { width: min(400px, 100%); background: var(--papier); color: var(--charbon); border-radius: 24px; padding: 2.4rem 2.1rem; display: flex; flex-direction: column; gap: 1rem; box-shadow: 0 40px 80px -30px #000; }
.porte-carte img { width: 130px; margin: 0 auto; }
.porte-carte h1 { font-size: 2rem; text-align: center; margin: 0; }
.porte-carte label { color: #5b4f3e; }
.porte-carte input { background: var(--creme); color: var(--charbon); border-color: #b9a985; }
.porte-carte input:focus { outline: none; border-color: var(--charbon); }
.porte-carte .btn { background: var(--charbon); color: var(--laiton-clair); }
.porte-aide { font: .8rem var(--machine); color: #7b6d57; text-align: center; margin: 0; }
.porte-carte .flash-err { color: var(--sang); background: rgba(142, 42, 34, .08); }

/* Bureau */
.statut { font: .78rem var(--machine); }
.statut-ok { color: #3f6e2e; } .statut-att { color: #8a6514; } .statut-non { color: #7b6d57; }
.actions-ligne { display: flex; gap: .4rem; flex-wrap: wrap; }
.actions-ligne .btn { padding: .35em .8em; font-size: .76rem; color: var(--charbon); border-color: #7b6d57; }
.actions-ligne .btn-noir { background: var(--charbon); color: var(--laiton-clair); }
.mdp-provisoire { font: 600 1.1rem ui-monospace, Menlo, monospace; background: var(--charbon); color: var(--laiton-clair); padding: .3em .7em; border-radius: 8px; user-select: all; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } .carte { transform: none; } }

.ctete .filtre { margin-top: 0; }
#annuaire a { color: inherit; text-decoration: none; border-bottom: 1px solid #b9a985; }
#annuaire a:hover { color: var(--sang); }
#annuaire td { vertical-align: middle; }

.role { display: inline-block; padding: .22em .8em; border-radius: 999px; font: 600 .68rem var(--texte); letter-spacing: .08em; text-transform: uppercase; background: var(--charbon); color: var(--laiton-clair); vertical-align: middle; }
.role-decouverte { background: none; color: #6b5d48; border: 1px dashed #9c8d74; }
.carte .role { margin: -.4rem 0 .7rem; }
.carte:not(:has(.role)) h2 { margin-top: .2rem; }

#annuaire .avatar-s { width: 52px; height: 52px; min-width: 52px; }
#annuaire td:nth-child(1) { width: 72px; }
#annuaire td:nth-child(5), #annuaire td:nth-child(6) { white-space: nowrap; }
.coord span { display: block; line-height: 1.5; user-select: all; }
.coord span + span { color: #5b4f3e; font-size: .85rem; }
#annuaire td:nth-child(2) .role { display: table; margin-top: .3rem; }
#annuaire td:nth-child(2) { min-width: 170px; font-weight: 600; }
#annuaire td:nth-child(2) .role { display: block; width: max-content; margin-top: .35rem; font-weight: 600; }
#annuaire td:nth-child(3) { width: 34px; padding-inline: 0; }
#annuaire a.li { border: 0; color: #5b4f3e; display: inline-flex; }
#annuaire a.li:hover { color: var(--sang); }
.role-membre { background: none; color: #5b4f3e; border: 1px solid #b9a985; }
.bloc-in .role-membre, .side .role-membre { color: var(--gris); border-color: var(--ligne); }
.statut-select { font: inherit; font-size: .8rem; padding: .3em .6em; border-radius: 999px; border: 1px solid #b9a985; background: var(--creme); color: var(--charbon); }

.ent { display: flex; align-items: center; gap: .75rem; min-width: 260px; }
.ent strong { display: block; font-weight: 600; }
.ent span { display: block; font-size: .82rem; color: #5b4f3e; line-height: 1.35; }
.logo-ent { width: 40px; height: 40px; min-width: 40px; object-fit: contain; background: #fff; border-radius: 10px; padding: 3px; box-shadow: 0 0 0 1px #d5c7a8; }
.logo-ent-vide { display: grid; place-items: center; font: 600 .85rem var(--display); color: var(--cuir); background: var(--creme); }
.carte-depuis { margin: -.6rem 0 .8rem; font-size: .78rem; font-style: italic; color: #7b6d57; }

.actions-menu summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: .4rem; padding: .4em .95em; border-radius: 999px; background: var(--charbon); color: var(--laiton-clair); font: 600 .78rem var(--texte); white-space: nowrap; }
.actions-menu summary::-webkit-details-marker { display: none; }
.actions-menu summary::after { content: '▾'; font-size: .7rem; transition: transform .2s; }
.actions-menu[open] summary::after { transform: rotate(180deg); }
.actions-menu div { position: fixed; z-index: 50; display: flex; flex-direction: column; gap: 2px; width: max-content; background: var(--creme); border: 1px solid #d5c7a8; border-radius: 12px; padding: .35rem; box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .55); }
.actions-menu:not([open]) div { display: none; }
#annuaire .actions-menu a { border: 0; padding: .5rem .7rem; border-radius: 8px; font-size: .85rem; font-weight: 500; white-space: nowrap; }
#annuaire .actions-menu a:hover { background: var(--papier-2); color: var(--charbon); }

.deux-tableaux { display: grid; grid-template-columns: 1fr 1fr; gap: 1.2rem; align-items: start; }
.deux-tableaux > section { min-width: 0; }
.deux-tableaux h2 { font-size: 1.45rem; display: flex; align-items: baseline; gap: .6rem; margin-bottom: .7rem; }
.deux-tableaux h2 span { font: 600 .85rem var(--texte); color: var(--laiton-clair); background: var(--fumee-2); border: 1px solid var(--ligne); border-radius: 999px; padding: .15em .7em; }
.deux-tableaux table.triable { font-size: .85rem; }
.deux-tableaux .triable td { padding: .7rem .75rem; }
.deux-tableaux .triable th button { padding: .8rem .75rem; }
.deux-tableaux td:first-child, .deux-tableaux td:last-child { white-space: nowrap; }
.deux-tableaux .triable td strong { display: block; font-weight: 600; }
.sous { display: block; font-size: .78rem; color: #5b4f3e; }
@media (max-width: 1100px) { .deux-tableaux { grid-template-columns: 1fr; } }

.liste-tete { margin: .4rem 0 1rem; }
.liste-tete h2 { font-size: 1.6rem; margin: 0; display: flex; align-items: baseline; gap: .7rem; flex-wrap: wrap; }
.liste-tete h2 span { font: 500 .85rem var(--texte); color: var(--gris); }
#invites .ent { min-width: 0; gap: .6rem; }
#invites .role { margin-top: .25rem; display: inline-block; }
#invites a.li { color: #5b4f3e; display: inline-flex; border: 0; }
#invites a.li:hover { color: var(--sang); }
#invites td:first-child { white-space: nowrap; }
#invites .avatar-vide { font-size: .8rem; background: var(--papier-2); color: var(--cuir); }

/* Mon compte */
a.side-moi { text-decoration: none; color: inherit; transition: border-color .2s; }
a.side-moi:hover { border-color: var(--laiton); }
.compte { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; align-items: start; }
.compte > .btn { grid-column: 1 / -1; justify-self: start; }
.compte .panneau h2 { margin-bottom: 1rem; }
.compte-visuel { display: flex; align-items: center; gap: 1.2rem; margin-bottom: 1.2rem; }
.compte-photo { width: 96px; height: 96px; min-width: 96px; border-radius: 50%; box-shadow: 0 0 0 1px var(--laiton); }
.compte-visuel .logo-ent { width: 72px; height: 72px; min-width: 72px; border-radius: 16px; }
.compte-visuel .logo-ent-vide { font-size: 1.3rem; }
.compte input[type=file] { padding: .55em; font-size: .85rem; }
.compte input:disabled { opacity: .55; cursor: not-allowed; }
@media (max-width: 1000px) { .compte { grid-template-columns: 1fr; } }

/* Popups de saisie */
dialog.modale { width: min(720px, calc(100vw - 32px)); max-height: calc(100vh - 48px); padding: 0; border: 1px solid var(--laiton); border-radius: 22px; background: var(--fumee); color: var(--creme); box-shadow: 0 40px 90px -30px #000; }
dialog.modale::backdrop { background: rgba(8, 7, 6, .72); backdrop-filter: blur(3px); }
dialog.modale[open] { animation: modale-in .18s ease-out; }
@keyframes modale-in { from { opacity: 0; transform: translateY(10px) scale(.98); } }
.modale .formulaire { padding: 1.5rem 1.6rem 1.4rem; }
.modale-tete { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.2rem; }
.modale-tete h2 { font-size: 1.7rem; margin: 0; }
.modale-x { all: unset; cursor: pointer; width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; font-size: 1.5rem; color: var(--gris); }
.modale-x:hover { background: var(--fumee-2); color: var(--creme); }
.modale-pied { display: flex; justify-content: flex-end; gap: .6rem; margin-top: .4rem; }
@media (prefers-reduced-motion: reduce) { dialog.modale[open] { animation: none; } }

/* ===== Thème « mur bleu canard » (30/10/2026) : fond texturé bleu, titres blancs patinés, cuivre ===== */
:root {
  --bleu: #1d4a53;
  --bleu-clair: #3b7680;
  --bleu-nuit: #0c2329;
  --laiton: #d29a52;
  --laiton-clair: #e8b877;
  --ligne: rgba(232, 184, 119, .25);
  --fumee: rgba(8, 26, 31, .62);
  --fumee-2: rgba(8, 26, 31, .82);
  --mur: radial-gradient(ellipse 70% 60% at 50% 35%, rgba(92, 160, 168, .55), transparent 70%),
         radial-gradient(ellipse 120% 90% at 50% 50%, transparent 40%, rgba(5, 18, 22, .85) 100%),
         url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='1200' height='1200'%3E%3Cfilter id='m'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.004' numOctaves='4' seed='7' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .08  0 0 0 0 .2  0 0 0 0 .23  0 0 0 -1.4 1.05'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23m)'/%3E%3C/svg%3E"),
         url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .55 -.2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)'/%3E%3C/svg%3E"),
         var(--bleu);
}
body { background: var(--mur); background-attachment: fixed; }
body::after { opacity: .07; }

/* Titres : capitales blanches, serif gras, légèrement usées */
h1, .bloc h2, .page-tete h1, .ctete h1, .bandeau h2 { color: #f3f1ea; }
h1 { text-transform: uppercase; font-weight: 900; letter-spacing: .015em; line-height: .96;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='u'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.75' numOctaves='3' seed='3'/%3E%3CfeColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  -3.2 0 0 0 2.75'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23u)'/%3E%3C/svg%3E");
          mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='u'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.75' numOctaves='3' seed='3'/%3E%3CfeColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  -3.2 0 0 0 2.75'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23u)'/%3E%3C/svg%3E"); }
h1 em, h2 em { font-style: normal; color: var(--laiton); }
.ctete h1, .porte-carte h1 { text-transform: none; font-weight: 700; -webkit-mask-image: none; mask-image: none; }
.surtitre { color: var(--laiton-clair); }

/* Barre, pied, blocs : on laisse respirer le mur */
.barre { background: rgba(9, 30, 35, .82); }
.hero { background: transparent; }
.hero::before { opacity: .04; }
.hero::after { content: ''; position: absolute; inset: clamp(10px, 2vw, 22px); border: 1px solid rgba(243, 241, 234, .55); pointer-events: none; }
.hero-tampon { filter: none; opacity: .92; }
.macaron { position: absolute; right: clamp(24px, 9vw, 150px); top: clamp(70px, 14%, 120px); width: 128px; height: 128px; margin: 0; border-radius: 50%; background: #0b0b0a; color: #f3f1ea; display: grid; place-content: center; text-align: center; font: 700 .95rem/1.05 var(--display); text-transform: uppercase; transform: rotate(-8deg); box-shadow: 0 14px 30px -12px #000; border: 2px solid rgba(243, 241, 234, .85); outline: 4px solid #0b0b0a; }
.macaron span { display: block; font-size: .78rem; letter-spacing: .08em; }
.macaron strong { display: block; font-size: 1.7rem; color: var(--laiton-clair); }
@media (max-width: 900px) { .macaron { top: 1.5rem; right: 1.5rem; width: 96px; height: 96px; font-size: .75rem; } .macaron strong { font-size: 1.25rem; } }
.bloc-encre { background: rgba(6, 22, 26, .55); border-block: 1px solid var(--ligne); }
.bandeau-in { background: linear-gradient(110deg, rgba(8, 26, 31, .85), rgba(29, 74, 83, .7)); }
.pied { background: rgba(5, 18, 22, .9); }
.timeline div { background: rgba(6, 22, 26, .55); }
.commissions article, .etapes article { background: rgba(6, 22, 26, .55); }
.regles li, .liste-regles li, .timeline p, .commissions p, .etapes article p, .hero-texte, .page-tete .intro { color: #d7e1df; }
.mosaique .avatar { filter: grayscale(.55) contrast(1.05); }
.btn-laiton { color: #12100d; }

/* Espace membre */
.side { background: rgba(5, 18, 22, .88); }
.kpi, .panneau, .saisie { background: var(--fumee); }
dialog.modale { background: #0f2c33; }
body.porte { background: var(--mur); }
.surtitre::before { content: none; display: none; }
body { background-size: auto, auto, cover, 220px 220px, auto; }
.carte h2, .chiffres strong { color: var(--charbon); }
.carte h2 span { color: #4a3f31; }

/* =====================================================================
   ESPACE MEMBRE : design moderne et clair (30/10/2026)
   Le site vitrine garde son thème « mur bleu » ; tout ce qui suit est limité à .espace et .porte.
   ===================================================================== */
body.espace, body.porte {
  --a: #0e7490; --a-600: #0891b2; --a-50: #ecfeff; --a-100: #cffafe;
  --ink: #0f172a; --ink-2: #334155; --muted: #64748b; --line: #e2e8f0; --bg: #f4f6f8;
  --ambre: #f59e0b; --vert: #16a34a;
  --ombre: 0 1px 2px rgba(15, 23, 42, .05), 0 4px 16px -6px rgba(15, 23, 42, .08);
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  background: var(--bg); color: var(--ink-2);
}
body.espace::after, body.porte::after { content: none; }
.espace h1, .espace h2, .espace h3, .porte h1 { font-family: inherit; color: var(--ink); text-transform: none; letter-spacing: -.02em; -webkit-mask-image: none; mask-image: none; }
.espace h1 em, .espace h2 em { font-style: normal; color: var(--a); }
.espace a { color: inherit; }
.espace ::selection { background: var(--a-100); color: var(--ink); }

/* Barre latérale */
.espace .side { background: #fff; border-right: 1px solid var(--line); padding: 1.3rem .9rem; gap: 1.2rem; }
.espace .side-logo img { width: 86px; margin: 0 .5rem; filter: none; }
.espace .side-moi { background: var(--bg); border: 1px solid var(--line); border-radius: 14px; padding: .7rem; }
.espace a.side-moi:hover { border-color: var(--a); }
.espace .side-moi strong { color: var(--ink); font-size: .88rem; }
.espace .side-moi span { font: 500 .75rem inherit; font-family: inherit; color: var(--muted); }
.espace .side nav a, .espace .side-bas a { display: flex; align-items: center; gap: .7rem; color: var(--ink-2); font-weight: 600; font-size: .9rem; padding: .62rem .8rem; border-radius: 10px; box-shadow: none; }
.espace .side nav a .ico, .espace .side-bas a .ico { color: #94a3b8; flex: none; }
.espace .side nav a:hover, .espace .side-bas a:hover { background: var(--bg); color: var(--ink); }
.espace .side nav a[aria-current], .espace .side-bas a[aria-current] { background: var(--a-50); color: var(--a); box-shadow: none; }
.espace .side nav a[aria-current] .ico, .espace .side-bas a[aria-current] .ico { color: var(--a); }
.espace .side-bas a { font-weight: 500; color: var(--muted); }
.espace .avatar-s { box-shadow: 0 0 0 2px #fff, 0 0 0 3px var(--line); background: var(--bg); }
.espace .avatar-vide { font: 700 .8rem inherit; font-family: inherit; color: var(--a); background: var(--a-50); font-style: normal; }

/* En-têtes de page */
.espace .contenu { padding: clamp(1.5rem, 3.5vw, 2.6rem); }
.espace .ctete { margin-bottom: 1.5rem; }
.espace .ctete h1 { font-size: clamp(1.6rem, 3vw, 2.1rem); font-weight: 800; margin-bottom: .25rem; }
.espace .ctete p { font: 500 .92rem inherit; font-family: inherit; color: var(--muted); }

/* Boutons et champs */
.espace .btn, .porte .btn { font-family: inherit; font-weight: 600; border-radius: 10px; border: 1px solid var(--line); background: #fff; color: var(--ink); padding: .62em 1.1em; letter-spacing: 0; }
.espace .btn:hover, .porte .btn:hover { background: var(--bg); transform: none; }
.espace .btn-laiton, .porte .btn-laiton { background: var(--a); border-color: var(--a); color: #fff; box-shadow: 0 6px 14px -8px rgba(14, 116, 144, .8); }
.espace .btn-laiton:hover { background: var(--a-600); }
.espace .btn-noir, .porte .btn-noir { background: var(--ink); border-color: var(--ink); color: #fff; }
.espace .formulaire label, .porte .porte-carte label { font: 600 .8rem inherit; font-family: inherit; color: var(--ink-2); }
.espace .formulaire input, .espace .formulaire select, .espace .formulaire textarea, .espace .periode select, .espace .filtre, .espace .statut-select, .porte .porte-carte input {
  font-family: inherit; background: #fff; color: var(--ink); border: 1px solid var(--line); border-radius: 10px; box-shadow: none; }
.espace .formulaire input:focus, .espace .formulaire select:focus, .espace .formulaire textarea:focus, .espace .filtre:focus, .porte .porte-carte input:focus { outline: none; border-color: var(--a); box-shadow: 0 0 0 3px var(--a-100); }
.espace .periode select { color: var(--ink); font-weight: 600; border-radius: 10px; }
.espace .filtre { margin: 0; font-size: .9rem; }
.espace .filtre::placeholder { color: #94a3b8; }
.espace input:disabled { background: var(--bg); opacity: 1; color: var(--muted); }

/* Messages */
.espace .flash { border-radius: 12px; font-family: inherit; border: 1px solid; }
.espace .flash-ok { background: #f0fdf4; color: #166534; border-color: #bbf7d0; }
.espace .flash-err { background: #fef2f2; color: #991b1b; border-color: #fecaca; }
.espace .flash-info { background: var(--a-50); color: var(--a); border-color: var(--a-100); }

/* Tableau de bord */
.espace .kpis { gap: .9rem; }
.espace .kpi { background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--ombre); padding: 1.1rem 1.2rem; }
.espace .kpi:hover { border-color: var(--a); background: #fff; }
.espace .kpi strong { font: 800 1.75rem/1.1 inherit; font-family: inherit; color: var(--ink); }
.espace .kpi span { font: 500 .82rem inherit; font-family: inherit; color: var(--muted); }
.espace .kpi-laiton { background: linear-gradient(135deg, var(--a), #155e75); border-color: transparent; }
.espace .kpi-laiton strong, .espace .kpi-laiton span { color: #fff; }
.espace .panneau { background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--ombre); }
.espace .panneau h2 { font-size: 1.15rem; font-weight: 700; }
.espace .panneau-encre { background: #fff; color: var(--ink-2); }
.espace .panneau-encre::after { font-family: inherit; color: #b45309; border: 0; background: #fef3c7; transform: none; opacity: 1; }
.espace .groupe div { border-color: var(--line); }
.espace .groupe dt { font: 500 .85rem inherit; font-family: inherit; color: var(--muted); }
.espace .groupe dd { font: 800 1.5rem inherit; font-family: inherit; color: var(--ink); }
.espace .panneau-groupe .groupe div { border-right-color: var(--line); }
.espace .part { color: var(--muted); }

/* Tableaux : blancs, compacts, lisibles */
.espace .table-wrap { background: #fff; color: var(--ink-2); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--ombre); }
.espace table.triable { font-size: .88rem; }
.espace .triable th { background: #f8fafc; border-bottom: 1px solid var(--line); }
.espace .triable th button { font: 600 .72rem inherit; font-family: inherit; color: var(--muted); letter-spacing: .05em; padding: .75rem 1rem; }
.espace .fleche::after { color: #cbd5e1; }
.espace th[aria-sort] .fleche::after { color: var(--a); }
.espace .triable td { padding: .7rem 1rem; border-bottom: 1px solid #f1f5f9; vertical-align: middle; }
.espace .triable tbody tr:last-child td { border-bottom: 0; }
.espace .triable tbody tr:hover { background: #f8fafc; }
.espace .triable td strong { color: var(--ink); }
.espace .sous, .espace .ent span, .espace .coord span + span { color: var(--muted); font-family: inherit; }
.espace .tag { font: 600 .72rem inherit; font-family: inherit; border: 0; background: #f1f5f9; color: var(--ink-2); padding: .25em .7em; }
.espace .tag-laiton { background: var(--a-50); color: var(--a); }
.espace .vide { font-style: normal; color: var(--muted); }
.espace .logo-ent { box-shadow: none; border: 1px solid var(--line); }
.espace .logo-ent-vide { font: 700 .8rem inherit; font-family: inherit; color: var(--a); background: var(--a-50); border-color: transparent; }
.espace #annuaire a, .espace #invites a.li, .espace #annuaire a.li { border: 0; color: var(--muted); }
.espace #annuaire a:hover, .espace #invites a.li:hover { color: var(--a); }
.espace #annuaire .ent a { color: var(--ink); }

/* Badges de statut */
.espace .role { font: 700 .68rem inherit; font-family: inherit; letter-spacing: .03em; text-transform: none; background: #fef3c7; color: #92400e; border: 0; padding: .22em .65em; }
.espace .role-membre { background: #f1f5f9; color: var(--muted); }
.espace .role-decouverte { background: var(--a-50); color: var(--a); border: 1px dashed #67e8f9; }
.espace .statut { display: inline-block; font: 600 .74rem inherit; font-family: inherit; padding: .22em .65em; border-radius: 999px; }
.espace .statut-ok { background: #dcfce7; color: #166534; }
.espace .statut-att { background: #fef3c7; color: #92400e; }
.espace .statut-non { background: #f1f5f9; color: var(--muted); }

/* Recos / Mercis en deux colonnes */
.espace .deux-tableaux h2, .espace .liste-tete h2 { font-size: 1.1rem; font-weight: 700; }
.espace .deux-tableaux h2 span, .espace .liste-tete h2 span { font-family: inherit; background: var(--a-50); color: var(--a); border: 0; }

/* Menus d'actions */
.espace .actions-menu summary { background: #fff; color: var(--ink); border: 1px solid var(--line); font-family: inherit; border-radius: 10px; }
.espace .actions-menu summary:hover, .espace .actions-menu[open] summary { border-color: var(--a); color: var(--a); }
.espace .actions-menu div { background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 18px 40px -16px rgba(15, 23, 42, .25); }
.espace .actions-menu a, .espace .actions-menu button { all: unset; cursor: pointer; display: block; padding: .55rem .75rem; border-radius: 8px; font: 500 .86rem inherit; font-family: inherit; color: var(--ink-2); white-space: nowrap; }
.espace #annuaire .actions-menu a { color: var(--ink-2); }
.espace .actions-menu a:hover, .espace .actions-menu button:hover { background: var(--a-50); color: var(--a); }
.espace .actions-menu form { margin: 0; }
.espace .actions-menu .danger:hover { background: #fef2f2; color: #b91c1c; }

/* Popups */
.espace dialog.modale { background: #fff; color: var(--ink-2); border: 1px solid var(--line); border-radius: 20px; box-shadow: 0 30px 80px -20px rgba(15, 23, 42, .35); }
.espace dialog.modale::backdrop { background: rgba(15, 23, 42, .45); backdrop-filter: blur(2px); }
.espace .modale-tete h2 { font-size: 1.3rem; font-weight: 800; }
.espace .modale-x { color: var(--muted); }
.espace .modale-x:hover { background: var(--bg); color: var(--ink); }

/* Mon compte */
.espace .compte-photo { box-shadow: 0 0 0 3px #fff, 0 0 0 4px var(--line); }
.espace .compte input[type=file] { background: var(--bg); }

/* Admin */
.espace .statut-select { font-size: .82rem; padding: .35em .6em; border-radius: 8px; }
.espace .mdp-provisoire { background: #fff; color: var(--ink); border: 1px solid var(--a-100); }
.espace .actions-ligne .btn { color: var(--ink); }
.espace .admin-membre strong { display: block; color: var(--ink); font-weight: 600; }
.espace .admin-membre span { display: block; font-size: .78rem; color: var(--muted); }
.espace .admin-compte small { display: block; font-size: .74rem; color: var(--muted); margin-top: .2rem; }
.espace #admin td:nth-child(1) { width: 56px; }
.espace #admin td { white-space: nowrap; }
.espace #admin .num { font-variant-numeric: tabular-nums; color: var(--ink); font-weight: 600; }
.espace .actions-menu.points summary { padding: .35em .7em; font-size: 1rem; line-height: 1; }
.espace .actions-menu.points summary::after { content: none; }

/* Connexion */
body.porte { background: radial-gradient(ellipse at 30% 20%, #155e75, #0b3b47 60%, #082f3a); }
.porte .porte-carte { background: #fff; color: var(--ink-2); border-radius: 22px; box-shadow: 0 40px 80px -30px rgba(0, 0, 0, .5); transform: none; }
.porte .porte-carte h1 { font-weight: 800; font-size: 1.6rem; }
.porte .porte-carte input { background: #fff; }
.porte .porte-aide { font-family: inherit; color: var(--muted); }
.porte .flash-err { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; border-radius: 10px; }
.espace #admin .triable td, .espace #admin .triable th button { padding-inline: .7rem; }
.espace #admin .statut-select { width: auto; max-width: 140px; }
.espace #admin input[type=month].statut-select { width: 150px; }
.espace #admin .admin-membre span { max-width: 230px; overflow: hidden; text-overflow: ellipsis; }
.espace .periode select { width: auto; min-width: 120px; }
.espace .saisis { display: flex; flex-wrap: wrap; gap: .35rem; }
.espace .saisi { display: inline-flex; align-items: center; gap: .4rem; padding: .18rem .6rem .18rem .2rem; border-radius: 999px; background: #f1f5f9; font-size: .8rem; font-weight: 600; color: var(--ink-2); white-space: nowrap; }
.espace .avatar-xs { width: 24px; height: 24px; min-width: 24px; border-radius: 50%; object-fit: cover; aspect-ratio: 1; }

/* Tableau de bord : mes chiffres | le groupe, chacun « année » puis « depuis le début » */
.espace .tableau-bord { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; align-items: start; }
.espace .tableau-bord .colonne { display: flex; flex-direction: column; gap: 1rem; }
.espace .tableau-bord h2 { font-size: 1.15rem; font-weight: 800; margin: 0; }
.espace .chiffres-bloc { background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--ombre); padding: 1.1rem 1.3rem .5rem; }
.espace .chiffres-bloc h3 { font-size: .78rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin: 0 0 .4rem; }
.espace .chiffres-bloc dl { margin: 0; }
.espace .chiffres-bloc dl div { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; padding: .62rem 0; border-top: 1px solid #f1f5f9; }
.espace .chiffres-bloc dl div:first-child { border-top: 0; }
.espace .chiffres-bloc dt { font-size: .9rem; color: var(--ink-2); }
.espace .chiffres-bloc dt a { text-decoration: none; }
.espace .chiffres-bloc dt a:hover { color: var(--a); }
.espace .chiffres-bloc dd { margin: 0; font-size: 1.15rem; font-weight: 800; color: var(--ink); font-variant-numeric: tabular-nums; white-space: nowrap; }
.espace .chiffres-bloc dd small { font-size: .82rem; font-weight: 600; color: var(--muted); margin-left: .35rem; }
.espace .chiffres-accent { border-color: var(--a-100); box-shadow: 0 0 0 1px var(--a-100), var(--ombre); }
.espace .chiffres-accent h3 { color: var(--a); }
@media (max-width: 1000px) { .espace .tableau-bord { grid-template-columns: 1fr; } }

/* ===== Vitrine, accueil (30/10/2026) : bandeau chiffres lisible, trombinoscope compact en couleur ===== */
.chiffres { background: rgba(6, 24, 29, .78); color: #f3f1ea; border: 1px solid rgba(232, 184, 119, .3); backdrop-filter: blur(6px); box-shadow: 0 24px 50px -28px #000; }
.chiffre { border-right-color: rgba(232, 184, 119, .22); }
.chiffre strong { font: 800 2.15rem/1.05 'Inter', system-ui, sans-serif; letter-spacing: -.02em; color: #fff; font-variant-numeric: lining-nums tabular-nums; }
.chiffre span { font: 500 .85rem 'Inter', system-ui, sans-serif; color: #bcd3d0; }
@media (max-width: 820px) { .chiffre:nth-child(-n+2) { border-bottom-color: rgba(232, 184, 119, .22); } }
.chiffres strong { color: #fff; }
.timeline time, .etape-num, .regles li::before { font-variant-numeric: lining-nums; }

.trombi { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1rem; }
.trombi-carte { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .15rem; padding: 1.1rem .7rem 1rem; border-radius: 18px; background: rgba(6, 24, 29, .5); border: 1px solid rgba(232, 184, 119, .18); text-decoration: none; transition: transform .2s, background .2s, border-color .2s; }
.trombi-carte:hover { transform: translateY(-4px); background: rgba(6, 24, 29, .75); border-color: var(--laiton); }
.trombi-carte .avatar { width: 86px; height: 86px; border-radius: 50%; margin-bottom: .6rem; box-shadow: 0 0 0 3px rgba(243, 241, 234, .85); filter: none; }
.trombi-carte strong { font: 600 .9rem/1.25 'Inter', system-ui, sans-serif; color: #f3f1ea; }
.trombi-carte span { font: 400 .78rem/1.3 'Inter', system-ui, sans-serif; color: #bcd3d0; }
/* Fiches de la page Membres : photos en couleur */
.carte .avatar { filter: none; }

.trombi-carte .role { margin: -1.1rem 0 .45rem; position: relative; font: 700 .62rem 'Inter', system-ui, sans-serif; letter-spacing: .06em; background: var(--laiton); color: #12100d; border: 2px solid rgba(6, 24, 29, .9); }
.trombi-carte .role-decouverte { background: #0f2c33; color: #bcd3d0; border: 1px dashed #7fb3b5; }

/* Accueil : valeurs et formations */
.valeurs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; margin-top: 2rem; }
.valeurs article { background: rgba(6, 24, 29, .5); border: 1px solid rgba(232, 184, 119, .18); border-radius: 20px; padding: 1.6rem 1.5rem; }
.valeurs h3 { font: 700 1.25rem/1.2 var(--display); color: var(--laiton-clair); margin-bottom: .5rem; }
.valeurs p { color: #d7e1df; margin: 0; }
@media (max-width: 820px) { .valeurs { grid-template-columns: 1fr; } }
.intro-bloc { color: #d7e1df; font-size: 1.05rem; max-width: 30rem; }
.formations { list-style: none; margin: 0; padding: 0; display: grid; gap: .7rem; }
.formations li { display: flex; flex-direction: column; gap: .1rem; padding: 1rem 1.2rem 1rem 3.2rem; position: relative; background: rgba(6, 24, 29, .5); border: 1px solid rgba(232, 184, 119, .18); border-radius: 16px; }
.formations li::before { content: ''; position: absolute; left: 1.2rem; top: 50%; width: 12px; height: 12px; margin-top: -6px; border-radius: 50%; background: var(--laiton); box-shadow: 0 0 0 4px rgba(210, 154, 82, .25); }
.formations strong { color: #f3f1ea; font-weight: 600; }
.formations span { color: #bcd3d0; font-size: .88rem; }
.seminaire { display: grid; grid-template-columns: 1.2fr 1fr; gap: clamp(2rem, 6vw, 5rem); align-items: center; padding: clamp(1.6rem, 4vw, 2.6rem); border-radius: 28px; background: linear-gradient(115deg, rgba(6, 24, 29, .82), rgba(29, 74, 83, .55)); border: 1px solid rgba(232, 184, 119, .25); }
.seminaires { list-style: none; margin: 0; padding: 0; display: grid; gap: .8rem; }
.seminaires li { display: flex; flex-direction: column; padding-left: 1.1rem; border-left: 2px solid var(--laiton); }
.seminaires strong { font: 700 1.15rem var(--display); color: #f3f1ea; font-variant-numeric: lining-nums; }
.seminaires span { color: #bcd3d0; font-size: .9rem; }
@media (max-width: 820px) { .seminaire { grid-template-columns: 1fr; } }
.liste-titre { font: 600 .74rem 'Inter', system-ui, sans-serif; letter-spacing: .16em; text-transform: uppercase; color: var(--laiton-clair); margin: 0 0 .9rem; }

/* Devenir membre : le parcours en frise, dessinée au fil du défilement */
.parcours { --c-invite: #5fb7c1; --c-decouverte: var(--laiton); --c-validation: #e07a5f; list-style: none; margin: 2.6rem 0 0; padding: 0; position: relative; }
.parcours::before { content: ''; position: absolute; left: 27px; top: 10px; bottom: 10px; width: 3px; border-radius: 3px; background: rgba(243, 241, 234, .14); }
.parcours::after { content: ''; position: absolute; left: 27px; top: 10px; width: 3px; border-radius: 3px; height: var(--avance, 0%); max-height: calc(100% - 20px); background: linear-gradient(var(--c-invite) 0%, var(--c-decouverte) 35%, var(--c-decouverte) 70%, var(--c-validation) 88%, #7bc47f 100%); transition: height .15s linear; }
.etape { position: relative; display: grid; grid-template-columns: 56px 1fr; gap: 1.4rem; padding-bottom: 2.2rem; opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.etape.visible { opacity: 1; transform: none; }
.etape:last-child { padding-bottom: 0; }
.etape-pastille { position: relative; z-index: 1; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; font: 800 1.2rem 'Inter', system-ui, sans-serif; color: #0c2329; background: var(--c); box-shadow: 0 0 0 6px rgba(6, 24, 29, .85), 0 10px 24px -10px #000; transform: scale(.6); transition: transform .5s cubic-bezier(.3, 1.6, .5, 1) .1s; }
.etape.visible .etape-pastille { transform: none; }
.etape-invite { --c: var(--c-invite); }
.etape-decouverte { --c: var(--c-decouverte); }
.etape-validation { --c: var(--c-validation); }
.etape-bienvenue { --c: #7bc47f; }
.etape-corps { background: rgba(6, 24, 29, .58); border: 1px solid rgba(243, 241, 234, .1); border-left: 3px solid var(--c); border-radius: 20px; padding: 1.4rem 1.6rem; }
.etape-phase { margin: 0 0 .35rem; font: 700 .74rem 'Inter', system-ui, sans-serif; letter-spacing: .12em; text-transform: uppercase; color: var(--c); }
.etape-corps h3 { font: 700 1.5rem/1.2 var(--display); color: #f3f1ea; margin-bottom: .5rem; }
.etape-corps > p { color: #d7e1df; margin-bottom: .8rem; }
.etape-corps .btn { margin-top: .2rem; }
.etape-points { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; color: #d7e1df; }
.etape-points li { padding-left: 1.2rem; position: relative; }
.etape-points li::before { content: ''; position: absolute; left: 0; top: .6em; width: 7px; height: 7px; border-radius: 50%; background: var(--c); }
.etape-points strong { color: #f3f1ea; }
.etape-grille { display: grid; grid-template-columns: repeat(3, 1fr); gap: .7rem; margin-top: .6rem; }
.etape-grille div { background: rgba(210, 154, 82, .1); border: 1px solid rgba(210, 154, 82, .28); border-radius: 14px; padding: .8rem .9rem; display: flex; flex-direction: column; gap: .15rem; }
.etape-grille strong { color: var(--laiton-clair); font-weight: 700; }
.etape-grille span { color: #d7e1df; font-size: .88rem; line-height: 1.35; }
.etape-note { margin: 1rem 0 0 !important; font-size: .9rem; color: #bcd3d0 !important; font-style: italic; }
.etape-bienvenue .tarifs { max-width: 320px; border-top-color: rgba(243, 241, 234, .15); }
@media (max-width: 820px) { .etape-grille { grid-template-columns: 1fr 1fr; } .etape { grid-template-columns: 44px 1fr; gap: 1rem; } .etape-pastille { width: 44px; height: 44px; font-size: 1rem; } .parcours::before, .parcours::after { left: 21px; } }
@media (max-width: 520px) { .etape-grille { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { .etape, .etape-pastille { opacity: 1; transform: none; transition: none; } .parcours::after { height: calc(100% - 20px); } }

.chiffres { grid-template-columns: repeat(5, 1fr); }
@media (max-width: 1000px) { .chiffres { grid-template-columns: repeat(3, 1fr); } .chiffre { border-bottom: 1px solid rgba(232, 184, 119, .22); } }
@media (max-width: 600px) { .chiffres { grid-template-columns: 1fr 1fr; } }
.espace .reglages { margin-top: 1.6rem; }
.espace .reglages-form { display: flex; align-items: flex-end; gap: .8rem; flex-wrap: wrap; }
.espace .reglages-form label { min-width: 260px; }
