/* ══════════════════════════════════════════════════════════════
   Helix - pages de contenu (guides, expertises détaillées, à propos)
   S'appuie sur styles.css (.std-page, .ex-wrap, .ex-head, .ex-final, .ex-foot).
   ══════════════════════════════════════════════════════════════ */
:root {
  --pg-line: rgba(16,13,46,.09);
  --pg-soft: #F3F1FF;
  --pg-text: #2E2A50;
}
html[data-theme="dark"] {
  --pg-line: rgba(255,255,255,.12);
  --pg-soft: #1E1840;
  --pg-text: #D6D3EC;
}

/* Fil d'Ariane */
.pg-crumbs { font-size: 13.5px; color: var(--ink-3); margin-bottom: 18px; }
.pg-crumbs ol { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.pg-crumbs li + li::before { content: "›"; margin-right: 6px; color: var(--ink-3); }
.pg-crumbs a { color: var(--ink-2); text-decoration: none; }
.pg-crumbs a:hover { color: var(--acc-violet, #6662FF); }

/* Signature et date */
.pg-byline { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 26px auto 0; font-size: 14px; color: var(--ink-2); }
.pg-byline img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; object-position: center 18%; }
.pg-byline a { color: inherit; font-weight: 600; text-decoration: none; }
.pg-byline a:hover { color: var(--acc-violet, #6662FF); }
.pg-byline time { color: var(--ink-3); }

/* Mise en page : sommaire + texte */
.pg-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 48px; padding-top: 48px; padding-bottom: 12px; align-items: start; }
.pg-toc { position: sticky; top: 96px; font-size: 14px; border-left: 2px solid var(--pg-line); padding-left: 16px; }
.pg-toc strong { display: block; font-family: var(--font-mono); font-size: 11.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 10px; font-weight: 600; }
.pg-toc ol { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.pg-toc a { color: var(--ink-2); text-decoration: none; line-height: 1.4; display: block; }
.pg-toc a:hover { color: var(--acc-violet, #6662FF); }
@media (max-width: 900px) {
  .pg-layout { grid-template-columns: 1fr; gap: 24px; padding-top: 32px; }
  .pg-toc { position: static; border-left: 0; padding: 16px 18px; background: var(--bg-card); border: 1px solid var(--pg-line); border-radius: 14px; }
}

/* Texte */
.pg-prose { max-width: 720px; font-size: 17px; line-height: 1.72; color: var(--pg-text); }
.pg-prose > *:first-child { margin-top: 0; }
.pg-prose h2 { font-family: var(--font); font-size: clamp(24px, 2.6vw, 30px); font-weight: 700; letter-spacing: -.02em; line-height: 1.2; color: var(--ink); margin: 52px 0 14px; scroll-margin-top: 96px; }
.pg-prose h3 { font-family: var(--font); font-size: 20px; font-weight: 700; letter-spacing: -.01em; line-height: 1.3; color: var(--ink); margin: 30px 0 10px; }
.pg-prose p { margin: 0 0 16px; }
.pg-prose ul, .pg-prose ol { margin: 0 0 18px; padding-left: 22px; }
.pg-prose li { margin: 0 0 8px; }
.pg-prose li::marker { color: var(--acc-violet, #6662FF); }
.pg-prose strong { color: var(--ink); font-weight: 650; }
.pg-prose a { color: var(--acc-violet, #6662FF); text-decoration: underline; text-underline-offset: 2px; }
html[data-theme="dark"] .pg-prose a { color: #ABA7FF; }
.pg-prose blockquote { margin: 0 0 20px; padding: 18px 22px; background: var(--bg-card); border: 1px solid var(--pg-line); border-left: 4px solid var(--acc-violet, #6662FF); border-radius: 12px; font-size: 15.5px; line-height: 1.65; }
.pg-prose blockquote p:last-child { margin-bottom: 0; }
.pg-tw { overflow-x: auto; margin: 0 0 22px; border: 1px solid var(--pg-line); border-radius: 14px; background: var(--bg-card); }
.pg-prose table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.5; }
.pg-prose th, .pg-prose td { padding: 12px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--pg-line); }
.pg-prose th { font-family: var(--font); font-weight: 700; color: var(--ink); background: var(--pg-soft); }
.pg-prose tr:last-child td { border-bottom: 0; }
.pg-callout { margin: 0 0 22px; padding: 18px 22px; background: var(--pg-soft); border-radius: 14px; border: 1px solid var(--pg-line); }
.pg-callout p:last-child, .pg-callout ul:last-child { margin-bottom: 0; }
.pg-steps ol { list-style: none; counter-reset: st; padding: 0; margin: 0 0 22px; display: flex; flex-direction: column; gap: 12px; }
.pg-steps li { counter-increment: st; position: relative; padding: 14px 16px 14px 60px; background: var(--bg-card); border: 1px solid var(--pg-line); border-radius: 14px; margin: 0; }
.pg-steps li::before { content: counter(st); position: absolute; left: 16px; top: 13px; width: 30px; height: 30px; border-radius: 50%; background: var(--acc-violet, #6662FF); color: #fff; font-family: var(--font); font-weight: 700; font-size: 15px; display: flex; align-items: center; justify-content: center; }

/* FAQ */
.pg-faq { max-width: 720px; margin: 56px 0 0; }
.pg-faq h2 { font-family: var(--font); font-size: clamp(24px, 2.6vw, 30px); font-weight: 700; letter-spacing: -.02em; color: var(--ink); margin: 0 0 16px; }
.pg-faq details { background: var(--bg-card); border: 1px solid var(--pg-line); border-radius: 14px; margin-bottom: 10px; }
.pg-faq summary { cursor: pointer; list-style: none; padding: 16px 48px 16px 20px; font-weight: 650; color: var(--ink); position: relative; line-height: 1.4; }
.pg-faq summary::-webkit-details-marker { display: none; }
.pg-faq summary::after { content: "+"; position: absolute; right: 20px; top: 13px; font-size: 22px; color: var(--acc-violet, #6662FF); transition: transform .2s; }
.pg-faq details[open] summary::after { transform: rotate(45deg); }
.pg-faq details > div { padding: 0 20px 16px; color: var(--pg-text); font-size: 16px; line-height: 1.65; }
.pg-faq details a { color: var(--acc-violet, #6662FF); }

/* Pages liées */
.pg-related { margin: 56px 0 0; }
.pg-related h2 { font-family: var(--font); font-size: 22px; font-weight: 700; color: var(--ink); margin: 0 0 16px; }
.pg-related-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 14px; }
.pg-related a { display: block; padding: 18px 20px; background: var(--bg-card); border: 1px solid var(--pg-line); border-radius: 16px; text-decoration: none; color: var(--ink); transition: transform .2s, border-color .2s; }
.pg-related a:hover { transform: translateY(-2px); border-color: var(--acc-violet, #6662FF); }
.pg-related b { display: block; font-family: var(--font); font-size: 17px; margin-bottom: 6px; }
.pg-related span { font-size: 14px; color: var(--ink-2); line-height: 1.5; }

/* Pied de page : coordonnées */
.ex-foot .nap { width: 100%; font-size: 13px; line-height: 1.7; color: rgba(255,255,255,.6); }
.ex-foot .nap a { font-size: 13px; }

@media (prefers-reduced-motion: reduce) {
  .pg-related a:hover { transform: none; }
  .pg-faq summary::after { transition: none; }
}

/* cellules chiffrées : jamais coupées */
.pg-prose td.num { white-space: nowrap; }
