/* Charte MITUX (logo hexagones) : bleu nuit, sarcelle, menthe, turquoise, bleu ciel.
   Mise en page épurée : une colonne de 68rem, beaucoup de blanc, deux pôles (Conseil en sarcelle, Formation en bleu). */
:root {
  color-scheme: light;
  --bg: #ffffff;
  --soft: #f3f8f8;
  --ink: #13243a;
  --muted: #5a6b79;
  --line: #e1eaea;
  --conseil: #0d7d77;
  --formation: #1c6e8c;
  --mint: #9fedc6;
  --aqua: #79d4d9;
  --sky: #98d9ed;
  --btn-fg: #ffffff;
  --f-body: "Noto Sans", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --r: 10px;
  --max: 68rem;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 1.05rem/1.7 var(--f-body); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--aqua); outline-offset: 3px; }

.wrap {
  max-width: var(--max); margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
h1, h2, h3 { margin: 0; line-height: 1.15; text-wrap: balance; letter-spacing: -.015em; }
h1 { font-size: clamp(2rem, 4.6vw, 3.1rem); font-weight: 750; }
h2 { font-size: clamp(1.45rem, 2.8vw, 1.9rem); font-weight: 700; }
h3 { font-size: 1.15rem; font-weight: 650; }
p { margin: 0; max-width: 62ch; }
.lead { font-size: 1.15rem; color: var(--muted); }
.muted { color: var(--muted); }
.label { font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--conseil); }
.formation .label, .label.f { color: var(--formation); }
.stack { display: grid; gap: 1.1rem; align-content: start; }

/* En-tête */
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--bg); }
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 9; background: var(--bg); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: .7rem; flex-wrap: wrap; }
.brand { display: flex; align-items: center; text-decoration: none; }
.brand img { height: 44px; width: auto; max-width: none; display: block; }
.nav { display: flex; align-items: center; gap: 1.6rem; flex-wrap: wrap; font-size: .97rem; }
.nav a { text-decoration: none; color: var(--muted); font-weight: 500; padding-block: .3rem; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); }
.nav a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--conseil); }
.formation .nav a[aria-current="page"] { box-shadow: inset 0 -2px 0 var(--formation); }
.menu-btn { display: none; background: none; border: 1px solid var(--line); color: var(--ink); border-radius: var(--r); padding: .35rem .8rem; font: 500 .9rem var(--f-body); cursor: pointer; }
@media (max-width: 680px) {
  .menu-btn { display: block; }
  .nav { display: none; width: 100%; flex-direction: column; align-items: flex-start; gap: .4rem; padding-bottom: .6rem; }
  .nav.open { display: flex; }
}

/* Boutons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; text-decoration: none; font: 600 1rem var(--f-body); padding: .8rem 1.3rem; border-radius: var(--r); border: 1.5px solid var(--conseil); background: var(--conseil); color: var(--btn-fg); cursor: pointer; }
.btn.f { background: var(--formation); border-color: var(--formation); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn:hover { filter: brightness(1.08); }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; }

/* Sections */
section { padding-block: clamp(3.5rem, 8vw, 6rem); }
section + section { border-top: 1px solid var(--line); }
.section-head { display: grid; gap: .8rem; margin-bottom: 2.5rem; }

/* Accueil */
.hero { padding-block: clamp(2.5rem, 5vw, 4rem) clamp(2rem, 4vw, 3rem); }
.hero .wrap { display: grid; grid-template-columns: 1fr 1.6fr; gap: 3rem; align-items: center; }
.hero .wrap > * { min-width: 0; }
.hero-logo { justify-self: center; width: min(240px, 100%); height: auto; }
.hero-brand { order: -1; justify-self: center; display: flex; align-items: center; gap: 1.25rem; min-width: 0; }
.hero-tag { display: none; font-size: clamp(.82rem, 4.2vw, 1.05rem); font-weight: 750; line-height: 1.25; letter-spacing: .04em; white-space: nowrap; text-transform: uppercase; color: var(--conseil); }
@media (max-width: 760px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 1.75rem; }
  .hero-brand { order: -1; justify-self: stretch; gap: 1rem; }
  .hero-logo { width: clamp(72px, 24vw, 110px); flex: none; }
  .hero-tag { display: block; }
  .hero-label { display: none; }
}

.poles { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
@media (max-width: 760px) { .poles { grid-template-columns: 1fr; } }
.pole { display: grid; gap: 1rem; align-content: start; padding: 2.2rem; border-radius: 16px; background: var(--soft); text-decoration: none; border-top: 4px solid var(--conseil); }
.pole.f { border-top-color: var(--formation); }
.pole .go { font-weight: 650; color: var(--conseil); }
.pole.f .go { color: var(--formation); }
.pole:hover { box-shadow: 0 0 0 1px var(--line); }
.pole ul { margin: 0; padding-left: 1.1rem; color: var(--muted); display: grid; gap: .25rem; }

/* Listes simples */
.cols { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem 3rem; }
@media (max-width: 700px) { .cols { grid-template-columns: 1fr; } }
.cols > div { display: grid; gap: .35rem; align-content: start; padding-top: 1rem; border-top: 1px solid var(--line); }
.cols p { color: var(--muted); font-size: 1rem; }

/* Tableaux */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 32rem; }
th, td { text-align: left; padding: 1rem 1rem 1rem 0; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
td.num { font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 650; }
td small { display: block; color: var(--muted); font-size: .92rem; }

/* Bandeau contact */
.contact-strip { background: var(--soft); }
.contact-strip .wrap { display: flex; justify-content: space-between; align-items: center; gap: 1.5rem; flex-wrap: wrap; }
.phone { font-size: 1.2rem; font-weight: 700; font-variant-numeric: tabular-nums; text-decoration: none; }

/* Contact */
.contact-grid { display: grid; grid-template-columns: 1fr 1.3fr; gap: 3rem; }
.contact-grid > * { min-width: 0; }
@media (max-width: 820px) { .contact-grid { grid-template-columns: 1fr; } }
.coord { display: grid; gap: .15rem; }
.coord small { font-size: .75rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
form { display: grid; gap: 1rem; }
label { display: grid; gap: .35rem; font-weight: 600; font-size: .92rem; }
input, select, textarea { font: 400 1rem var(--f-body); padding: .75rem .85rem; border: 1px solid var(--line); border-radius: var(--r); background: var(--soft); color: var(--ink); width: 100%; }
textarea { min-height: 8rem; resize: vertical; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 560px) { .row2 { grid-template-columns: 1fr; } }
.form-note { font-size: .92rem; color: var(--muted); }
.note { font-size: .93rem; color: var(--muted); margin-top: 1.5rem; }

/* Pied de page */
.site-footer { border-top: 1px solid var(--line); padding-block: 2rem; font-size: .9rem; color: var(--muted); }
.site-footer .wrap { display: flex; justify-content: space-between; align-items: center; gap: 1rem 2rem; flex-wrap: wrap; }
.site-footer img { height: 34px; width: auto; display: block; }
.site-footer nav { display: flex; gap: 1.2rem; flex-wrap: wrap; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--ink); }

.legal { display: grid; gap: 1rem; }
.legal h2 { font-size: 1.25rem; margin-top: 1rem; }

/* Démarche : séquence réelle en 4 étapes */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; counter-reset: s; }
.steps li { counter-increment: s; display: grid; gap: .35rem; align-content: start; padding-top: 1rem; border-top: 2px solid var(--conseil); }
.steps li::before { content: counter(s, decimal-leading-zero); font-size: .8rem; font-weight: 700; color: var(--conseil); font-variant-numeric: tabular-nums; }
.steps b { font-size: 1.1rem; }
.steps span { color: var(--muted); font-size: .98rem; }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr 1fr; } }
@media (max-width: 460px) { .steps { grid-template-columns: 1fr; } }

/* Mobile : tableaux en fiches empilées, titres plus compacts */
@media (max-width: 640px) {
  body { font-size: 1rem; }
  h1 { font-size: clamp(1.7rem, 7.5vw, 2.2rem); }
  section { padding-block: 2.75rem; }
  .section-head { margin-bottom: 1.75rem; }
  .table-wrap { overflow: visible; }
  table { min-width: 0; }
  table, tbody, tr, td { display: block; width: 100%; }
  thead { display: none; }
  tr { padding: 1rem 0; border-bottom: 1px solid var(--line); }
  td { border: 0; padding: .2rem 0; }
  td[data-label]:not(:first-child)::before { content: attr(data-label); display: block; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin-top: .45rem; }
  td.num { white-space: normal; }
  .pole { padding: 1.5rem; }
  .actions .btn { flex: 1 1 auto; }
  .contact-strip .wrap { flex-direction: column; align-items: flex-start; }
  .site-footer .wrap { flex-direction: column; align-items: flex-start; }
  .brand img { height: 40px; }
}

/* Champs à compléter dans les mentions légales */
mark.todo { background: #fff1b8; color: #5c4400; padding: 0 .25em; border-radius: 3px; }
.legal p { max-width: 70ch; }


/* Pages Conseil et Formation : bandeau d'en-tête, cartes, démarche */
.page-hero { position: relative; overflow: hidden; background: linear-gradient(135deg, #eafaf3 0%, #e8f6fa 100%); border-bottom: 1px solid var(--line); }
.formation .page-hero { background: linear-gradient(135deg, #e8f4fa 0%, #eef9f6 100%); }
.page-hero .wrap { position: relative; }
.page-hex { position: absolute; left: -80px; bottom: -90px; width: 260px; opacity: .3; pointer-events: none; }
.page-hero-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 2.5rem; align-items: center; }
.page-hero-grid > * { min-width: 0; }
.hero-card { background: #fff; border-radius: 16px; padding: 1.75rem; box-shadow: 0 10px 30px rgba(19,36,58,.08); border-left: 4px solid var(--conseil); display: grid; gap: .8rem; }
.formation .hero-card { border-left-color: var(--formation); }
.hero-card p { color: var(--muted); font-size: 1rem; }
.chips { list-style: none; margin: .2rem 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem; }
.chips li { background: #e3f3f9; color: var(--formation); font-weight: 600; font-size: .88rem; padding: .35rem .8rem; border-radius: 999px; }
@media (max-width: 820px) { .page-hero-grid { grid-template-columns: 1fr; } .page-hex { width: 200px; right: -70px; top: -40px; } }

.dgrid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.25rem; }
@media (max-width: 760px) { .dgrid { grid-template-columns: 1fr; } }
.dcard { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 1.6rem; display: grid; gap: .7rem; align-content: start; transition: box-shadow .2s, transform .2s; }
.dcard:hover { box-shadow: 0 12px 28px rgba(19,36,58,.08); transform: translateY(-2px); }
.dcard p { color: var(--muted); font-size: 1rem; }
.ico { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: #e3f5f1; color: var(--conseil); }
.ico svg { width: 24px; height: 24px; }
.formation .ico { background: #e3f3f9; color: var(--formation); }
.tags { display: flex; flex-wrap: wrap; gap: .4rem; }
.tags span { font-size: .8rem; font-weight: 600; padding: .25rem .6rem; border-radius: 6px; background: var(--soft); border: 1px solid var(--line); color: var(--ink); }

.band-dark { background: #13243a; color: #eef6f6; border-top: 0; }
.band-dark .label { color: #9fedc6; }
.band-dark .steps li { border-top-color: rgba(159,237,198,.5); }
.band-dark .steps li::before { color: #9fedc6; font-size: 1.6rem; font-weight: 750; }
.band-dark .steps span { color: #b5c6cf; }
.band-dark + .contact-strip { border-top: 0; }

.band-soft { background: var(--soft); }
.levels { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
@media (max-width: 860px) { .levels { grid-template-columns: 1fr; } }
.level { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 1.6rem; display: grid; gap: .6rem; align-content: start; border-top: 4px solid var(--formation); }
.level p { color: var(--muted); font-size: 1rem; }
.lvl { display: flex; gap: 4px; }
.lvl i { width: 22px; height: 6px; border-radius: 3px; background: var(--line); }
.lvl i.on { background: var(--formation); }
.level dl { margin: .4rem 0 0; display: grid; gap: .15rem; padding-top: .8rem; border-top: 1px solid var(--line); }
.level dt { font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin-top: .4rem; }
.level dd { margin: 0; font-weight: 600; font-size: .95rem; }
@media (prefers-reduced-motion: reduce) { .dcard:hover { transform: none; } }
