/* Leçons animées d'électronique de puissance (lecteur EPPlayer) */
.lecteur.ep{aspect-ratio:auto;background:#fff;overflow:auto;border:1px solid #dfe5ec}
.lecteur.ep:fullscreen{padding:14px;background:#fff}
.ep{--panel:#ffffff;--ink:#15222d;--mut:#5c6a77;--grid:#d3dae1;--accent:#E36C0A;--accent-soft:#fde9d9;
  --c1:#1c64d1;--c2:#d6336c;--c3:#2b8a3e;--cu:#E36C0A;--ci:#0b7285;--cd:#6741d9;--cg:#946c00;
  color:var(--ink);padding:12px 14px 10px;text-align:left}
.ep-top{display:flex;flex-direction:column;gap:2px;margin-bottom:6px}
.ep-count{font-size:.72rem;letter-spacing:.08em;text-transform:uppercase;color:var(--mut)}
.ep-title{margin:0;font-size:1.15rem;color:#1F4E79;text-wrap:balance}
.ep-stage{display:grid;grid-template-columns:minmax(260px,5fr) minmax(0,7fr);gap:14px;align-items:start}
.ep-col{min-width:0;display:flex;flex-direction:column;gap:6px}
.ep-svg{display:block;width:100%;height:auto;max-height:320px}
.ep-svg .w{fill:none;stroke:var(--ink);stroke-width:1.6;stroke-linejoin:round}
.ep-svg .dot{fill:var(--ink)}
.ep-svg text{font-size:12.5px;fill:var(--ink)}
.ep-svg text.mid{text-anchor:middle}.ep-svg text.sm{font-size:11px;fill:var(--mut)}.ep-svg text.lab{font-style:italic;fill:var(--mut)}
.ep-svg tspan.sub{font-size:9px}
.ep-svg .shape{fill:var(--panel);stroke:var(--ink);stroke-width:1.6;stroke-linejoin:round}
.ep-svg .bar{stroke:var(--ink);stroke-width:2.2}.ep-svg .bar.thick{stroke-width:4.5}
.ep-svg .cmp{fill:var(--panel);stroke:var(--ink);stroke-width:1.6}
.ep-svg .bgr{fill:var(--panel);stroke:none}
.ep-svg .coil{fill:none;stroke:var(--ink);stroke-width:1.8}
.ep-svg .node{fill:var(--ink)}
.ep-svg .arm{stroke:var(--ink);stroke-width:2.4;stroke-linecap:round}
.ep-svg .sw .arm.closed{display:none}.ep-svg .sw.on .arm.closed{display:inline;stroke:var(--accent)}.ep-svg .sw.on .arm.open{display:none}
.ep-svg .dev.on .shape{fill:var(--accent)}
.ep-svg .dev.on>text{fill:var(--accent);font-weight:600}
.ep-svg .blk.on .shape{fill:var(--accent-soft);stroke:var(--accent)}
.ep-svg .blk.on>text{fill:var(--ink)}
.ep-cur{fill:none;stroke:var(--accent);stroke-width:4.5;stroke-opacity:.8;stroke-dasharray:9 9;stroke-linecap:round;stroke-linejoin:round;pointer-events:none;animation:ep-flow .5s linear infinite;animation-play-state:paused}
.ep-joue .ep-cur{animation-play-state:running}
@keyframes ep-flow{from{stroke-dashoffset:18}to{stroke-dashoffset:0}}
.ep-legend{display:flex;gap:14px;flex-wrap:wrap;font-size:.75rem;color:var(--mut)}
.ep-legend i{display:inline-block;width:18px;height:4px;border-radius:2px;background:var(--accent);margin-right:5px;vertical-align:middle}
.ep-legend b{display:inline-block;width:10px;height:10px;background:var(--accent);margin-right:5px;vertical-align:-1px}
.ep-formulas{margin:4px 0 0;padding:0}
.ep-frow{display:grid;grid-template-columns:minmax(84px,31%) 1fr;gap:10px;align-items:center;padding:6px 0;border-top:1px solid var(--grid)}
.ep-frow dt{color:var(--mut);font-size:.82rem}
.ep-frow dd{margin:0;font-size:.93rem;overflow-x:auto;min-width:0}
.ep .fr{display:inline-flex;flex-direction:column;vertical-align:middle;text-align:center;margin:0 3px;font-size:.92em;line-height:1.15}
.ep .fr>span:first-child{border-bottom:1.3px solid currentColor;padding:0 4px 1px}
.ep .fr>span:last-child{padding:1px 4px 0}
.ep .sq{white-space:nowrap}.ep .sq>span{border-top:1.3px solid currentColor;padding:0 2px;display:inline-block}
.ep-note{margin:4px 0 0;font-size:.8rem;color:var(--mut);border-left:3px solid var(--cg);padding-left:8px}
.ep-plot{position:relative;height:440px;touch-action:pan-y;cursor:ew-resize}
.lecteur.ep canvas.ep-cv{position:absolute;inset:0;width:100%;height:100%;background:transparent;object-fit:fill}
.ep-chips{display:flex;flex-wrap:wrap;gap:6px;min-height:30px}
.ep-chip{font-family:ui-monospace,Consolas,monospace;font-size:.8rem;border:1px solid var(--grid);border-radius:999px;padding:3px 10px;font-variant-numeric:tabular-nums}
.ep-chip b{font-family:inherit;font-weight:500;color:var(--mut);margin-right:7px}
.ep-ctrls{display:flex;flex-direction:column;gap:6px;border-top:1px solid var(--grid);padding-top:8px}
.ep-ctl{display:grid;grid-template-columns:minmax(0,auto) minmax(120px,1fr) 52px;gap:12px;align-items:center;margin:0;color:var(--ink);font-size:.85rem;font-weight:600}
.ep-ctl output{font-family:ui-monospace,Consolas,monospace;text-align:right;font-weight:400}
.ep-ctl input[type=range]{padding:0;border:0;accent-color:var(--accent)}
@media (max-width:760px){.ep-stage{grid-template-columns:minmax(0,1fr)}.ep-plot{height:400px}.ep-ctl{grid-template-columns:1fr 52px}.ep-ctl span{grid-column:1/-1}}
@media (prefers-reduced-motion:reduce){.ep-cur{animation:none}}
.ep-ctrls[hidden],.ep-note[hidden]{display:none}
.ep-frow{transition:opacity .4s}.ep-frow.cache{opacity:.12}
.ep-3d{position:relative;height:330px;border-radius:10px;overflow:hidden;background:radial-gradient(ellipse at 50% 35%,#f4f8fb 0%,#dfe8ef 100%);border:1px solid var(--grid)}
.ep-3d canvas,.ca-3d canvas{display:block;width:100%;height:100%;touch-action:none;cursor:grab}
.ep-3d canvas:active,.ca-3d canvas:active{cursor:grabbing}
.s3d-bar{position:absolute;left:8px;right:8px;bottom:6px;display:flex;justify-content:space-between;align-items:center;gap:8px;pointer-events:none}
.s3d-aide{font-size:11px;color:#5c6a77;background:rgba(255,255,255,.75);padding:2px 7px;border-radius:6px}
.s3d-re,.ep-v3d,.ca-v3d{pointer-events:auto;font:600 12px Inter,system-ui,sans-serif;border:1px solid #c5ced7;background:#fff;color:#1F4E79;border-radius:7px;padding:4px 10px;cursor:pointer}
.ep-v3d{margin-left:auto}
@media (max-width:760px){.ep-3d{height:280px}.s3d-aide{display:none}}
.lecteur .ep-3d canvas,.lecteur .ca-3d canvas{background:transparent;aspect-ratio:auto;object-fit:fill;max-height:none}
