/* Prime CEE Séchage — identité "dossier / outil" : slate froid, bleu administratif, encadrés chiffres.
   System fonts only, zéro dépendance. Distincte des autres satellites (ton utilitaire, pratique). */

:root {
  --ink: #16212c;
  --slate: #22303c;
  --slate-2: #2c3e4c;
  --muted: #5a6b78;
  --line: #d7e0e8;
  --line-soft: #e7edf2;
  --bg: #eef2f6;
  --panel: #ffffff;
  --accent: #0f5aa8;
  --accent-dark: #0b4680;
  --accent-deep: #083661;
  --accent-soft: #e8f1fb;
  --gold: #a86a12;
  --gold-soft: #fbf1dd;
  --ok: #1f7a4d;
  --no: #c0392b;
  --shadow: 0 1px 3px rgba(22, 33, 44, 0.10), 0 6px 18px rgba(22, 33, 44, 0.06);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 18px;
  line-height: 1.62;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent-dark); }

h1, h2, h3 { line-height: 1.22; letter-spacing: -0.01em; }
h1 { font-size: 2.05rem; margin: 0 0 0.5em; }
h2 { font-size: 1.55rem; margin: 1.7em 0 0.55em; }
h3 { font-size: 1.16rem; margin: 1.3em 0 0.35em; }
p { margin: 0 0 1em; }
strong { color: var(--slate-2); }

.wrap { max-width: 780px; margin: 0 auto; padding: 0 20px; }
.num { font-variant-numeric: tabular-nums; }

/* ---------- En-tête ---------- */
.topbar { background: var(--slate); color: #fff; border-bottom: 3px solid var(--accent); }
.topbar-inner {
  max-width: 780px; margin: 0 auto; padding: 12px 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: #fff; font-weight: 800; font-size: 1.1rem; letter-spacing: -0.02em; }
.brand svg { flex: 0 0 auto; }
.brand span { color: #7fb4e8; }
.topbar-wa { text-decoration: none; color: #fff; font-weight: 700; font-size: 0.95rem; white-space: nowrap; border: 1.5px solid #4a6376; border-radius: 6px; padding: 6px 13px; }
.topbar-wa:hover { border-color: var(--accent); background: var(--accent); }

/* ---------- Hero ---------- */
.hero {
  background: linear-gradient(160deg, var(--slate-2) 0%, var(--accent-deep) 100%);
  color: #eaf1f8; padding: 44px 0 40px; border-bottom: 5px solid var(--accent);
}
.hero .kicker {
  display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,0.10);
  color: #cfe1f4; font-weight: 700; font-size: 0.8rem; letter-spacing: 0.05em; text-transform: uppercase;
  padding: 5px 12px; border-radius: 4px; margin-bottom: 16px; border: 1px solid rgba(255,255,255,0.16);
}
.hero h1 { color: #fff; font-size: 2.3rem; font-weight: 800; }
.hero h1 em { font-style: normal; color: #7fb4e8; }
.hero .lead { font-size: 1.15rem; color: #d3e1ef; max-width: 660px; }
.hero-cta { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Boutons ---------- */
.btn { display: inline-block; text-decoration: none; font-weight: 800; font-size: 1rem; padding: 13px 24px; border-radius: 8px; text-align: center; transition: transform .05s ease; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: #fff; box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--accent-dark); }
.btn-wa { background: #1faf54; color: #fff; }
.btn-wa:hover { background: #148a41; }
.btn-ghost { background: transparent; color: #eaf1f8; border: 2px solid #4a6376; }
.btn-ghost:hover { border-color: var(--accent); color: #fff; }

/* ---------- Sections ---------- */
section { padding: 6px 0; }
.section-alt { background: #fff; }
.section-dark { background: var(--slate); color: #dfe8f0; }
.section-dark h2, .section-dark h3 { color: #fff; }
.section-dark strong { color: #9cc6ec; }
.section-pad { padding: 34px 0; }
.lede { font-size: 1.1rem; color: var(--slate-2); }

/* ---------- Encadrés chiffres (signature) ---------- */
.statgrid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 24px 0 6px; }
.stat { background: var(--panel); border: 1px solid var(--line); border-top: 4px solid var(--accent); border-radius: 8px; padding: 16px 14px; box-shadow: var(--shadow); }
.stat .v { font-size: 1.55rem; font-weight: 800; color: var(--accent-dark); line-height: 1.05; font-variant-numeric: tabular-nums; }
.stat .k { font-size: 0.82rem; color: var(--muted); margin-top: 6px; line-height: 1.35; text-transform: uppercase; letter-spacing: 0.03em; }
.stat.gold { border-top-color: var(--gold); }
.stat.gold .v { color: var(--gold); }

/* ---------- Étapes numérotées (comment marche le CEE) ---------- */
.steps { counter-reset: step; margin: 22px 0; padding: 0; list-style: none; }
.steps li { counter-increment: step; position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 16px 16px 16px 62px; margin: 10px 0; box-shadow: var(--shadow); }
.steps li::before { content: counter(step); position: absolute; left: 14px; top: 14px; width: 34px; height: 34px; background: var(--accent); color: #fff; border-radius: 8px; font-weight: 800; font-size: 1.05rem; display: flex; align-items: center; justify-content: center; }
.steps li h3 { margin: 0 0 4px; font-size: 1.05rem; color: var(--slate-2); }
.steps li p { margin: 0; font-size: 0.98rem; }

/* ---------- "Ce n'est pas / c'est" ---------- */
.contrast { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 22px 0; }
.contrast .col { border-radius: 10px; padding: 18px; }
.contrast .is-not { background: #fdeceb; border: 1px solid #f3c9c5; }
.contrast .is-yes { background: var(--accent-soft); border: 1px solid #c8def5; }
.contrast h3 { margin-top: 0; font-size: 1.02rem; }
.contrast .is-not h3 { color: var(--no); }
.contrast .is-yes h3 { color: var(--accent-dark); }
.contrast ul { margin: 0; padding-left: 18px; font-size: 0.96rem; }
.contrast li { margin: 6px 0; }

/* ---------- Ce qui est financé ---------- */
.fin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 20px 0; }
.fin { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 18px; box-shadow: var(--shadow); }
.fin .tag { display: inline-block; background: var(--accent-soft); color: var(--accent-dark); font-size: 0.74rem; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; padding: 3px 9px; border-radius: 4px; margin-bottom: 10px; }
.fin h3 { margin: 0 0 6px; font-size: 1.05rem; }
.fin p { margin: 0; font-size: 0.96rem; }

/* ---------- 4 conditions ---------- */
.cond-grid { counter-reset: cond; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 22px 0; }
.cond { counter-increment: cond; position: relative; background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 8px; padding: 16px 16px 16px 18px; box-shadow: var(--shadow); }
.cond .n { font-size: 0.78rem; font-weight: 800; color: var(--accent); letter-spacing: 0.05em; text-transform: uppercase; }
.cond h3 { margin: 2px 0 5px; font-size: 1.06rem; color: var(--slate-2); }
.cond p { margin: 0; font-size: 0.95rem; color: var(--muted); }

/* ---------- Bande prime (accent) ---------- */
.prime-band { background: linear-gradient(160deg, var(--accent-dark), var(--accent-deep)); color: #eaf1f8; border-radius: 12px; padding: 26px; margin: 26px 0; }
.prime-band h2 { margin-top: 0; color: #fff; }
.prime-band strong { color: #ffe6b0; }
.prime-band .big { font-size: 2rem; font-weight: 800; color: #fff; display: block; margin: 6px 0; font-variant-numeric: tabular-nums; }

/* ---------- Exemple chiffré ---------- */
.example { background: var(--gold-soft); border: 1px solid #ecd6a8; border-left: 4px solid var(--gold); border-radius: 10px; padding: 20px; margin: 22px 0; }
.example .tag { display: inline-block; background: var(--gold); color: #fff; font-size: 0.74rem; font-weight: 800; text-transform: uppercase; letter-spacing: 0.04em; padding: 3px 10px; border-radius: 4px; margin-bottom: 12px; }
.example-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 12px 0; font-variant-numeric: tabular-nums; }
.example-row .from { color: #8a6a2f; font-weight: 700; }
.example-row .arrow { color: var(--gold); font-weight: 800; font-size: 1.25rem; }
.example-row .to { color: var(--ok); font-weight: 800; }

/* ---------- Note / callout ---------- */
.note { background: #fff; border: 1px solid var(--line); border-left: 4px solid var(--slate-2); border-radius: 8px; padding: 15px 18px; margin: 18px 0; box-shadow: var(--shadow); font-size: 0.98rem; }
.note strong { color: var(--slate-2); }

/* ---------- Checklist éligibilité ---------- */
.check-grid { display: grid; gap: 12px; margin: 22px 0; }
.check { display: flex; gap: 13px; align-items: flex-start; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; box-shadow: var(--shadow); }
.check .ic { flex: 0 0 auto; width: 28px; height: 28px; border-radius: 7px; background: var(--ok); color: #fff; font-weight: 800; display: flex; align-items: center; justify-content: center; font-size: 1rem; }
.check.no .ic { background: var(--no); }
.check .body { min-width: 0; }
.check strong { display: block; color: var(--slate-2); }
.check p { margin: 2px 0 0; font-size: 0.96rem; color: var(--muted); }

/* ---------- Zones ---------- */
.zones { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 20px 0; }
.zone { background: var(--panel); border: 1px solid var(--line); border-top: 4px solid var(--accent); border-radius: 10px; padding: 18px; box-shadow: var(--shadow); }
.zone h3 { margin: 0 0 6px; font-size: 1.08rem; color: var(--slate-2); }
.zone .scope { font-weight: 800; color: var(--accent-dark); }
.zone ul { margin: 8px 0 0; padding-left: 18px; font-size: 0.95rem; color: var(--muted); }
.zone li { margin: 4px 0; }

/* ---------- Anti-arnaque (5 points) ---------- */
.arn { counter-reset: arn; margin: 24px 0; }
.arn-item { counter-increment: arn; position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 18px 18px 18px 66px; margin: 14px 0; box-shadow: var(--shadow); }
.arn-item::before { content: counter(arn); position: absolute; left: 16px; top: 16px; width: 36px; height: 36px; background: var(--slate-2); color: #fff; border-radius: 9px; font-weight: 800; font-size: 1.1rem; display: flex; align-items: center; justify-content: center; }
.arn-item h3 { margin: 0 0 6px; font-size: 1.1rem; color: var(--slate-2); }
.arn-item p { margin: 0; font-size: 0.97rem; }
.arn-item .flag { display: inline-block; margin-top: 10px; font-size: 0.9rem; font-weight: 700; color: var(--no); }
.arn-item .flag::before { content: "⚑ "; }

/* ---------- CTA final ---------- */
.cta-final { text-align: center; padding: 42px 0; }
.cta-final h2 { color: #fff; }
.cta-final p.sub { color: #cfe1f4; max-width: 580px; margin: 0 auto 12px; }
.cta-final .btn { margin: 6px; }
.wa-line { margin-top: 14px; font-size: 1.02rem; }
.wa-line a { color: #eaf1f8; font-weight: 700; }

/* ---------- FAQ ---------- */
.faq details { border: 1px solid var(--line); border-radius: 8px; margin: 10px 0; background: var(--panel); overflow: hidden; box-shadow: var(--shadow); }
.faq summary { cursor: pointer; padding: 15px 46px 15px 18px; font-weight: 700; color: var(--slate-2); position: relative; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 18px; top: 12px; font-size: 1.4rem; color: var(--accent); font-weight: 800; }
.faq details[open] summary::after { content: "\2013"; }
.faq details[open] summary { border-bottom: 1px solid var(--line-soft); }
.faq .answer { padding: 6px 18px 15px; }
.faq .answer p { margin: 0.5em 0; }

/* ---------- Déroulé du dossier (timeline verticale) ---------- */
.timeline { counter-reset: tl; margin: 24px 0 6px; padding: 0; list-style: none; position: relative; }
.timeline::before { content: ""; position: absolute; left: 17px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.timeline li { counter-increment: tl; position: relative; padding: 0 0 20px 54px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: counter(tl); position: absolute; left: 0; top: 0; width: 36px; height: 36px; background: var(--accent); color: #fff; border-radius: 50%; font-weight: 800; font-size: 1rem; display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 4px var(--bg); }
.section-alt .timeline li::before { box-shadow: 0 0 0 4px #fff; }
.timeline li h3 { margin: 4px 0 4px; font-size: 1.08rem; color: var(--slate-2); }
.timeline li p { margin: 0; font-size: 0.97rem; color: var(--muted); }
.timeline .who { display: inline-block; margin-top: 6px; font-size: 0.82rem; font-weight: 700; color: var(--accent-dark); background: var(--accent-soft); border-radius: 4px; padding: 2px 8px; }

/* ---------- Calcul de prime travaillé (page fiche) ---------- */
.calc { counter-reset: calc; margin: 24px 0; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); background: var(--panel); }
.calc-step { counter-increment: calc; position: relative; display: grid; grid-template-columns: 46px 1fr; gap: 16px; padding: 18px 20px; border-bottom: 1px solid var(--line-soft); }
.calc-step:last-of-type { border-bottom: 0; }
.calc-step::before { content: counter(calc); align-self: start; width: 34px; height: 34px; background: var(--accent-soft); color: var(--accent-dark); border-radius: 8px; font-weight: 800; display: flex; align-items: center; justify-content: center; font-size: 1rem; }
.calc-step h3 { margin: 2px 0 4px; font-size: 1.04rem; color: var(--slate-2); }
.calc-step p { margin: 0; font-size: 0.96rem; color: var(--muted); }
.calc-step .val { display: block; margin-top: 8px; font-size: 1.12rem; font-weight: 800; color: var(--accent-dark); font-variant-numeric: tabular-nums; }
.calc-total { background: linear-gradient(160deg, var(--accent-dark), var(--accent-deep)); color: #eaf1f8; padding: 20px; text-align: center; }
.calc-total .val { display: block; font-size: 2rem; font-weight: 800; color: #fff; margin-top: 4px; font-variant-numeric: tabular-nums; }
.calc-total .lbl { font-size: 0.9rem; color: #cfe1f4; text-transform: uppercase; letter-spacing: 0.04em; }

/* ---------- Prérequis (liste à coche compacte) ---------- */
.prereq { display: grid; gap: 10px; margin: 20px 0; padding: 0; list-style: none; }
.prereq li { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px 12px 44px; box-shadow: var(--shadow); font-size: 0.97rem; }
.prereq li::before { content: "✓"; position: absolute; left: 13px; top: 12px; width: 22px; height: 22px; background: var(--ok); color: #fff; border-radius: 6px; font-size: 0.85rem; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.prereq li strong { color: var(--slate-2); }

/* ---------- Sous-navigation (fil de pages) ---------- */
.pagenav { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 0; }
.pagenav a { text-decoration: none; font-size: 0.86rem; font-weight: 700; color: #cfe1f4; border: 1px solid rgba(255,255,255,0.18); border-radius: 999px; padding: 5px 13px; }
.pagenav a:hover { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ---------- Divers ---------- */
.footnote { font-size: 0.84rem; color: var(--muted); margin-top: 18px; }
.credit { font-size: 0.95rem; color: var(--muted); background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; margin: 22px 0; }
.crumb { font-size: 0.9rem; color: var(--muted); padding: 14px 0 0; }
.crumb a { color: var(--accent-dark); }
.inline-cta { margin: 24px 0; text-align: center; }

/* ---------- Pied ---------- */
.foot { background: var(--ink); color: #a9bccb; padding: 30px 0 34px; margin-top: 30px; border-top: 3px solid var(--accent); font-size: 0.92rem; }
.foot a { color: #d3e1ef; text-decoration: none; }
.foot a:hover { text-decoration: underline; }
.foot nav { display: flex; flex-wrap: wrap; gap: 16px; margin-bottom: 14px; }
.foot .legal { color: #7c93a5; font-size: 0.84rem; }

/* ---------- 404 ---------- */
.err { text-align: center; padding: 60px 0; }
.err h1 { font-size: 3rem; color: var(--accent); }

/* ---------- Responsive ---------- */
@media (max-width: 680px) {
  body { font-size: 17px; }
  h1 { font-size: 1.7rem; }
  .hero h1 { font-size: 1.85rem; }
  h2 { font-size: 1.32rem; }
  .statgrid { grid-template-columns: 1fr 1fr; }
  .contrast, .fin-grid, .cond-grid, .zones { grid-template-columns: 1fr; }
  .hero-cta .btn, .cta-final .btn { width: 100%; }
  .topbar-inner { justify-content: center; }
}
@media (max-width: 380px) {
  .statgrid { grid-template-columns: 1fr; }
}
