:root {
  --encre: #13212c;
  --doux: #5a6772;
  --fond: #f4f6f3;
  --carte: #ffffff;
  --trait: #e2e6e1;
  --accent: #0b6e5f;
  --accent-fonce: #08574b;
  --accent-clair: #e2f3ee;
  --accent-tres-clair: #f1f9f6;
  --accent-vif: #0f8a76;
  --accent-lumineux: #3cc3a4;
  --accent-bord: #bfe3d8;
  --accent-ombre: rgba(11, 110, 95, 0.3);
  --or: #f2b441;
  --alerte: #9a3412;
  --alerte-fond: #fff1e6;
  --rouge: #dc2626;
  --orange: #ea7a0c;
  --vert: #16a34a;
  --rayon: 16px;
  --ombre: 0 1px 2px rgba(19, 33, 44, 0.05), 0 6px 20px rgba(19, 33, 44, 0.06);
  --ombre-forte: 0 2px 4px rgba(19, 33, 44, 0.06), 0 14px 34px rgba(19, 33, 44, 0.1);
  color-scheme: light;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, Ubuntu, "Helvetica Neue", sans-serif;
  color: var(--encre);
  background: var(--fond);
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-underline-offset: 2px; }
a:hover { color: var(--accent-fonce); }
:focus-visible { outline: 3px solid var(--or); outline-offset: 2px; }
.enveloppe { max-width: 920px; margin: 0 auto; padding: 0 20px; }

/* ---------------------------------------------------------------- en-tête */
.haut { position: sticky; top: 0; z-index: 10; background: rgba(255, 255, 255, 0.92); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--trait); }
.haut .enveloppe, .bas .enveloppe { max-width: 1140px; }
.haut .enveloppe { display: flex; align-items: center; justify-content: space-between; gap: 6px 18px; min-height: 62px; flex-wrap: wrap; padding-top: 8px; padding-bottom: 8px; }
.logo { display: inline-flex; align-items: center; gap: 9px; font-weight: 800; font-size: 1.22rem; letter-spacing: -0.03em; color: var(--encre); text-decoration: none; }
.logo > span:last-child { color: #0b6e5f; margin-left: -9px; }
.logo-marque { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #0f8a76, #08574b); box-shadow: 0 3px 8px rgba(11, 110, 95, 0.35); }
.haut nav { display: flex; gap: 4px; font-size: 0.9rem; overflow-x: auto; white-space: nowrap; max-width: 100%; scrollbar-width: none; }
.haut nav::-webkit-scrollbar { display: none; }
.haut nav a { color: var(--doux); text-decoration: none; padding: 6px 10px; border-radius: 20px; font-weight: 500; }
.haut nav a:hover { color: var(--accent); background: var(--accent-tres-clair); }
.haut nav .nav-vedette { color: #0b6e5f; background: #e2f3ee; font-weight: 700; }

/* ---------------------------------------------------------------- titres */
main.enveloppe { padding-top: 26px; padding-bottom: 56px; }
h1 { font-size: clamp(1.75rem, 5vw, 2.5rem); line-height: 1.12; letter-spacing: -0.03em; margin: 0 0 12px; font-weight: 800; }
h2 { font-size: 1.32rem; line-height: 1.25; margin: 38px 0 12px; letter-spacing: -0.015em; font-weight: 750; }
.accroche { color: var(--doux); font-size: 1.1rem; margin: 0 0 24px; max-width: 62ch; }
.maj { font-size: 0.84rem; color: var(--doux); display: flex; align-items: center; gap: 6px; }
.maj::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--vert); flex: none; }
.fil { display: flex; flex-wrap: wrap; gap: 6px; font-size: 0.85rem; color: var(--doux); margin-bottom: 10px; }
.fil a { color: var(--doux); text-decoration: none; }
.fil a:hover { color: var(--accent); text-decoration: underline; }

/* ---------------------------------------------------------------- accueil */
.hero { position: relative; padding: 34px 28px 30px; margin: 0 0 18px; border-radius: 24px; overflow: hidden; color: #fff;
  background: radial-gradient(120% 140% at 100% 0%, #1aa58c 0%, rgba(26, 165, 140, 0) 55%), linear-gradient(140deg, #0b6e5f 0%, #0a4f45 100%); box-shadow: var(--ombre-forte); }
.hero::after { content: ""; position: absolute; right: -60px; bottom: -80px; width: 260px; height: 260px; border-radius: 50%; border: 40px solid rgba(255, 255, 255, 0.06); }
.hero h1 { color: #fff; max-width: 20ch; }
.hero .accroche { color: rgba(255, 255, 255, 0.86); }
.sur-titre { display: inline-block; margin: 0 0 12px; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: #c9f1e6; background: rgba(255, 255, 255, 0.1); padding: 4px 10px; border-radius: 20px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; position: relative; z-index: 1; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 20px; border-radius: 12px; font-weight: 700; text-decoration: none; transition: transform 0.15s, box-shadow 0.15s; }
.btn:hover { transform: translateY(-1px); }
.btn-plein { background: #fff; color: var(--accent-fonce); box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15); }
.btn-plein:hover { color: var(--accent-fonce); }
.btn-contour { color: #fff; border: 1.5px solid rgba(255, 255, 255, 0.55); }
.btn-contour:hover { color: #fff; background: rgba(255, 255, 255, 0.08); }
.garanties { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 0; margin: 20px 0 0; font-size: 0.9rem; color: rgba(255, 255, 255, 0.9); }
.garanties li::before { content: "✓"; margin-right: 6px; color: var(--or); font-weight: 800; }
.vedette { display: flex; align-items: center; gap: 18px; padding: 20px 22px; margin: 0 0 10px; background: var(--carte); border: 1.5px solid var(--accent-bord); border-radius: var(--rayon); text-decoration: none; color: var(--encre); box-shadow: var(--ombre); transition: transform 0.15s, box-shadow 0.15s; }
.vedette:hover { transform: translateY(-2px); box-shadow: var(--ombre-forte); color: var(--encre); }
.vedette-texte { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.vedette-texte strong { font-size: 1.25rem; line-height: 1.25; letter-spacing: -0.01em; }
.vedette-texte span { color: var(--doux); font-size: 0.96rem; }
.vedette .pastille { align-self: flex-start; background: var(--or); color: #3b2a05; font-size: 0.72rem; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; padding: 3px 9px; border-radius: 20px; }
.vedette .vedette-lien { color: var(--accent); font-weight: 700; }
.vedette-image { width: 104px; flex: none; filter: drop-shadow(0 6px 12px rgba(19, 33, 44, 0.12)); transform: rotate(3deg); }
.grille { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin: 14px 0 28px; }
.tuile { display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px; background: var(--carte); border: 1px solid var(--trait); border-radius: var(--rayon); text-decoration: none; color: var(--encre); transition: border-color 0.15s, transform 0.15s, box-shadow 0.15s; }
.tuile:hover { border-color: #9fd3c5; transform: translateY(-2px); box-shadow: var(--ombre); color: var(--encre); }
.tuile strong { display: block; line-height: 1.3; }
.tuile small { color: var(--doux); font-size: 0.86rem; line-height: 1.42; display: block; margin-top: 3px; }
.categorie { margin-top: 34px; display: flex; align-items: center; gap: 10px; scroll-margin-top: 80px; }
.categorie::after { content: ""; flex: 1; height: 1px; background: var(--trait); }
.atouts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.atouts div { background: var(--carte); border: 1px solid var(--trait); border-radius: var(--rayon); padding: 18px; font-size: 0.95rem; color: var(--doux); }
.atouts strong { color: var(--encre); font-size: 1.02rem; }
.autres { margin-top: 34px; }
.hub li { margin: 8px 0; }

/* ---------------------------------------------------------------- calculateur */
.calc { position: relative; background: var(--carte); border: 1px solid var(--trait); border-radius: 20px; padding: 24px; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px 18px; margin-bottom: 16px; box-shadow: var(--ombre); overflow: hidden; }
.calc::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: linear-gradient(90deg, var(--accent-vif), var(--accent-lumineux), var(--or)); }
.calc .sous-titre { grid-column: 1 / -1; margin: 0; font-size: 1.1rem; }
.champ { display: flex; flex-direction: column; gap: 6px; font-weight: 650; font-size: 0.94rem; }
.champ small { font-weight: 400; color: var(--doux); font-size: 0.8rem; line-height: 1.4; }
.calc input[type="text"], .calc input[type="date"], .calc select {
  font: inherit; font-weight: 550; width: 100%; min-height: 48px;
  padding: 11px 13px; border: 1.5px solid #d6dcd6; border-radius: 12px; background: #fbfcfb; color: var(--encre); transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
}
.calc input[type="text"]:hover, .calc select:hover { border-color: #b8c3bb; }
.calc select { appearance: none; -webkit-appearance: none; padding-right: 38px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%230b6e5f' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 13px center; }
.calc input:focus, .calc select:focus { outline: none; border-color: var(--accent); background: #fff; box-shadow: 0 0 0 4px var(--accent-clair); }
.case { display: flex; align-items: center; gap: 10px; font-size: 0.95rem; cursor: pointer; }
.case input { width: 20px; height: 20px; accent-color: var(--accent); }
.resultat { grid-column: 1 / -1; display: block; background: linear-gradient(180deg, var(--accent-clair), var(--accent-tres-clair)); border: 1px solid var(--accent-bord); border-radius: 16px; padding: 18px 20px; }
.grand { display: flex; flex-direction: column; margin-bottom: 10px; }
.grand span { font-size: 0.88rem; color: var(--doux); font-weight: 600; }
.grand strong { font-size: clamp(2rem, 7vw, 2.6rem); color: var(--accent); letter-spacing: -0.03em; line-height: 1.12; font-variant-numeric: tabular-nums; }
.ligne { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-top: 1px solid rgba(11, 110, 95, 0.14); font-size: 0.96rem; }
.ligne strong { font-weight: 650; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ligne.fort strong { color: var(--accent); }
.note { font-size: 0.82rem; color: var(--doux); margin: 10px 0 0; }
.alerte { background: var(--alerte-fond); color: var(--alerte); padding: 11px 13px; border-radius: 12px; margin: 10px 0 0; font-size: 0.92rem; border: 1px solid #f7d4bb; }
.succes { background: #e7f6ec; color: #14532d; padding: 11px 13px; border-radius: 12px; margin: 10px 0 0; font-size: 0.92rem; }
.liste { margin: 8px 0 0; padding-left: 18px; }
.liste li { margin: 3px 0; }
.mini-titre { margin: 16px 0 2px; font-weight: 750; font-size: 0.88rem; color: var(--encre); text-transform: uppercase; letter-spacing: 0.04em; }
.table-res { margin: 10px 0; overflow-x: auto; }
.table-res table { display: table; background: rgba(255, 255, 255, 0.7); font-size: 0.85rem; margin: 0; border-radius: 10px; overflow: hidden; }
.table-res td, .table-res th { padding: 6px 6px; font-size: 0.8rem; }
.table-res td:first-child, .table-res th:first-child { white-space: normal; min-width: 7.5em; }
.table-res td:not(:first-child) { text-align: right; font-variant-numeric: tabular-nums; }
.jours { grid-column: 1 / -1; border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 16px; }
.jours legend { font-weight: 650; font-size: 0.94rem; margin-bottom: 6px; padding: 0; }

/* options d'expert */
.expert { grid-column: 1 / -1; border: 1.5px dashed #cfd7d0; border-radius: 14px; padding: 0; background: #fcfdfc; }
.expert[open] { border-style: solid; border-color: var(--accent-bord); background: var(--accent-tres-clair); }
.expert > summary { cursor: pointer; padding: 13px 16px; font-weight: 700; font-size: 0.95rem; color: var(--accent); list-style: none; display: flex; align-items: center; gap: 10px; }
.expert > summary::-webkit-details-marker { display: none; }
.expert > summary::before { content: "+"; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: #fff; font-size: 0.95rem; line-height: 1; flex: none; }
.expert[open] > summary::before { content: "−"; }
.expert-champs { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px 18px; padding: 4px 16px 18px; }

/* ---------------------------------------------------------------- contenu */
article { background: var(--carte); border: 1px solid var(--trait); border-radius: var(--rayon); padding: 8px 28px 26px; }
article h2:first-child { margin-top: 24px; }
article p, article li { max-width: 72ch; }
article a, .note a { overflow-wrap: anywhere; }
article ol, article ul { padding-left: 22px; }
article li { margin: 6px 0; }
table { width: 100%; border-collapse: collapse; font-size: 0.93rem; margin: 12px 0; display: block; overflow-x: auto; }
th, td { text-align: left; padding: 9px 11px; border-bottom: 1px solid var(--trait); white-space: nowrap; }
th { background: var(--fond); font-weight: 650; }
tbody tr:hover td { background: var(--accent-tres-clair); }
code { background: var(--fond); padding: 2px 6px; border-radius: 6px; font-size: 0.9em; overflow-wrap: anywhere; }
pre { background: var(--encre); color: #e8f1ee; padding: 14px; border-radius: 12px; overflow-x: auto; font-size: 0.85rem; }
.faq details { border-bottom: 1px solid var(--trait); padding: 14px 0; }
.faq summary { cursor: pointer; font-weight: 650; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "⌄"; color: var(--accent); font-weight: 800; transition: transform 0.2s; flex: none; }
.faq details[open] summary::after { transform: rotate(180deg); }
.faq p { margin: 8px 0 0; color: var(--doux); }
.sources { font-size: 0.82rem; color: var(--doux); margin-top: 22px; padding-top: 14px; border-top: 1px dashed var(--trait); }

/* publicité */
.pub { margin: 18px 0; min-height: 0; }

/* ---------------------------------------------------------------- pied */
.bas { background: #0f1c25; color: #a9b6be; font-size: 0.88rem; }
.bas .enveloppe { padding-top: 26px; padding-bottom: 32px; display: flex; flex-wrap: wrap; gap: 10px 20px; justify-content: space-between; }
.bas nav { display: flex; gap: 16px; flex-wrap: wrap; }
.bas a { color: #d6e2e7; text-decoration: none; }
.bas a:hover { color: #fff; text-decoration: underline; }

/* ---------------------------------------------------------------- vérification de fiche de paie */
.fiche .etape { grid-column: 1 / -1; margin: 8px 0 -4px; font-weight: 800; font-size: 1.08rem; display: flex; align-items: center; gap: 10px; letter-spacing: -0.01em; }
.fiche .etape:first-of-type { margin-top: 0; }
.fiche .etape span { width: 30px; height: 30px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-size: 0.92rem; flex: none; box-shadow: 0 3px 8px rgba(11, 110, 95, 0.3); }
.scan { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 12px; padding: 16px; border: 2px dashed var(--accent-bord); border-radius: 16px; background: var(--accent-tres-clair); }
.scan-boutons { display: flex; flex-wrap: wrap; gap: 10px; }
.cache { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.bouton-photo, .bouton-fichier, .bouton-copier { display: inline-flex; align-items: center; justify-content: center; gap: 9px; cursor: pointer; border-radius: 14px; font: inherit; font-weight: 750; padding: 15px 18px; position: relative; flex: 1 1 220px; text-align: center; transition: transform 0.15s, box-shadow 0.15s; }
.bouton-photo { background: linear-gradient(135deg, var(--accent-vif), var(--accent-fonce)); color: #fff; font-size: 1.06rem; box-shadow: 0 8px 18px var(--accent-ombre); }
.bouton-photo:hover, .bouton-fichier:hover { transform: translateY(-1px); }
.bouton-photo span { font-size: 1.4rem; line-height: 1; }
.bouton-fichier { background: #fff; color: var(--accent); border: 1.5px solid var(--accent); }
.bouton-photo:focus-within, .bouton-fichier:focus-within { box-shadow: 0 0 0 4px var(--or); }
.fiche-etat { margin: 0; font-size: 0.88rem; color: var(--doux); }
.fiche-etat.fiche-ok { color: #14532d; font-weight: 650; }
.fiche-etat.fiche-alerte { color: var(--alerte); font-weight: 650; }
.fiche-progression { height: 10px; background: #fff; border-radius: 10px; overflow: hidden; border: 1px solid #cfe7df; }
.fiche-progression div { height: 100%; width: 0; background: linear-gradient(90deg, var(--accent-vif), var(--accent-lumineux)); transition: width 0.3s; }
.fiche-image canvas { width: 100%; height: auto; display: block; border-radius: 12px; border: 1px solid var(--trait); box-shadow: var(--ombre); background: #fff; }
.fiche-image .note { margin-top: 8px; }
.lu-aide { grid-column: 1 / -1; margin: 0; font-size: 0.9rem; color: var(--doux); }
.lu-grille { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(auto-fill, minmax(165px, 1fr)); gap: 10px 14px; }
.lu-champ { font-size: 0.84rem; justify-content: flex-end; }
.calc input.lu { background: var(--accent-tres-clair); border-color: var(--accent-bord); }
.calc input.douteux { background: var(--alerte-fond); border-color: #f0a46b; }
.verdict { border-radius: 14px; padding: 16px 18px; margin-bottom: 12px; display: flex; flex-direction: column; gap: 4px; }
.verdict strong { font-size: 1.22rem; line-height: 1.25; letter-spacing: -0.01em; }
.verdict-erreurs { background: #fde8e8; color: #8f1d1d; border: 1px solid #f6c4c4; }
.verdict-a-verifier { background: var(--alerte-fond); color: var(--alerte); border: 1px solid #f7d4bb; }
.verdict-conforme { background: #dcf3e5; color: #14532d; border: 1px solid #b6e2c6; }
.verdict-incomplet { background: #fff; color: var(--doux); border: 1px solid var(--trait); }
.verdict-incomplet strong { color: var(--encre); }
.ctrl { display: flex; gap: 12px; background: #fff; border-radius: 14px; padding: 14px 16px; margin: 10px 0; border-left: 5px solid; box-shadow: 0 1px 3px rgba(19, 33, 44, 0.06); }
.ctrl-erreur { border-color: var(--rouge); }
.ctrl-a-verifier { border-color: var(--orange); }
.ctrl .num { flex: none; width: 28px; height: 28px; border-radius: 50%; color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 0.9rem; }
.ctrl-erreur .num, .ctrl-erreur .badge { background: var(--rouge); }
.ctrl-a-verifier .num, .ctrl-a-verifier .badge { background: var(--orange); }
.ctrl-corps { flex: 1; min-width: 0; }
.ctrl p { margin: 3px 0; font-size: 0.92rem; }
.ctrl-titre { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ctrl-titre strong { font-size: 1.02rem; }
.ctrl-resume { font-weight: 600; }
.badge { color: #fff; font-size: 0.7rem; font-weight: 800; padding: 2px 9px; border-radius: 20px; text-transform: uppercase; letter-spacing: 0.04em; }
.ctrl-chiffres { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 8px; }
.ctrl-chiffres span { flex: 1 1 90px; background: var(--fond); border-radius: 10px; padding: 7px 10px; display: flex; flex-direction: column; font-variant-numeric: tabular-nums; }
.ctrl-chiffres small { font-size: 0.72rem; color: var(--doux); text-transform: uppercase; letter-spacing: 0.04em; font-weight: 700; }
.ctrl-chiffres b { font-size: 1rem; white-space: nowrap; }
.ctrl-erreur .ctrl-chiffres span:last-child b { color: var(--rouge); }
.ctrl-bloc { padding-left: 12px; border-left: 3px solid var(--trait); margin: 8px 0 !important; }
.ctrl-bloc span { display: block; font-size: 0.72rem; font-weight: 800; color: var(--doux); text-transform: uppercase; letter-spacing: 0.05em; }
.ctrl-impact { border-left-color: var(--rouge); background: #fff6f6; border-radius: 0 8px 8px 0; padding: 6px 10px 6px 12px; }
.ctrl-a-verifier .ctrl-impact { border-left-color: var(--orange); background: var(--alerte-fond); }
.ctrl-quoi { margin-top: 6px; font-size: 0.88rem; }
.ctrl-quoi summary { cursor: pointer; color: var(--accent); font-weight: 650; }
.ctrl-quoi p { color: var(--doux); }
.ctrl-ok { color: #14532d; font-size: 0.9rem; margin: 12px 0 0; background: #e7f6ec; padding: 9px 12px; border-radius: 10px; }
.reclamation { margin-top: 12px; background: #fff; border-radius: 14px; padding: 12px 16px; border: 1px solid var(--accent-bord); }
.reclamation summary { cursor: pointer; font-weight: 750; color: var(--accent); }
.reclamation textarea { width: 100%; margin: 10px 0; font: inherit; font-size: 0.88rem; border: 1.5px solid var(--trait); border-radius: 12px; padding: 10px; resize: vertical; background: var(--fond); }
.bouton-copier { background: var(--accent); color: #fff; border: 0; padding: 11px 18px; }

/* ---------------------------------------------------------------- petits écrans */
@media (max-width: 560px) {
  body { font-size: 16px; }
  .enveloppe { padding: 0 14px; }
  main.enveloppe { padding-top: 18px; }
  .calc { padding: 20px 16px; border-radius: 18px; }
  article { padding: 4px 16px 20px; }
  .hero { padding: 26px 20px 24px; border-radius: 20px; }
  .hero-actions .btn { flex: 1 1 100%; }
  .vedette { padding: 16px; gap: 12px; }
  .vedette-image { width: 72px; }
  .haut { position: static; }
  .haut .enveloppe { min-height: 54px; }
  .haut nav { font-size: 0.86rem; }
  .sur-titre { font-size: 0.7rem; }
  .logo { font-size: 1.12rem; }
  .scan { padding: 12px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }

/* caméra dans la page (ordinateur) */
.camera { display: flex; flex-direction: column; gap: 10px; }
.camera-cadre { position: relative; border-radius: 14px; overflow: hidden; background: #0f1c25; aspect-ratio: 16 / 9; max-height: 72vh; margin: 0 auto; width: 100%; }
.camera-cadre video { width: 100%; height: 100%; object-fit: contain; display: block; }
.camera-guide { position: absolute; top: 2%; bottom: 2%; left: 50%; aspect-ratio: 21 / 29.7; transform: translateX(-50%); border: 3px dashed rgba(255, 255, 255, 0.85); border-radius: 10px; box-shadow: 0 0 0 9999px rgba(15, 28, 37, 0.35); pointer-events: none; }
.camera-aide { margin: 0; font-size: 0.88rem; color: var(--doux); }
.camera-boutons { display: flex; flex-wrap: wrap; gap: 10px; }
.camera-boutons .bouton-photo, .camera-boutons .bouton-fichier { border: 0; flex: 1 1 200px; }
.camera-boutons .bouton-fichier { border: 1.5px solid var(--accent); }
.bouton-annuler { font: inherit; font-weight: 650; background: none; border: 0; color: var(--doux); cursor: pointer; padding: 12px 14px; text-decoration: underline; }

/* reconnaissance du document */
.reconnaissance { border-radius: 14px; padding: 12px 14px; background: #fff; border: 1.5px solid var(--trait); font-size: 0.9rem; }
.reconnaissance p { margin: 4px 0; }
.reco-bloc-ok { border-color: #b6e2c6; }
.reco-bloc-doute { border-color: #f0c08f; background: #fffaf3; }
.reco-bloc-non { border-color: #f6c4c4; background: #fff5f5; }
.reco-titre { font-weight: 800; font-size: 1.02rem; display: flex; align-items: center; gap: 8px; }
.reco-titre span { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 0.85rem; flex: none; }
.reco-titre.reco-ok { color: #14532d; } .reco-titre.reco-ok span { background: var(--vert); }
.reco-titre.reco-doute { color: var(--alerte); } .reco-titre.reco-doute span { background: var(--orange); }
.reco-titre.reco-non { color: #8f1d1d; } .reco-titre.reco-non span { background: var(--rouge); }
.reco-siret .reco-ok { color: #14532d; font-weight: 650; } .reco-siret .reco-doute { color: var(--alerte); font-weight: 650; }
.reco-mentions summary { cursor: pointer; color: var(--accent); font-weight: 700; margin-top: 4px; }
.reco-mentions ul { list-style: none; padding: 0; margin: 8px 0; columns: 2 220px; }
.reco-mentions li { margin: 3px 0; break-inside: avoid; }
.reco-mentions .m-ok { color: #14532d; } .reco-mentions .m-non { color: var(--alerte); font-weight: 650; }

/* ---------------------------------------------------------------- mémo « vérifier sa fiche de paie » */
.memo { margin: 36px 0 8px; padding: 26px 22px; background: var(--carte); border: 1px solid var(--trait); border-radius: var(--rayon); box-shadow: var(--ombre); }
.memo h2 { margin: 2px 0 8px; font-size: 1.45rem; line-height: 1.25; }
.memo-sur-titre { margin: 0; color: var(--accent); font-weight: 700; font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; }
.memo-intro { color: var(--doux); margin: 0 0 14px; }
.memo-figure { margin: 0 0 18px; padding: 14px 10px 10px; background: var(--accent-tres-clair); border-radius: 14px; }
.memo-schema { display: block; width: 100%; max-width: 480px; height: auto; margin: 0 auto; font-family: inherit; }
.memo-boite rect { fill: #fff; stroke: var(--trait); stroke-width: 1.5; }
.memo-brut rect { fill: var(--accent-clair); stroke: var(--accent-bord); }
.memo-paye rect { fill: var(--accent); stroke: var(--accent); }
.memo-num { fill: var(--accent); }
.memo-num-t { fill: #fff; font-size: 13px; font-weight: 800; }
.memo-paye .memo-num { fill: #fff; }
.memo-paye .memo-num-t { fill: var(--accent); }
.memo-lib { fill: var(--encre); font-size: 14.5px; font-weight: 700; }
.memo-det { fill: var(--doux); font-size: 11.5px; }
.memo-val { fill: var(--encre); font-size: 15px; font-weight: 800; }
.memo-paye .memo-lib, .memo-paye .memo-val { fill: #fff; }
.memo-paye .memo-det { fill: rgba(255, 255, 255, 0.85); }
.memo-fleche { fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.memo-op { fill: var(--accent-fonce); font-size: 12.5px; font-weight: 600; }
.memo figcaption { margin-top: 8px; font-size: 0.88rem; color: var(--doux); text-align: center; }
.memo-etapes { padding-left: 1.3em; margin: 0 0 16px; }
.memo-etapes li { margin-bottom: 8px; }
.memo-erreurs { background: var(--alerte-fond); border-radius: 12px; padding: 12px 16px; margin-bottom: 14px; }
.memo-erreurs-titre { margin: 0 0 4px; font-weight: 700; color: var(--alerte); }
.memo-erreurs ul { margin: 0; padding-left: 1.2em; }
.memo-pied { font-size: 0.95rem; margin-bottom: 0; }
.memo-actions, .resultat .cta { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.memo .btn-plein, .resultat .cta .btn-plein { background: var(--accent); color: #fff; box-shadow: none; }
.memo .btn-plein:hover, .resultat .cta .btn-plein:hover { background: var(--accent-fonce); color: #fff; }
.memo .btn-contour { color: var(--accent-fonce); border: 1.5px solid var(--accent); background: #fff; font: inherit; font-weight: 700; cursor: pointer; }
.memo .btn-contour:hover { color: var(--accent-fonce); background: var(--accent-tres-clair); }
@media (max-width: 600px) { .memo { padding: 20px 14px; } .memo-figure { padding: 10px 4px 8px; } }

/* impression du mémo seul */
.zone-impression { display: none; }
@media print {
  html.impression-memo body > *:not(.zone-impression) { display: none !important; }
  html.impression-memo .zone-impression { display: block; }
  .zone-impression .memo { box-shadow: none; border: 0; margin: 0; padding: 0; }
  .zone-impression .memo-actions { display: none; }
  .zone-impression .memo-figure, .zone-impression .memo-erreurs { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .haut, .bas, .pub { display: none !important; }
}

/* ================================================================ couleurs par catégorie */
.cat-paie { --accent: #0b6e5f; --accent-fonce: #08574b; --accent-clair: #e2f3ee; --accent-tres-clair: #f1f9f6; --accent-vif: #0f8a76; --accent-lumineux: #3cc3a4; --accent-bord: #bfe3d8; --accent-ombre: rgba(11, 110, 95, 0.3); }
.cat-entreprise { --accent: #2f5bd3; --accent-fonce: #2445a6; --accent-clair: #e6edfc; --accent-tres-clair: #f4f7fe; --accent-vif: #3b6cf0; --accent-lumineux: #7aa2ff; --accent-bord: #c3d3f7; --accent-ombre: rgba(47, 91, 211, 0.3); }
.cat-impots { --accent: #c2410c; --accent-fonce: #9a3412; --accent-clair: #ffedd5; --accent-tres-clair: #fff7ed; --accent-vif: #ea580c; --accent-lumineux: #fdba74; --accent-bord: #fbd3ad; --accent-ombre: rgba(194, 65, 12, 0.28); }
.cat-exonerations { --accent: #7c3aed; --accent-fonce: #6227c9; --accent-clair: #efe7fd; --accent-tres-clair: #f8f4fe; --accent-vif: #8b5cf6; --accent-lumineux: #c4b5fd; --accent-bord: #d9c8fb; --accent-ombre: rgba(124, 58, 237, 0.28); }

/* menu du haut : on voit qu'il défile sur téléphone */
@media (max-width: 760px) {
  .haut nav { -webkit-mask-image: linear-gradient(90deg, #000 82%, transparent); mask-image: linear-gradient(90deg, #000 82%, transparent); padding-right: 28px; }
}

/* accueil : raccourcis de catégories dans le bandeau */
.raccourcis { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; margin-top: 22px; }
.raccourcis a { display: flex; align-items: center; gap: 9px; padding: 10px 12px; border-radius: 14px; background: rgba(255, 255, 255, 0.96); color: var(--encre); text-decoration: none; font-weight: 700; font-size: 0.92rem; line-height: 1.2; box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12); transition: transform 0.15s; }
.raccourcis a:hover { transform: translateY(-2px); color: var(--encre); }
.raccourcis small { margin-left: auto; font-size: 0.78rem; font-weight: 700; color: var(--accent); background: var(--accent-clair); border-radius: 20px; padding: 1px 8px; }
.raccourci-ico { flex: none; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--accent-vif), var(--accent-fonce)); }
.raccourci-ico svg { width: 17px; height: 17px; }

/* accueil : titres de catégorie */
.categorie { gap: 12px; }
.categorie::after { background: linear-gradient(90deg, var(--accent-bord), transparent); height: 2px; border-radius: 2px; }
.cat-pastille { flex: none; width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--accent-vif), var(--accent-fonce)); box-shadow: 0 6px 14px var(--accent-ombre); }

/* tuiles des calculateurs */
.tuile { position: relative; overflow: hidden; border: 1px solid var(--trait); background: linear-gradient(180deg, #fff, #fff 60%, var(--accent-tres-clair)); }
.tuile::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: linear-gradient(180deg, var(--accent-vif), var(--accent-lumineux)); opacity: 0.85; }
.tuile:hover { border-color: var(--accent-bord); box-shadow: 0 14px 28px -14px var(--accent-ombre); }
.tuile .ico { flex: none; width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; font-weight: 800; font-size: 0.85rem; letter-spacing: -0.02em; color: #fff; background: linear-gradient(135deg, var(--accent-vif), var(--accent-fonce)); box-shadow: 0 6px 14px var(--accent-ombre); }
.tuile strong { color: var(--encre); }
.tuile:hover strong { color: var(--accent-fonce); }

/* page de calculateur : en-tête coloré selon la catégorie */
.tete-page { position: relative; overflow: hidden; margin: 0 0 20px; padding: 18px 20px 4px; border-radius: 22px; border: 1px solid var(--accent-bord); background: radial-gradient(120% 120% at 100% 0%, var(--accent-clair) 0%, transparent 60%), linear-gradient(180deg, #fff, var(--accent-tres-clair)); }
.tete-page::after { content: ""; position: absolute; right: -40px; top: -40px; width: 160px; height: 160px; border-radius: 50%; border: 26px solid var(--accent-clair); opacity: 0.7; pointer-events: none; }
.tete-page > * { position: relative; z-index: 1; }
.tete-ligne { display: flex; align-items: center; gap: 14px; margin-bottom: 10px; }
.tete-ligne h1 { margin: 0; }
.tete-ico { flex: none; width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; color: #fff; font-weight: 800; background: linear-gradient(135deg, var(--accent-vif), var(--accent-fonce)); box-shadow: 0 8px 18px var(--accent-ombre); }
.tete-ico svg { width: 26px; height: 26px; }
.tete-page .accroche { margin-bottom: 16px; }
.tete-page .fil a:hover { color: var(--accent); }
h2 { position: relative; }
article h2::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 10px; vertical-align: 0.12em; background: linear-gradient(135deg, var(--accent-vif), var(--accent-lumineux)); }
@media (max-width: 560px) {
  .tete-page { padding: 14px 14px 2px; border-radius: 18px; }
  .tete-ico { width: 44px; height: 44px; border-radius: 13px; }
  .tete-ico svg { width: 22px; height: 22px; }
}

/* autres calculateurs : grille de cartes, chacune dans sa couleur */
.autres-grille { list-style: none; padding: 0; margin: 12px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 8px; }
.autres-grille a { display: flex; align-items: center; gap: 10px; height: 100%; padding: 9px 12px; border-radius: 12px; background: #fff; border: 1px solid var(--trait); color: var(--encre); text-decoration: none; font-size: 0.92rem; line-height: 1.3; transition: border-color 0.15s, transform 0.15s; }
.autres-grille a:hover { border-color: var(--accent-bord); color: var(--accent-fonce); transform: translateY(-1px); }
.mini-ico { flex: none; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; color: var(--accent); background: var(--accent-clair); font-size: 0.72rem; font-weight: 800; }
.mini-ico svg { width: 17px; height: 17px; }

/* pied de page */
.bas { background: radial-gradient(90% 140% at 0% 0%, #143a35 0%, transparent 55%), #0f1c25; }
.bas .enveloppe { display: block; padding-top: 34px; padding-bottom: 26px; }
.bas-haut { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 22px 28px; }
.bas-marque p { margin: 10px 0 0; max-width: 34ch; line-height: 1.5; }
.logo-clair { color: #fff; }
.logo-clair > span:last-child { color: #5fd3b8; }
.bas-cats, .bas-liens { display: flex; flex-direction: column; gap: 8px; }
.bas-cats a { display: inline-flex; align-items: center; gap: 9px; }
.bas-cats .point { width: 10px; height: 10px; border-radius: 3px; background: linear-gradient(135deg, var(--accent-lumineux), var(--accent-vif)); flex: none; }
.bas .gerer-cookies { align-self: flex-start; padding: 5px 12px; border-radius: 20px; border: 1px solid rgba(255, 255, 255, 0.25); }
.bas .gerer-cookies:hover { background: rgba(255, 255, 255, 0.08); text-decoration: none; }
.bas-note { margin: 24px 0 0; padding-top: 16px; border-top: 1px solid rgba(255, 255, 255, 0.1); font-size: 0.82rem; color: #8b9aa3; }
@media (max-width: 700px) { .bas-haut { grid-template-columns: 1fr 1fr; } .bas-marque { grid-column: 1 / -1; } }

/* fenêtre « Gérer mes cookies » quand celle de Google n'est pas disponible */
.cookies-boite { width: min(460px, calc(100vw - 32px)); border: 0; border-radius: 20px; padding: 22px 22px 18px; color: var(--encre); background: #fff; box-shadow: 0 24px 60px rgba(15, 28, 37, 0.35); }
.cookies-boite::backdrop { background: rgba(15, 28, 37, 0.5); backdrop-filter: blur(2px); }
.cookies-boite h2 { margin: 0 0 10px; font-size: 1.2rem; }
.cookies-boite p { margin: 0 0 12px; font-size: 0.95rem; color: var(--doux); }
.cookies-boite .cookies-raison { color: var(--encre); background: var(--accent-tres-clair); border: 1px solid var(--accent-bord); border-radius: 12px; padding: 10px 12px; }
.cookies-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; margin-top: 6px; }
.cookies-plus { color: var(--accent-fonce); border: 1.5px solid var(--accent-bord); background: #fff; font-size: 0.92rem; padding: 10px 14px; }
.cookies-fermer { background: var(--accent); color: #fff; border: 0; font: inherit; font-weight: 700; font-size: 0.92rem; padding: 10px 18px; cursor: pointer; }
.cookies-fermer:hover { background: var(--accent-fonce); }

@media print { .raccourcis, .cookies-boite, .tete-page::after { display: none !important; } .tete-page { border: 0; background: none; padding: 0; } }
