/* Page de téléchargement PLIGO — smartphone d'abord.
   23/10 (refonte du site) : mêmes teintes et mêmes polices que l'accueil
   (polices déclarées dans site.css). */
:root {
  --rouge: #A91F23;
  --rouge-fonce: #8a181c;
  --rouge-pale: #f8e6e6;
  --fond: #fbf7f6;
  --carte: #ffffff;
  --texte: #1d1416;
  --texte-doux: #6b5f60;
  --bord: #ecdfdd;
  --vert: #2e7d32;
  --info: #fff5d6;
  --info-bord: #e8c766;
  --rayon: 16px;
}
/* Sombre par défaut ; clair seulement si choisi (27/10). */
  :root:not([data-theme="clair"]) {
    --fond: #0b0a0b;
    --carte: #161314;
    --texte: #f4eeee;
    --texte-doux: #a39a9b;
    --bord: #2a2425;
    --rouge-pale: #3a1d1e;
    --info: #3a321a;
    --info-bord: #8a7432;
    --vert: #81c784;
  }


* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Figtree", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  background: var(--fond);
  color: var(--texte);
}
a { color: var(--rouge); }
:where(html:not([data-theme="clair"])) a { color: #ef8a8d; }
code {
  font-family: ui-monospace, Consolas, monospace;
  font-size: .88em;
  background: var(--rouge-pale);
  padding: 1px 5px;
  border-radius: 4px;
  overflow-wrap: anywhere;
}

/* Zone « compte » de l'en-tête : dans site.css (commune à toutes les pages, 08/10). */

/* Contenu */
main { max-width: 760px; margin: 0 auto; padding: 32px 16px 16px; }
h1, h2 { font-family: "Bricolage Grotesque", system-ui, sans-serif; letter-spacing: -.01em; text-wrap: balance; }
.intro h1 { margin: 6px 0 6px; font-size: clamp(1.8rem, 5vw, 2.4rem); line-height: 1.1; color: var(--rouge); }
:where(html:not([data-theme="clair"])) .intro h1 { color: #ef8a8d; }
.intro p { margin: 0 0 14px; color: var(--texte-doux); }

.carte {
  background: var(--carte); border: 1px solid var(--bord); border-radius: var(--rayon);
  padding: 16px; margin: 0 0 16px;
}
.carte h2 { margin: 0 0 6px; font-size: 1.2rem; }
.carte h3 { margin: 16px 0 6px; font-size: 1rem; }
.carte-tete { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.carte-beta { border-color: var(--rouge); box-shadow: inset 4px 0 0 var(--rouge); }
.pastille {
  display: inline-block; background: var(--rouge); color: #fff; border-radius: 999px;
  padding: 2px 10px; font-size: .85rem; font-weight: 600;
}
.pastille-beta { background: #6d4c41; }
.carte-anciennes { box-shadow: inset 4px 0 0 #8e24aa; }
.pastille-fondateur { background: #8e24aa; }
#anciennes-bouton { margin: 4px 0 8px; }
#anciennes-liste { margin-top: 8px; }
a[aria-busy="true"] { opacity: .6; cursor: progress; }
.sous { color: var(--texte-doux); font-size: .9rem; margin: 4px 0; }
.notes { white-space: pre-wrap; overflow-wrap: anywhere; margin: 0; }
.chargement { color: var(--texte-doux); text-align: center; padding: 20px 0; }

/* Boutons */
.boutons { display: flex; flex-direction: column; gap: 10px; margin: 14px 0 4px; }
.btn {
  font: inherit; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border-radius: 14px; padding: 12px 16px; border: 1px solid transparent; cursor: pointer;
  text-decoration: none; text-align: center; transition: transform .2s, box-shadow .2s;
}
.btn:not(:disabled):hover { transform: translateY(-1px); }
@media (prefers-reduced-motion: reduce) { .btn { transition: none; } .btn:not(:disabled):hover { transform: none; } }
.btn:disabled { opacity: .6; cursor: progress; }
.btn-principal {
  background: linear-gradient(180deg, #d5343a, var(--rouge)); color: #fff; font-weight: 600;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .14) inset, 0 10px 26px -10px rgba(226, 57, 63, .55);
}
.btn-principal:hover, .btn-principal:focus-visible { background: linear-gradient(180deg, #c42e33, var(--rouge-fonce)); }
.btn-secondaire { background: transparent; color: var(--rouge); border-color: var(--rouge); font-weight: 600; }
:where(html:not([data-theme="clair"])) .btn-secondaire, :where(html:not([data-theme="clair"])) .btn-lien { color: #ef8a8d; border-color: #ef8a8d; }
.btn-lien { background: none; border: none; color: var(--rouge); padding: 8px 4px; text-decoration: underline; }
.btn-dl { flex-direction: column; gap: 0; }
.btn-dl .btn-titre { font-size: 1.05rem; }
.btn-dl .btn-detail { font-size: .8rem; font-weight: 400; opacity: .9; }
.lien-secondaire { font-size: .9rem; text-align: center; }
.boutons-ligne { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }

/* Empreintes */
.empreintes { margin-top: 14px; }
.empreintes summary { cursor: pointer; color: var(--texte-doux); font-size: .9rem; }
.empreinte { margin: 8px 0; font-size: .85rem; }
.empreinte-nom { font-weight: 600; overflow-wrap: anywhere; }
.empreinte code { display: block; margin-top: 2px; padding: 4px 6px; }

/* Listes de versions */
.liste-versions details { border-top: 1px solid var(--bord); padding: 8px 0; }
.liste-versions details:first-child { border-top: none; }
.liste-versions summary { cursor: pointer; font-weight: 600; }
.liste-versions summary .sous { font-weight: 400; margin-left: 6px; }
.liens-fichiers { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.liens-fichiers .btn { padding: 8px 12px; font-size: .9rem; }

/* Étapes */
.etapes { padding-left: 22px; margin: 6px 0; }
.etapes li { margin: 4px 0; }

/* Formulaires */
.onglets { display: flex; gap: 4px; border-bottom: 1px solid var(--bord); margin: 8px 0 12px; }
.onglet {
  font: inherit; flex: 1; background: none; border: none; border-bottom: 3px solid transparent;
  padding: 10px 6px; cursor: pointer; color: var(--texte-doux); font-weight: 600;
}
.onglet[aria-selected="true"] { color: var(--rouge); border-bottom-color: var(--rouge); }
.formulaire { display: flex; flex-direction: column; gap: 4px; }
.formulaire label { font-weight: 600; margin-top: 8px; font-size: .95rem; }
.formulaire input[type="email"], .formulaire input[type="text"], .formulaire input[type="password"] {
  font: inherit; padding: 11px 12px; border-radius: 8px; border: 1px solid var(--bord);
  background: var(--fond); color: var(--texte); width: 100%;
}
.formulaire input:focus-visible { outline: 2px solid var(--rouge); outline-offset: 1px; }
.formulaire .btn-principal { margin-top: 12px; }
.case { display: flex; gap: 10px; align-items: flex-start; font-weight: 400 !important; }
.case input { margin-top: 5px; width: 18px; height: 18px; flex: none; accent-color: var(--rouge); }
.aide { font-weight: 400; color: var(--texte-doux); font-size: .82rem; margin: 2px 0 0; }
.aide.ok { color: var(--vert); }
.aide.ko { color: var(--rouge); }
.message { min-height: 1.2em; margin: 8px 0 0; font-size: .92rem; }
.message.ok { color: var(--vert); }
.message.ko { color: var(--rouge); }
:where(html:not([data-theme="clair"])) .message.ko, :where(html:not([data-theme="clair"])) .aide.ko { color: #ef8a8d; }

.alerte {
  background: var(--rouge-pale); border: 1px solid var(--rouge); border-radius: 8px;
  padding: 10px 12px; margin: 0 0 16px;
}
.alerte-info { background: var(--info); border-color: var(--info-bord); }
.alerte p { margin: 0 0 8px; }

.conditions p { font-size: .9rem; color: var(--texte-doux); }

[hidden] { display: none !important; }


@media (min-width: 600px) {
  .boutons { flex-direction: row; flex-wrap: wrap; }
  .boutons > .btn { flex: 1 1 240px; }
  .lien-secondaire { flex-basis: 100%; }
  .intro h1 { font-size: 1.9rem; }
}
