/* DermRX · Formulación magistral v3 · hoja de estilos (vive dentro del Shadow DOM) */

:host {
  /* tokens — DermRX design system v3 (mismos que el Vademécum tópico v3) */
  --ink: #0b1a2b;
  --ink-2: #1e3a52;
  --muted: #5b6a7c;
  --muted-2: #8a97a6;
  --teal: #0d7a6b;
  --teal-dark: #095f54;
  --teal-bg: #eef8f6;
  --teal-line: #bfe0da;
  --paper: #f6f9fb;
  --paper-2: #eef2f6;
  --line: #e3eaf1;
  --line-2: #cfd9e3;
  --white: #fff;
  --green: #047857; --green-bg: #ecfdf5; --green-line: #a7f3d0;
  --amber: #8a5a00; --amber-bg: #fffaf0; --amber-line: #f5d78e;
  --red: #b91c1c;   --red-bg: #fef2f2;   --red-line: #fecaca;
  --blue: #1d4ed8;  --blue-bg: #eff6ff;  --blue-line: #bfdbfe;
  --plum: #7f1d3a;  --plum-bg: #fdf2f6;  --plum-line: #f3c3d4;
  --navy: #0f172a;
  --focus: #0d7a6b;
  --r-sm: 6px; --r-md: 10px; --r-lg: 14px;
  --sh-1: 0 1px 2px rgba(11, 26, 43, .06);
  --sh-2: 0 10px 30px rgba(11, 26, 43, .10);
  --sh-3: 0 24px 60px rgba(11, 26, 43, .22);
  --f-body: "Source Sans 3", "Segoe UI", system-ui, -apple-system, Helvetica, Arial, sans-serif;
  --f-head: Archivo, "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --f-mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  --rail-w: 272px;
  --top-offset: 0px;

  display: block;
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

*, *::before, *::after { box-sizing: border-box; }
h1, h2, h3, h4, p, ul, ol, dl, dd, figure, pre { margin: 0; }
ul, ol { padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; }
a { color: var(--teal-dark); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--teal); }
svg { display: inline-block; vertical-align: middle; flex: none; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }
kbd { font: 600 11px/1 var(--f-body); color: var(--muted); border: 1px solid var(--line-2); border-bottom-width: 2px; border-radius: 4px; padding: 3px 5px; background: var(--white); }
.num { font-variant-numeric: tabular-nums; }
mark { background: none; color: var(--teal-dark); font-weight: 700; }

/* ---------- cabecera ---------- */
.top { background: var(--white); border-bottom: 1px solid var(--line); }
.top__in { max-width: 1240px; margin: 0 auto; padding: 28px clamp(16px, 3vw, 32px) 22px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 20px 40px; align-items: start; }
.eyebrow { font: 600 12px/1 var(--f-head); letter-spacing: .13em; text-transform: uppercase; color: var(--teal-dark); }
.title { font: 800 clamp(26px, 3.6vw, 36px)/1.1 var(--f-head); letter-spacing: -.02em; margin-top: 8px; text-wrap: balance; }
.lede { color: var(--ink-2); font-size: 17px; margin-top: 8px; max-width: 64ch; }

.status { border: 1px solid var(--line); border-radius: var(--r-md); background: var(--paper); padding: 12px 14px; min-width: 320px; }
.status__row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 18px; }
.stat { display: flex; align-items: baseline; gap: 8px; font-size: 13px; color: var(--muted); white-space: nowrap; }
.stat b { font: 700 18px/1 var(--f-head); color: var(--ink); font-variant-numeric: tabular-nums; }
.stat i { width: 8px; height: 8px; border-radius: 50%; display: inline-block; transform: translateY(-1px); flex: none; }
.stat--all i { background: var(--ink-2); }
.stat--draft i { background: var(--green); }
.stat--review i { background: var(--amber); }
.stat--insuf i { background: var(--muted-2); }
.status__foot { display: flex; justify-content: space-between; gap: 12px; margin-top: 10px; padding-top: 8px; border-top: 1px dashed var(--line-2); font-size: 12.5px; color: var(--muted); }
.linkbtn { color: var(--teal-dark); text-decoration: underline; text-underline-offset: 2px; font-weight: 600; }
.linkbtn:hover { color: var(--teal); }

/* búsqueda */
.search { grid-column: 1 / -1; position: relative; max-width: 900px; }
.search__box { display: flex; align-items: center; gap: 8px; background: var(--white); border: 2px solid var(--ink); border-radius: var(--r-lg); padding: 5px 8px 5px 14px; box-shadow: var(--sh-2); }
.search__box:focus-within { border-color: var(--teal); box-shadow: 0 0 0 4px rgba(13, 122, 107, .15), var(--sh-2); }
.search__box svg { color: var(--muted); }
.search__box input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 10px 4px; font-size: 18px; outline: 0; }
.search__box input::placeholder { color: var(--muted-2); }
.search__box input::-webkit-search-cancel-button { display: none; }
.iconbtn { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 8px; color: var(--muted); }
.iconbtn:hover { background: var(--paper-2); color: var(--ink); }
.iconbtn[aria-pressed="true"] { color: var(--amber); }
.search__go { background: var(--teal); color: var(--white); font: 700 15px/1 var(--f-head); padding: 0 18px; height: 40px; border-radius: 9px; }
.search__go:hover { background: var(--teal-dark); }
.search__hint { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 10px; font-size: 14px; color: var(--muted); }
.search__hint span { margin-right: 4px; }
.qchip { border: 1px solid var(--line-2); background: var(--white); border-radius: 999px; padding: 4px 11px; font-size: 13.5px; font-weight: 600; color: var(--ink-2); }
.qchip:hover { border-color: var(--teal); color: var(--teal-dark); background: var(--teal-bg); }

/* sugerencias */
.sugg { position: absolute; left: 0; right: 0; top: calc(100% - 44px); z-index: 30; background: var(--white); border: 1px solid var(--line-2); border-radius: var(--r-md); box-shadow: var(--sh-3); padding: 6px; max-height: min(60vh, 480px); overflow: auto; }
.sugg__group { font: 600 11px/1 var(--f-head); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); padding: 10px 10px 6px; }
.sugg__item { display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 8px 10px; border-radius: 8px; color: var(--ink); }
.sugg__item:hover, .sugg__item[aria-selected="true"] { background: var(--teal-bg); }
.sugg__item svg { color: var(--muted); }
.sugg__item b { font-weight: 600; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sugg__item small { display: block; color: var(--muted); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sugg__item .cnt { font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }

/* aviso editorial bajo la cabecera */
.gate { max-width: 1240px; margin: 0 auto; padding: 14px clamp(16px, 3vw, 32px) 0; }
.gate__in { display: flex; gap: 10px; align-items: flex-start; background: var(--amber-bg); border: 1px solid var(--amber-line); color: var(--ink-2); border-radius: var(--r-md); padding: 10px 14px; font-size: 14px; }
.gate__in svg { flex: none; color: var(--amber); margin-top: 2px; }
.gate__in b { color: var(--amber); }

/* ---------- cuerpo ---------- */
.body { max-width: 1240px; margin: 0 auto; padding: 18px clamp(16px, 3vw, 32px) 24px; display: grid; grid-template-columns: var(--rail-w) minmax(0, 1fr); gap: 24px; align-items: start; }

/* rail de filtros */
.rail { position: sticky; top: calc(var(--top-offset) + 12px); max-height: calc(100vh - var(--top-offset) - 24px); overflow: auto; background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 4px 0 8px; scrollbar-width: thin; }
.rail__head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px 8px; }
.rail__head h2 { font: 700 15px/1 var(--f-head); }
.rail__close { display: none; }
.facet { border-top: 1px solid var(--line); }
.facet > summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; font: 700 13.5px/1.2 var(--f-head); color: var(--ink-2); user-select: none; }
.facet > summary::-webkit-details-marker { display: none; }
.facet > summary .chev { transition: transform .15s; color: var(--muted); }
.facet[open] > summary .chev { transform: rotate(180deg); }
.facet > summary .on { font: 700 11px/1 var(--f-body); color: var(--white); background: var(--teal); border-radius: 999px; padding: 3px 7px; margin-left: auto; margin-right: 8px; }
.facet__body { padding: 0 8px 10px; }
.facet__hint { font-size: 12.5px; color: var(--muted); padding: 0 6px 6px; line-height: 1.35; }
.opt { display: flex; align-items: center; gap: 8px; padding: 5px 6px; border-radius: 6px; font-size: 14px; cursor: pointer; }
.opt:hover { background: var(--paper); }
.opt input { accent-color: var(--teal); width: 15px; height: 15px; margin: 0; flex: none; cursor: pointer; }
.opt span { flex: 1; min-width: 0; line-height: 1.25; }
.opt .cnt { color: var(--muted); font-size: 12.5px; font-variant-numeric: tabular-nums; flex: none; }
.opt.is-zero { color: var(--muted-2); }
.opt.is-zero .cnt { color: var(--muted-2); }
.opt--top { margin-top: 4px; border-top: 1px dashed var(--line); padding-top: 8px; }
.facet__more { color: var(--teal-dark); font-weight: 600; font-size: 13px; padding: 6px; }
.facet__search { width: calc(100% - 12px); border: 1px solid var(--line-2); border-radius: 7px; padding: 6px 9px; font-size: 13.5px; margin: 2px 6px 6px; background: var(--white); }
.facet__search:focus { border-color: var(--teal); outline: 0; box-shadow: 0 0 0 3px rgba(13,122,107,.15); }
.rail__actions { padding: 10px 14px 4px; display: flex; gap: 8px; flex-wrap: wrap; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border-radius: 8px; padding: 8px 14px; font: 600 14px/1.2 var(--f-body); border: 1px solid transparent; white-space: nowrap; }
.btn--primary { background: var(--teal); color: var(--white); }
.btn--primary:hover { background: var(--teal-dark); }
.btn--ghost { border-color: var(--line-2); background: var(--white); color: var(--ink-2); }
.btn--ghost:hover { border-color: var(--teal); color: var(--teal-dark); background: var(--teal-bg); }
.btn--quiet { color: var(--teal-dark); }
.btn--quiet:hover { background: var(--teal-bg); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn .n { background: rgba(255,255,255,.22); border-radius: 999px; padding: 1px 7px; font-size: 12px; font-variant-numeric: tabular-nums; }
.btn--ghost .n { background: var(--paper-2); color: var(--ink-2); }

/* toolbar */
.main { min-width: 0; }
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-bottom: 12px; }
.count { font-size: 15px; color: var(--ink-2); }
.count b { color: var(--ink); font-variant-numeric: tabular-nums; }
.toolbar__right { margin-left: auto; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sel { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; color: var(--muted); }
.sel select { border: 1px solid var(--line-2); border-radius: 7px; padding: 6px 28px 6px 9px; background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%235b6a7c' stroke-width='2.5'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E") no-repeat right 9px center; appearance: none; font-size: 13.5px; color: var(--ink); }
.seg { display: inline-flex; border: 1px solid var(--line-2); border-radius: 8px; overflow: hidden; background: var(--white); }
.seg button { display: inline-flex; align-items: center; gap: 6px; padding: 6px 11px; font-size: 13.5px; font-weight: 600; color: var(--muted); }
.seg button + button { border-left: 1px solid var(--line-2); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--white); }
.filterbtn { display: none; }

.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.chip { display: inline-flex; align-items: center; gap: 6px; background: var(--teal-bg); border: 1px solid var(--teal-line); color: var(--teal-dark); border-radius: 999px; padding: 4px 6px 4px 11px; font-size: 13px; font-weight: 600; }
.chip small { font-weight: 400; color: var(--muted); }
.chip button { display: inline-flex; width: 20px; height: 20px; border-radius: 50%; align-items: center; justify-content: center; color: var(--teal-dark); }
.chip button:hover { background: var(--white); }
.chip--clear { background: transparent; border-color: transparent; text-decoration: underline; padding-right: 11px; }

.notice { display: flex; gap: 10px; align-items: flex-start; background: var(--amber-bg); border: 1px solid var(--amber-line); color: var(--amber); border-radius: var(--r-md); padding: 10px 14px; font-size: 14px; margin-bottom: 12px; }
.notice svg { flex: none; margin-top: 2px; }
.notice--info { background: var(--blue-bg); border-color: var(--blue-line); color: var(--blue); }
.notice div { color: var(--ink-2); }
.notice b { color: inherit; }

/* ---------- tarjetas ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px 16px 12px; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto auto auto auto 1fr auto; gap: 8px; min-height: 100%; box-shadow: var(--sh-1); transition: box-shadow .15s, border-color .15s; position: relative; }
.card:hover { border-color: var(--teal-line); box-shadow: var(--sh-2); }
.card--cr { border-color: var(--green-line); }
.card--cmp { border-color: var(--teal); box-shadow: 0 0 0 2px var(--teal-line); }
.card__row { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; min-height: 24px; }
.card__row .iconbtn { margin-left: auto; width: 30px; height: 30px; }
.card__title { font: 700 16px/1.25 var(--f-head); letter-spacing: -.01em; text-align: left; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; text-wrap: pretty; }
.card__title:hover { color: var(--teal-dark); }
.card__title::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.card__meta { font-size: 13px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 6px; margin-top: -4px; }
.card__meta span + span::before { content: "·"; margin-right: 6px; color: var(--line-2); }
.tags { display: flex; flex-wrap: wrap; gap: 5px; position: relative; z-index: 1; }
.tag { font-size: 12px; font-weight: 600; border-radius: 6px; padding: 2px 8px; border: 1px solid transparent; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.tag--ind { background: var(--teal-bg); border-color: var(--teal-line); color: var(--teal-dark); }
.tag--act { background: var(--paper-2); border-color: var(--line); color: var(--ink-2); }
.tag--more { background: transparent; color: var(--muted); border-color: var(--line-2); }
.tag--btn { cursor: pointer; }
.tag--btn:hover { border-color: var(--teal); color: var(--teal-dark); }

/* composición */
.comp { border: 1px solid var(--line); border-left: 3px solid var(--teal-line); border-radius: 8px; padding: 8px 10px; background: var(--paper); font-size: 14px; color: var(--ink-2); position: relative; z-index: 1; }
.comp small { display: flex; justify-content: space-between; gap: 8px; font: 600 11px/1 var(--f-head); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 5px; }
.comp small em { font-style: normal; letter-spacing: .04em; text-transform: none; color: var(--teal-dark); font-weight: 600; }
.comp li { display: flex; gap: 8px; align-items: baseline; line-height: 1.35; padding: 1px 0; }
.comp li::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--teal); flex: none; transform: translateY(-2px); }
.comp li b { font-weight: 600; color: var(--ink); }
.comp__foot { margin-top: 5px; padding-top: 5px; border-top: 1px dashed var(--line-2); font-size: 12.5px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 2px 12px; }
.comp__foot b { color: var(--ink-2); font-weight: 600; }
.comp--more { color: var(--muted); font-size: 12.5px; }

/* variantes (dosis / presentación) */
.vars { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; position: relative; z-index: 1; }
.vars small { font: 600 11px/1 var(--f-head); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-right: 2px; }
.var { border: 1px solid var(--line-2); background: var(--white); border-radius: 6px; padding: 2px 8px; font-size: 12.5px; font-weight: 600; color: var(--ink-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.var:hover { border-color: var(--teal); color: var(--teal-dark); }
.var[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--white); }
.var--more { color: var(--teal-dark); border-style: dashed; }

.pauta { border-left: 3px solid var(--teal-line); padding: 2px 0 2px 10px; font-size: 14px; color: var(--ink-2); align-self: start; }
.pauta small { display: block; font: 600 11px/1 var(--f-head); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.pauta p { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pauta--ind { border-left-color: var(--amber-line); }
.pauta--ind small { color: var(--amber); }
.card__foot { display: flex; align-items: center; gap: 4px; border-top: 1px solid var(--line); padding-top: 8px; margin-top: 2px; position: relative; z-index: 1; }
.card__foot .btn { padding: 5px 10px; font-size: 13.5px; }
.card__foot .iconbtn { width: 30px; height: 30px; }
.card__foot .iconbtn[aria-pressed="true"] { color: var(--teal); background: var(--teal-bg); }
.card__foot .spacer { flex: 1; }
.card__foot .lock { color: var(--muted); font-size: 12.5px; display: inline-flex; align-items: center; gap: 4px; }

/* pastillas de estado */
.pill { display: inline-flex; align-items: center; gap: 5px; font: 600 12px/1 var(--f-body); letter-spacing: 0; border-radius: 999px; padding: 4px 8px; border: 1px solid transparent; white-space: nowrap; }
.pill i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; display: inline-block; }
.pill--draft { color: var(--green); background: var(--green-bg); border-color: var(--green-line); }
.pill--review { color: var(--amber); background: var(--amber-bg); border-color: var(--amber-line); }
.pill--insufficient { color: var(--muted); background: var(--paper-2); border-color: var(--line-2); }
.pill--specialized { color: var(--blue); background: var(--blue-bg); border-color: var(--blue-line); }
.pill--individual { color: var(--teal-dark); background: var(--teal-bg); border-color: var(--teal-line); }
.pill--nonpref { color: var(--red); background: var(--red-bg); border-color: var(--red-line); }
.pill--cr { color: var(--white); background: var(--green); border-color: var(--green); }
.pill--new { color: var(--plum); background: var(--plum-bg); border-color: var(--plum-line); }
.reg { display: inline-flex; align-items: center; font: 700 10.5px/1 var(--f-head); letter-spacing: .08em; text-transform: uppercase; border-radius: 4px; padding: 4px 6px; border: 1px solid var(--line-2); color: var(--muted); background: var(--white); white-space: nowrap; }
.reg--mono { color: var(--ink-2); }
.reg--assoc { color: var(--navy); border-color: var(--navy); }
.reg--complex { background: var(--navy); border-color: var(--navy); color: var(--white); }
.reg--alt { color: var(--blue); border-color: var(--blue-line); background: var(--blue-bg); }
.reg--pt { color: var(--plum); border-color: var(--plum-line); background: var(--plum-bg); }

/* ---------- tabla ---------- */
.tablewrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--white); }
.table { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 980px; }
.table th { position: sticky; top: 0; background: var(--paper); text-align: left; font: 700 12px/1.2 var(--f-head); letter-spacing: .05em; text-transform: uppercase; color: var(--muted); padding: 10px 10px; border-bottom: 1px solid var(--line-2); white-space: nowrap; z-index: 1; }
.table th button { font: inherit; color: inherit; display: inline-flex; align-items: center; gap: 4px; text-transform: inherit; letter-spacing: inherit; }
.table th button:hover { color: var(--ink); }
.table th[aria-sort] button { color: var(--teal-dark); }
.table td { padding: 9px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table tr:hover td { background: var(--paper); }
.table tr.is-cr td:first-child { box-shadow: inset 3px 0 0 var(--green); }
.table .t-name { font-weight: 700; color: var(--ink); text-align: left; font-family: var(--f-head); font-size: 14px; line-height: 1.25; }
.table .t-name:hover { color: var(--teal-dark); }
.table .t-sub { color: var(--muted); font-size: 12.5px; }
.table .t-comp { min-width: 220px; max-width: 300px; color: var(--ink-2); }
.table .t-comp div { line-height: 1.3; }
.table .t-pauta { max-width: 240px; min-width: 180px; color: var(--ink-2); }
.table .t-act { white-space: nowrap; }
.table .t-act .iconbtn { width: 28px; height: 28px; }
.table .t-act .iconbtn[aria-pressed="true"] { color: var(--teal); background: var(--teal-bg); }
.table .tags { gap: 3px; }
.table .tag { font-size: 11.5px; padding: 1px 6px; }

/* paginación / estados */
.more { display: flex; flex-direction: column; align-items: center; gap: 8px; margin: 20px 0 8px; color: var(--muted); font-size: 14px; }
.more .bar { width: 240px; height: 4px; border-radius: 2px; background: var(--paper-2); overflow: hidden; }
.more .bar i { display: block; height: 100%; background: var(--teal); }
.empty { text-align: center; padding: 48px 20px; background: var(--white); border: 1px dashed var(--line-2); border-radius: var(--r-md); color: var(--muted); }
.empty h3 { font: 700 18px/1.3 var(--f-head); color: var(--ink); margin-bottom: 6px; }
.empty .btn { margin-top: 14px; }
.skel { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.skel div { height: 250px; border-radius: var(--r-md); background: linear-gradient(90deg, var(--paper-2) 25%, var(--white) 50%, var(--paper-2) 75%); background-size: 200% 100%; animation: sh 1.2s infinite linear; }
@keyframes sh { to { background-position: -200% 0; } }
.error { background: var(--red-bg); border: 1px solid var(--red-line); color: var(--red); border-radius: var(--r-md); padding: 14px 16px; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--ink); color: var(--white); padding: 10px 16px; border-radius: 10px; font-size: 14px; box-shadow: var(--sh-3); z-index: 100; max-width: min(92vw, 520px); opacity: 0; transition: opacity .2s; pointer-events: none; }
.toast.is-on { opacity: 1; }

/* ---------- secciones editoriales (bajo los resultados) ---------- */
.editorial { max-width: 1240px; margin: 0 auto; padding: 8px clamp(16px, 3vw, 32px) 28px; display: grid; gap: 28px; }
.esec { border-top: 1px solid var(--line); padding-top: 22px; }
.esec__head { display: grid; gap: 4px; margin-bottom: 14px; }
.esec__head h2 { font: 800 22px/1.2 var(--f-head); letter-spacing: -.015em; }
.esec__head p { color: var(--muted); font-size: 14.5px; max-width: 70ch; }
.ecards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.ecards--flow { display: block; columns: 3; column-gap: 12px; }
.ecards--flow .ecard { break-inside: avoid; margin-bottom: 12px; }
.ecard { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px 16px; display: grid; gap: 8px; align-content: start; font-size: 14.5px; color: var(--ink-2); }
.ecard h3 { font: 700 16px/1.25 var(--f-head); color: var(--ink); }
.ecard .kick { font: 600 11px/1 var(--f-head); letter-spacing: .12em; text-transform: uppercase; color: var(--teal-dark); }
.ecard p b, .ecard p strong { color: var(--ink); font-weight: 600; }
.ecard .refs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.ecard .refs a { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; text-decoration: none; border: 1px solid var(--line-2); border-radius: 999px; padding: 3px 10px; background: var(--paper); }
.ecard .refs a:hover { border-color: var(--teal); background: var(--teal-bg); }
.ecard > a.more-link { font-weight: 600; text-decoration: none; margin-top: auto; }
.ecard > a.more-link:hover { text-decoration: underline; }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; counter-reset: step; }
.step { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px 16px 14px 52px; position: relative; font-size: 14.5px; color: var(--ink-2); }
.step::before { counter-increment: step; content: counter(step); position: absolute; left: 14px; top: 13px; width: 26px; height: 26px; border-radius: 50%; background: var(--teal-bg); border: 1px solid var(--teal-line); color: var(--teal-dark); font: 800 13px/24px var(--f-head); text-align: center; }
.step h3 { font: 700 15px/1.3 var(--f-head); color: var(--ink); margin-bottom: 4px; }
.faq { display: grid; gap: 8px; max-width: 900px; }
.faq details { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 0 16px; }
.faq summary { cursor: pointer; padding: 12px 0; font: 700 15px/1.3 var(--f-head); color: var(--ink); list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 700 18px/1 var(--f-head); color: var(--teal-dark); flex: none; }
.faq details[open] summary::after { content: "–"; }
.faq details p { padding: 0 0 14px; font-size: 14.5px; color: var(--ink-2); }
.faq details p b, .faq details p strong { color: var(--ink); font-weight: 600; }
.efoot { color: var(--muted); font-size: 13px; line-height: 1.55; }
.efoot b { color: var(--ink-2); }
.foot { max-width: 1240px; margin: 0 auto; padding: 8px clamp(16px, 3vw, 32px) 28px; color: var(--muted); font-size: 13px; line-height: 1.55; border-top: 1px solid var(--line); }
.foot b { color: var(--ink-2); }

/* ---------- panel de ficha (drawer) ---------- */
.scrim { position: fixed; inset: 0; background: rgba(11, 26, 43, .45); z-index: 60; opacity: 0; transition: opacity .18s; }
.scrim.is-on { opacity: 1; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(680px, 100vw); background: var(--white); z-index: 61; display: grid; grid-template-rows: auto 1fr auto; box-shadow: var(--sh-3); transform: translateX(100%); transition: transform .22s ease; outline: 0; }
.drawer.is-on { transform: none; }
@media (prefers-reduced-motion: reduce) { .drawer, .scrim { transition: none; } .skel div { animation: none; } }
.drawer__head { padding: 14px 18px 12px; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: start; }
.drawer__nav { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13px; }
.drawer__nav .iconbtn { width: 30px; height: 30px; }
.drawer__title { font: 800 21px/1.2 var(--f-head); letter-spacing: -.015em; margin-top: 6px; text-wrap: balance; }
.drawer__title:focus-visible { outline: none; }
.drawer__sub { color: var(--muted); font-size: 14.5px; margin-top: 2px; }
.drawer__sub b { color: var(--ink-2); font-weight: 600; }
.drawer__badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.drawer__vars { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 5px; padding-top: 8px; border-top: 1px dashed var(--line); }
.drawer__vars small { font: 600 11px/1 var(--f-head); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-right: 4px; }
.drawer__body { overflow: auto; padding: 16px 18px 24px; scroll-behavior: smooth; }
.drawer__foot { border-top: 1px solid var(--line); padding: 10px 18px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; background: var(--paper); }
.drawer__foot .spacer { flex: 1; }
.drawer__foot small { flex-basis: 100%; color: var(--muted); font-size: 12.5px; line-height: 1.4; }
.drawer__foot .btn--link { text-decoration: none; }

.sec { margin-bottom: 18px; }
.sec h3 { font: 700 12px/1 var(--f-head); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; display: flex; align-items: center; gap: 8px; }
.sec h3::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.sec h3 .cnt { font: 600 12px/1 var(--f-body); letter-spacing: 0; text-transform: none; color: var(--muted); }
.summ { background: var(--teal-bg); border: 1px solid var(--teal-line); border-radius: var(--r-md); padding: 12px 14px; display: grid; gap: 10px; }
.summ--ind { background: var(--amber-bg); border-color: var(--amber-line); }
.summ dt { font: 700 11px/1 var(--f-head); letter-spacing: .1em; text-transform: uppercase; color: var(--teal-dark); margin-bottom: 3px; }
.summ--ind dt { color: var(--amber); }
.summ dd { font-size: 15px; color: var(--ink); }
.summ .main-dd { font-size: 17px; font-weight: 600; }
.summ__foot { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; font-size: 12.5px; color: var(--muted); padding-top: 6px; border-top: 1px dashed var(--teal-line); }
.summ--ind .summ__foot { border-top-color: var(--amber-line); }
.compx { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; }
.compx table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.compx td { padding: 8px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.compx tr:last-child td { border-bottom: 0; }
.compx td:first-child { width: 26px; color: var(--teal); font-weight: 700; text-align: center; padding-right: 0; }
.compx td b { font-weight: 600; color: var(--ink); }
.compx .kvrow td { background: var(--paper); color: var(--ink-2); font-size: 14px; }
.compx .kvrow td:first-child { color: var(--muted); }
.note { border-left: 3px solid var(--amber-line); background: var(--amber-bg); padding: 10px 12px; border-radius: 0 8px 8px 0; font-size: 14.5px; color: var(--ink-2); }
.note b { color: var(--amber); font-weight: 700; font-family: var(--f-head); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; display: block; margin-bottom: 4px; }
.note--red { border-left-color: var(--red-line); background: var(--red-bg); }
.note--red b { color: var(--red); }
.note--green { border-left-color: var(--green-line); background: var(--green-bg); }
.note--green b { color: var(--green); }
.note p + p { margin-top: 6px; }
.kv { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 6px 12px; font-size: 14.5px; }
.kv dt { color: var(--muted); font-size: 13px; padding-top: 2px; }
.kv dd { color: var(--ink); }
.list { display: grid; gap: 5px; font-size: 14.5px; color: var(--ink-2); }
.list li { padding-left: 14px; position: relative; }
.list li::before { content: ""; position: absolute; left: 0; top: 10px; width: 5px; height: 5px; border-radius: 50%; background: var(--teal-line); }
.list--warn li::before { background: var(--amber-line); }
.list--red li::before { background: var(--red-line); }
.src { display: grid; gap: 6px; font-size: 14px; }
.src a { display: inline-flex; align-items: flex-start; gap: 5px; }
.src .muted { color: var(--muted); font-size: 13px; }
.src .muted b { color: var(--ink-2); font-weight: 600; }
details.acc { border: 1px solid var(--line); border-radius: 8px; padding: 0 12px; }
details.acc summary { cursor: pointer; padding: 9px 0; font-weight: 600; font-size: 14px; color: var(--ink-2); list-style: none; display: flex; align-items: center; justify-content: space-between; }
details.acc summary::-webkit-details-marker { display: none; }
details.acc[open] summary { border-bottom: 1px solid var(--line); }
details.acc .acc__body { padding: 10px 0 12px; font-size: 14px; color: var(--ink-2); display: grid; gap: 8px; }
.rx { background: var(--paper); border: 1px solid var(--line-2); border-radius: 8px; padding: 10px 12px; font: 13px/1.45 var(--f-mono); color: var(--ink-2); white-space: pre-wrap; word-break: break-word; max-height: 320px; overflow: auto; }
.rx__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.rx__head .btn { padding: 5px 10px; font-size: 13.5px; }
.rx__actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.rx__actions .btn { padding: 5px 10px; font-size: 13.5px; }
.rx__note { margin-top: 8px; font-size: 13px; color: var(--muted); line-height: 1.45; }
.gatebox { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line-2); background: var(--paper); border-radius: var(--r-md); padding: 10px 12px; font-size: 14px; color: var(--ink-2); }
.gatebox svg { flex: none; color: var(--muted); margin-top: 2px; }
.gatebox b { color: var(--ink); }

/* diálogos (comparar, metodología) */
dialog { border: 0; padding: 0; background: var(--white); color: var(--ink); border-radius: var(--r-lg); box-shadow: var(--sh-3); width: min(1100px, calc(100vw - 32px)); max-height: calc(100vh - 40px); font-family: var(--f-body); }
dialog::backdrop { background: rgba(11, 26, 43, .5); }
dialog.dlg--narrow { width: min(720px, calc(100vw - 32px)); }
.dlg__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.dlg__head h2 { font: 800 19px/1.2 var(--f-head); }
.dlg__body { padding: 16px 18px 20px; overflow: auto; max-height: calc(100vh - 130px); }
.dlg__body p { margin-bottom: 10px; color: var(--ink-2); }
.dlg__body .kv { margin: 12px 0 16px; grid-template-columns: 200px minmax(0, 1fr); }
.cmp { width: 100%; border-collapse: collapse; font-size: 14px; }
.cmp th, .cmp td { border: 1px solid var(--line); padding: 8px 10px; vertical-align: top; text-align: left; }
.cmp th[scope="row"] { width: 150px; background: var(--paper); font: 700 12px/1.3 var(--f-head); letter-spacing: .05em; text-transform: uppercase; color: var(--muted); position: sticky; left: 0; }
.cmp thead th { background: var(--paper); font: 700 14px/1.25 var(--f-head); color: var(--ink); vertical-align: top; }
.cmp thead th small { display: block; font: 400 12.5px/1.3 var(--f-body); color: var(--muted); margin-top: 2px; }
.cmp thead th .iconbtn { width: 26px; height: 26px; float: right; }
.cmp tr.is-same td { color: var(--muted); }
.cmp td.is-diff { background: var(--amber-bg); }
.cmp .empty-cell { color: var(--muted-2); }
.cmp td div + div { margin-top: 2px; }
.cmpwrap { overflow: auto; }

/* ---------- responsive ---------- */
@media (max-width: 1023px) {
  .ecards--flow { columns: 2; }
  .body { grid-template-columns: minmax(0, 1fr); }
  .rail { position: fixed; inset: auto 0 0 0; top: auto; max-height: 86vh; border-radius: 16px 16px 0 0; z-index: 62; transform: translateY(105%); transition: transform .22s ease; box-shadow: var(--sh-3); padding-bottom: 16px; }
  .rail.is-open { transform: none; }
  .rail__close { display: inline-flex; }
  .filterbtn { display: inline-flex; }
  .rail__actions { position: sticky; bottom: 0; background: var(--white); padding: 12px 14px; border-top: 1px solid var(--line); }
}
@media (max-width: 760px) {
  .top__in { grid-template-columns: minmax(0, 1fr); gap: 14px; padding-top: 18px; padding-bottom: 14px; }
  .search { order: 2; }
  .status { order: 3; min-width: 0; }
  .status__row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stat { white-space: normal; flex-wrap: wrap; }
  .stat--all { grid-column: 1 / -1; }
  .drawer__foot { padding: 8px 12px; gap: 6px; }
  .drawer__foot .btn { padding: 7px 10px; font-size: 13.5px; }
  .drawer__foot small { display: none; }
  .search__box kbd { display: none; }
  .lede { font-size: 15.5px; }
  .search__box input { font-size: 16px; }
  .search__go { display: none; }
  .search__hint span { display: none; }
  .grid { grid-template-columns: minmax(0, 1fr); }
  .toolbar__right { margin-left: 0; width: 100%; }
  .drawer { width: 100vw; }
  .drawer__head { padding: 12px 14px; }
  .drawer__body { padding: 14px; }
  .kv { grid-template-columns: minmax(0, 1fr); gap: 2px 0; }
  .kv dt { margin-top: 6px; }
  .cmp th[scope="row"] { width: 110px; }
  .esec__head h2 { font-size: 20px; }
  .ecards--flow { columns: 1; }
}


/* ---------- v3.1 · tabla compacta y sin cortes de palabra ---------- */
.table { table-layout: fixed; min-width: 860px; }
.table th, .table td { word-break: normal; overflow-wrap: break-word; hyphens: manual; -webkit-hyphens: manual; }
.table th:nth-child(1) { width: 21%; }
.table th:nth-child(2) { width: 14%; }
.table th:nth-child(3) { width: 12%; }
.table th:nth-child(4) { width: 12%; }
.table th:nth-child(5) { width: 19%; }
.table th:nth-child(6) { width: 17%; }
.table th:nth-child(7) { width: 72px; }
.table td { padding: 10px 10px; line-height: 1.35; }
.table .t-comp, .table .t-pauta { min-width: 0; max-width: none; }
.table .t-comp > div:not(.t-sub) { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.table .t-comp .t-sub { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 2px; }
.table .t-clamp { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.table .t-pauta .t-sub { margin-top: 3px; font-size: 11.5px; }
.table td:nth-child(3) .t-sub { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.table .tag { max-width: 100%; }
.table .tags { flex-wrap: wrap; }
.table td:first-child .tags { margin-top: 6px !important; }

.table .t-du { margin-top: 4px; font-size: 12px; line-height: 1.35; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.table .t-du b, .pauta__du b { font-weight: 700; color: var(--teal-dark); }
.pauta .pauta__du { margin-top: 6px; font-size: 13.5px; line-height: 1.45; color: var(--ink-2); }


/* ---- v3.2 · Formulario DermRX ---------------------------------------------- */
.modebar { max-width: 1240px; margin: 0 auto; padding: 16px clamp(16px, 3vw, 32px) 0; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; }
.modes { display: inline-flex; background: var(--white); border: 1px solid var(--line-2); border-radius: 999px; padding: 3px; box-shadow: var(--sh-1); }
.modes button { display: inline-flex; align-items: center; gap: 8px; border-radius: 999px; padding: 8px 16px; font: 700 14px/1 var(--f-head); color: var(--ink-2); }
.modes button[aria-selected="true"] { background: var(--ink); color: var(--white); }
.modes button .n { font: 700 11px/1 var(--f-body); background: var(--paper-2); color: var(--ink-2); border-radius: 999px; padding: 3px 7px; }
.modes button[aria-selected="true"] .n { background: rgba(255,255,255,.18); color: var(--white); }
.modebar__hint { margin: 0; font-size: 13.5px; color: var(--muted); }
.body.is-form, .app .body.is-form, .fmw-app .body.is-form { grid-template-columns: minmax(0, 1fr) !important; }
.body.is-form .rail, .body.is-form .rail[hidden] { display: none !important; }
.stat--fx i { background: var(--teal); }
.fx__head { display: flex; flex-wrap: wrap; gap: 14px 24px; align-items: flex-end; justify-content: space-between; margin-bottom: 14px; }
.fx__intro { max-width: 72ch; }
.fx__title { font: 800 24px/1.15 var(--f-head); margin: 0 0 6px; color: var(--ink); }
.fx__intro p, .app .fx__intro p { margin: 0; color: var(--ink-2); font-size: 15px !important; }
.fxbox p, .app .fxbox p { font-size: 14px !important; }
.fx__filter { flex: 1 1 320px; max-width: 420px; }
.search__box--sm { padding: 3px 8px 3px 12px; border-width: 1px; border-color: var(--line-2); box-shadow: var(--sh-1); }
.search__box--sm input { font-size: 14.5px; }
.fx__nav { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; position: sticky; top: calc(var(--top-offset) + 8px); z-index: 5; background: var(--paper); padding: 6px 0; }
.fx__nav a { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line-2); background: var(--white); border-radius: 999px; padding: 5px 11px; font-size: 13px; font-weight: 600; color: var(--ink-2); text-decoration: none; }
.fx__nav a:hover { border-color: var(--teal); color: var(--teal-dark); }
.fx__nav a .n { color: var(--muted); font-weight: 600; font-variant-numeric: tabular-nums; }
.fxb { margin: 0 0 26px; }
.fxb__title { display: flex; align-items: center; gap: 10px; font: 800 19px/1.2 var(--f-head); color: var(--ink); margin: 0 0 10px; padding-bottom: 8px; border-bottom: 2px solid var(--teal-line); }
.fxb__title .cnt { font: 700 12px/1 var(--f-body); background: var(--teal-bg); color: var(--teal-dark); border: 1px solid var(--teal-line); border-radius: 999px; padding: 3px 8px; }
.fxgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
.fxc { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-md); padding: 12px 14px 10px; display: grid; gap: 6px; box-shadow: var(--sh-1); transition: box-shadow .15s, border-color .15s; }
.fxc:hover { border-color: var(--teal-line); box-shadow: var(--sh-2); }
.fxc--cr { border-left: 4px solid var(--green); }
.fxc__top { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.fxc__fav { margin-left: auto; width: 30px; height: 30px; }
.fxl { display: inline-flex; align-items: center; font: 700 10.5px/1 var(--f-head); letter-spacing: .08em; text-transform: uppercase; border-radius: 4px; padding: 4px 7px; border: 1px solid var(--line-2); color: var(--muted); background: var(--white); white-space: nowrap; }
.fxl--1 { color: var(--white); background: var(--teal-dark); border-color: var(--teal-dark); }
.fxl--2 { color: var(--teal-dark); background: var(--teal-bg); border-color: var(--teal-line); }
.fxl--3 { color: var(--ink-2); background: var(--paper-2); border-color: var(--line-2); }
.fxc__name { margin: 0; font: 700 16.5px/1.25 var(--f-head); }
.fxc__name button, .app .fxc__name button { text-align: left; color: var(--ink); padding: 0 !important; min-height: 0 !important; background: none !important; border: 0 !important; font-size: 16.5px !important; font-weight: 700 !important; line-height: 1.25 !important; display: inline !important; }
.fxc__name button:hover { color: var(--teal-dark); text-decoration: underline; }
.fxc__role, .app .fxc__role { margin: 0; font-size: 13.5px !important; line-height: 1.4; color: var(--ink-2); }
.fxc__meta, .app .fxc__meta { margin: 0; font-size: 12.5px !important; color: var(--muted); }
.fxc__comp, .app .fxc__comp { margin: 2px 0 0; padding-left: 16px; font-size: 13px !important; color: var(--ink-2); }
.fxc__comp li { margin: 1px 0; }
.fxc__pauta, .app .fxc__pauta { margin: 0; font-size: 13px !important; color: var(--ink-2); background: var(--paper); border-radius: var(--r-sm); padding: 6px 8px; }
.fxc__drugs, .app .fxc__drugs { margin: 0; font-size: 12.5px !important; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; }
.fxc__drugs a { color: var(--teal-dark); font-weight: 600; text-decoration: none; border-bottom: 1px dotted var(--teal-line); }
.fxc__drugs a:hover { border-bottom-style: solid; }
.fxc__foot { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 4px; padding-top: 8px; border-top: 1px solid var(--line); }
.fxc__foot .btn--quiet { margin-right: auto; }
.btn--sm { padding: 6px 10px; font-size: 13px; }
.fx__foot { margin-top: 10px; padding: 14px 16px; background: var(--white); border: 1px dashed var(--line-2); border-radius: var(--r-md); font-size: 13.5px; color: var(--ink-2); }
.fx__foot p { margin: 0 0 8px; }
.sec--fx .fxbox { background: var(--teal-bg); border: 1px solid var(--teal-line); border-radius: var(--r-md); padding: 10px 12px; }
.fxbox__head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 4px; }
.fxbox__head b { font: 700 14px/1.2 var(--f-head); color: var(--teal-dark); }
.fxbox p { margin: 0; font-size: 14px; color: var(--ink-2); }
.fxdrugs { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 8px; font-size: 13px; color: var(--muted); align-items: center; }
.fxdrugs a { color: var(--teal-dark); font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: 3px; }
.fxdrugs a:hover { text-decoration: underline; }
/* Sobrescribe la capa de diseño global inyectada en el Shadow DOM (reglas con ids repetidos) */
:is(:host, #dxp#dxp#dxp#dxp#dxp) .fxc__name button { font-size: 16.5px !important; font-weight: 700 !important; line-height: 1.25 !important; padding: 0 !important; min-height: 0 !important; }
:is(:host, #dxp#dxp#dxp#dxp#dxp) .fxc__role { font-size: 13.5px !important; line-height: 1.4 !important; }
:is(:host, #dxp#dxp#dxp#dxp#dxp) .fxc__meta, :is(:host, #dxp#dxp#dxp#dxp#dxp) .fxc__drugs { font-size: 12.5px !important; }
:is(:host, #dxp#dxp#dxp#dxp#dxp) .fxc__comp li, :is(:host, #dxp#dxp#dxp#dxp#dxp) .fxc__pauta { font-size: 13px !important; line-height: 1.4 !important; }
:is(:host, #dxp#dxp#dxp#dxp#dxp) .fx__intro p { font-size: 15px !important; }
:is(:host, #dxp#dxp#dxp#dxp#dxp) .fxbox p { font-size: 14px !important; }
:is(:host, #dxp#dxp#dxp#dxp#dxp) .fx__foot p { font-size: 13.5px !important; }
@media (max-width: 760px) {
  .modes { width: 100%; }
  .modes button { flex: 1; justify-content: center; padding: 8px 10px; font-size: 13px; }
  .fx__nav { position: static; }
  .fxgrid { grid-template-columns: 1fr; }
}
