/*! Gestión de empleados · Ajustes (se cargan después de app.css y antes de encabezado.css).
   Agrupados por tema; dentro de cada grupo se conserva el orden en que se agregaron. */

/* ==================== 1. Celular (iPhone y Android) ==================== */
/* iPhone y celulares: Safari hace zoom al tocar un campo con letra menor a 16 px; en pantallas táctiles todos los campos usan 16 px */
@media (hover:none) and (pointer:coarse){
  input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]):not([type=file]),select,textarea{font-size:16px!important;}
}

/* ==================== 2. Tableta (iPad y pantallas medianas) ==================== */
/* Tableta (iPad) y pantallas medianas: pestañas que se deslizan, filtros en renglones parejos */
@media (min-width:701px) and (max-width:1100px){
  html body .qt-tabs,html body #lhTabs .qt-tabs.lh-tabs,html body .lh-tabs.qt-tabs:not(:has(> :nth-child(8))){display:flex!important;grid-template-columns:none!important;overflow-x:auto;scrollbar-width:none;gap:4px;}
  html body .qt-tabs::-webkit-scrollbar{display:none;}
  html body .qt-tabs > .vt,html body #lhTabs .qt-tabs.lh-tabs > .vt{flex:0 0 auto!important;padding:0 14px!important;white-space:nowrap;gap:8px;}
  html body .qt-tabs .vt-n{margin-left:2px;}
  #tbRow{flex-wrap:wrap!important;row-gap:10px!important;}
  #tbRow > .search{flex:1 1 100%!important;max-width:none!important;order:-2;}
  #tbRow .filters > label:not(.qt-oculto){flex:1 1 22%!important;min-width:150px!important;max-width:none!important;}
  #tbRow .filters > label select{width:100%!important;}
  #tbRow .filters > .vistas{flex:1 1 auto;order:5;min-width:0;}
  #tbRow .filters > .fcount{order:6;margin-left:auto;}
  #tbRow .filters > .lista-acc{order:7;}
  /* Prenómina: barra de vistas a lo ancho y los dos botones abajo, mitad y mitad; tarjetas de 2 en 2 */
  .pn-vbar{flex-wrap:wrap!important;}
  .pn-vbar .lh-tabs{flex:1 1 100%!important;}
  .pn-vbar .pn-vbtn{flex:1 1 100%!important;display:grid!important;grid-template-columns:1fr 1fr;gap:10px;}
  .pn-vbar .pn-vbtn .btn{width:100%;justify-content:center;}
  html body #pRes.pn-kpis{grid-template-columns:repeat(2,minmax(0,1fr))!important;}
}
/* Tableta: la barra de Asistencia igual que las demás (icono a la izquierda del texto, se desliza si no cabe) */
@media (min-width:701px) and (max-width:1100px){
  html body .asis-nav,html body #lhTabs .asis-nav{display:flex!important;flex-wrap:nowrap!important;overflow-x:auto!important;scrollbar-width:none;gap:4px!important;}
  html body .asis-nav::-webkit-scrollbar{display:none;}
  html body .asis-nav > button,html body #lhTabs .asis-nav > button{flex:0 0 auto!important;flex-direction:row!important;align-items:center!important;justify-content:center!important;gap:8px!important;padding:10px 14px!important;min-height:44px;white-space:nowrap;}
  html body .asis-nav > button svg{margin:0!important;}
}
/* Tableta: tablas de Administración como tabla (no tarjetas), y tarjetas del Tablero de 3 en 3 */
@media (min-width:701px) and (max-width:860px){
  html body .utable{display:table!important;width:100%!important;}
  html body .utable thead{display:table-header-group!important;}
  html body .utable tbody{display:table-row-group!important;}
  html body .utable tr{display:table-row!important;padding:0!important;border:0!important;}
  html body .utable th,html body .utable td{display:table-cell!important;width:auto!important;padding:8px 10px!important;border-bottom:1px solid var(--line)!important;vertical-align:middle;}
  html body .utable td::before{content:none!important;}
  html body .u-scroll{overflow-x:auto!important;}
}
@media (min-width:701px) and (max-width:1100px){
  html body .dash-kpis{grid-template-columns:repeat(3,minmax(0,1fr))!important;}
  html body .da-ks{grid-template-columns:repeat(3,minmax(0,1fr))!important;}
}
/* Tableta: las tablas (menos la lista de Candidatos) conservan su tarjeta blanca; sin la franja blanca de la columna fija */
@media (min-width:701px) and (max-width:899px){
  .tbl-wrap:not(:has(.recs)),.bit-tw{background:var(--surface)!important;border:1px solid var(--line)!important;border-radius:14px!important;overflow:auto!important;}
}
/* Tableta: filtros de la Bitácora parejos (buscador, guardia y acción arriba; fechas y «Rápido» abajo) */
@media (min-width:701px) and (max-width:1100px){
  .bit-filtros{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px 12px!important;align-items:end;}
  .bit-filtros > .search{grid-column:1/3;max-width:none!important;width:100%!important;margin:0!important;}
  .bit-filtros > .filters{display:contents!important;}
  .bit-filtros .filters > label{min-width:0!important;max-width:none!important;width:auto!important;margin:0!important;}
  .bit-filtros .filters > label input,.bit-filtros .filters > label select{width:100%!important;box-sizing:border-box;}
  .bit-filtros .bf-rap{grid-column:3/5;align-self:end;flex-wrap:wrap;margin:0!important;}
  .bit-filtros .fcount{grid-column:1/-1;justify-self:end;margin:0!important;}
}
@media (min-width:701px) and (max-width:1100px){
  .bit-filtros > .sr,.bit-filtros datalist,.bit-filtros input[type=hidden]{position:absolute!important;width:1px!important;height:1px!important;overflow:hidden;grid-area:auto!important;}
  .bit-filtros > .search{grid-row:1!important;grid-column:1/3!important;}
  .bit-filtros .filters > label.bf-g{grid-row:1!important;grid-column:3/5!important;}
  .bit-filtros .filters > label:nth-of-type(2){grid-row:2!important;grid-column:1!important;}
  .bit-filtros .filters > label:nth-of-type(3){grid-row:2!important;grid-column:2!important;}
  .bit-filtros .filters > label:nth-of-type(4){grid-row:2!important;grid-column:3!important;}
  .bit-filtros .bf-rap{grid-row:3!important;grid-column:1/4!important;align-self:center;}
  .bit-filtros .fcount{grid-row:3!important;grid-column:4!important;align-self:center;}
}


/* ==================== 3. Módulos: IMSS, Pendientes, Sesiones, menú «⋯», Papelera, Ayuda, Capacitaciones, Préstamos ==================== */
/* Aviso: personal sin comprobante del IMSS */
.imss-av{display:flex;align-items:center;gap:12px;margin:0 0 12px;padding:12px 14px;border:1px solid rgba(233,160,32,.5);background:rgba(233,160,32,.10);border-radius:12px;}.imss-av > span{font-size:20px;}.imss-av div{flex:1;display:grid;gap:2px;}.imss-av small{color:var(--muted);font-size:12.5px;}
.imss-dlg{width:min(820px,96vw);max-width:96vw;padding:0;}.imss-h{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;padding:16px 18px;border-bottom:1px solid var(--line);}.imss-h h3{margin:0;}.imss-h p{margin:2px 0 0;color:var(--muted);font-size:13px;}
.imss-b{padding:4px 18px 18px;max-height:70vh;overflow:auto;}.imss-b h4{display:flex;align-items:center;gap:8px;margin:14px 0 6px;font-size:13px;letter-spacing:.06em;text-transform:uppercase;}.imss-b h4 span{font-size:12px;padding:1px 8px;border-radius:99px;background:rgba(233,160,32,.2);}
.imss-t{width:100%;border-collapse:collapse;font-size:13.5px;}.imss-t td{padding:8px;border-bottom:1px solid var(--line);vertical-align:middle;}.imss-t small{display:block;color:var(--muted);font-size:12px;}.imss-t td.r{text-align:right;white-space:nowrap;}
@media (max-width:700px){.imss-av{flex-wrap:wrap;}.imss-av .btn{width:100%;}.imss-t .hm{display:none;}}

/* Pendientes: widgets acomodables */
#pendView.pd-ws{display:flex;flex-direction:column;}#pendView.pd-ws > .pd-top{order:-1;}#pendView.pd-ws > [hidden]{display:none!important;}
#pendView .pd-top{position:relative;}.pw-btn{display:inline-flex;align-items:center;gap:6px;height:36px;padding:0 12px;font-size:13px;}
.pw-dlg{width:min(460px,94vw);}.pw-l{list-style:none;margin:10px 0;padding:0;display:grid;gap:6px;}.pw-l li{display:flex;align-items:center;gap:10px;padding:10px 12px;border:1px solid var(--line);border-radius:12px;background:var(--surface);}.pw-l li.off span{color:var(--muted);}.pw-l li span{flex:1;font-weight:600;font-size:14px;}.pw-l small{font-weight:400;color:var(--muted);font-size:12px;}
.pw-m{all:unset;cursor:pointer;width:30px;height:30px;display:grid;place-items:center;border:1px solid var(--line);border-radius:8px;font-size:11px;color:var(--ink);}.pw-m:disabled{opacity:.3;cursor:default;}
.pw-sw{position:relative;width:40px;height:22px;flex:0 0 auto;}.pw-sw input{position:absolute;opacity:0;inset:0;margin:0;cursor:pointer;width:100%!important;height:100%!important;z-index:1;}.pw-sw i{position:absolute;inset:0;border-radius:99px;background:rgba(127,127,160,.35);transition:.15s;}.pw-sw i::after{content:"";position:absolute;top:3px;left:3px;width:16px;height:16px;border-radius:50%;background:#fff;transition:.15s;}.pw-sw input:checked+i{background:#1E8E5E;}.pw-sw input:checked+i::after{left:21px;}
.pw-a{display:flex;gap:8px;align-items:center;}
/* Sesiones activas en el celular: una tarjeta por sesión (nombre y botón arriba, equipo y horarios abajo) */
@media (max-width:700px){
  #sTabla thead{display:none!important;}
  #sTabla,#sTabla tbody{display:block!important;width:100%!important;min-width:0!important;}
  #sTabla tr{display:grid!important;grid-template-columns:minmax(0,1fr) auto;gap:3px 12px;align-items:center;padding:12px 14px!important;border-bottom:1px solid var(--line);}
  #sTabla tr:last-child{border-bottom:0;}
  #sTabla td{display:block!important;padding:0!important;border:0!important;white-space:normal!important;min-width:0;text-align:left!important;height:auto!important;}
  #sTabla td:nth-child(1){grid-column:1;grid-row:1;font-size:15px;}
  #sTabla td.r{grid-column:2;grid-row:1/span 2;align-self:start;}
  #sTabla td:nth-child(2),#sTabla td:nth-child(3),#sTabla td:nth-child(4){grid-column:1;font-size:13px;color:var(--muted);}
  #sTabla td:nth-child(3)::before{content:"Desde: ";font-weight:600;}
  #sTabla td:nth-child(4)::before{content:"Última actividad: ";font-weight:600;}
  #sTabla td:nth-child(2) .ses-sub{display:inline!important;margin-left:6px;}
  #sTabla td:nth-child(1) .ses-sub{display:block!important;font-size:12.5px;color:var(--muted);}
  #sTabla td.r .btn{height:36px;padding:0 14px;white-space:nowrap;}
  #sTabla .oc-th-acc,#sTabla .cols-th{display:none!important;}
}
/* Menú «⋯» de las tablas en el celular: hoja desde abajo (el menú se mueve al cuerpo de la página para que nada lo recorte) */
.menu-hoja-fondo{position:fixed;inset:0;background:rgba(14,12,46,.4);z-index:1000;}
.menu-hoja{position:fixed;left:10px;right:10px;bottom:calc(10px + env(safe-area-inset-bottom,0px));z-index:1001;max-height:72vh;overflow:auto;border-radius:18px;background:var(--surface);box-shadow:0 -10px 40px rgba(14,12,46,.28);padding:8px;}
.menu-hoja::before{content:"";display:block;width:40px;height:4px;border-radius:99px;background:rgba(127,127,160,.4);margin:2px auto 8px;}
.menu-hoja .menu-list{position:static!important;display:flex!important;flex-direction:column;min-width:0!important;width:auto!important;border:0!important;box-shadow:none!important;padding:0!important;background:none!important;transform:none!important;}
.menu-hoja form{display:block;width:100%;margin:0;}
.menu-hoja button,.menu-hoja a{display:block!important;width:100%!important;box-sizing:border-box;text-align:left!important;padding:15px 16px!important;margin:0!important;border:0!important;border-radius:12px!important;background:none!important;font:600 16px var(--body)!important;color:var(--ink)!important;white-space:normal!important;height:auto!important;min-height:0!important;text-decoration:none;}
.menu-hoja button:active,.menu-hoja a:active{background:var(--gold-soft)!important;}
.menu-hoja hr{margin:6px 8px;border:0;border-top:1px solid var(--line);}
.menu-hoja .danger,.menu-hoja [class*=danger]{color:var(--t-red-ink)!important;}

/* Papelera: «Vaciar papelera» y, en el celular, una tarjeta compacta por elemento */
.pl-vaciar{display:flex;justify-content:flex-end;margin:0 0 10px;}.pl-vaciar.pl-en-acc{display:inline-flex;align-items:center;margin:0 6px 0 0;vertical-align:middle;height:auto;}.pl-en-acc .pl-vac{margin:0!important;}.pl-vac{color:var(--t-red-ink)!important;}.pl-vac:hover{border-color:var(--t-red-ink)!important;background:rgba(220,70,50,.08)!important;}
@media (max-width:700px){
  .pl-t thead{display:none!important;}
  .pl-t,.pl-t tbody{display:block!important;width:100%!important;min-width:0!important;}
  .pl-t tr{display:grid!important;grid-template-columns:minmax(0,1fr) auto;column-gap:10px;row-gap:1px;align-items:center;padding:8px 0!important;border:0;border-bottom:1px solid var(--line);border-radius:0;margin:0;background:none;}
  .pl-t tr:last-child{border-bottom:0;}
  .pl-t td{display:block!important;padding:0!important;border:0!important;white-space:normal!important;text-align:left!important;min-width:0;}
  .pl-t td:nth-child(1){grid-column:1;grid-row:1;font-size:10.5px;font-weight:800;letter-spacing:.06em;text-transform:uppercase;color:var(--muted);line-height:1.2;}
  .pl-t td:nth-child(2){grid-column:1;grid-row:2;font-size:14.5px;line-height:1.25;overflow:hidden;text-overflow:ellipsis;white-space:nowrap!important;}
  .pl-t td:nth-child(3){grid-column:1;grid-row:3;font-size:12px;color:var(--muted);}
  .pl-t td:nth-child(4),.pl-t td:nth-child(5){display:none!important;}
  .pl-t td.pl-acc{grid-column:2;grid-row:1/span 3;display:flex!important;flex-direction:column;gap:5px;margin:0;align-self:center;}
  .pl-t td.pl-acc .btn{height:28px!important;min-height:28px!important;line-height:26px!important;padding:0 10px!important;font-size:12px!important;white-space:nowrap;width:100%;border-radius:8px!important;}
  .pl-t td:nth-child(3){white-space:nowrap!important;overflow:hidden;text-overflow:ellipsis;}
  .pl-t td.pl-acc form{margin:0;}
  .pl-t .oc-th-acc{display:none!important;}
}

.pl-mov{display:none;}@media (max-width:700px){.pl-t .pl-mov{display:inline;}}

.oc-th-acc .pl-vac{width:32px!important;height:32px!important;min-height:32px!important;padding:0!important;display:inline-grid!important;place-items:center;}.oc-th-acc .pl-vaciar.pl-en-acc{margin-right:4px;}
/* Ayuda */
.ay-dlg{width:min(520px,94vw);padding:0;}.ay-f{display:grid;gap:12px;padding:18px;}.ay-h{display:flex;justify-content:space-between;align-items:flex-start;gap:12px;}.ay-h h3{margin:0;}.ay-h p{margin:3px 0 0;color:var(--muted);font-size:13.5px;}
.ay-tipos{display:grid;grid-template-columns:1fr 1fr;gap:8px;}.ay-tipos label{position:relative;}.ay-tipos input{position:absolute;opacity:0;}.ay-tipos span{display:block;padding:10px 12px;border:1px solid var(--line);border-radius:12px;font-weight:600;font-size:14px;cursor:pointer;background:var(--surface);}.ay-tipos input:checked+span{border-color:#e9a020;background:rgba(233,160,32,.12);box-shadow:0 0 0 2px rgba(233,160,32,.25);}.ay-tipos input:focus-visible+span{outline:2px solid #e9a020;}
.ay-l{display:grid;gap:6px;font-weight:700;font-size:13.5px;}.ay-l textarea{width:100%;box-sizing:border-box;padding:12px;border:1px solid var(--line);border-radius:12px;background:var(--field);color:var(--ink);font:15px var(--body);resize:vertical;min-height:120px;}
.ay-info{margin:0;font-size:12.5px;color:var(--muted);}.ay-err{margin:0;color:var(--t-red-ink);font-weight:600;font-size:13.5px;}.ay-a{display:flex;gap:8px;justify-content:flex-end;}
.ay-ok{display:grid;gap:8px;justify-items:center;text-align:center;padding:28px 20px;}.ay-ok span{font-size:40px;}.ay-ok h3{margin:0;}.ay-ok p{margin:0 0 6px;color:var(--muted);}
.mod-ay{display:grid;gap:4px;margin:4px 0 10px 52px;font-size:13px;}.mod-ay input{height:38px;padding:0 10px;border:1px solid var(--line);border-radius:8px;width:min(340px,100%);margin-left:6px;background:var(--field);color:var(--ink);}
.ay-ok[hidden],.ay-f[hidden],.ay-err[hidden]{display:none!important;}

.ay-cap{display:grid;gap:8px;}.ay-cap-t{font-weight:700;font-size:13.5px;}.ay-cap-t small{font-weight:400;color:var(--muted);}
.ay-thumbs{display:flex;flex-wrap:wrap;gap:8px;}.ay-thumbs:empty{display:none;}.ay-th{position:relative;width:88px;height:88px;border-radius:10px;overflow:hidden;border:1px solid var(--line);background:var(--bg);}.ay-th img{width:100%;height:100%;object-fit:cover;display:block;}.ay-th button{all:unset;position:absolute;top:4px;right:4px;width:24px;height:24px;display:grid;place-items:center;border-radius:50%;background:rgba(14,12,46,.75);color:#fff;font-size:12px;cursor:pointer;}
.ay-add{justify-self:start;display:inline-flex;align-items:center;gap:6px;cursor:pointer;}.ay-add[hidden]{display:none!important;}.ay-pega{font-size:12px;color:var(--muted);}
@media (hover:none){.ay-pega{display:none;}}
/* Capacitaciones: las dos pestañas del mismo ancho, con el texto centrado (en todos los tamaños) */
html body main .cap-tabs.lh-tabs.lh-tabs:not(:has(> :nth-child(8))){display:grid!important;grid-template-columns:1fr 1fr!important;grid-auto-columns:unset!important;grid-auto-flow:row!important;gap:4px!important;overflow:visible!important;}
html body main .cap-tabs.lh-tabs.lh-tabs > .vt{width:100%!important;min-width:0!important;flex:none!important;justify-content:center!important;text-align:center;white-space:nowrap;}
@media (max-width:380px){html body main .cap-tabs.lh-tabs.lh-tabs > .vt{padding:0 8px!important;font-size:13px!important;gap:6px!important;}}

/* Préstamos con saldo */
.pn-pr-top{display:flex;align-items:center;justify-content:space-between;gap:12px;margin:12px 0;}.pn-pr-top div{display:grid;gap:2px;}.pn-pr-top small{color:var(--muted);}
.pn-pr-t td small{display:block;color:var(--muted);font-size:12px;font-weight:400;}.pn-pr-t tr.pn-pr-fin{opacity:.6;}
.pn-pr-bar{display:inline-block;width:70px;height:6px;border-radius:99px;background:rgba(127,127,160,.25);vertical-align:middle;margin-right:6px;overflow:hidden;}.pn-pr-bar i{display:block;height:100%;background:#1E8E5E;}
.pn-pr-dlg{width:min(480px,94vw);}.pn-pr-g{display:grid;grid-template-columns:1fr 1fr;gap:10px;}.pn-pr-l{display:grid;gap:5px;font-weight:700;font-size:13px;margin:0 0 10px;}.pn-pr-l input{height:42px;padding:0 10px;border:1px solid var(--line);border-radius:10px;background:var(--field);color:var(--ink);font:15px var(--body);width:100%;box-sizing:border-box;}
.pn-pr-err{color:var(--t-red-ink);font-weight:600;margin:0 0 8px;}.pn-pr-a{display:flex;gap:8px;align-items:center;flex-wrap:wrap;}
@media (max-width:700px){.pn-pr-top{flex-wrap:wrap;}.pn-pr-top .btn{width:100%;}.pn-pr-t td:nth-child(3){display:none;}.pn-pr-t th:nth-child(3){display:none;}}

/* Prenómina con 4 vistas (Resumen, Costo, Provisiones, Préstamos) */
@media (min-width:1101px){
  html body .pn-vbar{display:flex!important;flex-wrap:nowrap!important;align-items:center;gap:10px;}
  html body .pn-vbar .lh-tabs{flex:1 1 auto!important;min-width:0;}
  html body .pn-vbar .pn-vbtn{display:flex!important;flex-direction:row!important;flex-wrap:nowrap!important;gap:10px;flex:0 0 auto!important;width:auto!important;}
  html body .pn-vbar .pn-vbtn .btn{white-space:nowrap;}
}
@media (max-width:1100px){
  html body .pn-vbar .lh-tabs{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;overflow:visible!important;}
  html body .pn-vbar .lh-tabs > .vt{min-width:0!important;padding:0 6px!important;justify-content:center!important;}
}
@media (max-width:520px){
  html body .pn-vbar .lh-tabs{grid-template-columns:1fr 1fr!important;height:auto!important;min-height:0!important;row-gap:4px!important;padding:4px!important;}
  html body .pn-vbar .lh-tabs > .vt{height:40px!important;min-height:40px!important;}
}

/* ==================== 4. Cambios de sección y de página sin brincos ==================== */
/* Pendientes: orden y bloques ocultos aplicados por clase desde el primer instante (sin saltos) */
#pendView.pd-ws > .pd-setup{order:var(--o-setup,1);}#pendView.pd-ws > .pd-hoy:not(.pd-rev){order:var(--o-hoy,2);}#pendView.pd-ws > .pd-rev{order:var(--o-rev,3);}
#pendView.pd-ws > .pd-w-alta{order:var(--o-alta,4);}#pendView.pd-ws > .pd-seg:not(.pd-w-alta):not(.pd-w-imss){order:var(--o-seg,5);}
#pendView[data-oc~=setup] > .pd-setup,#pendView[data-oc~=hoy] > .pd-hoy:not(.pd-rev),#pendView[data-oc~=rev] > .pd-rev,#pendView[data-oc~=alta] > .pd-w-alta,#pendView[data-oc~=seg] > .pd-seg:not(.pd-w-alta):not(.pd-w-imss){display:none!important;}
/* Sin brincos al cambiar de sección: el lugar de las pestañas se reserva desde el primer instante y todas miden lo mismo */
html[data-vista=lista] #lhTabs,html[data-vista=clientes] #lhTabs,html[data-vista=asistencia] #lhTabs{min-height:46px;box-sizing:border-box;}
#lhTabs .asis-nav{min-height:46px;box-sizing:border-box;align-items:stretch;}
@media (min-width:701px){
  html[data-vista=lista] #lhTabs,html[data-vista=clientes] #lhTabs,html[data-vista=asistencia] #lhTabs{min-height:54px;}
  #lhTabs .asis-nav{min-height:54px;}
}

#pendView:not(.hidden){display:flex;flex-direction:column;}#pendView > .pd-ia-btn{order:99;}
html:not([data-vista=lista]) #imssAv{display:none!important;}
#tbRow .vistas:not([hidden]):not(.hidden),#lhVistas:not([hidden]){min-height:37px;box-sizing:border-box;}   /* el renglón de vistas guardadas ocupa su lugar desde el inicio (antes llegaba después y empujaba la tabla) */
#listView > #search,#listView > #filters,#listView > #vistasBar{visibility:hidden;}   /* antes de que se acomoden en la fila de búsqueda (evita un cuadro desordenado al cargar) */
html[data-vista=lista] #lhTabs[hidden],html[data-vista=clientes] #lhTabs[hidden],html[data-vista=asistencia] #lhTabs[hidden]{display:block!important;}   /* su lugar se aparta aunque las pestañas lleguen después */

html.oc-espera .tbl-wrap,html.oc-espera .u-scroll,html.oc-espera .bit-tw,html.oc-espera .tbl-scroll{visibility:hidden;}   /* un instante, hasta que la tabla tiene sus herramientas */
html[data-vista=lista] #lhTabs,html[data-vista=clientes] #lhTabs,html[data-vista=asistencia] #lhTabs{display:block!important;}
html[data-vista=asistencia] #lhTabs{margin-bottom:14px;}html body #lhTabs .asis-nav{margin:0!important;}
#pendView > .pd-ph{visibility:hidden;flex:0 0 auto;}
html.oc-espera main table{visibility:hidden;}

/* Cambio entre páginas: se desvanece el contenido (no la barra de arriba ni el menú de abajo) */
html.nav-sale body > :not(script):not(dialog){opacity:0!important;transition:none!important;}   /* al instante: el iPhone recorre la página vieja en cuanto se toca la opción */
@keyframes navEntra{from{opacity:0}to{opacity:1}}
html.nav-entra body > :not(script):not(dialog){animation:navEntra .22s ease-out both;}
/* El pie de página siempre al fondo: mientras carga una sección, el contenido ocupa la pantalla y el pie no aparece a media pantalla para luego bajar */
main,#listView,.admin-page,.alm-page,.pn-main,.cap-main{min-height:calc(100vh - 150px);min-height:calc(100dvh - 150px);}
@media (max-width:700px){main,#listView,.admin-page,.alm-page,.pn-main,.cap-main{min-height:calc(100dvh - 190px);}}
html.nav-espera .site-foot,html.nav-entra .site-foot{visibility:hidden;}
html.nav-sale dialog[open]{opacity:0!important;transition:none!important;}html.nav-sale dialog[open]::backdrop{opacity:0!important;}   /* la hoja «Más» también se oculta al cambiar de página (Safari la subía de golpe) */
#masLocal .mas-it > span svg{width:22px;height:22px;display:block;margin:0 auto;}#masLocal .mas-it.on{border-color:#e9a020;background:rgba(233,160,32,.12);}
@media (hover:none){.mas-it:hover:not(.on),.mas-it:focus:not(:focus-visible):not(.on){border-color:var(--line)!important;background:var(--surface)!important;box-shadow:none!important;}}   /* en el celular no queda marcada la opción que estaba bajo el dedo */

.ay-man{display:flex;align-items:center;gap:12px;padding:12px 14px;border:1px solid rgba(46,125,215,.35);background:rgba(46,125,215,.08);border-radius:12px;}.ay-man > span{font-size:22px;}.ay-man div{flex:1;display:grid;gap:2px;min-width:0;}.ay-man b{font-size:14px;}.ay-man small{font-size:12.5px;color:var(--muted);}.ay-man .btn{white-space:nowrap;}
@media (max-width:520px){.ay-man{flex-wrap:wrap;}.ay-man .btn{width:100%;}}

/* ==================== 5. Operación en sitio: pestañas y Semáforo ==================== */
/* Pestañas iguales a las demás secciones: en un renglón, con el ícono a la izquierda; se deslizan si no caben */
html body .op-tabs.lh-tabs{display:flex!important;flex-wrap:nowrap!important;grid-template-columns:none!important;overflow-x:auto!important;scrollbar-width:none;gap:4px!important;width:100%!important;max-width:100%;box-sizing:border-box;padding:4px!important;border-radius:14px!important;margin:0 0 16px!important;min-height:46px}
html body .op-tabs.lh-tabs::-webkit-scrollbar{display:none}
html body .op-tabs.lh-tabs > .vt{flex:1 0 auto!important;width:auto!important;min-width:0!important;display:inline-flex!important;flex-direction:row!important;align-items:center!important;justify-content:center!important;gap:8px!important;white-space:nowrap!important;padding:0 14px!important;min-height:38px;border-radius:10px!important;text-align:center}
@media (min-width:701px){html body .op-tabs.lh-tabs{min-height:54px}html body .op-tabs.lh-tabs > .vt{flex:1 1 0!important;min-height:46px}}
.sm-main{max-width:1280px;margin:0 auto;padding:28px 24px 60px}
@media (max-width:700px){.sm-main{padding:18px 14px 110px}}
.sm-sub{color:var(--muted);margin:0 0 14px;font-size:14px}
.sm-bar{display:flex;flex-wrap:wrap;gap:10px;align-items:center;justify-content:space-between;margin:0 0 16px}
.sm-res{display:flex;flex-wrap:wrap;gap:8px}.sm-p{display:inline-flex;align-items:center;gap:6px;padding:7px 12px;border-radius:99px;font-size:13px;font-weight:600;border:1px solid var(--line);background:var(--surface)}
.sm-p b{font-size:16px}.sm-p.r b{color:#D64545}.sm-p.a b{color:#C98A0C}.sm-p.v b{color:#1E8E5E}
.sm-per{display:inline-flex;gap:4px;padding:4px;border:1px solid var(--line);border-radius:12px;background:var(--surface)}.sm-per a{padding:7px 14px;border-radius:9px;font-weight:700;font-size:13px;color:var(--muted);text-decoration:none}.sm-per a.on{background:#E9A020;color:#0E0C2E}
.sm-g{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:14px}
@media (max-width:700px){.sm-g{grid-template-columns:1fr}.sm-bar{flex-direction:column;align-items:stretch}.sm-per{justify-content:stretch}.sm-per a{flex:1;text-align:center}}
.sm-c{background:var(--surface);border:1px solid var(--line);border-left:6px solid var(--line);border-radius:16px;padding:14px 16px;display:flex;flex-direction:column}
.sm-c.r{border-left-color:#D64545}.sm-c.a{border-left-color:#E9A020}.sm-c.v{border-left-color:#1E8E5E}
.sm-c header{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;margin:0 0 8px}.sm-c h2{margin:0;font-size:16px;line-height:1.25}
.sm-e{font-size:11.5px;font-weight:800;padding:3px 10px;border-radius:99px;white-space:nowrap;background:rgba(127,127,160,.15);color:var(--muted)}
.sm-c.r .sm-e{background:rgba(214,69,69,.14);color:#C23B3B}.sm-c.a .sm-e{background:rgba(233,160,32,.18);color:#A86F08}.sm-c.v .sm-e{background:rgba(30,142,94,.14);color:#1E8E5E}
.sm-c ul{list-style:none;margin:0;padding:0;display:grid;gap:2px}.sm-c li a{display:flex;gap:10px;align-items:flex-start;padding:8px 6px;border-radius:10px;color:inherit;text-decoration:none}.sm-c li a:hover{background:var(--bg)}
.sm-c li span{display:grid;gap:1px;font-size:13.5px;font-weight:600}.sm-c li small{font-weight:400;font-size:12.5px;color:var(--muted)}
.sm-d{flex:0 0 12px;width:12px;height:12px;border-radius:50%;margin-top:4px;background:rgba(127,127,160,.4)}.sm-d.r{background:#D64545}.sm-d.a{background:#E9A020}.sm-d.v{background:#1E8E5E}
.sm-nota{margin:18px 0 0;font-size:12px;color:var(--muted)}.sm-vacio{padding:30px;text-align:center;color:var(--muted);border:1px dashed var(--line);border-radius:14px}
.sm-per a{display:inline-flex;align-items:center;justify-content:center;height:34px;line-height:1}
.lb-tr{display:inline-block;margin-left:6px;padding:1px 8px;border-radius:99px;background:rgba(30,142,94,.13);color:#1E8E5E;font-size:12px;font-weight:700}
/* Semáforo compacto en el celular */
@media (max-width:700px){
  .sm-sub{font-size:13px;margin:0 0 10px}
  .sm-bar{gap:8px;margin:0 0 12px}
  .sm-res{gap:6px}.sm-p{padding:4px 10px;font-size:12px;gap:4px}.sm-p b{font-size:14px}
  .sm-per{padding:3px}.sm-per a{height:30px;font-size:12.5px;padding:0 10px}
  .sm-g{gap:10px}
  .sm-c{padding:10px 12px;border-left-width:5px;border-radius:14px}
  .sm-c header{margin:0 0 6px}.sm-c h2{font-size:14.5px}.sm-e{font-size:10.5px;padding:2px 8px}
  .sm-c ul{grid-template-columns:1fr 1fr;gap:2px 8px}
  .sm-c li a{gap:7px;padding:5px 4px}
  .sm-c li span{font-size:12px;line-height:1.25}.sm-c li small{font-size:11px;line-height:1.3}
  .sm-d{flex:0 0 9px;width:9px;height:9px;margin-top:3px}
  .sm-nota{font-size:11px}
}
.sm-c li b{font-weight:600}.sm-ts{display:none}@media (max-width:700px){.sm-tl{display:none}.sm-ts{display:inline}.sm-c h2{font-size:14px}.sm-c li small{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}}

.sm-fil{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.sm-sv select{height:40px;border:1px solid var(--line);border-radius:10px;background:var(--surface);color:var(--ink);font:600 14px var(--body);padding:0 34px 0 12px;max-width:280px}
.vh{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}
@media (max-width:700px){.sm-fil{flex-direction:column;align-items:stretch}.sm-sv select{width:100%;max-width:none;height:38px}}
/* Operación en sitio: tarjetas de indicadores del mismo ancho, que llenan el renglón (En vivo, Rondines, Supervisión) */
html body .ev-k{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}
html body .ev-k > div{flex:none!important;width:auto!important;min-width:0!important;max-width:none!important;box-sizing:border-box}
html body .rn-kpi > div,html body .sp-kpi > div{min-width:0}
@media (max-width:700px){
  html body .ev-k{grid-template-columns:1fr 1fr!important;gap:8px}
  html body .sp-kpi{grid-template-columns:1fr 1fr!important}
  html body .rn-kpi{grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:8px}
  html body .rn-kpi > div{padding:10px 12px}html body .rn-kpi b{font-size:24px}
}
/* Opción seleccionada en amarillo en todas las pestañas, filtros y botones de opción (en claro y oscuro) */
html body .in-tabs a.on,html body .rn-tabs a.on,html body .rt-fil a.on,html body .sp-dia a.on,html body .sp-dia input.on,html body .sp-fil a.on,
html body .dtabs button.on,html body .np-tabs button.on,html body .seg button.on,html body .pg-nav .btn.on,html body .chip-a.on,
html body .alm-tabs a.vt.on,html body .op-tabs a.on{background:#E9A020!important;border-color:#E9A020!important;color:#0E0C2E!important;font-weight:700}
html body .in-tabs a.on:hover,html body .rn-tabs a.on:hover,html body .sp-fil a.on:hover,html body .chip-a.on:hover,html body .seg button.on:hover{background:#D4910F!important;border-color:#D4910F!important}
html body .vchip.on{background:#E9A020!important;border-color:#E9A020!important}html body .vchip.on button{color:#0E0C2E!important;font-weight:700}html body .vchip.on .vchip-m{color:#3a2a05!important}

/* Supervisión: pestañas y «+ Nueva» en un renglón; filtros alineados (servicio arriba, fechas lado a lado, vistas abajo) */
@media (max-width:700px){
  .in-top{flex-wrap:nowrap!important;gap:8px!important;margin:6px 0 12px!important}
  .in-tabs{flex-wrap:nowrap!important;gap:6px!important;min-width:0}
  .in-tabs a{padding:0 12px!important;height:36px;display:inline-flex!important;align-items:center;font-size:13px!important;white-space:nowrap}
  .in-nueva{flex:0 0 auto;height:36px!important;min-height:36px!important;padding:0 12px!important;font-size:13px!important;white-space:nowrap;display:inline-flex!important;align-items:center}
  .in-lg{display:none}
  html body form.in-fil{display:grid!important;grid-template-columns:1fr 1fr!important;gap:8px 10px!important;align-items:end}
  html body form.in-fil .filters{display:contents!important}
  html body form.in-fil .filters > label{min-width:0!important;width:auto!important}
  html body form.in-fil .filters > label:first-child,html body form.in-fil > .vistas,html body form.in-fil > .fcount{grid-column:1/-1}
  html body form.in-fil input,html body form.in-fil select{width:100%!important;box-sizing:border-box}
}
@media (max-width:700px){.in-nueva{width:40px;height:36px!important;padding:0!important;justify-content:center;font-size:22px!important;font-weight:700;border-radius:12px!important;margin-left:auto}.in-tabs{flex:1 1 auto}.in-tabs a{flex:1 1 auto;justify-content:center}}
/* ==================== 6. Operación en sitio con el mismo diseño que Candidatos ==================== */
/* Texto que explica cada vista: gris, del mismo tamaño en todas */
html body .op-tabs ~ p.sub,html body .sm-sub{color:var(--muted)!important;font-size:14px!important;line-height:1.45;margin:0 0 14px!important}
@media (max-width:700px){html body .op-tabs ~ p.sub,html body .sm-sub{font-size:13.5px!important}}
/* Etiquetas de los filtros como en Candidatos (sin mayúsculas, 13 px) */
html body .lb-fil label,html body .pt-fil label,html body .rn-fil label,html body .ev-vf label,html body .sp-fil label{font:600 13px var(--body)!important;text-transform:none!important;letter-spacing:0!important;color:var(--muted)}
/* Controles de los filtros: misma altura, fondo y esquinas */
html body .pt-fil select,html body .pt-fil input,html body .rn-fil select,html body .rn-fil input,html body .sm-sv select,html body .ev-vf select,html body .ev-vf input{height:42px!important;border-radius:10px!important;background:var(--field)!important;color:var(--ink)!important;font-size:16px!important;box-sizing:border-box}
/* Filtros en el celular: en dos columnas parejas, como en Candidatos */
@media (max-width:700px){
  html body .pt-fil,html body .rn-fil{display:grid!important;grid-template-columns:1fr 1fr!important;gap:8px 10px!important;align-items:end}
  html body .pt-fil label,html body .rn-fil label{min-width:0!important;width:auto!important}
  html body .pt-fil select,html body .pt-fil input,html body .rn-fil select,html body .rn-fil input{width:100%!important}
}
/* Tarjetas de indicadores como las de Candidatos: número grande a la izquierda y franja dorada arriba */
html body .sp-kpi > div{text-align:left!important;border-top:3px solid #E9A020!important;padding:12px 14px!important}
html body .sp-kpi b,html body .rn-kpi b{font-size:30px!important}
html body .sp-kpi small,html body .rn-kpi small{color:var(--muted)}
@media (max-width:700px){html body .sp-kpi b,html body .rn-kpi b{font-size:26px!important}}
/* Rondines en el celular: pestañas a todo el ancho, Servicio | Día, y el reporte mensual en un renglón */
@media (max-width:700px){
  html body form.rn-fil{display:grid!important;grid-template-columns:1fr 1fr!important;gap:8px 10px!important;align-items:end;margin:6px 0 14px!important}
  html body form.rn-fil > .rn-tabs{grid-column:1/-1;display:flex!important;width:100%;box-sizing:border-box}
  html body form.rn-fil > .rn-tabs a{flex:1 1 0;display:flex;align-items:center;justify-content:center;height:38px;padding:0 8px!important;white-space:nowrap;text-align:center}
  html body form.rn-fil > .filters{display:contents!important}
  html body form.rn-fil > .filters > label{min-width:0!important;width:auto!important}
  html body form.rn-fil > .filters > label:only-of-type{grid-column:1/-1}
  html body form.rn-fil > .rn-mes{grid-column:1/-1;display:grid!important;grid-template-columns:minmax(0,1fr) auto;gap:4px 8px;align-items:center;margin:2px 0 0!important;width:auto!important}
  html body form.rn-fil > .rn-mes > span:first-child{grid-column:1/-1;font:600 13px var(--body);color:var(--muted)}
  html body form.rn-fil > .rn-mes select{width:100%!important;height:42px!important;margin:0!important}
  html body form.rn-fil > .rn-mes .btn{height:42px;min-height:42px;white-space:nowrap;margin:0!important}
  html body .rn-kpi small{font-size:12px;line-height:1.3;display:block;margin-top:4px}
}
@media (max-width:700px){
  html body .rn-kpi b{font-size:22px!important;white-space:nowrap}
  html body form.pt-fil > :not(label),html body .pt-fil > :not(label){grid-column:1/-1}
}
/* Asistencia: selector «Todos / Con alertas» junto a descargar y compactar */
html body .asis-top.con-seg{display:flex!important;align-items:center;gap:10px;flex-wrap:wrap}
html body .asis-top.con-seg > .seg-alert{margin:0!important}
html body .asis-top.con-seg > .note{flex:0 1 auto}
html body .asis-top.con-seg > .seg-alert + *{margin-left:auto}
@media (max-width:700px){html body .asis-top.con-seg > .note{flex-basis:100%}}
html body .oc-acc.con-seg{display:flex!important;align-items:center!important;justify-content:flex-end;gap:8px;width:100%;box-sizing:border-box;position:static!important}html body .oc-acc.con-seg > .seg-alert{margin:0 auto 0 0!important}
/* Ventanas emergentes: marco y sombra para que no se pierdan con el fondo; fondo de atrás más oscuro */
html body dialog:not(.pv)[open]{border:1px solid rgba(14,12,46,.14)!important;box-shadow:0 0 0 1px rgba(255,255,255,.04),0 24px 70px rgba(4,3,20,.45)!important}
html body dialog:not(.pv)::backdrop{background:rgba(6,5,22,.62);-webkit-backdrop-filter:blur(3px);backdrop-filter:blur(3px)}
html[data-theme="dark"] body dialog:not(.pv)[open]{border-color:rgba(233,160,32,.55)!important;box-shadow:0 0 0 4px rgba(233,160,32,.10),0 28px 80px rgba(0,0,0,.65)!important}
@media (prefers-color-scheme:dark){html:not([data-theme="light"]) body dialog:not(.pv)[open]{border-color:rgba(233,160,32,.55)!important;box-shadow:0 0 0 4px rgba(233,160,32,.10),0 28px 80px rgba(0,0,0,.65)!important}}
html body dialog:not(.pv)::backdrop{background:rgba(4,3,18,.70)}

/* Respaldos › Google Drive */
.gd-card{margin-bottom:14px}.gd-card h3{display:flex;align-items:center;gap:8px}
.gd-pasos{margin:10px 0;padding:10px 14px;border:1px solid var(--line);border-radius:12px;background:var(--bg)}.gd-pasos summary{cursor:pointer;font-weight:700}
.gd-pasos ol{margin:10px 0 4px 18px;padding:0;display:grid;gap:8px;font-size:14px;line-height:1.45}
.gd-uri{display:inline-block;margin:4px 6px 0 0;padding:4px 8px;border-radius:8px;background:var(--surface);border:1px solid var(--line);font-size:12.5px;word-break:break-all}

/* Campos de la solicitud: subir y bajar secciones */
.cf-ord{display:inline-flex;gap:4px;margin-left:10px}.cf-mv{width:30px;height:28px;border:1px solid var(--line);border-radius:8px;background:var(--surface);color:var(--ink);font-size:11px;cursor:pointer;line-height:1}
.cf-mv:hover{border-color:#E9A020;color:#B97A0A}.cf-sec.cf-movida{outline:2px solid #E9A020;outline-offset:2px;transition:outline-color .6s}
.cf-pend{box-shadow:0 0 0 3px rgba(233,160,32,.35)}
/* Expediente: la tarjeta del formulario mide lo que su contenido (sin hueco abajo); el pie sigue al fondo */
html body #capView > main.main{min-height:0!important;align-self:start!important}
html body #capView{min-height:calc(100vh - 150px);min-height:calc(100dvh - 150px)}
@media (max-width:700px){html body #capView{min-height:calc(100dvh - 190px)}}
/* Todas las páginas se adaptan al ancho de la pantalla: ocupan todo el espacio junto al menú, con el mismo margen a cada lado */
@media (min-width:701px){
  html body #listView,html body main.cap-main,html body main.admin-page:not(.cuenta-page),html body main.ev-main,html body main.in-main,html body main.lb-main,
  html body main.pt-main,html body main.rn-main,html body main.rt-main,html body main.sm-main,html body main.sp-main,html body main.pg-main,html body main.cf-main,html body main.pn-main{max-width:none!important;width:auto!important;margin-left:20px!important;margin-right:20px!important}
}
/* Tope para monitores muy anchos: el contenido llega hasta 2200 px y se centra junto al menú */
@media (min-width:2400px){
  html body #listView,html body main.cap-main,html body main.admin-page:not(.cuenta-page),html body main.ev-main,html body main.in-main,html body main.lb-main,
  html body main.pt-main,html body main.rn-main,html body main.rt-main,html body main.sm-main,html body main.sp-main,html body main.pg-main,html body main.cf-main,html body main.pn-main{max-width:2200px!important;margin-left:auto!important;margin-right:auto!important}
}

/* Administración › App Guardia360 */
.g3-grid{display:grid;grid-template-columns:240px 1fr;gap:22px;align-items:start;margin:14px 0}
@media (max-width:700px){.g3-grid{grid-template-columns:1fr}}
.g3-qr{display:grid;justify-items:center;gap:8px;padding:16px;border:1px solid var(--line);border-radius:16px;background:#fff}.g3-qr small{color:#555;font-size:12px}
.g3-qr #g3qr{width:200px;height:200px;display:grid;place-items:center}.g3-qr #g3qr svg,.g3-qr #g3qr canvas,.g3-qr #g3qr img{width:200px!important;height:200px!important}
.g3-dl{margin:0;display:grid;gap:4px}.g3-dl dt{font-weight:700;margin-top:8px}.g3-dl dd{margin:0;color:var(--muted)}
.g3-cod{font-size:18px;font-weight:800;padding:4px 12px;border-radius:10px;background:rgba(233,160,32,.15);color:#B97A0A;letter-spacing:.5px}
.g3-f{display:flex;flex-wrap:wrap;gap:10px;align-items:flex-end;margin:6px 0 10px}.g3-f label{display:grid;gap:4px;font:600 13px var(--body);color:var(--muted);flex:1 1 220px}
.g3-f input{height:42px;border:1px solid var(--line);border-radius:10px;padding:0 12px;background:var(--field);color:var(--ink);font-size:15px}
.g3-o{color:var(--muted);font-size:13px;margin:0 6px}.g3-cod2{font-size:14px;padding:2px 8px}

/* Administración › Actualizar el sistema › Actualizaciones anteriores.
   En celular (navegador o app) cada actualización es un renglón ordenado:
   paquete en negritas y «Regresar» a la derecha; abajo la fecha, quién y cuántos archivos. */
.up-hist td[data-l=Paquete]{font-weight:600;overflow-wrap:anywhere;}
.up-hist .cf-si{white-space:nowrap;margin-left:4px;}
.up-lista li{overflow-wrap:anywhere;padding:2px 0;}
@media (max-width:760px){
  /* Prefijo largo a propósito: gana a «html.densa .utable tbody tr» (vista compacta) y a «html body .utable tr». */
  html body .u-scroll:has(> table.up-hist){overflow:visible!important;margin:0!important;padding:0!important;}
  html body table.utable.up-hist,html body table.utable.up-hist tbody{display:block!important;width:100%!important;border:0!important;}
  html body table.utable.up-hist thead{display:none!important;}
  html body table.utable.up-hist tbody tr{display:grid!important;grid-template-columns:auto minmax(0,1fr) auto!important;
    grid-template-areas:"paq paq btn" "fec fec btn" "por arc arc"!important;gap:4px 10px!important;align-items:center!important;
    padding:14px 2px!important;margin:0!important;min-height:0!important;border:0!important;border-bottom:1px solid var(--line)!important;
    border-radius:0!important;background:none!important;box-shadow:none!important;}
  html body table.utable.up-hist tbody tr:last-child{border-bottom:0!important;}
  html body table.utable.up-hist tbody td{display:block!important;padding:0!important;border:0!important;text-align:left!important;
    width:auto!important;min-width:0!important;background:none!important;white-space:normal!important;}
  html body table.utable.up-hist tbody td::before{content:none!important;display:none!important;}
  html body table.utable.up-hist tbody td[data-l=Paquete]{grid-area:paq!important;font-size:15px!important;line-height:1.3;}
  html body table.utable.up-hist tbody td[data-l=Fecha]{grid-area:fec!important;font-size:13px!important;color:var(--muted);}
  html body table.utable.up-hist tbody td[data-l=Por]{grid-area:por!important;font-size:13px!important;color:var(--muted);white-space:nowrap!important;}
  html body table.utable.up-hist tbody td[data-l=Por]::after{content:"·";margin-left:8px;}
  html body table.utable.up-hist tbody td[data-l=Archivos]{grid-area:arc!important;font-size:13px!important;color:var(--muted);}
  html body table.utable.up-hist tbody td.r{grid-area:btn!important;align-self:center;text-align:right!important;}
  html body table.utable.up-hist tbody td:not([data-l]):not(.r){display:none!important;}
  html body table.utable.up-hist td.r form{margin:0;}
  html body table.utable.up-hist td.r .btn{min-height:40px;padding:0 14px;border-radius:10px;font-size:14px;white-space:nowrap;}
  /* Vista compacta: dos líneas por actualización (paquete + Regresar; fecha · quién · archivos) */
  html.densa body table.utable.up-hist tbody tr{grid-template-columns:auto auto minmax(0,1fr) auto!important;
    grid-template-areas:"paq paq paq btn" "fec por arc btn"!important;gap:2px 8px!important;padding:8px 2px!important;}
  html.densa body table.utable.up-hist tbody td[data-l=Paquete]{font-size:14px!important;line-height:1.25;}
  html.densa body table.utable.up-hist tbody td[data-l=Fecha],html.densa body table.utable.up-hist tbody td[data-l=Por],html.densa body table.utable.up-hist tbody td[data-l=Archivos]{font-size:12px!important;white-space:nowrap!important;
    overflow:hidden;text-overflow:ellipsis;}
  html.densa body table.utable.up-hist tbody td[data-l=Fecha]::after{content:"·";margin-left:8px;}
  html.densa body table.utable.up-hist tbody td[data-l=Fecha] .cf-si{display:none;}
  html.densa body table.utable.up-hist td.r .btn{min-height:32px;padding:0 10px;font-size:13px;}
  .up-f{flex-direction:column;align-items:stretch;}
  .up-f input[type=file]{min-width:0;width:100%;}
  .up-f .btn{width:100%;min-height:46px;}
  .up-rev .acard-foot form,.up-rev .acard-foot .btn{width:100%;}
  .up-rev .acard-foot .btn{min-height:46px;}
}

/* Almacén en tablet: las pestañas en una fila deslizable, ícono y texto juntos (ya no se enciman) */
@media (max-width:1100px){
  html body main .alm-tabs.lh-tabs.lh-tabs{display:flex!important;flex-wrap:nowrap!important;grid-template-columns:none!important;
    overflow-x:auto!important;scrollbar-width:none;gap:4px!important;padding:4px!important;border-radius:14px!important;height:auto!important}
  html body main .alm-tabs.lh-tabs.lh-tabs::-webkit-scrollbar{display:none}
  html body main .alm-tabs.lh-tabs.lh-tabs > .vt{flex:0 0 auto!important;width:auto!important;min-width:0!important;height:auto!important;
    display:inline-flex!important;flex-direction:row!important;align-items:center!important;justify-content:center!important;gap:8px!important;
    white-space:nowrap!important;padding:0 14px!important;min-height:44px!important;border-radius:10px!important;text-align:left!important}
  html body main .alm-tabs.lh-tabs.lh-tabs .tab-n{position:static!important;margin-left:2px}
}

/* Estado del sistema › secciones plegables (Actualizar el sistema, Respaldos y copias): una sola tarjeta
   que se abre hacia abajo; adentro, los bloques van separados por una línea, sin tarjetas dentro de tarjetas. */
.est-respaldos{display:block;margin-top:20px;scroll-margin-top:90px;border:1px solid var(--line);border-radius:16px;
  background:var(--surface,#fff);overflow:hidden}
.est-respaldos .est-sec{display:flex;align-items:center;justify-content:space-between;gap:16px;list-style:none;cursor:pointer;
  padding:20px 24px;margin:0;border:0;background:none}
.est-respaldos .est-sec::-webkit-details-marker{display:none}
.est-respaldos .est-sec h2{margin:0 0 4px;font-size:20px}
.est-respaldos .est-sec p{margin:0;color:var(--muted);font-size:14px;line-height:1.5;overflow-wrap:anywhere}
.est-respaldos .est-sec p b{color:var(--ink);font-weight:600}
.est-sec-abrir{flex:none;display:inline-flex;align-items:center;gap:8px;min-height:40px;padding:0 16px;border:1px solid var(--line);
  border-radius:10px;font-weight:600;font-size:14px;white-space:nowrap}
.est-sec-abrir i{font-style:normal}
.est-sec-abrir .ce,.est-respaldos[open] .est-sec-abrir .ab{display:none}
.est-respaldos[open] .est-sec-abrir .ce{display:inline}
.est-sec-abrir::after{content:"";width:8px;height:8px;border-right:2px solid currentColor;border-bottom:2px solid currentColor;
  transform:rotate(45deg) translateY(-2px);transition:transform .15s}
.est-respaldos[open] .est-sec-abrir::after{transform:rotate(-135deg) translateY(-2px)}
.est-respaldos[open] .est-sec{border-bottom:1px solid var(--line)}
/* Bloques de adentro: sin marco propio */
.est-respaldos > .acard,.est-respaldos > section{margin:0!important;border:0!important;border-radius:0!important;box-shadow:none!important;
  background:none!important;padding:22px 24px!important}
.est-respaldos > .acard + .acard,.est-respaldos > section + section{border-top:1px solid var(--line)!important}
.est-respaldos .acard-title{display:flex;flex-wrap:wrap;align-items:baseline;justify-content:space-between;gap:6px 20px;margin-bottom:6px}
.est-respaldos .acard-title .sub{max-width:520px;font-size:13px;color:var(--muted)}
.est-respaldos .mail-cfg{grid-template-columns:130px 1fr;gap:10px 18px;margin:16px 0 18px}
.est-respaldos .liga-row{display:flex;gap:12px;align-items:center;margin:0 0 6px}
.est-respaldos .liga-row input{flex:1;min-width:0}
.est-respaldos input:not([type=checkbox]):not([type=radio]):not([type=hidden]),.est-respaldos select{height:46px;font-size:15px;max-width:100%;box-sizing:border-box}
.est-respaldos .btn{min-height:44px;padding-left:18px;padding-right:18px;box-sizing:border-box;max-width:100%}
.est-respaldos .nube-card{padding:20px 22px;margin:22px 0;border-radius:14px}
.est-respaldos .nube-card h3{margin:0 0 8px}
.est-respaldos .nube-card .note{line-height:1.55;margin:0 0 12px}
.est-respaldos .nube-f{gap:16px 18px;margin-top:14px}
@media (min-width:900px){.est-respaldos .nube-f{grid-template-columns:repeat(3,minmax(0,1fr))}}
.est-respaldos .nube-f label{display:grid;gap:6px;min-width:0}
.est-respaldos .bak-acts{display:flex;flex-wrap:wrap;gap:12px;margin:22px 0 12px}
.est-respaldos .note{line-height:1.55}
.est-respaldos .up-f{box-sizing:border-box;max-width:100%}
.est-respaldos .up-f > *{min-width:0;max-width:100%;box-sizing:border-box}
@media (max-width:700px){
  .est-respaldos .est-sec{padding:16px 16px 16px 18px;gap:12px}
  .est-respaldos .est-sec h2{font-size:18px}
  .est-respaldos .est-sec p{font-size:13px}
  .est-sec-abrir{width:40px;height:40px;min-height:40px;padding:0;justify-content:center;border-radius:50%}
  .est-sec-abrir i{display:none!important}
  .est-respaldos > .acard,.est-respaldos > section{padding:18px 16px!important}
  .est-respaldos .mail-cfg{grid-template-columns:1fr;gap:2px 0}
  .est-respaldos .mail-cfg dd{margin:0 0 8px}
  .est-respaldos .liga-row{flex-direction:column;align-items:stretch}
  .est-respaldos .bak-acts .btn,.est-respaldos .bak-acts form{width:100%}
}

/* Estado del sistema: Versión y Errores a la izquierda, Espacio usado a la derecha (Correo y Accesos ya están en
   «Correo y reportes» y «Sesiones activas»). Debajo, Actualizar y Respaldos lado a lado; la que se abre toma todo el ancho. */
.est-grid{grid-template-areas:"ver esp" "res esp" "err esp"!important}
.est-grid .est-err{grid-area:err}
.est-grid.sin-res{grid-template-areas:"ver esp" "err esp"!important}
.est-plegables{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;align-items:start;margin-top:16px}
.est-plegables > .est-respaldos{margin-top:0}
.est-plegables .est-sec > span{min-width:0}
/* Cerradas: una sola línea de resumen para que las dos queden al mismo nivel; al abrirse se ve completa */
.est-plegables > details:not([open]) .est-sec p{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
/* Abiertas: se despliegan en su misma columna; los formularios se acomodan al ancho de la tarjeta */
.est-plegables .nube-f{grid-template-columns:repeat(auto-fit,minmax(190px,1fr))!important}
.est-plegables .up-hist td[data-l=Paquete]{word-break:break-word}
@media (max-width:900px){
  .est-grid{grid-template-areas:"ver" "esp" "res" "err"!important}
  .est-grid.sin-res{grid-template-areas:"ver" "esp" "err"!important}
  .est-plegables{grid-template-columns:1fr}
}

/* Estado del sistema › Versión: novedades del paquete instalado */
.ver-notas{margin-top:12px;border-top:1px solid var(--line);padding-top:10px}
.ver-notas summary{cursor:pointer;font-weight:600;font-size:14px}
.ver-notas ul{margin:8px 0 0;padding-left:20px;display:grid;gap:4px;font-size:13.5px;color:var(--muted);line-height:1.45}

/* Estado del sistema › Instalación de demostración */
.demo-card{margin-top:16px;border-left:4px solid var(--gold,#E9A020)}
.demo-card code{background:var(--bg);padding:1px 6px;border-radius:6px}

/* Usuarios › cliente: secciones del portal que puede ver */
.u-psec{margin-top:6px;font-size:12.5px}.u-psec summary{cursor:pointer;color:var(--muted);text-decoration:underline;text-underline-offset:2px}
.u-psec form{display:grid;gap:6px;margin-top:8px;padding:10px 12px;border:1px solid var(--line);border-radius:10px;background:var(--bg)}
.u-psec label{display:flex;align-items:center;gap:8px;font-size:13px;font-weight:500}.u-psec input[type=checkbox]{width:16px;height:16px;min-height:0}.u-psec .btn{justify-self:start}
/* Agregar usuario › Cliente: selector a lo ancho y secciones del portal */
.cli-pick{display:grid;gap:6px;margin:10px 0 4px}.cli-pick[hidden]{display:none!important}   /* solo con el rol Cliente (portal) */.cli-pick>label{font-weight:700;font-size:13px}
.cli-pick select{width:100%;height:46px;border:1px solid var(--line);border-radius:10px;background:var(--field,var(--bg));color:var(--ink);padding:0 12px;font:15px var(--body,system-ui)}
.cli-sec{margin:8px 0 0;padding:12px 14px;border:1px solid var(--line);border-radius:12px}.cli-sec legend{padding:0 6px;font-weight:700;font-size:13px}
.cli-sec>div{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 14px}.cli-sec label{display:flex;align-items:center;gap:8px;font-size:14px;font-weight:500}
.cli-sec input[type=checkbox]{width:18px;height:18px;min-height:0;flex:none}.cli-sec small{display:block;margin-top:8px;color:var(--muted);font-size:12px}
@media (max-width:520px){.cli-sec>div{grid-template-columns:1fr}}
.u-suprnd{margin-top:6px;font-size:12.5px}.u-suprnd label{display:inline-flex;align-items:center;gap:6px;color:var(--muted);cursor:pointer}.u-suprnd input{width:15px;height:15px;min-height:0}

/* Menú lateral agrupado: Personal · Operación · Nómina y números · Sistema */
.topnav .vt-g{display:none}
@media (min-width:1101px){
  .top .topnav{overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin}
  .top .topnav .vt-g{display:block;flex:none;padding:9px 14px 2px;font-size:10px;line-height:1.2;font-weight:800;letter-spacing:.08em;text-transform:uppercase;color:rgba(255,255,255,.42);pointer-events:none}
  .top .topnav .vt-g.vt-g1{padding-top:0}
  html.sb-mini .top .topnav .vt-g{padding:0;margin:6px 16px;height:1px;background:rgba(255,255,255,.16)}
  html.sb-mini .top .topnav .vt-g span{display:none}
  html.sb-mini .top .topnav .vt-g.vt-g1{display:none}
}

/* Computadora: barra superior con Buscar, Notificaciones y Ayuda (fuera del menú lateral) */
.top-tools{display:contents}
.gs-inline{display:none}   /* el campo que se abre con la lupa solo existe en computadora */
@media (min-width:1101px){
  .top:has(.topnav) .top-tools .gs-inline{display:block}
  body:has(.top .topnav){padding-top:52px}
  .top:has(.topnav) .top-tools{position:fixed;top:0;left:var(--sbw,260px);right:0;height:52px;z-index:55;display:flex;align-items:center;justify-content:flex-end;gap:8px;padding:0 28px;margin:0;
    background:color-mix(in srgb,var(--bg) 88%,transparent);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);border-bottom:1px solid var(--line);color:var(--ink)}
  .top:has(.topnav) .top-tools .notif-btn{position:relative;flex:none;width:42px!important;height:42px!important;padding:0!important;gap:0!important;justify-content:center!important;border-radius:12px!important;
    background:var(--surface)!important;border:1px solid var(--line)!important;color:var(--ink)!important;grid-column:auto}
  .top:has(.topnav) .top-tools .notif-btn::after{content:none!important}
  .top:has(.topnav) .top-tools .notif-btn .gs-txt{display:none!important}
  .top:has(.topnav) .top-tools .notif-btn:hover{border-color:#E9A020!important}
  html body .top:has(.topnav) .top-tools .notif-btn,html body .top:has(.topnav) .top-tools .notif-btn:not(.gs-btn){margin:0!important;top:0!important}
  .top:has(.topnav) .top-tools>*{align-self:center;margin:0!important;top:auto!important;vertical-align:middle;transform:none!important;box-sizing:border-box}
  .top:has(.topnav) .top-tools .gs-kbd{display:none!important}
  /* buscador: solo la lupa; al tocarla se abre un campo para escribir */
  .top:has(.topnav) .top-tools .gs-inline{width:0;opacity:0;height:42px;padding:0;border:1px solid transparent;border-radius:12px;background:var(--surface);color:var(--ink);font:500 14.5px var(--body,system-ui);transition:width .22s ease,opacity .18s ease,padding .22s ease;outline:none}
  .top:has(.topnav) .top-tools.gs-open .gs-inline{width:min(340px,34vw);opacity:1;padding:0 14px;border-color:#E9A020;box-shadow:0 0 0 3px rgba(233,160,32,.18)}
  .top:has(.topnav) .top-tools.gs-open .gs-btn:not(.ay-btn){border-color:#E9A020!important;color:#B07A0E!important}
  .top:has(.topnav) .top-tools .notif-n{position:absolute;top:-5px;right:-5px;margin:0}
  /* la flecha para cerrar/abrir el menú queda por encima de la barra superior */
  .top:has(.topnav) .sb-tog{z-index:70}
  /* menú de la cuenta, a la derecha de la barra superior: solo la inicial; la lista se abre hacia abajo */
  .top:has(.topnav) .top-tools .umenu{margin:0!important;padding:0!important;grid-column:auto;border:0!important;background:none!important}
  .top:has(.topnav) .top-tools .umenu-btn::before,.top:has(.topnav) .top-tools .umenu-btn::after{content:none!important}
  .top:has(.topnav) .top-tools .umenu-btn{width:42px!important;min-width:0!important;min-height:0!important;height:42px!important;padding:0!important;border-radius:12px!important;border:1px solid var(--line)!important;background:var(--surface)!important;color:var(--ink)!important;gap:0!important;display:flex!important;align-items:center!important;justify-content:center!important;box-shadow:none!important}
  .top:has(.topnav) .top-tools .umenu-btn:hover,.top:has(.topnav) .top-tools .umenu[open] .umenu-btn{border-color:#E9A020!important}
  .top:has(.topnav) .top-tools .umenu-btn .uinfo,.top:has(.topnav) .top-tools .umenu-btn>svg{display:none!important}
  .top:has(.topnav) .top-tools .uav{width:28px!important;height:28px!important;flex:0 0 28px!important;min-width:0!important;font:800 11.5px var(--body,system-ui)!important;letter-spacing:.02em;border:0!important;box-shadow:none!important;outline:0!important;margin:0!important}
  .top:has(.topnav) .top-tools .umenu-list,html.sb-mini .top:has(.topnav) .top-tools .umenu-list{top:calc(100% + 8px)!important;bottom:auto!important;right:0!important;left:auto!important;min-width:240px}
}

/* Candidatos (computadora): lista con su propio desplazamiento y títulos de columnas fijos (la altura la calcula app.js) */
@media (min-width:1101px){
  #listWrap.lw-scroll{overflow:auto!important;border:1px solid var(--line)!important;border-radius:16px;background:var(--surface)!important;overscroll-behavior:contain}
  #listWrap.lw-scroll thead th{position:sticky;top:0;z-index:3;background:var(--surface);box-shadow:0 1px 0 var(--line)}
  #listWrap.lw-scroll thead th.cols-th{z-index:4;right:0}
  /* más espacio para la lista: sin relleno ni pie de página debajo mientras se ve la lista */
  #listView:has(#listWrap.lw-scroll){min-height:0!important;padding-bottom:8px!important}
  body:has(#listWrap.lw-scroll) .app-foot{display:none!important}
  #listView:has(#listWrap.lw-scroll){padding-top:14px!important}
  #listView:has(#listWrap.lw-scroll) #imssAv{padding:6px 12px!important;margin-bottom:10px!important;min-height:0!important}
  #listView:has(#listWrap.lw-scroll) #imssAv small,#listView:has(#listWrap.lw-scroll) #imssAv p,#listView:has(#listWrap.lw-scroll) #imssAv .imss-sub{display:none!important}
  #listView:has(#listWrap.lw-scroll) #imssAv .btn{min-height:0!important;height:32px!important;padding:0 12px!important}
}

/* Computadora: tabla principal de cada módulo con su propio desplazamiento y títulos fijos (ver tema.js) */
@media (min-width:1101px){
  .lw-auto.lw-scroll{overflow:auto!important;overscroll-behavior:contain}
  .lw-auto.lw-scroll thead th{position:sticky;top:var(--lw-pre,0px);z-index:3;background:var(--surface);box-shadow:0 1px 0 var(--line)}
  .lw-auto.lw-scroll>.lw-pre{position:sticky;z-index:4;background:var(--surface)}
  .lw-auto.lw-scroll>.sm2-h{position:sticky;top:0;z-index:3;background:var(--surface)}   /* títulos del Semáforo */
  body.lw-pagina .app-foot,body.lw-pagina .site-foot{display:none!important}
  #listView:has(.lw-auto.lw-scroll){min-height:0!important;padding-bottom:8px!important}
  main:has(.lw-auto.lw-scroll),.adm-main:has(.lw-auto.lw-scroll){padding-bottom:8px!important;min-height:0!important}
}

.lw-float{position:fixed;z-index:52;overflow:hidden;pointer-events:none;background:var(--surface);box-shadow:0 6px 14px -8px rgba(14,12,46,.25);border-bottom:1px solid var(--line)}
.lw-float table{margin:0;border-collapse:separate;border-spacing:0}.lw-float th{background:var(--surface)}
@media (max-width:1100px){.lw-float{display:none!important}}

/* Computadora: encabezado de cada pantalla más compacto (barra, título, pestañas, filtros y tarjetas de totales) */
@media (min-width:1101px){
  body:has(.top .topnav){padding-top:52px}
  .top:has(.topnav) .top-tools{height:52px}
  html body .top:has(.topnav) .top-tools .notif-btn,html body .top:has(.topnav) .top-tools .umenu-btn{width:38px!important;height:38px!important}
  .top:has(.topnav) .top-tools .gs-inline{height:38px}
  /* espacio arriba del contenido */
  body:has(.top .topnav) main,body:has(.top .topnav) #listView{padding-top:14px!important}
  /* título y subtítulo */
  body:has(.top .topnav) main h1,body:has(.top .topnav) #listView .list-head h1{font-size:24px!important;line-height:1.15!important;margin:0!important}
  body:has(.top .topnav) .list-head,body:has(.top .topnav) .alm-top,body:has(.top .topnav) .op-head,body:has(.top .topnav) .pn-head,body:has(.top .topnav) main>header{margin-bottom:8px!important;min-height:0!important}
  body:has(.top .topnav) .list-head p,body:has(.top .topnav) .alm-top p,body:has(.top .topnav) .op-head p,body:has(.top .topnav) .pn-head small,body:has(.top .topnav) main>header p,body:has(.top .topnav) .list-head .sub{font-size:13px!important;margin:2px 0 0!important;line-height:1.35!important}
  /* pestañas */
  body:has(.top .topnav) .lh-tabs-slot,body:has(.top .topnav) .viewtabs,body:has(.top .topnav) .op-tabs{margin-bottom:8px!important}
  body:has(.top .topnav) .lh-tabs,body:has(.top .topnav) .viewtabs,body:has(.top .topnav) .op-tabs{padding:3px!important;min-height:0!important}
  body:has(.top .topnav) .lh-tabs .vt,body:has(.top .topnav) .viewtabs>a,body:has(.top .topnav) .viewtabs>button,body:has(.top .topnav) .op-tabs .vt,body:has(.top .topnav) .op-tabs>a{min-height:0!important;height:34px!important;padding-top:0!important;padding-bottom:0!important;font-size:13.5px!important}
  /* filtros: campos más bajos y etiquetas pequeñas */
  body:has(.top .topnav) .tb-row,body:has(.top .topnav) .filters,body:has(.top .topnav) .lb-fil,body:has(.top .topnav) .pn-bar,body:has(.top .topnav) .cap-tools{margin-bottom:8px!important;row-gap:6px!important}
  body:has(.top .topnav) :is(.tb-row,.filters,.lb-fil,.pn-bar,.cap-tools,.alm-bar) :is(select,input[type=search],input[type=text],input[type=date],input:not([type])){height:36px!important;min-height:0!important;padding-top:0!important;padding-bottom:0!important;font-size:14px!important}
  body:has(.top .topnav) #search{height:36px!important;min-height:0!important}
  body:has(.top .topnav) :is(.tb-row,.filters,.lb-fil,.cap-tools) label{font-size:11.5px!important;gap:2px!important}
  body:has(.top .topnav) :is(.tb-row,.filters,.lb-fil,.cap-tools,.pn-bar,.alm-bar) .btn{min-height:0!important;height:34px!important}
  /* tarjetas de totales (Almacén, Prenómina) */
  body:has(.top .topnav) .alm-kpis{margin-bottom:8px!important;gap:8px!important}
  body:has(.top .topnav) .alm-kpis>*{padding:8px 14px!important;min-height:0!important}
  body:has(.top .topnav) .alm-kpis>*>:first-child{font-size:22px!important;line-height:1.15!important}
  /* avisos y notas entre el encabezado y la lista */
  body:has(.top .topnav) #listView>.vistas,body:has(.top .topnav) .imss-av,body:has(.top .topnav) .alm-bar,body:has(.top .topnav) main>p.sub,body:has(.top .topnav) .sm2-tip{margin-bottom:8px!important}
}

/* Candidatos: columna «Avisos» (pendientes, enviado, no recontratable, prueba, revisar…) */
.recs td.avisos-c{min-width:110px;max-width:190px;vertical-align:middle}
.recs td.avisos-c>span{display:inline-block;margin:2px 4px 2px 0;white-space:nowrap}
.recs td.avisos-c:empty::before{content:"—";color:var(--muted)}

.recs td.fechas-c{min-width:96px;font-size:12.5px;line-height:1.35;vertical-align:middle}
.recs td.fechas-c>span{display:block;white-space:nowrap}.recs td.fechas-c .fc-cap{color:var(--muted)}.recs td.fechas-c .fc-no{color:var(--muted);font-style:italic}
@media (min-width:1101px){.recs .estado-c .meter i{width:56px!important;min-width:0!important}.recs .estado-c{white-space:nowrap}.recs td.upd{min-width:0;font-size:12.5px}}
@media (min-width:1101px){.recs td.estado-c{white-space:normal;width:1%}.recs .estado-c .estado{display:block;width:max-content;margin-bottom:4px}.recs .estado-c .meter{min-width:0!important;display:flex;align-items:center;gap:6px}}

/* «Actualizado» va ahora dentro de la columna Fechas (Captura · Envío · Actualizado) */
.recs th.th-upd,.recs td.upd{display:none}
.recs td.fechas-c .fc-act{color:var(--muted);font-size:11.5px;white-space:normal;max-width:170px}
@media (min-width:1101px){.recs td.meta-ingreso{white-space:nowrap}}
@media (max-width:1100px){
  .recs td.upd{display:none!important}
  .recs tr.row td.avisos-c,.recs tr.row td.fechas-c{display:block!important;grid-column:1/-1;padding:4px 0 0!important;max-width:none;min-width:0;border:0!important}
  .recs tr.row td.avisos-c:empty{display:none!important}
  .recs tr.row td.fechas-c>span{display:inline;margin-right:10px;white-space:normal}
}

/* Columna Fechas: dos renglones alineados (Captura / Envío), mismo tamaño de letra */
.recs td.fechas-c{min-width:0!important;white-space:nowrap;vertical-align:middle}
.recs td.fechas-c .fc-g{display:grid;grid-template-columns:auto auto;column-gap:10px;row-gap:3px;align-items:baseline;font-size:12.5px;line-height:1.35}
.recs td.fechas-c .fc-l{color:var(--muted)}
.recs td.fechas-c .fc-v{font-variant-numeric:tabular-nums;color:var(--ink);font-weight:600}
.recs td.fechas-c .fc-v.ok{color:#2E9E6B}
.recs td.fechas-c .fc-v.no{color:var(--muted);font-weight:500}
.recs td.avisos-c:empty::before{content:none!important}
/* Estado: etiqueta y barra del mismo ancho */
@media (min-width:1101px){.recs .estado-c .estado{width:104px!important;text-align:center;box-sizing:border-box}.recs .estado-c .meter{width:104px;display:flex;align-items:center;gap:6px}.recs .estado-c .meter i{width:62px!important;flex:none}}
@media (max-width:1100px){.recs tr.row td.fechas-c .fc-g{grid-template-columns:auto auto auto auto;justify-content:start}}

/* Columnas que se pueden hacer más angostas o más anchas (computadora) */
.col-rs{display:none}
@media (min-width:1101px){
  table thead th .col-rs{display:block;position:absolute;top:0;right:0;width:9px;height:100%;cursor:col-resize;z-index:5;touch-action:none}
  table thead th .col-rs::after{content:"";position:absolute;top:22%;bottom:22%;right:0;left:auto;width:1px;background:var(--line);transition:background .15s,width .15s}
  table thead th:hover .col-rs::after{background:#E9A020;width:2px}
  table thead th:last-child .col-rs{right:0}
  body.col-arrastre,body.col-arrastre *{cursor:col-resize!important;user-select:none!important}
  table.col-fijas td,table.col-fijas th{overflow:hidden;text-overflow:ellipsis}
  table.col-fijas td{overflow-wrap:break-word;word-break:normal;-webkit-hyphens:auto;hyphens:auto}
}

/* Candidatos (computadora): la foto va junto al nombre, no en su propia columna */
.recs td.name .nm-foto{display:none}
@media (min-width:1101px){
  .recs thead th.th-foto,.recs td.thumb{display:none!important}
  .recs td.name.con-foto{position:relative;padding-left:64px!important}
  .recs td.name .nm-foto{display:block;position:absolute;left:12px;top:50%;transform:translateY(-50%);width:40px;height:46px;border-radius:8px;overflow:hidden;background:var(--wash,#E6EAEE)}
  .recs td.name .nm-foto img{width:100%;height:100%;object-fit:cover;display:block}
  .recs td.name .nm-foto .nophoto{display:block;width:100%;height:100%}
  html.densa .recs td.name.con-foto{padding-left:48px!important}html.densa .recs td.name .nm-foto{width:28px;height:32px;left:10px}
}

/* Prenómina (computadora): encabezado compacto para que la tabla quede con su propio desplazamiento y lo de arriba fijo */
@media (min-width:1101px){
  .pn-bar{flex-wrap:wrap!important;gap:8px!important;align-items:flex-end!important;row-gap:6px!important}
  .pn-bar>label{flex:0 0 220px}
  .pn-bar .pn-acc{margin-left:auto!important;flex-wrap:nowrap!important;width:auto!important}
  .pn-bar .pn-acc .btn,.pn-bar .pn-sem .btn,.pn-bar .pn-tipo button{height:36px!important;min-height:0!important}
  .pn-bar .pn-acc #pCopiar{white-space:nowrap}
  .pn-bar .pn-estado{white-space:nowrap}
  /* tarjetas de totales en una franja baja */
  #pRes.alm-kpis>*{padding:6px 12px!important}
  #pRes.alm-kpis>* small,#pRes.alm-kpis>* .sub{display:inline!important;margin-left:6px}
  /* paleta de turnos: los tres grupos en una sola franja, sin textos de ayuda */
  html body #pPal.pn-pal{display:flex!important;flex-wrap:wrap!important;align-items:center!important;gap:6px 16px!important;padding:8px 12px!important;margin-bottom:8px!important;grid-template-columns:none!important}
  html body #pPal .pn-pg{display:flex!important;align-items:center!important;gap:6px!important;padding:0!important;border:0!important;margin:0!important;grid-template-columns:none!important}
  html body #pPal .pn-pal-h{display:none!important}
  .pn-pal .pn-pgt{font-size:10px!important;min-width:0!important;margin:0!important}
  .pn-pal .pn-pgb{display:flex!important;flex-wrap:wrap;gap:4px!important}
  .pn-pal .pn-pb{min-height:0!important;height:30px!important;padding:0 8px 0 4px!important;gap:5px!important}
  .pn-pal .pn-pb .pn-pl{font-size:12.5px!important}
  .pn-pal .pn-pk{min-width:26px!important;height:22px!important;font-size:11px!important}
  .pn-pal>p,.pn-pal .pn-tip,.pn-pal .pn-ayuda{display:none!important}
}
@media (min-width:1101px) and (max-width:1750px){.pn-pal .pn-pb .pn-pl{display:none!important}.pn-pal .pn-pb{padding:0 4px!important}}
@media (min-width:1101px) and (max-width:1500px){.pn-head h1 small{display:none!important}html body #pPal.pn-pal{flex-wrap:nowrap!important;overflow-x:auto;scrollbar-width:none;gap:4px 10px!important}html body #pPal .pn-pgt{display:none!important}}

@media (min-width:1101px){
  /* Prenómina con la tabla en su recuadro: la nota del cálculo (debajo) se oculta para darle espacio; el título se compacta */
  main:has(#pTbl.lw-auto:not(.lw-pegado))>p.note{display:none!important}
  .pn-head{flex-wrap:nowrap!important;align-items:center!important}
  .pn-head h1 small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:46vw;display:block}
}
@media (min-width:1101px) and (max-width:1500px){
  .pn-head .pn-acc{flex-wrap:nowrap!important;gap:6px!important;width:auto!important}
  .pn-head .pn-acc .btn{height:36px!important;min-height:0!important;padding:0 10px!important;font-size:13px!important;white-space:nowrap}
  .pn-head .pn-acc .pn-xl>.btn{white-space:nowrap}
}
html body #pPal.pn-pal[hidden]{display:none!important}
.rostro.r-reint{cursor:pointer;text-decoration:underline;text-underline-offset:2px}

/* Filtros plegables */
.filters .flt-bar{display:flex;align-items:center;gap:6px;flex-wrap:wrap;align-self:flex-end;min-height:36px}
.filters .flt-btn{display:inline-flex!important;align-items:center;gap:6px;height:36px;min-height:0!important;padding:0 12px!important;white-space:nowrap}
.filters .flt-btn.on{border-color:#E9A020!important}
.filters .flt-n{display:inline-grid;place-items:center;min-width:20px;height:20px;padding:0 5px;border-radius:10px;background:#E9A020;color:#0E0C2E;font:700 11.5px var(--body,system-ui)}
.filters .flt-n[hidden]{display:none}
.filters .flt-chips{display:contents}
.filters .flt-chip{display:inline-flex;align-items:center;gap:6px;height:30px;padding:0 6px 0 11px;border-radius:999px;border:1px solid var(--line);background:var(--surface);color:var(--ink);font:600 12.5px var(--body,system-ui);cursor:pointer;max-width:280px}
.filters .flt-chip span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.filters .flt-chip b{display:inline-grid;place-items:center;width:18px;height:18px;border-radius:50%;background:var(--line);font-size:10px;color:var(--muted)}
.filters .flt-chip:hover{border-color:#E9A020}.filters .flt-chip:hover b{background:#E9A020;color:#0E0C2E}
.filters.flt-cerrado>label:not(:has(input[type=search])):not(:has(input[name=q])),.filters.flt-cerrado>.ff-r{display:none!important}

/* Asistencia › Checadas en columnas */
.chk-cols td{vertical-align:middle}
.chk-cols td.c-fecha,.chk-cols td.c-ori,.chk-cols td.c-tipo{white-space:nowrap}
.chk-cols td.c-ros .rostro,.chk-cols td.c-ubi .rostro,.chk-cols td.c-acc .rostro{margin:2px 4px 2px 0;display:inline-block}
.chk-cols td.c-ubi{min-width:150px}.chk-cols td.c-acc{min-width:160px}
.chk-cols .chk-btn-al{font-weight:700;color:#B07A0E}
@media (max-width:1100px){.chk-cols thead{display:none}.chk-cols tr{display:grid;grid-template-columns:56px 1fr;gap:2px 10px;padding:10px 0;border-bottom:1px solid var(--line)}
  .chk-cols td{display:block;border:0!important;padding:2px 0!important}.chk-cols td.c-foto{grid-row:1/span 6}.chk-cols td:empty{display:none}}
.chk-cols .rostro{white-space:nowrap}.chk-cols td.c-nom{min-width:170px}

/* Computadora: las notificaciones se abren debajo de la campana de la barra superior (antes salían abajo, junto al menú lateral) */
@media (min-width:1101px){
  body:has(.top .topnav) .notif-panel{top:58px!important;bottom:auto!important;right:24px!important;left:auto!important;width:min(420px,calc(100vw - 48px))!important;max-height:calc(100vh - 80px)!important;z-index:96}
}

/* Asistencia › Checadas «Por persona»: entrada y salida en un renglón */
.chk-modo{margin:0 0 8px}
.chk-pares td.c-fotos{white-space:nowrap}.chk-pares td.c-fotos .chk-th{margin-right:4px}
.chk-pares td.c-dia,.chk-pares td.c-ent,.chk-pares td.c-sal,.chk-pares td.c-hrs{white-space:nowrap}
.chk-pares .par{display:flex;align-items:center;gap:6px;min-height:24px;flex-wrap:wrap}
.chk-pares .par+.par{margin-top:3px}
.chk-pares .par-l{display:inline-grid;place-items:center;width:18px;height:18px;border-radius:5px;background:var(--line);color:var(--muted);font:800 10px var(--body,system-ui);flex:none}
.chk-pares .sin-sal{color:#B07A0E;font-weight:700}
.chk-pares tr.chk-anulada-p{opacity:.75}
.chk-pares .chk-th{width:34px!important;height:40px!important}
.chk-pares td.c-ubi{min-width:110px!important}.chk-pares td.c-acc{min-width:120px!important}.chk-pares td.c-nom{min-width:150px!important}
.chk-pares td{padding-left:8px!important;padding-right:8px!important}
.chk-pares td.c-ubi small.umeta{display:none}
.chk-pares .par{flex-wrap:nowrap!important}.chk-pares .par .rostro{margin:0!important;display:inline-block!important}
.chk-pares .c-fotos .sin-foto{display:inline-grid!important;place-items:center;width:34px;height:40px;vertical-align:middle;color:var(--muted)}
.chk-modo{display:inline-flex!important;margin:0 10px 8px 0!important;vertical-align:middle}
.chk-modo+.seg-alert,.chk-modo~.seg-alert{display:inline-flex!important;vertical-align:middle}

/* Asistencia «Por persona» en el celular: tarjeta compacta (foto y nombre, una línea con entrada/salida/horas, avisos en renglón) */
@media (max-width:1100px){
  .chk-pares thead{display:none}
  .chk-pares tbody tr{display:grid!important;grid-template-columns:auto 1fr auto;grid-template-areas:"f n h" "f t t" "r r r" "a a a";gap:4px 10px;padding:10px 12px!important;border-bottom:1px solid var(--line);align-items:center}
  .chk-pares td{display:block;border:0!important;padding:0!important;min-width:0!important}
  .chk-pares td.c-fotos{grid-area:f;align-self:start;display:flex;gap:3px}
  .chk-pares td.c-fotos .chk-th{width:30px!important;height:36px!important;margin:0!important}
  .chk-pares td.c-nom{grid-area:n;font-size:14px;line-height:1.25}
  .chk-pares td.c-nom a b{font-size:14px}
  .chk-pares td.c-dia{display:none}
  .chk-pares td.c-ent,.chk-pares td.c-sal{grid-area:t;display:inline}
  .chk-pares td.c-ent{grid-area:t}
  .chk-pares td.c-hrs{grid-area:h;align-self:start;font-size:13px}
  .chk-pares td.c-ros{grid-area:r}.chk-pares td.c-ubi{display:none}.chk-pares td.c-acc{grid-area:a}
  .chk-pares .par{display:inline-flex;margin:0 10px 0 0!important}.chk-pares .par+.par{margin-top:0}
  .chk-pares td.c-ent br,.chk-pares td.c-sal br{display:none}
  .chk-pares td.c-ent small,.chk-pares td.c-sal small{display:none}
}
.chk-pares td.c-es-m,.chk-pares th.th-es-m{display:none}
@media (max-width:1100px){.chk-pares td.c-ent,.chk-pares td.c-sal{display:none!important}.chk-pares td.c-es-m{display:block!important;grid-area:t;font-size:13.5px}.chk-pares td.c-es-m .sin-sal{font-weight:700}}
/* (corrección) tarjeta del celular con flex: no se enciman las celdas */
@media (max-width:1100px){
  html body table.chk-pares tbody tr{display:flex!important;flex-wrap:wrap!important;align-items:center;gap:4px 10px;grid-template-columns:none!important;grid-template-areas:none!important;padding:10px 12px!important}
  html body table.chk-pares tbody td{display:block!important;grid-row:auto!important;grid-column:auto!important;grid-area:auto!important;position:static!important;padding:0!important;border:0!important;min-width:0!important;width:auto!important}
  html body table.chk-pares tbody td::before{content:none!important;display:none!important}
  html body table.chk-pares td.c-fotos{order:1;display:flex!important;gap:3px}
  html body table.chk-pares td.c-nom{order:2;flex:1 1 0}
  html body table.chk-pares td.c-hrs{order:3;font-size:13px}
  html body table.chk-pares td.c-es-m{order:4;flex:1 1 100%!important;font-size:13.5px}
  html body table.chk-pares td.c-ros{order:5;flex:1 1 100%!important}
  html body table.chk-pares td.c-acc{order:6;flex:1 1 100%!important}
  html body table.chk-pares td.c-dia,html body table.chk-pares td.c-ent,html body table.chk-pares td.c-sal,html body table.chk-pares td.c-ubi{display:none!important}
  html body table.chk-pares td.c-hrs:has(> :only-child:not(b)){display:none!important}
}

/* Celular: botón «Compacta» en Asistencia y tarjetas más bajas en vista compacta */
.dens-m{display:none}
@media (max-width:1100px){
  .dens-m{display:inline-flex!important;align-items:center;gap:6px;height:36px;min-height:0!important;padding:0 12px!important;vertical-align:middle;margin:0 0 8px}
  html.densa .dens-m{border-color:#E9A020!important;color:#B07A0E}
  /* Candidatos */
  html.densa .recs tr.row td.name small.exam,html.densa .recs tr.row td.meta-puesto,html.densa .recs tr.row .ed-lap{display:none!important}
  html.densa .recs tr.row td.thumb img,html.densa .recs tr.row td.thumb .nophoto{width:34px!important;height:40px!important}
  html.densa .recs tr.row td.acts .btn{min-height:0!important;height:32px!important;font-size:13px!important}
  html.densa .recs tr.row{padding-top:8px!important;padding-bottom:8px!important}
  /* Asistencia por persona */
  html.densa table.chk-pares tbody tr{padding:7px 10px!important;gap:2px 8px!important}
  html.densa table.chk-pares td.c-fotos .chk-th{width:24px!important;height:28px!important}
  html.densa table.chk-pares td.c-nom a b{font-size:13px}
  html.densa table.chk-pares td.c-ros .rostro,html.densa table.chk-pares td.c-acc{font-size:12px}
  html.densa table.chk-pares td.c-ros{flex:0 1 auto!important}html.densa table.chk-pares td.c-acc{flex:1 1 auto!important}
}

/* Prenómina › Bajas: lista paginada y compacta */
.pn-bj-pag{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:8px;font-size:13px}.pn-bj-pag select{height:32px;margin-left:6px}
#bjPg{display:flex;align-items:center;gap:8px}#bjPg .btn{min-height:0;height:32px;width:36px;padding:0}
#bjSv{height:36px;max-width:220px}
.pn-bj-t td{padding-top:7px!important;padding-bottom:7px!important;vertical-align:middle}
.pn-bj-t td.bj-nom b{display:block;font-size:13.5px;line-height:1.25}.pn-bj-t td.bj-nom small{display:block;font-size:11.5px}
.pn-bj-t td.bj-mot{max-width:170px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.pn-bj-t td.bj-est small{display:inline;margin-left:4px}
.pn-bj-pag label{display:inline-flex!important;flex-direction:row!important;align-items:center;gap:6px;font-weight:600}.pn-bj-pag label select{margin:0!important;width:auto}

/* ✕ en búsquedas y ojito en contraseñas */
.cx-w{display:grid!important;grid-template-columns:1fr;align-items:center;position:relative;box-sizing:border-box}
.cx-w>input{grid-area:1/1;box-sizing:border-box}
.cx-w>input.cx-con{padding-right:38px!important}
.cx-w>.cx-b{grid-area:1/1;justify-self:end;margin-right:6px;width:28px;height:28px;display:inline-grid;place-items:center;border:0;border-radius:50%;background:transparent;color:var(--muted);cursor:pointer;padding:0;font-size:13px;line-height:1;z-index:1}
.cx-w>.cx-b:hover{background:var(--line);color:var(--ink)}
.cx-w>.cx-b[hidden]{display:none!important}
.cx-w>input[type=search]::-webkit-search-cancel-button{display:none;-webkit-appearance:none}

/* Rotación › Encuestas de salida */
.rt-enc{margin-top:16px}.rt-enc-h{display:flex;flex-wrap:wrap;align-items:center;gap:8px 14px;margin-bottom:8px}.rt-enc-h h2{margin:0}.rt-enc-h .btn{margin-left:auto}
.rt-cal{list-style:none;margin:0;padding:0}.rt-cal li{display:flex;justify-content:space-between;gap:10px;padding:6px 0;border-bottom:1px solid var(--line);font-size:14px}
.rt-cal b{min-width:38px;text-align:center;border-radius:8px;padding:1px 6px}.rt-cal b.mal{background:#FDE8E6;color:#B3261E}.rt-cal b.reg{background:#FFF4D6;color:#8A5A00}.rt-cal b.bien{background:#E3F4EA;color:#1E7F4F}
html[data-theme=dark] .rt-cal b.mal,html.dark .rt-cal b.mal{background:#4A1F1C;color:#FFB4AB}

/* Encuesta de salida (diálogo del panel) */
.enc-dlg{width:min(520px,calc(100vw - 24px));max-height:calc(100vh - 40px);border:1px solid var(--line);border-radius:16px;padding:0;background:var(--surface,#fff);color:var(--ink)}
.enc-dlg::backdrop{background:rgba(10,12,30,.5)}
.enc-dlg header{display:flex;justify-content:space-between;align-items:flex-start;gap:10px;padding:16px 18px 8px}.enc-dlg h3{margin:0;font-size:18px}.enc-dlg header p{margin:2px 0 0}
.enc-dlg .enc-b{padding:4px 18px 10px;overflow:auto;max-height:calc(100vh - 170px)}.enc-dlg footer{padding:10px 18px 14px;border-top:1px solid var(--line)}
.enc-qr{width:210px;height:210px;margin:10px auto;background:#fff;padding:8px;border-radius:12px}.enc-qr svg{width:100%;height:100%;display:block}
.enc-url{display:flex;gap:8px;margin:8px 0}.enc-url input{flex:1;min-width:0}
.enc-acc{display:flex;flex-wrap:wrap;gap:8px;margin:8px 0}.enc-acc .btn{flex:1 1 auto;justify-content:center}
.enc-ok{color:#1E7F4F;font-weight:700}.enc-r{padding:8px 0;border-bottom:1px solid var(--line);font-size:14px}.enc-r>span{display:block;color:var(--muted);font-size:13px;margin-bottom:2px}
.enc-r ul{margin:2px 0 0;padding-left:18px}
.rt-main .acard{position:static!important;top:auto!important}

/* Asistencia «Por persona»: horas de la semana */
.chk-pares td.c-sem{white-space:nowrap}.chk-pares td.c-sem .rostro{margin-top:2px;font-size:11.5px}
.rostro.r-dud{background:#FFF1D6;color:#8A5A00}
@media (max-width:1100px){html body table.chk-pares td.c-sem{order:3;font-size:12.5px}html body table.chk-pares td.c-sem br{display:none}html body table.chk-pares td.c-sem small{display:inline}}
@media (min-width:1101px){.chk-pares td.c-ubi{min-width:90px!important}.chk-pares td.c-acc{min-width:105px!important}.chk-pares td.c-nom{min-width:140px!important}.chk-pares td.c-dia{white-space:normal!important;min-width:70px}.chk-pares td,.chk-pares th{padding-left:6px!important;padding-right:6px!important}}
.chk-pares.un-dia .th-dia,.chk-pares.un-dia td.c-dia{display:none!important}.chk-pares .c-fotos .sin-foto{display:none!important}

/* Computadora: la barra de arriba de la tabla (Por persona / Cada registro) no repite Descargar ni Vista compacta, que ya están en los títulos de la tabla */
@media (min-width:900px){.oc-acc.con-seg>[data-dens],.oc-acc.con-seg>.oc-xl-ico,.oc-acc.con-seg>.oc-xl{display:none!important}}
/* Encuesta de salida según el perfil (Administración › Roles) */
html.po-enc-enviar [data-encsal]{display:none!important}
html.po-enc-respuestas .enc-dlg footer,html.po-sec-tablero .enc-dlg footer{display:none!important}
.enc-dlg .enc-pdf{margin:2px 0 8px}
.enc-dlg .enc-fs{margin:-4px 0 8px}.enc-falta{border:1px dashed #E9A020;border-radius:12px;padding:10px 12px;margin:0 0 10px}.enc-falta .enc-qr{width:170px;height:170px}

/* Celular: sin «hover pegado» en las pestañas de Asistencia; solo la activa se resalta */
@media (hover:none){.asis-nav button:not(.on):hover,.asis-nav button:not(.on):focus{background:transparent!important;color:inherit}}
.asis-nav button:not(.on):focus:not(:focus-visible){background:transparent!important}

/* Asistencia › Horas por día en el celular: tarjeta compacta, sin salirse de la pantalla */
@media (max-width:1100px){
  table.hrs-tbl,table.hrs-tbl tbody{display:block;width:100%}
  table.hrs-tbl tr:first-child{display:none}
  table.hrs-tbl tr{display:grid!important;grid-template-columns:1fr auto;grid-template-areas:"nom hrs" "dat hrs";gap:2px 12px;padding:10px 12px!important;border-bottom:1px solid var(--line)}
  table.hrs-tbl td{display:inline!important;border:0!important;padding:0!important;min-width:0!important}
  table.hrs-tbl td.h-nom{grid-area:nom;font-size:14px;line-height:1.25;overflow:hidden;text-overflow:ellipsis}
  table.hrs-tbl td.h-nom small{display:block}
  table.hrs-tbl td.h-hrs{grid-area:hrs;align-self:center;text-align:right;font-size:15px;white-space:nowrap}
  table.hrs-tbl td.h-hrs small,table.hrs-tbl td.h-hrs a{font-size:12px}
  table.hrs-tbl td.h-dia,table.hrs-tbl td.h-ent,table.hrs-tbl td.h-sal{grid-area:dat;font-size:13px;color:var(--muted)}
  table.hrs-tbl tr{grid-template-areas:"nom hrs" "dat hrs"}
  table.hrs-tbl td.h-dia{grid-row:2;grid-column:1}
  table.hrs-tbl td.h-ent,table.hrs-tbl td.h-sal{display:none!important}
  table.hrs-tbl td.h-dia::after{content:attr(data-es)}
  .tbl-scroll:has(> table.hrs-tbl){overflow-x:hidden!important;max-width:100%}
}

/* «Por persona» en el celular: horas del día y de la semana en un mismo renglón, alineadas */
@media (max-width:1100px){
  html body table.chk-pares td.c-es-m{order:4}
  html body table.chk-pares td.c-hrs,html body table.chk-pares td.c-sem{order:5;flex:0 0 auto!important;font-size:13px!important;line-height:20px;align-self:baseline}
  html body table.chk-pares td.c-hrs::before{content:"Hoy ";color:var(--muted);font-weight:500}
  html body table.chk-pares td.c-sem::before{content:"Semana ";color:var(--muted);font-weight:500}
  html body table.chk-pares td.c-hrs{margin-right:14px!important}
  html body table.chk-pares td.c-hrs b,html body table.chk-pares td.c-sem b{font-size:13px}
  html body table.chk-pares td.c-sem .rostro{margin:0 0 0 6px!important;vertical-align:baseline}
  html body table.chk-pares td.c-ros{order:6}html body table.chk-pares td.c-acc{order:7}
  html body table.chk-pares td.c-nom{flex:1 1 calc(100% - 90px)!important}
}
@media (max-width:1100px){
  table.hrs-tbl{width:100%!important;min-width:0!important;table-layout:auto}
  table.hrs-tbl thead,table.hrs-tbl tr:has(>th){display:none!important}
  table.hrs-tbl tr{grid-template-columns:minmax(0,1fr) auto!important;width:100%;box-sizing:border-box}
  table.hrs-tbl td.h-nom b{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  html body table.chk-pares td.c-hrs::before{content:"Hoy "!important;display:inline!important}
  html body table.chk-pares td.c-sem::before{content:"Semana "!important;display:inline!important}
}

/* Asistencia: ‹ Hoy › para cambiar de día o de periodo */
.asis-dnav{display:inline-flex;align-items:flex-end;gap:4px;align-self:flex-end}
.asis-dnav .btn{min-height:0!important;height:38px;padding:0 12px!important;font-size:15px;font-weight:700}
.asis-dnav .btn[data-dnav="-1"],.asis-dnav .btn[data-dnav="1"]{width:38px;padding:0!important;font-size:20px;line-height:1}
/* Foto del registro: ‹ › entre registros */
.chk-fhead{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:10px}
.chk-fhead>div{flex:1;text-align:center;min-width:0}.chk-fhead b{display:block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.chk-fnav{width:42px;height:42px;min-height:0!important;padding:0!important;font-size:22px;line-height:1;flex:none}
.chk-fnav[disabled]{opacity:.35}
.asis-top{display:flex;align-items:center;gap:10px;flex-wrap:wrap}.asis-top .asis-dnav{align-self:center}
.chk-fnav{font-size:26px!important;font-weight:700}

/* Tablas con anchos fijos: nunca se salen de su recuadro (si no caben, se desplazan dentro) */
@media (min-width:1101px){.tbl-wrap:has(>table.col-fijas),.tbl-scroll:has(>table.col-fijas){overflow-x:auto!important}}
/* Asistencia: ‹ Hoy ›, Filtros, búsqueda y fechas a la misma altura y alineados abajo */
@media (min-width:1101px){
  .asis-dnav .btn,.lh-filtros .flt-btn,#lhFiltros .flt-btn{height:36px!important;min-height:36px!important;box-sizing:border-box}
  .asis-dnav{align-self:flex-end!important;margin:0!important}
  .asis-dnav .btn[data-dnav="-1"],.asis-dnav .btn[data-dnav="1"]{width:36px!important}
}
@media (min-width:1101px){html body .asis-dnav>.btn,html body .flt-bar>.flt-btn,html body .flt-btn{height:36px!important;min-height:36px!important;max-height:36px!important;box-sizing:border-box!important}}
/* barra de filtros: botones a la misma altura que la búsqueda y las fechas (36 px) */
body:has(.top .topnav) .filters .btn,body:has(.top .topnav) .filters .flt-btn{height:36px!important;min-height:36px!important}

/* Barra de filtros ordenada: arriba búsqueda · ‹ Hoy › · fechas · Filtros · Vistas; al abrir «Filtros», los filtros van en su propio renglón, del mismo ancho */
.flt-salto{display:none}
@media (min-width:1101px){
  .filters.flt-on:not(.flt-cerrado)>.flt-salto{display:block;flex:0 0 100%;order:90;height:0;margin:0;padding:0}
  .filters.flt-on:not(.flt-cerrado)>label:not(:has(#asD,#asH)){order:91;flex:0 1 210px!important;min-width:150px;max-width:260px}
  .filters.flt-on:not(.flt-cerrado)>label:not(:has(#asD,#asH)) select{width:100%}
  .tb-row:has(>.filters.flt-on:not(.flt-cerrado))>.lh-meta,.tb-row:has(>.filters.flt-on:not(.flt-cerrado))>.vistas{order:5}
  .tb-row:has(#asD) label:has(#asD),.tb-row:has(#asD) label:has(#asH){flex:0 0 170px!important}
}
/* envoltorio de una búsqueda escondida: tampoco ocupa lugar */
.cx-w:has(>input.hidden),.cx-w:has(>input[hidden]),.cx-w:has(>input[style*="display: none"]){display:none!important}
/* Asistencia: Desde y Hasta siempre a la vista, aunque «Filtros» esté cerrado */
html body .filters.flt-on.flt-cerrado>label:has(#asD),html body .filters.flt-on.flt-cerrado>label:has(#asH){display:flex!important}
@media (min-width:1101px){
  .tb-row:has(#asD) label:has(#asD),.tb-row:has(#asD) label:has(#asH){flex:0 0 150px!important;width:150px}
  .tb-row:has(#asD)>.cx-q{flex:1 1 200px!important;min-width:180px;max-width:360px}
}
@media (min-width:1101px){.tb-row:has(#asD)>.lh-meta{display:none!important}}   /* el periodo ya se ve en Desde / Hasta */
@media (min-width:1101px){html body .tb-row:has(#asD)>.cx-q{flex:1 1 160px!important;min-width:140px!important;max-width:340px!important;width:auto!important}html body .tb-row:has(#asD) label:has(#asD),html body .tb-row:has(#asD) label:has(#asH){flex:0 0 142px!important;width:142px!important}}
@media (min-width:1101px){html body .tb-row:has(#asD) label:has(#asD),html body .tb-row:has(#asD) label:has(#asH){flex:0 0 134px!important;width:134px!important;min-width:0!important}html body .tb-row:has(#asD)>.cx-q{flex-basis:120px!important;min-width:120px!important}}
/* Rotación › Encuestas contestadas (con su PDF) */
.rt-enc-lista{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:8px}
.rt-enc-it{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:8px 10px;border:1px solid var(--line);border-radius:10px}
.rt-enc-it b{display:block;font-size:13.5px}.rt-enc-it small{color:var(--muted);font-size:12px}
.rt-enc-it .btn{min-height:0;height:32px;padding:0 12px;flex:none}

/* Pantallas que se veían como franja angosta al centro: ahora alineadas a la izquierda como las demás (con un tope de ancho para que los formularios no se estiren de más) */
@media (min-width:1101px){
  html body main.ci-main,html body main.hy-main,html body main.dp-main,html body main.sv-main,html body main.di-main,html body main.cuenta-page{max-width:1600px!important;margin:0!important;box-sizing:border-box}
}
.cob-elige{display:flex;flex-wrap:wrap;gap:8px;margin-top:10px}.cob-elige .btn{min-height:0;height:36px}
@media (min-width:1101px){html body main.ci-main,html body main.hy-main,html body main.dp-main,html body main.sv-main,html body main.di-main,html body main.cuenta-page{margin:0 0 0 max(20px,calc((100vw - var(--sbw,260px) - 2200px)/2))!important;padding-left:24px!important;padding-right:24px!important}}
@media (min-width:1101px){html body main.cuenta-page{width:auto!important;max-width:min(1600px,calc(100vw - var(--sbw,260px) - 40px))!important}}

/* Seguimiento de ingresos en Pendientes y en la ficha (historial laboral y llamadas) */
.sg-pend{background:var(--surface);border:1px solid var(--line);border-left:4px solid #E9A020;border-radius:14px;padding:12px 16px;margin:0 0 14px}
.sg-pend header{display:flex;align-items:center;gap:10px}.sg-pend h3{margin:0;font-size:15px;flex:1}.sg-pend header .btn{padding:6px 12px;min-height:0}
.sg-pend ul{list-style:none;margin:8px 0 0;padding:0;display:grid;gap:6px}.sg-pend li small{display:block;color:var(--muted);font-size:12.5px}.sg-pend .hint{margin:6px 0 0}
.per-box[hidden]{display:none}.per-box > div{display:grid;gap:8px;padding-top:6px}
.per-it{border:1px solid var(--line);border-radius:10px;padding:8px 10px;display:grid;gap:2px;font-size:13.5px}.per-it small{color:var(--muted);font-size:12.5px}.per-it q{font-size:13px}
.per-docs,.per-acc{display:flex;gap:8px;flex-wrap:wrap;margin-top:4px}.per-docs a{font-size:12.5px}
/* Encuesta de salida: corregir respuestas dentro del recuadro */
.enc-ef .enc-r input[type=text],.enc-ef .enc-r textarea,.enc-ef .enc-r select{width:100%;box-sizing:border-box;min-height:40px;border:1px solid var(--line);border-radius:3px;padding:6px 10px;background:var(--field);color:var(--ink);font:15px var(--body)}
.enc-ef .enc-r textarea{min-height:80px}
.enc-eo{display:flex;flex-wrap:wrap;gap:6px}.enc-eo label{display:inline-flex;align-items:center;gap:6px;border:1px solid var(--line);border-radius:3px;padding:6px 10px;font-size:14px;cursor:pointer;background:var(--field)}
.enc-eo label:has(input:checked){border-color:var(--gold,#E9A020);background:var(--gold-soft,#FFF7E6)}.enc-eo label input[type=text]{min-height:32px!important;width:180px!important}
.enc-esc{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:6px 10px}.enc-esc label{font-size:13px;display:grid;gap:2px}
.enc-err{display:block;color:#C0392B;font-size:12.5px;margin-top:4px}
.enc-efbar{position:sticky;bottom:-10px;background:var(--surface);padding:10px 0;margin:6px 0 0;border-top:1px solid var(--line)}
.enc-acc .enc-pdf,.enc-acc .enc-ed{flex:1 1 0;min-height:42px}
td.col-x.enc-si{color:#1E6B45;font-weight:700}td.col-x.enc-no{color:#A3361A}
[data-theme="dark"] td.col-x.enc-si{color:#6FD39B}[data-theme="dark"] td.col-x.enc-no{color:#F0A08F}
.enc-eo label input[type=radio],.enc-eo label input[type=checkbox]{width:16px!important;height:16px!important;min-height:0!important;margin:0!important;padding:0!important;flex:0 0 auto;accent-color:#E9A020}
.enc-eo label{flex:0 1 auto;line-height:1.25}
.enc-eo label{margin:0!important}
.sg-pend li a{color:var(--ink);font-weight:600;text-decoration:none}.sg-pend li a:hover{text-decoration:underline}
.sg-pend h3{text-transform:none;letter-spacing:0}

/* Tarjeta «Lo trajo» en el resumen del expediente */
.fr-k .fr-lnk{border:0;background:none;padding:0;font:inherit;font-weight:700;color:var(--ink);text-decoration:underline;cursor:pointer}
.fr-k .fr-capsel{display:block;box-sizing:border-box;width:100%;max-width:100%;margin:3px 0 1px;min-height:34px;border:1px solid var(--gold,#E9A020);border-radius:6px;padding:4px 8px;background:var(--field);color:var(--ink);font:600 14px var(--body)}
