/* Bleds à collectionner : mise en page du jeu (barre, navigation, écrans). Le système des cartes est dans cartes.css. */
html{scroll-padding-top:84px}
body{min-height:100vh;min-height:100dvh}
body>header,body>main,body>footer,body>nav{position:relative;z-index:1}
[hidden]{display:none!important}
a{color:inherit}
.band{padding-block:clamp(22px,3.4vw,44px);padding-inline:max(4vw,16px)}
.in{max-width:1180px;margin:0 auto}
.sr{position:absolute!important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.jeu{background:var(--vert);color:var(--creme)}
.jeu :focus-visible{outline-color:var(--jaune)}
.jeu .note{color:var(--creme2)}
.rp{width:1.15em;height:1.15em;flex:none;vertical-align:-.2em}
.somme{display:inline-flex;align-items:center;gap:5px;font-weight:700;font-variant-numeric:tabular-nums;white-space:nowrap}

/* ---------- bandeau démo ---------- */
.bandeau-demo{position:relative;z-index:31;background:var(--jaune);color:var(--encre);font:600 14px/1.3 Figtree,sans-serif;text-align:center;padding:0 16px;border-bottom:1.5px solid var(--encre)}
.bandeau-demo a{font-weight:700;display:inline-flex;align-items:center;min-height:44px;padding-inline:4px}

/* ---------- barre du haut ---------- */
/* pas de backdrop-filter ici : il casserait la navigation fixée en bas sur téléphone (elle est dans la barre) */
.barre{position:sticky;top:0;z-index:30;background:var(--papier);border-bottom:1px solid var(--trait)}
.barre .in{display:flex;align-items:center;gap:8px 18px;min-height:64px;padding-inline:max(2.4vw,12px);max-width:1240px}
.logo{display:inline-flex;align-items:center;gap:9px;text-decoration:none;font:800 21px/1 Fraunces,Georgia,serif;letter-spacing:-.01em;white-space:nowrap;min-height:44px;min-width:44px;flex:none}
.logo .rp{width:30px;height:30px}
.onglets{display:flex;gap:2px}
.onglets{flex:none}
.onglets a{display:inline-flex;align-items:center;gap:7px;min-height:44px;padding:8px 10px;border-radius:10px;text-decoration:none;font:600 15px/1 Figtree,sans-serif;color:var(--doux)}
.onglets a svg{width:20px;height:20px;flex:none}
.onglets a:hover{background:rgba(31,36,33,.06);color:var(--encre)}
.onglets a[aria-current="page"]{color:var(--encre);background:var(--surface);box-shadow:0 0 0 1px var(--trait)}
.onglets a .pastille-nav{display:none}
.onglets a.externe{border-left:1px solid var(--trait);border-radius:0 10px 10px 0;margin-left:4px}
@media(max-width:600px){.onglets a.externe{border-left:0;margin-left:0;border-radius:10px}}
.etat{display:flex;align-items:center;gap:6px 10px;margin-left:auto}
.etat>*{flex:none}
.etat .solde .lib{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}
.etat .solde,.etat .reserve-mini{display:inline-flex;align-items:center;gap:6px;min-height:44px;padding:4px 12px;border-radius:999px;background:var(--surface);box-shadow:0 0 0 1px var(--trait);font:700 15px/1.1 Figtree,sans-serif;font-variant-numeric:tabular-nums;white-space:nowrap;text-decoration:none}
.etat .solde .rp{width:22px;height:22px}
.reserve-mini svg{width:18px;height:22px;flex:none}
.reserve-mini small{font:600 13px/1.1 Figtree,sans-serif;color:var(--doux);font-variant-numeric:tabular-nums}
.btn-notif{position:relative;display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;border-radius:999px;border:0;background:transparent;color:var(--encre);cursor:pointer}
.btn-notif:hover{background:rgba(31,36,33,.07)}
.btn-notif svg{width:22px;height:22px}
.btn-notif .compte{position:absolute;right:2px;top:2px;min-width:20px;height:20px;padding:0 5px;border-radius:999px;background:var(--rouge);color:#fff;font:700 13px/20px Figtree,sans-serif;text-align:center}
.pseudo-barre{font:700 15px/1 Figtree,sans-serif;text-decoration:none;white-space:nowrap;max-width:14ch;overflow:hidden;text-overflow:ellipsis;min-height:44px;display:inline-flex;align-items:center}
.notifs{position:absolute;right:max(2.4vw,12px);top:62px;width:min(380px,calc(100vw - 24px));max-height:min(70vh,520px);overflow:auto;background:var(--surface);border-radius:14px;box-shadow:0 0 0 1px var(--trait),0 18px 40px -16px rgba(31,36,33,.45);padding:8px}
.notifs h2{font:700 16px/1.2 Figtree,sans-serif;margin:8px 10px 6px}
.notifs ul{list-style:none;margin:0;padding:0}
.notifs li{padding:10px 10px;border-top:1px solid var(--trait);font-size:15px;line-height:1.4}
.notifs li.neuve{background:#FFF7DC}
.notifs li time{display:block;color:var(--doux);font-size:13px;margin-top:2px}

/* ---------- boutons, champs ---------- */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;font:700 16px/1.15 Figtree,sans-serif;min-height:46px;padding:10px 18px;border-radius:12px;border:0;background:var(--jaune);color:var(--encre);box-shadow:0 3px 0 #A97F0E;cursor:pointer;text-decoration:none;text-align:center}
.btn:hover{background:#F6CA4C}
.btn:active{transform:translateY(2px);box-shadow:0 1px 0 #A97F0E}
.btn:disabled{background:#E3DCCC;color:#5D625B;box-shadow:0 3px 0 #BDB39C;cursor:not-allowed;transform:none}
.btn-gros{font-size:19px;min-height:56px;padding:14px 28px;border-radius:14px}
.btn2{display:inline-flex;align-items:center;justify-content:center;gap:8px;font:600 15px/1.15 Figtree,sans-serif;min-height:44px;padding:9px 15px;border-radius:11px;border:1.5px solid var(--encre);background:var(--surface);color:var(--encre);cursor:pointer;text-decoration:none;text-align:center}
.btn2:hover{background:#fff}
.btn2:disabled{opacity:.55;cursor:not-allowed}
.jeu .btn2{background:transparent;color:var(--creme);border-color:#8FB5A4}
.jeu .btn2:hover{background:#2F6A53}
.btn-danger{border-color:var(--rouge);color:#A31F18}
.btn-danger:hover{background:#FBEDEB}
.btn-plein-danger{display:inline-flex;align-items:center;justify-content:center;font:700 15px/1.15 Figtree,sans-serif;min-height:44px;padding:9px 16px;border-radius:11px;border:0;background:#A31F18;color:#fff;cursor:pointer}
.btn-plein-danger:hover{background:#8A1913}
.lien44{display:inline-flex;align-items:center;min-height:44px}
.btn-lien{background:none;border:0;padding:8px 4px;min-height:44px;font:600 15px Figtree,sans-serif;color:var(--encre);text-decoration:underline;text-underline-offset:3px;cursor:pointer}
input[type=email],input[type=text],input[type=search],input[type=number],select{font:16px Figtree,sans-serif;min-height:46px;padding:10px 12px;border-radius:11px;border:1.5px solid #8C8574;background:var(--surface);color:var(--encre);width:100%}
input:focus-visible,select:focus-visible{outline:3px solid var(--encre);outline-offset:1px}
select{padding-right:34px;appearance:none;-webkit-appearance:none;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%231F2421' stroke-width='2'/%3E%3C/svg%3E");background-repeat:no-repeat;background-position:right 12px center;background-size:12px 8px}
label{font-weight:700}
.champ{display:flex;flex-direction:column;gap:6px}
.champ>span{font:700 14px/1.2 Figtree,sans-serif;color:var(--doux)}
.case{display:flex;align-items:center;gap:10px;min-height:44px;font-weight:600;cursor:pointer}
.case input{width:22px;height:22px;flex:none;accent-color:var(--vert);margin:0}
.msg{min-height:1.4em;margin:8px 0 0;font-weight:600}
.msg.erreur{color:#A31F18}
.jeu .msg.erreur{color:#FFD5CF}
.msg.ok{color:var(--vert)}
.jeu .msg.ok{color:var(--jaune)}
.puces{display:flex;flex-wrap:wrap;gap:8px}
.puces label{position:relative;display:inline-flex}
.puces input{position:absolute;opacity:0;inset:0;margin:0;cursor:pointer}
.puces span{display:inline-flex;align-items:center;min-height:44px;padding:8px 14px;border-radius:999px;border:1.5px solid #8C8574;background:var(--surface);font:600 15px/1 Figtree,sans-serif;cursor:pointer}
.puces input:checked+span{background:var(--vert);border-color:var(--vert);color:#fff}
.puces input:focus-visible+span{outline:3px solid var(--encre);outline-offset:2px}

/* ---------- titres d'écran, onglets internes ---------- */
.tete-ecran{display:flex;flex-wrap:wrap;align-items:end;justify-content:space-between;gap:10px 24px;margin-bottom:18px}
.tete-ecran h1{font-size:clamp(30px,4.4vw,46px)}
.tete-ecran p{margin:0;color:var(--doux)}
.jeu .tete-ecran p{color:var(--creme2)}
.sous-onglets{display:flex;flex-wrap:wrap;gap:6px;margin:0 0 18px;padding:4px;border-radius:14px;background:var(--papier2);width:max-content;max-width:100%}
.sous-onglets a,.sous-onglets button{display:inline-flex;align-items:center;gap:6px;min-height:44px;padding:8px 16px;border-radius:10px;border:0;background:transparent;font:600 15px/1 Figtree,sans-serif;color:var(--doux);text-decoration:none;cursor:pointer}
.sous-onglets [aria-current="page"],.sous-onglets [aria-selected="true"]{background:var(--surface);color:var(--encre);box-shadow:0 1px 0 rgba(31,36,33,.12),0 0 0 1px var(--trait)}
.sous-onglets .n{font-variant-numeric:tabular-nums;background:var(--papier2);border-radius:999px;padding:2px 7px;font-size:13px;color:var(--encre)}
.vide{background:var(--surface);border:1.5px dashed var(--trait);border-radius:16px;padding:22px;text-align:center;color:var(--doux)}
.vide p{margin:0 auto 12px}
.chargement{color:var(--doux);padding:24px 0}

/* ---------- accueil ---------- */
.accueil{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.55fr);gap:32px 40px;align-items:center}
.accueil .chapo{font-size:clamp(17px,1.6vw,20px);color:var(--doux);margin:16px 0 24px;max-width:46ch}
.connexion{background:var(--surface);border:1px solid var(--trait);border-radius:18px;padding:20px;max-width:520px;box-shadow:0 10px 30px -18px rgba(40,34,20,.45)}
.connexion .ligne{display:flex;gap:10px;flex-wrap:wrap}
.connexion .ligne input{flex:1 1 220px}
.connexion h2{font-size:24px;margin-bottom:8px}
.connexion .lien-dev{display:block;margin-top:10px;padding:10px 12px;border-radius:10px;background:#FFF7DC;border:1px dashed #A97F0E;overflow-wrap:anywhere;font-size:15px}
.vedettes{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;align-items:start}
.vedettes .carte{max-width:none}
.vedettes>:nth-child(2){margin-top:34px}
.principe{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}
.principe>div{background:var(--vert2);border:1px solid var(--vert3);border-radius:16px;padding:16px 18px}
.principe h3{color:#fff}
.principe p{color:var(--creme2);font-size:15px;margin:0}
.taux{display:flex;flex-wrap:wrap;gap:8px;margin-top:16px;align-items:center}
.taux .brille{position:static}
.pied-site{border-top:1px solid var(--trait);background:rgba(186,171,135,.2)}
.pied-site .in{display:flex;flex-wrap:wrap;gap:6px 22px;align-items:center;justify-content:space-between;font-size:14px;color:var(--doux)}
.pied-site a{display:inline-flex;align-items:center;min-height:44px}

/* ---------- pseudo ---------- */
.carton{max-width:560px;margin:0 auto;background:var(--surface);border:1px solid var(--trait);border-radius:18px;padding:24px}
.carton h1{font-size:clamp(28px,4vw,40px);margin-bottom:10px}

/* ---------- packs ---------- */
.table-packs{min-height:calc(100vh - 64px);overflow-x:clip}
.reserve{display:flex;flex-wrap:wrap;align-items:center;gap:8px 16px;color:var(--creme2);font-size:15px}
.reserve .fioles{display:flex;gap:4px}
.reserve .fioles i{display:block;width:14px;height:20px;border-radius:3px;background:#2F6A53;box-shadow:inset 0 0 0 1.5px #5E8E7A}
.reserve .fioles i.plein{background:var(--jaune);box-shadow:inset 0 0 0 1.5px #A97F0E,0 2px 0 #0F2C22}
.reserve b{color:#fff;font-variant-numeric:tabular-nums}
.scene{display:flex;flex-direction:column;align-items:center;gap:22px;padding:18px 0 8px}
.sachet{position:relative;width:212px;height:292px;border:0;padding:0;cursor:pointer;background:none;filter:drop-shadow(0 18px 18px rgba(0,0,0,.35))}
.sachet:disabled{cursor:default}
.sachet .corps{position:absolute;inset:0;border-radius:10px;overflow:hidden;
  background:linear-gradient(115deg,rgba(255,255,255,0) 30%,rgba(255,255,255,.28) 45%,rgba(255,255,255,0) 60%),linear-gradient(170deg,#2E6B53,#1A4033 70%,#122E25);
  box-shadow:inset 0 0 0 2px rgba(242,190,43,.7),inset 0 0 0 7px #1A4033,inset 0 0 0 8.5px rgba(255,255,255,.25)}
.sachet .corps::before,.sachet .corps::after{content:"";position:absolute;left:0;right:0;height:16px;background:repeating-linear-gradient(90deg,rgba(255,255,255,.22) 0 3px,rgba(0,0,0,.12) 3px 6px)}
.sachet .corps::before{top:0}
.sachet .corps::after{bottom:0}
.sachet .languette{position:absolute;left:0;right:0;top:0;height:30px;border-bottom:2px dashed rgba(255,255,255,.45);z-index:2}
.sachet .contenu{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px;color:#fff;text-align:center}
.sachet .contenu .rp{width:96px;height:96px;filter:drop-shadow(0 4px 0 rgba(0,0,0,.3))}
.sachet .contenu b{display:block;background:var(--jaune);color:var(--encre);font:700 21px/1.02 "Barlow Condensed",sans-serif;text-transform:uppercase;padding:6px 12px 5px;border-radius:4px;box-shadow:0 0 0 1.5px var(--encre),0 2px 0 rgba(0,0,0,.3)}
.sachet .contenu small{font:700 16px/1 "Barlow Condensed",sans-serif;letter-spacing:.02em;color:var(--creme)}
.sachet.ouvre{animation:secoue .42s ease-in-out}
.sachet.ouvre .languette{animation:dechire .45s .38s ease-in forwards}
.sachet.parti{animation:descend .4s ease-in forwards}
@keyframes secoue{0%,100%{transform:none}20%{transform:rotate(-4deg)}40%{transform:rotate(4deg)}60%{transform:rotate(-3deg)}80%{transform:rotate(2deg)}}
@keyframes dechire{to{transform:translate(40px,-70px) rotate(24deg);opacity:0}}
@keyframes descend{to{transform:translateY(60px) scale(.9);opacity:0}}
.tirage{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:16px;width:100%;align-items:stretch}
.volte{position:relative;display:grid;perspective:1100px;animation:distribue .5s cubic-bezier(.2,1,.4,1) backwards;animation-delay:calc(var(--i) * 90ms)}
.volte-in{position:relative;display:grid;transition:transform .34s cubic-bezier(.2,1.35,.45,1)}
.volte-in>*{grid-area:1/1}
.volte .recto{display:flex;position:relative}
.volte .recto>.clic{position:absolute;inset:0;z-index:5;border:0;background:transparent;border-radius:18px;cursor:pointer}
.volte .recto>.clic:focus-visible{outline:3px solid var(--jaune);outline-offset:3px}
.volte:not(.retournee) .recto{visibility:hidden}
.volte.retournee .dos{visibility:hidden}
.volte.tourne .volte-in{transform:rotateY(90deg) scale(1.05);transition:transform .22s ease-in}
.volte .dos{cursor:pointer;min-height:100%}
.volte.tension .dos{animation:tremble .55s ease-in-out infinite}
.volte.eclat::before{content:"";position:absolute;inset:-22%;z-index:-1;border-radius:50%;background:radial-gradient(closest-side,var(--halo,rgba(242,190,43,.85)),rgba(242,190,43,0));animation:halo 1.6s ease-out forwards}
.volte.eclat .volte-in{animation:sursaut .6s ease-out}
.volte.eclat.brillante-tiree .carte{--sx:0%;animation:reflet 1.4s .1s ease-in-out}
@property --sx{syntax:"<percentage>";inherits:true;initial-value:30%}
@keyframes reflet{from{--sx:0%}to{--sx:100%}}
/* pile façon WikiMasters : cartes empilées, on tape sur celle du dessus */
.pile-scene{display:flex;flex-direction:column;align-items:center;gap:16px;width:100%}
.pile{position:relative;display:grid;width:min(300px,82vw);margin:6px 0 10px}
.pile>.pile-carte{grid-area:1/1;transform:translate(calc(var(--d,0) * 6px),calc(var(--d,0) * 7px)) rotate(calc(var(--d,0) * 1.6deg));transition:transform .25s ease}
.pile>.pile-carte .carte{max-width:none}
.pile>.pile-carte.sortie{transform:translate(115%,-14px) rotate(14deg);opacity:0;transition:transform .26s ease-in,opacity .26s ease-in}
.pile-tap{position:absolute;inset:0;z-index:40;border:0;background:transparent;border-radius:18px;cursor:pointer;-webkit-tap-highlight-color:transparent}
.pile-tap:focus-visible{outline:3px solid var(--jaune);outline-offset:5px}
.pile-aide{margin:0;min-height:1.5em;max-width:34em;text-align:center;color:#F3EEE3;font:600 16px/1.45 Figtree,sans-serif}
.pile-vues{display:flex;flex-wrap:wrap;justify-content:center;gap:8px;min-height:0}
.pile-vu{border:0;background:transparent;padding:0;min-height:44px;cursor:pointer;display:inline-flex;align-items:center}
.pile-vu:focus-visible{outline:3px solid var(--jaune);outline-offset:2px;border-radius:20px}
.pile-scene{overflow-x:clip;padding-bottom:8px}
@media(max-width:600px){
  .pile{width:min(260px,68vw);margin:2px 0 6px}
  .pile>.pile-carte{transform:translate(calc(var(--d,0) * 4px),calc(var(--d,0) * 5px)) rotate(calc(var(--d,0) * 1deg))}
  .pile-aide{font-size:15px;min-height:1.5em;order:-1}
}
@keyframes distribue{from{transform:translateY(-46px) rotate(-7deg) scale(.92);opacity:0}}
@keyframes tremble{0%,100%{transform:none}25%{transform:translateX(-3px) rotate(-1.2deg)}75%{transform:translateX(3px) rotate(1.2deg)}}
@keyframes halo{0%{opacity:0;transform:scale(.6)}35%{opacity:1}100%{opacity:.55;transform:scale(1.05)}}
@keyframes sursaut{0%{transform:scale(1)}40%{transform:scale(1.07)}100%{transform:scale(1)}}
.tirage .carte{max-width:none}
.tirage .art{height:132px}
.resume{display:flex;flex-direction:column;align-items:center;gap:14px;text-align:center}
.resume p{margin:0;font:700 clamp(19px,2vw,23px)/1.3 Fraunces,Georgia,serif;color:#fff;max-width:40ch}
.resume .boutons{display:flex;flex-wrap:wrap;gap:12px;justify-content:center}
.btn-passer{min-height:44px}

/* ---------- grilles de cartes ---------- */
.outils{display:grid;grid-template-columns:minmax(0,2fr) repeat(3,minmax(0,1fr));gap:10px 12px;align-items:end;margin-bottom:10px}
.cases{display:flex;flex-wrap:wrap;gap:0 18px;align-items:center;margin-bottom:12px}
.compteur{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px 18px;margin:6px 0 18px;color:var(--doux);font-size:15px}
.compteur b{color:var(--encre)}
.grille-cartes{display:grid;grid-template-columns:repeat(auto-fill,minmax(168px,1fr));gap:22px 14px}
.tuile{position:relative;display:flex}
.tuile>.clic{position:absolute;inset:0;z-index:5;border:0;background:transparent;border-radius:15px;cursor:pointer}
.tuile>.clic:focus-visible{outline:3px solid var(--encre);outline-offset:3px}
.tuile .pied .etat-ex{font-weight:700;color:var(--encre)}
.plus{display:flex;justify-content:center;margin-top:24px}

/* ---------- carte de France ---------- */
.fr-bloc{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);gap:22px 32px;align-items:start}
.fr-carte{position:relative;background:var(--surface);border:1px solid var(--trait);border-radius:18px;padding:12px}
.france{display:block;width:100%;height:auto}
.fr-deps path{stroke:#FBF8F1;stroke-width:1.3;stroke-linejoin:round;cursor:pointer}
.fr-deps path:hover{stroke:var(--encre);stroke-width:2}
.fr-manque{fill:none;stroke:rgba(31,36,33,.14);stroke-width:2.1;stroke-linecap:round;pointer-events:none}
.fr-a-ombre{fill:none;stroke:#FBF8F1;stroke-width:7.5;stroke-linecap:round;pointer-events:none}
.fr-a{fill:none;stroke:var(--rouge);stroke-width:5;stroke-linecap:round;pointer-events:none}
.fr-sel{fill:none;stroke:var(--encre);stroke-width:3;stroke-linejoin:round;pointer-events:none}
.fr-legende{list-style:none;margin:10px 0 0;padding:0;display:flex;flex-wrap:wrap;gap:6px 14px;font-size:14px;color:var(--doux)}
.fr-legende li{display:inline-flex;align-items:center;gap:6px}
.fr-legende i{display:inline-block;width:16px;height:12px;border-radius:3px;box-shadow:0 0 0 1px rgba(31,36,33,.2)}
.fr-legende i.pt-a{width:9px;height:9px;border-radius:50%;background:var(--rouge);box-shadow:0 0 0 2px #FBF8F1}
.fr-legende i.pt-m{width:6px;height:6px;border-radius:50%;background:rgba(31,36,33,.3);box-shadow:none}
.fr-source{font-size:13px;color:var(--doux);margin:8px 0 0}
.bulle{position:absolute;z-index:6;pointer-events:none;background:var(--encre);color:#fff;font:600 14px/1.35 Figtree,sans-serif;padding:7px 10px;border-radius:8px;white-space:nowrap;transform:translate(-50%,calc(-100% - 12px))}
.fr-panneau{background:var(--surface);border:1px solid var(--trait);border-radius:18px;padding:18px}
.fr-panneau h2{font-size:26px;margin-bottom:4px}
.fr-zoom{display:block;width:100%;max-height:300px;margin:10px 0}
.dep-fond{fill:#EFEADD;stroke:#B9AE95;stroke-width:1;vector-effect:non-scaling-stroke}
.dep-manque circle{fill:rgba(31,36,33,.2)}
.dep-a{fill:var(--rouge);stroke:#FBF8F1;stroke-width:var(--r);cursor:pointer}
.barre-prog{height:10px;border-radius:999px;background:var(--papier2);overflow:hidden;box-shadow:inset 0 0 0 1px rgba(31,36,33,.12)}
.barre-prog i{display:block;height:100%;background:var(--vert);border-radius:999px;min-width:0}
.listes-dep{display:grid;gap:14px;margin-top:14px}
.listes-dep h3{font-size:16px;margin:0 0 6px}
.noms{list-style:none;margin:0;padding:0;columns:2 150px;column-gap:16px;font-size:14px}
.noms li{break-inside:avoid;display:flex;align-items:center;gap:6px;padding:2px 0;line-height:1.3}
.noms .gem{width:9px;height:9px}
.noms button{display:inline-flex;align-items:center;gap:6px;min-height:44px;padding:2px 0;border:0;background:none;font:600 14px Figtree,sans-serif;color:var(--encre);text-align:left;cursor:pointer;text-decoration:underline;text-underline-offset:3px}
.noms.manquent li{color:var(--doux)}
.deroule{max-height:340px;overflow:auto;padding-right:4px}
.choix-dep{display:flex;flex-wrap:wrap;gap:10px;align-items:end;margin-bottom:12px}
.choix-dep .champ{flex:1 1 220px}
.outremer{margin-top:28px}
.outremer ul{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:8px 18px}
.outremer li button{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:4px 10px;width:100%;min-height:44px;padding:8px 10px;border:1px solid var(--trait);border-radius:12px;background:var(--surface);font:600 15px Figtree,sans-serif;color:var(--encre);text-align:left;cursor:pointer}
.outremer li button:hover{border-color:var(--encre)}
.outremer li .barre-prog{grid-column:1/-1}
.outremer li small{font-size:13px;color:var(--doux);font-variant-numeric:tabular-nums}

/* ---------- fiche (détail d'une carte, d'une enchère) ---------- */
dialog.fiche{width:min(940px,calc(100vw - 24px));max-height:calc(100vh - 24px);padding:0;border:0;border-radius:20px;background:var(--papier);color:var(--encre);box-shadow:0 30px 80px -20px rgba(0,0,0,.5)}
dialog.fiche::backdrop{background:rgba(18,30,25,.62)}
.fiche-in{display:grid;grid-template-columns:300px minmax(0,1fr);gap:24px 30px;padding:26px}
.fiche-carte{display:flex;justify-content:center}
.fermer{position:absolute;right:10px;top:10px;z-index:3;width:44px;height:44px;border-radius:999px;border:0;background:var(--surface);box-shadow:0 0 0 1px var(--trait);cursor:pointer;display:inline-flex;align-items:center;justify-content:center}
.fermer svg{width:18px;height:18px}
.fiche-infos h2{font-size:clamp(26px,3vw,34px);margin:0 40px 8px 0}
.ligne-infos{display:flex;flex-wrap:wrap;gap:6px 12px;align-items:center;color:var(--doux);font-size:15px;margin-bottom:12px}
.encadre{background:var(--surface);border:1px solid var(--trait);border-radius:14px;padding:14px 16px;margin:12px 0}
.encadre h3{font-size:17px}
.exemplaires{list-style:none;margin:0;padding:0}
.exemplaires li{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px 12px;padding:10px 0;border-top:1px solid var(--trait)}
.exemplaires li:first-child{border-top:0}
.exemplaires li.choisi .qui{font-weight:700}
.exemplaires .qui{font-size:15px}
.exemplaires .qui small{display:block;color:var(--doux);font-size:13px}
.exemplaires .actions{display:flex;flex-wrap:wrap;gap:6px}
.etiquette{display:inline-flex;align-items:center;padding:3px 9px;border-radius:999px;font:700 13px/1.25 Figtree,sans-serif;background:var(--papier2);color:var(--encre);white-space:nowrap}
.etiquette.vente{background:#FDE7C9;color:#6B3500}
.etiquette.echange{background:#DCE9F5;color:#1D3F5E}
.etiquette.mene{background:#D8EBDD;color:#1B4A33}
.etiquette.battu{background:#FBE0DC;color:#8A1913}
.formulaire{display:grid;gap:12px}
.formulaire .rangee{display:flex;flex-wrap:wrap;gap:10px;align-items:end}
.formulaire .rangee .champ{flex:1 1 140px}
.historique{list-style:none;margin:0;padding:0;font-size:15px}
.historique li{display:flex;justify-content:space-between;gap:10px;padding:7px 0;border-top:1px solid var(--trait)}
.historique li:first-child{border-top:0}
.historique time{color:var(--doux);font-size:14px}

/* ---------- marché ---------- */
.lots{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:24px 16px}
.lot{display:flex;flex-direction:column;gap:10px}
.lot .tuile .carte{max-width:none}
.lot-infos{display:grid;gap:6px;font-size:15px}
.lot-prix{display:flex;justify-content:space-between;align-items:baseline;gap:8px}
.lot-prix b{font-size:19px}
.lot-prix small,.lot-meta{color:var(--doux);font-size:14px}
.termines{margin-top:28px}
.termines h2{font-size:24px}
.lot-fin{font-weight:700;font-variant-numeric:tabular-nums}
.lot-infos .etiquette{justify-self:start;white-space:normal}
.lot-fin.bientot{color:#A31F18}
.miser{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px}
.miser input{min-width:0;padding-inline:10px}
.pages{display:flex;flex-wrap:wrap;justify-content:center;align-items:center;gap:12px;margin-top:24px}

/* ---------- échanges ---------- */
.deux-col{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.35fr);gap:24px 32px;align-items:start}
.bloc{background:var(--surface);border:1px solid var(--trait);border-radius:18px;padding:18px}
.bloc+.bloc{margin-top:18px}
.bloc h2{font-size:24px;margin-bottom:10px}
.bloc h3{font-size:16px;margin:14px 0 6px}
.gens{list-style:none;margin:0;padding:0}
.gens li{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px;padding:8px 0;border-top:1px solid var(--trait)}
.gens li:first-child{border-top:0}
.gens .nom{font-weight:700;overflow-wrap:anywhere}
.gens .actions{display:flex;flex-wrap:wrap;gap:6px}
.ajout{display:flex;gap:8px;flex-wrap:wrap}
.ajout input{flex:1 1 180px}
.echange{border:1px solid var(--trait);border-radius:14px;padding:14px;background:#fff}
.echange+.echange{margin-top:12px}
.echange .entete{display:flex;flex-wrap:wrap;justify-content:space-between;gap:6px 12px;margin-bottom:10px}
.echange .entete b{overflow-wrap:anywhere}
.echange .cotes{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px}
.echange .cote h4{margin:0 0 6px;font:700 14px/1.2 Figtree,sans-serif;color:var(--doux)}
.puce-carte{display:flex;align-items:center;gap:6px;font-size:14px;padding:3px 0;line-height:1.3}
.puce-carte .gem{width:9px;height:9px}
.puce-carte .rp{width:16px;height:16px}
.puce-carte em{font-style:normal;font-weight:700;font-size:13px;color:#5A3E91}
.echange .actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px}
.composer .cotes{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:18px}
.choix-cartes{list-style:none;margin:8px 0 0;padding:0;max-height:420px;overflow:auto;border:1px solid var(--trait);border-radius:12px;background:#fff}
.choix-cartes li{border-top:1px solid #ECE6D8}
.choix-cartes li:first-child{border-top:0}
.choix-cartes label{display:flex;align-items:center;gap:10px;min-height:46px;padding:6px 12px;font-weight:500;font-size:15px;cursor:pointer}
.choix-cartes label:hover{background:#F8F4EA}
.choix-cartes input{width:20px;height:20px;flex:none;accent-color:var(--vert);margin:0}
.choix-cartes .nom{flex:1;overflow-wrap:anywhere}
.choix-cartes small{color:var(--doux);font-size:13px;white-space:nowrap}
.recap{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:12px;margin-top:16px;padding-top:14px;border-top:1px solid var(--trait)}

/* ---------- profil ---------- */
.chiffres{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin-bottom:18px}
.chiffres>div{background:var(--surface);border:1px solid var(--trait);border-radius:14px;padding:14px 16px}
.chiffres b{display:flex;align-items:center;gap:6px;font:800 clamp(24px,3vw,32px)/1.1 Fraunces,Georgia,serif;font-variant-numeric:tabular-nums}
.chiffres span{color:var(--doux);font-size:14px}
.paliers{list-style:none;margin:0;padding:0;display:grid;gap:12px}
.paliers li{display:grid;grid-template-columns:150px minmax(0,1fr) auto;gap:6px 14px;align-items:center;font-size:15px}
.paliers .pal{justify-self:start}
.paliers small{color:var(--doux);font-variant-numeric:tabular-nums;font-size:14px}
.zone-danger{border-color:#E3B5AF}

/* ---------- message flottant ---------- */
.toast{position:fixed;left:50%;bottom:24px;z-index:50;transform:translateX(-50%);max-width:min(520px,calc(100vw - 24px));background:var(--encre);color:#fff;font:600 15px/1.4 Figtree,sans-serif;padding:12px 18px;border-radius:12px;box-shadow:0 12px 30px -10px rgba(0,0,0,.5)}
.toast.erreur{background:#8A1913}

/* ---------- pages simples (mentions, confidentialité) ---------- */
.page-texte{max-width:760px}
.page-texte h1{font-size:clamp(30px,4vw,44px);margin-bottom:14px}
.page-texte h2{font-size:24px;margin:26px 0 8px}

/* ---------- téléphone ---------- */
@media(max-width:1120px) and (min-width:761px){
  .logo span{display:none}
}
@media(max-width:980px) and (min-width:761px){
  .pseudo-barre{display:none}
  .onglets a span{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}
  .onglets a{padding:8px 11px}
}
@media(max-width:1000px){
  .principe{grid-template-columns:repeat(2,minmax(0,1fr))}
  .outils{grid-template-columns:repeat(2,minmax(0,1fr))}
  .outils .champ-q{grid-column:1/-1}
  .chiffres{grid-template-columns:repeat(2,minmax(0,1fr))}
  .tirage{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media(max-width:860px){
  .accueil{grid-template-columns:minmax(0,1fr)}
  .fr-bloc,.deux-col,.fiche-in{grid-template-columns:minmax(0,1fr)}
  .fiche-carte .carte{max-width:300px}
}
@media(max-width:760px){
  html{scroll-padding-top:70px}
  body{padding-bottom:calc(68px + env(safe-area-inset-bottom))}
  .barre .in{min-height:56px;gap:6px 8px}
  .logo span{display:none}
  .logo .rp{width:34px;height:34px}
  .pseudo-barre{display:none}
  .etat{gap:6px}
  .etat .solde,.etat .reserve-mini{padding:4px 10px;font-size:15px}
  .reserve-mini small{display:none}
  .reserve-mini.attente small{display:inline}
  .onglets{position:fixed;left:0;right:0;bottom:0;z-index:30;justify-content:space-around;gap:0;padding:4px 2px calc(4px + env(safe-area-inset-bottom));background:var(--surface);border-top:1px solid var(--trait);box-shadow:0 -8px 20px -14px rgba(31,36,33,.4)}
  .onglets a{flex:1 1 0;flex-direction:column;gap:3px;padding:6px 2px;min-height:56px;font-size:13px;border-radius:10px;position:relative}
  .onglets a svg{width:22px;height:22px}
  .onglets a[aria-current="page"]{box-shadow:none;background:var(--papier2)}
  .onglets a .pastille-nav{display:block;position:absolute;top:4px;right:calc(50% - 18px);width:10px;height:10px;border-radius:50%;background:var(--rouge);box-shadow:0 0 0 2px var(--surface)}
  .onglets a .pastille-nav[hidden]{display:none}
  .notifs{top:54px}
  /* les trois vedettes défilent dans leur propre bande : la page, elle, ne défile pas de côté */
  .vedettes{grid-template-columns:none;grid-auto-flow:column;grid-auto-columns:82%;overflow-x:auto;scroll-snap-type:x mandatory;padding:4px 4px 18px;margin-inline:-4px;scrollbar-width:thin}
  .vedettes>*{scroll-snap-align:center}
  .vedettes>:nth-child(2){margin-top:0}
  .principe{grid-template-columns:minmax(0,1fr)}
  .tirage{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px 12px}
  .tirage>.volte:last-child{grid-column:1/-1;justify-self:center;width:min(100%,230px)}
  .grille-cartes{grid-template-columns:repeat(2,minmax(0,1fr));gap:18px 12px}
  .lots{grid-template-columns:repeat(2,minmax(0,1fr));gap:20px 12px}
  .miser{grid-template-columns:minmax(0,1fr)}
  .composer .cotes,.echange .cotes{grid-template-columns:minmax(0,1fr)}
  .paliers li{grid-template-columns:minmax(0,1fr) auto}
  .paliers li .barre-prog{grid-column:1/-1;grid-row:2}
  dialog.fiche{width:100vw;max-width:100vw;max-height:100dvh;height:100dvh;margin:0;border-radius:0}
  .fiche-in{padding:18px 16px 28px}
  .toast{bottom:calc(80px + env(safe-area-inset-bottom))}
  .sous-onglets{width:100%}
  .sous-onglets a,.sous-onglets button{flex:1 1 auto;justify-content:center;padding:8px 10px}
}
@media(max-width:420px){
  .etat .solde .lib,.reserve-mini .lib{display:none}
}
@media(prefers-reduced-motion:reduce){
  .pile>.pile-carte,.pile>.pile-carte.sortie,.volte,.volte-in,.volte.eclat::before,.volte.eclat .volte-in,.volte.tension .dos,.sachet.ouvre,.sachet.ouvre .languette,.sachet.parti,.volte.eclat.brillante-tiree .carte{animation:none!important;transition:none!important}
}
