/* ==========================================================================
   CIS Wiki — feuille de style commune (site public + composants partagés)
   ========================================================================== */

:root {
  --font: "Atkinson Hyperlegible", Arial, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: ui-monospace, "Cascadia Code", "SFMono-Regular", Consolas, "Liberation Mono", monospace;

  --bg: #ffffff;
  --surface: #ffffff;
  --surface-2: #f3f5f7;
  --surface-3: #e6eaef;
  --border: #e2e2e2;
  --border-strong: #c9ced6;
  --text: #1f2937;
  --text-2: #454f5b;
  --text-3: #6b7280;

  --primary: #195192;
  --primary-hover: #123e72;
  --primary-soft: #e8eef6;
  --primary-text: #195192;
  --on-primary: #ffffff;
  --guided: #195192;
  --expert: #04153a;

  --ok: #0f7b55;      --ok-soft: #e2f4ec;
  --warn: #9a5800;    --warn-soft: #fdf0d9;
  --danger: #c2183a;  --danger-soft: #fde6ea;
  --info: #1d4ed8;    --info-soft: #e7eefd;

  --note-c: #195192;      --note-bg: #eef3f9;
  --tip-c: #2f6b3a;       --tip-bg: #eef6ef;
  --warning-c: #8a6a12;   --warning-bg: #fbf6e6;
  --important-c: #c40030; --important-bg: #fdecef;

  --lvl-b: #0f7b55; --lvl-b-bg: #e2f4ec;
  --lvl-i: #925400; --lvl-i-bg: #fdf0d9;
  --lvl-a: #6d28d9; --lvl-a-bg: #efe8fd;

  --c-blue: #195192; --c-indigo: #04153a; --c-teal: #195192;
  --c-rose: #c40030; --c-amber: #a8892c; --c-green: #2f6b3a;
  --phase-before: #195192; --phase-during: #a8892c; --phase-after: #2f6b3a;

  --radius: 10px; --radius-sm: 6px; --radius-lg: 14px;
  --shadow-sm: 0 1px 2px rgba(4, 21, 58, .06);
  --shadow: 0 4px 14px rgba(4, 21, 58, .08);
  --shadow-lg: 0 20px 50px rgba(16, 24, 40, .20);
  --header-h: 76px; --sidebar-w: 284px; --toc-w: 220px; --content-w: 780px;
  color-scheme: light;
}


/* ---- Base --------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.6; color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; }
img, video { max-width: 100%; }
a { color: var(--primary-text); }
h1, h2, h3, h4 { line-height: 1.25; }
.i { width: 18px; height: 18px; flex-shrink: 0; vertical-align: middle; }
.i.big { width: 48px; height: 48px; color: var(--text-3); }
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 300; background: var(--primary); color: var(--on-primary); padding: 10px 14px; border-radius: 8px; text-decoration: none; font-weight: 600; }
.skip-link:focus { top: 12px; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--primary) 55%, transparent); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
mark { background: color-mix(in srgb, #facc15 50%, transparent); color: inherit; border-radius: 3px; padding: 0 1px; }
code, pre, kbd, textarea, .mono, .diff { font-variant-ligatures: none; font-feature-settings: "liga" 0, "calt" 0; }
kbd { font-family: var(--mono); font-size: .8em; padding: .1em .45em; border: 1px solid var(--border-strong); border-bottom-width: 2px; border-radius: 6px; background: var(--surface); color: var(--text-2); white-space: nowrap; }
.no-scroll { overflow: hidden; }
.sub { font-size: 12.5px; color: var(--text-3); }

/* ---- Formulaires -------------------------------------------------------- */
input:not([type="checkbox"]):not([type="radio"]):not([type="file"]), select, textarea {
  font: inherit; font-size: 15px; color: var(--text); background: var(--surface);
  border: 1px solid var(--border-strong); border-radius: 10px; padding: 8px 12px; min-height: 40px;
  transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 18%, transparent); }
input::placeholder, textarea::placeholder { color: var(--text-3); }
.input-icon { position: relative; }
.input-icon > .i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--text-3); pointer-events: none; }
.input-icon > input { width: 100%; padding-left: 38px !important; }

/* ---- Boutons ------------------------------------------------------------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: 10px; border: 1px solid transparent; font: inherit; font-size: 14.5px; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s, color .15s; }
.btn--primary { background: var(--primary); color: var(--on-primary); }
.btn--primary:hover { background: var(--primary-hover); }
.btn--ghost { background: var(--surface); border-color: var(--border); color: var(--text); }
.btn--ghost:hover { background: var(--surface-2); border-color: var(--border-strong); }
.btn--danger { background: var(--danger); color: #fff; }
.btn--danger:hover { filter: brightness(.95); }
.btn--sm { height: 32px; padding: 0 12px; font-size: 13.5px; border-radius: 8px; }
.btn--block { width: 100%; }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; }
.icon-btn { width: 38px; height: 38px; display: inline-grid; place-items: center; border-radius: 10px; border: 1px solid transparent; background: transparent; color: var(--text-2); cursor: pointer; text-decoration: none; padding: 0; flex-shrink: 0; }
.icon-btn:hover { background: var(--surface-2); color: var(--text); }
.icon-btn--danger:hover { color: var(--danger); background: var(--danger-soft); }
.link-btn { display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; padding: 4px 0; color: var(--primary-text); font: inherit; font-size: 14px; font-weight: 500; cursor: pointer; text-decoration: none; }
.link-btn:hover { text-decoration: underline; }
.link-btn .i { width: 16px; height: 16px; }
.link-more { display: inline-flex; align-items: center; gap: 6px; color: var(--primary-text); text-decoration: none; font-weight: 600; font-size: 14.5px; white-space: nowrap; }
.link-more:hover { text-decoration: underline; }
.link-more .i { width: 16px; height: 16px; }

.seg { display: inline-flex; padding: 3px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; gap: 2px; flex-shrink: 0; }
.seg button { border: 0; background: transparent; color: var(--text-2); font: inherit; font-size: 13px; font-weight: 650; padding: 5px 10px; border-radius: 7px; display: inline-flex; align-items: center; gap: 6px; cursor: pointer; min-height: 30px; }
.seg button .i { width: 16px; height: 16px; }
.seg button:hover { color: var(--text); }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow-sm); }
.seg--mode button[data-mode="guided"][aria-pressed="true"] { color: var(--guided); }
.seg--mode button[data-mode="expert"][aria-pressed="true"] { color: var(--expert); }
.seg--sm button { font-size: 12.5px; padding: 3px 8px; min-height: 26px; }

.chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text-2); font: inherit; font-size: 13.5px; font-weight: 500; text-decoration: none; cursor: pointer; }
.chip:hover { border-color: var(--border-strong); color: var(--text); }
.chip[aria-pressed="true"] { background: var(--text); color: var(--surface); border-color: var(--text); }

.badge { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 650; padding: 3px 9px; border-radius: 999px; background: var(--surface-2); color: var(--text-2); border: 1px solid transparent; white-space: nowrap; line-height: 1.4; }
.badge .i { width: 14px; height: 14px; }
.badge--beginner { background: var(--lvl-b-bg); color: var(--lvl-b); }
.badge--intermediate { background: var(--lvl-i-bg); color: var(--lvl-i); }
.badge--advanced { background: var(--lvl-a-bg); color: var(--lvl-a); }
.badge--step { background: var(--primary-soft); color: var(--primary-text); }
.badge--plain { background: transparent; border-color: var(--border); }
.badge--warn { background: var(--warn-soft); color: var(--warn); }
.badge--ok { background: var(--ok-soft); color: var(--ok); }
.badge--danger { background: var(--danger-soft); color: var(--danger); }

.avatar { --h: 220; width: 28px; height: 28px; border-radius: 50%; display: inline-grid; place-items: center; font-size: 11px; font-weight: 750; letter-spacing: .02em; color: hsl(var(--h) 55% 28%); background: hsl(var(--h) 70% 89%); flex-shrink: 0; }

.cat--blue { --cc: var(--c-blue); } .cat--indigo { --cc: var(--c-indigo); } .cat--teal { --cc: var(--c-teal); }
.cat--rose { --cc: var(--c-rose); } .cat--amber { --cc: var(--c-amber); } .cat--green { --cc: var(--c-green); }

/* ---- En-tête -------------------------------------------------------------- */
.site-header { position: sticky; top: 0; z-index: 50; height: var(--header-h); background: color-mix(in srgb, var(--surface) 88%, transparent); -webkit-backdrop-filter: saturate(1.4) blur(12px); backdrop-filter: saturate(1.4) blur(12px); border-bottom: 1px solid var(--border); }
.header-inner { height: 100%; display: flex; align-items: center; gap: 14px; padding: 0 20px; max-width: 1440px; margin: 0 auto; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); flex-shrink: 0; }
.brand-mark { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: linear-gradient(135deg, #1d4ed8, #6d28d9); color: #fff; font-weight: 800; font-size: 12px; letter-spacing: .05em; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 15px; }
.brand-text small { font-size: 11.5px; color: var(--text-3); }
.header-nav { display: flex; gap: 2px; margin-left: 8px; }
.header-nav a { padding: 8px 12px; border-radius: 8px; color: var(--text-2); text-decoration: none; font-weight: 550; font-size: 14.5px; }
.header-nav a:hover, .header-nav a.active { background: var(--surface-2); color: var(--text); }
.search-trigger { margin-left: auto; display: flex; align-items: center; gap: 8px; min-width: 250px; height: 38px; padding: 0 8px 0 12px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface-2); color: var(--text-3); font: inherit; font-size: 14px; cursor: pointer; }
.search-trigger:hover { border-color: var(--border-strong); color: var(--text-2); }
.search-trigger span { flex: 1; text-align: left; }
.header-tools { display: flex; align-items: center; gap: 8px; }
.menu-btn { display: none; }
.side-mobile-tools { display: none; gap: 8px; flex-wrap: wrap; }

@media (max-width: 1180px) { .header-nav { display: none; } }
@media (max-width: 760px) {
  .search-trigger { min-width: 0; width: 38px; padding: 0; justify-content: center; }
  .search-trigger span, .search-trigger kbd { display: none; }
  .seg--mode button span { display: none; }
  .seg--mode button { padding: 5px 8px; }
}
@media (max-width: 520px) {
  .header-inner { gap: 6px; padding: 0 10px; }
  .brand-text { display: none; }
  .header-tools { gap: 6px; }
  .header-tools > .icon-btn { display: none; }
  .side-mobile-tools { display: flex; }
}

/* ---- Mise en page ----------------------------------------------------------- */
.layout { max-width: 1440px; margin: 0 auto; min-height: calc(100vh - var(--header-h)); }
.layout--sidebar { display: grid; grid-template-columns: var(--sidebar-w) minmax(0, 1fr); }
.main { min-width: 0; outline: none; }
.page-wrap { max-width: 980px; margin: 0 auto; padding: 28px 32px 64px; }
.backdrop { display: none; }

.sidebar { position: sticky; top: var(--header-h); height: calc(100vh - var(--header-h)); overflow-y: auto; padding: 20px 14px 24px 20px; border-right: 1px solid var(--border); display: flex; flex-direction: column; gap: 16px; }
.layout:not(.layout--sidebar) .sidebar { display: none; }
.sidebar-head { display: none; }
.side-nav { display: flex; flex-direction: column; gap: 4px; }
.side-link { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; color: var(--text-2); text-decoration: none; font-weight: 600; font-size: 14px; }
.side-link:hover, .side-link.active { background: var(--surface-2); color: var(--text); }
.side-group summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; cursor: pointer; font-weight: 650; font-size: 14px; color: var(--text); }
.side-group summary::-webkit-details-marker { display: none; }
.side-group summary:hover { background: var(--surface-2); }
.side-group .chev { margin-left: auto; width: 16px; height: 16px; color: var(--text-3); transition: transform .2s; }
.side-group:not([open]) .chev { transform: rotate(-90deg); }
.side-ico { width: 26px; height: 26px; border-radius: 7px; display: grid; place-items: center; background: color-mix(in srgb, var(--cc, var(--primary)) 14%, transparent); color: var(--cc, var(--primary)); flex-shrink: 0; }
.side-ico .i { width: 15px; height: 15px; }
.side-group ul { list-style: none; margin: 2px 0 8px 22px; padding: 0 0 0 8px; border-left: 1px solid var(--border); }
.side-group li a { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border-radius: 7px; color: var(--text-2); text-decoration: none; font-size: 14px; line-height: 1.35; }
.side-group li a:hover { background: var(--surface-2); color: var(--text); }
.side-group li a.active { background: var(--primary-soft); color: var(--primary-text); font-weight: 600; }
.side-label { flex: 1; min-width: 0; }
.step-dot { width: 20px; height: 20px; border-radius: 50%; display: inline-grid; place-items: center; font-size: 11px; font-weight: 750; background: var(--surface-3); color: var(--text-2); flex-shrink: 0; }
.active .step-dot { background: var(--primary); color: var(--on-primary); }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--border-strong); margin: 0 7px; flex-shrink: 0; }
.tr-flag { font-size: 10px; font-weight: 750; padding: 1px 5px; border-radius: 4px; background: var(--warn-soft); color: var(--warn); }
.side-card { margin-top: auto; padding: 14px; border-radius: var(--radius); background: var(--surface-2); border: 1px solid var(--border); font-size: 13.5px; color: var(--text-2); }
.side-card p { margin: 0 0 10px; }
.side-card-title { display: flex; gap: 8px; align-items: center; font-weight: 700; color: var(--text) !important; margin-bottom: 4px !important; }
body[data-mode="guided"] .side-card-title .i { color: var(--guided); }
body[data-mode="expert"] .side-card-title .i { color: var(--expert); }

@media (max-width: 960px) {
  .layout--sidebar { display: block; }
  .menu-btn { display: inline-grid; }
  .sidebar, .layout:not(.layout--sidebar) .sidebar {
    display: flex; position: fixed; top: 0; left: 0; bottom: 0; height: auto; width: min(86vw, 320px); z-index: 70;
    background: var(--surface); padding: 16px; transform: translateX(-100%); visibility: hidden;
    transition: transform .25s ease, visibility .25s; box-shadow: var(--shadow-lg);
  }
  .sidebar-open .sidebar { transform: none; visibility: visible; }
  .sidebar-head { display: flex; justify-content: space-between; align-items: center; padding-left: 4px; }
  .sidebar-open .backdrop { display: block; position: fixed; inset: 0; background: rgba(8, 12, 24, .45); z-index: 60; }
}
@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .page-wrap { padding: 20px 16px 48px; }
}

/* ---- Fil d'Ariane, en-têtes de page ------------------------------------------ */
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0 0 18px; font-size: 13.5px; color: var(--text-3); }
.breadcrumb li + li::before { content: "/"; margin-right: 6px; color: var(--border-strong); }
.breadcrumb a { color: var(--text-2); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }
.page-head { display: flex; gap: 18px; align-items: flex-start; margin: 0 0 24px; }
.page-head h1 { margin: 0 0 6px; font-size: clamp(26px, 4vw, 34px); letter-spacing: -.02em; }
.page-head .lead { margin: 0; }
.page-count { margin: 8px 0 0; font-size: 13.5px; color: var(--text-3); font-weight: 600; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 20px; }
.empty { color: var(--text-3); text-align: center; padding: 32px 0; }
.empty-state { text-align: center; padding: 48px 16px; color: var(--text-2); }
.empty-state h1 { margin: 12px 0 8px; }
.notice { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: var(--radius); background: var(--info-soft); color: var(--text); font-size: 14.5px; margin: 0 0 18px; border: 1px solid color-mix(in srgb, var(--info) 25%, transparent); }
.notice .i { color: var(--info); margin-top: 2px; }
.notice--draft { background: var(--warn-soft); border-color: color-mix(in srgb, var(--warn) 30%, transparent); }
.notice--draft .i { color: var(--warn); }
.lead { font-size: 18px; color: var(--text-2); line-height: 1.55; }

/* ---- Accueil --------------------------------------------------------------- */
.hero { position: relative; overflow: hidden; padding: 64px 0 44px; border-bottom: 1px solid var(--border);
  background: radial-gradient(1100px 420px at 8% -20%, color-mix(in srgb, var(--primary) 16%, transparent), transparent 62%),
              radial-gradient(900px 420px at 100% -10%, color-mix(in srgb, var(--expert) 14%, transparent), transparent 60%), var(--bg); }
.hero-inner { max-width: 900px; text-align: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 750; text-transform: uppercase; letter-spacing: .08em; color: var(--primary-text); background: var(--primary-soft); padding: 5px 12px; border-radius: 999px; margin: 0 0 18px; }
.eyebrow .i { width: 15px; height: 15px; }
.hero h1 { font-size: clamp(30px, 5.2vw, 52px); line-height: 1.08; letter-spacing: -.03em; margin: 0 0 16px; }
.hero .lead { font-size: clamp(16px, 2vw, 19px); max-width: 690px; margin: 0 auto 28px; }
.hero-search { display: flex; align-items: center; gap: 10px; max-width: 680px; margin: 0 auto; padding: 7px 7px 7px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; box-shadow: var(--shadow); color: var(--text-3); }
.hero-search:focus-within { border-color: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 18%, transparent); }
.hero-search input, .search-form input, .palette-input input { flex: 1; min-width: 0; border: 0 !important; background: transparent !important; box-shadow: none !important; padding: 0 !important; font-size: 16.5px; color: var(--text); }
.chips { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px; margin-top: 18px; font-size: 14px; color: var(--text-3); }
.paths { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; padding-top: 32px; }
.path-card { --pc: var(--guided); position: relative; display: flex; flex-direction: column; gap: 6px; padding: 24px; border-radius: var(--radius-lg); background: var(--surface); border: 1px solid var(--border); text-decoration: none; color: var(--text); box-shadow: var(--shadow-sm); transition: transform .15s, box-shadow .15s, border-color .15s; }
.path-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: color-mix(in srgb, var(--pc) 50%, var(--border)); }
.path-card--expert { --pc: var(--expert); }
.path-icon { width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; background: color-mix(in srgb, var(--pc) 13%, transparent); color: var(--pc); }
.path-icon .i { width: 23px; height: 23px; }
.path-tag { position: absolute; top: 26px; right: 24px; font-size: 12px; font-weight: 750; text-transform: uppercase; letter-spacing: .07em; color: var(--pc); }
.path-card h2 { margin: 10px 0 0; font-size: 21px; }
.path-card p { margin: 0; color: var(--text-2); }
.path-card .cta { margin-top: 10px; display: inline-flex; align-items: center; gap: 6px; font-weight: 650; color: var(--pc); }
.section { padding-top: 56px; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.section-head h2 { display: flex; align-items: center; gap: 10px; margin: 0; font-size: 24px; letter-spacing: -.01em; }
.section-head h2 .i { color: var(--primary-text); width: 22px; height: 22px; }
.section-head p { margin: 4px 0 0; color: var(--text-2); }

.stepper { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 10px; }
.step { --ph: var(--phase-before); }
.step--during { --ph: var(--phase-during); }
.step--after { --ph: var(--phase-after); }
.step a { position: relative; display: flex; flex-direction: column; gap: 8px; height: 100%; padding: 16px 14px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); border-top: 3px solid var(--ph); text-decoration: none; color: var(--text); transition: transform .15s, box-shadow .15s, border-color .15s; }
.step a:hover { box-shadow: var(--shadow); transform: translateY(-2px); border-color: var(--ph); }
.step-top { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.step-num { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 13px; background: var(--ph); color: var(--surface); flex-shrink: 0; }
.step-phase { font-size: 11px; font-weight: 750; text-transform: uppercase; letter-spacing: .06em; color: var(--ph); }
.step-icon { color: var(--text-3); }
.step strong { font-size: 15px; line-height: 1.3; }
.step small { font-size: 13px; color: var(--text-2); line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
@media (max-width: 1100px) { .stepper { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 720px) {
  .stepper { grid-template-columns: 1fr; gap: 8px; }
  .step a { flex-direction: row; align-items: center; padding: 12px 14px; border-top-width: 1px; border-left: 4px solid var(--ph); }
  .step small, .step-icon { display: none; }
  .step-top { flex-direction: row-reverse; gap: 10px; }
  .step strong { flex: 1; }
}

.cheat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 310px), 1fr)); gap: 14px; }
.cheat-card { display: flex; flex-direction: column; gap: 10px; padding: 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); }
.cheat-card header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.cheat-card h3 { margin: 0; font-size: 16px; }
.cheat-card h3 a { color: var(--text); text-decoration: none; display: flex; gap: 8px; align-items: center; }
.cheat-card h3 a:hover { color: var(--primary-text); }
.cheat-card ul { margin: 0; padding-left: 18px; font-size: 14px; color: var(--text-2); display: grid; gap: 4px; }
.cheat-card .link-more { margin-top: auto; font-size: 14px; }

.timeline { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.timeline > li { padding: 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); border-top: 3px solid var(--c-teal); }
.tl-day { display: inline-block; font-weight: 800; font-size: 14px; padding: 3px 10px; border-radius: 999px; background: color-mix(in srgb, var(--c-teal) 14%, transparent); color: var(--c-teal); margin-bottom: 10px; }
.timeline ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.timeline ul a { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 7px 10px; border-radius: 8px; color: var(--text); text-decoration: none; font-size: 14.5px; }
.timeline ul a:hover { background: var(--surface-2); }
.timeline ul .i { width: 16px; height: 16px; color: var(--text-3); }

.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); gap: 14px; }
.cat-card { display: flex; flex-direction: column; gap: 6px; padding: 20px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); text-decoration: none; color: var(--text); transition: transform .15s, box-shadow .15s, border-color .15s; }
.cat-card:hover { border-color: var(--cc); box-shadow: var(--shadow); transform: translateY(-2px); }
.cat-icon { width: 42px; height: 42px; border-radius: 11px; display: grid; place-items: center; background: color-mix(in srgb, var(--cc, var(--primary)) 13%, transparent); color: var(--cc, var(--primary)); margin-bottom: 6px; flex-shrink: 0; }
.cat-icon--lg { width: 56px; height: 56px; border-radius: 15px; margin: 0; }
.cat-icon--lg .i { width: 28px; height: 28px; }
.cat-card strong { font-size: 17px; }
.cat-card p { margin: 0; color: var(--text-2); font-size: 14.5px; flex: 1; }
.cat-count { font-size: 13px; color: var(--text-3); font-weight: 600; margin-top: 6px; }

.video-strip { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(230px, 1fr); gap: 14px; overflow-x: auto; padding-bottom: 8px; scroll-snap-type: x mandatory; }
.video-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 18px; }
.video-card { display: flex; flex-direction: column; gap: 6px; text-decoration: none; color: var(--text); scroll-snap-align: start; }
.video-thumb { aspect-ratio: 16 / 9; border-radius: var(--radius); display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #be123c, #6d28d9); box-shadow: var(--shadow-sm); }
.video-thumb .i { width: 26px; height: 26px; padding: 14px; box-sizing: content-box; background: rgba(255, 255, 255, .2); border-radius: 50%; transition: transform .2s; }
.video-card:hover .video-thumb .i { transform: scale(1.1); }
.video-card strong { font-size: 15.5px; }
.video-card > span:last-child { font-size: 13.5px; color: var(--text-2); }

.updates { list-style: none; margin: 0; padding: 0; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.updates li { display: flex; align-items: center; justify-content: space-between; gap: 8px 16px; padding: 12px 16px; border-bottom: 1px solid var(--border); flex-wrap: wrap; }
.updates li:last-child { border-bottom: 0; }
.updates a { display: flex; flex-direction: column; text-decoration: none; color: var(--text); min-width: 0; }
.updates a:hover .upd-title { color: var(--primary-text); }
.upd-title { font-weight: 600; }
.upd-cat { font-size: 13px; color: var(--text-3); }
.upd-meta { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--text-2); }
.upd-meta .avatar { width: 24px; height: 24px; font-size: 10px; }

@media (max-width: 820px) { .timeline { grid-template-columns: 1fr; } }
@media (max-width: 720px) { .paths { grid-template-columns: 1fr; } }
@media (max-width: 560px) {
  .hero { padding: 40px 0 28px; }
  .hero-search kbd, .hero-search .btn { display: none; }
  .section { padding-top: 40px; }
}

/* ---- Catégorie ----------------------------------------------------------------- */
.doc-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.doc-card { display: flex; align-items: center; gap: 16px; padding: 16px 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); text-decoration: none; color: var(--text); transition: border-color .15s, box-shadow .15s; }
.doc-card:hover { border-color: var(--primary); box-shadow: var(--shadow-sm); }
.doc-num { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; background: var(--primary); color: var(--on-primary); flex-shrink: 0; }
.doc-icon { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--surface-2); color: var(--text-2); flex-shrink: 0; }
.doc-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.doc-body strong { font-size: 16.5px; }
.doc-sum { color: var(--text-2); font-size: 14.5px; }
.doc-meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 4px; }
.doc-path { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--text-3); }
.doc-path .i { width: 14px; height: 14px; }
.doc-chev { color: var(--text-3); }
@media (max-width: 560px) { .page-head { flex-direction: column; gap: 12px; } .doc-chev { display: none; } .doc-card { align-items: flex-start; } }

/* ---- Recherche ------------------------------------------------------------------ */
.search-form { display: flex; align-items: center; gap: 10px; padding: 6px 6px 6px 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); margin: 8px 0 18px; color: var(--text-3); }
.search-form:focus-within { border-color: var(--primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 18%, transparent); }
.search-count { color: var(--text-2); margin: 0 0 12px; font-size: 14.5px; }
.results { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.results a { display: flex; flex-direction: column; gap: 4px; padding: 16px 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); text-decoration: none; color: var(--text); }
.results a:hover { border-color: var(--primary); }
.res-cat { font-size: 12px; font-weight: 750; text-transform: uppercase; letter-spacing: .05em; color: var(--text-3); }
.results strong { font-size: 17px; }
.res-snippet { color: var(--text-2); font-size: 14.5px; }
.res-meta { margin-top: 4px; }
.term-hits { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: 10px; margin-bottom: 16px; }
.term-hit { display: flex; gap: 10px; padding: 12px 14px; border-radius: var(--radius); background: color-mix(in srgb, var(--c-amber) 7%, var(--surface)); border: 1px solid color-mix(in srgb, var(--c-amber) 25%, var(--border)); text-decoration: none; color: var(--text); font-size: 14px; }
.term-hit > span { display: flex; flex-direction: column; gap: 2px; }
.term-hit > span > span { color: var(--text-2); }
.term-hit .i { color: var(--c-amber); margin-top: 2px; }

/* ---- Glossaire ---------------------------------------------------------------- */
.gloss-tools { position: sticky; top: var(--header-h); z-index: 5; background: var(--bg); padding: 12px 0; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; border-bottom: 1px solid var(--border); }
.gloss-tools .input-icon { flex: 1 1 260px; }
.letters { display: flex; flex-wrap: wrap; gap: 4px; }
.letters a { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 8px; text-decoration: none; font-weight: 700; font-size: 13.5px; color: var(--text-2); border: 1px solid var(--border); background: var(--surface); }
.letters a:hover { border-color: var(--primary); color: var(--primary-text); }
.gloss-group { padding-top: 12px; scroll-margin-top: calc(var(--header-h) + 70px); }
.gloss-group h2 { font-size: 22px; color: var(--primary-text); margin: 10px 0; }
.gloss-group dl { margin: 0; display: grid; gap: 10px; }
.gloss-item { padding: 14px 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--border); scroll-margin-top: calc(var(--header-h) + 90px); transition: box-shadow .3s, border-color .3s; }
.gloss-item dt { font-weight: 700; font-size: 16.5px; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
.other-lang { font-size: 12.5px; font-weight: 650; color: var(--text-3); }
.gloss-item dd { margin: 4px 0 0; color: var(--text-2); }
.gloss-item dd p { margin: 0 0 6px; }
.gloss-item:target, .gloss-item.flash { border-color: var(--c-amber); box-shadow: 0 0 0 4px color-mix(in srgb, var(--c-amber) 22%, transparent); }

/* ---- Article ------------------------------------------------------------------- */
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) var(--toc-w); gap: 48px; max-width: 1140px; margin: 0 auto; padding: 28px 40px 72px; }
.article { min-width: 0; max-width: var(--content-w); width: 100%; }
.article h1 { font-size: clamp(28px, 4vw, 38px); line-height: 1.15; letter-spacing: -.02em; margin: 0 0 12px; }
.article-head .lead { margin: 0 0 16px; }
.badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.menupath { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; color: var(--text-2); margin: 0 0 16px; }
.menupath > .i { color: var(--text-3); width: 16px; height: 16px; }
.menupath-chips { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.menupath .sep { color: var(--text-3); }
kbd.ui { font-family: var(--font); font-size: 13px; font-weight: 600; padding: 2px 8px; border-radius: 6px; background: var(--surface); border: 1px solid var(--border-strong); border-bottom-width: 2px; color: var(--text); }
.menupath--sm { margin: 0; font-size: 13px; }
.menupath--sm kbd.ui { font-size: 12px; padding: 1px 6px; }
.article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font-size: 14px; color: var(--text-2); padding: 12px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); margin-bottom: 28px; }
.article-meta > span:not(.meta-actions):not(.avatar) { flex: 1 1 220px; }
.meta-actions { margin-left: auto; display: flex; flex-wrap: wrap; gap: 4px 16px; }

body[data-mode="guided"] .only-expert, body[data-mode="expert"] .only-guided { display: none !important; }

.box-title { display: flex; align-items: center; gap: 8px; font-size: 13.5px; text-transform: uppercase; letter-spacing: .07em; margin: 0 0 12px; }
.intro-box { border: 1px solid color-mix(in srgb, var(--guided) 30%, var(--border)); background: color-mix(in srgb, var(--guided) 5%, var(--surface)); border-radius: var(--radius-lg); padding: 18px 20px; margin: 0 0 28px; }
.intro-box .box-title { color: var(--guided); }
.intro-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 16px 28px; }
.intro-grid h3 { display: flex; align-items: center; gap: 8px; font-size: 14.5px; margin: 0 0 8px; }
.intro-grid h3 .i { color: var(--text-3); width: 16px; height: 16px; }
.checks, .prereq { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; font-size: 15px; }
.checks li { display: flex; gap: 8px; }
.checks .i { color: var(--ok); margin-top: 3px; width: 16px; height: 16px; }
.prereq a { display: flex; gap: 8px; align-items: center; color: var(--text); text-decoration: none; padding: 6px 10px; border-radius: 8px; background: var(--surface); border: 1px solid var(--border); }
.prereq a:hover { border-color: var(--primary); }
.prereq .i { width: 16px; height: 16px; color: var(--text-3); }
.cheat { border: 1px solid color-mix(in srgb, var(--expert) 35%, var(--border)); background: color-mix(in srgb, var(--expert) 5%, var(--surface)); border-radius: var(--radius-lg); padding: 18px 20px; margin: 0 0 28px; }
.cheat .box-title { color: var(--expert); }
.cheat-list { margin: 0; padding: 0; list-style: none; counter-reset: c; display: grid; gap: 8px; }
.cheat-list li { counter-increment: c; display: grid; grid-template-columns: 24px 1fr; gap: 10px; font-size: 15px; align-items: start; }
.cheat-list li::before { content: counter(c); width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 750; background: var(--expert); color: var(--surface); }
.cheat-list a { color: var(--primary-text); }

/* ---- Contenu rédigé (.prose) -------------------------------------------------------- */
.prose { font-size: 16.5px; line-height: 1.72; }
.prose p { margin: 0 0 1em; }
.prose h2 { font-size: 24px; letter-spacing: -.01em; margin: 2em 0 .6em; }
.prose h3 { font-size: 19px; margin: 1.6em 0 .5em; }
.prose h4 { font-size: 16.5px; margin: 1.4em 0 .4em; }
.prose > h2:first-child, .prose > h3:first-child { margin-top: 0; }
.prose .anchor { margin-left: 8px; color: var(--text-3); opacity: 0; text-decoration: none; font-weight: 400; }
.prose h2:hover .anchor, .prose h3:hover .anchor, .prose .anchor:focus { opacity: 1; }
.prose a { color: var(--primary-text); text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--primary) 40%, transparent); text-underline-offset: 3px; }
.prose a:hover { text-decoration-color: currentColor; }
.prose a.anchor { text-decoration: none; }
.prose .ext-link::after { content: "\2197"; font-size: .8em; margin-left: 2px; }
.prose .file-link { display: inline-flex; align-items: center; gap: 6px; padding: 1px 10px; border-radius: 8px; background: var(--primary-soft); text-decoration: none; font-weight: 600; word-break: break-all; }
.prose .file-link::before { content: "\2913"; }
.prose .wikilink--missing { color: var(--danger); text-decoration-style: dashed; }
.prose ul, .prose ol { padding-left: 1.5em; margin: 0 0 1em; }
.prose li + li { margin-top: .3em; }
.prose li > ul, .prose li > ol { margin: .3em 0 0; }
.prose ol > li::marker { font-weight: 700; color: var(--primary-text); }
.prose code { font-family: var(--mono); font-size: .86em; background: var(--surface-2); padding: .1em .4em; border-radius: 5px; border: 1px solid var(--border); }
.prose pre { background: var(--surface-2); padding: 14px 16px; border-radius: var(--radius); overflow: auto; font-size: 14px; border: 1px solid var(--border); }
.prose pre code { border: 0; padding: 0; background: none; }
.prose hr { border: 0; border-top: 1px solid var(--border); margin: 2em 0; }
.prose blockquote { margin: 0 0 1em; padding: 4px 16px; border-left: 3px solid var(--border-strong); color: var(--text-2); }
.table-wrap { position: relative; overflow-x: auto; margin: 0 0 1.3em; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.prose table { border-collapse: collapse; width: 100%; font-size: 14.5px; line-height: 1.45; }
.prose th, .prose td { padding: 9px 12px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: top; }
.prose thead th { background: var(--surface-2); font-weight: 650; font-size: 13.5px; color: var(--text-2); }
.prose tbody tr:last-child td { border-bottom: 0; }
.prose tbody tr:hover td { background: color-mix(in srgb, var(--primary) 4%, transparent); }

.callout { --c: var(--note-c); --b: var(--note-bg); background: var(--b); border: 1px solid color-mix(in srgb, var(--c) 22%, transparent); border-left: 4px solid var(--c); border-radius: var(--radius); padding: 12px 16px; margin: 0 0 1.3em; }
.callout--tip { --c: var(--tip-c); --b: var(--tip-bg); }
.callout--warning { --c: var(--warning-c); --b: var(--warning-bg); }
.callout--important { --c: var(--important-c); --b: var(--important-bg); }
.callout-title { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--c); font-size: 14.5px; margin-bottom: 4px; }
.callout-body { font-size: 15.5px; }
.callout-body > :last-child { margin-bottom: 0; }
.callout-body ul { padding-left: 1.2em; }

.mode-block { position: relative; border: 1px dashed color-mix(in srgb, var(--guided) 45%, transparent); border-radius: var(--radius); padding: 16px 16px 4px; margin: 10px 0 1.3em; background: color-mix(in srgb, var(--guided) 4%, transparent); }
.mode-block--expert { border-color: color-mix(in srgb, var(--expert) 45%, transparent); background: color-mix(in srgb, var(--expert) 4%, transparent); }
.mode-flag { position: absolute; top: -10px; left: 12px; font-size: 11px; font-weight: 750; text-transform: uppercase; letter-spacing: .06em; background: var(--bg); padding: 0 6px; color: var(--guided); line-height: 20px; }
.mode-block--expert .mode-flag { color: var(--expert); }
.mode-block .callout { margin-bottom: 12px; }
.md-details { margin: 0 0 1.2em; border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 14px; background: var(--surface); }
.md-details summary { cursor: pointer; font-weight: 600; }

.shot { margin: 0 0 1.4em; }
.shot > summary { display: none; }
body[data-mode="expert"] .shot > summary { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-size: 13.5px; color: var(--text-2); padding: 5px 12px; border: 1px dashed var(--border-strong); border-radius: 8px; list-style: none; max-width: 100%; }
body[data-mode="expert"] .shot > summary:hover { border-color: var(--primary); color: var(--primary-text); }
.shot > summary::-webkit-details-marker { display: none; }
.shot > summary .i { width: 16px; height: 16px; }
body[data-mode="expert"] .shot[open] > summary { margin-bottom: 8px; }
.shot figure { margin: 0; }
.shot-zoom { display: block; width: 100%; padding: 0; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--surface); cursor: zoom-in; box-shadow: var(--shadow-sm); }
.shot-zoom:hover { border-color: var(--border-strong); }
.shot-zoom img { display: block; max-width: 100%; height: auto; margin: 0 auto; }
.shot figcaption { font-size: 13.5px; color: var(--text-3); margin-top: 6px; text-align: center; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 230px), 1fr)); gap: 14px; margin: 0 0 1.4em; }
.gallery .shot { margin: 0; }
.gallery .shot-zoom img { height: 170px; width: 100%; object-fit: contain; background: var(--surface-2); }
body[data-mode="expert"] .gallery { display: flex; flex-wrap: wrap; gap: 8px; }
body[data-mode="expert"] .gallery .shot[open] { flex-basis: 100%; }
.video { margin: 0 0 1.4em; }
.video video { width: 100%; border-radius: var(--radius); background: #000; aspect-ratio: 16 / 9; display: block; }
.video figcaption { font-size: 13.5px; color: var(--text-3); margin-top: 6px; }

.term { font: inherit; color: inherit; background: none; border: 0; padding: 0; margin: 0; cursor: help; text-decoration: underline dotted; text-decoration-color: var(--guided); text-decoration-thickness: 1.5px; text-underline-offset: 4px; }
.term:hover { color: var(--guided); }
body[data-mode="expert"] .term { text-decoration: none; cursor: inherit; pointer-events: none; }
body[data-mode="expert"] .term:hover { color: inherit; }
.term-pop { position: absolute; z-index: 90; width: max-content; max-width: min(320px, calc(100vw - 16px)); background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 12px 14px; font-size: 14px; line-height: 1.5; }
.term-pop p { margin: 4px 0 8px; color: var(--text-2); }
.term-pop a { font-weight: 600; text-decoration: none; }

.article-foot { margin-top: 48px; display: grid; gap: 18px; }
.next-step { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 4px 16px; padding: 18px 22px; border-radius: var(--radius-lg); background: linear-gradient(135deg, #1d4ed8, #6d28d9); color: #fff; text-decoration: none; box-shadow: var(--shadow); }
.next-step:hover { filter: brightness(1.06); }
.ns-label { font-size: 12.5px; opacity: .88; text-transform: uppercase; letter-spacing: .06em; font-weight: 650; }
.next-step strong { font-size: 19px; grid-column: 1; }
.ns-arrow { grid-row: 1 / span 2; grid-column: 2; width: 28px; height: 28px; }
.feedback { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.feedback p { margin: 0; display: flex; gap: 8px; align-items: center; font-weight: 550; }
.feedback p .i { color: var(--ok); }
.fb-btns { display: flex; gap: 8px; }
.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pager-link { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px; border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; color: var(--text); background: var(--surface); }
.pager-link:hover { border-color: var(--primary); }
.pager-link span { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--text-3); }
.pager-link span .i { width: 15px; height: 15px; }
.pager-link--next { text-align: right; grid-column: 2; }
.pager-link--next span { justify-content: flex-end; }

.toc { position: sticky; top: calc(var(--header-h) + 28px); align-self: start; max-height: calc(100vh - var(--header-h) - 56px); overflow: auto; font-size: 13.5px; }
.toc-title { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; font-weight: 750; color: var(--text-3); margin: 0 0 10px; }
.toc ul { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--border); }
.toc li a { display: block; padding: 5px 0 5px 14px; margin-left: -1px; border-left: 2px solid transparent; color: var(--text-2); text-decoration: none; line-height: 1.35; }
.toc li a:hover { color: var(--text); }
.toc li.lvl-3 a { padding-left: 26px; font-size: 13px; }
.toc a.active { color: var(--primary-text); border-left-color: var(--primary); font-weight: 600; }
.toc-actions { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; margin-top: 20px; padding-top: 14px; border-top: 1px solid var(--border); }

@media (max-width: 1200px) {
  .article-layout { grid-template-columns: minmax(0, 1fr); }
  .toc { display: none; }
  .article { margin: 0 auto; }
}
@media (max-width: 640px) {
  .article-layout { padding: 20px 16px 56px; }
  .prose { font-size: 16px; }
  .meta-actions { margin-left: 0; width: 100%; }
  .pager { grid-template-columns: 1fr; }
  .pager-link--next { grid-column: 1; }
  .next-step strong { font-size: 17px; }
}

/* ---- Palette Ctrl K ---------------------------------------------------------- */
.palette-wrap { position: fixed; inset: 0; z-index: 100; background: rgba(8, 12, 24, .5); display: flex; justify-content: center; align-items: flex-start; padding: 10vh 16px 16px; }
.palette { width: 100%; max-width: 640px; background: var(--surface); border-radius: 16px; box-shadow: var(--shadow-lg); border: 1px solid var(--border); overflow: hidden; display: flex; flex-direction: column; max-height: 76vh; }
.palette-input { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--border); color: var(--text-3); }
.palette-input input { font-size: 17px !important; min-height: 28px !important; }
.palette-list { list-style: none; margin: 0; padding: 8px; overflow-y: auto; }
.palette-list a { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; color: var(--text); text-decoration: none; }
.palette-list a > .i { color: var(--text-3); }
.palette-list a:hover, .palette-list [aria-selected="true"] a { background: var(--primary-soft); }
.palette-list [aria-selected="true"] a > .i { color: var(--primary-text); }
.pal-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.pal-title { font-weight: 600; }
.pal-snippet { font-size: 13px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pal-meta { font-size: 12px; color: var(--text-3); white-space: nowrap; }
.palette-foot { margin: 0; padding: 10px 16px; font-size: 12.5px; color: var(--text-3); border-top: 1px solid var(--border); background: var(--surface-2); }
@media (max-width: 560px) { .palette-wrap { padding-top: 12px; } .pal-meta { display: none; } }

/* ---- Fenêtres modales, visionneuse, notifications ---------------------------------- */
dialog { color: var(--text); }
dialog::backdrop { background: rgba(8, 12, 24, .6); }
.lightbox { padding: 0; border: 0; background: transparent; max-width: 96vw; max-height: 96vh; overflow: visible; }
.lightbox img { display: block; max-width: 96vw; max-height: 86vh; border-radius: 12px; background: #fff; margin: 0 auto; }
.lightbox-cap { color: #fff; text-align: center; margin: 10px 0 0; text-shadow: 0 1px 3px rgba(0, 0, 0, .6); }
.lightbox-close { position: absolute; top: 8px; right: 8px; background: rgba(0, 0, 0, .6); color: #fff; }
.lightbox-close:hover { background: rgba(0, 0, 0, .8); color: #fff; }
.modal { width: min(640px, calc(100vw - 32px)); padding: 0; border: 1px solid var(--border); border-radius: 16px; background: var(--surface); box-shadow: var(--shadow-lg); }
.modal--wide { width: min(980px, calc(100vw - 32px)); }
.modal-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.modal-head h2 { margin: 0; font-size: 18px; display: flex; align-items: center; gap: 8px; }
.modal-body { padding: 18px 20px; max-height: 70vh; overflow: auto; }
.modal-body > p:first-child { margin-top: 0; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 20px; border-top: 1px solid var(--border); background: var(--surface-2); border-radius: 0 0 16px 16px; flex-wrap: wrap; }
.rev-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.rev-list--public .rev { display: flex; gap: 12px; }
.rev-list--public .rev p { margin: 0; }
.rev-note { color: var(--text-2); font-size: 14.5px; margin: 2px 0 0; }
.hint { display: flex; gap: 8px; align-items: flex-start; font-size: 13.5px; color: var(--text-3); margin: 16px 0 0; }
.hint .i { width: 16px; height: 16px; margin-top: 2px; }
.toasts { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: max-content; max-width: calc(100vw - 32px); }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 10px; background: var(--text); color: var(--surface); padding: 10px 16px; border-radius: 12px; box-shadow: var(--shadow-lg); font-size: 14.5px; animation: toast-in .2s ease; transition: opacity .3s, transform .3s; }
.toast.out { opacity: 0; transform: translateY(6px); }
.toast--error { background: var(--danger); color: #fff; }
.toast--ok { background: var(--ok); color: #fff; }
.toast-action { background: transparent; border: 1px solid currentColor; color: inherit; border-radius: 8px; padding: 3px 10px; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }

/* ---- Pied de page --------------------------------------------------------------- */
.site-footer { margin-top: 72px; border-top: 1px solid var(--border); background: var(--surface); padding: 40px 0 0; font-size: 14.5px; }
.footer-inner { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; }
.site-footer h2 { font-size: 12.5px; text-transform: uppercase; letter-spacing: .08em; color: var(--text-3); margin: 0 0 12px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.site-footer a { color: var(--text-2); text-decoration: none; }
.site-footer a:hover { color: var(--text); text-decoration: underline; }
.site-footer .brand:hover { text-decoration: none; }
.footer-brand p { color: var(--text-2); max-width: 380px; }
.footer-note { display: flex; gap: 8px; align-items: center; padding-top: 16px; padding-bottom: 16px; margin-top: 32px; border-top: 1px solid var(--border); color: var(--text-3); font-size: 13px; }
.footer-note .i { width: 16px; height: 16px; }
@media (max-width: 720px) { .footer-inner { grid-template-columns: 1fr; gap: 24px; } }

/* ---- Préférences de mouvement, impression ----------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
@media print {
  .site-header, .sidebar, .toc, .site-footer, .article-foot, .meta-actions, .backdrop, .toasts, .skip-link, .palette-wrap { display: none !important; }
  .layout--sidebar { display: block; }
  .article-layout { display: block; padding: 0; }
  body { background: #fff; color: #000; }
  .shot > summary { display: none !important; }
  body[data-mode] .only-guided, body[data-mode] .only-expert { display: block !important; }
  .callout, .intro-box, .cheat { break-inside: avoid; }
}

/* ==========================================================================
   Étapes en cartes, simulateur de calcul, exemples par métier
   ========================================================================== */
.steps > ol { list-style: none; counter-reset: step; padding: 0; margin: 0 0 1.4em; display: grid; gap: 10px; }
.steps > ol > li { counter-increment: step; position: relative; padding: 12px 14px 12px 56px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); min-height: 48px; }
.steps > ol > li::before { content: counter(step); position: absolute; left: 12px; top: 10px; width: 30px; height: 30px; border-radius: 50%; background: var(--primary); color: var(--on-primary); font-weight: 750; font-size: 15px; display: grid; place-items: center; }
.steps > ol > li > :last-child { margin-bottom: 0; }
.steps > ol > li .shot { margin-top: 10px; }

.calc-sim { border: 1px solid color-mix(in srgb, var(--primary) 30%, var(--border)); border-radius: var(--radius-lg); background: var(--surface); margin: 0 0 1.6em; overflow: hidden; box-shadow: var(--shadow-sm); }
.sim-fallback { margin: 0; padding: 14px 16px; color: var(--text-3); }
.sim-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; padding: 12px 16px; background: var(--primary-soft); border-bottom: 1px solid var(--border); }
.sim-head strong { font-size: 15px; color: var(--primary-text); }
.sim-head span { flex: 1 1 260px; font-size: 13.5px; color: var(--text-2); }
.sim-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0; }
.sim-params { margin: 0; border: 0; border-right: 1px solid var(--border); padding: 14px 16px; display: grid; gap: 10px; align-content: start; min-width: 0; }
.sim-params legend { font-size: 12px; font-weight: 750; text-transform: uppercase; letter-spacing: .05em; color: var(--text-3); padding: 14px 0 0; float: left; width: 100%; }
.sim-field { display: grid; gap: 4px; font-size: 13.5px; color: var(--text-2); }
.sim-field > span:first-child { font-weight: 600; }
.calc-sim input[type="text"], .calc-sim select, .trades input, .trades select { font: inherit; font-size: 14px; color: var(--text); background: var(--surface); border: 1px solid var(--border-strong); border-radius: 8px; padding: 6px 9px; min-width: 0; width: 100%; }
.calc-sim input:focus, .calc-sim select:focus, .trades input:focus, .trades select:focus { outline: 2px solid var(--primary); outline-offset: 1px; border-color: var(--primary); }
.sim-radios { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 14px; color: var(--text); }
.sim-radios label, .sim-check { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; font-size: 14px; color: var(--text); }
.sim-grid { display: grid; gap: 6px; }
.sim-grid--2 { grid-template-columns: 1.6fr 1fr; }
.sim-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.sim-colhead { font-size: 12px; font-weight: 650; color: var(--text-3); }
.sim-values { padding: 14px 16px; min-width: 0; }
.sim-values table { width: 100%; border-collapse: collapse; font-size: 14px; }
.sim-values th { text-align: left; font-size: 12px; font-weight: 750; text-transform: uppercase; letter-spacing: .04em; color: var(--text-3); padding: 0 6px 6px; }
.sim-values td { padding: 4px 6px; border-top: 1px solid var(--border); vertical-align: middle; }
.sim-values td:first-child { width: 2.5em; color: var(--text-3); font-weight: 650; }
.sim-values .num { text-align: right; width: 38%; }
.sim-mark { display: block; font-weight: 750; font-variant-numeric: tabular-nums; font-size: 15px; color: var(--ok); }
.sim-mark--none { color: var(--text-3); font-weight: 500; font-size: 13px; font-style: italic; }
.sim-bar { display: block; height: 5px; border-radius: 3px; background: var(--surface-3); margin-top: 3px; overflow: hidden; }
.sim-bar i { display: block; height: 100%; background: var(--ok); border-radius: 3px; transition: width .2s; }
.sim-note--max { color: #9b0026 !important; background: #fdecef !important; font-weight: 700; }
.sim-note { font-size: 13px; color: var(--warn); background: var(--warn-soft); border-radius: 8px; padding: 8px 10px; margin: 10px 0 0; }
@media (max-width: 760px) { .sim-body { grid-template-columns: 1fr; } .sim-params { border-right: 0; border-bottom: 1px solid var(--border); } }

.trades { margin: 0 0 1.6em; }
.trades-filter { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.trades-filter input { max-width: 320px; }
.trades-count { font-size: 13px; color: var(--text-3); white-space: nowrap; }
.trades-table th[scope="row"] { font-weight: 650; white-space: nowrap; }
.trades-pick { display: grid; gap: 6px; max-width: 460px; margin-bottom: 14px; font-weight: 650; font-size: 14.5px; }
.trades-pick select { font-size: 15.5px; padding: 9px 11px; }
.trades-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.trade-card { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); padding: 12px 14px; display: grid; gap: 6px; align-content: start; }
.trade-card header { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.trade-card header a { font-size: 12.5px; white-space: nowrap; }
.trade-method { font-size: 12px; font-weight: 750; text-transform: uppercase; letter-spacing: .04em; color: var(--primary-text); }
.trade-aspect { margin: 0; font-weight: 650; font-size: 14.5px; }
.trade-setting { margin: 0; font-size: 13.5px; color: var(--text-2); }
.trade-card--empty { background: var(--surface-2); }
.trade-card--empty .trade-setting { color: var(--text-3); font-style: italic; }

/* Cartes « méthode » sur la page de choix */
.method-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin: 0 0 1.4em; }
.trades .table-wrap { max-height: 440px; overflow-y: auto; }
.trades .table-wrap thead th { position: sticky; top: 0; background: var(--surface-2); z-index: 1; }

/* ==========================================================================
   Charte WorldSkills France — sobre, lisible, pour les débutants
   (inspirée de worldskills-france.org : marine, bleu, or, bande tricolore)
   ========================================================================== */
:root { --navy: #04153a; --navy-2: #0b2556; --gold: #c1a74a; --gold-text: #7a5f12; --gold-soft: #f6f0dc; --wsf-red: #c40030; }
body { font-size: 17px; line-height: 1.65; }
h1, h2, h3, h4 { color: var(--navy); font-weight: 700; letter-spacing: 0 !important; }

/* Bande tricolore + en-tête blanc avec le logo */
.tricolor { display: flex; height: 4px; position: sticky; top: 0; z-index: 51; }
.tricolor i { flex: 1; } .tricolor i:nth-child(1) { background: #1f3f94; } .tricolor i:nth-child(2) { background: #ffffff; } .tricolor i:nth-child(3) { background: #d6283c; }
.site-header { top: 4px; height: var(--header-h); background: #fff; -webkit-backdrop-filter: none; backdrop-filter: none; border-bottom: 1px solid var(--border); box-shadow: 0 1px 0 rgba(4, 21, 58, .04); }
.header-inner { gap: 18px; padding: 0 24px; }
.brand { gap: 14px; }
.brand-logo { height: 58px; width: auto; display: block; }
.brand-sep { width: 1px; height: 40px; background: var(--gold); }
.brand-text strong { font-size: 17px; color: var(--navy); }
.brand-text small { font-size: 13px; color: var(--gold-text); font-weight: 700; }
.header-nav a { font-size: 15.5px; font-weight: 700; color: var(--navy); border-radius: 999px; padding: 8px 14px; }
.header-nav a:hover { background: var(--surface-2); }
.header-nav a.active { background: var(--primary-soft); color: var(--primary); }
.search-trigger { border-radius: 999px; }
.seg { border-radius: 999px; }
.seg button { border-radius: 999px; }
@media (max-width: 1100px) { .brand-sep, .brand-text { display: none; } }
@media (max-width: 700px) { .brand-logo { height: 46px; } }

/* Boutons « pilule » */
.btn { border-radius: 999px; font-weight: 700; }
.btn--lg { height: 52px; padding: 0 24px; font-size: 16.5px; }
.btn--gold { background: var(--gold); color: var(--navy); }
.btn--gold:hover { background: #d4be6f; }
.btn--outline-light { background: transparent; border: 1px solid rgba(255, 255, 255, .7); color: #fff; }
.btn--outline-light:hover { background: rgba(255, 255, 255, .1); }
.pill { display: inline-flex; align-items: center; padding: 7px 16px; border: 1px solid var(--border-strong); border-radius: 999px; background: var(--surface); color: var(--navy); font-weight: 700; font-size: 14.5px; text-decoration: none; }
.pill:hover { border-color: var(--gold); }

/* Accueil : bienvenue + explication directe */
.welcome { background: var(--navy); color: #fff; padding: 56px 0 48px; border-bottom: 4px solid var(--gold); }
.welcome-inner { max-width: 960px; }
.welcome-kicker { color: var(--gold); font-weight: 700; margin: 0 0 10px; font-size: 15px; }
.welcome h1 { color: #fff; font-size: clamp(30px, 4.6vw, 46px); line-height: 1.12; margin: 0 0 16px; }
.welcome-lead { font-size: clamp(17px, 2vw, 20px); color: #dbe3f0; max-width: 780px; margin: 0 0 28px; }
.welcome-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 28px; }
.welcome-search { display: flex; align-items: center; gap: 10px; max-width: 640px; padding: 6px 6px 6px 16px; background: #fff; border-radius: 999px; color: var(--text-3); }
.welcome-search input { flex: 1; min-width: 0; border: 0 !important; background: transparent !important; box-shadow: none !important; padding: 0 !important; font-size: 16.5px; color: #1f2937; }
.section { padding-top: 44px; }
.section-title { font-size: 26px; margin: 0 0 6px; }
.section-lead { color: var(--text-2); margin: 0 0 18px; }
.intro3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.intro3-item { border-top: 3px solid var(--gold); padding-top: 14px; }
.intro3-num { font-size: 14px; font-weight: 700; color: var(--gold-text); }
.intro3-item h2 { font-size: 21px; margin: 4px 0 8px; }
.intro3-item p { margin: 0; color: var(--text-2); }
.guide-band { display: flex; align-items: center; gap: 18px; padding: 22px 24px; border-radius: var(--radius-lg); background: var(--surface-2); border: 1px solid var(--border); text-decoration: none; color: var(--text); }
.guide-band:hover { border-color: var(--gold); }
.guide-band-icon { width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; background: var(--navy); color: var(--gold); flex-shrink: 0; }
.guide-band-icon .i { width: 26px; height: 26px; }
.guide-band-text { flex: 1; display: grid; gap: 4px; }
.guide-band-text strong { font-size: 19px; color: var(--navy); }
.guide-band-text span { color: var(--text-2); }
.path-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.path-list a { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; color: var(--text); background: var(--surface); }
.path-list a:hover { border-color: var(--primary); }
.path-num { width: 34px; height: 34px; border-radius: 50%; background: var(--navy); color: #fff; font-weight: 700; display: grid; place-items: center; flex-shrink: 0; }
.path-text { flex: 1; display: grid; gap: 2px; min-width: 0; }
.path-text strong { color: var(--navy); }
.path-text small { color: var(--text-3); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.path-list .i { color: var(--text-3); }
.cat-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.cat-item { display: flex; gap: 12px; align-items: flex-start; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius); text-decoration: none; color: var(--text); }
.cat-item:hover { border-color: var(--primary); }
.cat-item-icon { color: var(--primary); padding-top: 2px; }
.cat-item strong { display: block; color: var(--navy); }
.cat-item small { color: var(--text-3); font-size: 14px; }
.help-box { display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; border-radius: var(--radius); background: var(--gold-soft); color: #4b3d0d; }
.help-box p { margin: 0; }
@media (max-width: 900px) { .intro3, .cat-list { grid-template-columns: 1fr; } .path-list { grid-template-columns: 1fr; } .guide-band { flex-wrap: wrap; } }

/* Catégories et cartes : plus sobres, une seule couleur */
.cat-icon, .side-ico { background: var(--primary-soft) !important; color: var(--primary) !important; }
.cat-card, .doc-card { box-shadow: none !important; }
.cat-card:hover, .doc-card:hover { transform: none !important; border-color: var(--primary) !important; }

/* Pages */
.article h1 { color: var(--navy); }
.article-date { display: flex; align-items: center; gap: 6px; font-size: 14px; color: var(--text-3); margin: 0 0 24px; padding-bottom: 14px; border-bottom: 1px solid var(--border); }
.menupath { margin-bottom: 10px; }
.badge { border-radius: 999px; }
.intro-box { background: var(--surface-2) !important; border: 0 !important; border-left: 4px solid var(--gold) !important; border-radius: var(--radius) !important; box-shadow: none !important; }
details.cheat { padding: 0 !important; margin: 0 0 24px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
details.cheat > summary { cursor: pointer; padding: 12px 16px; font-weight: 700; color: var(--navy); display: flex; align-items: center; gap: 8px; list-style: none; }
details.cheat > summary::-webkit-details-marker { display: none; }
details.cheat > summary::after { content: "+"; margin-left: auto; font-size: 20px; color: var(--text-3); }
details.cheat[open] > summary::after { content: "–"; }
details.cheat .cheat-list { margin: 0; padding: 0 16px 14px 40px; }
.prose h2 { font-size: 25px; padding-top: 6px; border-top: 1px solid var(--border); }
.prose h2:first-child { border-top: 0; }
.prose table th { background: var(--surface-2); color: var(--navy); }
.callout { border-radius: var(--radius); }
.steps > ol > li::before { background: var(--navy); color: #fff; }
.shot figure, .shot img { border-radius: 8px; }
.side-group summary { font-weight: 700; color: var(--navy); }
.side-guide { display: flex; align-items: center; gap: 10px; margin-top: 8px; padding: 12px 14px; border-radius: var(--radius); background: var(--navy); color: #fff; font-weight: 700; text-decoration: none; }
.side-guide .i { color: var(--gold); }
.next-step { border-color: var(--gold) !important; }

/* Pied de page avec le logo */
.site-footer { background: var(--surface-2); border-top: 4px solid var(--gold); padding: 40px 0 0; margin-top: 80px; }
.footer-inner { display: flex !important; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }
.footer-brand { display: flex; align-items: center; gap: 18px; max-width: 560px; }
.footer-logo { height: 84px; width: auto; display: block; flex-shrink: 0; }
.footer-logo-link { flex-shrink: 0; }
.footer-brand p { margin: 0; color: var(--text-2); font-size: 15px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px; }
.footer-note { display: flex !important; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding: 18px 24px 22px !important; margin-top: 28px; border-top: 1px solid var(--border); font-size: 13.5px; color: var(--text-3); }

/* ==========================================================================
   Guide pas à pas
   ========================================================================== */
.tour { max-width: 1280px; margin: 0 auto; padding: 28px 24px 0; }
.tour-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 32px; padding-bottom: 18px; border-bottom: 1px solid var(--border); margin-bottom: 22px; }
.tour-kicker { display: flex; align-items: center; gap: 8px; color: var(--gold-text); font-weight: 700; margin: 0 0 4px; }
.tour-head h1 { font-size: clamp(24px, 3vw, 32px); margin: 0; }
.tour-progress { display: grid; gap: 6px; min-width: 240px; flex: 0 1 320px; }
.tour-count { font-weight: 700; color: var(--navy); font-size: 15px; }
.tour-bar { height: 8px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.tour-bar i { display: block; height: 100%; background: var(--gold); border-radius: 999px; transition: width .25s; }
.tour-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 28px; align-items: start; }
.tour-chapters { position: sticky; top: calc(var(--header-h) + 20px); }
.tour-chapters-title { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--text-3); margin: 0 0 10px; }
.tour-chapters ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.tour-chapters button { width: 100%; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid transparent; border-radius: var(--radius); background: none; font: inherit; font-size: 15px; color: var(--text-2); text-align: left; cursor: pointer; }
.tour-chapters button:hover { background: var(--surface-2); }
.tour-chapters button.active { background: var(--primary-soft); color: var(--navy); font-weight: 700; border-color: color-mix(in srgb, var(--primary) 25%, transparent); }
.tc-num { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-3); font-size: 13px; font-weight: 700; flex-shrink: 0; }
.tour-chapters button.done .tc-num { background: var(--gold); color: var(--navy); }
.tour-chapters button.active .tc-num { background: var(--navy); color: #fff; }
.tc-label { flex: 1; }
.tc-count { font-size: 12.5px; color: var(--text-3); }
.tour-ch-select { display: none; }
.tour-stage { min-width: 0; }
.tour-chapter { margin: 0 0 10px; font-size: 13.5px; font-weight: 700; color: var(--gold-text); text-transform: uppercase; letter-spacing: .05em; }
.tour-shot { margin: 0 0 18px; }
.tour-frame { max-height: 58vh; overflow: auto; border: 1px solid var(--border-strong); border-radius: var(--radius); background: #fff; }
.tour-canvas { position: relative; width: 100%; margin: 0 auto; }
.tour-canvas img { display: block; width: 100%; height: auto; }
.tour-svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.tour-dim { fill: rgba(4, 21, 58, .55); }
.tour-ring { fill: none; stroke: var(--gold); stroke-width: 4; }
@media (prefers-reduced-motion: no-preference) { .tour-ring { animation: tour-pulse 1.6s ease-in-out infinite; } }
@keyframes tour-pulse { 50% { stroke-width: 7; stroke-opacity: .65; } }
.tour-line { stroke: var(--gold); stroke-width: 3; }
.tour-arrow-head { fill: var(--gold); }
.tour-bubble { position: absolute; left: 0; top: 0; display: flex; gap: 10px; align-items: flex-start; padding: 10px 14px; border-radius: 12px; background: #fff; color: var(--navy); font-weight: 700; font-size: 15px; line-height: 1.35; box-shadow: 0 8px 24px rgba(4, 21, 58, .35); border: 2px solid var(--gold); }
.tour-bubble-num { min-width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--navy); color: #fff; font-size: 13px; flex-shrink: 0; }
.tour-shot figcaption { margin-top: 6px; font-size: 14px; }
.tour-shot figcaption a { display: inline-flex; align-items: center; gap: 6px; }
.tour-intro { display: grid; place-items: center; padding: 40px; border-radius: var(--radius); background: var(--navy); color: var(--gold); margin-bottom: 18px; }
.tour-intro .i { width: 64px; height: 64px; }
.tour-text { background: var(--surface); }
.tour-text h2 { display: flex; align-items: center; gap: 12px; font-size: 24px; margin: 0 0 8px; }
.tour-n { min-width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--navy); color: #fff; font-size: 15px; flex-shrink: 0; }
.tour-text p { font-size: 18px; margin: 0 0 12px; }
.tour-text--final { padding: 16px 18px; border-radius: var(--radius); background: #fdecef; border-left: 5px solid var(--wsf-red); }
.tour-text--final .tour-n { background: var(--wsf-red); }
.tour-nav { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--border); }
.tour-keys { font-size: 13.5px; color: var(--text-3); }
.tour-done { text-align: center; padding: 36px 20px; border-radius: var(--radius-lg); background: var(--surface-2); }
.tour-done .i { width: 54px; height: 54px; color: var(--gold); }
.tour-done-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
@media (max-width: 900px) {
  .tour-layout { grid-template-columns: 1fr; gap: 14px; }
  .tour-chapters { position: static; }
  .tour-chapters ol, .tour-chapters-title { display: none; }
  .tour-ch-select { display: block; }
  .tour-ch-select select { width: 100%; }
  .tour-keys { display: none; }
  .tour-bubble { font-size: 13px; padding: 7px 10px; }
  .tour-frame { max-height: 52vh; }
}

/* Pages sans menu latéral : le bandeau d'accueil occupe toute la largeur */
.layout:not(.layout--sidebar) { max-width: none; }
html, body { background: #fff; color-scheme: light; }

/* ==========================================================================
   Formulaire « Votre avis »
   ========================================================================== */
.fb-open { border-color: var(--gold) !important; color: var(--navy) !important; }
@media (max-width: 1100px) { .fb-open span { display: none; } }
.pill--gold { border-color: var(--gold); background: var(--gold-soft); cursor: pointer; font: inherit; font-weight: 700; font-size: 14.5px; }
.fb-report { margin: 10px 0 0; font-size: 15px; color: var(--text-2); display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.fb-dialog { width: min(640px, calc(100vw - 24px)); max-height: calc(100vh - 32px); padding: 0; border: 0; border-top: 5px solid var(--gold); border-radius: var(--radius-lg); box-shadow: 0 24px 60px rgba(4, 21, 58, .35); color: var(--text); background: #fff; }
.fb-dialog::backdrop { background: rgba(4, 21, 58, .55); }
.fb-form { display: grid; gap: 14px; padding: 22px 24px; }
.fb-form header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.fb-form h2 { margin: 0; font-size: 22px; }
.fb-x { border: 0; background: none; font-size: 28px; line-height: 1; color: var(--text-3); cursor: pointer; padding: 0 4px; }
.fb-lead { margin: 0; color: var(--text-2); }
.fb-types { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.fb-types legend { font-weight: 700; color: var(--navy); margin-bottom: 8px; padding: 0; }
.fb-types label { cursor: pointer; }
.fb-types input { position: absolute; opacity: 0; pointer-events: none; }
.fb-types span { display: inline-block; padding: 7px 14px; border: 1px solid var(--border-strong); border-radius: 999px; font-size: 15px; }
.fb-types input:checked + span { background: var(--navy); border-color: var(--navy); color: #fff; }
.fb-types input:focus-visible + span { outline: 3px solid var(--gold); outline-offset: 2px; }
.fb-page { margin: 0; font-size: 14.5px; color: var(--text-3); }
.fb-page strong { color: var(--text); }
.fb-field { display: grid; gap: 6px; font-weight: 700; color: var(--navy); font-size: 15px; }
.fb-field textarea, .fb-field input { font-weight: 400; width: 100%; }
.fb-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.fb-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.fb-status { margin: 0; min-height: 1.2em; font-size: 15px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.fb-status--ok { color: #1f6b35; font-weight: 700; }
.fb-status--error { color: #9b0026; }
.fb-form footer { display: flex; justify-content: flex-end; gap: 10px; }
@media (max-width: 600px) { .fb-row { grid-template-columns: 1fr; } .fb-form { padding: 18px; } }
