/* =========================================================
   MEDFOCO • ATLAS DE OFTALMOLOGIA — CSS DOS ARTIGOS
   Vale para todos os artigos (modelos "completo" e "compacto").
   Escopo: .mfoa (página) e .mfoa-modal (popups, criados no <body>).
   Identidade: hero verde-azulado do atlas (#0d9488 → #0f766e → #115e59),
   títulos azul-marinho (#163256), abas e lateral no padrão dos artigos antigos.
   ========================================================= */

.mfoa,
.mfoa-modal {
  --mfoa-pri: #0d9488;
  --mfoa-pri-l: #e8f7f5;
  --mfoa-pri-b: #b9e6df;
  --mfoa-pri-d: #0f766e;
  --mfoa-pri-dd: #115e59;
  --mfoa-pri-s: #5eead4;
  --mfoa-navy: #2b4c7e;
  --mfoa-navy-l: #eef4fb;
  --mfoa-head: #163256;
  --mfoa-body: #3f4b5b;
  --mfoa-muted: #6b7280;
  --mfoa-bg: #fff;
  --mfoa-bg-s: #f8fafc;
  --mfoa-border: #dce6f2;
  --mfoa-border-l: #e8eef6;

  --mfoa-ok: #0f8f5f;      --mfoa-ok-bg: #e9f8f0;      --mfoa-ok-b: #bfe8d3;
  --mfoa-alt: #1f6fb2;     --mfoa-alt-bg: #eaf3fc;     --mfoa-alt-b: #c4dcf3;
  --mfoa-warn: #a86800;    --mfoa-warn-bg: #fff7e6;    --mfoa-warn-b: #f5dcaa;
  --mfoa-dang: #c0392b;    --mfoa-dang-bg: #fdeeee;    --mfoa-dang-b: #f4c5c0;
  --mfoa-prova: #6b47c2;   --mfoa-prova-bg: #f3effc;   --mfoa-prova-b: #dccff6;

  --mfoa-r: 20px;
  --mfoa-r-s: 12px;
  --mfoa-sh: 0 8px 30px rgba(43, 76, 126, .07);
  --mfoa-sh-h: 0 2px 4px rgba(43, 76, 126, .06), 0 14px 32px rgba(43, 76, 126, .13);

  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--mfoa-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  box-sizing: border-box;
}
.mfoa { width: 100%; max-width: 1400px; margin: 0 auto; }

.mfoa *, .mfoa *::before, .mfoa *::after,
.mfoa-modal *, .mfoa-modal *::before, .mfoa-modal *::after { box-sizing: border-box; }

/* Reset de controles (o Astra estiliza button/input globalmente) */
.mfoa button, .mfoa-modal button {
  font-family: inherit; font-size: inherit; line-height: 1.3; color: inherit;
  background: none; border: 0; border-radius: 0; padding: 0; margin: 0;
  box-shadow: none; text-transform: none; letter-spacing: normal; cursor: pointer;
  touch-action: manipulation;
}
.mfoa button:focus-visible, .mfoa-modal button:focus-visible,
.mfoa summary:focus-visible { outline: 3px solid var(--mfoa-pri-s); outline-offset: 2px; }

.mfoa h1, .mfoa h2, .mfoa h3, .mfoa h4,
.mfoa-modal h2, .mfoa-modal h3, .mfoa-modal h4 {
  font-family: inherit; color: var(--mfoa-head); margin: 0; line-height: 1.25; letter-spacing: -.01em;
}
.mfoa p, .mfoa-modal p { margin: 0 0 .75em; }
.mfoa p:last-child, .mfoa-modal p:last-child { margin-bottom: 0; }
.mfoa a { color: var(--mfoa-pri-d); }
.mfoa strong, .mfoa b, .mfoa em,
.mfoa-modal strong, .mfoa-modal b, .mfoa-modal em { display: inline; }
.mfoa strong, .mfoa-modal strong { color: var(--mfoa-head); font-weight: 700; }
.mfoa code, .mfoa-modal code { font-size: .85em; background: #eef3f8; padding: 1px 5px; border-radius: 4px; }

/* =========================================================
   BREADCRUMBS + HERO
   ========================================================= */
.mfoa-bc {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px;
  font-size: 13px; color: var(--mfoa-muted); padding: 4px 0 14px;
}
.mfoa-bc a { color: var(--mfoa-muted); text-decoration: none; }
.mfoa-bc a:hover { color: var(--mfoa-pri); }
.mfoa-bc i { font-size: 9px; opacity: .6; }
.mfoa-bc strong { color: var(--mfoa-head); font-weight: 600; }

.mfoa-hero {
  position: relative; overflow: hidden; border-radius: 22px; color: #fff; padding: 34px 32px 30px;
  background: linear-gradient(135deg, #0d9488 0%, #0f766e 52%, #115e59 100%);
  box-shadow: 0 14px 40px rgba(13, 40, 46, .18);
}
.mfoa-hero::before {
  content: ""; position: absolute; top: -90px; right: -80px; width: 300px; height: 300px; border-radius: 50%;
  background: radial-gradient(circle, rgba(94, 234, 212, .30), transparent 70%); pointer-events: none;
}
.mfoa-hero::after {
  content: ""; position: absolute; left: -100px; bottom: -120px; width: 320px; height: 320px; border-radius: 50%;
  background: radial-gradient(circle, rgba(15, 118, 110, .45), transparent 70%); pointer-events: none;
}
.mfoa-hero-in { position: relative; z-index: 1; max-width: 860px; }
.mfoa-compacto .mfoa-hero-in { max-width: none; }
.mfoa-hero-tag {
  display: inline-flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase;
  background: rgba(255,255,255,.13); border: 1px solid rgba(255,255,255,.22); padding: 6px 14px; border-radius: 999px;
}
.mfoa-hero-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--mfoa-pri-s); animation: mfoa-pulso 1.4s infinite; }
@keyframes mfoa-pulso { 0%, 100% { opacity: 1; transform: scale(1); } 50% { opacity: .5; transform: scale(1.4); } }
@media (prefers-reduced-motion: reduce) { .mfoa-hero-dot { animation: none; } }
.mfoa .mfoa-hero h1 { color: #fff; font-size: clamp(30px, 5vw, 46px); font-weight: 800; letter-spacing: -1px; line-height: 1.06; margin: 14px 0 6px; }
.mfoa-hero-alt { font-size: 14.5px; color: #c9f5ee; margin: 0 0 6px; }
.mfoa-hero-sub { font-size: 15.5px; line-height: 1.65; color: rgba(255,255,255,.9); max-width: 720px; margin: 8px 0 0; }
.mfoa .mfoa-hero-sub strong, .mfoa .mfoa-hero-alt strong, .mfoa .mfoa-hero-sub em { color: #fff; }
.mfoa-hero-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.mfoa-hero-pills span {
  display: inline-flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 700;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.16); padding: 7px 13px; border-radius: 999px;
}
.mfoa-hero-pills i { color: var(--mfoa-pri-s); }
.mfoa-hero-meta { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 16px; font-size: 12.5px; color: #c9f1eb; }
.mfoa-hero-meta:empty { display: none; }
.mfoa-hero-meta span { display: inline-flex; align-items: center; gap: 6px; }

/* Ficha do modelo compacto (4 itens no hero) */
.mfoa-hero-ficha { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 18px 0 0; }
.mfoa-hero-ficha > div { background: rgba(255,255,255,.09); border: 1px solid rgba(255,255,255,.18); border-radius: 12px; padding: 10px 12px; min-width: 0; }
.mfoa-hero-ficha dt { display: flex; align-items: center; gap: 6px; margin: 0 0 3px; font-size: 10.5px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: var(--mfoa-pri-s); }
.mfoa-hero-ficha dd { margin: 0; font-size: 14px; font-weight: 800; color: #fff; line-height: 1.35; }

/* =========================================================
   CARDS-RESUMO
   ========================================================= */
.mfoa-resumo { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin: -22px 18px 0; position: relative; z-index: 2; }
.mfoa .mfoa-resumo-card {
  display: flex; flex-direction: column; align-items: flex-start; gap: 8px; text-align: left;
  background: var(--mfoa-bg); border: 1px solid var(--mfoa-border); border-radius: var(--mfoa-r);
  padding: 18px; box-shadow: var(--mfoa-sh); transition: transform .18s, box-shadow .18s, border-color .18s;
}
.mfoa .mfoa-resumo-card:hover { transform: translateY(-3px); box-shadow: var(--mfoa-sh-h); border-color: var(--mfoa-pri-b); background: var(--mfoa-bg); }
.mfoa-resumo-ic {
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px;
  background: var(--mfoa-pri-l); color: var(--mfoa-pri); font-size: 17px;
}
.mfoa-resumo-card > strong { font-size: 15.5px; }
.mfoa-resumo-txt { font-size: 13.5px; color: var(--mfoa-body); line-height: 1.5; flex: 1; }
.mfoa-resumo-mais { font-size: 13px; font-weight: 600; color: var(--mfoa-pri); display: inline-flex; gap: 6px; align-items: center; }
.mfoa-resumo-card:hover .mfoa-resumo-mais i { transform: translateX(3px); }
.mfoa-resumo-mais i { transition: transform .18s; }


/* =========================================================
   LAYOUT
   ========================================================= */
.mfoa-page { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 18px; align-items: start; margin-top: 18px; }
.mfoa-resumo + .mfoa-page { margin-top: 22px; }
.mfoa-main { min-width: 0; }
.mfoa-side { display: flex; flex-direction: column; gap: 16px; }

/* =========================================================
   ABAS — barra branca no padrão dos artigos do atlas
   ========================================================= */
.mfoa-tabs {
  display: grid; grid-template-columns: repeat(var(--mfoa-col, 6), minmax(0, 1fr)); gap: 6px; padding: 8px; margin: 0 0 18px;
  background: #fff; border: 1px solid var(--mfoa-border); border-radius: 14px; box-shadow: var(--mfoa-sh);
}
.mfoa .mfoa-tab {
  position: relative; display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 11px 10px; border-radius: 11px;
  font-size: 12.8px; font-weight: 700; color: #64748b; background: #fff; text-align: center; line-height: 1.2; transition: background .2s, color .2s;
}
.mfoa .mfoa-tab i { font-size: 13px; flex: 0 0 auto; }
.mfoa .mfoa-tab:hover { color: var(--mfoa-pri-d); background: var(--mfoa-bg-s); }
.mfoa .mfoa-tab.mfoa-on { color: var(--mfoa-pri-dd); background: var(--mfoa-pri-l); }
.mfoa .mfoa-tab.mfoa-on::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: 0; height: 3px; border-radius: 50px; background: var(--mfoa-pri); }
.mfoa .mfoa-tab.mfoa-on i { color: var(--mfoa-pri); }

.mfoa-aba { display: none; flex-direction: column; gap: 16px; }
.mfoa-aba.mfoa-on { display: flex; animation: mfoa-in .25s ease; }
@keyframes mfoa-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.mfoa .mfoa-quickbtn { display: none; }
.mfoa-ref-web { background: var(--mfoa-pri-l); color: var(--mfoa-pri-d); }

/* =========================================================
   CARD DE SEÇÃO
   ========================================================= */
.mfoa-card {
  background: var(--mfoa-bg); border: 1px solid var(--mfoa-border); border-radius: var(--mfoa-r);
  padding: 24px; box-shadow: var(--mfoa-sh); display: flex; flex-direction: column; gap: 16px;
}
.mfoa-card > * { margin: 0; }
.mfoa .mfoa-card-tit { display: flex; align-items: center; gap: 12px; font-size: 20px; font-weight: 700; }
.mfoa-card-tit > span {
  flex: 0 0 auto; display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px;
  background: var(--mfoa-pri-l); color: var(--mfoa-pri); font-size: 16px;
}
.mfoa-card-perigo { border-color: var(--mfoa-dang-b); }
.mfoa-card-perigo .mfoa-card-tit > span { background: var(--mfoa-dang-bg); color: var(--mfoa-dang); }
.mfoa-card-prova .mfoa-card-tit > span { background: var(--mfoa-prova-bg); color: var(--mfoa-prova); }

.mfoa .mfoa-sub, .mfoa-modal .mfoa-sub { font-size: 16px; font-weight: 700; display: flex; gap: 8px; align-items: center; margin-top: 4px; }
.mfoa-sub i { color: var(--mfoa-pri); font-size: 14px; }

/* Em 30 segundos */
.mfoa-essencial {
  position: relative; overflow: hidden; background: #fff; border: 1px solid var(--mfoa-pri-b);
  border-radius: var(--mfoa-r); box-shadow: var(--mfoa-sh);
}
.mfoa-essencial-head {
  display: flex; align-items: center; gap: 12px; padding: 14px 20px;
  background: linear-gradient(135deg, #0d9488 0%, #0f766e 55%, #115e59 100%);
}
.mfoa-essencial-head > span {
  flex: 0 0 auto; width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center;
  background: rgba(255,255,255,.16); color: #fff; font-size: 16px;
}
.mfoa .mfoa-essencial-head h2 { color: #fff; font-size: 16px; font-weight: 800; margin: 0; }
.mfoa-essencial-head p { color: #c9f1eb; font-size: 12.5px; margin: 0; }
.mfoa-essencial ol {
  list-style: none; margin: 0; padding: 16px 20px 18px; counter-reset: mfze;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px;
}
.mfoa-essencial li {
  position: relative; counter-increment: mfze; display: block; min-width: 0;
  padding: 12px 14px 12px 50px; border-radius: 12px; background: var(--mfoa-bg-s); border: 1px solid var(--mfoa-border-l);
  font-size: 14px; line-height: 1.5; color: var(--mfoa-head);
}
.mfoa-essencial li::before {
  content: counter(mfze); position: absolute; left: 12px; top: 12px; width: 26px; height: 26px; border-radius: 8px;
  display: grid; place-items: center; background: var(--mfoa-pri-l); color: var(--mfoa-pri-d); font-weight: 800; font-size: 13px;
}

/* =========================================================
   BLOCOS
   ========================================================= */

/* Frase-chave */
.mfoa-chave {
  display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px; border-radius: var(--mfoa-r-s);
  background: var(--mfoa-head); color: #fff;
}
.mfoa-chave i { color: var(--mfoa-pri-s); font-size: 18px; margin-top: 3px; }
.mfoa-chave p { font-size: 15.5px; font-weight: 600; color: #fff; }
.mfoa .mfoa-chave strong, .mfoa-modal .mfoa-chave strong { color: var(--mfoa-pri-s); }

/* Alertas */
.mfoa-alerta { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: var(--mfoa-r-s); border: 1px solid; font-size: 14.5px; }
.mfoa-alerta > i { font-size: 16px; margin-top: 3px; flex: 0 0 auto; }
.mfoa-alerta > div { min-width: 0; }
.mfoa-alerta-tit { display: block; margin-bottom: 2px; }
.mfoa-alerta-info    { background: var(--mfoa-alt-bg);  border-color: var(--mfoa-alt-b); }   .mfoa-alerta-info > i    { color: var(--mfoa-alt); }
.mfoa-alerta-atencao { background: var(--mfoa-warn-bg); border-color: var(--mfoa-warn-b); }  .mfoa-alerta-atencao > i { color: var(--mfoa-warn); }
.mfoa-alerta-perigo  { background: var(--mfoa-dang-bg); border-color: var(--mfoa-dang-b); }  .mfoa-alerta-perigo > i  { color: var(--mfoa-dang); }
.mfoa-alerta-ok      { background: var(--mfoa-ok-bg);   border-color: var(--mfoa-ok-b); }    .mfoa-alerta-ok > i      { color: var(--mfoa-ok); }
.mfoa-alerta-prova   { background: var(--mfoa-prova-bg); border-color: var(--mfoa-prova-b); } .mfoa-alerta-prova > i  { color: var(--mfoa-prova); }

/* Rótulo (badge) */
.mfoa-rotulo {
  display: inline-flex; align-items: center; gap: 5px; align-self: flex-start;
  font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; line-height: 1.4;
  color: var(--mfoa-pri-d); background: var(--mfoa-pri-l); padding: 2px 8px; border-radius: 6px;
}
.mfoa-rotulo i { font-size: 9px; }

/* Card com imagem */
.mfoa-figcard {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 22px; align-items: center;
  background: var(--mfoa-bg-s); border: 1px solid var(--mfoa-border-l); border-radius: var(--mfoa-r); padding: 18px;
}
.mfoa-figcard-sem, .mfoa-figcard-largo { grid-template-columns: 1fr; }
.mfoa-figcard-largo .mfoa-fig img { max-height: 620px; }
.mfoa-figcard-txt { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.mfoa .mfoa-figcard-txt h3, .mfoa-modal .mfoa-figcard-txt h3 { font-size: 17.5px; }
.mfoa-fig { margin: 0; display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.mfoa .mfoa-fig-btn, .mfoa-modal .mfoa-fig-btn,
.mfoa .mfoa-gal-img, .mfoa-modal .mfoa-gal-img {
  position: relative; display: block; width: 100%; border-radius: 12px; overflow: hidden; background: #e9f0f6; cursor: zoom-in;
}
.mfoa-fig img { display: block; width: 100%; height: auto; max-height: 380px; object-fit: contain; background: #fff; }
.mfoa-fig-zoom {
  position: absolute; right: 10px; bottom: 10px; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; background: rgba(6, 63, 60, .78); color: #fff; font-size: 14px; opacity: .9; transition: transform .15s;
}
.mfoa-fig-btn:hover .mfoa-fig-zoom, .mfoa-gal-img:hover .mfoa-fig-zoom { transform: scale(1.1); }
.mfoa-fig figcaption { font-size: 12.5px; color: var(--mfoa-muted); text-align: center; }
.mfoa-fig-vazia {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; text-align: center;
  min-height: 200px; border: 2px dashed #c9d6e3; border-radius: 12px; padding: 18px; color: var(--mfoa-muted); font-size: 13px; background: #fff;
}
.mfoa-fig-vazia i { font-size: 28px; color: #b6c5d4; }
.mfoa-fig-vazia small { font-size: 11px; opacity: .8; }

/* Galeria */
.mfoa-galeria { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.mfoa-gal-n1 { grid-template-columns: minmax(0, 420px); }
.mfoa-gal-n2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mfoa-gal-n4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.mfoa-gal-item {
  display: flex; flex-direction: column; background: var(--mfoa-bg); border: 1px solid var(--mfoa-border);
  border-radius: var(--mfoa-r); overflow: hidden; transition: box-shadow .18s, transform .18s;
}
.mfoa-gal-item:hover { box-shadow: var(--mfoa-sh-h); transform: translateY(-2px); }
.mfoa .mfoa-gal-img, .mfoa-modal .mfoa-gal-img { border-radius: 0; aspect-ratio: 4 / 3; }
.mfoa-gal-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.mfoa-gal-icone {
  aspect-ratio: 4 / 3; display: flex; flex-direction: column; gap: 6px; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--mfoa-pri-l), #f3f9fd); color: var(--mfoa-pri); font-size: 34px;
}
.mfoa-gal-icone small { font-size: 11px; color: var(--mfoa-muted); padding: 0 10px; text-align: center; }
.mfoa-gal-txt { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 6px; }
.mfoa .mfoa-gal-txt h4, .mfoa-modal .mfoa-gal-txt h4 { font-size: 15.5px; }
.mfoa-gal-txt p { font-size: 13.5px; line-height: 1.5; }

/* Mini-cards */
.mfoa-cards { display: grid; gap: 12px; }
.mfoa-col-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.mfoa-col-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.mfoa-col-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.mfoa-mini {
  background: var(--mfoa-bg-s); border: 1px solid var(--mfoa-border-l); border-left: 3px solid var(--mfoa-pri-s);
  border-radius: 12px; padding: 14px 16px; min-width: 0;
}
.mfoa-mini-head { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.mfoa-mini-head i { color: var(--mfoa-pri); font-size: 15px; width: 18px; text-align: center; flex: 0 0 auto; }
.mfoa .mfoa-mini h4, .mfoa-modal .mfoa-mini h4 { font-size: 15px; }
.mfoa-mini p { font-size: 14px; line-height: 1.55; }
.mfoa-mini-perigo { border-left-color: var(--mfoa-dang); }  .mfoa-mini-perigo .mfoa-mini-head i { color: var(--mfoa-dang); }
.mfoa-mini-atencao { border-left-color: #e3a634; }        .mfoa-mini-atencao .mfoa-mini-head i { color: var(--mfoa-warn); }
.mfoa-mini-ok { border-left-color: var(--mfoa-ok); }        .mfoa-mini-ok .mfoa-mini-head i { color: var(--mfoa-ok); }

/* Números */
.mfoa-nums { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.mfoa-num {
  display: flex; flex-direction: column; gap: 4px; padding: 16px; border-radius: 14px;
  background: linear-gradient(160deg, #fff, var(--mfoa-pri-l)); border: 1px solid var(--mfoa-pri-b);
}
.mfoa-num i { color: var(--mfoa-pri); font-size: 16px; margin-bottom: 4px; }
.mfoa .mfoa-num strong, .mfoa-modal .mfoa-num strong { font-size: 21px; font-weight: 800; color: var(--mfoa-pri-dd); line-height: 1.15; }
.mfoa-num span { font-size: 13px; line-height: 1.45; color: var(--mfoa-body); }

/* Passos */
.mfoa-passos { list-style: none; margin: 0; padding: 0; counter-reset: mfzp; display: flex; flex-direction: column; gap: 0; }
.mfoa-passos > li { position: relative; display: block; padding: 0 0 18px 50px; counter-increment: mfzp; }
.mfoa-passos > li::before {
  content: counter(mfzp); position: absolute; left: 0; top: 0; width: 32px; height: 32px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 800; font-size: 14px; color: #fff; background: var(--mfoa-pri);
  box-shadow: 0 0 0 4px var(--mfoa-pri-l);
}
.mfoa-passos > li::after { content: ""; position: absolute; left: 15px; top: 36px; bottom: 4px; width: 2px; background: var(--mfoa-pri-b); }
.mfoa-passos > li:last-child { padding-bottom: 0; }
.mfoa-passos > li:last-child::after { display: none; }
.mfoa-passo-tit { display: block; font-size: 15.5px; margin: 4px 0 2px; }
.mfoa-passos p { font-size: 14.5px; }
.mfoa-passos-fluxo { flex-direction: row; gap: 10px; }
.mfoa-passos-fluxo > li { flex: 1; padding: 46px 14px 14px; background: var(--mfoa-bg-s); border: 1px solid var(--mfoa-border-l); border-radius: 12px; }
.mfoa-passos-fluxo > li::before { left: 14px; top: 12px; width: 28px; height: 28px; font-size: 13px; }
.mfoa-passos-fluxo > li::after { display: none; }

/* Listas */
.mfoa-lista { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.mfoa-lista > li { position: relative; display: block; padding-left: 28px; font-size: 14.5px; line-height: 1.55; }
.mfoa-lista > li::before {
  font-family: "Font Awesome 6 Free"; font-weight: 900; position: absolute; left: 0; top: 2px; font-size: 13px;
  width: 19px; height: 19px; border-radius: 50%; display: grid; place-items: center;
}
.mfoa-lista-check > li::before { content: "\f00c"; color: var(--mfoa-ok); background: var(--mfoa-ok-bg); font-size: 10px; }
.mfoa-lista-x > li::before { content: "\f00d"; color: var(--mfoa-dang); background: var(--mfoa-dang-bg); font-size: 10px; }
.mfoa-lista-alerta > li::before { content: "\21"; color: var(--mfoa-warn); background: var(--mfoa-warn-bg); font-size: 10px; }
.mfoa-lista-dot > li { padding-left: 20px; }
.mfoa-lista-dot > li::before { content: ""; width: 7px; height: 7px; top: 9px; left: 4px; background: var(--mfoa-pri); }

/* Comparar */
.mfoa-comparar { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.mfoa-comp { border-radius: 14px; padding: 16px; border: 1px solid var(--mfoa-border); background: var(--mfoa-bg-s); display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.mfoa .mfoa-comp h4, .mfoa-modal .mfoa-comp h4 { font-size: 15px; display: flex; gap: 8px; align-items: center; }
.mfoa-comp p { font-size: 14px; }
.mfoa-comp-ok      { background: var(--mfoa-ok-bg);   border-color: var(--mfoa-ok-b); }   .mfoa-comp-ok h4 i { color: var(--mfoa-ok); }
.mfoa-comp-alt     { background: var(--mfoa-alt-bg);  border-color: var(--mfoa-alt-b); }  .mfoa-comp-alt h4 i { color: var(--mfoa-alt); }
.mfoa-comp-atencao { background: var(--mfoa-warn-bg); border-color: var(--mfoa-warn-b); } .mfoa-comp-atencao h4 i { color: var(--mfoa-warn); }
.mfoa-comp-perigo  { background: var(--mfoa-dang-bg); border-color: var(--mfoa-dang-b); } .mfoa-comp-perigo h4 i { color: var(--mfoa-dang); }
.mfoa-comp-neutro h4 i { color: var(--mfoa-pri); }

/* Tabelas */
.mfoa-tabela-wrap { width: 100%; overflow-x: auto; border: 1px solid var(--mfoa-border); border-radius: 14px; -webkit-overflow-scrolling: touch; }
.mfoa-tabela { width: 100%; border-collapse: collapse; table-layout: auto; font-size: 14px; margin: 0; background: #fff; }
.mfoa-tabela th {
  background: var(--mfoa-bg-s); color: var(--mfoa-head); font-weight: 700; font-size: 12.5px; text-transform: uppercase; letter-spacing: .04em;
  text-align: left; padding: 12px 14px; border: 0; border-bottom: 1px solid var(--mfoa-border);
}
.mfoa-tabela td { padding: 12px 14px; border: 0; border-bottom: 1px solid var(--mfoa-border-l); vertical-align: top; overflow-wrap: break-word; hyphens: auto; line-height: 1.5; }
.mfoa-tabela tbody tr:last-child td { border-bottom: 0; }
.mfoa-tabela tbody tr:nth-child(even) td { background: #fbfdff; }
.mfoa-tabela td:first-child { font-weight: 600; color: var(--mfoa-head); min-width: 130px; }
.mfoa-tabela-nota { display: flex; gap: 8px; font-size: 13px; color: var(--mfoa-muted); margin: 0; }
.mfoa-tabela-nota i { color: var(--mfoa-pri); margin-top: 3px; }

/* Selos de prioridade */
.mfoa-nivel {
  display: inline-block; margin: 0 0 6px; font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em;
  padding: 3px 10px; border-radius: 999px; border: 1px solid; white-space: nowrap; line-height: 1.3;
}
.mfoa-nivel + * { display: block; }
.mfoa-nivel-ok     { color: var(--mfoa-ok);   background: var(--mfoa-ok-bg);   border-color: var(--mfoa-ok-b); }
.mfoa-nivel-alt    { color: var(--mfoa-alt);  background: var(--mfoa-alt-bg);  border-color: var(--mfoa-alt-b); }
.mfoa-nivel-perigo { color: var(--mfoa-dang); background: var(--mfoa-dang-bg); border-color: var(--mfoa-dang-b); }
.mfoa-nivel-neutro { color: var(--mfoa-muted); background: #f1f5f9; border-color: var(--mfoa-border); }
.mfoa-tx td:first-child .mfoa-nivel { display: table; }

/* Medicamento citado no texto: link discreto que abre a ficha */
.mfoa .mfoa-med, .mfoa-modal .mfoa-med {
  display: inline; font: inherit; font-weight: 700; color: var(--mfoa-pri-d); line-height: inherit; vertical-align: baseline;
  text-decoration: underline; text-decoration-style: dotted; text-decoration-color: var(--mfoa-pri-s); text-underline-offset: 3px;
}
.mfoa .mfoa-med:hover, .mfoa-modal .mfoa-med:hover { color: var(--mfoa-pri); text-decoration-style: solid; background: none; }
.mfoa-essencial-head .mfoa-med, .mfoa-chave .mfoa-med { color: inherit; }

/* Rotas de tratamento */
.mfoa-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mfoa-rotas { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-flow: row dense; gap: 14px; }
.mfoa-rota {
  --rc: var(--mfoa-pri); --rc-soft: var(--mfoa-pri-l); --rc-ink: var(--mfoa-pri-dd);
  position: relative; background: #fff; border: 1px solid var(--mfoa-border); border-radius: 16px; min-width: 0; overflow: hidden;
  transition: box-shadow .2s, border-color .2s; scroll-margin-top: 90px;
}
.mfoa-rota::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--rc); }
.mfoa-rota-blue   { --rc: #2b6cb0; --rc-soft: #eaf2fb; --rc-ink: #1d4f86; }
.mfoa-rota-navy   { --rc: var(--mfoa-head); --rc-soft: #e7edf6; --rc-ink: var(--mfoa-head); }
.mfoa-rota-amber  { --rc: #d69e2e; --rc-soft: var(--mfoa-warn-bg); --rc-ink: var(--mfoa-warn); }
.mfoa-rota-red    { --rc: var(--mfoa-dang); --rc-soft: var(--mfoa-dang-bg); --rc-ink: #9b2c22; }
.mfoa-rota-violet { --rc: var(--mfoa-prova); --rc-soft: var(--mfoa-prova-bg); --rc-ink: #4c3fa3; }
.mfoa-rota:hover { border-color: var(--mfoa-pri-b); box-shadow: var(--mfoa-sh-h); }
.mfoa-rota.mfoa-aberta { grid-column: 1 / -1; border-color: var(--mfoa-pri-b); box-shadow: var(--mfoa-sh-h); }
.mfoa .mfoa-rota-head {
  width: 100%; height: 100%; min-height: 176px; display: grid; grid-template-columns: 48px minmax(0, 1fr); grid-template-rows: 1fr auto;
  column-gap: 14px; row-gap: 12px; padding: 18px 18px 16px 23px; text-align: left; align-items: start;
}
.mfoa .mfoa-rota-head:hover { background: transparent; }
.mfoa-rota.mfoa-aberta .mfoa-rota-head { min-height: 0; height: auto; background: var(--rc-soft); border-bottom: 1px solid var(--mfoa-border); }
.mfoa-rota-ic { width: 48px; height: 48px; border-radius: 14px; background: var(--rc-soft); color: var(--rc-ink); display: grid; place-items: center; font-size: 19px; }
.mfoa-rota.mfoa-aberta .mfoa-rota-ic { background: #fff; }
.mfoa-rota-main { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.mfoa-rota-chip { align-self: flex-start; font-size: 10.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--rc-ink); background: var(--rc-soft); border-radius: 999px; padding: 3px 10px; }
.mfoa-rota.mfoa-aberta .mfoa-rota-chip { background: #fff; }
.mfoa-rota-t { font-size: 17px; font-weight: 800; color: var(--mfoa-head); line-height: 1.3; }
.mfoa-rota-d { font-size: 13px; line-height: 1.6; color: var(--mfoa-body); }
.mfoa-rota-nomes { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.mfoa-rota-nomes span { font-size: 11px; font-weight: 700; color: var(--mfoa-head); background: var(--mfoa-bg-s); border: 1px solid var(--mfoa-border-l); border-radius: 7px; padding: 3px 8px; }
.mfoa-rota.mfoa-aberta .mfoa-rota-nomes { display: none; }
.mfoa-rota-estado { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding-top: 12px; border-top: 1px dashed var(--mfoa-border); }
.mfoa-rota-n { font-size: 12px; font-weight: 700; color: var(--mfoa-muted); }
.mfoa-rota-go { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 800; color: var(--mfoa-pri-d); background: var(--mfoa-pri-l); border-radius: 9px; padding: 7px 12px; transition: background .2s, color .2s; }
.mfoa-rota-go i { transition: transform .25s; font-size: 11px; }
.mfoa-rota-head:hover .mfoa-rota-go { background: var(--mfoa-pri); color: #fff; }
.mfoa-rota-fechar { display: none; }
.mfoa-rota.mfoa-aberta .mfoa-rota-abrir { display: none; }
.mfoa-rota.mfoa-aberta .mfoa-rota-fechar { display: inline; }
.mfoa-rota.mfoa-aberta .mfoa-rota-go { background: #fff; }
.mfoa-rota.mfoa-aberta .mfoa-rota-go i { transform: rotate(180deg); }
.mfoa-rota-corpo { padding: 20px 22px 22px 25px; display: flex; flex-direction: column; gap: 14px; animation: mfoa-in .25s ease; }
.mfoa-rota-corpo[hidden] { display: none; }
.mfoa-rota-quando { display: flex; align-items: flex-start; gap: 12px; background: var(--mfoa-bg-s); border: 1px solid var(--mfoa-border-l); border-radius: 12px; padding: 12px 14px; }
.mfoa-rota-quando > i { margin-top: 4px; color: var(--mfoa-pri); }
.mfoa-rota-quando b { display: block; font-size: 12px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--mfoa-head); margin-bottom: 2px; }
.mfoa-rota-quando span { display: block; font-size: 13.5px; line-height: 1.65; }
.mfoa-rota-pe { display: flex; justify-content: flex-end; }
.mfoa .mfoa-rota-recolher {
  display: inline-flex; align-items: center; gap: 9px; font-size: 12.5px; font-weight: 800; color: var(--mfoa-head);
  border: 1px solid var(--mfoa-border); background: #fff; border-radius: 10px; padding: 6px 12px 6px 6px;
}
.mfoa .mfoa-rota-recolher:hover { background: var(--mfoa-bg-s); }
.mfoa-rota-recolher > span { width: 24px; height: 24px; border-radius: 7px; background: var(--mfoa-bg-s); display: grid; place-items: center; font-size: 11px; }

/* Tabela de dose (rotas e aba Posologia do popup) — padrão do bulário */
.mfoa-dose { display: grid; gap: 9px; }
.mfoa-dose + .mfoa-dose { margin-top: 6px; }
.mfoa-dose-head { display: flex; align-items: center; gap: 9px; padding: 0 2px; color: var(--mfoa-pri-dd); }
.mfoa-dose-head > i { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: var(--mfoa-pri-l); color: var(--mfoa-pri); font-size: 14px; flex: 0 0 auto; }
.mfoa .mfoa-dose-head strong, .mfoa-modal .mfoa-dose-head strong { font-size: 15px; font-weight: 800; color: var(--mfoa-pri-dd); }
.mfoa-dose-head > span { margin-left: auto; padding: 4px 10px; border-radius: 999px; background: var(--mfoa-pri-l); color: var(--mfoa-pri-d); font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.mfoa-dose-nota { margin: 0; font-size: 13px; color: var(--mfoa-muted); }
.mfoa-dose-wrap { width: 100%; overflow-x: auto; border: 1px solid var(--mfoa-border); border-radius: 14px; background: #fff; }
.mfoa-dose-tab {
  width: 100%; min-width: 720px; margin: 0; border-collapse: collapse; border-spacing: 0; table-layout: fixed;
  background: #fff; color: var(--mfoa-body); font-size: 13.5px;
}
.mfoa-dose-tab th {
  padding: 12px 14px; background: #f6f8fa; border: 0; border-bottom: 1px solid var(--mfoa-border);
  color: var(--mfoa-muted); font-size: 11.5px; font-weight: 800; text-align: left; text-transform: uppercase; letter-spacing: .055em;
}
.mfoa-dose-tab th:nth-child(1) { width: 20%; }
.mfoa-dose-tab th:nth-child(2) { width: 23%; }
.mfoa-dose-tab th:nth-child(3) { width: 16%; }
.mfoa-dose-tab th:nth-child(4) { width: 16%; }
.mfoa-dose-tab th:nth-child(5) { width: 25%; }
.mfoa-dose-tab td.mfoa-dose-f, .mfoa-dose-tab td.mfoa-dose-d { padding-left: 12px; padding-right: 10px; }

.mfoa-dose-tab td { padding: 12px 14px; border: 0; border-bottom: 1px solid #edf1f4; vertical-align: top; line-height: 1.48; overflow-wrap: break-word; background: #fff; }
.mfoa-dose-tab tbody + tbody tr:first-child td { border-top: 2px solid #d5dde3; }
.mfoa-dose-tab tbody:last-child tr:last-child td, .mfoa-dose-tab tbody:last-child td[rowspan] { border-bottom: 0; }
.mfoa-dose-tab tbody { --ind: #2f7a62; --ind-soft: #edf7f3; }
.mfoa-dose-tab tbody.mfoa-ind-1 { --ind: #396f9b; --ind-soft: #edf4f9; }
.mfoa-dose-tab tbody.mfoa-ind-2 { --ind: #765e9b; --ind-soft: #f3f0f8; }
.mfoa-dose-tab tbody.mfoa-ind-3 { --ind: #9a6b27; --ind-soft: #fbf4e9; }
.mfoa-dose-tab tbody.mfoa-ind-4 { --ind: #9a4e49; --ind-soft: #fbefee; }
.mfoa-dose-tab tbody.mfoa-ind-5 { --ind: #4b7180; --ind-soft: #eef5f7; }
.mfoa-dose-tab td.mfoa-dose-ind { background: var(--ind-soft); color: var(--ind); border-right: 1px solid #e3e9ee; }
.mfoa-dose-tab td.mfoa-dose-obs { border-left: 1px solid #edf1f4; color: var(--mfoa-muted); }
.mfoa-dose-ind-t { display: block; font-weight: 800; line-height: 1.35; color: var(--ind); }
.mfoa-dose-ind-t strong, .mfoa-dose-ind-t em { color: inherit; }
.mfoa-dose-badge {
  display: inline-block; margin: 0 0 7px; font-size: 10px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase;
  padding: 3px 10px; border-radius: 999px; border: 1px solid; line-height: 1.3; white-space: normal;
  max-width: 100%; overflow-wrap: anywhere;
}
.mfoa-dose-sub { display: block; margin-top: 4px; font-size: 12px; font-weight: 500; color: var(--mfoa-muted); line-height: 1.4; }
.mfoa-dose-main strong { display: block; color: var(--mfoa-head); font-weight: 800; }
.mfoa-dose-farm { display: block; font-size: 11.5px; font-weight: 600; color: var(--mfoa-muted); margin-bottom: 1px; }
.mfoa-fichas { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; margin-top: 10px; }
/* Ficha do medicamento: ícone ao lado do nome do fármaco */
.mfoa .mfoa-ficha.mfoa-ficha-ic {
  display: inline-grid; place-items: center; vertical-align: middle; position: relative; top: -1px; width: 20px; height: 20px; padding: 0; margin-left: 5px;
  border-radius: 50%; border: 1px solid transparent; background: #fff; color: var(--ind, var(--mfoa-pri));
  box-shadow: 0 1px 2px rgba(15,23,42,.12); font-size: 12px; line-height: 1; cursor: pointer;
}
.mfoa .mfoa-ficha.mfoa-ficha-ic i { font-size: 12px; line-height: 1; color: inherit; display: block; }
.mfoa .mfoa-ficha.mfoa-ficha-ic:hover { background: var(--ind, var(--mfoa-pri)); border-color: var(--ind, var(--mfoa-pri)); color: #fff; }
.mfoa .mfoa-ficha.mfoa-ficha-ic:hover i { color: #fff; }
/* Associação: uma célula por fármaco, mesma família de cor + etiqueta */
.mfoa-dose-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; margin-bottom: 6px; }
.mfoa-dose-tags .mfoa-dose-badge { margin: 0; }
.mfoa-dose-assoc { display: inline-flex; max-width: 100%; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; background: #fff; border: 1px dashed var(--ind); color: var(--ind); font-size: 10.5px; font-weight: 800; letter-spacing: .03em; text-transform: uppercase; }
.mfoa-dose-assoc i { font-size: 9px; }
.mfoa-nowrap { white-space: nowrap; }
/* Associação (célula mesclada): um fármaco por linha, "+" entre eles, ícone à direita */
.mfoa-dose-lista { display: flex; flex-direction: column; gap: 2px; }
.mfoa-dose-item { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-weight: 800; line-height: 1.3; color: var(--ind); }
.mfoa-dose-item .mfoa-ficha.mfoa-ficha-ic { flex: 0 0 auto; margin-left: 0; top: 0; }
.mfoa-dose-sep { align-self: flex-start; display: grid; place-items: center; width: 18px; height: 18px; margin: 1px 0; border-radius: 50%; background: var(--ind); color: #fff; font-size: 12px; font-weight: 800; line-height: 1; }
.mfoa .mfoa-ficha {
  display: inline-flex; align-items: center; gap: 6px; max-width: 100%;
  padding: 5px 10px; border-radius: 999px; border: 1px solid var(--mfoa-head); background: var(--mfoa-head);
  color: #fff; font-size: 11.5px; font-weight: 700; line-height: 1.25; transition: background .15s, border-color .15s;
}
.mfoa .mfoa-ficha span { white-space: normal; text-align: left; }
.mfoa .mfoa-ficha i { font-size: 8px; flex: 0 0 auto; }
.mfoa .mfoa-ficha:hover { background: var(--mfoa-pri); border-color: var(--mfoa-pri); color: #fff; }
.mfoa .mfoa-ficha i { color: var(--mfoa-pri-s); }
.mfoa .mfoa-ficha:hover i { color: #fff; }

/* Detalhes recolhíveis */
.mfoa-det { border: 1px solid var(--mfoa-border); border-radius: 12px; background: #fff; overflow: hidden; }
.mfoa-det > summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; gap: 10px; padding: 14px 16px;
  font-weight: 700; color: var(--mfoa-head); font-size: 15px; background: var(--mfoa-bg-s);
}
.mfoa-det > summary::-webkit-details-marker { display: none; }
.mfoa-det > summary > i:first-child { color: var(--mfoa-pri); }
.mfoa-det > summary > span { flex: 1; }
.mfoa-det > summary > i:last-child { color: var(--mfoa-muted); font-size: 12px; transition: transform .2s; }
.mfoa-det[open] > summary > i:last-child { transform: rotate(180deg); }
.mfoa-det[open] > summary { border-bottom: 1px solid var(--mfoa-border-l); }
.mfoa-det-corpo { padding: 16px; display: flex; flex-direction: column; gap: 14px; }

/* Ferramentas */
.mfoa-tool { border: 1px solid var(--mfoa-alt-b); background: linear-gradient(180deg, #f5f9fe, #fff); border-radius: var(--mfoa-r); padding: 18px; display: flex; flex-direction: column; gap: 14px; }
.mfoa-tool-head { display: flex; gap: 12px; align-items: flex-start; }
.mfoa-tool-head > i { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--mfoa-alt-bg); color: var(--mfoa-alt); flex: 0 0 auto; }
.mfoa-tool-head strong { font-size: 16px; display: block; }
.mfoa-tool-head p { font-size: 13.5px; color: var(--mfoa-muted); margin-top: 2px; }
.mfoa-campos { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.mfoa-campo { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.mfoa-campo label { font-size: 13px; font-weight: 700; color: var(--mfoa-head); margin: 0; }
.mfoa .mfoa-campo select, .mfoa .mfoa-campo input,
.mfoa-modal .mfoa-campo select, .mfoa-modal .mfoa-campo input,
.mfoa .mfoa-calc-conc, .mfoa-modal .mfoa-calc-conc {
  width: 100%; min-height: 48px; font-size: 16px; font-family: inherit; color: var(--mfoa-head);
  padding: 10px 38px 10px 12px; border: 1px solid var(--mfoa-border); border-radius: 10px; background-color: #fff;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; touch-action: manipulation; margin: 0; box-shadow: none;
}
.mfoa .mfoa-campo input, .mfoa-modal .mfoa-campo input { padding-right: 12px; }
.mfoa-tool-res {
  padding: 14px 16px; border-radius: 12px; background: #fff; border: 1px dashed var(--mfoa-border); font-size: 14.5px; color: var(--mfoa-muted);
}
.mfoa-tool-res.mfoa-res-info    { border: 1px solid var(--mfoa-alt-b);  background: var(--mfoa-alt-bg);  color: var(--mfoa-body); }
.mfoa-tool-res.mfoa-res-ok      { border: 1px solid var(--mfoa-ok-b);   background: var(--mfoa-ok-bg);   color: var(--mfoa-body); }
.mfoa-tool-res.mfoa-res-atencao { border: 1px solid var(--mfoa-warn-b); background: var(--mfoa-warn-bg); color: var(--mfoa-body); }
.mfoa-tool-res.mfoa-res-perigo  { border: 1px solid var(--mfoa-dang-b); background: var(--mfoa-dang-bg); color: var(--mfoa-body); }
.mfoa-tool-nota { display: flex; gap: 8px; font-size: 12.5px; color: var(--mfoa-muted); margin: 0; }
.mfoa-tool-nota i { color: var(--mfoa-warn); margin-top: 3px; }
.mfoa-calc-lista { display: flex; flex-direction: column; gap: 8px; }
.mfoa-calc-item {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 220px); gap: 12px; align-items: center;
  padding: 12px 14px; background: #fff; border: 1px solid var(--mfoa-border-l); border-radius: 12px;
}
.mfoa-calc-nome { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.mfoa-calc-nome > span { font-size: 12.5px; color: var(--mfoa-muted); }
.mfoa .mfoa-calc-conc, .mfoa-modal .mfoa-calc-conc { min-height: 40px; font-size: 16px; padding: 6px 30px 6px 10px; margin-top: 4px; max-width: 220px; }
.mfoa-calc-saida { text-align: right; display: flex; flex-direction: column; }
.mfoa-calc-dose { font-size: 20px; font-weight: 800; color: var(--mfoa-pri-dd); }
.mfoa-calc-sub { font-size: 12.5px; color: var(--mfoa-muted); }
.mfoa-calc-sub b { color: var(--mfoa-warn); }

/* Referências */
.mfoa-refs { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.mfoa-ref {
  display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 14px; align-items: start;
  padding: 14px 16px; border: 1px solid var(--mfoa-border); border-radius: 14px; background: #fff; transition: border-color .15s, box-shadow .15s;
}
.mfoa-ref:hover { border-color: var(--mfoa-pri-b); box-shadow: var(--mfoa-sh); }
.mfoa-ref-n { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; background: var(--mfoa-head); color: #fff; font-weight: 800; font-size: 13px; }
.mfoa-ref-c { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.mfoa-ref-meta { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.mfoa-ref-tipo { font-size: 10px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; }
.mfoa-ref-of  { background: var(--mfoa-ok-bg); color: var(--mfoa-ok); }
.mfoa-ref-dir { background: var(--mfoa-alt-bg); color: var(--mfoa-alt); }
.mfoa-ref-man { background: var(--mfoa-prova-bg); color: var(--mfoa-prova); }
.mfoa-ref-art { background: var(--mfoa-warn-bg); color: var(--mfoa-warn); }
.mfoa-ref-ano { font-size: 12px; font-weight: 700; color: var(--mfoa-muted); }
.mfoa-ref-txt { font-size: 13.5px; line-height: 1.6; color: var(--mfoa-body); overflow-wrap: anywhere; }
.mfoa-ref-txt strong { display: inline; color: var(--mfoa-head); }
.mfoa-ref-txt a { color: var(--mfoa-pri-d); font-weight: 600; }
.mfoa-aviso { background: var(--mfoa-bg); }

/* =========================================================
   LATERAL
   ========================================================= */
.mfoa-side-card { background: var(--mfoa-bg); border: 1px solid var(--mfoa-border); border-radius: var(--mfoa-r); padding: 18px; box-shadow: var(--mfoa-sh); }
.mfoa .mfoa-side-card h3, .mfoa-modal .mfoa-side-card h3 { font-size: 14.5px; display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.mfoa-side-card h3 i { color: var(--mfoa-pri); }
.mfoa-side-card.mfoa-side-info { padding: 0; overflow: hidden; }
.mfoa .mfoa-side-info .mfoa-side-head, .mfoa-modal .mfoa-side-info .mfoa-side-head {
  margin: 0; padding: 15px 18px; border-bottom: 1px solid var(--mfoa-border); font-size: 13.5px; font-weight: 800;
  letter-spacing: .03em; text-transform: uppercase; color: var(--mfoa-navy);
}
.mfoa-side-info dl { margin: 0; }
.mfoa-side-info dl > div { display: grid; grid-template-columns: 28px minmax(0, 1fr); column-gap: 10px; padding: 13px 18px; border-bottom: 1px solid var(--mfoa-border-l); }
.mfoa-side-info dl > div:last-child { border-bottom: 0; }
.mfoa-side-info dl > div > i { grid-row: span 2; width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: var(--mfoa-pri-l); color: var(--mfoa-pri-d); font-size: 12px; }
.mfoa-side-info dt { font-size: 12px; font-weight: 800; color: var(--mfoa-navy); line-height: 1.4; }
.mfoa-side-info dd { margin: 2px 0 0; font-size: 13px; line-height: 1.5; color: var(--mfoa-body); }
.mfoa-side-list { display: flex; flex-direction: column; gap: 10px; }
.mfoa-side-item { display: flex; gap: 10px; align-items: flex-start; }
.mfoa-side-item > i {
  flex: 0 0 auto; width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
  background: var(--mfoa-warn-bg); color: var(--mfoa-warn); font-size: 13px;
}
.mfoa-side-item strong { display: block; font-size: 13.5px; }
.mfoa-side-item p { font-size: 13px; line-height: 1.45; margin: 0; }
.mfoa-rel-off {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; font-size: 13.5px; font-weight: 600;
  border: 1px dashed var(--mfoa-border); color: var(--mfoa-muted);
}
.mfoa-rel-off > i { width: 16px; text-align: center; }
.mfoa-rel-off > span { flex: 1; }
.mfoa-rel-off small { font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.mfoa-rel { display: flex; flex-direction: column; gap: 8px; }
.mfoa-rel a {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; text-decoration: none;
  border: 1px solid var(--mfoa-border-l); background: var(--mfoa-bg-s); color: var(--mfoa-head); font-size: 13.5px; font-weight: 600; transition: all .15s;
}
.mfoa-rel a:hover { border-color: var(--mfoa-pri-b); background: var(--mfoa-pri-l); }
.mfoa-rel a > i:first-child { color: var(--mfoa-pri); width: 16px; text-align: center; }
.mfoa-rel a > span { flex: 1; }
.mfoa-rel a > i:last-child { font-size: 10px; color: var(--mfoa-muted); }
.mfoa-prova { background: linear-gradient(160deg, #fff, var(--mfoa-prova-bg)); border-color: var(--mfoa-prova-b); }
.mfoa .mfoa-prova h3 i, .mfoa-modal .mfoa-prova h3 i { color: var(--mfoa-prova); }
.mfoa-prova p { font-size: 13.5px; }
.mfoa-prova-dest { font-weight: 600; color: var(--mfoa-head); }
.mfoa .mfoa-btn-quiz, .mfoa-modal .mfoa-btn-quiz {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; margin-top: 12px; min-height: 44px;
  border-radius: 12px; background: var(--mfoa-prova); color: #fff; font-weight: 700; font-size: 14px; transition: filter .15s;
}
.mfoa .mfoa-btn-quiz:hover, .mfoa-modal .mfoa-btn-quiz:hover { filter: brightness(1.1); background: var(--mfoa-prova); color: #fff; }

.mfoa-footer {
  display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--mfoa-muted);
  border-top: 1px solid var(--mfoa-border); padding: 18px 4px 6px; margin-top: 6px;
}
.mfoa-footer i { color: var(--mfoa-pri); margin-top: 3px; }

/* =========================================================
   MODAIS
   ========================================================= */
.mfoa-modal {
  position: fixed; inset: 0; z-index: 999999; display: none; align-items: center; justify-content: center;
  padding: 20px; background: rgba(6, 25, 45, .55); backdrop-filter: blur(3px);
}
.mfoa-modal.mfoa-aberto { display: flex; animation: mfoa-fade .18s ease; }
@keyframes mfoa-fade { from { opacity: 0; } to { opacity: 1; } }
.mfoa-caixa {
  position: relative; width: 100%; max-width: 760px; max-height: calc(100vh - 40px); max-height: calc(100dvh - 40px);
  overflow-y: auto; overscroll-behavior: contain; background: #fff; border-radius: 20px; box-shadow: 0 30px 80px rgba(0,0,0,.3);
  animation: mfoa-sobe .22s ease;
}
@keyframes mfoa-sobe { from { transform: translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }
.mfoa-caixa-barra { position: sticky; top: 0; z-index: 3; display: flex; justify-content: flex-end; align-items: flex-start; gap: 8px; height: 0; padding: 0 12px; overflow: visible; }
.mfoa-caixa-barra > button { margin-top: 12px; }
.mfoa-modal .mfoa-x, .mfoa-modal .mfoa-voltar {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255,255,255,.95); color: var(--mfoa-head); box-shadow: 0 2px 10px rgba(0,0,0,.15); font-size: 16px;
}
.mfoa-modal .mfoa-voltar[hidden] { display: none; }
.mfoa-modal .mfoa-x:hover, .mfoa-modal .mfoa-voltar:hover { background: #fff; color: var(--mfoa-pri); }
.mfoa-conteudo { padding: 0; }

/* Popup de resumo */
.mfoa-pop { display: flex; flex-direction: column; gap: 16px; padding: 0 26px 26px; }
.mfoa-pop-head {
  margin: 0 -26px; padding: 30px 112px 24px 26px;
  background: linear-gradient(135deg, #0d9488 0%, #0f766e 50%, #115e59 100%); color: #fff;
}
.mfoa-pop-kicker { display: inline-block; font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #c9f1eb; margin-bottom: 6px; }
.mfoa-modal .mfoa-pop-head h2 { color: #fff; font-size: 23px; font-weight: 800; }
.mfoa-modal .mfoa-pop-head strong { color: #fff; }

/* Popup de medicamento */
.mfoa-caixa.mfoa-caixa-med { overflow: hidden; display: flex; flex-direction: column; max-width: 860px; height: min(780px, calc(100dvh - 40px)); }
.mfoa-caixa-med .mfoa-conteudo { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.mfoa-medpop { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.mfoa-medpop-head { flex: 0 0 auto; display: flex; gap: 14px; align-items: center; padding: 18px 112px 14px 20px; border-bottom: 1px solid var(--mfoa-border-l); }
.mfoa-medpop-ic { flex: 0 0 auto; width: 46px; height: 46px; border-radius: 13px; display: grid; place-items: center; font-size: 19px; background: var(--mfoa-pri); color: #fff; }
.mfoa-medpop-classe { display: block; font-size: 10.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--mfoa-pri-d); }
.mfoa-modal .mfoa-medpop-head h2 { font-size: 19px; font-weight: 800; margin: 1px 0; }
.mfoa-medpop-head p { font-size: 12.5px; color: var(--mfoa-muted); margin: 0; }
.mfoa-medpop-hl { flex: 0 0 auto; margin: 14px 20px 0; display: flex; flex-direction: column; gap: 4px; background: var(--mfoa-dang-bg); border: 1px solid var(--mfoa-dang-b); border-radius: 12px; padding: 11px 14px; }
.mfoa-medpop-hl > span { display: flex; align-items: center; gap: 7px; font-size: 10.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--mfoa-dang); }
.mfoa-modal .mfoa-medpop-hl > strong { font-size: 15px; font-weight: 800; color: var(--mfoa-dang); line-height: 1.5; }
.mfoa-mtabs { flex: 0 0 auto; display: flex; gap: 4px; padding: 10px 20px 0; overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--mfoa-border); }
.mfoa-mtabs::-webkit-scrollbar { display: none; }
.mfoa-modal .mfoa-mtab {
  flex: 0 0 auto; display: inline-flex; align-items: center; gap: 7px; padding: 10px 13px; margin-bottom: -1px;
  font-size: 13px; font-weight: 700; color: #64748b; border-bottom: 3px solid transparent; white-space: nowrap; transition: color .2s, border-color .2s;
}
.mfoa-modal .mfoa-mtab:hover { color: var(--mfoa-head); background: none; }
.mfoa-modal .mfoa-mtab.mfoa-on { color: var(--mfoa-head); border-bottom-color: var(--mfoa-pri); }
.mfoa-mtab.mfoa-on i { color: var(--mfoa-pri); }
.mfoa-mpanes { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 18px 20px 22px; }
.mfoa-mpane { display: none; flex-direction: column; gap: 12px; }
.mfoa-mpane.mfoa-on { display: flex; animation: mfoa-in .2s ease; }
.mfoa-mpane > * { margin: 0; }
.mfoa-modal .mfoa-lead { font-size: 15px; line-height: 1.7; color: var(--mfoa-head); font-weight: 500; }
.mfoa-modal .mfoa-msub {
  display: flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  color: var(--mfoa-head); padding-bottom: 6px; border-bottom: 1px solid var(--mfoa-border-l); margin-top: 6px;
}
.mfoa-msub i { color: var(--mfoa-pri); }
.mfoa-kv { margin: 0; display: grid; border: 1px solid var(--mfoa-border-l); border-radius: 12px; overflow: hidden; }
.mfoa-kv > div { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 14px; padding: 11px 14px; border-bottom: 1px solid var(--mfoa-border-l); background: #fff; }
.mfoa-kv > div:nth-child(even) { background: var(--mfoa-bg-s); }
.mfoa-kv > div:last-child { border-bottom: 0; }
.mfoa-kv dt { font-size: 13px; font-weight: 800; color: var(--mfoa-head); line-height: 1.5; }
.mfoa-kv dd { margin: 0; font-size: 13.5px; line-height: 1.6; color: var(--mfoa-body); }

/* Modal rápido (celular) */
.mfoa-quick .mfoa-side-card { box-shadow: none; }

/* Zoom de imagem */
.mfoa-zoom .mfoa-caixa { max-width: 1100px; background: #0b1622; }
.mfoa-zoom img { display: block; width: 100%; height: auto; max-height: calc(100dvh - 120px); object-fit: contain; }
.mfoa-zoom figcaption { color: #c9d8ea; font-size: 13px; text-align: center; padding: 10px 16px 14px; }

/* Quiz */
.mfoa-quiz { padding: 0 26px 26px; display: flex; flex-direction: column; gap: 16px; }
.mfoa-quiz .mfoa-pop-head { background: linear-gradient(135deg, #7b56d6, #5534a8); }
.mfoa-quiz-corpo { display: flex; flex-direction: column; gap: 16px; }
.mfoa-quiz-meta { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 13px; color: var(--mfoa-muted); }
.mfoa-quiz-nivel { font-size: 11.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; padding: 4px 10px; border-radius: 999px; background: var(--mfoa-prova-bg); color: var(--mfoa-prova); }
.mfoa-quiz-barra { height: 6px; border-radius: 6px; background: #eef1f6; overflow: hidden; }
.mfoa-quiz-barra span { display: block; height: 100%; background: var(--mfoa-prova); transition: width .3s; }
.mfoa-modal .mfoa-quiz-perg { font-size: 18px; font-weight: 700; line-height: 1.45; }
.mfoa-quiz-ops { display: flex; flex-direction: column; gap: 10px; }
.mfoa-modal .mfoa-quiz-op {
  display: flex; gap: 12px; align-items: flex-start; text-align: left; width: 100%; padding: 14px 16px; border-radius: 12px;
  border: 1.5px solid var(--mfoa-border); background: #fff; font-size: 15px; line-height: 1.45; transition: all .15s;
}
.mfoa-modal .mfoa-quiz-op:hover:not(:disabled) { border-color: var(--mfoa-prova-b); background: var(--mfoa-prova-bg); }
.mfoa-quiz-letra { flex: 0 0 auto; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 13px; background: #eef1f6; color: var(--mfoa-head); }
.mfoa-modal .mfoa-quiz-op.mfoa-certa { border-color: var(--mfoa-ok); background: var(--mfoa-ok-bg); }
.mfoa-modal .mfoa-quiz-op.mfoa-certa .mfoa-quiz-letra { background: var(--mfoa-ok); color: #fff; }
.mfoa-modal .mfoa-quiz-op.mfoa-errada { border-color: var(--mfoa-dang); background: var(--mfoa-dang-bg); }
.mfoa-modal .mfoa-quiz-op.mfoa-errada .mfoa-quiz-letra { background: var(--mfoa-dang); color: #fff; }
.mfoa-modal .mfoa-quiz-op:disabled { cursor: default; }
.mfoa-quiz-exp { padding: 14px 16px; border-radius: 12px; background: var(--mfoa-bg-s); border-left: 4px solid var(--mfoa-prova); font-size: 14.5px; }
.mfoa-quiz-exp small { display: block; margin-top: 8px; color: var(--mfoa-muted); font-size: 12.5px; }
.mfoa-modal .mfoa-quiz-btn {
  align-self: flex-end; min-height: 46px; padding: 10px 22px; border-radius: 12px; background: var(--mfoa-prova); color: #fff; font-weight: 700; font-size: 15px;
}
.mfoa-modal .mfoa-quiz-btn:disabled { opacity: .4; cursor: not-allowed; }
.mfoa-quiz-placar { text-align: center; padding: 10px 0; }
.mfoa-quiz-placar strong { display: block; font-size: 44px; font-weight: 800; color: var(--mfoa-prova); line-height: 1.1; }
.mfoa-quiz-rev { display: flex; flex-direction: column; gap: 10px; }
.mfoa-quiz-rev > div { padding: 12px 14px; border-radius: 12px; border: 1px solid var(--mfoa-border); font-size: 14px; }
.mfoa-quiz-rev > div.mfoa-certa { border-color: var(--mfoa-ok-b); background: var(--mfoa-ok-bg); }
.mfoa-quiz-rev > div.mfoa-errada { border-color: var(--mfoa-dang-b); background: var(--mfoa-dang-bg); }

html.mfoa-trava, html.mfoa-trava body { overflow: hidden; }

/* =========================================================
   RESPONSIVO
   ========================================================= */
@media (max-width: 1100px) {
  .mfoa-page { grid-template-columns: minmax(0, 1fr) 236px; gap: 18px; }
  .mfoa-resumo { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mfoa-col-4, .mfoa-gal-n4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 900px) {
  .mfoa-page { grid-template-columns: 1fr; }
  .mfoa-side, .mfoa-resumo { display: none; }
  .mfoa-hero { padding: 28px 22px 24px; border-radius: 18px; }
  .mfoa-hero-sub { font-size: 15px; }
  .mfoa .mfoa-quickbtn {
    display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 48px; margin-bottom: 12px;
    border-radius: 14px; background: var(--mfoa-head); color: #fff; font-weight: 700; font-size: 15px;
  }
  .mfoa .mfoa-quickbtn i { color: var(--mfoa-pri-s); }
  .mfoa-tabs { display: flex; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .mfoa .mfoa-tab { flex: 0 0 156px; }
  .mfoa-rotas { grid-template-columns: minmax(0, 1fr); }
  .mfoa .mfoa-rota-head { min-height: 0; }
  .mfoa-tabs::-webkit-scrollbar { display: none; }
  .mfoa-figcard { grid-template-columns: 1fr; }
  .mfoa-col-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mfoa-essencial ol { grid-template-columns: 1fr; }
  .mfoa-passos-fluxo { flex-direction: column; gap: 8px; }
  .mfoa-passos-fluxo > li { padding: 10px 14px 10px 52px; }
  .mfoa-passos-fluxo > li::before { left: 12px; top: 50%; transform: translateY(-50%); }
  .mfoa-passos-fluxo .mfoa-passo-tit { margin-top: 0; }
  .mfoa-kv > div { grid-template-columns: minmax(0, 1fr); gap: 2px; }
}

@media (max-width: 700px) {
  .mfoa-card { padding: 18px 16px; border-radius: 14px; }
  .mfoa .mfoa-card-tit { font-size: 18px; }
  .mfoa-col-2, .mfoa-col-3, .mfoa-col-4 { grid-template-columns: 1fr; }
  .mfoa-galeria, .mfoa-gal-n4 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .mfoa-gal-n1 { grid-template-columns: 1fr; }
  .mfoa-gal-txt { padding: 10px 12px 12px; }

  /* tabelas viram cartões */
  .mfoa-tabela-wrap { border: 0; overflow: visible; }
  .mfoa-tabela, .mfoa-tabela tbody, .mfoa-tabela tr, .mfoa-tabela td { display: block; width: 100%; }
  .mfoa-tabela thead { display: none; }
  .mfoa-tabela tr { border: 1px solid var(--mfoa-border); border-radius: 12px; margin-bottom: 10px; overflow: hidden; background: #fff; }
  .mfoa-tabela tbody tr:nth-child(even) td { background: #fff; }
  .mfoa-tabela td { padding: 8px 14px; border-bottom: 1px solid var(--mfoa-border-l); }
  .mfoa-tabela td::before {
    content: attr(data-label); display: block; font-size: 11px; font-weight: 800; text-transform: uppercase;
    letter-spacing: .05em; color: var(--mfoa-muted); margin-bottom: 2px;
  }
  .mfoa-tabela td:first-child { background: var(--mfoa-bg-s); padding-top: 12px; }
  .mfoa-tabela tbody tr:nth-child(even) td:first-child { background: var(--mfoa-bg-s); }
  .mfoa-tabela td:first-child::before { display: none; }
  .mfoa-calc-item { grid-template-columns: 1fr; }
  .mfoa-calc-saida { text-align: left; }

  .mfoa-modal { padding: 0; align-items: flex-end; }
  .mfoa-caixa.mfoa-caixa-med { height: 92dvh; }
  .mfoa-caixa { max-height: 92vh; max-height: 92dvh; border-radius: 20px 20px 0 0; }
  .mfoa-pop, .mfoa-quiz { padding: 0 18px 22px; }
  .mfoa-pop-head { margin: 0 -18px; padding: 26px 104px 20px 18px; }
  .mfoa-medpop-head { padding: 16px 100px 12px 16px; }
  .mfoa-medpop-hl { margin: 12px 16px 0; }
  .mfoa-mtabs { padding: 8px 16px 0; }
  .mfoa-mpanes { padding: 16px 16px 20px; }
  .mfoa-rota-corpo { padding: 16px 14px 18px 18px; }
  .mfoa-ref { grid-template-columns: 1fr; gap: 8px; }
  .mfoa-dose-wrap { border: 0; overflow: visible; background: none; }
  .mfoa-dose-tab, .mfoa-dose-tab tbody { display: block; width: 100%; min-width: 0; }
  .mfoa-dose-tab thead { display: none; }
  .mfoa-dose-tab tbody { display: flex; flex-wrap: wrap; border: 1px solid var(--mfoa-border); border-radius: 14px; overflow: hidden; margin-bottom: 10px; background: #fff; }
  .mfoa-dose-tab tr { display: contents; }
  .mfoa-dose-tab td { display: block; padding: 8px 14px; border: 0; border-bottom: 1px solid #edf1f4; }
  .mfoa-dose-tab tbody + tbody tr:first-child td { border-top: 0; }
  .mfoa-dose-tab td.mfoa-dose-ind { order: 0; width: 100%; border-right: 0; padding: 11px 14px; }
  .mfoa-fichas { flex-direction: row; flex-wrap: wrap; }
  .mfoa-dose-tab td.mfoa-dose-main { order: 1; width: 100%; padding-bottom: 2px; border-bottom: 0; }
  .mfoa-dose-tab td.mfoa-dose-f, .mfoa-dose-tab td.mfoa-dose-d { order: 1; width: 50%; padding-top: 2px; }
  .mfoa-dose-tab td.mfoa-dose-obs { order: 2; width: 100%; border-left: 0; border-bottom: 0; }
  .mfoa-dose-tab td.mfoa-dose-f::before, .mfoa-dose-tab td.mfoa-dose-d::before, .mfoa-dose-tab td.mfoa-dose-obs::before {
    content: attr(data-label); display: block; font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; color: var(--mfoa-muted);
  }
  .mfoa-dose-main strong { font-size: 15px; }
  .mfoa-zoom { align-items: center; padding: 10px; }
  .mfoa-zoom .mfoa-caixa { border-radius: 14px; }
}

/* =========================================================
   COMPONENTES DO ATLAS (imagem principal, estrutura em destaque,
   visor, vídeo, imagem pendente, diferencial, registro)
   ========================================================= */

/* Imagem principal (Visão geral do modelo completo) */
.mfoa-principal { display: flex; flex-direction: column; gap: 8px; }
.mfoa .mfoa-principal .mfoa-fig-btn { border-radius: 18px; border: 1px solid var(--mfoa-border); background: #fff; }
.mfoa-principal .mfoa-fig-btn img { display: block; width: 100%; height: auto; max-height: 560px; object-fit: contain; background: #f4f7fa; transition: transform .3s; }
.mfoa-principal .mfoa-fig-btn:hover img { transform: scale(1.015); }
.mfoa-principal .mfoa-pend { min-height: 280px; }

/* "Principais achados" + "Estrutura em destaque" */
.mfoa-destaque { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 16px; align-items: start; }
.mfoa-destaque-pe { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: stretch; }
.mfoa-achados { margin: 0; padding: 0 0 0 4px; list-style: none; counter-reset: mfoaa; display: flex; flex-direction: column; gap: 8px; }
.mfoa-achados li { position: relative; padding-left: 34px; font-size: 14.5px; line-height: 1.55; counter-increment: mfoaa; }
.mfoa-achados li::before {
  content: counter(mfoaa); position: absolute; left: 0; top: 0; width: 24px; height: 24px; border-radius: 7px;
  display: grid; place-items: center; background: var(--mfoa-pri-l); color: var(--mfoa-pri-d); font-size: 12px; font-weight: 800;
}
.mfoa .mfoa-estrutura .mfoa-fig-btn { border: 1px solid var(--mfoa-border); background: #fff; }
.mfoa-estrutura .mfoa-fig-btn img { display: block; width: 100%; height: auto; }
.mfoa-estrutura p { font-size: 14px; }

/* Imagem / mídia genérica */
.mfoa .mfoa-fig-btn img, .mfoa-modal .mfoa-fig-btn img { display: block; width: 100%; height: auto; }

/* Imagem pendente: visitante vê ícone discreto; editor vê a descrição */
.mfoa-pend {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center;
  min-height: 190px; padding: 18px; border-radius: 14px; color: #8aa0b3; font-size: 12.5px; font-weight: 600;
  background: linear-gradient(135deg, var(--mfoa-pri-l), #f4f8fc); border: 1px solid var(--mfoa-border-l);
}
.mfoa-pend > i { font-size: 30px; color: #9fd6cf; }
.mfoa-pend-adm { border: 2px dashed #e3a634; background: #fffaf0; color: #7a5a14; align-items: stretch; text-align: left; }
.mfoa-pend-adm > i { color: #e3a634; align-self: center; }
.mfoa .mfoa-pend-adm strong, .mfoa-modal .mfoa-pend-adm strong { color: #7a4b00; text-align: center; font-size: 14px; display: block; }
.mfoa-pend-adm span { font-size: 12px; font-weight: 500; line-height: 1.5; }
.mfoa-pend-adm em { display: block; font-style: normal; font-weight: 500; font-size: 12.5px; line-height: 1.55; color: #4b3a12; background: #fff; border: 1px solid #f5dcaa; border-radius: 10px; padding: 8px 10px; }
.mfoa-pend-adm small { font-size: 10.5px; text-align: center; opacity: .8; }

/* Visor (imagem clínica ↔ esquema, com leitura guiada) */
.mfoa-visor { display: flex; flex-direction: column; gap: 12px; }
.mfoa-seg { display: inline-flex; align-self: flex-start; flex-wrap: wrap; gap: 4px; padding: 4px; background: var(--mfoa-bg-s); border: 1px solid var(--mfoa-border); border-radius: 12px; max-width: 100%; }
.mfoa .mfoa-seg-btn, .mfoa-modal .mfoa-seg-btn {
  display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: 9px;
  font-size: 12.8px; font-weight: 700; color: #64748b; transition: all .2s; white-space: nowrap;
}
.mfoa .mfoa-seg-btn:hover { color: var(--mfoa-pri-d); }
.mfoa .mfoa-seg-btn.mfoa-on { background: #fff; color: var(--mfoa-pri-dd); box-shadow: 0 2px 8px rgba(43, 76, 126, .12); }
.mfoa-vista { display: flex; flex-direction: column; gap: 10px; animation: mfoa-in .25s ease; }
.mfoa-vista[hidden] { display: none; }
.mfoa-visor-frame { position: relative; }
.mfoa .mfoa-visor-frame .mfoa-fig-btn { border-radius: 18px; border: 1px solid var(--mfoa-border); background: #fff; }
.mfoa-visor-frame .mfoa-fig-btn img { max-height: 600px; object-fit: contain; background: #f4f7fa; }
.mfoa-visor-frame .mfoa-pend { min-height: 260px; }
.mfoa-visor-tag {
  position: absolute; left: 14px; top: 14px; z-index: 2; background: rgba(15, 23, 42, .72); color: #fff; pointer-events: none;
  border-radius: 999px; padding: 5px 11px; font-size: 10.5px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase;
}
.mfoa-visor-cap { font-size: 13px; line-height: 1.6; color: var(--mfoa-muted); margin: 0; }
.mfoa-leitura { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; }
.mfoa-leitura-t { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--mfoa-navy); }
.mfoa-leitura-t i { color: var(--mfoa-pri); }
.mfoa-leitura-lista { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.mfoa-leitura-lista li { display: flex; gap: 11px; align-items: flex-start; background: var(--mfoa-bg-s); border: 1px solid var(--mfoa-border-l); border-radius: 12px; padding: 12px 13px; min-width: 0; }
.mfoa-leitura-n { flex: 0 0 auto; width: 24px; height: 24px; border-radius: 7px; background: var(--mfoa-pri); color: #fff; font-size: 11.5px; font-weight: 800; display: grid; place-items: center; }
.mfoa .mfoa-leitura-lista b { display: block; font-size: 13.5px; color: var(--mfoa-head); margin-bottom: 2px; }
.mfoa-leitura-lista span { display: block; font-size: 13px; line-height: 1.6; }
/* número do roteiro: centralizado (a regra acima também pega este span) */
.mfoa-leitura-lista .mfoa-leitura-n { display: grid; place-items: center; text-align: center; font-size: 11.5px; line-height: 1; }
/* texto que acompanha uma vista do visor (ex.: Estrutura em destaque no modelo completo) */
.mfoa-visor-txt { display: flex; flex-direction: column; gap: 8px; background: var(--mfoa-bg-s); border: 1px solid var(--mfoa-border-l); border-radius: 12px; padding: 12px 14px; }
.mfoa-visor-txt p { margin: 0; font-size: 14px; line-height: 1.65; }

/* Vídeo */
.mfoa-video { border-radius: 16px; overflow: hidden; background: #0b1622; border: 1px solid var(--mfoa-border); }
.mfoa-video video { display: block; width: 100%; max-height: 560px; background: #0b1622; }
.mfoa-fig-video .mfoa-pend { min-height: 220px; }

/* Galeria (fotos com legenda longa) */
.mfoa-gal-midia { position: relative; }
.mfoa-gal-midia .mfoa-pend { aspect-ratio: 4 / 3; min-height: 0; border-radius: 0; border: 0; }
.mfoa-gal-midia .mfoa-video { border-radius: 0; border: 0; }
.mfoa-gal-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.mfoa-gal-tags span { font-size: 11px; font-weight: 700; color: var(--mfoa-pri-dd); background: var(--mfoa-pri-l); border-radius: 7px; padding: 3px 8px; }
.mfoa-gal-n2 .mfoa-gal-txt p, .mfoa-gal-n1 .mfoa-gal-txt p { font-size: 13.8px; line-height: 1.6; }

/* Intro de aba */
.mfoa-intro { display: flex; gap: 12px; align-items: flex-start; padding: 14px 18px; border-radius: var(--mfoa-r-s); background: var(--mfoa-navy-l); border: 1px solid var(--mfoa-border); font-size: 14.5px; }
.mfoa-intro > i { color: var(--mfoa-navy); margin-top: 4px; }

/* Diagnóstico diferencial */
.mfoa-dif { border: 1px solid var(--mfoa-border); border-radius: 14px; overflow: hidden; background: #fff; }
.mfoa-dif-head, .mfoa-dif-row { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr) minmax(0, 1.3fr); }
.mfoa-dif-head span { padding: 11px 14px; background: var(--mfoa-bg-s); border-bottom: 1px solid var(--mfoa-border); font-size: 11.5px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--mfoa-muted); }
.mfoa-dif-row > div { padding: 12px 14px; border-bottom: 1px solid var(--mfoa-border-l); font-size: 14px; line-height: 1.55; min-width: 0; }
.mfoa-dif-row:last-child > div { border-bottom: 0; }
.mfoa-dif-row > div small { display: none; }
.mfoa-dif-nome { display: flex; gap: 10px; align-items: flex-start; background: #fbfdff; }
.mfoa-dif-nome > i { color: var(--mfoa-pri); margin-top: 4px; width: 16px; text-align: center; flex: 0 0 auto; }
.mfoa .mfoa-dif-nome a { font-weight: 700; color: var(--mfoa-pri-d); text-decoration: none; }
.mfoa-dif-nome a i { font-size: 10px; margin-left: 6px; }
.mfoa .mfoa-dif-nome a:hover { text-decoration: underline; }
.mfoa-dif-perigo .mfoa-dif-nome > i { color: var(--mfoa-dang); }
.mfoa-dif-atencao .mfoa-dif-nome > i { color: var(--mfoa-warn); }
.mfoa-dif-atual .mfoa-dif-nome { background: var(--mfoa-pri-l); }

/* Registro (modelo de prontuário) */
.mfoa-registro { border: 1px solid var(--mfoa-pri-b); border-radius: 14px; overflow: hidden; background: #fff; }
.mfoa-registro-head { display: flex; align-items: center; gap: 10px; padding: 10px 14px; background: var(--mfoa-pri-l); color: var(--mfoa-pri-dd); }
.mfoa-registro-head b { flex: 1; font-size: 14px; }
.mfoa .mfoa-copiar { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; padding: 6px 10px; border-radius: 8px; background: #fff; color: var(--mfoa-pri-dd); border: 1px solid var(--mfoa-pri-b); }
.mfoa .mfoa-copiar:hover { background: var(--mfoa-pri); color: #fff; }
.mfoa .mfoa-registro-txt { padding: 14px 16px; margin: 0; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13.5px; line-height: 1.7; color: var(--mfoa-head); }
.mfoa-registro-pe { display: flex; gap: 8px; padding: 10px 16px; border-top: 1px dashed var(--mfoa-border); font-size: 12.5px; color: var(--mfoa-muted); }
.mfoa-registro-pe i { color: var(--mfoa-pri); margin-top: 3px; }

/* Botão "Informações rápidas" (celular) e cards-resumo dentro do modal */
.mfoa-quick-resumo { display: flex; flex-direction: column; gap: 8px; }
.mfoa-modal .mfoa-quick-resumo button { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--mfoa-border); background: #fff; }
.mfoa-modal .mfoa-quick-resumo button:hover { border-color: var(--mfoa-pri-b); background: var(--mfoa-pri-l); }
.mfoa-quick-resumo button > i:first-child { flex: 0 0 auto; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; background: var(--mfoa-pri-l); color: var(--mfoa-pri); }
.mfoa-quick-resumo button > span { flex: 1; font-size: 13px; line-height: 1.45; }
.mfoa-quick-resumo button > span strong { display: block; font-size: 14px; }
.mfoa-quick-resumo button > i:last-child { color: var(--mfoa-muted); font-size: 11px; }
.mfoa-quick .mfoa-side-card { box-shadow: none; }
.mfoa .mfoa-quickbtn > span { flex: 1; text-align: left; }

/* Zoom: setas para navegar entre as imagens da aba */
.mfoa-zoom .mfoa-caixa { position: relative; }
.mfoa-zoom figure { margin: 0; }
.mfoa-modal .mfoa-zoom-nav {
  display: none; position: absolute; top: 50%; transform: translateY(-50%); z-index: 4; width: 44px; height: 44px; border-radius: 50%;
  place-items: center; background: rgba(255,255,255,.92); color: var(--mfoa-head); box-shadow: 0 2px 10px rgba(0,0,0,.25); font-size: 16px;
}
.mfoa-modal.mfoa-zoom-multi .mfoa-zoom-nav { display: grid; }
.mfoa-zoom-ant { left: 10px; }
.mfoa-zoom-prox { right: 10px; }

/* =========================================================
   RESPONSIVO DOS COMPONENTES DO ATLAS
   ========================================================= */
@media (max-width: 1100px) {
  .mfoa-destaque { grid-template-columns: minmax(0, 1fr) 280px; }
}
@media (max-width: 900px) {
  .mfoa .mfoa-quickbtn { justify-content: space-between; background: var(--mfoa-navy-l); color: var(--mfoa-navy); border: 1px solid var(--mfoa-border); font-weight: 800; font-size: 14px; padding: 0 16px; }
  .mfoa .mfoa-quickbtn i { color: var(--mfoa-pri); }
  .mfoa-destaque, .mfoa-destaque-pe { grid-template-columns: 1fr; }
  .mfoa-hero-ficha { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mfoa-leitura-lista { grid-template-columns: 1fr; }
  .mfoa .mfoa-tab { flex: 0 0 auto; min-width: 132px; padding: 10px 14px; }
}
@media (max-width: 700px) {
  .mfoa-hero { padding: 24px 18px 22px; }
  .mfoa-hero-tag { font-size: 10px; letter-spacing: .06em; }
  .mfoa-hero-ficha dd { font-size: 13px; }
  .mfoa-galeria.mfoa-gal-n2, .mfoa-galeria.mfoa-gal-n3 { grid-template-columns: 1fr; }
  .mfoa-dif-head { display: none; }
  .mfoa-dif-row { grid-template-columns: 1fr; border-bottom: 1px solid var(--mfoa-border); }
  .mfoa-dif-row:last-child { border-bottom: 0; }
  .mfoa-dif-row > div { border-bottom: 0; padding: 8px 14px; }
  .mfoa-dif-row > div:first-child { padding-top: 12px; }
  .mfoa-dif-row > div:last-child { padding-bottom: 14px; }
  .mfoa-dif-row > div small { display: block; font-size: 10.5px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--mfoa-muted); }
  .mfoa .mfoa-seg { display: flex; align-self: stretch; }
  .mfoa .mfoa-seg-btn { flex: 1 1 0; justify-content: center; padding: 8px; }
  .mfoa-modal .mfoa-zoom-nav { width: 38px; height: 38px; }
}
