/* Scoped teaching figures: site palette, readable HTML labels, static print. */
.hfir-figure{margin:8px 0;padding:8px;border:1px solid var(--rule);background:var(--paper)}
.hfir-figure img{display:block;width:100%;max-height:190px;object-fit:contain;margin:0 auto}
.hfir-figure figcaption{font-size:8pt;line-height:1.4;margin-top:5px;color:var(--ink)}
.hfir-figure a{color:var(--guide-red)}
.hfir-pair{display:grid;grid-template-columns:1fr 1fr;gap:10px;align-items:start}
.hfir-pair p{margin:4px 0;font-size:9pt;line-height:1.45}
.hfir-flow{display:grid;gap:6px;margin:6px 0}
.hfir-flow>div{border-left:3px solid var(--guide-red);padding:5px 8px;background:var(--paper-warm);font-size:9pt;line-height:1.4}
.hfir-motion svg{display:block;width:100%;max-height:210px;color:var(--ink)}
.hfir-motion .hfir-fire{fill:var(--guide-red);opacity:1}
.hfir-motion .hfir-scar{fill:var(--ink);stroke:var(--paper);stroke-width:2}
.hfir-motion [data-hfir-arrow]{stroke:var(--guide-red);stroke-width:4;fill:none}
.hfir-controls{display:flex;flex-wrap:wrap;gap:8px;margin-top:7px}
.hfir-controls button{font:inherit;border:1px solid var(--rule);background:var(--paper);color:var(--ink);padding:6px 10px;cursor:pointer;min-height:36px}
.hfir-controls button:focus-visible{outline:3px solid var(--guide-red);outline-offset:2px}
.hfir-status{font-size:9pt;font-weight:700;margin:5px 0}
.hfir-static-note{font-size:8pt;line-height:1.4}
@media(max-width:600px){.hfir-pair{grid-template-columns:1fr}.hfir-pair p,.hfir-flow>div,.hfir-status{font-size:14px}.hfir-figure figcaption,.hfir-static-note{font-size:12px}.hfir-motion svg{max-height:none}}
@media print{.hfir-controls{display:none}.hfir-motion .hfir-fire{opacity:.25!important}.hfir-motion [data-hfir-arrow]{stroke-dashoffset:0!important}.hfir-figure{break-inside:avoid}.hfir-status{display:none}.hfir-pair{grid-template-columns:1fr 1fr}.hfir-figure img{max-height:150px}}

/* Room for readable screen labels without changing compact PDF cards. */
@media screen {
  body[data-guide-id="cardiac-sarcoidosis"] .emg .ec-b .er{grid-template-columns:90px minmax(0,1fr)!important}
}
@media screen and (max-width:600px) {
  body[data-guide-id="cardiac-sarcoidosis"] .emg .ec-b .er{grid-template-columns:minmax(0,1fr)!important;gap:2px}
}
