.aide-page {
    --bg: #eaf2f2;
    --paper: #fff;
    --ink: #0e2a33;
    --mute: #4d6670;
    --line: #d3e0e1;
    --teal: #00b8c2;
    --deep: #00606a;
    --deepbg: #07404a;
    --tint: #e1f5f6;
    --amber: #f2a93b;
    --amberbg: #fdf1da;
    --green: #1f7a4d;
    --greenbg: #e2f3ea;
    --blue: #2c64b8;
    --yellow: #c58a00;
    --text-primary: var(--ink);
    --text-secondary: var(--mute);
    --bg-secondary: var(--paper);
    --border-color: var(--line);
    box-sizing: border-box;
    width: 100%;
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 20px 40px;
    background: var(--bg);
    color: var(--ink);
    font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
    font-size: 18px;
    line-height: 1.6;
    overflow-wrap: anywhere;
}
.aide-page.aide-big { font-size: 22px; }
.aide-page *, .aide-page *::before, .aide-page *::after { box-sizing: border-box; }
.aide-page [hidden] { display: none !important; }
.aide-page button, .aide-page input { font: inherit; }
.aide-page button, .aide-page a { -webkit-tap-highlight-color: transparent; }
.aide-page a { color: inherit; text-decoration: none; }
.aide-page button { cursor: pointer; }
.aide-page :focus-visible { outline: 3px solid var(--deep); outline-offset: 4px; }
.aide-page svg { width: 1.25em; height: 1.25em; flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Les thèmes globaux imposent des cadres et couleurs avec !important. */
.aide-page #aide-view :is(h1, h2, h3) { color: inherit !important; }
.aide-page #aide-view :is(.aide-lead, .aide-sub, .aide-legend, .aide-crumb, .aide-screen-label) { color: var(--mute) !important; }
.aide-page h2 {
    display: block;
    background: none !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    text-align: left;
    text-transform: none;
    text-shadow: none;
    font-size: 1.6em;
    font-weight: 800;
    line-height: 1.3;
    letter-spacing: -.015em;
}
.aide-page h2::before, .aide-page h2::after { content: none; }
.aide-page .aide-bar { display: flex; align-items: center; gap: 14px; padding: 18px 0; flex-wrap: wrap; }
.aide-page .aide-logo { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.3em; letter-spacing: -.02em; }
.aide-page .aide-logo > span:last-child { color: var(--mute); font-weight: 600; }
.aide-page .aide-logo-img { width: 130px; }
.aide-page .aide-tools { margin-left: auto; display: flex; gap: 10px; flex-wrap: wrap; }
.aide-page .aide-tool { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--paper); border: 1.5px solid var(--line); border-radius: 12px; padding: 9px 14px; font-size: .85em; font-weight: 700; color: var(--ink); min-height: 44px; box-shadow: none; }
.aide-page .aide-tool[aria-pressed="true"] { border-color: var(--deep); background: var(--tint); }
.aide-page .aide-hero { padding: 26px 0 10px; }
.aide-page h1 { font-size: 2.5em; line-height: 1.1; letter-spacing: -.025em; font-weight: 800; margin: 0 0 10px; max-width: 16ch; padding: 0; background: none; border: 0; box-shadow: none; text-shadow: none; }
.aide-page .aide-lead { font-size: 1.15em; color: var(--mute); margin: 0 0 24px; max-width: 46ch; white-space: pre-line; }
.aide-page .aide-search { display: flex; align-items: stretch; width: 100%; max-width: 720px; margin: 0; background: var(--paper); border: 2px solid var(--deep); border-radius: 18px; overflow: hidden; }
.aide-page .aide-search svg { margin-left: 18px; align-self: center; color: var(--deep); width: 1.6em; height: 1.6em; }
.aide-page .aide-search input { flex: 1 1 0; width: 0; min-width: 0; max-width: none; height: auto; margin: 0; border: 0 !important; border-radius: 0; padding: 18px 14px; font-size: 1em; background: transparent !important; color: var(--ink) !important; box-shadow: none; }
.aide-page .aide-search input::placeholder { color: var(--mute); opacity: 1; }
.aide-page .aide-search:focus-within { outline: 3px solid var(--teal); outline-offset: 4px; }
.aide-page .aide-search input:focus { outline: none; box-shadow: none; }
.aide-page .aide-search button { flex: none; align-self: stretch; margin: 0; border: 0; border-radius: 0; background: var(--deep); color: var(--paper); font-size: 1em; font-weight: 800; padding: 0 22px; box-shadow: none; }
.aide-page .aide-section-title { margin: 44px 0 4px; }
.aide-page .aide-sub { margin: 0 0 18px; font-size: 1.15em; color: var(--mute); }
.aide-page .aide-connections, .aide-page .aide-docs, .aide-page .aide-pages { display: grid; align-items: stretch; }
.aide-page .aide-connections, .aide-page .aide-docs { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.aide-page .aide-card, .aide-page .aide-page-card, .aide-page .aide-doc-column { background: var(--paper) !important; border: 1.5px solid var(--line) !important; color: var(--ink) !important; box-shadow: none; min-width: 0; margin: 0; }
.aide-page #aide-view :is(.aide-card, .aide-card-icon, .aide-page-card) { transform: none; box-shadow: none; }
.aide-page .aide-card { border-radius: 22px; padding: 22px; display: flex; flex-direction: column; gap: 12px; min-height: 300px; }
.aide-page .aide-card-icon { width: 56px; height: 56px; flex: none; margin: 0; padding: 0; border: 0 !important; border-radius: 16px; background: var(--tint) !important; color: var(--deep) !important; box-shadow: none; display: grid; place-items: center; }
.aide-page .aide-card-icon svg { width: 28px; height: 28px; }
.aide-page .aide-card h3 { margin: 6px 0 0; padding: 0; font-size: 1.35em; font-weight: 800; line-height: 1.2; letter-spacing: -.01em; }
.aide-page .aide-card p { margin: 0; color: inherit; font-size: 1em; }
.aide-page .aide-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.aide-page .aide-pill { --text-primary: var(--deep); border-radius: 999px; padding: 4px 12px; font-size: .8em; font-weight: 700; background: var(--tint); color: var(--text-primary); }
.aide-page .aide-pill-green { --text-primary: var(--green); background: var(--greenbg); }
.aide-page .aide-go { --text-primary: var(--deep); display: flex; align-items: center; gap: 8px; font-size: 1em; font-weight: 800; color: var(--text-primary); padding-top: 14px; border-top: 1.5px solid var(--line); }
.aide-page .aide-card-first { --text-primary: var(--paper); background: var(--deepbg) !important; border-color: var(--deepbg) !important; color: var(--paper) !important; }
.aide-page .aide-card-first .aide-card-icon { background: var(--teal) !important; color: var(--ink) !important; }
.aide-page .aide-card-first .aide-pill { --text-primary: #d6f4f6; background: #0d5560; }
.aide-page .aide-card-first .aide-pill-green { --text-primary: var(--ink); background: var(--teal); }
.aide-page .aide-card-first .aide-go { --text-primary: var(--paper); border-color: #1c5a64; }
.aide-page .aide-pages { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.aide-page .aide-page-card { border-radius: 16px; padding: 16px 18px; display: flex; flex-direction: column; gap: 4px; min-height: 112px; }
.aide-page .aide-page-card b { display: flex; align-items: center; gap: 10px; font-size: 1.05em; }
.aide-page .aide-page-card b::before, .aide-page .aide-legend i { content: ""; width: 12px; height: 12px; border-radius: 4px; background: var(--aide-family, var(--blue)); flex: none; }
.aide-page .aide-family-quotidien { --aide-family: var(--blue); }
.aide-page .aide-family-activite { --aide-family: var(--green); }
.aide-page .aide-family-argent { --aide-family: var(--yellow); }
.aide-page .aide-page-card > span { font-size: 1em; color: var(--ink); line-height: 1.4; }
.aide-page .aide-legend { display: flex; gap: 18px; flex-wrap: wrap; margin: 0 0 14px; font-size: .85em; color: var(--mute); }
.aide-page .aide-legend span { display: flex; align-items: center; gap: 8px; }
.aide-page .aide-doc-column { border-radius: 22px; padding: 16px; }
.aide-page .aide-doc-column h3 { display: flex; align-items: center; gap: 12px; margin: 0; padding: 0 0 12px; font-size: 1.2em; font-weight: 800; }
.aide-page .aide-doc-column h3 svg { width: 28px; height: 28px; color: var(--deep); }
.aide-page .aide-doc-row { display: flex; align-items: center; gap: 12px; padding: 13px 0; border-top: 1.5px solid var(--line); font-weight: 600; font-size: 1em; line-height: 1.35; }
.aide-page .aide-doc-row svg { color: var(--deep); }
.aide-page .aide-ask { width: 100%; text-align: left; margin-top: 44px; background: var(--amberbg); border: 1.5px solid #f0d49c; border-radius: 22px; padding: 22px; display: flex; gap: 20px; align-items: center; color: var(--ink); box-shadow: none; }
.aide-page .aide-orb { width: 60px; height: 60px; border-radius: 50%; background: var(--teal); color: var(--deepbg); font-weight: 800; display: grid; place-items: center; flex: none; }
.aide-page .aide-ask strong { display: block; font-size: 1.25em; }
.aide-page .aide-ask small { font-size: 1em; color: var(--mute); }
.aide-page .aide-crumb { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; font-size: .85em; color: var(--mute); padding: 6px 0 0; }
.aide-page .aide-crumb a { --text-primary: var(--deep); color: var(--text-primary); font-weight: 700; }
.aide-page .aide-crumb svg { width: 1em; height: 1em; }
.aide-page .aide-article-meta { margin: 6px 0 30px; }
.aide-page .aide-route { position: relative; }
.aide-page .aide-route::before { content: ""; position: absolute; left: 27px; top: 30px; bottom: 60px; width: 4px; background: repeating-linear-gradient(to bottom, var(--teal) 0 10px, transparent 10px 18px); border-radius: 2px; }
.aide-page .aide-step { position: relative; display: grid; grid-template-columns: 58px minmax(0, 1fr); gap: 22px; margin: 0 0 26px; }
.aide-page .aide-step-number { --text-primary: var(--paper); width: 58px; height: 58px; border-radius: 50%; background: var(--deepbg); color: var(--text-primary); font-weight: 800; font-size: 1.5em; display: grid; place-items: center; border: 5px solid var(--bg); position: relative; z-index: 1; }
.aide-page .aide-step-box, .aide-page .aide-panel { background: var(--paper); border: 1.5px solid var(--line); border-radius: 22px; padding: 22px; min-width: 0; }
.aide-page .aide-step h2 { margin: 0 0 6px; }
.aide-page .aide-step p { margin: 0 0 14px; max-width: 60ch; white-space: pre-line; }
.aide-page .aide-screen { border: 1.5px solid var(--line); border-radius: 16px; overflow: hidden; background: #f5f9f9; margin: 6px 0 0; }
.aide-page .aide-screen-bar { display: flex; gap: 6px; padding: 10px 12px; background: #dfeaea; }
.aide-page .aide-screen-bar i { width: 10px; height: 10px; border-radius: 50%; background: #b6c9ca; }
.aide-page .aide-screen-body { padding: 18px; display: grid; gap: 12px; }
.aide-page .aide-screen-line { height: 12px; border-radius: 6px; background: #dbe6e6; }
.aide-page .aide-screen-line-short { width: 55%; }
.aide-page .aide-screen-line-medium { width: 75%; }
.aide-page .aide-screen-label { color: var(--mute); font-size: .85em; }
.aide-page .aide-screen img { display: block; width: 100%; height: auto; }
.aide-page .aide-hint { display: flex; gap: 12px; align-items: flex-start; border-radius: 14px; padding: 14px 16px; margin-top: 14px; font-weight: 600; font-size: 1em; white-space: pre-line; }
.aide-page .aide-hint svg { margin-top: 3px; }
.aide-page .aide-hint-ok { --text-primary: #175c39; background: var(--greenbg); color: var(--text-primary); }
.aide-page .aide-hint-warn { --text-primary: #6b4a07; background: var(--amberbg); color: var(--text-primary); }
.aide-page .aide-panel { margin: 0 0 18px; }
.aide-page .aide-panel h2 { margin: 0 0 10px; }
.aide-page .aide-panel ul { margin: 0; padding-left: 1.2em; }
.aide-page .aide-panel li { margin: 6px 0; white-space: pre-line; }
.aide-page .aide-question { --text-primary: var(--deep); display: inline-block; background: var(--tint); color: var(--text-primary); border-radius: 12px; padding: 8px 14px; font-weight: 700; margin: 4px 6px 4px 0; font-size: 1em; white-space: pre-line; }
.aide-page .aide-next { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 14px; margin-top: 8px; }
.aide-page .aide-next a { display: inline-flex; align-items: center; gap: 10px; border-radius: 16px; padding: 18px 22px; font-weight: 800; font-size: 1.05em; background: var(--paper); border: 1.5px solid var(--line); }
.aide-page .aide-next a:last-child { margin-left: auto; }
.aide-page .aide-next .aide-primary { --text-primary: var(--paper); background: var(--deep); color: var(--text-primary); border-color: var(--deep); }

.aide-nav-separator { border: 0; border-top: 1.5px solid var(--border-color); margin: 6px 8px; }
#lou-page-plus .aide-nav-entry { display: flex; align-items: center; gap: 12px; background: var(--upstay-blue); color: var(--bg-secondary); border-radius: 12px; padding: 16px 14px; font-size: 18px; font-weight: 700; width: 100%; text-align: left; border: 0; }
#lou-page-plus .aide-nav-entry .lou-plus-label { color: inherit; }
html.theme-dark #lou-page-plus .aide-nav-entry { color: var(--text-primary); }
.aide-new { margin-left: auto; background: var(--app-gold); color: var(--app-text-dark); border-radius: 999px; padding: 2px 10px; font-size: .7em; font-weight: 800; }
@media (max-width: 900px) {
    .aide-page .aide-connections, .aide-page .aide-docs, .aide-page .aide-pages { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .aide-page .aide-card { min-height: 0; }
    .aide-page h1 { font-size: 2em; }
}
@media (max-width: 560px) {
    .aide-page { padding: 0 12px 32px; }
    .aide-page .aide-connections, .aide-page .aide-docs, .aide-page .aide-pages { grid-template-columns: minmax(0, 1fr); }
    .aide-page .aide-tools { margin-left: 0; }
    .aide-page .aide-logo { flex-wrap: wrap; }
    .aide-page .aide-step { grid-template-columns: 44px minmax(0, 1fr); gap: 14px; }
    .aide-page .aide-step-number { width: 44px; height: 44px; font-size: 1.2em; }
    .aide-page .aide-route::before { left: 20px; }
    .aide-page .aide-step-box { padding: 18px 16px; }
    .aide-page .aide-search { flex-wrap: wrap; }
    .aide-page .aide-search svg { margin-left: 12px; }
    .aide-page .aide-search button { width: 100%; padding: 18px 12px; }
    .aide-page .aide-ask { flex-direction: column; align-items: flex-start; }
}
@media print {
    body.aide-print > :not(.container) { display: none !important; }
    body.aide-print .container { display: block !important; max-width: none !important; padding: 0 !important; }
    body.aide-print .container > :not(#tab-aide) { display: none !important; }
    body.aide-print #tab-aide, body.aide-print #aide-page { display: block !important; }
    .aide-page .aide-tools, .aide-page .aide-search, .aide-page .aide-next, .aide-page .aide-ask, .aide-page .aide-crumb { display: none !important; }
    .aide-page { max-width: none; font-size: 12pt; padding: 0; color: CanvasText; background: Canvas; }
    .aide-page .aide-step-box, .aide-page .aide-panel, .aide-page .aide-card, .aide-page .aide-doc-column { break-inside: avoid; color: CanvasText !important; background: Canvas !important; }
}
