/* Optencis Edge : page du cours, leçons, déblocage (maquette dev/maquettes/edge-parcours.html). */
.opx-edge-app {
	--e-ink: var(--wp--preset--color--ink, #01182A);
	--e-blue: var(--wp--preset--color--blue, #0D36D0);
	--e-ivory: var(--wp--preset--color--ivory, #FEFFFA);
	--e-muted: var(--wp--preset--color--ink-muted, #4F5B66);
	--e-line: var(--wp--preset--color--platinum, #E4E4E6);
	--e-cyan: var(--wp--preset--color--cyan, #1FCDFF);
	--e-gold: var(--wp--preset--color--market-gold, #FFB800);
	--e-green: #0B7F55;
	--e-soft: #EEF1FC;
	/* Variables du guide (tableaux partagés). */
	--g-line: var(--e-line); --g-muted: var(--e-muted); --g-blue: var(--e-blue); --g-ink: var(--e-ink);
	color: var(--e-ink);
	margin-block: 0 !important;
}
.opx-edge-app *, .opx-edge-app *::before, .opx-edge-app *::after { box-sizing: border-box; }
.opx-eh__wrap { max-width: 1120px; margin: 0 auto; padding-inline: clamp(16px, 4vw, 32px); }

/* Boutons */
.opx-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 22px; border: 0; border-radius: 999px; font: inherit; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; text-decoration: none !important; cursor: pointer; transition: transform .15s ease, box-shadow .15s ease; }
.opx-btn:hover { transform: translateY(-1px); }
.opx-btn--light { background: var(--e-ivory); color: var(--e-blue) !important; box-shadow: 0 8px 24px rgba(1, 24, 42, .25); }
.opx-btn--ghost { background: transparent; color: var(--e-ivory) !important; border: 1px solid rgba(254, 255, 250, .35); }
.opx-btn--blue { background: var(--e-blue); color: #fff !important; box-shadow: 0 8px 22px rgba(13, 54, 208, .25); }
.opx-btn--line { background: #fff; color: var(--e-blue) !important; border: 1px solid var(--e-line); }
.opx-btn:focus-visible { outline: 2px solid var(--e-cyan); outline-offset: 3px; }

/* ── Page du cours ── */
.opx-eh__hero { position: relative; overflow: hidden; padding: clamp(44px, 7vw, 76px) 0 clamp(40px, 6vw, 60px); color: var(--e-ivory); background: radial-gradient(1000px 380px at 85% -10%, rgba(31, 205, 255, .2), transparent 60%), linear-gradient(180deg, var(--e-ink), #06205e 70%, var(--e-blue) 150%); }
.opx-eh__hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(115deg, transparent 58%, rgba(255, 255, 255, .05) 58%, rgba(255, 255, 255, .05) 72%, transparent 72%); }
.opx-eh__grid { position: relative; z-index: 1; display: grid; grid-template-columns: 1.35fr 1fr; gap: 36px; align-items: end; }
@media (max-width: 880px) { .opx-eh__grid { grid-template-columns: 1fr; } }
.opx-eh__eyebrow { margin: 0; color: var(--e-cyan); font-size: 12px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; }
.opx-eh__title { margin: 10px 0 12px; color: inherit; font-size: clamp(40px, 6.4vw, 66px); font-weight: 500; letter-spacing: -.025em; line-height: 1.02; }
.opx-eh__lead { max-width: 600px; margin: 0; color: rgba(254, 255, 250, .82); font-size: clamp(16px, 2vw, 19px); line-height: 1.6; }
.opx-eh__facts { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 22px 0 0; padding: 0; list-style: none; color: rgba(254, 255, 250, .75); font-size: 14px; }
.opx-eh__facts b { color: #fff; }
.opx-eh__actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 0; }
.opx-eh__card { padding: 22px; border: 1px solid rgba(255, 255, 255, .16); border-radius: 20px; background: rgba(255, 255, 255, .07); backdrop-filter: blur(6px); }
.opx-eh__card .opx-btn { width: 100%; margin-top: 8px; }
.opx-eh__card-k { margin: 0; color: var(--e-cyan); font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.opx-eh__card-t { margin: 6px 0 4px; font-size: 20px; font-weight: 600; }
.opx-eh__ticks { margin: 12px 0 14px; padding: 0; list-style: none; color: rgba(254, 255, 250, .86); font-size: 14px; }
.opx-eh__ticks li { position: relative; padding: 4px 0 4px 26px; }
.opx-eh__ticks li::before { content: "✓"; position: absolute; left: 0; top: 3px; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: rgba(31, 205, 255, .2); color: var(--e-cyan); font-size: 11px; font-weight: 800; }
.opx-eh__fine { margin: 10px 0 0; color: rgba(254, 255, 250, .55); font-size: 12px; }
.opx-eh__ring { position: relative; width: 96px; height: 96px; margin: 12px 0 6px; }
.opx-eh__ring svg { transform: rotate(-90deg); }
.opx-eh__ring circle { fill: none; stroke-width: 3.2; }
.opx-eh__ring .bg { stroke: rgba(255, 255, 255, .14); }
.opx-eh__ring .fg { stroke: var(--e-cyan); stroke-linecap: round; transition: stroke-dasharray .6s ease; }
.opx-eh__ring b { position: absolute; inset: 0; display: grid; place-items: center; font-size: 18px; }

.opx-eh__learn { padding-top: 48px; }
.opx-eh__learn h2, .opx-eh__prog h2, .opx-eh__levels h2, .opx-eh__why h2 { margin: 0 0 18px; font-size: clamp(24px, 3.4vw, 32px); font-weight: 600; letter-spacing: -.01em; }
.opx-eh__learn-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; }
.opx-eh__learn-card { padding: 20px; border: 1px solid var(--e-line); border-radius: 18px; background: #fff; }
.opx-eh__learn-card span { display: inline-grid; place-items: center; width: 36px; height: 36px; margin-bottom: 12px; border-radius: 10px; background: var(--e-soft); color: var(--e-blue); font-weight: 800; }
.opx-eh__learn-card b { display: block; margin-bottom: 6px; font-size: 17px; }
.opx-eh__learn-card p { margin: 0; color: var(--e-muted); font-size: 14px; line-height: 1.55; }

.opx-eh__prog { padding-top: 54px; }
.opx-eh__prog-head { display: flex; flex-wrap: wrap; gap: 6px 20px; align-items: baseline; justify-content: space-between; }
.opx-eh__prog-head p { margin: 0; color: var(--e-muted); font-size: 14px; }
.opx-eh__chapter { margin-top: 26px; }
.opx-eh__chapter h3 { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; margin: 0 0 12px; font-size: 20px; }
.opx-eh__chapter h3 span { color: var(--e-blue); font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.opx-eh__chapter h3 small { color: var(--e-muted); font-size: 13px; font-weight: 500; }
.opx-eh__lessons { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 12px; }

/* Carte de leçon */
.opx-lc { position: relative; display: flex; flex-direction: column; gap: 6px; overflow: hidden; padding: 16px 18px 18px; border: 1px solid var(--e-line); border-radius: 16px; background: #fff; color: var(--e-ink) !important; text-decoration: none !important; transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease; }
.opx-lc:hover { border-color: var(--e-blue); transform: translateY(-2px); box-shadow: 0 10px 28px rgba(13, 54, 208, .1); }
.opx-lc__top { display: flex; justify-content: space-between; gap: 8px; color: var(--e-muted); font-size: 12px; }
.opx-lc__tag { display: inline-flex; gap: 5px; align-items: center; padding: 2px 9px; border-radius: 999px; background: var(--e-soft); color: var(--e-blue); font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
.opx-lc__title { font-size: 16.5px; line-height: 1.3; }
.opx-lc__sum { color: var(--e-muted); font-size: 13.5px; line-height: 1.5; }
.opx-lc.is-open:first-child, .opx-lc.is-open { border-color: rgba(13, 54, 208, .45); }
.opx-lc.is-open .opx-lc__tag { background: rgba(11, 127, 85, .12); color: var(--e-green); }
.opx-lc.is-soon .opx-lc__tag { background: #f1f2f5; color: var(--e-muted); }
.opx-lc.is-locked .opx-lc__sum, .opx-lc.is-bronze .opx-lc__sum { filter: blur(4.5px); user-select: none; }
.opx-lc__veil { position: absolute; inset: auto 0 0; display: flex; align-items: flex-end; justify-content: center; height: 56%; padding-bottom: 14px; background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, .94) 55%); color: var(--e-blue); font-size: 12.5px; font-weight: 700; }
.opx-lc.is-bronze .opx-lc__tag { background: linear-gradient(90deg, #c98a4b, #e7b07a); color: #3b2108; }
.opx-lc.is-bronze .opx-lc__veil { color: #8a5a2b; }
.opx-lc__done { display: none; gap: 5px; align-items: center; margin-top: 4px; color: var(--e-green); font-size: 12px; font-weight: 700; }
.opx-lc.is-done .opx-lc__done { display: inline-flex; }
.opx-lc.is-done { border-color: rgba(11, 127, 85, .45); }

.opx-eh__levels { padding-top: 54px; }
.opx-eh__levels p, .opx-eh__why p { max-width: 720px; margin: 0 0 16px; color: var(--e-muted); line-height: 1.6; }
.opx-eh__tiers { display: flex; flex-wrap: wrap; gap: 8px; }
.opx-tier { padding: 7px 12px; border: 1px solid var(--e-line); border-radius: 10px; background: #fff; color: var(--e-muted); font-size: 12.5px; font-weight: 700; }
.opx-tier.is-on { border-color: var(--e-blue); background: var(--e-soft); color: var(--e-blue); }
.opx-tier.is-oic { display: inline-flex; flex-direction: column; border-color: var(--e-ink); background: var(--e-ink); color: var(--e-gold); line-height: 1.15; }
.opx-tier.is-oic small { color: rgba(254, 255, 250, .6); font-size: 10px; font-weight: 600; }
.opx-eh__why { padding-top: 48px; }
.opx-eh__why > div { padding: 24px; border-left: 4px solid var(--e-blue); border-radius: 0 18px 18px 0; background: var(--e-soft); }
.opx-eh__why h2 { margin-bottom: 8px; font-size: 22px; }
.opx-eh__why p { margin: 0; color: var(--e-ink); }
.opx-eh__risk { margin: 34px 0 60px; padding: 12px 16px; border-left: 3px solid var(--e-gold); border-radius: 0 8px 8px 0; background: rgba(255, 184, 0, .08); color: var(--e-muted); font-size: 13px; }

/* ── Leçon ── */
.opx-lp__bar { position: sticky; top: var(--wp-admin--admin-bar--height, 0px); z-index: 30; border-bottom: 1px solid var(--e-line); background: rgba(254, 255, 250, .96); backdrop-filter: blur(6px); }
.opx-lp__bar-in { display: flex; flex-wrap: wrap; gap: 4px 16px; align-items: center; justify-content: space-between; max-width: 1180px; margin: 0 auto; padding: 10px clamp(16px, 4vw, 32px); font-size: 13px; }
.opx-lp__crumb a { color: var(--e-blue); font-weight: 600; text-decoration: none; }
.opx-lp__count { color: var(--e-muted); }
.opx-lp__progress { height: 3px; background: var(--e-soft); }
.opx-lp__progress span { display: block; height: 100%; background: linear-gradient(90deg, var(--e-blue), var(--e-cyan)); transform: scaleX(0); transform-origin: left; }
.opx-lp__grid { display: grid; grid-template-columns: 250px minmax(0, 720px); gap: 48px; justify-content: center; max-width: 1180px; margin: 0 auto; padding: 30px clamp(16px, 4vw, 32px) 20px; }
@media (max-width: 1000px) { .opx-lp__grid { grid-template-columns: minmax(0, 720px); gap: 18px; } }

/* Sommaire du cours */
.opx-nav { position: sticky; top: calc(var(--wp-admin--admin-bar--height, 0px) + 70px); align-self: start; max-height: calc(100vh - 100px); overflow: auto; font-size: 13px; }
@media (max-width: 1000px) { .opx-nav { position: static; max-height: none; } }
.opx-nav summary { margin-bottom: 8px; color: var(--e-muted); font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; cursor: pointer; }
.opx-nav details:not([open]) summary { margin-bottom: 0; }
@media (min-width: 1001px) { .opx-nav details[open] summary { pointer-events: none; list-style: none; } .opx-nav summary::-webkit-details-marker { display: none; } }
@media (max-width: 1000px) { .opx-nav details { padding: 12px 14px; border: 1px solid var(--e-line); border-radius: 14px; background: #fff; } }
.opx-nav__ch { margin: 14px 0 4px; font-weight: 700; }
.opx-nav__ch span { display: block; color: var(--e-blue); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; }
.opx-nav ol { margin: 0; padding: 0; list-style: none; }
.opx-nav a { display: flex; gap: 8px; align-items: flex-start; padding: 6px 8px; border-radius: 9px; color: var(--e-muted); text-decoration: none; line-height: 1.35; }
.opx-nav a:hover { background: var(--e-soft); color: var(--e-ink); }
.opx-nav__n { display: inline-grid; flex: none; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: #f1f2f5; color: var(--e-muted); font-size: 10.5px; font-weight: 800; }
.opx-nav .is-current a { background: var(--e-soft); color: var(--e-blue); font-weight: 600; }
.opx-nav .is-current .opx-nav__n { background: var(--e-blue); color: #fff; }
.opx-nav .is-done .opx-nav__n { background: rgba(11, 127, 85, .14); color: var(--e-green); }
.opx-nav .is-locked a, .opx-nav .is-bronze a { opacity: .7; }

/* En-tête et texte */
.opx-pill { display: inline-block; padding: 4px 11px; border-radius: 999px; background: var(--e-soft); color: var(--e-blue); font-size: 11.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.opx-pill.is-open { background: rgba(11, 127, 85, .12); color: var(--e-green); }
.opx-lp__head h1 { margin: 12px 0 8px; font-size: clamp(32px, 4.8vw, 46px); font-weight: 600; letter-spacing: -.02em; line-height: 1.1; }
.opx-lp__meta { margin: 0 0 22px; color: var(--e-muted); font-size: 14px; }
.opx-lp__in { margin: 0 0 24px; padding: 18px 22px; border-radius: 16px; background: var(--e-ink); color: rgba(254, 255, 250, .88); }
.opx-lp__in p { margin: 0 0 8px; color: var(--e-cyan); font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.opx-lp__in ul { margin: 0; padding-left: 18px; }
.opx-lp__in li { margin-bottom: 5px; }
.opx-lp__text { font-size: 17.5px; line-height: 1.75; }
.opx-lp__text p { margin: 0 0 1em; }
.opx-lp__text h2 { margin: 40px 0 14px; font-size: clamp(23px, 3.2vw, 28px); line-height: 1.2; letter-spacing: -.01em; scroll-margin-top: 90px; }
.opx-lp__text ul, .opx-lp__text ol { margin: 0 0 1.2em; padding-left: 1.3em; }
.opx-lp__text li { margin-bottom: .45em; }
.opx-lp__text li::marker { color: var(--e-blue); font-weight: 700; }
.opx-lp__text p > em:first-child { display: inline-block; margin-top: -0.4em; color: var(--e-blue); font-style: normal; font-weight: 700; }
.opx-lp__text .opx-guide__table { margin: 6px 0 1.4em; border: 1px solid var(--e-line); border-radius: 14px; overflow-x: auto; background: #fff; }
.opx-lp__text table { width: 100%; border-collapse: collapse; font-size: 15px; }
.opx-lp__text th, .opx-lp__text td { padding: 11px 14px; border-bottom: 1px solid var(--e-line); text-align: left; }
.opx-lp__text th { background: #f6f7fb; color: var(--e-muted); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; }
.opx-lp__text tr:last-child td { border-bottom: 0; }
.opx-lesson__mistake { margin: 36px 0; padding: 4px 22px 10px; border-left: 4px solid #c8323f; border-radius: 0 18px 18px 0; background: rgba(200, 50, 63, .06); }
.opx-lesson__mistake h2 { margin-top: 16px; color: #a3222d; font-size: 20px; }
.opx-check { margin: 0 0 1em !important; padding: 0 !important; list-style: none; }
.opx-check li { margin: 0 0 8px; }
.opx-check label { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--e-line); border-radius: 12px; background: #fff; cursor: pointer; transition: border-color .15s ease, background .15s ease; }
.opx-check input { flex: none; width: 20px; height: 20px; margin-top: 3px; accent-color: var(--e-green); }
.opx-check input:checked + span { color: var(--e-muted); text-decoration: line-through; text-decoration-color: rgba(11, 127, 85, .5); }
.opx-check label:has(input:checked) { border-color: rgba(11, 127, 85, .45); background: rgba(11, 127, 85, .05); }
.opx-quiz { margin: 0 0 10px; border: 1px solid var(--e-line); border-radius: 14px; background: #fff; }
.opx-quiz summary { display: flex; flex-direction: column; gap: 4px; padding: 14px 18px; font-weight: 600; cursor: pointer; list-style: none; }
.opx-quiz summary::-webkit-details-marker { display: none; }
.opx-quiz__hint { color: var(--e-blue); font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.opx-quiz[open] .opx-quiz__hint { display: none; }
.opx-quiz p { margin: 0 !important; padding: 0 18px 16px; color: var(--e-green); font-weight: 600; }
.opx-lesson__risk, .opx-lp__main .opx-eh__risk { font-size: 13px; }
.opx-lesson__risk { margin-top: 28px !important; padding: 12px 16px; border-left: 3px solid var(--e-gold); border-radius: 0 8px 8px 0; background: rgba(255, 184, 0, .08); color: var(--e-muted); }

/* Fin de leçon */
.opx-lp__done { margin: 36px 0 18px; padding: 20px; border: 1px dashed rgba(13, 54, 208, .35); border-radius: 18px; text-align: center; }
.opx-lp__done-ok { display: none; margin: 0; color: var(--e-green); font-weight: 700; }
.opx-lp__done.is-done { border-style: solid; border-color: rgba(11, 127, 85, .4); background: rgba(11, 127, 85, .05); }
.opx-lp__done.is-done > .opx-btn { display: none; }
.opx-lp__done.is-done .opx-lp__done-ok { display: inline-flex; gap: 6px; align-items: center; }
.opx-next-lesson { position: relative; display: flex; flex-direction: column; gap: 6px; overflow: hidden; margin: 18px 0; padding: 20px 22px; border-radius: 20px; background: linear-gradient(160deg, var(--e-ink), #06205e 70%, var(--e-blue) 140%); color: var(--e-ivory) !important; text-decoration: none !important; }
.opx-next-lesson__k { color: var(--e-cyan); font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.opx-next-lesson b { font-size: 21px; }
.opx-next-lesson__sum { color: rgba(254, 255, 250, .75); font-size: 14.5px; }
.opx-next-lesson.is-locked .opx-next-lesson__sum, .opx-next-lesson.is-bronze .opx-next-lesson__sum { filter: blur(4px); user-select: none; }
.opx-next-lesson__go { display: inline-flex; gap: 6px; align-items: center; align-self: flex-start; margin-top: 6px; padding: 10px 16px; border-radius: 999px; background: var(--e-ivory); color: var(--e-blue); font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }

/* Leçon fermée */
.opx-ghost { position: relative; margin: 6px 0 0; padding: 4px 0 30px; }
.opx-ghost i { display: block; height: 12px; margin: 12px 0; border-radius: 6px; background: #d9dde7; filter: blur(3px); }
.opx-ghost::after { content: ""; position: absolute; inset: auto 0 0; height: 70%; background: linear-gradient(180deg, rgba(254, 255, 250, 0), var(--e-ivory)); }
.opx-lp__sum { color: var(--e-muted); font-size: 18px; line-height: 1.6; }
.opx-unlock { position: relative; margin: -10px 0 24px; padding: 24px; border: 1px solid var(--e-line); border-radius: 20px; background: #fff; box-shadow: 0 16px 48px rgba(1, 24, 42, .1); }
.opx-unlock__k { margin: 0; color: var(--e-blue); font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.opx-unlock__t { margin: 6px 0 14px; font-size: 21px; font-weight: 600; line-height: 1.3; }
.opx-unlock ol { margin: 0 0 16px; padding: 0; list-style: none; counter-reset: s; }
.opx-unlock li { counter-increment: s; position: relative; padding: 10px 0 10px 46px; border-top: 1px solid var(--e-line); }
.opx-unlock li::before { content: counter(s); position: absolute; top: 10px; left: 0; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; background: var(--e-soft); color: var(--e-blue); font-weight: 800; }
.opx-unlock li b { display: block; }
.opx-unlock li span { color: var(--e-muted); font-size: 14px; }
.opx-unlock__a { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; }
.opx-unlock__fine { margin: 12px 0 0; color: var(--e-muted); font-size: 12px; }
.opx-soon { margin: -10px 0 24px; padding: 20px 22px; border-radius: 18px; background: var(--e-soft); }
.opx-soon b { color: var(--e-blue); font-size: 13px; letter-spacing: .1em; text-transform: uppercase; }
.opx-soon p { margin: 6px 0 0; }

/* ── Fenêtre de déblocage ── */
.opx-gate { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 16px; background: rgba(1, 24, 42, .6); backdrop-filter: blur(3px); }
.opx-gate[hidden] { display: none; }
.opx-gate__box { position: relative; width: min(540px, 100%); max-height: calc(100vh - 32px); overflow: auto; padding: 28px; border-radius: 22px; background: #fff; box-shadow: 0 30px 80px rgba(1, 24, 42, .35); animation: opx-pop .2s ease; }
@keyframes opx-pop { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .opx-gate__box { animation: none; } .opx-btn, .opx-lc { transition: none; } }
.opx-gate__x { position: absolute; top: 12px; right: 14px; width: 36px; height: 36px; border: 0; border-radius: 50%; background: #f1f2f5; color: var(--e-ink); font-size: 22px; line-height: 1; cursor: pointer; }
.opx-gate h2 { margin: 6px 0 6px; font-size: 25px; }
.opx-gate__lead { margin: 0 0 16px; color: var(--e-muted); }
.opx-gate__step { display: flex; gap: 14px; margin-bottom: 12px; padding: 16px; border: 1px solid var(--e-line); border-radius: 16px; }
.opx-gate__step > span { display: grid; flex: none; place-items: center; width: 32px; height: 32px; border-radius: 10px; background: var(--e-soft); color: var(--e-blue); font-weight: 800; }
.opx-gate__step > div { flex: 1; min-width: 0; }
.opx-gate__step b { display: block; margin-bottom: 2px; }
.opx-gate__step p { margin: 0 0 10px; color: var(--e-muted); font-size: 14px; }
.opx-gate__step.is-focus { border-color: var(--e-blue); box-shadow: 0 0 0 3px rgba(13, 54, 208, .1); }
.opx-gate__fine { margin: 6px 0 0; color: var(--e-muted); font-size: 12px; }
.opx-gate__soon { margin: 0; color: var(--e-muted); }
/* Formulaire de connexion Pocket dans la fenêtre */
.opx-gate .opx-po { margin: 4px 0 0; padding: 0; border: 0; background: none; }
.opx-gate .opx-po h3 { display: none; }
.opx-gate .opx-po__form { display: grid; gap: 6px; }
.opx-gate .opx-po__form label { font-size: 13px; font-weight: 600; }
.opx-gate .opx-po__form input { width: 100%; padding: 11px 14px; border: 1px solid var(--e-line); border-radius: 12px; font: inherit; font-size: 15px; }
.opx-gate .opx-po__form input:focus { outline: 2px solid rgba(13, 54, 208, .35); border-color: var(--e-blue); }
.opx-gate .opx-po__form button { justify-self: start; margin-top: 8px; padding: 12px 22px; border: 0; border-radius: 999px; background: var(--e-blue); color: #fff; font: inherit; font-size: 13px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; }
.opx-gate .opx-po__msg { margin: 0 0 8px; padding: 10px 12px; border-radius: 10px; background: var(--e-soft); font-size: 14px; }
.opx-gate .opx-po__msg.is-error { background: rgba(200, 50, 63, .08); color: #a3222d; }
.opx-gate .opx-po__note, .opx-gate .opx-po__signup { margin: 8px 0 0; color: var(--e-muted); font-size: 12px; }

/* ── Blocs de leçon (dev/lesson-to-html.py) ── */
.opx-lesson__part { scroll-margin-top: 80px; }
/* Sommaire de la leçon en cours, suivi à la lecture */
.opx-nav__toc { margin: 2px 0 8px 18px !important; padding: 0 0 0 12px !important; border-left: 2px solid var(--e-line); }
.opx-nav .is-current .opx-nav__toc a { display: block; padding: 4px 8px; border-radius: 7px; background: none; color: var(--e-muted); font-size: 12.5px; font-weight: 400; }
.opx-nav .is-current .opx-nav__toc a:hover { color: var(--e-ink); }
.opx-nav .is-current .opx-nav__toc a.is-active { color: var(--e-blue); font-weight: 600; }

/* Mots du glossaire : définition au survol (bas d'écran sur mobile) */
.opx-term { position: relative; border-bottom: 1.5px dotted var(--e-blue); cursor: help; outline: none; }
.opx-term:focus-visible { border-radius: 3px; box-shadow: 0 0 0 2px rgba(13, 54, 208, .25); }
.opx-term::after { content: attr(data-def); position: absolute; bottom: calc(100% + 8px); left: 50%; z-index: 20; width: 280px; padding: 10px 12px; border-radius: 12px; background: var(--e-ink); color: var(--e-ivory); font-size: 13.5px; font-weight: 400; line-height: 1.45; text-align: left; box-shadow: 0 12px 30px rgba(1, 24, 42, .25); opacity: 0; pointer-events: none; transform: translate(-50%, 4px); transition: opacity .15s ease, transform .15s ease; }
.opx-term:hover::after, .opx-term:focus::after { opacity: 1; transform: translate(-50%, 0); }
@media (max-width: 700px) { .opx-term::after { position: fixed; top: auto; right: 16px; bottom: 16px; left: 16px; width: auto; transform: translateY(6px); } .opx-term:hover::after, .opx-term:focus::after { transform: none; } }

/* Carte définition */
.opx-lp__text .opx-def { margin: 4px 0 1.4em; padding: 14px 18px; border-left: 4px solid var(--e-blue); border-radius: 0 14px 14px 0; background: var(--e-soft); font-size: 16px; line-height: 1.6; }
.opx-lp__text .opx-def__term { margin: 0 0 2px; color: var(--e-blue); font-size: 11.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.opx-lp__text .opx-def__text { margin: 0; }

/* Étapes numérotées */
.opx-lp__text .opx-steps { margin: 18px 0 1.4em; padding: 0; list-style: none; }
.opx-lp__text .opx-steps > li { position: relative; display: flex; gap: 16px; margin: 0; padding: 0 0 22px; }
.opx-steps > li::before { content: ""; position: absolute; top: 40px; bottom: 4px; left: 17px; width: 2px; background: var(--e-line); }
.opx-lp__text .opx-steps > li:last-child { padding-bottom: 0; }
.opx-steps > li:last-child::before { display: none; }
.opx-steps__n { display: grid; flex: none; place-items: center; width: 36px; height: 36px; border-radius: 12px; background: var(--e-ink); color: var(--e-cyan); font-size: 15px; font-weight: 800; }
.opx-steps > li > div { flex: 1; min-width: 0; padding: 14px 18px; border: 1px solid var(--e-line); border-radius: 16px; background: #fff; }
.opx-lp__text .opx-steps h3 { margin: 0 0 6px; font-size: 19px; line-height: 1.3; }
.opx-lp__text .opx-steps p { margin: 0 0 .7em; font-size: 16.5px; line-height: 1.65; }
.opx-lp__text .opx-steps .opx-steps__check { margin: 0; padding: 10px 12px; border-radius: 10px; background: #f6f7fb; font-size: 15px; }
.opx-steps__check b { display: block; color: var(--e-blue); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; }
@media (max-width: 560px) { .opx-lp__text .opx-steps > li { display: block; padding-bottom: 12px; } .opx-steps > li::before { display: none; } .opx-steps__n { position: absolute; top: 13px; left: 14px; width: 28px; height: 28px; border-radius: 9px; font-size: 13px; } .opx-steps > li > div { padding: 14px; } .opx-lp__text .opx-steps h3 { min-height: 28px; margin-left: 38px; line-height: 28px; } }

/* Frise en trois temps */
.opx-lp__text .opx-flow { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 8px 0 1.4em; padding: 0; list-style: none; }
.opx-lp__text .opx-flow li { position: relative; display: flex; flex-direction: column; gap: 3px; margin: 0; padding: 14px 16px; border: 1px solid var(--e-line); border-radius: 16px; background: #fff; font-size: 14.5px; line-height: 1.45; }
.opx-flow li:last-child { border-color: var(--e-ink) !important; background: var(--e-ink) !important; color: var(--e-ivory); }
.opx-flow li:not(:last-child)::after { content: "→"; position: absolute; top: 50%; right: -12px; z-index: 1; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--e-ivory); color: var(--e-blue); font-weight: 800; transform: translateY(-50%); }
.opx-flow small { color: var(--e-blue); font-size: 11px; font-weight: 800; letter-spacing: .1em; }
.opx-flow li:last-child small { color: var(--e-cyan); }
.opx-flow b { font-size: 16px; }
.opx-flow span { color: var(--e-muted); }
.opx-flow li:last-child span { color: rgba(254, 255, 250, .78); }
@media (max-width: 640px) { .opx-lp__text .opx-flow { grid-template-columns: 1fr; } .opx-flow li:not(:last-child)::after { content: "↓"; top: auto; right: 50%; bottom: -16px; transform: translateX(50%); } }

/* Résultats dans les tableaux */
.opx-lp__text td.is-pos strong { color: var(--e-green); }
.opx-lp__text td.is-neg strong { color: #b3262f; }

/* Cartes comparées */
.opx-lp__text .opx-cmp { margin: 8px 0 1.4em; }
.opx-cmp figcaption { margin-bottom: 8px; color: var(--e-muted); font-size: 13px; font-weight: 600; }
.opx-cmp__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .opx-cmp__grid { grid-template-columns: 1fr; } }
.opx-cmp__card { padding: 16px 18px; border: 1px solid var(--e-line); border-radius: 18px; background: #fff; }
.opx-cmp__card.is-pos { border-color: rgba(11, 127, 85, .35); }
.opx-cmp__card.is-neg { border-color: rgba(179, 38, 47, .3); }
.opx-lp__text .opx-cmp__label { margin: 0; color: var(--e-muted); font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.opx-lp__text .opx-cmp__total { margin: 2px 0 10px; font-size: 34px; font-weight: 700; letter-spacing: -.02em; line-height: 1.1; }
.opx-cmp__card.is-pos .opx-cmp__total { color: var(--e-green); }
.opx-cmp__card.is-neg .opx-cmp__total { color: #b3262f; }
.opx-cmp__bar { display: block; margin-top: 8px; font-size: 13px; line-height: 1.4; }
.opx-cmp__bar i { display: block; height: 8px; margin-bottom: 3px; border-radius: 4px; }
.opx-cmp__bar.is-g i { background: linear-gradient(90deg, var(--e-blue), var(--e-cyan)); }
.opx-cmp__bar.is-l i { background: #cfd4df; }
.opx-cmp__bar em { color: var(--e-muted); font-style: normal; }

/* Calculateurs */
.opx-calc { margin: 10px 0 1.6em; padding: 20px 22px; border-radius: 20px; background: linear-gradient(160deg, var(--e-ink), #06205e 80%); color: var(--e-ivory); box-shadow: 0 16px 40px rgba(1, 24, 42, .18); }
.opx-lp__text .opx-calc p { margin: 0; }
.opx-lp__text .opx-calc__k { color: var(--e-cyan); font-size: 11.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.opx-lp__text .opx-calc__t { margin: 2px 0 14px; font-size: 21px; font-weight: 600; line-height: 1.3; }
.opx-calc__in { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; margin-bottom: 14px; }
@media (max-width: 560px) { .opx-calc__in { grid-template-columns: 1fr; } .opx-calc { padding: 18px 16px; } }
.opx-calc label { display: flex; flex-direction: column; gap: 8px; font-size: 14px; }
.opx-calc label > span:first-child { display: flex; justify-content: space-between; color: rgba(254, 255, 250, .8); }
.opx-calc output { color: var(--e-ivory); font-weight: 700; }
.opx-calc input[type=range] { width: 100%; accent-color: var(--e-cyan); }
.opx-calc__money { display: flex; align-items: center; border: 1px solid rgba(254, 255, 250, .25); border-radius: 12px; background: rgba(254, 255, 250, .06); }
.opx-calc__money i { padding-left: 12px; color: rgba(254, 255, 250, .6); font-style: normal; }
.opx-calc__money input { width: 100%; padding: 9px 12px 9px 6px; border: 0; background: none; color: var(--e-ivory); font: inherit; font-size: 17px; font-weight: 600; outline: none; }
.opx-calc__money:focus-within { border-color: var(--e-cyan); }
.opx-calc__out { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.opx-calc__out--one { grid-template-columns: 1fr; }
.opx-calc__out > div { display: flex; flex-direction: column; padding: 12px 14px; border-radius: 14px; background: rgba(254, 255, 250, .07); }
.opx-calc__out small { color: rgba(254, 255, 250, .7); font-size: 12px; }
.opx-calc__out b { font-size: 28px; letter-spacing: -.01em; }
.opx-calc__out .is-pos b { color: #4be3a6; }
.opx-calc__out .is-neg b { color: #ff8a93; }
.opx-calc__out span { color: rgba(254, 255, 250, .7); font-size: 13px; }
.opx-calc__line { position: relative; height: 10px; margin: 18px 0 10px; border-radius: 5px; background: linear-gradient(90deg, rgba(255, 138, 147, .35), rgba(75, 227, 166, .35)); }
.opx-calc__line span { position: absolute; top: 50%; transition: left .2s ease; }
.opx-calc__be { width: 3px; height: 24px; margin-left: -1px; border-radius: 2px; background: var(--e-gold); transform: translateY(-50%); }
.opx-calc__you { width: 18px; height: 18px; margin-left: -9px; border: 3px solid #06205e; border-radius: 50%; background: var(--e-cyan); transform: translateY(-50%); }
.opx-lp__text .opx-calc__legend { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; color: rgba(254, 255, 250, .8); }
.opx-calc__legend i { display: inline-block; width: 10px; height: 10px; margin-right: 6px; border-radius: 50%; vertical-align: -1px; }
.opx-calc__legend i.is-you { background: var(--e-cyan); }
.opx-calc__legend i.is-be { width: 3px; border-radius: 1px; background: var(--e-gold); }
.opx-lp__text .opx-calc__fine { margin-top: 10px; color: rgba(254, 255, 250, .55); font-size: 12px; line-height: 1.5; }

/* Carte outil du site */
.opx-tool { display: flex; flex-direction: column; gap: 2px; margin: 0 0 1.4em; padding: 14px 18px; border: 1px solid var(--e-line); border-radius: 16px; background: #fff; color: var(--e-ink) !important; text-decoration: none !important; transition: border-color .15s ease, transform .15s ease; }
.opx-tool:hover { border-color: var(--e-blue); transform: translateY(-1px); }
.opx-tool__k { color: var(--e-green); font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.opx-tool b { font-size: 17px; }
.opx-tool__d { color: var(--e-muted); font-size: 14.5px; line-height: 1.5; }
.opx-tool__go { margin-top: 4px; color: var(--e-blue); font-size: 13px; font-weight: 700; }

/* Encadrés : notre règle, bon à savoir (l'erreur fréquente reste en rouge) */
.opx-callout { margin: 4px 0 1.4em; padding: 14px 18px; border-radius: 16px; font-size: 16.5px; line-height: 1.6; }
.opx-lp__text .opx-callout p { margin: 0; }
.opx-lp__text .opx-callout .opx-callout__k { margin-bottom: 4px; font-size: 11.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.opx-callout.is-rule { border: 1px solid rgba(13, 54, 208, .25); background: var(--e-soft); }
.opx-callout.is-rule .opx-callout__k { color: var(--e-blue); }
.opx-callout.is-rule p:last-child { font-weight: 600; }
.opx-callout.is-tip { border: 1px solid var(--e-line); background: #f6f7f9; }
.opx-callout.is-tip .opx-callout__k { color: var(--e-muted); }

/* À retenir */
.opx-lesson__recap { margin: 36px 0; padding: 6px 24px 18px; border-radius: 20px; background: var(--e-ink); color: var(--e-ivory); }
.opx-lp__text .opx-lesson__recap h2 { margin-top: 18px; color: var(--e-ivory); font-size: 20px; }
.opx-lp__text .opx-lesson__recap ul { margin: 0; padding: 0; list-style: none; counter-reset: r; }
.opx-lp__text .opx-lesson__recap li { counter-increment: r; position: relative; margin: 0 0 10px; padding-left: 40px; color: rgba(254, 255, 250, .9); }
.opx-lesson__recap li::before { content: counter(r); position: absolute; top: 2px; left: 0; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; background: rgba(31, 205, 255, .16); color: var(--e-cyan); font-size: 13px; font-weight: 800; }
.opx-lesson__recap .opx-term { border-bottom-color: var(--e-cyan); }

/* Exercice sur compte démo */
.opx-ex { margin: 18px 0 1.4em; padding: 18px 20px; border: 1px dashed rgba(13, 54, 208, .4); border-radius: 18px; background: #fff; }
.opx-lp__text .opx-ex p { margin: 0 0 8px; font-size: 16px; line-height: 1.6; }
.opx-lp__text .opx-ex .opx-ex__k { margin: 0; color: var(--e-green); font-size: 11.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.opx-lp__text .opx-ex .opx-ex__t { margin: 2px 0 6px; font-size: 19px; font-weight: 600; }
.opx-ex__dots { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 8px; }
.opx-ex__dots button { display: inline-flex; gap: 6px; align-items: center; padding: 8px 12px; border: 1px solid var(--e-line); border-radius: 999px; background: #fff; color: var(--e-muted); font: inherit; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.opx-ex__dots button svg { opacity: .25; }
.opx-ex__dots button[aria-pressed=true] { border-color: rgba(11, 127, 85, .45); background: rgba(11, 127, 85, .08); color: var(--e-green); }
.opx-ex__dots button[aria-pressed=true] svg { opacity: 1; }
.opx-lp__text .opx-ex .opx-ex__count { margin: 0; color: var(--e-muted); font-size: 13.5px; }
.opx-ex.is-done { border-style: solid; border-color: rgba(11, 127, 85, .45); background: rgba(11, 127, 85, .04); }

/* Quiz à choix */
.opx-q { margin: 0 0 12px; padding: 16px 18px; border: 1px solid var(--e-line); border-radius: 16px; background: #fff; }
.opx-lp__text .opx-q__t { margin: 0 0 10px; font-size: 16.5px; font-weight: 600; line-height: 1.45; }
.opx-q__opts { display: grid; gap: 8px; }
.opx-q__opt { display: flex; align-items: center; gap: 10px; width: 100%; padding: 11px 14px; border: 1px solid var(--e-line); border-radius: 12px; background: #fff; color: var(--e-ink); font: inherit; font-size: 15.5px; line-height: 1.4; text-align: left; cursor: pointer; transition: border-color .15s ease, background .15s ease; }
.opx-q__opt::before { content: ""; display: grid; flex: none; place-items: center; width: 20px; height: 20px; border: 2px solid #c5cad6; border-radius: 50%; }
.opx-q__opt:hover:not(:disabled) { border-color: var(--e-blue); background: var(--e-soft); }
.opx-q__opt:disabled { cursor: default; }
.opx-q__opt.is-right { border-color: rgba(11, 127, 85, .5); background: rgba(11, 127, 85, .07); color: var(--e-green); font-weight: 600; }
.opx-q__opt.is-right::before { content: "✓"; border-color: var(--e-green); background: var(--e-green); color: #fff; font-size: 11px; font-weight: 800; }
.opx-q__opt.is-wrong { border-color: rgba(179, 38, 47, .45); background: rgba(179, 38, 47, .06); color: #b3262f; }
.opx-q__opt.is-wrong::before { content: "×"; border-color: #b3262f; background: #b3262f; color: #fff; font-size: 14px; font-weight: 800; line-height: 1; }
.opx-q__opt.is-dim { opacity: .55; }
.opx-lp__text .opx-q__why { margin: 10px 0 0; padding: 10px 12px; border-radius: 10px; background: #f6f7fb; font-size: 15px; line-height: 1.55; }
.opx-lp__text .opx-q__score { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin: 4px 0 0; padding: 14px 18px; border-radius: 16px; background: var(--e-soft); font-weight: 600; }
.opx-lp__text .opx-q__score[hidden], .opx-lp__text .opx-q__why[hidden] { display: none; }
.opx-q__score button { padding: 0; border: 0; background: none; color: var(--e-blue); font: inherit; font-size: 13px; font-weight: 700; text-decoration: underline; cursor: pointer; }

/* Fin de leçon, visiteur : la suite à un compte gratuit */
.opx-lp__done-more { display: none; margin-top: 14px; padding-top: 16px; border-top: 1px solid rgba(11, 127, 85, .2); }
.opx-lp__done.is-done .opx-lp__done-more { display: block; animation: opx-pop .25s ease; }
.opx-lp__done-more p { margin: 0 0 6px; }
.opx-lp__done-more .opx-lp__done-big { font-size: 22px; }
.opx-lp__done-big b { color: var(--e-blue); }
.opx-lp__done-more .opx-unlock__a { justify-content: center; margin-top: 12px; }
@media (prefers-reduced-motion: reduce) { .opx-term::after, .opx-calc__line span, .opx-tool { transition: none; } .opx-lp__done.is-done .opx-lp__done-more { animation: none; } }

/* Le bon réflexe (remplace « l'erreur fréquente ») */
.opx-lesson__habit { margin: 36px 0; padding: 4px 22px 10px; border-left: 4px solid var(--e-green); border-radius: 0 18px 18px 0; background: rgba(11, 127, 85, .06); }
.opx-lp__text .opx-lesson__habit h2 { margin-top: 16px; color: var(--e-green); font-size: 20px; }

/* Ce que vous y gagnez */
.opx-lp__text .opx-gains { display: grid; gap: 10px; margin: 6px 0 1.4em; padding: 0; list-style: none; }
.opx-lp__text .opx-gains li { display: flex; gap: 14px; align-items: flex-start; margin: 0; padding: 14px 16px; border: 1px solid rgba(11, 127, 85, .28); border-radius: 16px; background: #fff; }
.opx-gains__ic { display: grid; flex: none; place-items: center; width: 30px; height: 30px; border-radius: 10px; background: rgba(11, 127, 85, .12); color: var(--e-green); }
.opx-gains li div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.opx-gains li b { font-size: 16px; line-height: 1.4; }
.opx-gains li div > span { color: var(--e-muted); font-size: 15.5px; line-height: 1.55; }
