* { box-sizing: border-box; }
:root { color-scheme: light; }   /* 02/10: la página es solo clara (en celulares con modo oscuro salía texto oscuro sobre fondo oscuro) */
body { margin: 0; font-family: system-ui, -apple-system, "Segoe UI", sans-serif; background: #f4f6f8; color: #1f2933; }
button { font: inherit; cursor: pointer; }

/* Pantalla de entrada */
body.entrada { display: flex; min-height: 100vh; align-items: center; justify-content: center; }
.tarjeta-entrada { background: #fff; padding: 2rem; border-radius: 12px; width: 100%; max-width: 360px;
  box-shadow: 0 4px 20px rgba(0,0,0,.08); }
.tarjeta-entrada h1 { margin: 0; color: #0b5cad; }
.sub { margin: .2rem 0 1.5rem; color: #52606d; }
label { display: block; margin: .8rem 0 .3rem; font-weight: 600; font-size: .9rem; }
input { width: 100%; padding: .6rem .7rem; border: 1px solid #cbd2d9; border-radius: 8px; font: inherit; }
input:focus { outline: 2px solid #0b5cad; border-color: transparent; }
#boton { width: 100%; margin-top: 1.2rem; padding: .7rem; border: 0; border-radius: 8px; background: #0b5cad; color: #fff; font-weight: 600; }
#boton:disabled { opacity: .6; }
.mensaje { color: #c62828; min-height: 1.2em; margin: .8rem 0 0; }
.nota { font-size: .8rem; color: #7b8794; margin: 1rem 0 0; }

/* Página principal */
.barra { display: flex; justify-content: space-between; align-items: center; padding: .8rem 1.2rem; background: #0b5cad; color: #fff; }
.marca { font-weight: 700; font-size: 1.2rem; }
.enlace { background: none; border: 1px solid rgba(255,255,255,.6); color: #fff; border-radius: 6px; padding: .2rem .6rem; margin-left: .5rem; }
/* Tareas en curso (2026-09-27). Clases propias (p-…) para no chocar con la barra azul de arriba (.barra). */
.tareas { background: #fff8e1; border-bottom: 1px solid #f3e3ad; padding: .45rem 1.2rem; font-size: .82rem; color: #3e4c59; }
.tareas.listas { background: #f3faf4; border-bottom-color: #d8eddb; }
.tareas-cabeza { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.tareas-cabeza b { font-weight: 600; }
.tareas-cabeza .hora { color: #9aa5b1; }
.tareas-cabeza .ver { background: none; border: 0; color: #0b5cad; padding: 0; font-size: .8rem; cursor: pointer; }
.tareas-cabeza .ver:hover { text-decoration: underline; }
#tareas-lista { display: grid; gap: .25rem; margin-top: .35rem; }
.p-tarea { display: grid; grid-template-columns: 17em 12em 3em 1fr; gap: .8rem; align-items: center; }
.p-barra { height: 6px; background: #e4e7eb; border-radius: 999px; overflow: hidden; }
.p-relleno { height: 100%; width: 0; background: #0b5cad; border-radius: 999px; transition: width .6s ease; }
.p-tarea.hecha .p-relleno { background: #3a9b46; }
.p-pct { font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; color: #1f2933; }
.p-detalle { color: #7b8794; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 700px) { .p-tarea { grid-template-columns: 1fr 3em; } .p-barra, .p-detalle { grid-column: 1 / -1; } }
@media (prefers-reduced-motion: reduce) { .p-relleno { transition: none; } }
.cuerpo { display: flex; min-height: calc(100vh - 52px); }
.menu { width: 220px; background: #fff; border-right: 1px solid #e4e7eb; padding: 1rem 0; }
.modulo { margin: 0 1rem .6rem; font-size: .75rem; text-transform: uppercase; letter-spacing: .05em; color: #7b8794; }
.menu a { display: block; padding: .6rem 1rem; color: #1f2933; text-decoration: none; border-left: 3px solid transparent; }
.menu a:hover { background: #f0f4f8; }
.menu a.activo { border-left-color: #0b5cad; background: #e8f1fb; font-weight: 600; }
.contenido { flex: 1; padding: 1.5rem 2rem; }
.construccion { font-size: 1.1rem; color: #52606d; }
.estado { color: #7b8794; font-size: .9rem; }

/* Parte 2 (2026-09-26): Movimientos y Alertas */
[hidden] { display: none !important; }
.estado { margin-top: -.4rem; }
.filtros { display: flex; flex-wrap: wrap; gap: .8rem 1rem; align-items: flex-end; background: #fff; border: 1px solid #e4e7eb;
  border-radius: 10px; padding: .9rem 1rem; margin: 1rem 0; }
.filtros label { margin: 0; font-size: .8rem; color: #52606d; display: flex; flex-direction: column; gap: .3rem; }
.filtros .ancho { flex: 1; min-width: 200px; }
.filtros select, .filtros input { padding: .45rem .5rem; border: 1px solid #cbd2d9; border-radius: 6px; font: inherit; background: #fff; }
.secundario { background: #fff; border: 1px solid #cbd2d9; color: #1f2933; border-radius: 6px; padding: .45rem .9rem; }
.secundario:hover { border-color: #0b5cad; color: #0b5cad; }
.totales { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .6rem; margin-bottom: 1rem; }
.total { background: #fff; border: 1px solid #e4e7eb; border-radius: 8px; padding: .6rem .8rem; }
.total .t { display: block; font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: #7b8794; }
.total .v { font-weight: 700; font-size: 1.05rem; font-variant-numeric: tabular-nums; }
/* 2026-09-27: «Caja en vivo» */
.vivo-cabeza { display: flex; align-items: center; gap: 1rem; margin: .4rem 0 .8rem; }
.tabla tr.clicable { cursor: pointer; }
.tabla tr.clicable:hover { background: #f5f9ff; }
.tabla tr.elegida { background: #eef5fc; }

/* 2026-09-27: «Atención inmediata» */
.franja-urgente { display: block; background: #b3261e; color: #fff; padding: .55rem 1.2rem; text-decoration: none; font-size: .95rem; }
.franja-urgente:hover { background: #8f1d17; }
.franja-urgente[hidden] { display: none; }
.franja-urgente u { margin-left: .4rem; }
.rv-gravedad.g-urgente { background: #b3261e; color: #fff; }
.urg-tarjeta { border-left: 5px solid #b3261e; margin-bottom: 1rem; }

/* 2026-09-27: bandeja «Revisar» */
.boton-revisar { margin-left: 1rem; background: #fff3cd; color: #7a4d00; border-radius: 999px; padding: .25rem .8rem;
  font-weight: 700; text-decoration: none; font-size: .9rem; }
.boton-revisar:hover { background: #ffe8a1; }
.rv-avance { display: flex; align-items: center; gap: .8rem; margin: .4rem 0 .8rem; font-weight: 600; }
.rv-avance .p-barra { flex: 1; max-width: 320px; }
.rv-tarjeta { background: #fff; border: 1px solid #e4e7eb; border-radius: 12px; padding: 1.1rem 1.3rem; max-width: 820px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .05); }
.rv-cabeza { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.rv-gravedad { font-weight: 700; font-size: .85rem; padding: .15rem .6rem; border-radius: 999px; background: #eef2f6; }
.rv-gravedad.g-alta { background: #fdecea; color: #b3261e; }
.rv-gravedad.g-media { background: #fff3e0; color: #8a4b00; }
.rv-gravedad.g-pregunta { background: #eef5fc; color: #0b5cad; }
.rv-tipo { font-size: .85rem; color: #52606d; }
.rv-titulo { font-size: 1.2rem; margin: .6rem 0 .3rem; }
.rv-detalle { line-height: 1.5; white-space: pre-wrap; }
.rv-nota-l { display: block; font-size: .85rem; color: #52606d; margin-top: .8rem; }
.rv-tarjeta textarea { width: 100%; font: inherit; border: 1px solid #cbd2d9; border-radius: 8px; padding: .5rem; margin-top: .3rem; box-sizing: border-box; }
.rv-todos { display: block; margin-top: .5rem; }
.rv-botones { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .9rem; }
.rv-b { font: inherit; padding: .55rem .9rem; border-radius: 8px; border: 1px solid #cbd2d9; background: #fff; cursor: pointer; font-weight: 600; }
.rv-b small { font-weight: 400; color: #52606d; }
.rv-ok { background: #e8f5ec; border-color: #1e7b34; color: #1e7b34; }
.rv-despues { background: #eef5fc; border-color: #0b5cad; color: #0b5cad; }
.rv-no { background: #f5f5f5; }
.rv-saltar { margin-left: auto; border-style: dashed; color: #52606d; }
.rv-vacio { font-size: 1.1rem; padding: 2rem 0; }

/* 2026-09-27: pantalla Resumen (agentes de vigilancia) */
.tarjeta-resumen { background: #fff; border: 1px solid #e4e7eb; border-radius: 10px; padding: 1rem 1.2rem; margin-bottom: 1.2rem; }
.tarjeta-resumen h3 { margin: 0 0 .2rem; }
.r-texto { white-space: pre-wrap; line-height: 1.5; }
.r-titulo { margin: 1.4rem 0 .2rem; }
button.chip { font: inherit; cursor: pointer; border: 1px solid #cbd2d9; background: #fff; border-radius: 999px; padding: .25rem .7rem; margin: 0 .4rem .4rem 0; }
button.chip.activo { border-color: #0b5cad; background: #eef5fc; color: #0b5cad; }
/* 2026-09-27: tarjetas que filtran al hacer clic */
button.total { font: inherit; text-align: left; cursor: pointer; color: inherit; }
button.total:hover { border-color: #0b5cad; box-shadow: 0 1px 4px rgba(11, 92, 173, .15); }
button.total:focus-visible { outline: 2px solid #0b5cad; outline-offset: 2px; }
.total.activo { border: 2px solid #0b5cad; background: #eef5fc; }
.total.activo .t::after { content: " · filtrando"; color: #0b5cad; text-transform: none; letter-spacing: 0; }
/* Estado clicable y ventana del motivo */
.est-boton { font: inherit; font-weight: 600; color: inherit; background: none; border: 0; padding: .1rem 0; cursor: pointer;
  text-decoration: underline dotted; text-underline-offset: 3px; white-space: nowrap; }
.est-boton:hover { text-decoration-style: solid; }
.motivo { border: 0; border-radius: 12px; padding: 0; width: min(560px, calc(100vw - 32px)); max-height: 85vh;
  box-shadow: 0 10px 40px rgba(0, 0, 0, .25); color: #1f2933; }
.motivo::backdrop { background: rgba(15, 23, 42, .45); }
.motivo > * { margin-left: 1.2rem; margin-right: 1.2rem; }
.mo-cabeza { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-top: 1rem; }
.mo-cabeza h3 { margin: 0; font-size: 1.1rem; }
.mo-x { background: none; border: 0; font-size: 1.1rem; cursor: pointer; color: #52606d; padding: .3rem; }
.mo-estado { font-weight: 700; margin: .3rem 0 .6rem; }
.motivo h4 { margin: 1rem 0 .4rem; font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: #7b8794; }
.motivo ul { padding-left: 1.2rem; margin-top: 0; line-height: 1.45; }
.mo-pregunta { border: 1px solid #e4e7eb; border-radius: 8px; padding: .7rem .8rem; margin-bottom: .6rem; background: #f8fafc; }
.mo-para { font-size: .78rem; color: #52606d; font-weight: 600; }
.mo-texto { margin: .3rem 0 .5rem; line-height: 1.45; }
.mo-copiar { font: inherit; font-size: .85rem; padding: .35rem .7rem; border-radius: 6px; border: 1px solid #0b5cad;
  background: #fff; color: #0b5cad; cursor: pointer; }
.mo-copiar:hover { background: #eef5fc; }
.mo-tecnico { margin-top: 1rem; margin-bottom: 1.2rem; font-size: .8rem; color: #52606d; }
.mo-tecnico pre { white-space: pre-wrap; font-family: inherit; }
.tabla-caja { overflow-x: auto; background: #fff; border: 1px solid #e4e7eb; border-radius: 10px; }
.tabla { border-collapse: collapse; width: 100%; font-size: .88rem; min-width: 820px; }
.tabla th { text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; color: #52606d;
  background: #f7f9fb; padding: .55rem .7rem; border-bottom: 1px solid #e4e7eb; position: sticky; top: 0; }
.tabla th.ordenable { cursor: pointer; user-select: none; }
.tabla th.ordenable:hover, .tabla th.ordenable:focus-visible { color: #0b5cad; outline: none; }
.tabla th.ordenable::after { content: attr(data-flecha); color: #0b5cad; }
.tabla td { padding: .45rem .7rem; border-bottom: 1px solid #eef1f4; vertical-align: top; }
.tabla .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tabla tr.con-alerta { background: #fff8e6; }
.tabla tr.sin-info { background: #fdecea; }
.tabla tr.historico { color: #7b8794; }
.tabla td.fuerte { font-weight: 700; }
.filtros .casilla { flex-direction: row; align-items: center; gap: .4rem; padding-bottom: .5rem; }
.falta { color: #b3261e; font-weight: 600; white-space: nowrap; text-align: right; }
/* 2026-09-27: estado del DINERO de cada corte; verde solo con el depósito confirmado en el banco */
.est { white-space: nowrap; font-weight: 600; cursor: help; }
.est-ok { color: #1e7b34; }
.est-espera { color: #8a6100; }
.est-mal { color: #b3261e; }
.aviso { color: #a05a00; font-weight: 600; white-space: nowrap; }
.pie { color: #7b8794; font-size: .85rem; }
.ayuda { color: #52606d; max-width: 70ch; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin: .8rem 0 1rem; }
.chip { background: #fff3d6; color: #8a4b00; border-radius: 999px; padding: .3rem .8rem; font-size: .85rem; font-weight: 600; }
.chip.bien { background: #e3f4e6; color: #256b32; }
.chip.construir { background: #1f5fbf; color: #fff; text-decoration: none; }   /* 30/09: que se vea dónde conectar sus hojas */
.contador { background: #c62828; color: #fff; border-radius: 999px; font-size: .7rem; padding: .05rem .45rem; margin-left: .3rem; }
.wa { font-size: .85rem; background: rgba(255,255,255,.15); border-radius: 999px; padding: .2rem .7rem; margin-right: .6rem; }
/* Mis pendientes (2026-09-27) */
.modulo.segundo { margin-top: 1.2rem; }
.contador.azul { background: #0b5cad; }
.nuevo-pendiente { display: flex; flex-wrap: wrap; gap: .6rem; margin: 1rem 0 .4rem; }
.nuevo-pendiente input { flex: 1 1 260px; width: auto; }
.nuevo-pendiente button { border: 0; border-radius: 8px; background: #0b5cad; color: #fff; font-weight: 600; padding: .6rem 1.2rem; }
.lista-pendientes { display: grid; gap: .7rem; max-width: 900px; }
.pendiente { background: #fff; border: 1px solid #e4e7eb; border-left: 4px solid #0b5cad; border-radius: 8px; padding: .8rem 1rem; }
.pendiente.en_espera { border-left-color: #c9a227; }
.pendiente.hecha { border-left-color: #3a9b46; opacity: .7; }
.pendiente.hecha h3 { text-decoration: line-through; }
.p-cabeza { display: flex; align-items: center; gap: .6rem; }
.pendiente h3 { margin: 0; font-size: 1rem; }
.p-estado { font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; padding: .15rem .5rem;
  border-radius: 999px; background: #e8f1fb; color: #0b5cad; white-space: nowrap; }
.pendiente.en_espera .p-estado { background: #fbf1d3; color: #7a5d00; }
.pendiente.hecha .p-estado { background: #e3f4e6; color: #256b32; }
.p-texto { margin: .4rem 0 0; color: #3e4c59; }
.p-fecha { margin: .3rem 0 0; font-size: .8rem; color: #9aa5b1; }
.p-botones { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .6rem; }
.p-botones .secundario { font-size: .82rem; padding: .3rem .7rem; }
.etiqueta-suc { display: inline-block; min-width: 7.5em; text-align: center; padding: .1rem .7rem; border-radius: 999px;
  background: #eef1f4; color: #1f2933; font-size: .85rem; white-space: nowrap; }
.boton-enlace { color: #0b5cad; font-weight: 600; text-decoration: none; white-space: nowrap; }
.boton-enlace:hover { text-decoration: underline; }

@media (max-width: 700px) {
  .cuerpo { flex-direction: column; }
  .menu { width: 100%; display: flex; flex-wrap: wrap; border-right: 0; border-bottom: 1px solid #e4e7eb; padding: .5rem; }
  .modulo { width: 100%; }
  .menu a { border-left: 0; border-bottom: 3px solid transparent; padding: .4rem .6rem; }
  .menu a.activo { border-bottom-color: #0b5cad; }
  /* 2026-09-27: celular. Menú en una sola fila que se desliza, contenido a lo ancho, botones grandes */
  .menu { flex-wrap: nowrap; overflow-x: auto; -webkit-overflow-scrolling: touch; gap: .2rem; }
  .menu .modulo { display: none; }
  .menu a { white-space: nowrap; font-size: .95rem; padding: .55rem .7rem; }
  .contenido { padding: .8rem; }
  .contenido h1 { font-size: 1.35rem; }
  .barra { flex-wrap: wrap; gap: .4rem; padding: .6rem .8rem; }
  .barra .usuario { font-size: .85rem; }
  .boton-revisar { margin-left: 0; }
  .tareas { font-size: .85rem; }
  .rv-tarjeta { padding: .9rem; }
  .rv-titulo { font-size: 1.05rem; }
  .rv-botones { flex-direction: column; }
  .rv-b { width: 100%; padding: .8rem; font-size: 1rem; }
  .rv-saltar { margin-left: 0; }
  .mo-copiar { width: 100%; padding: .6rem; }
  .totales { grid-template-columns: repeat(2, 1fr); }
  .motivo { width: calc(100vw - 16px); }
  .ayuda { font-size: .88rem; }
}

/* ==========================================================================================================
   2026-09-28 · DISEÑO MINIMALISTA «CCF Admin Panel» (David: «un concepto más minimalista, que no se amontonen
   las cosas o botones… es demasiado agobiante»). Van al final y mandan sobre las reglas anteriores.
   Respaldo del diseño anterior: respaldos/antes_minimalista_20260928/.
   ========================================================================================================== */
:root { --azul: #1f5fbf; --tinta: #1d2733; --suave: #6b7785; --linea: #e8ecf1; --fondo: #f6f7f9; --rojo: #c0392b; }
body.minimal { background: var(--fondo); color: var(--tinta); font-size: 15px; }
/* Barra superior blanca: marca a la izquierda; a la derecha, cosas separadas con aire */
body.minimal .barra { background: #fff; color: var(--tinta); border-bottom: 1px solid var(--linea); padding: .7rem 1.6rem;
  position: sticky; top: 0; z-index: 20; }
body.minimal .marca { display: flex; align-items: center; gap: .55rem; font-weight: 600; font-size: 1.05rem; color: var(--tinta);
  text-decoration: none; letter-spacing: .01em; }
.logo { display: inline-grid; place-items: center; background: #1f5fbf; color: #fff; font-weight: 700; font-size: .72rem;
  letter-spacing: .06em; border-radius: 7px; padding: .3rem .45rem; vertical-align: middle; }
.tarjeta-entrada h1 { display: flex; align-items: center; gap: .6rem; color: #1d2733; font-size: 1.4rem; }
.barra-der { display: flex; align-items: center; gap: 1.2rem; }
body.minimal .wa { background: none; padding: 0; margin: 0; font-size: .85rem; color: var(--suave); white-space: nowrap; }
body.minimal .usuario { font-size: .9rem; color: var(--suave); white-space: nowrap; max-width: 14ch; overflow: hidden; text-overflow: ellipsis; }
.salir { background: none; border: 1px solid var(--linea); color: var(--tinta); border-radius: 8px; padding: .35rem .8rem; font-size: .85rem; }
.salir:hover { border-color: var(--azul); color: var(--azul); }
.campana { position: relative; text-decoration: none; font-size: 1.1rem; line-height: 1; }
.burbuja { position: absolute; top: -.45rem; right: -.7rem; background: var(--rojo); color: #fff; font-size: .65rem; font-weight: 700;
  border-radius: 999px; padding: .1rem .38rem; }
/* Menú lateral limpio */
body.minimal .cuerpo { min-height: calc(100vh - 56px); }
body.minimal .menu { width: 210px; background: transparent; border-right: 0; padding: 1.4rem 0 1rem .6rem; }
body.minimal .modulo { font-size: .68rem; letter-spacing: .09em; color: #9aa5b1; margin: 0 1rem .5rem; }
body.minimal .modulo.segundo { margin-top: 1.6rem; }
body.minimal .menu a { border-left: 0; border-radius: 8px; margin: 0 .6rem .15rem 0; padding: .55rem .9rem; color: #3b4754; font-size: .93rem; }
body.minimal .menu a:hover { background: #eceff3; }
body.minimal .menu a.activo { background: #fff; color: var(--azul); font-weight: 600; box-shadow: 0 1px 3px rgba(20, 30, 45, .08); }
body.minimal .contador { font-size: .66rem; }
/* Contenido con aire */
body.minimal .contenido { padding: 1.8rem 2.4rem 3rem; max-width: 1180px; }
body.minimal .contenido h1 { font-size: 1.55rem; font-weight: 650; margin: 0 0 1.1rem; }
body.minimal .estado:empty { display: none; }
body.minimal .ayuda { color: var(--suave); font-size: .9rem; margin: 0 0 1rem; }
/* Tarjetas y tablas más ligeras */
body.minimal .tabla-caja, body.minimal .tarjeta-resumen, body.minimal .rv-tarjeta, body.minimal .total, body.minimal .pendiente {
  border: 1px solid var(--linea); box-shadow: none; border-radius: 12px; }
body.minimal .tabla th { background: #fafbfc; color: #8a95a3; font-weight: 600; }
body.minimal .tabla td { border-bottom-color: #f1f3f6; }
/* Inicio: 4 números grandes */
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-bottom: 1.4rem; }
.kpi { background: #fff; border: 1px solid var(--linea); border-radius: 14px; padding: 1.1rem 1.2rem; text-decoration: none;
  color: var(--tinta); display: flex; flex-direction: column; gap: .35rem; transition: border-color .15s, transform .15s; }
.kpi:hover { border-color: var(--azul); transform: translateY(-1px); }
.kpi-v { font-size: 1.9rem; font-weight: 700; font-variant-numeric: tabular-nums; line-height: 1.1; }
.kpi-t { font-size: .82rem; color: var(--suave); }
.kpi.rojo { border-color: #f1c9c4; background: #fdf4f3; }
.kpi.rojo .kpi-v { color: var(--rojo); }
.tr-cabeza { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; margin-bottom: .6rem; }
.tr-cabeza h3 { margin: 0; font-size: 1rem; }
body.minimal .tarjeta-resumen { padding: 1.2rem 1.4rem; margin-bottom: 1.2rem; }
body.minimal .r-texto { color: #34404d; line-height: 1.6; }
/* Secciones plegables («Ver más») */
.plegable { background: #fff; border: 1px solid var(--linea); border-radius: 12px; padding: .2rem 1.2rem; margin-bottom: .9rem; }
.plegable > summary { cursor: pointer; padding: .85rem 0; font-weight: 600; font-size: .95rem; list-style: none; }
.plegable > summary::-webkit-details-marker { display: none; }
.plegable > summary::before { content: "›"; display: inline-block; margin-right: .6rem; color: var(--suave); transition: transform .15s; }
.plegable[open] > summary::before { transform: rotate(90deg); }
.plegable[open] { padding-bottom: 1rem; }
.plegable .tabla-caja { border: 0; }
.plegable .tareas { background: none; border: 0; padding: 0 0 .8rem; }
.filtros-plegable .filtros { border: 0; padding: 0 0 .6rem; margin: 0; }
/* Botones de las tarjetas «Revisar» menos pesados */
body.minimal .rv-b { font-weight: 600; border-radius: 10px; }
body.minimal .rv-tarjeta { padding: 1.3rem 1.5rem; }
body.minimal .franja-urgente { padding: .6rem 1.6rem; font-size: .9rem; }
@media (max-width: 900px) { .kpis { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 700px) {
  body.minimal .barra { padding: .6rem .9rem; flex-wrap: nowrap; }
  .barra-der { gap: .8rem; }
  body.minimal .usuario { display: none; }            /* en el celular no cabe: el nombre sobra */
  /* el menú ocupa TODO el ancho (antes se quedaba en 210 px y se cortaba) y se desliza con el dedo */
  body.minimal .menu { width: 100%; padding: .4rem .6rem; background: #fff; border-bottom: 1px solid var(--linea); scrollbar-width: none; }
  body.minimal .menu::-webkit-scrollbar { display: none; }
  body.minimal .menu a { margin: 0; padding: .5rem .75rem; }
  body.minimal .menu a.activo { box-shadow: none; background: #eef3fb; }
  body.minimal .contenido { padding: 1rem .9rem 2rem; }
  body.minimal .contenido h1 { font-size: 1.25rem; margin-bottom: .8rem; }
  .kpis { gap: .6rem; }
  .kpi { padding: .85rem .9rem; }
  .kpi-v { font-size: 1.5rem; }
  /* 2026-09-28 (revisión en iPhone): en el celular solo las columnas que importan; nada se sale de la pantalla */
  body.minimal .tabla { min-width: 0; font-size: .85rem; }
  body.minimal .tabla td, body.minimal .tabla th { padding: .5rem .45rem; }
  /* Caja en vivo: Sucursal · Caja · Efectivo que debe haber (lo demás al tocar la sucursal) */
  #p-vivo #vivo-filas td:nth-child(3), #p-vivo #vivo-filas td:nth-child(4), #p-vivo #vivo-filas td:nth-child(5),
  #p-vivo #vivo-filas td:nth-child(6), #p-vivo #vivo-filas td:nth-child(8),
  #vivo-tabla th:nth-child(3), #vivo-tabla th:nth-child(4), #vivo-tabla th:nth-child(5),
  #vivo-tabla th:nth-child(6), #vivo-tabla th:nth-child(8) { display: none; }
  #vivo-mov td:nth-child(3), #vivo-mov td:nth-child(5), #vivo-detalle th:nth-child(3), #vivo-detalle th:nth-child(5) { display: none; }
  #vivo-tabla td, #vivo-tabla th, #vivo-tabla .est { white-space: normal; }   /* que quepa «Efectivo que debe haber» */
  .vivo-cabeza { flex-wrap: wrap; gap: .5rem; }
  /* Cortes: sin Ciudad ni Enviado; totales en una fila que se desliza */
  #m-filas td:nth-child(2), #m-filas td:nth-child(6), #m-encabezado th:nth-child(2), #m-encabezado th:nth-child(6) { display: none; }
  body.minimal .totales { display: flex; overflow-x: auto; gap: .5rem; padding-bottom: .3rem; scrollbar-width: none; }
  body.minimal .totales::-webkit-scrollbar { display: none; }
  body.minimal .total { flex: 0 0 auto; min-width: 118px; padding: .5rem .7rem; }
  body.minimal .etiqueta-suc { min-width: 0; padding: .1rem .5rem; }
  body.minimal .est-boton { white-space: normal; text-align: left; }
  /* Alertas: sin Ciudad */
  #a-filas td:nth-child(3), #a-encabezado th:nth-child(3) { display: none; }
}
/* Pantallas muy chicas (iPhone SE y similares): la marca en una línea y WhatsApp solo como punto de color */
body.minimal .marca { white-space: nowrap; }
@media (max-width: 440px) {
  body.minimal .wa-texto { display: none; }
  .barra-der { gap: .7rem; }
}
@media (max-width: 340px) {
  body.minimal .marca { font-size: .95rem; gap: .4rem; }
  body.minimal .barra { padding: .55rem .6rem; }
  .salir { padding: .3rem .55rem; }
}
/* Alertas: si no hay ninguna, no se muestra la tabla vacía */
#p-alertas .tabla-caja:has(tbody:empty) { display: none; }
/* Resumen del día: lo esencial; lo demás plegado */
.r-mas { margin-top: .6rem; }
.r-mas > summary { cursor: pointer; color: var(--azul); font-size: .88rem; }
.r-mas > div { white-space: pre-wrap; margin-top: .5rem; color: #4a5664; font-size: .9rem; line-height: 1.55; }

/* ===== 2026-09-28: entrada con Google, espacio de usuarios y pantalla «Usuarios» ===== */
.google-caja { display: flex; justify-content: center; min-height: 44px; margin: 1.2rem 0 .4rem; }
.con-contrasena { margin-top: 1.2rem; border-top: 1px solid var(--linea); padding-top: .8rem; }
.con-contrasena > summary { cursor: pointer; color: var(--suave); font-size: .85rem; }
.con-contrasena[hidden] { display: none; }

.es-contenido { max-width: 1100px; margin: 0 auto; padding: 1.6rem 1.6rem 2rem; }
.es-espera { background: #fff; border: 1px solid var(--linea); border-radius: 14px; padding: 2.4rem 1.6rem; text-align: center; max-width: 520px; margin: 3rem auto; }
.es-espera h1 { font-size: 1.4rem; margin: .4rem 0 .8rem; }
.es-espera p { color: #4a5664; line-height: 1.55; }
.es-icono { font-size: 2.4rem; }
.es-titulo { font-size: 1.5rem; font-weight: 650; margin: 0 0 .3rem; }
.es-sub { color: var(--suave); margin: 0 0 1.2rem; line-height: 1.5; }
.es-rejilla { display: grid; grid-template-columns: 300px 1fr; gap: 1.2rem; align-items: start; }
.es-objetivos { background: #fff; border: 1px solid var(--linea); border-radius: 14px; padding: 1rem 1.1rem; position: sticky; top: 1rem; }
.es-objetivos summary { cursor: pointer; font-size: 1rem; display: flex; justify-content: space-between; gap: .6rem; list-style: none; }
.es-objetivos summary::-webkit-details-marker { display: none; }
.es-avance { color: var(--suave); font-size: .85rem; font-weight: 400; }
.es-objetivos .p-barra { margin: .7rem 0 .4rem; }
.es-lista { list-style: none; padding: 0; margin: .4rem 0 0; }
.es-lista li { display: flex; gap: .6rem; align-items: flex-start; padding: .42rem 0; border-bottom: 1px solid #f1f3f6; font-size: .92rem; line-height: 1.35; }
.es-lista li:last-child { border-bottom: 0; }
.es-lista li.es-logrado { color: #1e7b3c; }
.es-punto { flex: none; width: .75rem; height: .75rem; border-radius: 50%; margin-top: .25rem; background: #cfd6de; display: inline-block; }
.es-punto.es-en_progreso { background: #f0b429; }
.es-punto.es-logrado { background: #2e9d52; box-shadow: 0 0 0 3px #d9f2e1; }
.es-leyenda { font-size: .75rem; color: var(--suave); margin: .8rem 0 0; display: flex; gap: .35rem; align-items: center; flex-wrap: wrap; }
.es-leyenda .es-punto { margin: 0 0 0 .4rem; width: .6rem; height: .6rem; box-shadow: none; }
.es-leyenda .es-punto:first-child { margin-left: 0; }
.es-chat { background: #fff; border: 1px solid var(--linea); border-radius: 14px; display: flex; flex-direction: column; min-height: 60vh; }
.es-mensajes { flex: 1; overflow-y: auto; padding: 1.1rem; display: flex; flex-direction: column; gap: .7rem; max-height: 65vh; }
.es-msg { max-width: 82%; padding: .7rem .95rem; border-radius: 14px; line-height: 1.5; font-size: .95rem; overflow-wrap: anywhere; }
.es-msg.ia { background: #f1f4f8; align-self: flex-start; border-bottom-left-radius: 4px; }
.es-msg.yo { background: var(--azul); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }
.es-msg.sistema { background: #fff6e0; color: #6b4e00; align-self: center; font-size: .85rem; }
.es-hora { display: block; font-size: .7rem; opacity: .6; margin-top: .3rem; text-align: right; }
.es-msg.pensando { display: flex; gap: .3rem; padding: .85rem 1rem; }
.es-msg.pensando span { width: .45rem; height: .45rem; border-radius: 50%; background: #9aa5b1; animation: es-salto 1.2s infinite; }
.es-msg.pensando span:nth-child(2) { animation-delay: .2s; } .es-msg.pensando span:nth-child(3) { animation-delay: .4s; }
@keyframes es-salto { 0%, 60%, 100% { transform: translateY(0); opacity: .5; } 30% { transform: translateY(-4px); opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .es-msg.pensando span { animation: none; } }
.es-form { display: flex; gap: .6rem; padding: .8rem; border-top: 1px solid var(--linea); }
.es-form textarea { flex: 1; resize: none; border: 1px solid var(--linea); border-radius: 10px; padding: .6rem .7rem; font: inherit; font-size: 16px; }
.es-form textarea:focus { outline: 2px solid #c7d8f3; border-color: var(--azul); }
.es-form button { background: var(--azul); color: #fff; border: 0; border-radius: 10px; padding: 0 1.1rem; font-weight: 600; font-size: .95rem; }
.es-form button:disabled { opacity: .5; }
.es-chat > .mensaje { margin: 0 .9rem .6rem; }
@media (max-width: 760px) {
  .es-contenido { padding: 1rem 1rem 1.2rem; }
  .es-titulo { font-size: 1.25rem; }
  .es-rejilla { grid-template-columns: 1fr; gap: .8rem; }
  .es-objetivos { position: static; padding: .8rem .9rem; }
  .es-chat { min-height: 0; }
  .es-mensajes { max-height: 58vh; min-height: 45vh; padding: .8rem; }
  .es-msg { max-width: 90%; }
}

/* Copia de pruebas (2026-09-28): franja amarilla fija para no confundirla con la página en vivo */
.franja-pruebas { position: sticky; top: 0; z-index: 50; background: #ffd84d; color: #3d3000; text-align: center;
  font-weight: 700; font-size: .85rem; padding: .35rem .8rem; letter-spacing: .02em; }

/* Avisos al celular (2026-09-28) */
.av-caja { background: #fff; border: 1px solid var(--linea); border-radius: 12px; padding: 1rem 1.2rem; margin-bottom: 1rem; }
.av-caja ol { margin: .5rem 0 0; padding-left: 1.3rem; line-height: 1.7; }
.av-estado { margin: 0 0 .8rem; font-size: 1rem; }
.av-botones { display: flex; gap: .6rem; flex-wrap: wrap; }
.av-si { background: var(--azul); color: #fff; border: 0; border-radius: 10px; padding: .7rem 1.1rem; font-weight: 600; font-size: 1rem; cursor: pointer; }
.av-lista { list-style: none; padding: 0; margin: 0 0 1.2rem; }
.av-lista li { background: #fff; border: 1px solid var(--linea); border-radius: 10px; padding: .6rem .9rem; margin-bottom: .45rem; }
.av-cuerpo { color: #4a5664; font-size: .9rem; }

.api-llave { display: block; word-break: break-all; background: #f1f4f8; padding: .6rem .8rem; border-radius: 8px; font-size: .95rem; margin: .5rem 0; }
#api-llaves li button { margin-top: .4rem; }

/* Espacios de aclaraciones (2026-09-28): pruebas por punto, fotos, «Lo revisa David» */
.es-punto.es-escalado { background: #e8710a; }
.es-lista li.es-escalado { color: #a24d00; }
.es-lista li.es-con-pruebas { display: block; padding: 0; }
.es-lista li.es-con-pruebas summary { display: flex; gap: .6rem; align-items: flex-start; padding: .42rem 0; cursor: pointer; list-style: none; }
.es-lista li.es-con-pruebas summary::-webkit-details-marker { display: none; }
.es-est { display: block; font-size: .72rem; color: var(--suave); }
.es-pruebas { background: #f6f8fb; border-radius: 8px; padding: .6rem .75rem; margin: 0 0 .6rem 1.35rem; font-size: .85rem; color: #34404d; }
.es-pruebas ul { margin: .4rem 0 0; padding-left: 1.1rem; }
.es-pruebas li { display: list-item !important; border: 0 !important; padding: .15rem 0 !important; }
.es-clip { display: flex; align-items: center; justify-content: center; font-size: 1.3rem; cursor: pointer; padding: 0 .3rem; }
.es-clip[hidden] { display: none; }
.es-foto { max-width: 220px; max-height: 260px; border-radius: 10px; display: block; }

/* Pantalla «Lespago» (2026-09-28) */
.lp-h2 { font-size: 1.15rem; margin: 1.8rem 0 .4rem; }
.lp-volver { color: var(--azul); text-decoration: none; font-size: .9rem; }
.lp-gris td { color: #8a95a3; }
.lp-comp { display: inline-block; background: #f1f4f8; border-radius: 6px; padding: 0 .35rem; margin: .1rem 0; }
.lp-chips { display: inline-flex; gap: .3rem; margin-left: .4rem; }
.lp-chips .chip { cursor: pointer; }
.lp-chips .chip.activo { background: var(--azul); color: #fff; border-color: var(--azul); }
.lp-dos { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1rem; }
@media (max-width: 760px) { .lp-dos { grid-template-columns: 1fr; } }
.es-lp-link { display: inline-block; margin: 0 0 1rem; background: var(--azul); color: #fff; text-decoration: none; border-radius: 10px; padding: .5rem .9rem; font-weight: 600; }

/* Uso del panel (2026-09-29): 40 min al día */
.us-uso { margin-top: .5rem; }
.us-uso-t { font-size: .85rem; color: #34404d; }
.us-datos .us-uso-t b { display: inline; }
/* 29/09: «Inventario y pedido» */
.inv.es-contenido { max-width: 1280px; }
.inv-controles { display: flex; flex-wrap: wrap; gap: .8rem 1.2rem; background: #fff; border: 1px solid var(--linea); border-radius: 12px; padding: 1rem 1.1rem; margin: 1rem 0 1.4rem; }
.inv-controles label { display: flex; flex-direction: column; gap: .25rem; font-size: .8rem; color: var(--suave); }
.inv-controles select, .inv-controles input[type=search] { font: inherit; font-size: .92rem; padding: .4rem .5rem; border: 1px solid #cfd8dc; border-radius: 8px; color: var(--tinta); background: #fff; }
.inv-controles .inv-check { flex-direction: row; align-items: center; gap: .4rem; align-self: flex-end; }
.inv-barras { display: flex; align-items: flex-end; gap: .35rem; height: 160px; background: #fff; border: 1px solid var(--linea); border-radius: 12px; padding: .8rem; overflow-x: auto; }
.inv-bar { flex: 1 0 34px; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; font-size: .72rem; color: var(--suave); }
.inv-bar i { display: block; width: 70%; background: var(--azul); border-radius: 4px 4px 0 0; }
.inv-bar-n { font-weight: 700; color: var(--tinta); }
.inv-mini { display: inline-flex; align-items: flex-end; gap: 2px; height: 20px; }
.inv-mini i { display: block; width: 4px; background: #9bb8e3; border-radius: 1px; }
.inv-tabla tr.inv-rojo { background: #fdecea; }
.inv-tabla tr.inv-amarillo { background: #fff8e6; }
.inv-tabla tr.inv-gris td { color: #8a95a3; }
.inv-cant { width: 4.2rem; font: inherit; text-align: right; padding: .2rem .3rem; border: 1px solid #cfd8dc; border-radius: 6px; }
.inv-nota { display: inline-block; font-size: .7rem; background: #eef1f4; color: #52606d; border-radius: 4px; padding: 0 .35rem; font-weight: 400; }
/* 30/09: versión del equipo (debe ser NOM) */
.inv-nom { color: #256b32; font-size: .7rem; }
.inv-nonom { color: #b42318; font-size: .7rem; }
.inv-conf { color: #a15c07; font-size: .7rem; }
/* 30/09: «Balance de mercancía» */
.inv-ok { color: #1f7a44; }
#bm-indicador p { margin: .35rem 0; }
/* 30/09: ganancia por sucursal (PayJoy) */
tr.pj-sub td { background: #f4f7fb; }
tr.pj-total td { background: #e8f0fb; font-weight: 600; }
.inv-sube { color: #1f7a44; font-size: .75rem; } .inv-baja { color: var(--rojo); font-size: .75rem; }
.inv-det > td { background: #f7f9fc; }
.inv-det-caja { padding: .3rem .2rem .6rem; }
.inv-det-caja .tabla { min-width: 0; font-size: .82rem; background: #fff; }
.inv-leyenda { display: inline-flex; flex-wrap: wrap; align-items: center; gap: .3rem .5rem; margin-left: .3rem; font-size: .8rem; }
.inv-l { display: inline-block; width: .8rem; height: .8rem; border-radius: 3px; border: 1px solid #e0e4e8; }
.inv-l.rojo { background: #fdecea; } .inv-l.amarillo { background: #fff8e6; } .inv-l.gris { background: #eef1f4; }
.inv-acciones { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin: .8rem 0; }
.inv-acciones input { font: inherit; padding: .4rem .6rem; border: 1px solid #cfd8dc; border-radius: 8px; min-width: 14rem; }
.inv-acciones button { font: inherit; padding: .45rem .9rem; border-radius: 8px; border: 1px solid #cfd8dc; background: #fff; cursor: pointer; }
.inv-acciones button.si { background: #1f6f4a; color: #fff; border-color: #1f6f4a; }
.inv-g { background: #fff; border: 1px solid var(--linea); border-radius: 10px; padding: .6rem .9rem; margin-bottom: .5rem; }
.inv-g summary { cursor: pointer; }
@media (max-width: 760px) { .inv-controles label { flex: 1 1 45%; } }
/* 29/09: «Proveedores» */
.pr-tarjetas { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .8rem; }
.pr-tarjeta { background: #fff; border: 1px solid var(--linea); border-radius: 12px; padding: .8rem 1rem; font-size: .88rem; }
.pr-tarjeta b { display: block; font-size: 1rem; }
.pr-tarjeta ul { margin: .4rem 0 0; padding-left: 1rem; color: #3b4652; }
.pr-tabla td.pr-mejor { background: #e3f4e6; font-weight: 700; }
.pr-tabla td.pr-agotado { color: #8a95a3; }
.pr-tabla td.pr-vacio { color: #c3cad2; }
.pr-mejor-l { background: #e3f4e6; border-radius: 4px; padding: 0 .3rem; }
.pr-filtro { display: inline-flex; align-items: center; gap: .4rem; margin-left: .6rem; font-size: .85rem; }
.pr-filtro input { font: inherit; padding: .3rem .5rem; border: 1px solid #cfd8dc; border-radius: 8px; }
.pr-eventos { list-style: none; padding: 0; margin: 0; background: #fff; border: 1px solid var(--linea); border-radius: 12px; }
.pr-eventos li { padding: .5rem .9rem; border-bottom: 1px solid #eef1f4; font-size: .88rem; }
.pr-fecha { display: inline-block; min-width: 3.2rem; color: var(--suave); font-variant-numeric: tabular-nums; }
.pr-hist { columns: 3 220px; margin: .4rem 0 0; font-size: .82rem; }   /* 29/09: «Hoy: 42 de 40 min» en un solo renglón */
.us-hilos { display: flex; flex-wrap: wrap; gap: .4rem; margin: .2rem 0 .8rem; }
.us-hilos button { font-size: .85rem; padding: .3rem .7rem; border-radius: 999px; border: 1px solid #cfd8dc; background: #fff; cursor: pointer; }
.us-hilos button.activo { background: #1f6f4a; color: #fff; border-color: #1f6f4a; }
.us-hallazgos { margin-top: 1rem; font-size: .85rem; }
.us-hallazgos h4 { margin: 0 0 .4rem; font-size: .9rem; }
.us-hallazgos li { margin-bottom: .35rem; }
.us-hallazgos .us-tipo { display: inline-block; font-size: .72rem; padding: 0 .4rem; border-radius: 4px; background: #eef1ef; margin-right: .3rem; }
.us-uso .p-barra { margin: .3rem 0; max-width: 320px; }
.p-relleno.us-ok { background: #2e9d52; }
.us-semana { display: flex; gap: .25rem; }
.us-dia { font-size: .7rem; width: 1.6rem; text-align: center; border-radius: 4px; padding: .1rem 0; background: #eef1f5; color: #8a95a3; }
.us-dia.poco { background: #fff1d6; color: #8a5a00; }
.us-dia.ok { background: #dff3e6; color: #1e7b3c; }

/* Construir mi espacio (2026-09-29) */
.es-hilos { display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: 1rem; }
.es-hilos .chip { text-decoration: none; }
.es-hilos .chip.activo { background: var(--azul); color: #fff; border-color: var(--azul); }
.cn-paso p { margin: .4rem 0 .6rem; }
.cn-ir { padding: .25rem .6rem; margin: .3rem 0 0; font-size: .85rem; }

/* Pantalla «Usuarios» del dueño */
.franja-usuarios { display: block; background: #1f5fbf; color: #fff; padding: .6rem 1.6rem; text-decoration: none; font-size: .9rem; }
.franja-usuarios[hidden] { display: none; }
.us-lista { display: grid; gap: .8rem; }
.us-tarjeta { background: #fff; border: 1px solid var(--linea); border-radius: 12px; padding: 1rem 1.2rem; display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; }
.us-tarjeta img, .us-tarjeta .us-sinfoto { width: 44px; height: 44px; border-radius: 50%; background: #e3e8ef; flex: none; object-fit: cover; }
.us-datos { flex: 1; min-width: 200px; }
.us-datos b { display: block; }
.us-datos .hora { display: block; }
.us-estado { font-size: .78rem; padding: .15rem .55rem; border-radius: 999px; background: #eef1f5; color: #4a5664; margin-left: .4rem; }
.us-estado.pendiente { background: #fff1d6; color: #8a5a00; }
.us-estado.autorizado { background: #dff3e6; color: #1e7b3c; }
.us-estado.rechazado { background: #fde3e1; color: #a32a20; }
.us-acciones { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.us-acciones select { padding: .4rem; border-radius: 8px; border: 1px solid var(--linea); }
.us-acciones button { border-radius: 8px; padding: .45rem .8rem; border: 1px solid var(--linea); background: #fff; font-weight: 600; cursor: pointer; }
.us-acciones button.si { background: #2e9d52; border-color: #2e9d52; color: #fff; }
.us-acciones button.no { color: var(--rojo); }
.us-chat { margin-top: 1.2rem; }
.us-chat .es-rejilla { grid-template-columns: minmax(0, 1fr); }
.us-chat .es-objetivos { position: static; }
.us-chat .es-chat { min-height: 0; }
.us-chat .es-lista li { flex-wrap: wrap; }
.us-chat .es-resumen { flex-basis: 100%; margin-left: 1.35rem; color: #4a5664; font-size: .82rem; }
@media (max-width: 760px) { .us-chat .es-rejilla { grid-template-columns: 1fr; } }

/* ---------- Casos por explicar (01/10/2026) ---------- */
.cs-mios { max-width: 820px; margin: 0 auto 1.4rem; }
.cs-h { font-size: 1.15rem; margin: .4rem 0 .3rem; display: flex; align-items: center; gap: .5rem; }
.cs-h .contador { position: static; }
.cs-ayuda { color: var(--suave); font-size: .9rem; margin: 0 0 .8rem; line-height: 1.45; }
.cs-tarjeta { margin-bottom: .9rem; }
.cs-tarjeta.cs-hecha { background: #fbfcfd; }
.cs-nota { background: #eef5fc; color: #0b3d75; border-radius: 8px; padding: .5rem .7rem; margin: .5rem 0; font-size: .92rem; }
.cs-nota.devuelto { background: #fff3e0; color: #6b3a00; }
.cs-quienes { margin: .6rem 0 0; display: flex; flex-wrap: wrap; gap: .4rem; }
.cs-persona { font-size: .8rem; padding: .15rem .55rem; border-radius: 999px; background: #eef2f6; color: var(--suave); }
.cs-persona.ok { background: #e3f4ea; color: #11734b; font-weight: 600; }
.cs-fotos { display: flex; flex-wrap: wrap; gap: .45rem; margin: .5rem 0; }
.cs-fotos img { width: 84px; height: 84px; object-fit: cover; border-radius: 8px; border: 1px solid var(--linea); display: block; }
.cs-foto { position: relative; }
.cs-foto button { position: absolute; top: -6px; right: -6px; width: 22px; height: 22px; border-radius: 50%; border: 0;
  background: var(--rojo); color: #fff; font-size: .7rem; cursor: pointer; line-height: 22px; padding: 0; }
.cs-adjuntar { display: inline-flex; align-items: center; }
.cs-mia, .cs-resp { background: #fff; border: 1px solid var(--linea); border-radius: 10px; padding: .6rem .8rem; margin: .5rem 0; }
.cs-mia p, .cs-resp p { margin: .3rem 0; white-space: pre-wrap; line-height: 1.45; }
.cs-resp-cab { display: flex; gap: .5rem; align-items: baseline; }
.cs-sub { font-size: .95rem; margin: .9rem 0 .2rem; }
.cs-estado { color: var(--suave); font-size: .88rem; margin: .5rem 0 0; }
.cs-antes { margin: .5rem 0; font-size: .9rem; }
.cs-antes > summary { cursor: pointer; color: var(--azul); }
.cs-aprobados { margin-top: .4rem; color: var(--suave); font-size: .9rem; }
.cs-aprobados > summary { cursor: pointer; }
.cs-mandar { background: #f6f9fc; border: 1px solid var(--linea); border-radius: 10px; padding: .7rem .9rem; margin-top: .8rem; }
.cs-mandar p { margin: 0 0 .4rem; }
.cs-elegir { display: flex; flex-wrap: wrap; gap: .9rem; margin: .3rem 0 .5rem; }
.rv-b.rv-mandar { border-color: #9cc3ef; color: #0b5cad; }
@media (max-width: 700px) { .cs-fotos img { width: 72px; height: 72px; } .cs-mios { margin-bottom: 1rem; } }

/* Casos, segunda parte (01/10): opinión de cada quien, revisora (Victoria) y nuevo caso */
.cs-cab { display: flex; align-items: center; justify-content: space-between; gap: .6rem; flex-wrap: wrap; }
.cs-de { font-size: .8rem; color: var(--suave); }
.cs-ver { font-size: .8rem; font-weight: 600; padding: .1rem .5rem; border-radius: 999px; }
.cs-ver.ok { background: #e3f4ea; color: #11734b; }
.cs-ver.mal { background: #fdecea; color: #b3261e; }
.cs-persona.rev { background: #eef5fc; color: #0b5cad; font-weight: 600; }
.cs-veredicto { display: flex; flex-wrap: wrap; gap: .4rem 1rem; align-items: center; margin: .6rem 0 .2rem; font-size: .92rem; }
.cs-veredicto > span { font-weight: 600; color: var(--tinta); }
.cs-rev { border-color: #9cc3ef; background: #f4f9ff; }
.cs-nuevo { background: #fff; border: 1px solid var(--linea); border-radius: 12px; padding: .8rem 1rem; margin: .6rem 0; }
.cs-in { width: 100%; font: inherit; border: 1px solid #cbd2d9; border-radius: 8px; padding: .45rem .5rem; box-sizing: border-box; margin: .25rem 0 .5rem; }
.cs-nuevo textarea { width: 100%; font: inherit; border: 1px solid #cbd2d9; border-radius: 8px; padding: .5rem; box-sizing: border-box; }
.cs-dos { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.cs-foto-n { font-size: .85rem; background: #eef2f6; border-radius: 6px; padding: .2rem .5rem; }
.cs-mandar textarea { width: 100%; font: inherit; border: 1px solid #cbd2d9; border-radius: 8px; padding: .5rem; box-sizing: border-box; }
@media (max-width: 700px) { .cs-dos { grid-template-columns: 1fr; } }

/* 01/10 (David): la pregunta de David a la persona, muy llamativa */
.cs-pregunta { background: #fff4cc; border: 2px solid #f0b400; border-left-width: 8px; border-radius: 12px; padding: .8rem 1rem; margin: 0 0 .8rem; }
.cs-pregunta-t { display: block; font-weight: 800; font-size: 1.05rem; color: #7a4f00; margin-bottom: .25rem; }
.cs-pregunta p { margin: 0; font-size: 1.15rem; font-weight: 600; color: #2b2100; line-height: 1.45; white-space: pre-wrap; }
.cs-pregunta.devuelto { background: #ffe9e0; border-color: #e0663a; }
.cs-pregunta.devuelto .cs-pregunta-t { color: #8a2c0a; }
.cs-con-pregunta { border-color: #f0b400; box-shadow: 0 0 0 3px #fff1c2; }
.cs-contexto { font-size: .8rem; color: var(--suave); margin: 0 0 .3rem; text-transform: uppercase; letter-spacing: .03em; }
.cs-tu-pregunta-l { display: block; font-weight: 700; color: #7a4f00; margin-bottom: .3rem; }
.cs-mandar textarea.cs-tu-pregunta { background: #fffaf0; border: 2px solid #f0b400; font-size: 1rem; }

/* «En qué trabaja David» (01/10) */
.pv-detalle { white-space: pre-wrap; line-height: 1.45; margin: .4rem 0; }

/* «Libro del negocio» (01/10) */
.lb-areas { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: .6rem; margin: .8rem 0 1rem; }
.lb-area { text-align: left; background: #fff; border: 1px solid var(--linea); border-radius: 12px; padding: .6rem .8rem; cursor: pointer; font: inherit; }
.lb-area.activo { border-color: var(--azul); box-shadow: 0 0 0 2px #dbe7fb; }
.lb-area-t { display: block; font-weight: 600; font-size: .92rem; }
.lb-area-n { display: block; font-size: .78rem; color: var(--suave); margin-top: .2rem; }
.lb-barra { display: block; height: 6px; background: #eef2f6; border-radius: 3px; margin-top: .4rem; overflow: hidden; }
.lb-barra i { display: block; height: 100%; background: #2f7d4f; }
.lb-cap { max-width: 900px; }
.lb-resumen { line-height: 1.55; font-size: 1rem; }
.lb-lista { margin: .2rem 0 .8rem; padding-left: 1.2rem; line-height: 1.5; }
.lb-de { color: var(--suave); font-size: .88rem; }

/* 01/10: «🧮 Asistente de administración»: sin lista de objetivos, el chat a todo lo ancho */
.es-rejilla.es-solo-chat { grid-template-columns: minmax(0, 1fr); }


/* ---------- 02/10 (David): espacio más ordenado: Inicio · Casos plegados · Plática ---------- */
.es-inicio { margin-bottom: 1.4rem; }
.es-hola { font-size: 1.6rem; margin: .2rem 0 0; }
.es-fecha { color: var(--gris, #5b6475); margin: .1rem 0 .8rem; text-transform: capitalize; }
.es-h2 { font-size: 1.05rem; margin: 1.2rem 0 .6rem; color: inherit; }
.es-hoy { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: .7rem; }
.es-card { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: .8rem; align-items: center;
  text-decoration: none; color: inherit; background: #fff; border: 1px solid #e3e7ee; border-radius: 14px; padding: .9rem 1rem;
  box-shadow: 0 1px 3px rgba(16, 24, 40, .06); }
.es-card:hover { box-shadow: 0 4px 14px rgba(16, 24, 40, .12); }
.es-card .es-card-n { grid-row: 1 / 3; font-size: 1.7rem; font-weight: 800; min-width: 2.6rem; text-align: center; }
.es-card small { color: #5b6475; }
.es-card.rojo { border-left: 6px solid #d92d20; } .es-card.rojo .es-card-n { color: #d92d20; }
.es-card.naranja { border-left: 6px solid #f79009; } .es-card.naranja .es-card-n { color: #c46a00; }
.es-card.verde { border-left: 6px solid #12b76a; } .es-card.verde .es-card-n { color: #12b76a; }
.es-card.azul { border-left: 6px solid #1f5fbf; }
.es-herr { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: .6rem; }
.es-tool { display: flex; flex-direction: column; gap: .15rem; text-decoration: none; color: inherit; background: #fff;
  border: 1px solid #e3e7ee; border-radius: 12px; padding: .75rem .85rem; }
.es-tool[hidden] { display: none; }
.es-tool span { font-size: 1.4rem; } .es-tool small { color: #5b6475; font-size: 12px; }
.es-tool:hover { border-color: #1f5fbf; }
.es-tool.alerta { border-color: #d92d20; background: #fff5f4; }
.cs-mios { margin-bottom: 1.4rem; }
.cs-plegable { padding: 0 !important; overflow: hidden; }
.cs-fila { all: unset; box-sizing: border-box; display: flex; gap: .7rem; align-items: center; width: 100%; padding: .7rem .9rem; cursor: pointer; }
.cs-fila:hover { background: #f6f8fb; }
.cs-fila.pregunta { background: #fff8db; }
.cs-fila-g { font-size: 1.1rem; }
.cs-fila-t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.cs-fila-t b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-fila-t small { color: #5b6475; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cs-fila-a { color: #1f5fbf; font-weight: 600; font-size: 13px; white-space: nowrap; }
.cs-cuerpo { padding: 0 1rem 1rem; border-top: 1px solid #eef1f5; }
.cs-plegable.abierta .cs-fila-a { opacity: .6; }
.cs-plegable + .cs-plegable { margin-top: .4rem; }
.es-bloque-platica { border-top: 1px solid #e3e7ee; padding-top: .4rem; }
body.es-en-hilo #cs-mios, body.es-en-hilo #es-inicio { display: none !important; }
body.es-en-hilo .es-bloque-platica { border-top: 0; }
@media (max-width: 560px) { .es-hoy { grid-template-columns: 1fr; } .es-herr { grid-template-columns: 1fr 1fr; } .es-hola { font-size: 1.35rem; } }

.cs-mios { max-width: none; }
.cs-ver-mas { margin-top: .6rem; }
