/* Mercado · página de demostración (ámbito: producto:mercado).
   Concepto: landing SaaS clara de una sola columna de lectura, con la app real (estética tipo chat)
   como pieza central. Tokens alineados con ui/src/styles/app.css; el subrayado de cita (marcador
   amarillo) es el único gesto propio: es lo que hace Mercado, señalar la frase. */
:root {
  --bg:          #ffffff;
  --surface:     #f6f7f9;
  --surface-2:   #eef1f6;
  --border:      #e2e5eb;
  --text:        #1b2233;
  --muted:       #5d6679;
  --primary:     #2447b8;
  --primary-ink: #ffffff;
  --primary-soft:#eaf0ff;
  --ok:          #12805c;
  --ok-soft:     #e3f4ec;
  --warn:        #b45f00;
  --warn-soft:   #fdf0de;
  --crit:        #c62f2c;
  --crit-soft:   #fde8e7;
  --mark:        #ffe98a;
  --mark-ink:    #1b2233;
  --dark:        #141a2b;
  --dark-ink:    #f2f4f8;
  --glow:        rgba(36, 71, 184, 0.14);
  --shadow-sm:   0 1px 2px rgba(16, 24, 40, 0.06);
  --shadow-md:   0 10px 34px rgba(16, 24, 40, 0.09), 0 2px 6px rgba(16, 24, 40, 0.05);
  --shadow-lg:   0 30px 80px rgba(20, 34, 80, 0.18), 0 6px 18px rgba(16, 24, 40, 0.08);

  --f-display: 'Source Serif 4', 'Iowan Old Style', 'Palatino Linotype', Palatino, Georgia, serif;
  --f-body:    system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --f-mono:    ui-monospace, 'SF Mono', Menlo, Consolas, monospace;

  --r:    10px;
  --r-lg: 18px;
  --ancho: 1160px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #14161b; --surface: #1b1e25; --surface-2: #232733; --border: #2b303b;
    --text: #e4e6eb; --muted: #9aa1b0; --primary: #5b82f0; --primary-ink: #0d1220; --primary-soft: #1c2540;
    --ok: #3cbf8c; --ok-soft: #13291f; --warn: #f0a24a; --warn-soft: #2e2213; --crit: #f0716d; --crit-soft: #331817;
    --mark: #6b5a12; --mark-ink: #fff6cf; --dark: #0c0f17; --dark-ink: #f2f4f8; --glow: rgba(91, 130, 240, 0.18);
    --shadow-sm: 0 1px 2px rgba(0,0,0,.4); --shadow-md: 0 10px 34px rgba(0,0,0,.45); --shadow-lg: 0 30px 80px rgba(0,0,0,.55);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #14161b; --surface: #1b1e25; --surface-2: #232733; --border: #2b303b;
  --text: #e4e6eb; --muted: #9aa1b0; --primary: #5b82f0; --primary-ink: #0d1220; --primary-soft: #1c2540;
  --ok: #3cbf8c; --ok-soft: #13291f; --warn: #f0a24a; --warn-soft: #2e2213; --crit: #f0716d; --crit-soft: #331817;
  --mark: #6b5a12; --mark-ink: #fff6cf; --dark: #0c0f17; --dark-ink: #f2f4f8; --glow: rgba(91, 130, 240, 0.18);
  --shadow-sm: 0 1px 2px rgba(0,0,0,.4); --shadow-md: 0 10px 34px rgba(0,0,0,.45); --shadow-lg: 0 30px 80px rgba(0,0,0,.55);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--f-body); font-size: 16px; line-height: 1.55;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 60; background: var(--bg); }
h1, h2, h3 { margin: 0; text-wrap: balance; }
p, ul, ol { margin: 0; }
a { color: inherit; }
button, input { font: inherit; color: inherit; }
img, svg { max-width: 100%; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; border-radius: 4px; }
code { font-family: var(--f-mono); font-size: .86em; background: var(--surface-2); padding: 1px 5px; border-radius: 5px; overflow-wrap: anywhere; }
mark { background: var(--mark); color: var(--mark-ink); padding: 0 2px; border-radius: 3px; }
[hidden] { display: none !important; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.salta { position: absolute; left: -999px; top: 8px; background: var(--primary); color: var(--primary-ink); padding: 8px 12px; border-radius: 8px; z-index: 100; }
.salta:focus { left: 12px; }

.env {
  max-width: var(--ancho); margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
@media (min-width: 720px) { .env { padding-left: max(32px, env(safe-area-inset-left, 0px)); padding-right: max(32px, env(safe-area-inset-right, 0px)); } }
.env--estrecho { max-width: 820px; }

.logo { width: 26px; height: 26px; flex-shrink: 0; }

/* ── Botones ─────────────────────────────────────────────────────────── */
.boton {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 20px; border-radius: 999px; border: 1px solid transparent;
  background: var(--primary); color: var(--primary-ink); font-weight: 650; font-size: 15px;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
}
.boton:hover { transform: translateY(-1px); box-shadow: 0 8px 20px var(--glow); }
.boton--osc { background: var(--text); color: var(--bg); }
.boton--claro { background: #ffffff; color: #141a2b; }

/* ── Cabecera ────────────────────────────────────────────────────────── */
.cab {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--border);
}
.cab__fila { display: flex; align-items: center; gap: 24px; height: 64px; }
.marca { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; font-family: var(--f-display); font-weight: 600; font-size: 22px; letter-spacing: -.01em; }
.nav { display: flex; gap: 26px; margin-left: auto; font-size: 15px; }
.nav a { text-decoration: none; color: var(--muted); }
.nav a:hover { color: var(--text); }
.cab__cta { padding: 9px 16px; font-size: 14px; }
@media (max-width: 860px) { .nav { display: none; } .cab__cta { margin-left: auto; } }

/* ── Portada ─────────────────────────────────────────────────────────── */
.hero { position: relative; overflow: hidden; padding-block: 64px 72px; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto 40%; height: 120%;
  background: radial-gradient(closest-side, var(--glow), transparent 70%); pointer-events: none;
}
.hero__rejilla { position: relative; display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center; }
.hero__texto { min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.pastilla {
  align-self: flex-start; display: inline-flex; align-items: center; gap: 8px;
  padding: 5px 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--bg);
  font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--primary);
}
.punto { width: 7px; height: 7px; border-radius: 50%; background: var(--primary); box-shadow: 0 0 0 4px var(--primary-soft); }
.hero h1 {
  font-family: var(--f-display); font-weight: 600; letter-spacing: -.02em;
  font-size: clamp(38px, 5.4vw, 64px); line-height: 1.04;
}
.subrayado {
  color: var(--primary); font-style: italic; font-weight: 500;
  background: linear-gradient(transparent 62%, var(--mark) 62%, var(--mark) 92%, transparent 92%);
  -webkit-box-decoration-break: clone; box-decoration-break: clone; padding: 0 .08em;
}
.hero__entradilla { font-size: 18px; color: var(--muted); max-width: 34em; }
.hero__entradilla strong { color: var(--text); font-weight: 650; }
.captura { display: flex; gap: 8px; max-width: 470px; padding: 6px; border-radius: 999px; background: var(--bg); border: 1px solid var(--border); box-shadow: var(--shadow-md); }
.captura input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 0 14px; font-size: 15px; outline: none; }
.captura:focus-within { border-color: var(--primary); }
.hero__aviso, .cta__aviso { min-height: 1.4em; font-size: 14px; color: var(--ok); margin-top: -10px; }
.hero__aviso.error, .cta__aviso.error { color: var(--crit); }
.hero__garantias { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 20px; font-size: 14px; color: var(--muted); margin-top: -6px; }
.hero__garantias li { display: inline-flex; align-items: center; gap: 6px; }
.hero__garantias svg { width: 15px; height: 15px; fill: none; stroke: var(--ok); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.hero__garantias a { color: var(--primary); font-weight: 600; text-decoration-thickness: 1px; text-underline-offset: 3px; }

.hero__app { position: relative; min-width: 0; padding: 24px 8px 40px; }
.ventana { background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); overflow: hidden; }
.ventana__barra { display: flex; align-items: center; gap: 6px; padding: 11px 14px; border-bottom: 1px solid var(--border); background: var(--surface); }
.ventana__barra span { width: 10px; height: 10px; border-radius: 50%; background: var(--border); }
.ventana__barra em { margin-left: 10px; font-style: normal; font-size: 12px; color: var(--muted); }
.ventana__cuerpo { padding: 22px 22px 18px; display: flex; flex-direction: column; gap: 16px; font-size: 14.5px; }
.burbuja--yo { align-self: flex-end; max-width: 85%; background: var(--surface-2); padding: 10px 14px; border-radius: 18px 18px 4px 18px; }
.respuesta { display: grid; grid-template-columns: 26px 1fr; gap: 12px; }
.respuesta__avatar svg { width: 26px; height: 26px; }
.respuesta > div:last-child { min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.respuesta ul { padding-left: 18px; display: flex; flex-direction: column; gap: 6px; }
.cita {
  display: inline-flex; align-items: center; gap: 4px; vertical-align: 1px;
  padding: 1px 8px; border-radius: 999px; font-size: 11.5px; font-weight: 600; white-space: nowrap;
  background: var(--primary-soft); color: var(--primary); border: 0; font-family: var(--f-body);
}
button.cita { cursor: pointer; }
button.cita:hover { background: var(--primary); color: var(--primary-ink); }
.cita::before { content: ""; width: 9px; height: 11px; border: 1.5px solid currentColor; border-radius: 2px; opacity: .8; }
.composer--mini { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 10px 10px 16px; border: 1px solid var(--border); border-radius: 999px; color: var(--muted); font-size: 13.5px; box-shadow: var(--shadow-sm); }
.composer--mini b { width: 30px; height: 30px; flex-shrink: 0; display: grid; place-items: center; border-radius: 50%; background: var(--text); color: var(--bg); }

.flotante {
  position: absolute; display: flex; flex-direction: column; gap: 2px;
  background: var(--bg); border: 1px solid var(--border); border-radius: 14px; padding: 10px 14px;
  box-shadow: var(--shadow-md); font-size: 13px;
}
.flotante b { font-family: var(--f-display); font-size: 22px; line-height: 1; margin-right: 4px; }
.flotante small { color: var(--muted); font-size: 12px; }
.flotante--a { left: -18px; bottom: 6px; flex-direction: row; align-items: baseline; flex-wrap: wrap; max-width: 210px; }
.flotante--a small { flex-basis: 100%; }
.flotante--b { right: -10px; top: -2px; }
@media (prefers-reduced-motion: no-preference) {
  .flotante--a { animation: flota 6s ease-in-out infinite; }
  .flotante--b { animation: flota 7s ease-in-out -2s infinite; }
}
@keyframes flota { 50% { transform: translateY(-6px); } }

@media (max-width: 960px) {
  .hero { padding-block: 40px 48px; }
  .hero__rejilla { grid-template-columns: 1fr; gap: 28px; }
  .flotante--a { left: 0; } .flotante--b { right: 0; }
}
@media (max-width: 520px) {
  .captura { flex-direction: column; border-radius: 18px; }
  .captura input { padding: 10px 12px; }
  .flotante--b { display: none; }
  .ventana__cuerpo { padding: 16px; }
}

/* ── Chips y estados ─────────────────────────────────────────────────── */
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 650; white-space: nowrap; }
.chip--aviso { background: var(--warn-soft); color: var(--warn); }
.chip--ok { background: var(--ok-soft); color: var(--ok); }
.chip--crit { background: var(--crit-soft); color: var(--crit); }
.chip--neutro { background: var(--surface-2); color: var(--muted); }
.estado { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 650; padding: 3px 10px; border-radius: 999px; }
.estado::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.estado--ok { background: var(--ok-soft); color: var(--ok); }
.estado--pend { background: var(--warn-soft); color: var(--warn); }

/* ── Banda ───────────────────────────────────────────────────────────── */
.banda { border-block: 1px solid var(--border); background: var(--surface); }
.banda__fila { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; padding-block: 28px; }
.banda__fila div { display: flex; flex-direction: column; gap: 4px; text-align: center; }
.banda__fila b { font-family: var(--f-display); font-size: 30px; font-weight: 600; color: var(--primary); line-height: 1.1; }
.banda__fila span { font-size: 14px; color: var(--muted); }
@media (max-width: 760px) { .banda__fila { grid-template-columns: repeat(2, 1fr); } }

/* ── Secciones ───────────────────────────────────────────────────────── */
.seccion { padding-block: 96px; }
.seccion--gris { background: var(--surface); }
@media (max-width: 720px) { .seccion { padding-block: 64px; } }
.antetitulo { text-align: center; font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--primary); margin-bottom: 14px; }
.seccion h2, .cta h2 { text-align: center; font-family: var(--f-display); font-weight: 600; letter-spacing: -.015em; font-size: clamp(30px, 4vw, 46px); line-height: 1.1; }
.acento { color: var(--primary); font-style: italic; font-weight: 500; }
.seccion__entradilla { text-align: center; max-width: 40em; margin: 18px auto 0; color: var(--muted); font-size: 17px; }

/* Antes / después */
.comparativa { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 48px; }
.lado { border: 1px solid var(--border); border-radius: var(--r-lg); padding: 28px; display: flex; flex-direction: column; gap: 18px; background: var(--bg); min-width: 0; }
.lado--despues { border-color: color-mix(in srgb, var(--primary) 45%, var(--border)); box-shadow: 0 20px 50px var(--glow); }
.lado h3 { display: flex; align-items: center; gap: 12px; font-family: var(--f-display); font-size: 22px; font-weight: 600; }
.icono-lado { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; font-family: var(--f-body); font-size: 16px; background: var(--surface-2); color: var(--muted); }
.lado--despues .icono-lado { background: var(--primary); color: var(--primary-ink); }
.lado ul { padding-left: 18px; display: flex; flex-direction: column; gap: 10px; font-size: 15.5px; }
.lado li::marker { color: var(--muted); }
.lado--despues li::marker { color: var(--primary); }
.lado__resultado { margin-top: auto; padding-top: 16px; border-top: 1px dashed var(--border); font-weight: 650; font-size: 15px; }
@media (max-width: 820px) { .comparativa { grid-template-columns: 1fr; } .lado { padding: 22px; } }

/* Pasos */
.pasos { list-style: none; padding: 0; margin-top: 48px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; counter-reset: paso; }
.paso { background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 24px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.paso__n { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 10px; background: var(--primary-soft); color: var(--primary); font-weight: 700; }
.paso h3 { font-size: 18px; font-weight: 650; }
.paso p { font-size: 14.5px; color: var(--muted); }
.paso__mini { margin-top: auto; padding-top: 14px; display: flex; flex-wrap: wrap; gap: 6px; }
.archivo { font-size: 12px; padding: 4px 8px; border-radius: 6px; background: var(--surface); border: 1px solid var(--border); font-family: var(--f-mono); overflow-wrap: anywhere; }
.campo { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13px; padding: 6px 10px; border-radius: 8px; background: var(--surface); border: 1px solid var(--border); font-weight: 600; }
.campo em { font-style: normal; color: var(--muted); font-weight: 500; }
@media (max-width: 980px) { .pasos { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .pasos { grid-template-columns: 1fr; } }

/* ── Demo: la app ────────────────────────────────────────────────────── */
.seccion--demo { background: linear-gradient(var(--bg), var(--surface)); }
.app {
  position: relative; margin-top: 44px; display: grid; grid-template-columns: 220px 1fr;
  height: 640px; border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden;
  background: var(--bg); box-shadow: var(--shadow-lg); font-size: 14px;
}
.app__lateral { background: var(--surface); border-right: 1px solid var(--border); display: flex; flex-direction: column; padding: 16px 10px; gap: 14px; min-width: 0; }
.app__marca { display: flex; align-items: center; gap: 9px; padding: 2px 8px 8px; font-family: var(--f-display); font-weight: 600; font-size: 20px; }
.app__marca .logo { width: 24px; height: 24px; }
.app__nav { display: flex; flex-direction: column; gap: 2px; }
.app__nav button {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; border: 0; border-radius: 8px;
  background: none; color: var(--muted); cursor: pointer; text-align: left; font-size: 14px;
}
.app__nav button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.app__nav button:hover { background: var(--surface-2); color: var(--text); }
.app__nav button[aria-selected="true"] { background: var(--primary-soft); color: var(--primary); font-weight: 650; }
.contador { margin-left: auto; min-width: 20px; padding: 0 6px; border-radius: 999px; background: var(--warn); color: #fff; font-size: 11px; font-weight: 700; text-align: center; line-height: 18px; }
.contador:empty, .contador[data-cero] { display: none; }
.app__pie { margin-top: auto; padding: 0 8px; font-size: 11.5px; color: var(--muted); }
.app__principal { position: relative; min-width: 0; min-height: 0; display: flex; }
.vista { flex: 1; min-width: 0; min-height: 0; display: flex; flex-direction: column; }

/* Chat */
.chat { flex: 1; overflow-y: auto; padding: 28px clamp(16px, 5%, 64px) 12px; display: flex; flex-direction: column; gap: 22px; scrollbar-width: thin; }
.chat__inicio { margin: auto 0; display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.chat__inicio h3 { font-family: var(--f-display); font-weight: 600; font-size: clamp(22px, 3vw, 30px); letter-spacing: -.01em; }
.chat__inicio p { color: var(--muted); font-size: 13.5px; }
.sugerencias { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; width: 100%; max-width: 620px; margin-top: 18px; }
.sugerencia {
  display: flex; flex-direction: column; gap: 3px; text-align: left; padding: 12px 14px; border-radius: 14px;
  border: 1px solid var(--border); background: var(--bg); cursor: pointer; transition: border-color .15s, background .15s;
}
.sugerencia:hover { border-color: var(--primary); background: var(--primary-soft); }
.sugerencia b { font-size: 13px; }
.sugerencia span { font-size: 13px; color: var(--muted); }
.msg-yo { align-self: flex-end; max-width: 78%; background: var(--surface-2); padding: 10px 15px; border-radius: 18px 18px 4px 18px; }
.msg-ia { display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 12px; max-width: 760px; }
.msg-ia svg { width: 26px; height: 26px; }
.msg-ia__cuerpo { display: flex; flex-direction: column; gap: 10px; line-height: 1.6; }
.msg-ia__cuerpo ul { padding-left: 18px; display: flex; flex-direction: column; gap: 7px; }
.msg-ia__nota { font-size: 12.5px; color: var(--muted); }
.escribiendo { display: inline-flex; gap: 4px; padding: 8px 0; }
.escribiendo i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); opacity: .4; animation: late 1s infinite; }
.escribiendo i:nth-child(2) { animation-delay: .15s; } .escribiendo i:nth-child(3) { animation-delay: .3s; }
@keyframes late { 50% { opacity: 1; transform: translateY(-2px); } }
.siguientes { display: flex; flex-wrap: wrap; gap: 6px; }
.siguientes button { border: 1px solid var(--border); background: var(--bg); border-radius: 999px; padding: 5px 12px; font-size: 12.5px; cursor: pointer; color: var(--muted); }
.siguientes button:hover { border-color: var(--primary); color: var(--primary); }
.composer {
  display: flex; align-items: center; gap: 8px; margin: 8px clamp(16px, 5%, 64px) 18px; padding: 7px 7px 7px 18px;
  border: 1px solid var(--border); border-radius: 999px; background: var(--bg); box-shadow: var(--shadow-md);
}
.composer:focus-within { border-color: var(--primary); }
.composer input { flex: 1; min-width: 0; border: 0; outline: none; background: transparent; font-size: 14.5px; }
.composer button { width: 36px; height: 36px; flex-shrink: 0; border: 0; border-radius: 50%; background: var(--text); color: var(--bg); font-size: 17px; font-weight: 700; cursor: pointer; }

/* Maestro-detalle (validación) */
.md { flex: 1; min-height: 0; display: grid; grid-template-columns: 250px 1fr; }
.md__lista { border-right: 1px solid var(--border); overflow-y: auto; padding: 10px; display: flex; flex-direction: column; gap: 4px; }
.md__grupo { font-size: 11px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); padding: 10px 8px 4px; }
.fila { display: flex; flex-direction: column; gap: 3px; width: 100%; text-align: left; padding: 10px; border-radius: 10px; border: 1px solid transparent; background: none; cursor: pointer; }
.fila:hover { background: var(--surface); }
.fila[aria-current="true"] { background: var(--primary-soft); border-color: color-mix(in srgb, var(--primary) 30%, transparent); }
.fila b { font-size: 13.5px; }
.fila small { font-size: 12px; color: var(--muted); }
.fila .estado { align-self: flex-start; margin-top: 3px; font-size: 11px; padding: 1px 8px; }
.md__detalle > *, .venc > * { flex-shrink: 0; }
.md__detalle { overflow-y: auto; padding: 22px 26px; display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.det__cab { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 10px; }
.det__cab h3 { font-family: var(--f-display); font-size: 22px; font-weight: 600; }
.det__cab p { color: var(--muted); font-size: 13px; }
.campos { display: flex; flex-direction: column; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.campo-fila { display: grid; grid-template-columns: 130px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 11px 14px; border-top: 1px solid var(--border); }
.campo-fila:first-child { border-top: 0; }
.campo-fila[data-ok] { background: color-mix(in srgb, var(--ok-soft) 55%, transparent); }
.campo-fila__k { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.campo-fila__v { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-weight: 600; min-width: 0; }
.campo-fila__v input { width: 100%; max-width: 260px; padding: 5px 8px; border: 1px solid var(--primary); border-radius: 7px; background: var(--bg); font-weight: 500; }
.campo-fila__acc { display: flex; gap: 6px; }
.mini { border: 1px solid var(--border); background: var(--bg); border-radius: 8px; padding: 5px 10px; font-size: 12.5px; cursor: pointer; white-space: nowrap; }
.mini:hover { border-color: var(--primary); color: var(--primary); }
.mini--ok { background: var(--ok); border-color: var(--ok); color: #fff; }
.mini--ok:hover { color: #fff; filter: brightness(1.08); }
.hecho { font-size: 12.5px; font-weight: 650; color: var(--ok); white-space: nowrap; }
.clausula { border: 1px solid color-mix(in srgb, var(--warn) 40%, var(--border)); background: var(--warn-soft); border-radius: 12px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.clausula blockquote { margin: 0; padding-left: 12px; border-left: 3px solid var(--warn); font-family: var(--f-display); font-size: 15.5px; font-style: italic; }
.clausula p { font-size: 13px; color: var(--muted); }
.det__pie { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.det__pie .boton { padding: 10px 18px; font-size: 14px; }
.det__pie .boton[disabled] { opacity: .45; cursor: not-allowed; transform: none; box-shadow: none; }
.det__pie small { color: var(--muted); font-size: 12.5px; }
.vacio { margin: auto; text-align: center; color: var(--muted); max-width: 30em; display: flex; flex-direction: column; gap: 8px; }
.vacio b { font-family: var(--f-display); font-size: 22px; color: var(--text); }

/* Vencimientos */
.venc { flex: 1; min-height: 0; overflow-y: auto; padding: 22px 26px; display: flex; flex-direction: column; gap: 16px; }
.venc__cab { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 12px; }
.venc__cab h3 { font-family: var(--f-display); font-size: 22px; font-weight: 600; }
.venc__cab p { color: var(--muted); font-size: 13px; }
.filtros { display: flex; gap: 6px; flex-wrap: wrap; }
.filtro { border: 1px solid var(--border); background: var(--bg); border-radius: 999px; padding: 6px 12px; font-size: 13px; cursor: pointer; }
.filtro[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.tabla-env { overflow-x: auto; border: 1px solid var(--border); border-radius: 12px; }
.tabla { width: 100%; border-collapse: collapse; font-size: 13.5px; font-variant-numeric: tabular-nums; min-width: 640px; }
.tabla th { text-align: left; font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); background: var(--surface); padding: 10px 14px; }
.tabla td { padding: 12px 14px; border-top: 1px solid var(--border); vertical-align: middle; }
.tabla td small { display: block; color: var(--muted); font-size: 12px; }
.tabla .num { text-align: right; }
.tabla td:nth-child(2), .tabla td:nth-child(4) { white-space: nowrap; }

/* Visor de cita */
.visor {
  position: absolute; top: 0; right: 0; bottom: 0; width: min(440px, 100%); z-index: 5;
  background: var(--surface); border-left: 1px solid var(--border); box-shadow: -20px 0 50px rgba(16,24,40,.12);
  display: flex; flex-direction: column;
}
@media (prefers-reduced-motion: no-preference) { .visor { animation: entra .22s ease-out; } }
@keyframes entra { from { transform: translateX(30px); opacity: 0; } }
.visor__cab { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--border); background: var(--bg); }
.visor__cab div { display: flex; flex-direction: column; min-width: 0; }
.visor__cab b { font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.visor__cab span { font-size: 12px; color: var(--muted); }
.visor__cerrar { width: 32px; height: 32px; flex-shrink: 0; border: 1px solid var(--border); background: var(--bg); border-radius: 8px; font-size: 18px; cursor: pointer; }
.pagina {
  margin: 18px; padding: 30px 28px; background: #fffefb; color: #2a2a2a; border-radius: 4px;
  box-shadow: 0 2px 10px rgba(0,0,0,.12); font-family: var(--f-display); font-size: 13px; line-height: 1.7;
  overflow-y: auto; display: flex; flex-direction: column; gap: 12px;
}
.pagina h4 { margin: 0; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; text-align: center; color: #555; }
.pagina p { color: #3b3b3b; }
.pagina .resaltada { background: #ffe98a; color: #1b1b1b; padding: 1px 2px; border-radius: 2px; box-shadow: 0 0 0 2px #ffe98a; }
.pagina__num { margin-top: auto; text-align: center; font-size: 11px; color: #888; font-family: var(--f-body); }

@media (max-width: 760px) {
  .app { grid-template-columns: 1fr; grid-template-rows: auto 1fr; height: 720px; }
  .app__lateral { border-right: 0; border-bottom: 1px solid var(--border); flex-direction: row; align-items: center; padding: 8px; gap: 6px; overflow-x: auto; }
  .app__marca, .app__pie { display: none; }
  .app__nav { flex-direction: row; gap: 4px; }
  .app__nav button { white-space: nowrap; padding: 8px 10px; }
  .sugerencias { grid-template-columns: 1fr; }
  .md { grid-template-columns: 1fr; grid-template-rows: auto 1fr; }
  .md__lista { border-right: 0; border-bottom: 1px solid var(--border); flex-direction: row; overflow-x: auto; max-height: none; }
  .md__grupo { display: none; }
  .fila { min-width: 0; flex: 0 0 auto; width: auto; padding: 8px 10px; }
  .fila small { display: none; }
  .fila b { white-space: nowrap; }
  .md__detalle, .venc { padding: 16px; }
  .campo-fila { grid-template-columns: 1fr; gap: 6px; }
  .msg-yo { max-width: 90%; }
}
.nota-demo { margin: 18px auto 0; max-width: 46em; text-align: center; font-size: 13.5px; color: var(--muted); }
.nota-demo b { color: var(--text); }

/* ── Privacidad ──────────────────────────────────────────────────────── */
.priv { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.priv__texto { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.priv__texto .antetitulo, .priv__texto h2 { text-align: left; margin-bottom: 0; }
.priv__texto > p { color: var(--muted); font-size: 17px; }
.lista-check { list-style: none; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.lista-check li { position: relative; padding-left: 28px; }
.lista-check li::before { content: "✓"; position: absolute; left: 0; top: 1px; width: 19px; height: 19px; display: grid; place-items: center; border-radius: 50%; background: var(--ok-soft); color: var(--ok); font-size: 12px; font-weight: 700; }
.priv__ejemplo { display: flex; flex-direction: column; align-items: stretch; gap: 10px; min-width: 0; }
.tarjeta-texto { border: 1px solid var(--border); border-radius: var(--r-lg); padding: 20px 22px; background: var(--bg); box-shadow: var(--shadow-md); display: flex; flex-direction: column; gap: 10px; }
.tarjeta-texto p { font-family: var(--f-display); font-size: 16.5px; line-height: 1.75; }
.tarjeta-texto--alias { background: var(--dark); color: var(--dark-ink); border-color: var(--dark); }
.etiqueta { font-size: 11.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.tarjeta-texto--alias .etiqueta { color: #9fb2ef; }
.dato { background: var(--mark); color: var(--mark-ink); padding: 0 3px; border-radius: 3px; }
.alias { font-family: var(--f-mono); font-size: 13.5px; background: rgba(91,130,240,.22); color: #c9d6ff; padding: 1px 5px; border-radius: 4px; }
.flecha { align-self: center; width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; background: var(--primary); color: var(--primary-ink); font-weight: 700; }
@media (max-width: 880px) { .priv { grid-template-columns: 1fr; gap: 36px; } }

/* ── Funciones ───────────────────────────────────────────────────────── */
.funciones { margin-top: 48px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.funcion { background: var(--bg); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 22px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.funcion__cab { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; }
.funcion h3 { font-size: 17px; font-weight: 650; }
.funcion p { font-size: 14.5px; color: var(--muted); }
@media (max-width: 940px) { .funciones { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .funciones { grid-template-columns: 1fr; } }

/* ── FAQ ─────────────────────────────────────────────────────────────── */
.faq { margin-top: 40px; display: flex; flex-direction: column; gap: 10px; }
.faq details { border: 1px solid var(--border); border-radius: 14px; background: var(--bg); }
.faq summary { list-style: none; cursor: pointer; padding: 18px 20px; font-weight: 650; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 22px; font-weight: 400; color: var(--primary); transition: transform .2s; flex-shrink: 0; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 20px 18px; color: var(--muted); }

/* ── CTA y pie ───────────────────────────────────────────────────────── */
.cta { padding-block: 24px 96px; }
.cta__caja {
  max-width: calc(var(--ancho) - 64px); border-radius: 28px; padding-block: 64px;
  background: radial-gradient(120% 140% at 85% 0%, #3d63d6 0%, #2447b8 45%, #172f80 100%);
  color: #ffffff; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 18px;
}
.cta h2 { color: #ffffff; }
.cta p { max-width: 36em; color: rgba(255,255,255,.82); font-size: 17px; }
.captura--cta { width: 100%; background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.25); box-shadow: none; }
.captura--cta input { color: #ffffff; }
.captura--cta input::placeholder { color: rgba(255,255,255,.65); }
.cta__aviso { color: #c9f5df; margin-top: -6px; }
.cta__aviso.error { color: #ffd2cf; }
@media (max-width: 720px) { .cta__caja { border-radius: 0; padding-block: 48px; } .cta { padding-block: 0; } }

.pie { border-top: 1px solid var(--border); padding-block: 48px 32px; background: var(--bg); }
.pie__fila { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; }
.pie__fila > div { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.pie__fila p { color: var(--muted); font-size: 14px; max-width: 26em; }
.pie__col b { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.pie__col a, .pie__col span { font-size: 14px; text-decoration: none; overflow-wrap: anywhere; }
.pie__col a:hover { color: var(--primary); }
.pie__legal { margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--border); }
.pie__legal p { font-size: 12.5px; color: var(--muted); }
@media (max-width: 720px) { .pie__fila { grid-template-columns: 1fr 1fr; } .pie__fila > div:first-child { grid-column: 1 / -1; } }

/* ── Comparar ofertas ────────────────────────────────────────────────── */
.flujo { list-style: none; padding: 0; margin-top: 44px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; counter-reset: fl; border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; background: var(--bg); }
.flujo li { counter-increment: fl; padding: 22px 24px 22px 70px; position: relative; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.flujo li + li { border-left: 1px solid var(--border); }
.flujo li::before { content: counter(fl); position: absolute; left: 24px; top: 22px; width: 32px; height: 32px; display: grid; place-items: center; border-radius: 10px; background: var(--primary); color: var(--primary-ink); font-weight: 700; }
.flujo b { font-size: 16.5px; }
.flujo span { font-size: 14.5px; color: var(--muted); }
@media (max-width: 820px) { .flujo { grid-template-columns: 1fr; } .flujo li + li { border-left: 0; border-top: 1px solid var(--border); } }

.metodos { margin-top: 18px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.metodo { border: 1px solid var(--border); border-radius: 14px; padding: 16px; display: flex; flex-direction: column; gap: 8px; background: var(--surface); min-width: 0; }
.metodo p { font-size: 13.5px; color: var(--muted); }
.metodo__tipo { align-self: flex-start; display: inline-block; font-size: 11.5px; font-weight: 700; padding: 2px 9px; border-radius: 999px; white-space: nowrap; }
.metodo__tipo--formula { background: var(--primary-soft); color: var(--primary); }
.metodo__tipo--contar { background: var(--ok-soft); color: var(--ok); }
.metodo__tipo--juicio { background: var(--warn-soft); color: var(--warn); }
.metodo__tipo--cumplimiento { background: var(--surface-2); color: var(--text); }
@media (max-width: 980px) { .metodos { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .metodos { grid-template-columns: 1fr; } }

.matriz { margin-top: 36px; border: 1px solid var(--border); border-radius: var(--r-lg); background: var(--bg); box-shadow: var(--shadow-lg); overflow: hidden; font-size: 14px; }
.matriz__cab { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 14px; padding: 18px 22px; border-bottom: 1px solid var(--border); }
.matriz__codigo { font-family: var(--f-mono); font-size: 12px; color: var(--muted); }
.matriz__cab h3 { font-family: var(--f-display); font-size: 22px; font-weight: 600; }
.matriz__cab p { font-size: 13px; color: var(--muted); }
.matriz__acciones { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.matriz__acciones .boton { padding: 10px 18px; font-size: 14px; }
.matriz__acciones .boton[disabled] { opacity: .55; cursor: default; transform: none; box-shadow: none; }
.matriz__acciones .mini { padding: 9px 14px; font-size: 13.5px; }
.matriz__cuerpo { display: grid; grid-template-columns: 290px minmax(0, 1fr); }
.matriz__lateral { background: var(--surface); border-right: 1px solid var(--border); padding: 16px 14px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.matriz__lateral h4 { margin: 4px 4px 0; font-size: 11px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); }
.crit, .docs { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.crit li { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px; align-items: center; padding: 9px 10px; border-radius: 10px; background: var(--bg); border: 1px solid var(--border); }
.crit__txt { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.crit__txt b { font-size: 13px; }
.crit__txt small { font-size: 11.5px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.crit__txt .metodo__tipo { font-size: 10.5px; padding: 1px 7px; }
.crit__pts { display: flex; align-items: center; gap: 2px; font-variant-numeric: tabular-nums; }
.crit__pts span { min-width: 24px; text-align: center; font-weight: 700; }
.crit__pts button, .crit__quitar { width: 24px; height: 24px; border: 1px solid var(--border); background: var(--bg); border-radius: 7px; cursor: pointer; line-height: 1; }
.crit__pts button:hover:not([disabled]), .crit__quitar:hover { border-color: var(--primary); color: var(--primary); }
.crit__pts button[disabled] { opacity: .35; cursor: default; }
.crit__quitar { border-color: transparent; background: none; color: var(--muted); font-size: 16px; }
.crit__filtro { font-size: 11.5px; font-weight: 700; color: var(--muted); padding: 2px 6px; }
.crit__nuevo { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.crit__nuevo > span { width: 100%; font-size: 12px; color: var(--muted); padding: 2px 4px 0; }
.crit__nuevo .mini { font-size: 12px; border-style: dashed; }
.docs li { display: flex; gap: 10px; align-items: center; padding: 7px 8px; min-width: 0; }
.docs li > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.docs b { font-size: 13px; }
.docs small { font-size: 11.5px; color: var(--muted); overflow-wrap: anywhere; }
.docs__ico { flex-shrink: 0; width: 30px; height: 36px; display: grid; place-items: end center; padding-bottom: 4px; border-radius: 4px 9px 4px 4px; background: var(--crit-soft); color: var(--crit); font-size: 9px; font-weight: 800; }
.matriz__principal { min-width: 0; padding: 16px; display: flex; flex-direction: column; gap: 14px; }
.tabla--matriz { min-width: 760px; }
.tabla--matriz th small { display: block; font-weight: 500; letter-spacing: 0; text-transform: none; color: var(--muted); font-size: 11.5px; margin-top: 2px; }
.tabla--matriz thead th { vertical-align: bottom; text-transform: none; letter-spacing: 0; font-size: 12.5px; color: var(--text); }
.tabla--matriz tbody th { text-align: left; font-weight: 500; padding: 10px 12px; border-top: 1px solid var(--border); background: var(--bg); }
.tabla--matriz tbody th { display: table-cell; }
.tabla--matriz tbody th > span:last-child { display: inline-flex; flex-direction: column; vertical-align: middle; }
.tabla--matriz tbody th small { color: var(--muted); font-size: 11.5px; }
.mx-rank { display: inline-grid; place-items: center; width: 24px; height: 24px; margin-right: 8px; border-radius: 50%; background: var(--surface-2); font-size: 12px; font-weight: 700; vertical-align: middle; }
tbody tr:first-child:not(.mx-fila--exc) .mx-rank { background: var(--primary); color: var(--primary-ink); }
.mx-total b { font-size: 18px; font-family: var(--f-display); }
.mx-total small { display: block; font-size: 11.5px; font-weight: 650; }
.txt-warn { color: var(--warn); } .txt-ok { color: var(--ok); } .txt-crit { color: var(--crit); }
.mx-fila--exc td { opacity: .6; }
.mx-fila--exc th b, .mx-fila--exc th small { color: var(--muted); }
.tabla--matriz td.mx-celda { padding: 0; }
.mx-celda button { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 100%; height: 100%; min-height: 58px; padding: 10px 12px; border: 0; background: none; cursor: pointer; text-align: left; }
.mx-celda button:hover { background: var(--primary-soft); }
.mx-celda b { font-size: 14px; font-variant-numeric: tabular-nums; }
.mx-celda small { font-size: 11.5px; color: var(--muted); }
.mx-celda--rev { background: color-mix(in srgb, var(--ok-soft) 70%, transparent); }
.mx-celda--duda { background: color-mix(in srgb, var(--warn-soft) 60%, transparent); }
.mx-celda--no b { color: var(--crit); }
.mx-celda--sel { box-shadow: inset 0 0 0 2px var(--primary); }
.mx-celda--vacia span { display: block; padding: 10px 12px; font-size: 12px; color: var(--muted); }
.mx-celda--cargando { background: linear-gradient(90deg, var(--surface) 0%, var(--primary-soft) 50%, var(--surface) 100%); background-size: 200% 100%; }
@media (prefers-reduced-motion: no-preference) { .mx-celda--cargando { animation: brillo 1.1s linear infinite; } }
@keyframes brillo { from { background-position: 100% 0; } to { background-position: -100% 0; } }
.marca-ok { font-style: normal; color: var(--ok); font-weight: 700; }
.marca-duda { font-style: normal; color: var(--warn); font-weight: 800; }

.celda-det { border: 1px solid var(--border); border-radius: 12px; padding: 16px 18px; display: flex; flex-direction: column; gap: 10px; background: var(--surface); }
.celda-det__vacio { color: var(--muted); font-size: 13.5px; }
.celda-det__cab { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: 8px; }
.celda-det__cab small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.celda-det__prop { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; }
.celda-det__prop span { font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.celda-det__prop b { font-family: var(--f-display); font-size: 19px; }
.celda-det > p { font-size: 14px; }
.extracto { margin: 0; background: #fffefb; color: #2a2a2a; border-radius: 6px; padding: 12px 16px; box-shadow: 0 1px 6px rgba(0,0,0,.1); }
.extracto figcaption { font-family: var(--f-mono); font-size: 11px; color: #777; margin-bottom: 6px; overflow-wrap: anywhere; }
.extracto blockquote { margin: 0; font-family: var(--f-display); font-size: 14.5px; line-height: 1.7; }
.extracto .resaltada { background: #ffe98a; color: #1b1b1b; padding: 1px 2px; border-radius: 2px; box-shadow: 0 0 0 2px #ffe98a; }
.extracto--sin { font-size: 13px; color: #6b5300; background: var(--warn-soft); box-shadow: none; }
.celda-det__acc { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.celda-det__acc input { padding: 6px 9px; border: 1px solid var(--border); border-radius: 8px; background: var(--bg); font-size: 13.5px; }
.celda-det__acc input[type="number"] { width: 90px; }
.celda-det__acc input[type="text"] { flex: 1; min-width: 180px; }
.garantias-mx { list-style: none; padding: 0; margin-top: 24px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.garantias-mx li { font-size: 14px; color: var(--muted); padding-left: 14px; border-left: 2px solid var(--primary); }
.garantias-mx strong { color: var(--text); }
@media (max-width: 980px) { .matriz__cuerpo { grid-template-columns: 1fr; } .matriz__lateral { border-right: 0; border-bottom: 1px solid var(--border); } .garantias-mx { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .garantias-mx { grid-template-columns: 1fr; } .matriz__cab, .matriz__principal { padding: 14px; } }

.docs-fila { display: flex; flex-direction: column; gap: 6px; }
.docs-fila h4 { margin: 0; font-size: 11px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); }
.docs-fila .docs { flex-direction: row; flex-wrap: wrap; gap: 8px; }
.docs-fila .docs li { border: 1px solid var(--border); border-radius: 10px; padding: 6px 12px 6px 8px; flex: 1 1 200px; }
.tabla--matriz tbody th { text-transform: none; letter-spacing: 0; color: var(--text); font-size: 13.5px; }
.tabla--matriz tbody th b { font-weight: 650; }
.mx-celda b, .mx-total b { white-space: nowrap; }
.crit li { padding: 8px 10px; }
.crit__txt b { line-height: 1.3; }
.tabla--matriz tr > :first-child { position: sticky; left: 0; z-index: 1; min-width: 150px; box-shadow: 1px 0 0 var(--border); }
.tabla--matriz thead tr > :first-child { background: var(--surface); }
.celda-det .hecho { white-space: normal; }
@media (max-width: 560px) { .tabla--matriz tr > :first-child { min-width: 128px; } .mx-rank { margin-right: 4px; } }
