@import url("https://fonts.googleapis.com/css2?family=Source+Sans+3:wght@400;500;600;700&family=Source+Serif+4:opsz,wght@8..60,600;8..60,700&display=swap");

:root {
  --ink: #1D2433; --muted: #5B6475; --soft: #8A93A3; --paper: #F6F5F1; --card: #FFFFFF; --line: #E6E2D8; --line2: #EFECE4;
  --teal: #0F5C4D; --teal-2: #13705E; --teal-soft: #E7F2EF; --gold: #B98321; --gold-soft: #FBF2E1; --ochre: #8F5B1C; --ochre-soft: #F6EAD8;
  --green: #1F7A4A; --green-soft: #E3F3EA; --red: #A3322A; --red-soft: #FBE9E7;
  --r: 14px; --shadow: 0 1px 2px rgba(29,36,51,.06), 0 4px 16px rgba(29,36,51,.06); --shadow-h: 0 2px 4px rgba(29,36,51,.08), 0 10px 28px rgba(29,36,51,.10);
  --serif: "Source Serif 4", Georgia, serif; --sans: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 18px/1.6 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: var(--teal); }
h1, h2, h3, h4 { font-family: var(--serif); line-height: 1.22; letter-spacing: -.01em; color: var(--ink); }
h1 { font-size: 2rem; margin: .2rem 0 .5rem; } h2 { font-size: 1.45rem; margin: 2rem 0 .8rem; } h3 { font-size: 1.18rem; margin: 1.1rem 0 .45rem; }
h4 { font-family: var(--sans); font-weight: 700; font-size: 1rem; margin: 1rem 0 .3rem; }
.sec-h { margin-top: 2.4rem; }
.lead { font-size: 1.08rem; color: var(--muted); margin-top: 0; }
.hint { color: var(--muted); font-size: .95rem; }
.i { width: 1.15em; height: 1.15em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; vertical-align: -.2em; flex: none; }

/* ------------------------------------------------ en-tête */
.top { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; gap: 1.2rem; height: 66px; padding: 0 22px;
  background: rgba(255,255,255,.96); backdrop-filter: blur(6px); border-bottom: 1px solid var(--line); }
.logo { display: flex; align-items: center; gap: .65rem; color: var(--ink); text-decoration: none; line-height: 1.1; font-weight: 700; }
.logo .mk { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: var(--teal); color: #fff; font: 700 1rem var(--serif); }
.logo em { display: block; color: var(--teal); font-style: normal; font-weight: 600; font-size: .9rem; }
.topnav { display: flex; gap: .2rem; margin-left: auto; }
.topnav a { display: flex; align-items: center; gap: .45rem; padding: .5rem .8rem; border-radius: 10px; color: var(--muted); text-decoration: none; font-weight: 600; font-size: .97rem; }
.topnav a:hover, .topnav a.on { background: var(--teal-soft); color: var(--teal); }
.avatar { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--gold-soft); color: var(--ochre); font-weight: 700; text-decoration: none; border: 2px solid #F0DDB8; }

/* ------------------------------------------------ colonnes */
.wrap { display: grid; grid-template-columns: 290px 1fr; max-width: 1340px; margin: 0 auto; }
.side { position: sticky; top: 66px; align-self: start; height: calc(100vh - 66px); overflow: auto; padding: 1.2rem .9rem 2rem; border-right: 1px solid var(--line); background: var(--card); }
.side-prog { padding: .2rem .6rem 1rem; border-bottom: 1px solid var(--line2); margin-bottom: .8rem; }
.side-prog small { color: var(--soft); text-transform: uppercase; letter-spacing: .06em; font-weight: 700; font-size: .72rem; } .side-prog b { font-size: .9rem; color: var(--teal); }
.side-h { color: var(--soft); text-transform: uppercase; letter-spacing: .06em; font-weight: 700; font-size: .72rem; margin: 1rem .6rem .4rem; }
.nav-s { display: flex; align-items: center; gap: .7rem; padding: .55rem .6rem; border-radius: 10px; text-decoration: none; color: var(--ink); line-height: 1.25; margin-bottom: 2px; }
.nav-s .t { display: flex; flex-direction: column; min-width: 0; } .nav-s .t small { color: var(--soft); font-size: .78rem; font-weight: 600; } .nav-s .t b { font-weight: 600; font-size: .95rem; }
.nav-s:hover { background: var(--paper); } .nav-s.on { background: var(--teal-soft); } .nav-s.on .t b { color: var(--teal); }
.nav-s.lock { color: var(--soft); } .nav-s.lock .t b { color: var(--soft); }
.st { display: grid; place-items: center; width: 30px; height: 30px; flex: none; color: var(--soft); }
.st.done { background: var(--green); color: #fff; border-radius: 50%; } .st.done .i { width: 16px; height: 16px; stroke-width: 3; }
.nav-s.home .st, .nav-s:last-child .st { color: var(--teal); }
.ring { width: 28px; height: 28px; } .ring circle { fill: none; stroke: var(--line); stroke-width: 3; } .ring .v { stroke: var(--teal); stroke-linecap: round; }
.main { padding: 1.8rem 32px 6rem; min-width: 0; max-width: 1000px; }
.bar { height: 8px; background: var(--line2); border-radius: 6px; overflow: hidden; margin: .4rem 0; }
.bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--teal), var(--teal-2)); border-radius: 6px; }

/* ------------------------------------------------ boutons */
.btn { display: inline-flex; align-items: center; gap: .5rem; border: 0; border-radius: 11px; background: var(--teal); color: #fff; font: 700 1rem var(--sans);
  padding: .7rem 1.2rem; cursor: pointer; text-decoration: none; transition: background .15s, transform .05s; }
.btn:hover { background: var(--teal-2); } .btn:active { transform: translateY(1px); }
.btn.big { font-size: 1.08rem; padding: .9rem 1.5rem; margin: .8rem 0; }
.btn.ghost { background: var(--card); color: var(--teal); box-shadow: inset 0 0 0 2px var(--teal); } .btn.ghost:hover { background: var(--teal-soft); }
.btn.sm { font-size: .9rem; padding: .45rem .85rem; }
.row { display: flex; gap: .8rem; flex-wrap: wrap; align-items: center; }
.help { position: fixed; right: 20px; bottom: 20px; display: flex; align-items: center; gap: .45rem; background: var(--ink); color: #fff; padding: .7rem 1.1rem;
  border-radius: 30px; text-decoration: none; font-weight: 700; box-shadow: var(--shadow-h); z-index: 9; }

/* ------------------------------------------------ tableau de bord */
.hero-card { display: grid; grid-template-columns: 300px 1fr; gap: 1.5rem; align-items: center; background: var(--card); border-radius: 18px; padding: 1rem;
  text-decoration: none; color: var(--ink); box-shadow: var(--shadow); border: 1px solid var(--line); margin: 1rem 0 1.4rem; transition: box-shadow .2s; }
.hero-card:hover { box-shadow: var(--shadow-h); }
.hero-card img { width: 100%; aspect-ratio: 16 / 8.4; object-fit: cover; border-radius: 12px; border: 1px solid var(--line2); }
.hero-card small { color: var(--teal); font-weight: 700; text-transform: uppercase; letter-spacing: .05em; font-size: .8rem; }
.hero-card h2 { margin: .25rem 0 .3rem; font-size: 1.55rem; } .hero-card p { margin: 0 0 .3rem; color: var(--muted); } .hero-card .bar { max-width: 360px; } .hero-card .btn { margin-top: .6rem; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .9rem; }
.stat { display: flex; flex-direction: column; gap: .1rem; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: .9rem 1rem; text-decoration: none; color: var(--ink); }
.stat .i { color: var(--gold); width: 1.4em; height: 1.4em; } .stat b { font: 700 1.7rem var(--serif); } .stat b small { font-size: 1rem; color: var(--soft); } .stat b.sm { font-size: 1.25rem; }
.stat span { color: var(--muted); font-size: .92rem; }
.quick { display: flex; flex-wrap: wrap; gap: .6rem; margin: 1rem 0 .4rem; }
.quick a { display: inline-flex; align-items: center; gap: .45rem; background: var(--card); border: 1px solid var(--line); border-radius: 30px; padding: .5rem .95rem; text-decoration: none; color: var(--ink); font-weight: 600; font-size: .95rem; }
.quick a:hover { border-color: var(--teal); color: var(--teal); } .quick .i { color: var(--teal); }
.sgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 1.1rem; }
.scard { display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; text-decoration: none; color: var(--ink);
  box-shadow: var(--shadow); transition: box-shadow .2s, transform .2s; }
.scard:hover { box-shadow: var(--shadow-h); transform: translateY(-2px); }
.scard .th { position: relative; } .scard img { display: block; width: 100%; aspect-ratio: 16 / 8.4; object-fit: cover; border-bottom: 1px solid var(--line2); }
.scard.lock img { filter: grayscale(.9) opacity(.6); }
.badge { position: absolute; left: 10px; top: 10px; display: inline-flex; align-items: center; gap: .3rem; background: rgba(255,255,255,.95); color: var(--ink);
  border-radius: 20px; padding: .2rem .65rem; font-size: .8rem; font-weight: 700; box-shadow: 0 1px 4px rgba(0,0,0,.12); }
.badge.ok { background: var(--green); color: #fff; } .badge.lock { color: var(--muted); } .badge .i { width: 14px; height: 14px; }
.scard .bd { padding: .8rem 1rem 1rem; } .scard small { color: var(--soft); font-weight: 600; font-size: .85rem; } .scard h3 { margin: .2rem 0 .5rem; font-size: 1.12rem; }

/* ------------------------------------------------ cartes génériques */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; }
.card { display: block; background: var(--card); border: 1px solid var(--line); border-radius: var(--r); padding: 1.1rem 1.2rem; text-decoration: none; color: var(--ink); box-shadow: var(--shadow); }
a.card { transition: box-shadow .2s, transform .2s; } a.card:hover { box-shadow: var(--shadow-h); transform: translateY(-2px); }
.card h3 { margin: .15rem 0 .4rem; } .card small { color: var(--soft); font-weight: 600; } .card p { margin: .2rem 0 .6rem; color: var(--muted); } .card ul { padding-left: 1.1rem; margin: .3rem 0; }
.card.tool h3 { color: var(--teal); } .card.lock { opacity: .6; }

/* ------------------------------------------------ séance */
.crumb { color: var(--soft); font-size: .92rem; font-weight: 600; } .crumb a { color: var(--muted); text-decoration: none; } .crumb a:hover { color: var(--teal); }
.stepper { display: flex; gap: 0; margin: 1rem 0 1.4rem; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: .5rem; box-shadow: var(--shadow); overflow-x: auto; }
.stp { flex: 1; display: flex; align-items: center; gap: .6rem; padding: .55rem .7rem; border-radius: 11px; text-decoration: none; color: var(--muted); min-width: 135px; position: relative; }
.stp + .stp::before { content: ""; position: absolute; left: -6px; top: 50%; width: 12px; height: 2px; background: var(--line); }
.stp .dot { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--paper); border: 2px solid var(--line); color: var(--soft); flex: none; }
.stp .lb { display: flex; flex-direction: column; line-height: 1.15; font-weight: 700; color: var(--ink); } .stp .lb small { color: var(--soft); font-weight: 600; font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; }
.stp:hover { background: var(--paper); }
.stp.ok .dot { background: var(--green); border-color: var(--green); color: #fff; } .stp.ok .dot .i { stroke-width: 3; }
.stp.on { background: var(--teal-soft); } .stp.on .dot { background: var(--teal); border-color: var(--teal); color: #fff; } .stp.on .lb { color: var(--teal); }
.step { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 1.4rem 1.6rem 1.6rem; box-shadow: var(--shadow); }
.step > h2:first-child { margin-top: .2rem; }
.vid video { width: 100%; border-radius: 12px; background: #000; aspect-ratio: 16 / 9; display: block; }
.ess { padding-left: 1.2rem; } .ess li { margin: .35rem 0; } .ess li::marker { color: var(--gold); }
.lecon { width: 100%; height: 72vh; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.okmsg { display: inline-flex; align-items: center; gap: .4rem; color: var(--green); font-weight: 700; background: var(--green-soft); padding: .45rem .9rem; border-radius: 30px; }
.next { margin-top: 1.2rem; display: flex; justify-content: flex-end; }
.tasks { padding-left: 1.3rem; } .tasks li { margin: .45rem 0; } .tasks li::marker { color: var(--teal); font-weight: 700; }
.note { background: var(--gold-soft); border-left: 4px solid var(--gold); padding: .75rem 1rem; border-radius: 10px; margin: .9rem 0; }
.tabs { display: flex; gap: .4rem; flex-wrap: wrap; margin: .6rem 0 1.2rem; }
.tab { padding: .5rem 1rem; border-radius: 30px; background: var(--card); border: 1px solid var(--line); text-decoration: none; color: var(--ink); font-weight: 600; }
.tab.on { background: var(--teal); color: #fff; border-color: var(--teal); }

/* ------------------------------------------------ formulaires */
.f { display: block; margin: .9rem 0; } .f > span { display: block; font-weight: 600; margin-bottom: .3rem; }
.f .in { display: flex; align-items: center; gap: .5rem; } .f .in em { font-style: normal; color: var(--muted); white-space: nowrap; }
input, select, textarea { font: inherit; padding: .6rem .8rem; border: 1.5px solid #D5D0C4; border-radius: 10px; background: #fff; width: 100%; max-width: 640px; color: var(--ink); transition: border-color .15s, box-shadow .15s; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 4px var(--teal-soft); }
.f.num input { max-width: 240px; } input[type=radio], input[type=checkbox] { width: 1.15rem; height: 1.15rem; margin: 0 .55rem 0 0; accent-color: var(--teal); vertical-align: -.15em; }
.radio { display: block; padding: .6rem .85rem; margin: .35rem 0; background: var(--card); border: 1.5px solid var(--line); border-radius: 11px; cursor: pointer; transition: border-color .15s; }
.radio:hover { border-color: #C9C4B6; } .radio:has(input:checked) { border-color: var(--teal); background: var(--teal-soft); }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; } .chip { padding: .45rem .9rem; border: 1.5px solid var(--line); border-radius: 30px; background: #fff; cursor: pointer; }
.chip:has(input:checked) { background: var(--teal-soft); border-color: var(--teal); }
.fiche-box { border: 1px solid var(--line); border-radius: 14px; padding: .4rem 1.2rem 1rem; margin: 1rem 0; background: #FCFBF8; }
.step .fiche-box { background: #FCFBF8; } .main > .fiche { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: .6rem 1.6rem 1.4rem; box-shadow: var(--shadow); margin-top: .8rem; }
.fiche .fh { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; } .fiche .fh h3 { color: var(--teal); }
.calc { display: flex; flex-wrap: wrap; align-items: baseline; gap: .2rem 1rem; background: var(--teal-soft); border: 1px solid #CFE5DF; border-radius: 11px; padding: .65rem 1rem; margin: .6rem 0; }
.calc span { font-weight: 600; } .calc b { font: 700 1.3rem var(--serif); color: var(--teal); margin-left: auto; } .calc small { flex-basis: 100%; color: var(--ink); }
.exo { border-top: 1px dashed var(--line); padding-top: .5rem; }
.expl { margin: .4rem 0; } .expl.good { color: var(--green); } .expl.bad { color: var(--red); }
.checks { list-style: none; padding: 0; } .checks li { margin: .4rem 0; }
.checks label { display: block; padding: .6rem .85rem; background: var(--card); border: 1.5px solid var(--line); border-radius: 11px; cursor: pointer; }
.checks label:has(input:checked) { background: var(--green-soft); border-color: #A8D5BA; }

/* ------------------------------------------------ tableaux */
.tw { overflow-x: auto; border-radius: 12px; } .tbl { border-collapse: separate; border-spacing: 0; width: 100%; background: #fff; margin: .5rem 0; font-size: .95rem; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.tbl th, .tbl td { border-bottom: 1px solid var(--line2); padding: .5rem .7rem; text-align: left; vertical-align: middle; }
.tbl tr:last-child th, .tbl tr:last-child td { border-bottom: 0; }
.tbl tr:first-child th { background: #F3F1EA; color: var(--muted); font-weight: 700; font-size: .85rem; text-transform: uppercase; letter-spacing: .03em; }
.tbl.in td { padding: 0; border-left: 1px solid var(--line2); } .tbl.in td input { border: 0; border-radius: 0; min-width: 110px; max-width: none; padding: .6rem .7rem; box-shadow: none; }
.tbl.in td input:focus { background: var(--teal-soft); } .tbl.in tr th:first-child { font-weight: 600; min-width: 150px; color: var(--ink); }
.j { font-size: .78rem; padding: .1rem .5rem; border-radius: 20px; font-weight: 700; } .j.bon { background: var(--green-soft); color: var(--green); }
.j.moyen { background: var(--gold-soft); color: var(--ochre); } .j.faible { background: var(--red-soft); color: var(--red); }

/* ------------------------------------------------ quiz */
.qz { padding-left: 1.4rem; } .qz > li { margin: 1.3rem 0; } .qz > li > p { font-weight: 700; margin-bottom: .45rem; } .qz > li::marker { color: var(--teal); font-weight: 700; }
.result { margin: 1rem 0; } .big-res { font: 700 1.7rem var(--serif); } .big-res.good { color: var(--green); } .big-res.bad { color: var(--red); }
.warn { color: var(--red); font-weight: 600; }

/* ------------------------------------------------ accueil / connexion */
.onb { max-width: 600px; margin: 3rem auto; padding: 2rem 2.2rem 2.4rem; background: var(--card); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow-h); }
.onb .logo { margin-bottom: 1rem; } .onb .tabs { margin: 1rem 0 0; } .onb .tab { flex: 1; text-align: center; }
.dots { display: flex; gap: .5rem; margin: 1rem 0; } .dots i { flex: 1; height: 6px; border-radius: 4px; background: var(--line2); } .dots i.on { background: var(--teal); }

/* ------------------------------------------------ certificat */
.cert { background: #fff; border: 2px solid var(--gold); outline: 8px solid var(--gold-soft); border-radius: 6px; padding: 3rem 2rem; text-align: center; margin: 1.2rem 0; }
.cert small { text-transform: uppercase; letter-spacing: .15em; color: var(--gold); font-weight: 700; } .cert h1 { color: var(--teal); } .cert h2 { font-size: 2.2rem; margin: .4rem 0; } .cert .sig { color: var(--muted); margin-top: 2rem; }

/* ------------------------------------------------ téléphone */
@media (max-width: 900px) {
  body { font-size: 17px; }
  .top { height: auto; padding: .6rem 14px; flex-wrap: wrap; gap: .5rem; } .logo em { display: none; }
  .topnav { order: 3; flex-basis: 100%; margin: 0 -6px; overflow-x: auto; } .topnav a { padding: .4rem .6rem; font-size: .9rem; } .avatar { margin-left: auto; }
  .wrap { grid-template-columns: 1fr; } .wrap > * { min-width: 0; }
  .side { position: static; height: auto; display: flex; gap: .3rem; overflow-x: auto; padding: .6rem 14px; border-right: 0; border-bottom: 1px solid var(--line); }
  .side-prog, .side-h { display: none; } .nav-s { flex: 0 0 auto; } .nav-s .t small { display: none; } .nav-s .t b { font-size: .85rem; max-width: 9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .main { padding: 1rem 14px 6rem; } h1 { font-size: 1.6rem; }
  .hero-card { grid-template-columns: 1fr; } .stats { grid-template-columns: 1fr 1fr; }
  .step { padding: 1rem; border-radius: 14px; } .stp { min-width: auto; flex: 0 0 auto; } .stp .lb small { display: none; }
  .onb { margin: 0; border-radius: 0; border: 0; box-shadow: none; padding: 1.4rem 16px; }
  .fiche-box { padding: .3rem .8rem .8rem; } .help span { display: none; }
}

@media print {
  .top, .side, .help, .stepper, .next, .btn, .hint { display: none !important; }
  .wrap { display: block; } .main { padding: 0; max-width: none; } body { background: #fff; font-size: 12pt; } .step { box-shadow: none; border: 0; padding: 0; }
  body.print-one .main > *:not(.step):not(a) { display: none; } body.print-one .fiche-box:not(:has(.printing)) { display: none; }
}
.topnav a.btn, .topnav a.btn:hover { color: #fff; background: var(--teal); margin-left: .4rem; }
.topnav a.btn:hover { background: var(--teal-2); }
.onb h1 { margin-top: 1.4rem; }
/* choix du moyen de paiement */
.btn-card { font: inherit; text-align: left; cursor: pointer; display: flex; flex-direction: column; gap: .45rem; color: var(--ink); }
.btn-card:hover { border-color: var(--teal); } .btn-card small { color: var(--teal); font-weight: 700; }
