/* Opendexa — charte de la plateforme (opendexa.com). Même jeton de couleur que la navbar partagée. */
:root {
  --bg: #ffffff; --bg-alt: #f5f7fb; --surface: #ffffff; --ink: #0f172a; --muted: #4b5875;
  --line: #dfe5ee; --field-line: #7b8497; --brand: #2346d8; --brand-ink: #ffffff; --brand-soft: #e8edff; --navy: #0f1b3d;
  --ok: #0f7b4b; --warn-bg: #fff6e0; --warn: #7a4b00;
  --radius: 14px; --max: 1160px;
  --shadow: 0 1px 2px rgba(15, 23, 42, .05), 0 10px 30px rgba(15, 23, 42, .07);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light;
}
/* Sombre par défaut (retours du propriétaire, 2026-11-09) ; clair seulement si l'utilisateur l'a choisi
   (data-theme="light", posé avant le premier rendu par le script en ligne du <head>, apply_navbar.THEME_HEAD). */
:root:not([data-theme="light"]) {
  --bg: #0b1020; --bg-alt: #10172b; --surface: #131b33; --ink: #e6ebf5; --muted: #a3aec6;
  --line: #26325a; --field-line: #5f6e9c; --brand: #8ea7ff; --brand-ink: #0b1020; --brand-soft: #1a2550; --navy: #060b18;
  --ok: #4ade80; --warn-bg: #2a2110; --warn: #fcd58a; --shadow: none; color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.6 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--brand); text-underline-offset: .15em; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; border-radius: 4px; }
img, svg { max-width: 100%; }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 16px; }
.skip { position: absolute; left: 16px; top: -60px; background: var(--brand); color: var(--brand-ink); padding: 8px 14px; border-radius: 8px; z-index: 2000; }
.skip:focus { top: 8px; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -.02em; margin: 0 0 12px; }
h1 { font-size: clamp(32px, 5vw, 52px); }
h2 { font-size: clamp(24px, 3.2vw, 34px); }
h3 { font-size: 19px; }
p { margin: 0 0 14px; }
.lead { font-size: 19px; color: var(--muted); max-width: 760px; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.center { text-align: center; }
.center .lead { margin-left: auto; margin-right: auto; }
section { padding: 72px 0; }
section.alt { background: var(--bg-alt); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.eyebrow { display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); margin-bottom: 12px; }

/* Boutons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 20px; border-radius: 10px;
  font-weight: 600; font-size: 15px; text-decoration: none; border: 1px solid transparent; cursor: pointer; font-family: inherit; }
.btn-primary { background: var(--brand); color: var(--brand-ink); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--field-line); }   /* 3:1 (UX-A09) */
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn[aria-disabled="true"], .btn:disabled { opacity: .6; cursor: not-allowed; }

/* Héros */
.hero { padding: 88px 0 64px; background:
  radial-gradient(1000px 420px at 85% -10%, color-mix(in srgb, var(--brand) 16%, transparent), transparent 70%),
  radial-gradient(700px 320px at 0% 0%, color-mix(in srgb, var(--brand) 8%, transparent), transparent 70%); }
.hero h1 span { color: var(--brand); }
.hero .actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 28px; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; margin-top: 48px; }
.stat { border-left: 3px solid var(--brand); padding: 4px 0 4px 14px; }
.stat strong { display: block; font-size: 26px; letter-spacing: -.02em; }
.stat span { color: var(--muted); font-size: 14px; }

/* Grilles et cartes */
.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); }
.module { display: flex; flex-direction: column; gap: 10px; }
.module h3 { margin: 0; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.module p { color: var(--muted); font-size: 15px; margin: 0; flex: 1; }
.module .meta { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 14px; flex-wrap: wrap; }
.module .meta a { font-weight: 600; text-decoration: none; }
.module .meta a:hover { text-decoration: underline; }
/* Tuile « Un outil vous manque ? » : même place qu'un outil, mais une invitation, pas un produit (pas de prix) */
.module.ask { background: transparent; box-shadow: none; border: 1.5px dashed var(--brand); }
.module.ask h3 { color: var(--brand); }
.ask-plus { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); font-weight: 800; }
.host { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; color: var(--muted); }
.badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 9px; border-radius: 999px; background: var(--brand-soft); color: var(--brand); letter-spacing: .01em; }
.badge.soon { background: var(--warn-bg); color: var(--warn); }
.group-title { margin: 40px 0 16px; font-size: 15px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }

/* Bundles et plans */
.bundles { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); margin-top: 32px; }
.bundle { position: relative; display: flex; flex-direction: column; }
.bundle.featured { border: 2px solid var(--brand); }
.bundle .flag { position: absolute; top: -12px; left: 20px; background: var(--brand); color: var(--brand-ink); font-size: 12px; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.price { font-size: 38px; font-weight: 800; letter-spacing: -.03em; margin: 6px 0 2px; }
.price small { font-size: 15px; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.bundle .who { font-size: 14px; color: var(--muted); }
.bundle ul, .plan ul { list-style: none; padding: 0; margin: 14px 0 20px; flex: 1; }
.bundle li, .plan li { padding: 5px 0 5px 24px; position: relative; font-size: 15px; }
.bundle li::before, .plan li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 700; }
.bundle li.soon::before { content: "◷"; color: var(--warn); }
.saving { font-size: 14px; color: var(--ok); font-weight: 600; margin: 0 0 12px; }
.plans { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.plan { display: flex; flex-direction: column; padding: 18px; }
.plan .price { font-size: 28px; }
.plan h4 { margin: 0; font-size: 16px; }
.module-pricing { margin-top: 48px; }
.module-pricing header { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.module-pricing header h3 { margin: 0; }
.pending { border: 1px dashed var(--line); border-radius: var(--radius); padding: 18px; color: var(--muted); }

/* Tableaux */
.table-wrap { position: relative; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 15px; }
th, td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
thead th { background: var(--bg-alt); font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
tbody tr:last-child td, tbody tr:last-child th { border-bottom: 0; }
td.num, th.num { text-align: right; white-space: nowrap; }

/* Étapes / arguments */
.steps { counter-reset: s; display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.steps .card::before { counter-increment: s; content: counter(s); display: inline-grid; place-items: center; width: 32px; height: 32px;
  border-radius: 50%; background: var(--brand-soft); color: var(--brand); font-weight: 800; margin-bottom: 10px; }

/* Formulaires (maquettes) */
.auth { max-width: 440px; margin: 0 auto; }
label { display: block; font-weight: 600; font-size: 14px; margin: 14px 0 6px; }
input[type="email"], input[type="password"], input[type="text"] { width: 100%; padding: 11px 12px; border-radius: 10px; border: 1px solid var(--field-line);
  background: var(--bg); color: var(--ink); font: inherit; }
.notice { background: var(--warn-bg); color: var(--warn); border-radius: 10px; padding: 12px 14px; font-size: 14px; }
.notice strong { color: inherit; }
.status-msg { margin-top: 14px; font-weight: 600; }
/* minmax(0, 1fr) : un tableau large défile dans sa zone au lieu d'élargir toute la page (UX-A04, 2026-11-14) */
.dash { display: grid; gap: 18px; grid-template-columns: 260px minmax(0, 1fr); align-items: start; }
.dash > * { min-width: 0; }
@media (max-width: 760px) { .dash { grid-template-columns: minmax(0, 1fr); } }
.side a { display: block; padding: 8px 10px; border-radius: 8px; text-decoration: none; color: var(--ink); }
.side a[aria-current="page"] { background: var(--brand-soft); color: var(--brand); font-weight: 600; }
.skeleton { height: 12px; border-radius: 6px; background: var(--bg-alt); margin: 10px 0; }

/* Pages légales */
.doc { max-width: 820px; }
.doc h2 { font-size: 22px; margin-top: 36px; }
.ph { background: var(--warn-bg); color: var(--warn); padding: 0 4px; border-radius: 4px; font-weight: 600; }
details { border-bottom: 1px solid var(--line); padding: 14px 0; }
summary { cursor: pointer; font-weight: 600; }

/* Pied de page */
footer.site { border-top: 1px solid var(--line); padding: 48px 0 32px; font-size: 14px; color: var(--muted); }
footer.site .cols { display: grid; gap: 28px; grid-template-columns: 2fr repeat(3, 1fr); }
@media (max-width: 760px) { footer.site .cols { grid-template-columns: 1fr 1fr; } }
footer.site strong { color: var(--ink); display: block; margin-bottom: 8px; }
footer.site ul { list-style: none; padding: 0; margin: 0; }
footer.site li { margin: 4px 0; }
footer.site a { color: var(--muted); text-decoration: none; }
footer.site a:hover { color: var(--brand); text-decoration: underline; }
footer.site .legal { margin-top: 32px; padding-top: 18px; border-top: 1px solid var(--line); }

/* Utilitaires */
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
ul.ticks { list-style: none; padding: 0; margin: 12px 0; }
ul.ticks li { padding: 5px 0 5px 24px; position: relative; }
ul.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 700; }
.bundle.proposal { border-style: dashed; box-shadow: none; }
.bundle.proposal .flag { background: var(--warn-bg); color: var(--warn); }
.compare { display: grid; gap: 18px; grid-template-columns: 1.4fr 1fr; align-items: stretch; }
@media (max-width: 760px) { .compare { grid-template-columns: 1fr; } }
.compare .us { border: 2px solid var(--brand); }
.compare .total { font-size: 30px; font-weight: 800; letter-spacing: -.02em; margin: 8px 0; }
.addon { border-top: 1px dashed var(--line); padding-top: 8px; margin: 4px 0 12px; color: var(--muted); }
.upsell { margin: 0 0 12px; font-weight: 600; }

/* Profils (accueil) */
.personas { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); margin-top: 24px; }
.persona { display: flex; flex-direction: column; gap: 10px; color: var(--ink); text-decoration: none; transition: border-color .2s, transform .2s; }
.persona h3 { margin: 0; font-size: 20px; }
.persona p { margin: 0; color: var(--muted); flex: 1; }
.persona .go { color: var(--brand); font-weight: 600; }
.persona:hover { border-color: var(--brand); transform: translateY(-2px); }
.persona:focus-visible { outline: 3px solid var(--brand); outline-offset: 3px; }
.persona.all { background: var(--brand-soft); }

/* Situations (pages par profil) */
.situations { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); margin-top: 24px; }
.situation h3 { margin: 0 0 8px; font-size: 17px; }
.situation p { margin: 0 0 8px; color: var(--muted); }
.situation p.small { margin: 0; }

/* Matrice des offres (page prix) */
.matrix-wrap { margin-top: 20px; position: relative; }  /* contient les textes réservés aux lecteurs d'écran */
table.matrix { font-size: 14px; min-width: 980px; }
.matrix thead th { position: sticky; top: 0; z-index: 2; text-transform: none; letter-spacing: 0; font-size: 14px;
  color: var(--ink); background: var(--bg-alt); vertical-align: bottom; min-width: 112px; }
.matrix thead th a { font-weight: 700; color: var(--ink); text-decoration: none; display: block; }
.matrix thead th a:hover { color: var(--brand); text-decoration: underline; }
.matrix thead .p { display: block; font-size: 17px; font-weight: 800; margin-top: 4px; }
.matrix thead .p small { font-size: 11px; font-weight: 500; color: var(--muted); }
.matrix thead .w { display: block; font-size: 12px; font-weight: 500; color: var(--muted); margin-top: 2px; }
.matrix th[scope="row"], .matrix .corner { position: sticky; left: 0; z-index: 1; background: var(--surface);
  min-width: 170px; font-weight: 600; }
.matrix .corner { z-index: 3; }
/* Téléphone : la zone du tableau défile dans les deux sens, l'en-tête des offres et la colonne des modules restent
   visibles (le sticky s'applique au conteneur qui défile), colonnes resserrées (UX-A10, 2026-11-14). */
@media (max-width: 760px) {
  .matrix-wrap { max-height: 78vh; overflow: auto; }
  table.matrix { min-width: 0; font-size: 13px; }
  .matrix thead th { min-width: 92px; }
  .matrix th[scope="row"], .matrix .corner { min-width: 118px; max-width: 118px; }
}
.matrix thead .corner { z-index: 3; background: var(--bg-alt); }
.matrix th[scope="row"] a { color: var(--ink); text-decoration: none; }
.matrix th[scope="row"] a:hover { color: var(--brand); text-decoration: underline; }
.matrix tr.grp th { background: var(--brand-soft); color: var(--brand); font-size: 12px; text-transform: uppercase;
  letter-spacing: .06em; position: static; }
.matrix td { text-align: center; }
.matrix td.yes strong { display: block; font-size: 13px; }
.matrix td.yes span:not(.tick):not(.visually-hidden) { display: block; font-size: 12px; color: var(--muted); line-height: 1.35; }
.matrix .tick { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%;
  background: var(--ok); color: var(--surface); font-weight: 800; font-size: 13px; margin-bottom: 4px; }
.matrix td.no { color: var(--muted); font-size: 18px; vertical-align: middle; }   /* sans opacité : 4,5:1 (UX-A20) */
.matrix tbody tr:hover td, .matrix tbody tr:hover th[scope="row"] { background: var(--bg-alt); }

/* Logo en grand sur l'accueil (build.py brand_hero) : les carrés de la grille se posent un à un, puis le nom apparaît */
.brand-hero { display: block; width: min(360px, 78vw); height: auto; margin: 0 0 28px; overflow: visible; }
.brand-hero g > rect { transform-box: fill-box; transform-origin: center; animation: odx-cell .45s cubic-bezier(.2,.8,.2,1.2) both; }
.brand-hero g > rect:nth-of-type(1) { animation-delay: .05s; } .brand-hero g > rect:nth-of-type(2) { animation-delay: .1s; }
.brand-hero g > rect:nth-of-type(3) { animation-delay: .15s; } .brand-hero g > rect:nth-of-type(4) { animation-delay: .2s; }
.brand-hero g > rect:nth-of-type(5) { animation-delay: .25s; } .brand-hero g > rect:nth-of-type(6) { animation-delay: .3s; }
.brand-hero g > rect:nth-of-type(7) { animation-delay: .35s; } .brand-hero g > rect:nth-of-type(8) { animation-delay: .4s; }
.brand-hero g > rect:nth-of-type(9) { animation-delay: .45s; }
.brand-hero g > path { animation: odx-fade .4s .55s both; }
.brand-hero > path { animation: odx-word .6s .6s cubic-bezier(.2,.8,.2,1) both; }
@keyframes odx-cell { from { opacity: 0; transform: scale(.2); } to { opacity: 1; transform: none; } }
@keyframes odx-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes odx-word { from { opacity: 0; transform: translateX(-12px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .brand-hero *, .brand-hero > path { animation: none !important; } }
:root:not([data-theme="light"]) .brand-hero [fill="#4F46E5"] { fill: #818CF8; }
:root:not([data-theme="light"]) .brand-hero [stroke="#4F46E5"] { stroke: #818CF8; }

/* Accueil v2 (2026-11-09) : 3 outils, chacun dans sa couleur (--tool), posés en colonnes puis l'un sous l'autre */
.tool-cards { display: grid; gap: 18px; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 24px; }
@media (max-width: 900px) { .tool-cards { grid-template-columns: 1fr; } }
.tool-card, .tool-price, .home-tool { border-top: 4px solid var(--tool, var(--brand)); display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.tool-card h3, .tool-price h3, .home-tool h3 { margin: 0; font-size: 21px; overflow-wrap: anywhere; }
.tool-card p { margin: 0; color: var(--muted); }
.tool-icon { display: inline-grid; place-items: center; width: 48px; height: 48px; border-radius: 12px;
  color: var(--tool, var(--brand)); background: color-mix(in srgb, var(--tool, var(--brand)) 12%, transparent); }
.tool-icon .odx-icon, .tool-eyebrow .odx-icon, .tool-price .odx-icon, .tool-group .odx-icon { color: var(--tool, var(--brand)); }
.tool-tabs-title { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.tool-tabs { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px; flex: 1; align-content: flex-start; }
.tool-tabs li { font-size: 13px; padding: 2px 10px; border-radius: 999px; border: 1px solid var(--line); }
.tool-card .go { font-weight: 600; text-decoration: none; color: var(--brand); }   /* 4,5:1 ; couleur de l'outil sur l'icône (UX-A08) */
.tool-card .go:hover { text-decoration: underline; }
.tool-price .price { font-size: 28px; }
.tool-group { color: var(--ink); scroll-margin-top: 80px; }   /* couleur de l'outil sur l'icône seulement (UX-A08) */

/* Accueil client (/compte/) : badges des 3 outils, accès rapides */
.home-tool .badge.in { background: color-mix(in srgb, var(--ok) 15%, transparent);
  color: color-mix(in srgb, var(--ok) 75%, var(--ink)); }   /* 12 px : 4,5:1 (UX-A19) */
.home-tool .badge.out { background: var(--bg-alt); color: var(--muted); }
.home-tool .actions { margin-top: auto; }
.quick { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); margin-top: 14px; }
.quick a { display: flex; gap: 10px; align-items: flex-start; text-decoration: none; color: var(--ink); }
.quick a:hover strong { color: var(--brand); text-decoration: underline; }
.quick .odx-icon { color: var(--brand); flex: none; margin-top: 3px; }
.quick span span { display: block; font-size: 14px; color: var(--muted); }
.recent { list-style: none; padding: 0; margin: 10px 0 0; }
.recent li { padding: 6px 0; border-bottom: 1px solid var(--line); }

/* Champ mot de passe avec bouton œil (comptes) : sans JavaScript, le bouton reste caché et le champ marche seul */
.pw-field { position: relative; }
.pw-field input { padding-right: 52px; }
.pw-toggle { position: absolute; top: 50%; right: 4px; transform: translateY(-50%); width: 44px; height: 40px;
  display: inline-grid; place-items: center; border: 0; border-radius: 8px; background: transparent; color: var(--muted); cursor: pointer; }
.pw-toggle:hover { color: var(--brand); }
.pw-toggle .pw-off, .pw-toggle[aria-pressed="true"] .pw-on { display: none; }
.pw-toggle[aria-pressed="true"] .pw-off { display: inline-flex; }
.pw-toggle[hidden] { display: none; }
