/* calidad-cm.css — Calidad en el TELEFONO (html.mv) · observaciones CM1–CM3 de VIDEOS/plan-calidad.md
 *
 * Solo presentacion y solo con html.mv.cd1-cal (la clase la pone assets/calidad-cd1.js mientras la
 * vista activa es de Calidad). Escritorio no cambia: nada de aqui casa sin .mv. Se deshace quitando
 * su <link>.
 * Esta hoja carga en el <head>, ANTES que movil/estilos.css (final del <body>): a igual especificidad
 * gana la capa. Por eso cada regla que compite lleva :not(#cm1a) (suma un id) y, si la de la capa es
 * !important o un comodin de la capa, !important — el comentario dice a quien le gana.
 */

/* ── G01 · sin MAYUSCULAS en Calidad (R-101 y R-209 aplicados a Calidad) ──────────────────── */
html.mv.cd1-cal:not(#cm1a) :is(#sec-panel-calidad,#sec-calidad-sig,#sec-calidad-nc,#sec-calidad-cap,#sec-calidad-dossier,#sec-calidad-gestionsig,#sec-calidad-equipos,#sec-sames,#sec-docref) *:not(table.sigf, table.sigf *){
  text-transform:none !important;   /* cal-base: el formato SIG oficial (table.sigf) conserva su caja */   /* gana a «.mv-ncr .insp-est{text-transform:uppercase}» (estilos.css ~3462) */
}

/* ── R-410 · estados con el semaforo del estandar y suaves; minimo de rotulo 12,5 ──────────── */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) [data-cd1]{
  display:inline-flex !important; align-items:center !important; gap:4px !important;
  font:700 12.5px/17px 'Inter',sans-serif !important; letter-spacing:normal !important;
  padding:3px 9px !important; border-radius:8px !important; border:0 !important; white-space:nowrap !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) [data-cd1="ok"]{  color:#15803d !important; background:#e9f9ef !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) [data-cd1="seg"]{ color:#c2410c !important; background:#fff4e9 !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) [data-cd1="no"]{  color:#b91c1c !important; background:#fef2f2 !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) [data-cd1="sd"]{  color:#6b7a88 !important; background:#edf1f6 !important; }

/* ── R-409 · R-412 · R-422 · cada registro en su tarjeta blanca (Figma 833:981) ────────────────
   Medido: la tarjeta .mv-ncr ya la define estilos.css (blanca, borde #D9DADB, radio 12) pero no se
   ve: armazon.js la marca data-mv-contenedor="1" y «html.mv [data-mv-contenedor="1"]{background:
   transparent !important; border:0 !important}» la aplana. En Calidad se rescata (y con la sombra
   suave de G09). */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) :is(#sec-calidad-nc,#sec-calidad-sig,#sec-calidad-cap,#sec-calidad-dossier,#sec-calidad-gestionsig) .mv-ncr:not(.mv-ncr-det){
  background:#fff !important; border:1px solid #D9DADB !important; border-radius:12px !important;
  box-shadow:0 1px 4px rgba(0,0,0,.05) !important; padding:14px !important;
}
/* Filete entre bloques de la tarjeta hasta el borde: el ancho lo da el relleno, no el separador. */

/* ── G05 · «+ Agregar registro» con el icono de calidad-cd1.js (en el teléfono sin tamaño salía de
   300 px: un <svg> sin medida propia toma el ancho de su caja). */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #scrollArea .rfi-btn-primary:has(.cd1-ico){
  display:flex !important; align-items:center !important; justify-content:center !important; gap:6px !important;
}
html.mv.cd1-cal .cd1-ico{ width:16px !important; height:16px !important; flex:0 0 16px !important; }

/* ── R-405 · pestañas centradas («Registro de Inspecciones | Indicadores») ───────────────────
   «safe»: si las pestañas no caben (Equipos tiene 3), no se cortan por la izquierda. */
html.mv.cd1-cal:not(#cm1a) :is(#sec-calidad-nc,#sec-calidad-sig,#sec-calidad-cap,#sec-calidad-gestionsig,#sec-calidad-equipos,#sec-sames) :is(.rfi-tabs,.sst-tabs){
  justify-content:safe center !important;
}

/* ── R-406 · R-414 · R-415 · R-407 · KPI de Indicadores en carril ───────────────────────────
   Lo pidieron «igual que el carrusel ya aprobado»: el mismo carril de Resumen (#rKpiGrid en
   movil/estilos.css: 78 %, tope 320, hueco 10, encaje al inicio). Deshace la «tarjeta única con una
   fila por KPI» de movil/estilos.css (~3608-3690), que es la que el revisor observó.
   Todas las tarjetas son el mismo componente: rótulo, cifra, explicación y pie con su pastilla (R-407;
   los pies de Inspecciones ya los puso D-144). Todo con !important: la capa marca !important en
   display, rejilla, relleno y borde de .kpi-card. */
html.mv.cd1-cal:not(#cm1a):not(#cm1b):not(#cm1c) :is(#ncPane-indicadores,#inspPane-indicadores,#capregPane-indicadores,#gsigPane-indicadores) .kpi-strip{
  display:flex !important; flex-direction:row !important; gap:10px !important; align-items:stretch !important;
  overflow-x:auto !important; scrollbar-width:none; scroll-snap-type:x mandatory; scroll-padding-inline:16px;
  overscroll-behavior-x:contain; -webkit-overflow-scrolling:touch;
  margin:0 -16px 14px !important; padding:2px 16px 8px !important;
  background:none !important; border:0 !important; border-radius:0 !important; box-shadow:none !important;
}
html.mv.cd1-cal :is(#ncPane-indicadores,#inspPane-indicadores,#capregPane-indicadores,#gsigPane-indicadores) .kpi-strip::-webkit-scrollbar{ width:0; height:0; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b):not(#cm1c) :is(#ncPane-indicadores,#inspPane-indicadores,#capregPane-indicadores,#gsigPane-indicadores) .kpi-card{
  flex:0 0 78% !important; max-width:320px !important; min-width:0 !important; scroll-snap-align:start;
  display:flex !important; flex-direction:column !important; align-items:stretch !important; gap:4px !important;
  padding:16px !important; background:#fff !important;
  border:1px solid #D9DADB !important; border-radius:12px !important; box-shadow:0 1px 4px rgba(0,0,0,.05) !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b):not(#cm1c) :is(#ncPane-indicadores,#inspPane-indicadores,#capregPane-indicadores,#gsigPane-indicadores) .kpi-value{
  order:1; justify-self:auto !important; text-align:left !important;
  font:700 28px/32px 'Inter',sans-serif !important; color:#0e1726 !important;   /* la cifra del modelo (Resumen / escritorio D-204) */
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b):not(#cm1c) :is(#ncPane-indicadores,#inspPane-indicadores,#capregPane-indicadores,#gsigPane-indicadores) .kpi-value[data-mv-vacio="1"]{ color:#A3A7AE !important; font-size:24px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b):not(#cm1c) :is(#ncPane-indicadores,#inspPane-indicadores,#capregPane-indicadores,#gsigPane-indicadores) .kpi-label{ order:0; margin:0 !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b):not(#cm1c) :is(#ncPane-indicadores,#inspPane-indicadores,#capregPane-indicadores,#gsigPane-indicadores) .kpi-sublabel{ order:2; font-size:13px !important; }
/* El pie baja al fondo: en el carril las tarjetas miden lo mismo y sus pies quedan alineados. */
html.mv.cd1-cal:not(#cm1a):not(#cm1b):not(#cm1c) :is(#ncPane-indicadores,#inspPane-indicadores,#capregPane-indicadores,#gsigPane-indicadores) .kpi-meta-footer{
  order:3; margin:auto 0 0 !important; padding:10px 0 0 !important; flex-wrap:wrap !important;
}

/* ── R-419 · R-421 · Gestión SIG › Indicadores ────────────────────────────────────────────── */
/* R-421: el mismo aire que ya lleva escritorio (calidad-cd1.css #calSIGBloques). Gana al gap:8px en línea. */
html.mv.cd1-cal:not(#cm1a) #calSIGBloques{ gap:16px !important; margin-top:14px !important; }
html.mv.cd1-cal:not(#cm1a) #calSIGBloques > div > div > div:nth-child(2){ height:10px !important; margin-top:8px !important; }
html.mv.cd1-cal:not(#cm1a) #gsigPane-indicadores .mv-ncr-caja-det .mv-ncr{ padding:14px 0 !important; }

/* ── D02 en el teléfono · ficha de la obra y «Descargar resumen» del Panel de Calidad (calidad-cd1.js
   panelCabecera). Modelo: Panel de Operaciones a 700 px (assets/ui/panel-operaciones.css): la ficha
   baja a su renglón y se reparte; la descarga es el principal a todo el ancho (G05 · M07); rótulos
   ≥ 12 px (G04). Mismos valores que escritorio para letra y color (calidad-cd1.css D-139). ── */
html.mv.cd1-cal #sec-panel-calidad .pcz-cab{ flex-wrap:wrap; }
html.mv.cd1-cal #sec-panel-calidad .cd1-meta{ display:flex; flex-wrap:wrap; order:3; flex:1 1 100%; min-width:0; gap:10px 16px; padding:0; }
html.mv.cd1-cal #sec-panel-calidad .cd1-m{ display:flex; flex-direction:column; gap:2px; min-width:0; flex:1 1 calc(50% - 8px); }
html.mv.cd1-cal #sec-panel-calidad .cd1-m-dir{ flex-basis:100%; }
html.mv.cd1-cal #sec-panel-calidad .cd1-m-l{ font:500 12px/1.35 'Inter',sans-serif; color:#5D6879; }
html.mv.cd1-cal #sec-panel-calidad .cd1-m-v{ font:500 13px/1.35 'Inter',sans-serif; color:#22262D; overflow-wrap:anywhere; }
html.mv.cd1-cal #sec-panel-calidad .cd1-dl{
  order:4; flex:1 1 100%; display:inline-flex; align-items:center; justify-content:center; gap:8px; min-height:44px;
  padding:0 16px; border:0; border-radius:999px; color:#fff; background:#077FCF; font:500 14px/normal 'Inter',sans-serif; cursor:pointer;
}
html.mv.cd1-cal #sec-panel-calidad .cd1-dl:focus-visible{ outline:2px solid #077FCF; outline-offset:2px; }
html.mv.cd1-cal #sec-panel-calidad .cd1-dl .cd1-ico{ width:18px !important; height:18px !important; flex:0 0 18px !important; }   /* como .pz-dl en el telefono */

/* ── R-420 · gráfico ampliado: hoja desde abajo con alto contenido, no 84vh ──────────────────
   La ventana es de toda la app (#chartMaxOverlay, index.html ~47618); cd1-cal solo está en <html>
   mientras se ve Calidad, así que las demás vistas la siguen viendo igual. */
html.mv.cd1-cal:not(#cm1a) .chart-max-ov{ align-items:flex-end !important; padding:0 !important; }
html.mv.cd1-cal:not(#cm1a) .chart-max-box{
  width:100% !important; max-width:none !important; height:auto !important; max-height:88dvh !important;
  border-radius:18px 18px 0 0 !important; padding-bottom:env(safe-area-inset-bottom, 0px);
}
html.mv.cd1-cal:not(#cm1a) .chart-max-head{ padding:16px 16px 6px !important; }
html.mv.cd1-cal:not(#cm1a) .chart-max-title{ white-space:normal !important; }
html.mv.cd1-cal:not(#cm1a) .chart-max-close{ min-height:44px !important; padding:0 16px !important; border-radius:999px !important; font-size:13px !important; }
html.mv.cd1-cal:not(#cm1a) .chart-max-canvas-wrap{ flex:none !important; height:340px !important; padding:4px 12px 18px !important; }

/* ══ Documentación referencial de Calidad en el teléfono (R-427 · R-428 · R-429 · R-430 · R-432 · G12)
   #sec-docref es de las 6 áreas: todo va bajo html.mv.cd1-cal, que solo existe con docref-calidad
   abierta (calidad-cd1.js). Los nodos, el plegado y las acciones son los originales. ═══════════════ */
html.mv.cd1-cal:not(#cm1a) #sec-docref .cd1-desc{ font:400 13px/18px 'Inter',sans-serif; color:#5b6b7b; margin-top:4px; }

/* R-428 · sin «Ocultar visor»: en el teléfono el visor no convive con la lista (R-430). */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-tb > .dref-btn[onclick^="drefSoloArbol"]{ display:none !important; }
/* R-427 · la fila de botones centrada y sin corte (antes «Añadir ar…» se salía de la pantalla). */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-tb{ justify-content:center !important; width:100%; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-tb > .dref-sp{ display:none !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-btn{ border-radius:999px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-btn:not(.gris){ background:#0070B4 !important; border-color:#0070B4 !important; color:#fff !important; }

/* R-432 · el buscador con la misma medida y forma que el de las listas (.mv-buscar: 42, radio 11,
   sombra, sin borde). Gana a [data-mv-anidada]{padding:13px 14px} de la capa. */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-nav{ gap:8px !important; padding:10px 0 !important; border:0 !important; align-items:stretch !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-buscar{
  min-height:42px !important; padding:0 12px !important; border:0 !important; border-radius:11px !important;
  background:#fff !important; box-shadow:0 1px 4px rgba(0,0,0,.05), 0 0 0 1px #E5E9EF !important; gap:9px !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-buscar input{ padding:11px 0 !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-buscar svg{ width:16px !important; height:16px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-modo{ border-radius:11px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-modo button{ min-width:44px !important; min-height:42px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-modo button.act{ background:#0070B4 !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-modo svg{ width:16px !important; height:16px !important; margin:auto; }

/* R-429 · carpetas como tarjetas y navegación por niveles, sin árbol desplegable.
   La carpeta «actual» es la seleccionada y abierta (drefClicCarpeta: 1er toque selecciona y abre,
   2º toque sobre la misma la cierra). En cada nivel que la contiene solo quedan la ruta (antecesoras y
   la actual, como migas) y el contenido de la actual. Tocar una miga sube a ese nivel; tocar la
   actual la cierra y vuelve arriba. Nada se reimplementa: es el mismo clic. */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref :is(#drefArbol,.dref-hijos):has([data-cm-actual]) > :not([data-cm-actual]):not(.dref-nodo:has(+ .dref-hijos [data-cm-actual])):not(.dref-hijos:has([data-cm-actual])):not([data-cm-actual] + .dref-hijos){
  display:none !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref :is(#drefArbol,.dref-hijos){ display:flex !important; flex-direction:column !important; gap:8px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-hijos{ margin:0 !important; padding:0 !important; border:0 !important; }
/* Cada carpeta o archivo, una tarjeta. */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-nodo{
  margin:0 !important; min-height:56px !important; padding:10px 12px !important;
  background:#fff !important; border:1px solid #D9DADB !important; border-radius:12px !important;
  box-shadow:0 1px 4px rgba(0,0,0,.05) !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-carpeta > svg{ width:24px !important; height:24px !important; color:#E8A33D; }
/* El triángulo del árbol sobra: la carpeta se «entra», no se despliega. La flecha a la derecha lo dice. */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-chev{ display:none !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-carpeta:not(.abierta)::after{
  content:""; flex:0 0 8px; width:8px; height:8px; margin:0 4px 0 2px;
  border-right:2px solid #9AA6B2; border-top:2px solid #9AA6B2; transform:rotate(45deg);
}
/* Migas: la ruta hasta la carpeta actual, plana y con «‹» delante (se toca para volver). */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref :is([data-cm-actual], .dref-nodo:has(+ .dref-hijos [data-cm-actual])){
  min-height:44px !important; background:transparent !important; border:0 !important; box-shadow:none !important;
  padding:6px 2px !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref :is([data-cm-actual], .dref-nodo:has(+ .dref-hijos [data-cm-actual]))::before{
  content:""; flex:0 0 9px; width:9px; height:9px; margin:0 4px 0 6px;
  border-left:2px solid #0070B4; border-bottom:2px solid #0070B4; transform:rotate(45deg);
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-nodo:has(+ .dref-hijos [data-cm-actual]) .dref-nom{ color:#0070B4 !important; font-weight:600 !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-nodo:has(+ .dref-hijos [data-cm-actual]) :is(.dref-acc,.dref-cont,.dref-chip-auto,svg){ display:none !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref [data-cm-actual] .dref-nom{ font-size:16px !important; }
/* Una carpeta abierta sin nada dentro lo dice, en vez de dejar la pantalla en blanco. */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref [data-cm-actual]:not(:has(+ .dref-hijos)){ position:relative; margin-bottom:40px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref [data-cm-actual]:not(:has(+ .dref-hijos))::after{
  content:"Carpeta vacía"; position:absolute; left:0; right:0; top:calc(100% + 12px); text-align:center;
  font:400 13px/18px 'Inter',sans-serif; color:#6b7a88;
}

/* El archivo no tiene contador: la píldora vacía que dejaba .dref-cont se quita. */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-nodo > .dref-cont:empty{ display:none !important; }

/* D-136 en el teléfono · el «⋯» de calidad-cd1.js con medida táctil; su menú flota fijo sobre todo. */
html.mv.cd1-cal .cd1-menu{ position:relative; display:inline-flex; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .cd1-keb{
  width:44px !important; height:44px !important; min-width:44px !important; min-height:44px !important; padding:0 !important;
  display:inline-flex !important; align-items:center !important; justify-content:center !important;
  border:0 !important; border-radius:999px !important; background:transparent !important; color:#42526B !important;
}
html.mv.cd1-cal #sec-docref .cd1-keb svg{ width:18px; height:18px; }
html.mv.cd1-cal .cd1-pop{ display:none; position:fixed; z-index:100060; min-width:200px; padding:6px;
  background:#fff; border:1px solid #e2e8f0; border-radius:12px; box-shadow:0 10px 28px rgba(16,24,40,.18); }
html.mv.cd1-cal .cd1-menu.abierto .cd1-pop{ display:block; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) .cd1-pop .cd1-pop-i{
  display:flex !important; align-items:center !important; justify-content:flex-start !important; gap:10px !important;
  width:100% !important; min-height:44px !important; padding:0 12px !important; margin:0 !important;
  border:0 !important; border-radius:8px !important; background:transparent !important; color:#0e1726 !important; box-shadow:none !important;
  font:500 14px 'Inter',sans-serif !important; white-space:nowrap;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) .cd1-pop .cd1-pop-i.cd1-peligro{ color:#b91c1c !important; }
html.mv.cd1-cal .cd1-pop .cd1-pop-i svg{ width:16px !important; height:16px !important; flex:0 0 16px; }

/* ── R-201 aplicado a Calidad (R-404 · R-418): ningún texto por debajo de 12 px en el teléfono, y el
   mismo tamaño para el mismo tipo de texto secundario. Medido a 390: eje del gráfico del Panel 11,
   pies de meta 11,5; código y datos de las listas genéricas 10,5 / 11,5; contadores de Docref 10 y
   la píldora «automática» 8,5. ───────────────────────────────────────────────────────────── */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-panel-calidad svg text{ font-size:12px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-panel-calidad .kpi-meta-target{ font-size:12px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) .mv-registros :is(.mv-registros-cuenta, .mv-registros-cuenta b){ font-size:12.5px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) .mv-registros .mv-reg-cod{ font-size:12px !important; letter-spacing:.02em; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) .mv-registros .mv-reg-meta{ font-size:13px !important; line-height:18px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-arbol-cab,
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-arbol-cab *{ font-size:12.5px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-nodo > .dref-cont{ font:700 12px/1 'Inter',sans-serif !important; padding:4px 8px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-chip-auto{ font:600 12px/1 'Inter',sans-serif !important; padding:4px 8px !important; border-radius:8px !important; white-space:nowrap; }
/* SAME: cabeceras de la tabla de estatus a 11 px. (Las mayúsculas que quedan son DATOS escritos por el
   usuario —siglas IIMM, IISS, PTAG, «ARQUITECTURA»—: no se transforman.) */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-sames th{ font-size:12px !important; }
/* Toques: las pestañas de Equipos medían 42 y el conmutador carpetas/lista 42. */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) :is(#sec-calidad-equipos,#sec-sames,#sec-calidad-cap,#sec-calidad-nc,#sec-calidad-sig,#sec-calidad-gestionsig) .insp-cab-tabs button{ min-height:44px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-modo button{ min-height:44px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-buscar{ min-height:44px !important; }

/* R-416 · «Mis capacitaciones» como la Bandeja (valores de #sec-central .oc-card / .oc-top / .oc-tit /
   .fch en index.html). La tabla original queda oculta en el teléfono; en escritorio no hay .cm-mias. */
.cm-mias{ display:none; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #capregPane-mios:has(.cm-mias) :is(.rfi-table-wrap, .mv-ncr-caja-lista){ display:none !important; }
html.mv.cd1-cal #capregPane-mios .cm-mias{ display:flex; flex-direction:column; gap:12px; margin:4px 0 12px; }
html.mv.cd1-cal #capregPane-mios .cm-mia{ background:#fff; border:1px solid #ECEEF2; border-radius:20px; padding:15px 18px;
  box-shadow:0 4px 4px rgba(0,0,0,.05); }
html.mv.cd1-cal #capregPane-mios .cm-mia-top{ display:flex; align-items:center; gap:12px; margin-bottom:8px; }
html.mv.cd1-cal #capregPane-mios .cm-mia-fch{ margin-left:auto; font:400 14px/22px 'Inter',sans-serif; color:#4B5563; font-variant-numeric:tabular-nums; white-space:nowrap; }
html.mv.cd1-cal #capregPane-mios .cm-mia-tit{ font:700 16px/22px 'Inter',sans-serif; color:#4B5563; margin-bottom:10px; overflow-wrap:anywhere; }
html.mv.cd1-cal #capregPane-mios .cm-mia-pie{ display:flex; flex-wrap:wrap; gap:4px 18px; padding-top:10px; border-top:1px solid #edf1f6;
  font:400 14px/22px 'Inter',sans-serif; color:#2A2D34; }
html.mv.cd1-cal #capregPane-mios .cm-mia-lbl{ color:#6b7a88; margin-right:6px; }
html.mv.cd1-cal #capregPane-mios .cm-mia-pie b{ font-weight:600; }

/* R-413 · desplegable propio (hoja desde abajo, calidad-cd1.js hojaSelect). Mismo patrón que las
   ventanas del teléfono: velo con desenfoque, radio 18 arriba, asa, renglones de 48, marcado en azul. */
.cm-sel-ov{ position:fixed; inset:0; z-index:100070; display:flex; align-items:flex-end;
  background:rgba(16,24,40,.45); -webkit-backdrop-filter:blur(4px); backdrop-filter:blur(4px); animation:cmVelo .16s ease-out; }
.cm-sel-hoja{ position:relative; width:100%; max-height:70dvh; display:flex; flex-direction:column; background:#fff;
  border-radius:18px 18px 0 0; padding:18px 12px calc(12px + env(safe-area-inset-bottom, 0px)); box-shadow:0 -10px 30px rgba(16,24,40,.18);
  animation:cmSube .2s ease-out; }
.cm-sel-hoja::before{ content:""; position:absolute; top:7px; left:50%; width:36px; height:4px; margin-left:-18px; border-radius:4px; background:#D9DADB; }
.cm-sel-cab{ display:flex; align-items:center; justify-content:space-between; gap:12px; padding:4px 4px 8px 8px; }
.cm-sel-tit{ font:700 16px/22px 'Inter',sans-serif; color:#0e1726; }
.cm-sel-x{ flex:0 0 44px; width:44px; height:44px; display:inline-flex; align-items:center; justify-content:center; border:1px solid #D9DADB; border-radius:999px; background:#fff; color:#334155; padding:0; }
.cm-sel-ops{ overflow-y:auto; overscroll-behavior:contain; display:flex; flex-direction:column; }
.cm-sel-op{ display:flex; align-items:center; justify-content:space-between; gap:12px; width:100%; min-height:48px !important; height:auto !important; padding:0 12px;
  border:0; border-radius:10px; background:transparent; color:#0e1726; font:500 15px/20px 'Inter',sans-serif; text-align:left; }
.cm-sel-op + .cm-sel-op{ margin-top:2px; }
.cm-sel-op.on{ background:#EAF4FB; color:#0070B4; font-weight:700; }
.cm-sel-op svg{ flex:0 0 18px; }
@keyframes cmVelo{ from{ opacity:0; } }
@keyframes cmSube{ from{ transform:translateY(24px); opacity:.6; } }

/* R-430 · el visor no va incrustado: vacío no se ve; con un archivo abierto ocupa la pantalla
   entera, con su ✕ (calidad-cd1.js). Gana a `.dref-grid.solo-arbol .dref-visor-col{display:none}`. */
.cm-visor-x{ display:none; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-col:has(#drefVisor > .dref-nada),
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-col[data-cm-cerrado]{ display:none !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-col:not(:has(#drefVisor > .dref-nada)):not([data-cm-cerrado]){
  display:flex !important; flex-direction:column !important;
  position:fixed !important; inset:0 !important; z-index:100050 !important;
  width:auto !important; height:auto !important; max-height:none !important; margin:0 !important;
  border:0 !important; border-radius:0 !important; background:#fff !important;
  padding-top:env(safe-area-inset-top, 0px) !important; padding-bottom:env(safe-area-inset-bottom, 0px) !important;
}
/* Cabecera del visor en dos filas: el nombre del archivo arriba (la ✕ a su derecha), y debajo
   flechas, tamaño y «Descargar». El botón de pantalla completa sobra: ya lo está. */
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-col .dref-visor-cab{
  display:flex !important; flex-wrap:wrap !important; align-items:center !important; gap:6px 10px !important;
  padding:12px 16px 10px !important; min-height:0 !important; border-bottom:1px solid #edf1f6 !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-cab .dref-cab-txt{
  order:0; flex:1 1 100% !important; min-width:0 !important; width:auto !important; padding-right:52px; min-height:44px;
  display:flex !important; flex-direction:column !important; justify-content:center !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-cab .dref-cab-txt .dref-t{
  font:700 15px/20px 'Inter',sans-serif !important; white-space:normal !important; overflow-wrap:anywhere; width:auto !important; max-width:none !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-cab .dref-cab-txt .dref-ruta{
  font:400 12.5px/17px 'Inter',sans-serif !important; color:#6b7a88 !important; white-space:normal !important; width:auto !important; max-width:none !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-cab .dref-flechas{ order:1; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-cab .dref-flechas button{ min-width:44px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-cab .dref-meta{ order:2; flex:1 1 0 !important; min-width:0; font-size:12.5px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-cab > .dref-btn.gris:not(.dref-descargar){ display:none !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-cab > .dref-descargar{
  order:3; flex:0 0 auto !important; width:auto !important; min-width:0 !important; min-height:44px !important; padding:0 16px !important;
  border-radius:999px !important; background:#0070B4 !important; border-color:#0070B4 !important; color:#fff !important;
  display:inline-flex !important; align-items:center !important; gap:6px !important; white-space:nowrap !important; font-size:13px !important;
}
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-cab > .dref-descargar svg{ width:15px !important; height:15px !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .dref-visor-col .dref-visor{ flex:1 1 auto !important; min-height:0 !important; height:auto !important; }
html.mv.cd1-cal:not(#cm1a):not(#cm1b) #sec-docref .cm-visor-x{
  display:inline-flex; align-items:center; justify-content:center;
  position:absolute; top:calc(8px + env(safe-area-inset-top, 0px)); right:10px; z-index:2;
  width:44px; height:44px; border-radius:999px; border:1px solid #D9DADB; background:#fff; color:#334155; padding:0;
}
