/* Ask To Boss — « affiche de gala » : papier blanc bleuté, encre marine, bleu du club, tampons ;
   titres en capitales étroites, comme sur une affiche de combat. */
@font-face { font-family: 'Archivo'; src: url(/polices/archivo.woff2) format('woff2-variations'), url(/polices/archivo.woff2) format('woff2');
  font-weight: 100 900; font-stretch: 62% 125%; font-display: swap; }
@font-face { font-family: 'Plex Mono'; src: url(/polices/plex-mono-500.woff2) format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Plex Mono'; src: url(/polices/plex-mono-600.woff2) format('woff2'); font-weight: 600; font-display: swap; }

:root {
  --papier: #f2f5fd; --papier-2: #e3e9f9; --carte: #ffffff; --carte-2: #f5f8fe;
  --encre: #0d1b3e; --encre-2: #3c4a6e; --encre-3: #667191; --ligne: rgba(13, 27, 62, .12); --ligne-forte: rgba(13, 27, 62, .26);
  /* le bleu du club (relevé sur son logo), et ses déclinaisons */
  --marque: #2a64f6; --marque-vif: #3f74ff; --marque-fonce: #1845c4; --marque-pale: #e1eaff; --marque-texte: #1d50dc; --marque-clair: #9db9ff; --marque-titre: #2a64f6;
  /* les couleurs qui disent quelque chose : victoire, refus, attente, repos */
  --vert: #157347; --vert-pale: #daf1e4; --rouge: #cf3628; --rouge-fonce: #a3271c; --rouge-pale: #fde5e1; --rouge-texte: #a3271c;
  --orange: #a35c00; --orange-pale: #fdeed2; --gris: #5d6885; --gris-pale: #e8ecf5;
  /* les surfaces sombres (bandeau de la Boss, affiche, messages) et la lumière du tableau d'affichage */
  --nuit: #0d1b3e; --sur-nuit: #f2f5fd; --sur-nuit-2: rgba(242, 245, 253, .66); --trait-nuit: rgba(242, 245, 253, .24); --lumiere: #ffc93c;
  --point: rgba(13, 27, 62, .05);
  --ombre: 0 1px 0 rgba(13, 27, 62, .05), 0 10px 30px -12px rgba(13, 27, 62, .24);
  --ombre-ticket: rgba(13, 27, 62, .2);
  --rayon: 18px; --mono: 'Plex Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  --texte: 'Archivo', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --papier: #0a1124; --papier-2: #131c38; --carte: #151f3f; --carte-2: #1b274c;
    --encre: #eef2ff; --encre-2: #bcc6e4; --encre-3: #8c96b8; --ligne: rgba(238, 242, 255, .11); --ligne-forte: rgba(238, 242, 255, .27);
    --marque: #2a64f6; --marque-vif: #4a7dff; --marque-fonce: #163a9e; --marque-pale: #1a2c5e; --marque-texte: #9db9ff; --marque-clair: #9db9ff; --marque-titre: #5a88ff;
    --vert: #5fd49a; --vert-pale: #163529; --rouge: #ff7566; --rouge-fonce: #a82f22; --rouge-pale: #3d1f22; --rouge-texte: #ffb9af;
    --orange: #f3b04e; --orange-pale: #3a2d16; --gris: #a3acc8; --gris-pale: #232c47;
    --nuit: #1c284d; --sur-nuit: #eef2ff; --sur-nuit-2: rgba(238, 242, 255, .64); --trait-nuit: rgba(238, 242, 255, .22); --lumiere: #ffc93c;
    --point: rgba(238, 242, 255, .04);
    --ombre: 0 1px 0 rgba(0, 0, 0, .2), 0 12px 30px -14px rgba(0, 0, 0, .7);
    --ombre-ticket: rgba(0, 0, 0, .5);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --papier: #0a1124; --papier-2: #131c38; --carte: #151f3f; --carte-2: #1b274c;
  --encre: #eef2ff; --encre-2: #bcc6e4; --encre-3: #8c96b8; --ligne: rgba(238, 242, 255, .11); --ligne-forte: rgba(238, 242, 255, .27);
  --marque: #2a64f6; --marque-vif: #4a7dff; --marque-fonce: #163a9e; --marque-pale: #1a2c5e; --marque-texte: #9db9ff; --marque-clair: #9db9ff; --marque-titre: #5a88ff;
  --vert: #5fd49a; --vert-pale: #163529; --rouge: #ff7566; --rouge-fonce: #a82f22; --rouge-pale: #3d1f22; --rouge-texte: #ffb9af;
  --orange: #f3b04e; --orange-pale: #3a2d16; --gris: #a3acc8; --gris-pale: #232c47;
  --nuit: #1c284d; --sur-nuit: #eef2ff; --sur-nuit-2: rgba(238, 242, 255, .64); --trait-nuit: rgba(238, 242, 255, .22); --lumiere: #ffc93c;
  --point: rgba(238, 242, 255, .04);
  --ombre: 0 1px 0 rgba(0, 0, 0, .2), 0 12px 30px -14px rgba(0, 0, 0, .7);
  --ombre-ticket: rgba(0, 0, 0, .5);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--papier); color: var(--encre); font-family: var(--texte); font-size: 17px; line-height: 1.5;
  font-weight: 430; -webkit-font-smoothing: antialiased;
  background-image: radial-gradient(var(--point) 1px, transparent 1px); background-size: 14px 14px;
  min-height: 100vh; padding-top: env(safe-area-inset-top); padding-bottom: env(safe-area-inset-bottom);
}
a { color: inherit; }
button, input, textarea, select { font: inherit; color: inherit; }
/* Les titres : capitales étroites et grasses. */
h1, h2, h3 { margin: 0; font-stretch: 62%; font-weight: 800; text-transform: uppercase; line-height: 1; letter-spacing: .005em; text-wrap: balance; }
h1 { font-size: clamp(3rem, 11vw, 5.6rem); line-height: .92; }
h2 { font-size: clamp(1.9rem, 5vw, 2.6rem); }
h3 { font-size: 1.32rem; font-stretch: 68%; font-weight: 760; letter-spacing: .015em; }
p { margin: 0; }
.mono { font-family: var(--mono); font-weight: 500; letter-spacing: .02em; }
.etiquette { display: inline-block; font-family: var(--mono); font-weight: 600; font-size: .72rem; line-height: 1.5; letter-spacing: .12em; text-transform: uppercase; color: var(--encre-3); }
.discret { color: var(--encre-3); }
.petit { font-size: .88rem; }
.cache { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--marque-vif); outline-offset: 2px; border-radius: 6px; }

/* ---------- cadre ---------- */
.page { max-width: 1080px; margin: 0 auto; padding: 0 18px 64px; }
.barre { display: flex; align-items: center; gap: 12px; padding: 14px 0; }
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-stretch: 62%; font-weight: 820; text-transform: uppercase;
  letter-spacing: .01em; font-size: 1.5rem; line-height: 1; color: var(--marque-texte); }
.logo svg { width: 40px; height: 40px; flex: none; }
.logo small { white-space: nowrap; display: block; font-family: var(--mono); font-stretch: 100%; font-weight: 500; font-size: .62rem; letter-spacing: .14em; color: var(--encre-3); margin-top: 3px; }
.barre nav { margin-left: auto; display: flex; gap: 6px; align-items: center; }
.lien-barre { white-space: nowrap; text-decoration: none; padding: 8px 12px; border-radius: 999px; font-weight: 600; font-size: .95rem; display: inline-flex; gap: 6px; align-items: center; }
.lien-barre:hover { background: var(--papier-2); }
.pastille { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 999px; background: var(--marque); color: #fff; font-size: .75rem;
  font-family: var(--mono); font-weight: 600; display: inline-flex; align-items: center; justify-content: center; }
.pied { margin-top: 56px; padding-top: 22px; border-top: 1px dashed var(--ligne-forte); display: flex; flex-wrap: wrap; gap: 10px 22px;
  justify-content: space-between; color: var(--encre-3); font-size: .9rem; }
.pied a { color: var(--encre-2); }

/* ---------- boutons et champs ---------- */
.bouton { appearance: none; border: 0; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  border-radius: 999px; padding: 14px 24px; font-stretch: 76%; font-weight: 740; font-size: 1.04rem; letter-spacing: .035em; text-transform: uppercase; line-height: 1.2;
  background: var(--marque); color: #fff; box-shadow: 0 4px 0 var(--marque-fonce); transition: transform .08s, box-shadow .08s, background .15s; touch-action: manipulation; }
.bouton:hover { background: var(--marque-vif); }
.bouton:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--marque-fonce); }
.bouton[disabled] { opacity: .45; cursor: not-allowed; transform: none; box-shadow: 0 4px 0 var(--marque-fonce); }
.bouton.grand { padding: 18px 30px; font-size: 1.2rem; }
.bouton.second { background: var(--carte); color: var(--encre); box-shadow: 0 0 0 1.5px var(--ligne-forte) inset, 0 3px 0 var(--ligne-forte); }
.bouton.second:hover { background: var(--carte-2); }
.bouton.second:active { box-shadow: 0 0 0 1.5px var(--ligne-forte) inset, 0 0 0 var(--ligne-forte); }
.bouton.petit { padding: 9px 16px; font-size: .9rem; box-shadow: 0 2px 0 var(--marque-fonce); }
.bouton.second.petit { box-shadow: 0 0 0 1.5px var(--ligne-forte) inset, 0 2px 0 var(--ligne-forte); }
.bouton.fantome { background: transparent; color: var(--encre-2); box-shadow: none; padding: 9px 12px; }
.bouton.fantome:hover { background: var(--papier-2); }
.bouton.danger { background: transparent; color: var(--rouge); box-shadow: 0 0 0 1.5px currentColor inset; }
.rangee { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.champ { display: grid; gap: 6px; }
.champ > span, .legende { font-weight: 650; font-size: .95rem; }
.champ em, .aide { font-style: normal; color: var(--encre-3); font-size: .86rem; font-weight: 430; }
input[type=text], input[type=password], input[type=date], input[type=search], textarea, select {
  width: 100%; background: var(--carte); border: 1.5px solid var(--ligne-forte); border-radius: 12px; padding: 12px 14px; font-size: 1rem;
  transition: border-color .15s, box-shadow .15s; }
textarea { min-height: 120px; resize: vertical; line-height: 1.45; }
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--marque); box-shadow: 0 0 0 4px var(--marque-pale); }
input::placeholder, textarea::placeholder { color: var(--encre-3); opacity: .85; }
.case { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; padding: 12px 14px; border-radius: 12px; border: 1.5px dashed var(--ligne-forte); }
.case input { width: 22px; height: 22px; accent-color: var(--marque); margin: 1px 0 0; flex: none; }

/* ---------- cartes ---------- */
.carte { background: var(--carte); border: 1px solid var(--ligne); border-radius: var(--rayon); box-shadow: var(--ombre); padding: 22px; }
.carte + .carte { margin-top: 16px; }
.carte h2 + p, .carte h3 + p { margin-top: 6px; }
.grille { display: grid; gap: 16px; }

/* ---------- accueil ---------- */
.heros { display: grid; gap: 28px; align-items: center; padding: 26px 0 10px; }
@media (min-width: 860px) { .heros { grid-template-columns: 1.15fr .85fr; padding-top: 44px; } }
.heros .accroche { margin-top: 18px; font-size: 1.16rem; color: var(--encre-2); max-width: 32em; }
.heros h1 em { font-style: normal; color: var(--marque-titre); }
.heros .rangee { margin-top: 26px; }
.distributeur { display: block; width: min(330px, 78vw); margin: 0 auto; cursor: pointer; background: none; border: 0; padding: 0; }
.distributeur svg { width: 100%; height: auto; overflow: visible; }
.distributeur .languette { transition: transform .35s cubic-bezier(.3, 1.6, .5, 1); transform-origin: 50% 0; }
.distributeur:hover .languette, .distributeur:focus-visible .languette { transform: translateY(10px) rotate(-1.5deg); }
/* La fiche de la tireuse, comme au dos d'une affiche de gala. */
.affiche { position: relative; overflow: hidden; background: var(--nuit); color: var(--sur-nuit); border-radius: var(--rayon); padding: 26px 24px 24px; display: grid; gap: 20px; }
.affiche::before { content: ''; position: absolute; inset: 0; pointer-events: none;
  background-image: repeating-linear-gradient(-58deg, transparent 0 26px, rgba(42, 100, 246, .2) 26px 30px);
  -webkit-mask-image: linear-gradient(100deg, transparent 35%, #000); mask-image: linear-gradient(100deg, transparent 35%, #000); }
.affiche > * { position: relative; }
.affiche .etiquette { color: var(--sur-nuit-2); }
.affiche .nom { margin-top: 8px; font-stretch: 62%; font-weight: 850; text-transform: uppercase; font-size: clamp(2.3rem, 8vw, 3.7rem); line-height: .92; }
.affiche .nom em { font-style: normal; color: var(--marque-clair); }
.affiche dl { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 20px; }
@media (min-width: 760px) { .affiche dl { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.affiche dt { font-family: var(--mono); font-weight: 600; font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; color: var(--sur-nuit-2); }
.affiche dd { margin: 4px 0 0; font-weight: 640; line-height: 1.25; }
.humeur { display: flex; gap: 16px; align-items: center; margin-top: 16px; }
.humeur .emoji { font-size: 2.3rem; width: 64px; height: 64px; border-radius: 18px; background: var(--papier); display: grid; place-items: center; flex: none; }
.humeur strong { font-stretch: 68%; font-weight: 780; text-transform: uppercase; font-size: 1.6rem; line-height: 1.05; letter-spacing: .01em; }
.chiffres { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; margin-top: 18px; border-radius: var(--rayon); overflow: hidden;
  border: 1px solid var(--ligne); background: var(--carte); box-shadow: var(--ombre); }
@media (min-width: 760px) { .chiffres { grid-template-columns: repeat(4, 1fr); } }
.chiffre { padding: 18px 18px 16px; border-right: 1px dashed var(--ligne-forte); border-bottom: 1px dashed var(--ligne-forte); }
.chiffre b { display: block; font-stretch: 62%; font-weight: 820; font-variant-numeric: tabular-nums; font-size: 2.6rem; line-height: 1; margin: 8px 0 6px; color: var(--marque-texte); }
.chiffre b.long { font-size: 1.7rem; line-height: 1.05; padding: 7px 0; }
.chiffre span { font-size: .84rem; color: var(--encre-3); }
.etapes { display: grid; gap: 14px; counter-reset: e; margin-top: 18px; }
@media (min-width: 760px) { .etapes { grid-template-columns: repeat(3, 1fr); } }
.etape { counter-increment: e; padding: 18px; border-radius: var(--rayon); border: 1.5px dashed var(--ligne-forte); }
.etape::before { content: 'Reprise ' counter(e); font-family: var(--mono); font-weight: 600; font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--marque-texte); display: block; margin-bottom: 10px; }
.etape p { color: var(--encre-2); margin-top: 8px; font-size: .95rem; }
.section { margin-top: 44px; }
.section > .etiquette { display: block; margin-bottom: 10px; }
.chiffre .etiquette { display: block; }
.faq details { border-top: 1px dashed var(--ligne-forte); padding: 14px 2px; }
.faq details:last-child { border-bottom: 1px dashed var(--ligne-forte); }
.faq summary { cursor: pointer; font-weight: 650; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-family: var(--mono); color: var(--marque-texte); font-weight: 600; }
.faq details[open] summary::after { content: '–'; }
.faq details p { margin-top: 8px; color: var(--encre-2); max-width: 46em; }

/* ---------- formulaire ---------- */
.formulaire { display: grid; gap: 22px; margin-top: 10px; }
@media (min-width: 900px) { .formulaire { grid-template-columns: 1fr 330px; align-items: start; } .formulaire .cote { position: sticky; top: 16px; } }
.bloc { display: grid; gap: 16px; }
.bloc-titre { display: flex; gap: 12px; align-items: baseline; }
.bloc-titre .mono { color: var(--marque-texte); font-weight: 600; font-size: .9rem; }
.tuiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .tuiles { grid-template-columns: repeat(4, 1fr); } }
.tuile { position: relative; cursor: pointer; border: 1.5px solid var(--ligne-forte); border-radius: 14px; padding: 12px 12px 11px; background: var(--carte);
  display: grid; gap: 2px; align-content: start; text-align: left; transition: border-color .12s, background .12s, transform .12s; min-height: 92px; }
.tuile:hover { border-color: var(--encre-3); }
.tuile .e { font-size: 1.5rem; line-height: 1.2; }
.tuile b { font-weight: 680; font-size: .95rem; line-height: 1.2; }
.tuile small { color: var(--encre-3); font-size: .78rem; line-height: 1.25; }
.tuile[aria-pressed=true] { border-color: var(--marque); background: var(--marque-pale); box-shadow: 0 0 0 1.5px var(--marque) inset; }
.tuile[aria-pressed=true] small { color: var(--encre-2); }
/* L'urgence : cinq crans, en colonne sur téléphone (les libellés restent lisibles), en ligne au-delà. */
.echelle { display: grid; gap: 6px; }
.cran { cursor: pointer; border: 1.5px solid var(--ligne-forte); background: var(--carte); border-radius: 12px; padding: 10px 14px; display: flex; align-items: center; gap: 12px;
  font-size: .95rem; font-weight: 620; line-height: 1.15; text-align: left; }
.cran .e { font-size: 1.35rem; }
@media (min-width: 640px) {
  .echelle { grid-template-columns: repeat(5, 1fr); }
  .cran { display: grid; justify-items: center; gap: 3px; padding: 10px 4px 8px; font-size: .8rem; text-align: center; }
  .cran .e { font-size: 1.45rem; }
}
.cran[aria-pressed=true] { border-color: var(--encre); background: var(--encre); color: var(--papier); }
.puces { display: flex; flex-wrap: wrap; gap: 8px; }
.puce { cursor: pointer; border: 1.5px solid var(--ligne-forte); background: var(--carte); border-radius: 999px; padding: 8px 14px; font-weight: 580; font-size: .93rem;
  display: inline-flex; gap: 7px; align-items: center; }
.puce[aria-pressed=true] { border-color: var(--marque); background: var(--marque-pale); box-shadow: 0 0 0 1px var(--marque) inset; }
.piege { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.erreur { background: var(--rouge-pale); color: var(--rouge-texte); border-radius: 12px; padding: 12px 14px; font-weight: 600; }

/* ---------- Bossomètre ---------- */
.jauge { text-align: center; }
.jauge svg { width: 100%; max-width: 260px; display: block; margin: 0 auto; }
.jauge .aiguille { transition: transform .6s cubic-bezier(.3, 1.5, .5, 1); transform-origin: 120px 120px; }
.jauge .valeur { font-stretch: 62%; font-weight: 850; font-variant-numeric: tabular-nums; font-size: 3.4rem; line-height: .9; margin-top: -2px; }
.jauge .verdict { font-stretch: 72%; font-weight: 760; text-transform: uppercase; letter-spacing: .03em; margin-top: 8px; color: var(--marque-texte); }
.raisons { list-style: none; padding: 0; margin: 14px 0 0; text-align: left; display: grid; gap: 5px; font-size: .86rem; }
.raisons li { display: flex; gap: 10px; align-items: baseline; }
.raisons .pts { font-family: var(--mono); font-weight: 600; min-width: 34px; text-align: right; }
.raisons .plus { color: var(--vert); } .raisons .moins { color: var(--rouge); }

/* ---------- le ticket ---------- */
.ticket-ombre { filter: drop-shadow(0 12px 22px var(--ombre-ticket)); }
/* overflow : le tampon arrive en grand (animation) et ne doit pas élargir la page sur téléphone. */
.ticket { position: relative; overflow: hidden; background: var(--carte); border-radius: 16px; padding: 22px 24px;
  -webkit-mask: radial-gradient(circle 12px at 0 103px, #0000 97%, #000) left / 51% 100% no-repeat, radial-gradient(circle 12px at 100% 103px, #0000 97%, #000) right / 51% 100% no-repeat;
          mask: radial-gradient(circle 12px at 0 103px, #0000 97%, #000) left / 51% 100% no-repeat, radial-gradient(circle 12px at 100% 103px, #0000 97%, #000) right / 51% 100% no-repeat; }
.ticket .tete { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; min-height: 58px; }
.ticket .numero { font-family: var(--mono); font-weight: 600; font-size: 2.1rem; letter-spacing: -.03em; line-height: 1; color: var(--marque-texte); }
.ticket .perfo { border-top: 2px dashed var(--ligne-forte); margin: 22px -24px 18px; }
.ticket .objet { font-stretch: 76%; font-size: 1.55rem; font-weight: 760; line-height: 1.12; overflow-wrap: anywhere; }
.ticket .details { margin-top: 10px; color: var(--encre-2); white-space: pre-wrap; overflow-wrap: anywhere; }
.meta { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.meta span { background: var(--papier); border-radius: 999px; padding: 5px 11px; font-size: .83rem; font-weight: 560; }
.tampon { display: inline-block; font-family: var(--texte); font-stretch: 62%; font-weight: 850; text-transform: uppercase; letter-spacing: .05em; font-size: 1.3rem; line-height: 1;
  padding: 8px 12px 7px; border: 3px solid currentColor; border-radius: 8px; box-shadow: 0 0 0 2px var(--carte) inset, 0 0 0 4px currentColor inset;
  transform: rotate(-7deg); color: var(--marque-texte); opacity: .9; white-space: nowrap;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='60'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' seed='4'/%3E%3CfeColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 -1.6 1.35'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23f)'/%3E%3C/svg%3E");
          mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='60'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' seed='4'/%3E%3CfeColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 -1.6 1.35'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23f)'/%3E%3C/svg%3E"); }
.tampon.vert { color: var(--vert); } .tampon.rouge { color: var(--rouge); } .tampon.orange { color: var(--orange); } .tampon.gris { color: var(--gris); }
.tampon.frais { animation: tampon .5s cubic-bezier(.2, 1.6, .4, 1) both; }
@keyframes tampon { from { transform: rotate(-7deg) scale(2.2); opacity: 0; } 60% { opacity: .95; } to { transform: rotate(-7deg) scale(1); opacity: .9; } }
.sortie { animation: sortie .7s cubic-bezier(.2, .9, .3, 1.2) both; }
@keyframes sortie { from { transform: translateY(-40px) scaleY(.6); opacity: 0; clip-path: inset(0 0 100% 0); } to { transform: none; opacity: 1; clip-path: inset(0 0 0 0); } }
@media (prefers-reduced-motion: reduce) { .sortie, .tampon.frais { animation: none; } }

.puce-statut { display: inline-flex; align-items: center; gap: 6px; font-weight: 650; font-size: .8rem; padding: 4px 10px; border-radius: 999px;
  background: var(--marque-pale); color: var(--marque-texte); white-space: nowrap; }
.puce-statut.vert { background: var(--vert-pale); color: var(--vert); } .puce-statut.rouge { background: var(--rouge-pale); color: var(--rouge-texte); }
.puce-statut.orange { background: var(--orange-pale); color: var(--orange); } .puce-statut.gris { background: var(--gris-pale); color: var(--gris); }
.rail { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 18px; }
.rail div { font-size: .74rem; font-weight: 640; color: var(--encre-3); display: grid; gap: 7px; }
.rail div::before { content: ''; height: 6px; border-radius: 99px; background: var(--papier-2); }
.rail .fait { color: var(--encre); } .rail .fait::before { background: var(--encre); }
.rail .ici { color: var(--marque-texte); } .rail .ici::before { background: var(--marque); }

.colonnes { display: grid; gap: 18px; margin-top: 8px; }
@media (min-width: 900px) { .colonnes { grid-template-columns: 1fr 340px; align-items: start; } }
.garde { border: 2px dashed var(--marque); background: var(--marque-pale); border-radius: var(--rayon); padding: 18px; }
.garde .etiquette { color: var(--marque-texte); }
.garde .code { white-space: nowrap; font-family: var(--mono); font-weight: 600; font-size: 1.5rem; letter-spacing: .08em; }
.copie { display: flex; gap: 8px; margin-top: 10px; }
.copie input { font-family: var(--mono); font-size: .82rem; }

/* ---------- fil de discussion ---------- */
.fil { display: grid; gap: 12px; margin-top: 6px; }
.evt { display: flex; gap: 10px; align-items: baseline; font-size: .88rem; color: var(--encre-2); padding: 2px 6px; }
.evt .ic { flex: none; width: 22px; text-align: center; }
.evt time { margin-left: auto; padding-left: 10px; color: var(--encre-3); font-size: .76rem; font-variant-numeric: tabular-nums; white-space: nowrap; }
.bulle { display: grid; grid-template-columns: 38px 1fr; gap: 10px; align-items: start; }
.bulle .av { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; font-weight: 760; background: var(--papier-2); font-size: 1rem; }
.bulle .corps { background: var(--carte); border: 1px solid var(--ligne); border-radius: 4px 16px 16px 16px; padding: 11px 14px; min-width: 0; }
.bulle .qui { display: flex; gap: 8px; align-items: baseline; font-size: .82rem; font-weight: 700; margin-bottom: 3px; }
.bulle .qui time { font-weight: 500; font-size: .76rem; color: var(--encre-3); font-variant-numeric: tabular-nums; }
.bulle .texte { white-space: pre-wrap; overflow-wrap: anywhere; }
.bulle.boss .av { background: var(--marque); color: #fff; }
.bulle.boss .corps { background: var(--marque-pale); border-color: transparent; }
.bulle.auto .av { background: var(--encre); color: var(--papier); font-size: .95rem; }
.bulle.auto .corps { background: transparent; border-style: dashed; border-color: var(--ligne-forte); }
.citation { margin-top: 6px; padding: 8px 12px; border-left: 3px solid var(--ligne-forte); color: var(--encre-2); font-style: italic; white-space: pre-wrap; }
.composer { display: grid; gap: 10px; margin-top: 14px; }
.composer textarea { min-height: 90px; }
.relance { display: grid; gap: 8px; }
.compteur { font-family: var(--mono); font-size: .8rem; color: var(--encre-3); }
.notes { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.notes button { cursor: pointer; border: 1.5px solid var(--ligne-forte); background: var(--carte); border-radius: 12px; padding: 10px 2px; display: grid; gap: 4px;
  justify-items: center; font-stretch: 78%; font-size: .74rem; font-weight: 640; line-height: 1.15; text-align: center; }
.notes button .e { font-size: 1.5rem; }
.notes button[aria-pressed=true] { border-color: var(--marque); background: var(--marque-pale); box-shadow: 0 0 0 1px var(--marque) inset; }

/* ---------- le coin de la Boss ---------- */
.bandeau-boss { background: var(--nuit); color: var(--sur-nuit); border-radius: var(--rayon); padding: 22px; display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); }
.bandeau-boss .discret, .bandeau-boss .etiquette { color: var(--sur-nuit-2); }
.humeurs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.humeurs button { flex: none; cursor: pointer; border: 1.5px solid var(--trait-nuit); background: transparent; color: inherit; border-radius: 999px;
  padding: 7px 12px; font-weight: 600; font-size: .88rem; display: inline-flex; gap: 6px; }
.humeurs button[aria-pressed=true] { background: var(--sur-nuit); color: #0d1b3e; border-color: var(--sur-nuit); }
.bandeau-boss input { background: rgba(255, 255, 255, .08); border-color: var(--trait-nuit); color: inherit; }
.bandeau-boss input::placeholder { color: var(--sur-nuit-2); }
.bandeau-boss form input { flex: 1; min-width: 0; }
.onglets { display: flex; gap: 6px; overflow-x: auto; margin: 22px 0 12px; padding-bottom: 4px; scrollbar-width: none; }
.onglets button { flex: none; cursor: pointer; border: 0; background: transparent; padding: 8px 13px; border-radius: 999px; font-weight: 640; font-size: .93rem; color: var(--encre-2);
  display: inline-flex; gap: 7px; align-items: center; }
.onglets button[aria-pressed=true] { background: var(--encre); color: var(--papier); }
.onglets .n { font-family: var(--mono); font-size: .75rem; opacity: .7; }
.liste { display: grid; gap: 8px; }
.ligne { display: grid; grid-template-columns: auto 1fr auto; gap: 4px 14px; align-items: center; text-decoration: none; padding: 14px 16px;
  background: var(--carte); border: 1px solid var(--ligne); border-radius: 14px; transition: border-color .12s, transform .12s; }
.ligne:hover { border-color: var(--ligne-forte); transform: translateY(-1px); }
.ligne .num { font-family: var(--mono); font-weight: 600; color: var(--marque-texte); font-size: .9rem; position: relative; }
.ligne.nonlu .num::after { content: ''; position: absolute; left: -10px; top: 50%; width: 7px; height: 7px; margin-top: -3.5px; border-radius: 50%; background: var(--marque); }
.ligne .titre { font-weight: 680; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.ligne.nonlu .titre { font-weight: 800; }
.ligne .sous { grid-column: 2 / 4; font-size: .84rem; color: var(--encre-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
/* Sur téléphone, le titre d'une demande garde deux lignes et son statut passe dessous. */
@media (max-width: 560px) {
  .ligne { grid-template-columns: auto 1fr; }
  .ligne .titre { white-space: normal; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; line-clamp: 2; line-height: 1.25; }
  .ligne .puce-statut { grid-column: 2; justify-self: start; }
  .ligne .sous { grid-column: 2; }
}
.vide { text-align: center; padding: 40px 18px; color: var(--encre-3); border: 1.5px dashed var(--ligne-forte); border-radius: var(--rayon); }
.vide .e { font-size: 2.4rem; display: block; margin-bottom: 6px; }
.vide h2 { color: var(--encre); }
.reponses { display: flex; gap: 6px; flex-wrap: wrap; }
.reponses button { cursor: pointer; border: 1.5px dashed var(--ligne-forte); background: transparent; border-radius: 999px; padding: 6px 11px; font-size: .84rem; font-weight: 600; }
.reponses button:hover { border-style: solid; border-color: var(--marque); }
.boutons-statut { display: flex; flex-wrap: wrap; gap: 6px; }
.boutons-statut button { cursor: pointer; border: 1.5px solid var(--ligne-forte); background: var(--carte); border-radius: 10px; padding: 7px 11px; font-size: .86rem; font-weight: 640; }
.boutons-statut button[aria-pressed=true] { background: var(--encre); color: var(--papier); border-color: var(--encre); }
.connexion { max-width: 420px; margin: 40px auto 0; }
form[data-envoi=motdepasse] { max-width: 440px; }
.journal { font-family: var(--mono); font-size: .76rem; color: var(--encre-3); display: grid; gap: 3px; margin-top: 10px; overflow-wrap: anywhere; }
pre.commande { font-family: var(--mono); font-weight: 500; font-size: .82rem; white-space: pre-wrap; overflow-wrap: anywhere; background: var(--papier); padding: 12px; border-radius: 10px; margin: 10px 0 0; }

/* ---------- divers ---------- */
#toasts { position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom)); transform: translateX(-50%); display: grid; gap: 8px; z-index: 50;
  width: min(460px, calc(100vw - 24px)); pointer-events: none; }
.toast { background: var(--nuit); color: var(--sur-nuit); border: 1px solid var(--trait-nuit); padding: 12px 16px; border-radius: 14px; box-shadow: 0 12px 30px -8px rgba(0, 0, 0, .45); font-weight: 560;
  font-size: .94rem; animation: toast .3s cubic-bezier(.2, 1.4, .4, 1) both; pointer-events: auto; }
.toast small { display: block; opacity: .7; font-weight: 500; margin-bottom: 2px; font-family: var(--mono); font-size: .7rem; letter-spacing: .08em; text-transform: uppercase; }
.toast.erreur { background: var(--rouge-fonce); color: #fff; border-color: transparent; }
@keyframes toast { from { transform: translateY(16px); opacity: 0; } }
.chargement { padding: 60px 0; text-align: center; color: var(--encre-3); }
.chargement::before { content: '🥊'; display: block; font-size: 2rem; animation: sautille 1s ease-in-out infinite; }
@keyframes sautille { 50% { transform: translateY(-8px) rotate(-8deg); } }
@media (prefers-reduced-motion: reduce) { .chargement::before, .toast { animation: none; } }
.retour { display: inline-flex; gap: 6px; align-items: center; text-decoration: none; color: var(--encre-2); font-weight: 600; font-size: .93rem; margin: 6px 0 14px; }
.tete-page { margin: 8px 0 20px; }
.tete-page p { color: var(--encre-2); margin-top: 10px; font-size: 1.05rem; }
.separateur { border: 0; border-top: 1px dashed var(--ligne-forte); margin: 18px 0; }
.lien { color: var(--marque-texte); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; background: none; border: 0; padding: 0; }
.lien.sourdine { color: var(--encre-3); }
.avis { background: var(--orange-pale); border-radius: 12px; padding: 12px 14px; font-size: .92rem; }

/* ---------- maquette ---------- */
.demo { position: sticky; top: 0; z-index: 40; display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: center; justify-content: space-between;
  padding: 8px 18px; background: #0d1b3e; color: #f2f5fd; font-size: .84rem; }
.demo a, .demo button { color: #ffc93c; font-weight: 650; background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; font-size: .84rem; }
.demo .rangee { gap: 14px; }

@media (max-width: 420px) { .logo small { display: none; } .barre { gap: 6px; } }
/* Bossomètre en miniature, en bas de l'écran pendant qu'on remplit (téléphone). */
.mini-jauge { position: fixed; z-index: 30; left: 50%; transform: translateX(-50%); bottom: calc(14px + env(safe-area-inset-bottom)); display: inline-flex; gap: 10px; align-items: center;
  background: var(--nuit); color: var(--sur-nuit); border: 1px solid var(--trait-nuit); border-radius: 999px; padding: 10px 16px; font-weight: 650; font-size: .9rem; cursor: pointer;
  box-shadow: 0 10px 26px -8px rgba(0, 0, 0, .5); white-space: nowrap; transition: opacity .2s; max-width: calc(100vw - 24px); }
.mini-jauge b { font-variant-numeric: tabular-nums; font-size: 1.05rem; color: var(--lumiere); }
.mini-jauge.loin { opacity: 0; pointer-events: none; }
@media (min-width: 900px) { .mini-jauge { display: none; } }
.grille > *, .colonnes > *, .formulaire > * { min-width: 0; }
