/* Maileq Carnes — Al Fuego. Paleta de marca: bordó, blanco, negro, naranja. */

:root {
  --brand: #D71920;
  --brand-dark: #B3141A;
  --brand-light: #FDECEC;
  --accent: #D71920;
  --accent-dark: #B3141A;
  --accent-light: #FDECEC;
  --bg: #F5F5F5;
  --surface: #FFFFFF;
  --border: #E6E6E6;
  --border-soft: #E6E6E6;
  --text: #1A1A1A;
  --muted: #666666;
  --muted-dark: #444444;
  --success: #1E7A3A;
  --success-bg: #E4F3E8;
  --warning: #B26A00;
  --warning-bg: #FFF0D6;
  --danger: #D71920;
  --danger-bg: #FDECEC;
  --danger-border: #F5B5B8;
  --highlight-bg: #FDECEC;
  --highlight-bg-2: #F0F0F0;
  --chart-blue: #111111;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 1px 8px rgba(0, 0, 0, 0.05);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

.layout { display: flex; min-height: 100vh; }

.sidebar {
  width: 226px;
  background: var(--surface);
  border-right: 1px solid var(--border-soft);
  padding: 22px 14px;
  flex-shrink: 0;
}

.sidebar .brand {
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -0.01em;
  margin: 0 0 24px;
  padding: 4px 10px;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}
.sidebar .brand::before {
  content: "";
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

.nav-group-title {
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  font-weight: 700;
  padding: 16px 10px 6px;
}
.nav-group-title:first-of-type { padding-top: 0; }

/* Bloques de navegación plegables -- cada bloque es un <details> nativo,
   así se abre/cierra sin JS. El bloque que contiene la página activa
   arranca abierto (atributo "open" puesto desde Python). */
.nav-block { margin-bottom: 6px; }
.nav-block summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: var(--border-soft);
  color: var(--muted-dark);
  transition: background 0.12s ease, color 0.12s ease;
}
.nav-block summary::-webkit-details-marker { display: none; }
.nav-block summary::after {
  content: "›";
  font-size: 15px;
  font-weight: 400;
  color: inherit;
  transition: transform 0.15s ease;
}
.nav-block[open] > summary::after { transform: rotate(90deg); }
.nav-block summary:hover { background: var(--brand-light); color: var(--brand); }
.nav-block-title.active-block { background: var(--brand); color: #fff; }
.nav-block-title.active-block:hover { background: var(--brand-dark); color: #fff; }
.nav-block-links { display: flex; flex-direction: column; padding: 2px 0 8px 2px; }

.sidebar a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  color: #3A322C;
  text-decoration: none;
  font-size: 13.5px;
  margin-bottom: 1px;
  border-left: 3px solid transparent;
  transition: background 0.12s ease;
}
.sidebar a:hover { background: var(--brand-light); color: var(--brand); }
.sidebar a.active {
  background: var(--brand-light);
  font-weight: 600;
  color: var(--brand);
  border-left: 3px solid var(--brand);
}

.badge {
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 1px 7px;
  border-radius: 10px;
}

.content { flex: 1; padding: 32px 40px 60px; max-width: 1600px; }

h1 {
  font-size: 23px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 6px;
  color: var(--text);
}
h2 {
  font-size: 16px;
  font-weight: 700;
  margin: 30px 0 12px;
  color: var(--text);
  letter-spacing: -0.005em;
}

.muted { color: var(--muted); font-size: 13px; }

.flash {
  background: var(--success-bg);
  border: 1px solid #C9E0B4;
  color: #2C5423;
  padding: 11px 16px;
  border-radius: var(--radius-sm);
  margin-bottom: 18px;
  font-size: 14px;
}

.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 18px 0 28px; }
.card {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 16px 18px;
  box-shadow: var(--shadow);
}
.card .label { font-size: 12px; color: var(--muted); margin-bottom: 6px; font-weight: 500; }
.card .value { font-size: 24px; font-weight: 700; letter-spacing: -0.01em; }

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
th, td {
  text-align: center; padding: 11px 14px; font-size: 13.5px;
  /* fila horizontal: linea fina gris clara; columna vertical: linea ancha
     blanca -- mismo criterio que la tabla "Resumen Gastro", aplicado a
     TODAS las tablas de la app (ver th:last-child/td:last-child abajo para
     no dejar el borde colgando contra el borde propio de la tabla). */
  border-bottom: 1px solid var(--border-soft);
  border-right: 4px solid #fff;
}
th:last-child, td:last-child { border-right: none; }
/* Encabezados de tabla en bordó de marca (igual que el pill activo del nav
   y la tabla "Resumen Gastro") -- estética unificada en toda la app, ver
   nota en el bloque .cards de más abajo para las tarjetas a juego. */
th { color: #fff; font-weight: 600; font-size: 11.5px; text-transform: uppercase; letter-spacing: 0.04em; background: var(--brand); }
/* Encabezados vacíos (columnas de solo-acciones, ej. "Vistas guardadas")
   no llevan el relleno bordó -- si no, quedan como bloques de color sin
   texto, se ven como un glitch en vez de una columna de botones. */
th:empty { background: transparent; }
tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: #FDFBF9; }
.section-row td { background: var(--brand-light); font-weight: 700; color: var(--brand); }
/* .right queda centrado a proposito -- el usuario pidio que TODO en las
   tablas este centrado, incluidas las columnas numericas que antes se
   alineaban a la derecha con esta clase. Se deja el nombre de la clase
   (se sigue usando en cientos de lugares) pero ya no alinea a la derecha. */
.right { text-align: center; }
.center { text-align: center; }

.tag { font-size: 11px; padding: 2px 9px; border-radius: 8px; font-weight: 600; }
.tag-up { background: var(--accent-light); color: var(--accent-dark); }
.tag-down { background: var(--success-bg); color: var(--success); }
.tag-same { background: var(--border-soft); color: var(--muted-dark); }
.tag-new { background: var(--brand-light); color: var(--brand); }

form.inline { display: inline; }

button, .btn {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 8px 15px;
  font-size: 13.5px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  color: var(--text);
  display: inline-block;
  transition: background 0.12s ease, border-color 0.12s ease;
}
button:hover, .btn:hover { background: var(--brand-light); border-color: #DDBEC4; }
.btn-primary { background: var(--brand); color: #fff; border-color: var(--brand); font-weight: 600; }
.btn-primary:hover { background: var(--brand-dark); border-color: var(--brand-dark); }

select, input[type=number], input[type=text], input[type=date] {
  padding: 7px 10px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  background: var(--surface);
  color: var(--text);
}
select:focus, input:focus { outline: 2px solid var(--brand-light); border-color: var(--brand); }

.file-row {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--surface); border: 1px solid var(--border-soft);
  border-radius: var(--radius); padding: 14px 16px; margin-bottom: 8px;
  box-shadow: var(--shadow);
}
.pending-card {
  background: var(--surface); border: 1px solid var(--border-soft);
  border-radius: var(--radius); padding: 16px; margin-bottom: 10px;
  box-shadow: var(--shadow);
}
.pending-card form { display: flex; gap: 8px; align-items: center; margin-top: 10px; flex-wrap: wrap; }

.pick-section { margin-bottom: 16px; }
.pick-section-title {
  font-weight: 700; font-size: 12.5px; text-transform: uppercase; letter-spacing: 0.03em;
  background: var(--brand-light); color: var(--brand);
  padding: 7px 11px; border-radius: var(--radius-sm); margin-bottom: 4px;
}
.check-row { display: flex; align-items: center; gap: 10px; padding: 7px 10px; font-size: 13px; }
.check-row span:nth-child(2) { flex: 1; }
.qty-row { display: flex; align-items: center; gap: 10px; padding: 7px 10px; font-size: 13px; }
.pct-input { width: 60px; }
.qty-name { flex: 1; }
.day-sep td { border-top: 2px solid var(--border); }
.pago-parcial-form { display: flex; align-items: center; gap: 4px; margin: 0; }
.pago-parcial-form input[type=number] { width: 90px; }

/* Pastillas seleccionables (campos de filtro/agrupamiento tipo UBIAR) --
   sin JS: el estado visual (tildado / panel que aparece) se resuelve
   solo con CSS, usando el checkbox oculto + selectores :checked. */
.pill-group { display: flex; flex-wrap: wrap; gap: 6px 8px; margin: 8px 0 16px; align-items: flex-start; }
.pill-item { display: inline-flex; align-items: center; }
.pill-check { display: none; }
.pill-label {
  display: inline-block; padding: 6px 13px; border-radius: 14px;
  background: var(--border-soft); color: var(--muted-dark); font-size: 12.5px;
  font-weight: 500; cursor: pointer; user-select: none; white-space: nowrap;
  transition: background .12s ease, color .12s ease;
}
.pill-label:hover { background: var(--brand-light); color: var(--brand); }
.pill-check:checked + .pill-label { background: var(--brand); color: #fff; font-weight: 600; }
.pill-check.con-panel:checked + .pill-label { border-radius: 14px 0 0 14px; }
.pill-panel {
  display: none; align-items: center; gap: 6px; background: var(--brand-light);
  border: 1px solid var(--brand); border-left: none; border-radius: 0 14px 14px 0;
  padding: 4px 10px 4px 6px;
}
.pill-check.con-panel:checked ~ .pill-panel { display: inline-flex; }
.pill-panel-chk {
  font-size: 11px; color: var(--brand); font-weight: 600; white-space: nowrap;
  display: inline-flex; align-items: center; gap: 3px; cursor: pointer;
}
.pill-panel-input { width: 100px; font-size: 12px; padding: 4px 8px; border: 1px solid var(--border); border-radius: 6px; }

/* Panel de checklist de valores (tipo UBIAR): buscador + lista de
   checkboxes scrolleable, todos tildados por defecto. El buscador usa un
   poco de JS (ver script al pie de la página) para esconder/mostrar
   ítems -- es la única parte de esta pantalla que necesita JS, porque
   filtrar texto dentro de una lista larga no se puede hacer solo con CSS. */
.pill-panel-checklist { flex-direction: column; align-items: stretch; padding: 8px; gap: 6px; min-width: 190px; }
.valores-buscador { display: flex; gap: 4px; align-items: center; }
.valores-buscar { flex: 1; font-size: 12px; padding: 4px 8px; border: 1px solid var(--border); border-radius: 6px; }
.valores-todos, .valores-ninguno {
  font-size: 10.5px; padding: 3px 7px; border-radius: 6px; border: 1px solid var(--brand);
  background: #fff; color: var(--brand); cursor: pointer; white-space: nowrap;
}
.valores-todos:hover, .valores-ninguno:hover { background: var(--brand); color: #fff; }
.valores-lista { max-height: 190px; overflow-y: auto; background: #fff; border-radius: 6px; padding: 2px 4px; }
.valor-item {
  display: flex; align-items: center; gap: 6px; font-size: 12px; padding: 3px 4px;
  border-radius: 4px; cursor: pointer; white-space: nowrap;
}
.valor-item:hover { background: var(--brand-light); }
.valor-item input { flex-shrink: 0; }
.valor-item span { overflow: hidden; text-overflow: ellipsis; }
.valores-vacio { font-size: 11.5px; color: var(--muted); padding: 4px; }

/* Bloque "Filas del reporte" (Ventas UBIAR) -- dos columnas con chips
   arrastrables (drag & drop nativo HTML5) para armar el desglose del
   pivot en el orden elegido, al estilo de la Estadística de Ventas de
   UBIAR. Ver _pivot_filas_builder en views.py. */
.pivot-builder { margin: 10px 0 18px; }
.dnd-columns { display: flex; gap: 14px; flex-wrap: wrap; }
.dnd-col { flex: 1 1 240px; min-width: 220px; }
.dnd-col-title { font-size: 11px; color: var(--muted); margin-bottom: 4px; text-transform: uppercase; letter-spacing: .02em; }
.dnd-zone {
  display: flex; flex-wrap: wrap; align-content: flex-start; gap: 6px; min-height: 46px;
  background: var(--surface); border: 1px dashed var(--border); border-radius: var(--radius-sm);
  padding: 8px;
}
.dnd-zone-filas { border-color: var(--brand); background: var(--brand-light); }
.dnd-chip {
  display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 500;
  background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 4px 6px 4px 10px;
  cursor: grab; user-select: none; box-shadow: var(--shadow);
}
.dnd-zone-filas .dnd-chip { border-color: var(--brand); }
.dnd-chip:active { cursor: grabbing; }
.dnd-chip.dnd-dragging { opacity: .35; }
.dnd-chip-x {
  display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px;
  border-radius: 50%; color: var(--muted); font-size: 13px; line-height: 1;
}
.dnd-chip:hover .dnd-chip-x { background: var(--danger-bg); color: var(--danger); }

/* Bloque colapsable "Locales, filas y filtros" (Ventas UBIAR) -- una vez
   consultado se cierra solo para que los resultados no arranquen a mitad
   de pantalla; fecha/vistas/Consultar quedan afuera, siempre visibles. */
.config-consulta { border: 1px solid var(--border-soft); border-radius: var(--radius-sm); padding: 10px 12px; margin-bottom: 14px; }
.config-consulta summary { cursor: pointer; font-size: 13px; font-weight: 600; list-style: none; }
.config-consulta summary::-webkit-details-marker { display: none; }
.config-consulta summary::before { content: "▸ "; color: var(--muted); }
.config-consulta[open] summary::before { content: "▾ "; }

/* Pool de campos truncado en altura (solo visual, no cambia el DOM) con
   un botón para expandirlo -- evita que la lista larga de ~40 campos
   ocupe media pantalla por defecto. */
.dnd-zone-truncada { max-height: 92px; overflow: hidden; }
.dnd-zone-toggle {
  margin-top: 6px; font-size: 11.5px; color: var(--brand); background: none; border: none;
  cursor: pointer; padding: 2px 0; text-decoration: underline;
}

/* Chip de "Filtros" (Ventas UBIAR) -- igual que un dnd-chip pero con un
   popup adentro (oculto hasta que se toca la etiqueta), calcado del
   filtro de columna de UBIAR (título, buscador, "(Todos)", checklist,
   Ok/Cancelar). Ver _dnd_filtro_chip / _pivot_filtros_builder. */
.filtro-chip { position: relative; cursor: pointer; }
#dnd-filtros-pool .filtro-chip .dnd-chip-x { display: none; }
.filtro-chip.filtro-chip-activo { border-color: var(--brand); }
/* Pista visual de que un chip ya activo se puede tocar para abrir su
   filtro de valores (el área clickeable es todo el chip, ver JS). */
.dnd-zone-filas .filtro-chip .dnd-chip-label::after { content: " ▾"; color: var(--muted); font-weight: 400; }
.filtro-popup {
  display: none; position: absolute; top: calc(100% + 6px); left: 0; z-index: 40;
  width: 240px; background: #fff; border: 1px solid var(--border); border-radius: 10px;
  box-shadow: 0 4px 18px rgba(30, 24, 21, .14); padding: 10px; cursor: default;
  flex-direction: column; gap: 6px;
}
.filtro-popup.is-open { display: flex; }
.filtro-popup-titulo { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 2px; }
.filtro-popup-modo {
  font-size: 12px; color: var(--muted-dark); border: 1px solid var(--border); border-radius: 6px;
  padding: 4px 8px; background: var(--border-soft);
}
.filtro-popup .valores-buscador { position: relative; }
.filtro-popup .valores-buscar { width: 100%; padding-right: 22px; }
.valores-buscar-x {
  position: absolute; right: 4px; top: 50%; transform: translateY(-50%); border: none; background: none;
  color: var(--muted); font-size: 13px; cursor: pointer; line-height: 1; padding: 2px 4px;
}
.valor-todos { border-bottom: 1px solid var(--border-soft); padding-bottom: 6px; font-weight: 600; }
.filtro-popup-footer { display: flex; justify-content: flex-end; gap: 6px; margin-top: 4px; }
.filtro-popup-footer button {
  font-size: 12px; padding: 5px 12px; border-radius: 6px; border: 1px solid var(--border); background: #fff;
  cursor: pointer;
}
.filtro-popup-ok { background: var(--brand) !important; color: #fff !important; border-color: var(--brand) !important; }
.filtro-popup-cancelar:hover { background: var(--border-soft); }

/* Fila de "etiquetas" de totales (Ventas UBIAR) -- cada métrica en su
   propio recuadro con más aire entre ellas, en vez de un grid apretado. */
.stat-row { display: flex; flex-wrap: wrap; gap: 22px; margin: 16px 0 10px; }
.stat-chip {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 14px 22px; box-shadow: var(--shadow); min-width: 150px;
}
.stat-chip-label { font-size: 11.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .02em; margin-bottom: 6px; }
.stat-chip-value { font-size: 22px; font-weight: 700; color: var(--text); }
.stat-chip-brand { border-color: var(--brand); background: var(--brand-light); }
.stat-chip-brand .stat-chip-value { color: var(--brand-dark); }
.stat-chip-accent { border-color: var(--accent); }
.stat-chip-accent .stat-chip-value { color: var(--accent-dark); }

/* Versión chica de las mismas "etiquetas", para cada fila del desglose
   (Parque España / Nordelta / etc., ver _render_arbol_ventas). */
.nodo-summary { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; font-size: 15px; }
.nodo-valor { font-weight: 700; margin-right: 2px; font-size: 15.5px; }
.stat-chip-mini {
  display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 600;
  background: #fff; border: 1px solid var(--border); border-radius: 999px; padding: 4px 12px 4px 11px;
  white-space: nowrap;
}
.stat-chip-mini-label { color: var(--muted); font-weight: 500; }
.stat-chip-mini-brand { border-color: var(--brand); background: var(--brand-light); color: var(--brand-dark); }
.stat-chip-mini-brand .stat-chip-mini-label { color: var(--brand-dark); opacity: .75; }
.stat-chip-mini-accent { border-color: var(--accent); background: var(--accent-light); color: var(--accent-dark); }
.stat-chip-mini-accent .stat-chip-mini-label { color: var(--accent-dark); opacity: .75; }

/* Resumen de Locales/Filas/Filtros activos -- siempre visible arriba de
   los totales, aunque el bloque colapsable esté cerrado (ver
   _resumen_activo_html). */
.resumen-activo { display: flex; flex-wrap: wrap; gap: 8px; margin: 2px 0 16px; }
.resumen-chip {
  font-size: 12px; font-weight: 600; padding: 4px 11px; border-radius: 999px;
  background: var(--border-soft); color: var(--muted-dark);
}
.resumen-chip-filas { background: var(--brand-light); color: var(--brand-dark); }
.resumen-chip-filtro { background: var(--accent-light); color: var(--accent-dark); }
.resumen-chip-btn { border: none; font-family: inherit; cursor: pointer; position: relative; }
.resumen-chip-btn:hover { filter: brightness(0.96); }
.resumen-chip-btn:active { filter: brightness(0.9); }
.resumen-popup-backdrop { position: fixed; inset: 0; background: rgba(31, 22, 18, .28); z-index: 39; }
/* El popup de un filtro abierto desde el resumen (arriba de los totales) no
   se ancla debajo del chip -- ahí no hay lugar y termina pisando las
   tarjetas de totales o la fila de resultados. En cambio se muestra como
   un mini-diálogo centrado y fijo, arriba de todo (con el fondo oscurecido
   de .resumen-popup-backdrop atrás), así nunca choca con lo de abajo. */
.filtro-popup.resumen-popup-modal {
  position: fixed; top: 90px; left: 50%; transform: translateX(-50%);
  max-height: calc(100vh - 130px); overflow-y: auto;
}


/* ===== PALETA NUEVA (negro / rojo #D71920 / blanco / gris) =====
   Para volver a la paleta anterior: restaurar el backup static/style.css.bak_before_paleta */
.sidebar { background: #111; border-right: none; color: #fff; }
.sidebar .brand { color: #fff; }
.sidebar .brand::before { background: #D71920; }
.nav-group-title { color: #9a9a9a; }
.nav-block summary { background: #222; color: #fff; }
.nav-block summary:hover { background: #333; color: #fff; }
.nav-block-title.active-block { background: #D71920; color: #fff; }
.nav-block-title.active-block:hover { background: #B3141A; color: #fff; }
.sidebar a { color: #e8e8e8; }
.sidebar a:hover { background: #222; color: #fff; }
.sidebar a.active { background: #D71920; color: #fff; border-left-color: #D71920; }
.badge { background: #D71920; color: #fff; }
th { background: #111; color: #fff; }
th:empty { background: transparent; }
tbody tr:hover td { background: #FAFAFA; }
.section-row td { background: #F0F0F0; color: #111; }
button:hover, .btn:hover { background: #FDECEC; border-color: #F5B5B8; }
.btn-primary, button.btn-primary { background: #D71920; color: #fff; border-color: #D71920; }
.btn-primary:hover, button.btn-primary:hover { background: #B3141A; border-color: #B3141A; color: #fff; }
form[action$="/pagar/marcar"] .btn, form[action$="/deudas/marcar"] .btn, form[action$="/cobrar/marcar"] .btn { background: #D71920; color: #fff; border-color: #D71920; font-weight: 600; }
form[action$="/pagar/marcar"] .btn:hover, form[action$="/deudas/marcar"] .btn:hover, form[action$="/cobrar/marcar"] .btn:hover { background: #B3141A; border-color: #B3141A; }
tr[style*="FDECEC"] td:first-child { box-shadow: inset 3px 0 0 #D71920; }
.card { border-color: #E6E6E6; }

/* componentes nuevos (tarjetas de indicadores y grficos aditivos) */
.pv2-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin: 14px 0 16px; }
.pv2-kpi { background: #fff; border: 1px solid #E6E6E6; border-radius: 12px; padding: 16px 18px; }
.pv2-kpi small { display: block; color: #666; font-size: 11.5px; letter-spacing: .05em; text-transform: uppercase; }
.pv2-kpi .v { font-size: 26px; font-weight: 800; margin: 6px 0 4px; color: #1A1A1A; }
.pv2-kpi .s { font-size: 12px; color: #666; }
.pv2-kpi.big { background: #7E0F17; border-color: #7E0F17; }
.pv2-kpi.big small, .pv2-kpi.big .s { color: #F0C9CC; }
.pv2-kpi.big .v { color: #fff; font-size: 32px; }
.pv2-kpi.neg .v { color: #D71920; }
.pv2-kpi.pos .v { color: #1E7A3A; }
.pv2-card { background: #fff; border: 1px solid #E6E6E6; border-radius: 12px; padding: 16px 20px; margin: 0 0 16px; }
.pv2-card h3 { margin: 0 0 8px; font-size: 15px; }
.pv2-clasica { font-size: 11.5px; margin: 0 0 8px; text-align: right; }
.pv2-clasica a { color: #666; }

.pv2-cards { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.pv2-cards .card:first-child { background: #7E0F17; border-color: #7E0F17; }
.pv2-cards .card:first-child .label, .pv2-cards .card:first-child .muted { color: #F0C9CC; }
.pv2-cards .card:first-child .value { color: #fff; }
tr[style*="accent-light"] td:first-child { box-shadow: inset 3px 0 0 #D71920; }

.pv2-kpi .v { font-size: clamp(19px, 2.1vw, 26px); }
.pv2-kpi.big .v { font-size: clamp(21px, 2.5vw, 30px); }

/* ===== SIDEBAR v2 (solo presentacion) ===== */
.layout { display: flex; align-items: flex-start; min-height: 100vh; }
.layout > .content { flex: 1 1 auto; min-width: 0; align-self: stretch; }
.sidebar {
  --sb-w: 264px; --sb-red: #E3131B; --sb-bg: #111111; --sb-line: #2a2a2a;
  position: sticky; top: 0; align-self: flex-start;
  flex: 0 0 var(--sb-w); width: var(--sb-w); min-width: 0;
  height: 100vh; max-height: 100vh; box-sizing: border-box;
  overflow-x: hidden; overflow-y: auto;
  display: flex; flex-direction: column;
  background: var(--sb-bg) !important; background-image: none !important;
  color: #fff; border: 0; border-right: 1px solid #1e1e1e;
  padding: 0 0 16px; box-shadow: none;
  scrollbar-width: thin; scrollbar-color: #3a3a3a transparent;
}
.sidebar > * { flex: 0 0 auto; }
html.sb-ready .sidebar { transition: width .18s ease, flex-basis .18s ease; }
.sidebar .brand {
  display: flex; align-items: center; gap: 10px;
  padding: 16px 14px 14px 16px; margin: 0 0 10px;
  background: none; color: #fff; font-size: 16px; font-weight: 600;
  letter-spacing: 0; text-transform: none; line-height: 1.2;
  border: 0; border-bottom: 1px solid var(--sb-line); position: relative;
}
.sidebar .brand::before, .sidebar .brand::after { display: none !important; content: none !important; }
.sidebar .brand img { width: 34px; height: 34px; flex: 0 0 34px; display: block; border-radius: 0; }
.sidebar .brand .bt { flex: 1 1 auto; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #fff; }
.sidebar .sb-toggle {
  flex: 0 0 auto; margin-left: auto; width: 28px; height: 28px; padding: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: transparent; color: #b5b5b5; border: 0; border-radius: 6px; cursor: pointer;
}
.sidebar .sb-toggle:hover { background: #222; color: #fff; border: 0; }
.sidebar .sb-toggle:focus-visible, .sidebar summary:focus-visible, .sidebar a:focus-visible { outline: 2px solid #fff; outline-offset: -2px; }
.sidebar .nav-block { margin: 0 10px 2px; padding: 0; border: 0; background: none; }
.sidebar details.nav-block > summary {
  display: flex; align-items: center; gap: 12px; box-sizing: border-box;
  min-height: 38px; padding: 9px 12px; border-radius: 8px;
  list-style: none; cursor: pointer; user-select: none;
  background: transparent; color: #e6e6e6;
  font-size: 14px; font-weight: 500; line-height: 20px; letter-spacing: 0; text-transform: none;
}
.sidebar details.nav-block > summary::-webkit-details-marker { display: none; }
.sidebar details.nav-block > summary::marker { content: ""; }
.sidebar details.nav-block > summary:hover { background: #1d1d1d; color: #fff; }
.sidebar details.nav-block[open] > summary,
.sidebar details.nav-block[open] > summary.active-block { background: var(--sb-red); color: #fff; }
.sidebar details.nav-block[open] > summary:hover { background: #cf1119; color: #fff; }
.sidebar details.nav-block > summary .ni { display: inline-flex; flex: 0 0 18px; width: 18px; height: 18px; }
.sidebar details.nav-block > summary .ni svg { width: 18px; height: 18px; display: block; }
.sidebar details.nav-block > summary .nl { flex: 1 1 auto; min-width: 0; }
.sidebar details.nav-block > summary::after {
  content: ""; display: block; flex: 0 0 auto; margin-left: auto;
  width: 7px; height: 7px; background: none; position: static;
  border-right: 1.8px solid currentColor; border-bottom: 1.8px solid currentColor;
  transform: rotate(-45deg); opacity: .7; transition: transform .15s ease;
}
.sidebar details.nav-block[open] > summary::after { transform: rotate(45deg); opacity: 1; margin-top: -3px; }
.sidebar .nav-block-links {
  display: flex; flex-direction: column; margin: 4px 0 8px 21px; padding: 2px 0;
  border-left: 1px solid #333;
}
.sidebar .nav-block-links a {
  position: relative; display: flex; align-items: center; justify-content: space-between; gap: 8px;
  margin: 1px 0; padding: 7px 10px 7px 16px; border: 0; border-radius: 0 6px 6px 0;
  background: transparent; color: #b8b8b8; text-decoration: none;
  font-size: 13.5px; font-weight: 400; line-height: 18px;
}
.sidebar .nav-block-links a:hover { background: #1d1d1d; color: #fff; }
.sidebar .nav-block-links a.active { background: #2c2c2c; color: #fff; font-weight: 500; border: 0; }
.sidebar .nav-block-links a.active:hover { background: #333; }
.sidebar .nav-block-links a.active::before {
  content: ""; position: absolute; left: -1px; top: 3px; bottom: 3px; width: 3px; border-radius: 2px; background: var(--sb-red);
}
.sidebar .nav-block-links > div { color: #cfcfcf !important; font-size: 12px !important; font-weight: 500 !important; padding: 4px 10px 6px 16px !important; }
.sidebar .badge { background: var(--sb-red); color: #fff; border-radius: 10px; padding: 0 7px; font-size: 11px; line-height: 17px; font-weight: 600; }
.sb-tip {
  position: fixed; z-index: 9999; transform: translateY(-50%); pointer-events: none;
  background: #111; color: #fff; border: 1px solid #3a3a3a; border-radius: 6px;
  padding: 6px 10px; font-size: 12.5px; line-height: 1.2; white-space: nowrap;
  opacity: 0; visibility: hidden; transition: opacity .1s ease;
}
.sb-tip.on { opacity: 1; visibility: visible; }
/* modo compacto: solo iconos */
html.sb-compact .sidebar { --sb-w: 64px; }
html.sb-compact .sidebar .brand { flex-direction: column; justify-content: center; gap: 8px; padding: 14px 0 12px; }
html.sb-compact .sidebar .brand .bt { display: none; }
html.sb-compact .sidebar .brand .sb-toggle { margin: 0; }
html.sb-compact .sidebar .nav-block { margin: 0 11px 4px; }
html.sb-compact .sidebar details.nav-block > summary { justify-content: center; padding: 9px 0; gap: 0; }
html.sb-compact .sidebar details.nav-block > summary .nl,
html.sb-compact .sidebar details.nav-block > summary::after { display: none; }
html.sb-compact .sidebar .nav-block-links { display: none; }
html.sb-compact .sidebar details.nav-block[open] > summary { background: transparent; color: #e6e6e6; }
html.sb-compact .sidebar details.nav-block[open] > summary:hover { background: #1d1d1d; color: #fff; }
html.sb-compact .sidebar details.nav-block > summary.active-block,
html.sb-compact .sidebar details.nav-block[open] > summary.active-block { background: var(--sb-red); color: #fff; }
html.sb-compact .sidebar details.nav-block:has(a.active) > summary { background: var(--sb-red); color: #fff; }
@media (max-width: 899px) { .layout > .content { padding-left: 16px; padding-right: 16px; } }
@media print { .sidebar, .sb-tip { display: none !important; } }
/* ===== /SIDEBAR v2 ===== */
.sidebar .brand { position: sticky; top: 0; z-index: 3; background: #111111; }

/* ===== SIDEBAR logo v3: solo escudo ===== */
.sidebar .brand { position: sticky; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0; padding: 16px 10px; border-bottom: 1px solid #2a2a2a; }
.sidebar .brand img { width: 150px; height: 150px; flex: 0 0 150px; max-width: 100%; object-fit: contain; image-rendering: auto; margin: 0 auto; }
.sidebar .brand .sb-toggle { position: absolute; top: 6px; right: 6px; width: 26px; height: 26px; margin: 0; z-index: 2; }
html.sb-compact .sidebar .brand { padding: 16px 0; gap: 8px; }
html.sb-compact .sidebar .brand img { width: 56px; height: 56px; flex: 0 0 56px; }
html.sb-compact .sidebar .brand .sb-toggle { position: static; width: 26px; height: 26px; margin: 0; }

/* ===== Pedido carnico (pc-*) -- usa las variables y el estilo de tablas/botones/avisos de la app ===== */
.pc-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: 12px 0 8px; }
.pc-bar form { margin: 0; display: inline-flex; align-items: center; gap: 8px; }
.pc-bar label { font-size: 13px; font-weight: 600; color: var(--muted-dark); }
.pc-bar select { min-width: 270px; max-width: 100%; }
.pc-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 14px 0 14px; }
.pc-tabs a.btn.on { background: var(--accent); color: #fff; border-color: var(--accent); font-weight: 600; }
.pc-tabs a.btn.on:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.pc-flash { background: var(--success-bg); border: 1px solid #C9E0B4; color: #2C5423; padding: 10px 16px; border-radius: var(--radius-sm); margin: 10px 0 14px; font-size: 13.5px; }
.pc-warn { background: var(--warning-bg); border: 1px solid #EBCB8B; color: #7A4A00; padding: 10px 16px; border-radius: var(--radius-sm); margin: 10px 0 12px; font-size: 13.5px; }
.pc-err { background: var(--danger-bg); border: 1px solid var(--danger-border); color: #8A1015; padding: 10px 16px; border-radius: var(--radius-sm); margin: 10px 0 12px; font-size: 13.5px; }
.pc-note { color: var(--muted); font-size: 12.5px; margin: 6px 0 10px; line-height: 1.45; }
.pc-info { background: var(--surface); border: 1px solid var(--border-soft); border-left: 3px solid var(--brand); border-radius: var(--radius-sm); padding: 9px 14px; font-size: 12.5px; color: var(--muted-dark); margin: 0 0 12px; line-height: 1.45; }
.pc-actions { display: flex; align-items: center; gap: 12px; margin: 0 0 10px; flex-wrap: wrap; }
.pc-actions .pc-note { margin: 0; }
.pc-toast { position: fixed; right: 24px; top: 18px; z-index: 90; max-width: 420px; box-shadow: var(--shadow); font-weight: 600; }
.pc-toast[hidden] { display: none; }
.pc-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 8px; }
.pc-chip { font-size: 12px; padding: 4px 11px; border-radius: 999px; background: var(--border-soft); color: var(--muted-dark); }
.pc-chip-ok { background: var(--success-bg); color: var(--success); }
.pc-chip-sug { background: var(--warning-bg); color: var(--warning); }

table.pc { table-layout: fixed; min-width: 1020px; overflow: visible; border-radius: 0; box-shadow: none; font-size: 12.5px; }
table.pc th, table.pc td { padding: 5px 4px; font-size: 12.5px; border-right: 2px solid #fff; border-bottom: 1px solid #EEEEEE; text-align: center; vertical-align: middle; overflow-wrap: anywhere; }
table.pc th:last-child, table.pc td:last-child { border-right: none; }
table.pc thead th { position: sticky; top: 0; z-index: 5; padding: 7px 3px; font-size: 10px; letter-spacing: 0; line-height: 1.2; background: #111; color: #fff; }
table.pc thead th small { display: block; font-size: 9.5px; font-weight: 500; opacity: 0.8; text-transform: none; letter-spacing: 0; }
table.pc thead th.pc-main { background: var(--brand); }
table.pc th.pc-l, table.pc td.pc-l { text-align: left; padding-left: 8px; }
table.pc tbody tr:nth-child(even) td { background: #FAFAFA; }
table.pc tbody tr:hover td { background: #F3F3F3; }
table.pc tbody tr.pc-q td { background: #FEF3F3; }
table.pc tbody tr.pc-q:hover td { background: #FCE8E8; }
table.pc tbody tr.pc-q td:first-child { box-shadow: inset 3px 0 0 var(--accent); }
table.pc tbody tr.pc-sugrow td { background: #FFFAEE; }
table.pc tbody tr.pc-na td { color: var(--muted); }
table.pc tbody tr td.pc-main { background: var(--brand-light); color: var(--accent-dark); font-size: 14px; }
table.pc tbody tr.pc-sec td { background: #F0F0F0; color: #111; font-weight: 700; font-size: 11.5px; letter-spacing: 0.04em; text-transform: uppercase; text-align: left; padding: 6px 10px; box-shadow: inset 3px 0 0 var(--brand); }
table.pc td.pc-ubc { padding: 4px 5px; }
table.pc td.pc-est { padding: 4px 3px; }
.pc-cod { font-weight: 600; font-size: 11.5px; white-space: nowrap; }
.pc-dash { color: #BBB; }
.pc-pos { font-weight: 800; }
.pc-zero { font-weight: 500; color: var(--muted); }
input.pc-in { width: 58px; padding: 3px 2px; text-align: center; font-size: 12.5px; border-radius: 6px; }

.pc-pill { display: inline-block; padding: 2px 8px; border-radius: 10px; font-size: 10.5px; font-weight: 600; line-height: 1.35; margin: 1px 0; }
.pc-p-ok { background: var(--success-bg); color: var(--success); }
.pc-p-q { background: var(--danger-bg); color: var(--brand-dark); border: 1px solid var(--danger-border); font-weight: 700; }
.pc-p-sug { background: #FFE2A8; color: #7A4A00; }
.pc-p-rev { background: var(--warning-bg); color: var(--warning); border: 1px solid #EBCB8B; }
.pc-p-na { background: var(--border-soft); color: var(--muted-dark); }

.pc-ub { display: flex; flex-direction: column; align-items: stretch; gap: 3px; }
.pc-ub.pc-busy { opacity: 0.5; pointer-events: none; }
button.pc-ub-btn { position: relative; display: block; width: 100%; padding: 3px 16px 3px 6px; font-size: 12px; font-weight: 500; line-height: 1.25; text-align: center; background: #fff; border: 1px solid var(--border); border-radius: 6px; color: var(--text); }
button.pc-ub-btn:hover { background: var(--brand-light); border-color: #DDBEC4; }
.pc-ub[data-estado="sugerido"] button.pc-ub-btn { background: #FFF8E6; border-color: #E8B64F; }
.pc-caret { position: absolute; right: 5px; top: 50%; transform: translateY(-50%); font-size: 9px; color: var(--muted); }
.pc-ub-name { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pc-ub-none { color: var(--muted); font-style: italic; }
.pc-ub-sub { display: flex; align-items: center; justify-content: center; gap: 4px; flex-wrap: wrap; }
.pc-ub-code { font-size: 10.5px; color: var(--muted); }
.pc-eb { font-size: 10px; font-weight: 700; padding: 1px 7px; border-radius: 999px; white-space: nowrap; }
.pc-eb-auto { background: var(--success-bg); color: var(--success); }
.pc-eb-sug { background: #FFE2A8; color: #7A4A00; border: 1px solid #E8B64F; }
.pc-eb-ver { background: var(--success); color: #fff; }
.pc-eb-none { background: var(--border-soft); color: var(--muted-dark); }
button.pc-confirm { padding: 1px 8px; font-size: 10.5px; font-weight: 700; border-radius: 999px; background: var(--success); color: #fff; border: 1px solid var(--success); }
button.pc-confirm:hover { background: #17612E; border-color: #17612E; }

.pc-pop { position: absolute; z-index: 80; width: 340px; max-height: 370px; display: flex; flex-direction: column; gap: 6px; background: #fff; border: 1px solid var(--border); border-radius: 10px; box-shadow: 0 4px 18px rgba(0, 0, 0, 0.18); padding: 8px; }
.pc-pop[hidden] { display: none; }
.pc-pop-q { width: 100%; }
.pc-pop-list { position: relative; overflow-y: auto; max-height: 300px; }
.pc-opt { display: flex; justify-content: space-between; gap: 8px; padding: 5px 8px; border-radius: 6px; cursor: pointer; font-size: 12.5px; text-align: left; }
.pc-opt:hover { background: var(--brand-light); }
.pc-opt.on { background: var(--brand-light); font-weight: 700; color: var(--brand-dark); }
.pc-opt-c { color: var(--muted); font-size: 11px; white-space: nowrap; }
.pc-opt-none { border-bottom: 1px solid var(--border-soft); font-weight: 600; }
.pc-opt-reset { color: var(--muted-dark); font-style: italic; }
.pc-opt-more { padding: 6px 8px; font-size: 11.5px; color: var(--muted); }

/* --- pedido carnico: banner de semana, cartel de congelado --- */
.pc-banner { border-radius: var(--radius); padding: 18px 24px; margin: 8px 0 14px; border: 2px solid; box-shadow: var(--shadow); }
.pc-bn-ok { background: var(--success-bg); border-color: var(--success); color: #14532B; }
.pc-bn-warn { background: var(--warning-bg); border-color: var(--warning); color: #6B3F00; }
.pc-bn-tit { font-size: 36px; font-weight: 800; letter-spacing: .5px; line-height: 1.1; }
.pc-bn-sub { font-size: 19px; font-weight: 600; margin-top: 6px; }
.pc-bn-row { font-size: 16px; margin-top: 6px; }
.pc-bn-file { font-size: 13px; margin-top: 8px; opacity: .9; }
.pc-bn-alert { margin-top: 12px; background: var(--danger); color: #fff; font-size: 21px; font-weight: 800; padding: 10px 16px; border-radius: var(--radius-sm); }
.pc-cong { padding: 10px 16px; border-radius: var(--radius-sm); margin: 0 0 12px; font-size: 14px; border: 1px solid; }
.pc-cong b { font-size: 16px; }
.pc-cong span { margin-left: 8px; font-size: 12.5px; }
.pc-cong-vivo { background: var(--success-bg); border-color: var(--success); color: var(--success); }
.pc-cong-frio { background: #E8EEF7; border-color: #7F98C2; color: #1F3A66; }
.pc-semtag { font-size: 17px; font-weight: 700; margin: 4px 0 8px; color: var(--text); }
.pc-lock { display: inline-block; font-weight: 600; font-size: 13px; color: #1F3A66; background: #E8EEF7; border: 1px solid #7F98C2; padding: 6px 12px; border-radius: var(--radius-sm); }

/* ---- Pedido crnico: alarma de equivalencias y pedido editable (fase 3) ---- */
.pc-alarm { border: 2px solid; border-radius: var(--radius-sm); padding: 10px 16px; margin: 10px 0 12px; }
.pc-alarm-rojo { background: #FDECEC; border-color: #C62828; color: #8E1B1B; }
.pc-alarm-amb { background: #FFF4DC; border-color: #E0A100; color: #7A4A00; }
.pc-alarm-tit { font-size: 15px; font-weight: 700; margin-bottom: 4px; }
.pc-alarm-list { margin: 4px 0 8px 18px; padding: 0; font-size: 13px; }
.pc-alarm-list li { margin: 2px 0; }
.pc-alarm-nota { display: block; font-size: 12px; font-weight: 600; }
.pc-alarm-btn { display: inline-block; margin-top: 2px; }
.pc-nuevo { display: inline-block; background: #C62828; color: #fff; font-size: 10px; font-weight: 700; padding: 1px 6px; border-radius: 8px; letter-spacing: .5px; vertical-align: middle; }
.pc-tabcnt { display: inline-block; min-width: 18px; padding: 0 6px; border-radius: 10px; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; color: #fff; margin-left: 2px; }
.pc-tabcnt-red { background: #C62828; }
.pc-tabcnt-amb { background: #E08A00; }
.pc-mp-td { text-align: center; vertical-align: middle; white-space: nowrap; }
.pc-mp-ctl { display: inline-flex; align-items: center; gap: 2px; }
.pc-mp-b, .pc-mp-rs { border: 1px solid #B8C2CC; background: #fff; border-radius: 6px; width: 24px; height: 26px; font-size: 15px; font-weight: 700; line-height: 1; cursor: pointer; padding: 0; }
.pc-mp-b:hover, .pc-mp-rs:hover { background: #E8F0FE; }
.pc-mp-rs { width: 22px; color: #1A57B8; font-size: 14px; margin-left: 2px; }
.pc-mp-n { width: 44px; height: 26px; text-align: center; font-weight: 700; border: 1px solid #B8C2CC; border-radius: 6px; padding: 0 2px; -moz-appearance: textfield; }
.pc-mp-n::-webkit-outer-spin-button, .pc-mp-n::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.pc-mp-tag { font-size: 10px; color: #6B7785; margin-top: 2px; }
.pc-mp-ed { background: #E3EEFF; box-shadow: inset 3px 0 0 #1A57B8; }
.pc-mp-ed .pc-mp-n { border-color: #1A57B8; background: #F3F8FF; }
.pc-mp-pend { opacity: .7; }
.pc-mp-lock .pc-mp-ro { font-weight: 700; }
.pc-mp-info { margin-top: 4px; }
.pc-dr { text-align: center; font-weight: 600; }
.pc-dr-igual { background: #E3F5E8; color: #14532B; }
.pc-dr-difiere { background: #FFE9B8; color: #7A4A00; }
.pc-dr-vacio { background: #ECEFF2; color: #6B7785; }
.pc-foot td { background: #F4F6F8; border-top: 2px solid #B8C2CC; font-size: 12.5px; }
.pc-mp-tot, .pc-dr-tot { text-align: center; font-size: 14px; }
.pc-mp-tot small, .pc-dr-tot small { display: block; font-size: 10px; font-weight: 400; color: #6B7785; }

/* ---- Pedido carnico: columnas por secciones de color (pc-v2) ---- */
table.pc.pc-v2 { min-width: 0; width: 100%; font-size: 12px; }
table.pc.pc-v2 th, table.pc.pc-v2 td { text-align: center; padding: 4px 3px; }
table.pc.pc-v2 th.pc-l, table.pc.pc-v2 td.pc-l { text-align: left; padding-left: 6px; }
table.pc.pc-v2 thead tr.pc-hs th { top: 0; padding: 4px 3px; font-size: 11px; font-weight: 800; letter-spacing: .06em; color: #fff; border-bottom: 2px solid #7A1E2C; }
table.pc.pc-v2 thead tr.pc-hc th { top: 25px; font-size: 10px; line-height: 1.2; }
table.pc.pc-v2 th.cs-first, table.pc.pc-v2 td.cs-first, table.pc.pc-v2 td.pc-mp-td { border-left: 2px solid #7A1E2C; }
table.pc.pc-v2 th.hs-d { background: #111; }
table.pc.pc-v2 th.hs-s { background: #6B7280; }
table.pc.pc-v2 th.hs-p { background: #9A3412; }
table.pc.pc-v2 th.hs-m { background: #000; }
table.pc.pc-v2 thead th.hc-d { background: #fff; color: #111; border-bottom: 2px solid #111; }
table.pc.pc-v2 thead th.hc-s { background: #E5E7EB; color: #111; border-bottom: 2px solid #6B7280; }
table.pc.pc-v2 thead th.hc-s3 { background: #646C7A; color: #fff; border-bottom: 2px solid #6B7280; }
table.pc.pc-v2 thead th.hc-p { background: #FFE2C4; color: #7C2D12; border-bottom: 2px solid #9A3412; }
table.pc.pc-v2 thead th.hc-p3 { background: #DC4C11; color: #fff; border-bottom: 2px solid #9A3412; }
table.pc.pc-v2 thead th.hc-m { background: #222; color: #fff; border-bottom: 2px solid #000; }
table.pc.pc-v2 thead th.hc-m3 { background: #F3F4F6; color: #111; border-bottom: 2px solid #000; }
table.pc.pc-v2 thead th small { font-size: 9px; }
table.pc.pc-v2 tbody tr td.cs-d { background: #fff; color: #111; }
table.pc.pc-v2 tbody tr td.cs-s { background: #ECEDEF; color: #111; }
table.pc.pc-v2 tbody tr td.cs-s3 { background: #646C7A; color: #fff; font-weight: 700; }
table.pc.pc-v2 tbody tr td.cs-p { background: #FFEBD6; color: #3B1A08; }
table.pc.pc-v2 tbody tr td.cs-p3 { background: #DC4C11; color: #fff; font-weight: 800; font-size: 14px; }
table.pc.pc-v2 tbody tr td.cs-p3 b.pc-zero { color: #FFD9BF; }
table.pc.pc-v2 tbody tr td.cs-p3 b.pc-pos { color: #fff; }
table.pc.pc-v2 tbody tr td.pc-sp-q { background: #FBD5D5; color: #B91C1C; font-weight: 800; box-shadow: inset 0 0 0 1px #E58A8A; }
table.pc.pc-v2 .pc-warn-ico { font-size: 12px; }
table.pc.pc-v2 tbody tr.pc-na td.cs-d, table.pc.pc-v2 tbody tr.pc-na td.cs-s, table.pc.pc-v2 tbody tr.pc-na td.cs-p { color: #6B7785; }
table.pc.pc-v2 tbody tr:hover td.cs-d, table.pc.pc-v2 tbody tr:hover td.cs-s, table.pc.pc-v2 tbody tr:hover td.cs-p { filter: brightness(.96); }
table.pc.pc-v2 tbody tr td.pc-mp-td { background: #1F1F1F; color: #fff; }
table.pc.pc-v2 td.pc-mp-td .pc-mp-ro { color: #fff; font-size: 14px; }
table.pc.pc-v2 td.pc-mp-td .pc-mp-tag { color: #CFCFCF; }
table.pc.pc-v2 tbody tr td.pc-mp-ed { background: #2B2B2B; box-shadow: inset 3px 0 0 #6EA8FF; }
table.pc.pc-v2 td.pc-mp-td .pc-mp-n { width: 40px; color: #111; background: #fff; }
table.pc.pc-v2 td.pc-mp-td .pc-mp-b, table.pc.pc-v2 td.pc-mp-td .pc-mp-rs { width: 22px; }
table.pc.pc-v2 td.pc-mp-td .pc-mp-rs { color: #1A57B8; }
table.pc.pc-v2 td.pc-mp-lock { background: #2B2B2B; }
table.pc.pc-v2 td.pc-dr { text-align: center; font-weight: 700; }
table.pc.pc-v2 .pc-ico { display: inline-block; margin-left: 4px; font-size: 12px; cursor: help; vertical-align: middle; }
table.pc.pc-v2 .pc-ico-rev { color: #B45309; }
table.pc.pc-v2 .pc-ico-na { color: #6B7785; }
table.pc.pc-v2 tfoot td.pc-foot-l, table.pc.pc-v2 tfoot td { text-align: center; }
table.pc.pc-v2 tfoot td.pc-l { text-align: left; }
table.pc.pc-v2 tfoot td.pc-kg-tot, table.pc.pc-v2 tfoot td.pc-sg-tot { font-size: 14px; background: #FFEBD6; }
table.pc.pc-v2 tfoot td.pc-sg-tot { background: #DC4C11; color: #fff; }
table.pc.pc-v2 tfoot td.pc-sg-tot small, table.pc.pc-v2 tfoot td.pc-kg-tot small { display: block; font-size: 10px; font-weight: 400; }
table.pc.pc-v2 tfoot td.pc-sg-tot small { color: #FFD9BF; }
table.pc.pc-v2 tfoot td.pc-kg-tot small { color: #7C2D12; }
table.pc.pc-v2 tfoot td.pc-mp-tot { background: #1F1F1F; color: #fff; }
table.pc.pc-v2 tfoot td.pc-mp-tot small { color: #CFCFCF; }
table.pc.pc-v2 input.pc-in { width: 52px; }
table.pc.pc-v2 tfoot td.pc-dr-tot.pc-id-tot { background: #fff; color: #111; }
table.pc.pc-v2 tfoot td.pc-dr-tot.pc-id-tot small { color: #6B7785; }
/* retoques 20261014: Mi pedido compacto, totales de stock en el pie */
table.pc.pc-v2 td.pc-mp-td { position: relative; padding: 4px 1px; }
table.pc.pc-v2 td.pc-mp-td .pc-mp-ctl { display: flex; justify-content: center; gap: 1px; }
table.pc.pc-v2 td.pc-mp-td .pc-mp-b { width: 15px; height: 24px; font-size: 13px; border-radius: 4px; }
table.pc.pc-v2 td.pc-mp-td .pc-mp-n { width: 24px; height: 24px; font-size: 12px; padding: 0; border-radius: 4px; }
table.pc.pc-v2 td.pc-mp-td .pc-mp-rs { position: absolute; top: 1px; right: 1px; width: 11px; height: 11px; margin: 0; font-size: 9px; border-radius: 3px; z-index: 2; }
table.pc.pc-v2 tfoot td.pc-si-tot { background: #ECEDEF; color: #111; font-size: 13px; }
table.pc.pc-v2 tfoot td.pc-sa-tot { background: #646C7A; color: #fff; font-size: 13px; }
table.pc.pc-v2 tfoot td.pc-si-tot small, table.pc.pc-v2 tfoot td.pc-sa-tot small { display: block; font-size: 10px; font-weight: 400; }
table.pc.pc-v2 tfoot td.pc-si-tot small { color: #6B7785; }
table.pc.pc-v2 tfoot td.pc-sa-tot small { color: #E5E7EB; }
table.pc.pc-v2 input.pc-in { width: 100%; max-width: 52px; box-sizing: border-box; padding-left: 2px; padding-right: 2px; }

/* ===== Pedido carnico REDISENO v3 (pc3-*, contenedor .pc-v3root) -- la vista clasica (?vista=clasica) sigue usando pc-v2 ===== */
.pc-v3root .pc3-bn { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; border: 1px solid; border-radius: 8px; padding: 8px 14px; margin: 4px 0 8px; }
.pc3-bn-ok { background: #F3F8F4; border-color: #A9CDB1; color: #14532B; }
.pc3-bn-warn { background: #FFF4DC; border-color: #E0A100; color: #6B3F00; }
.pc3-bn-t { font-size: 19px; font-weight: 800; letter-spacing: .3px; }
.pc3-bn-r { font-size: 14px; font-weight: 700; }
.pc3-bn-i { font-size: 12.5px; }
.pc3-tag { background: #15803D; color: #fff; font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 999px; }
.pc3-bn-warn .pc3-tag { background: #B45309; }
.pc3-bn-f { margin: 0 0 0 auto; }
.pc3-bn-f .btn { padding: 4px 10px; font-size: 12px; }
.pc3-lnk { font-size: 11.5px; color: #666; }
.pc3-bn-alert { flex-basis: 100%; background: #C62828; color: #fff; font-weight: 800; font-size: 14px; padding: 6px 12px; border-radius: 6px; }
.pc3-bn-file { flex-basis: 100%; font-size: 11px; opacity: .75; }
.pc-v3root .pc-bn-row { flex-basis: 100%; font-size: 11.5px; }
.pc-v3root .pc-cong { padding: 5px 12px; margin: 0 0 8px; font-size: 12.5px; }
.pc-v3root .pc-cong b { font-size: 13px; }
.pc-v3root .pc-info { padding: 5px 10px; font-size: 11.5px; margin: 0 0 8px; }
.pc-v3root .pc-tabs { margin: 6px 0 8px; }
.pc3-al { border: 1px solid; border-radius: 6px; margin: 0 0 6px; padding: 4px 12px; font-size: 12.5px; }
.pc3-al-rojo { background: #FDECEC; border-color: #C62828; color: #8E1B1B; }
.pc3-al-amb { background: #FFF4DC; border-color: #E0A100; color: #7A4A00; }
.pc3-al summary { display: flex; align-items: center; gap: 12px; cursor: pointer; list-style: none; }
.pc3-al summary::-webkit-details-marker { display: none; }
.pc3-al-v { font-size: 11px; text-decoration: underline; opacity: .8; }
.pc3-al-b { margin-left: auto; padding: 3px 10px; font-size: 12px; }
.pc3-al ul { margin: 6px 0 4px 18px; padding: 0; }
.pc3-chips { display: flex; flex-wrap: wrap; gap: 6px 8px; margin: 0 0 6px; }
.pc3-ch { background: #F3F4F6; color: #374151; border: 1px solid #E5E7EB; border-radius: 999px; padding: 3px 12px; font-size: 12px; }
.pc3-ch b { font-size: 14px; margin-right: 3px; color: #111827; }
.pc3-ch-or { background: #FFF1E3; border-color: #F6C79B; }
.pc3-ch-or b { color: #9A3412; }
.pc3-ch-bl { background: #EAF1FF; border-color: #BCD0F5; }
.pc3-ch-bl b { color: #1A57B8; }
.pc3-ch-am { background: #FFF4DC; border-color: #EBCB8B; }
.pc3-ch-am b { color: #7A4A00; }
.pc3-ch-rd b { color: #B91C1C; }
.pc3-tools { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; margin: 0 0 8px; }
.pc3-fps, .pc3-act { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; }
.pc3-fp, .pc3-btn { border: 1px solid #D1D5DB; background: #fff; color: #374151; border-radius: 999px; padding: 4px 12px; font-size: 12px; cursor: pointer; font-family: inherit; }
.pc3-btn { border-radius: 6px; padding: 4px 10px; }
.pc3-fp:hover, .pc3-btn:hover { background: #F3F4F6; }
.pc3-fp.on { background: #7A1E2C; border-color: #7A1E2C; color: #fff; font-weight: 600; }
.pc3-save { padding: 4px 10px; font-size: 12px; }
.pc3-lock { margin: 0; padding: 4px 10px; font-size: 12px; }
table.pc3 { width: 100%; table-layout: fixed; border-collapse: separate; border-spacing: 0; font-size: 12.5px; background: #fff; }
table.pc3 thead th { position: sticky; top: 0; z-index: 5; background: #1f2937; color: #fff; font-size: 11.5px; font-weight: 700; line-height: 1.2; padding: 7px 4px; text-align: center; border: 0; }
table.pc3 thead th small { display: block; font-size: 9.5px; font-weight: 400; opacity: .8; }
table.pc3 thead th.pc3-l { text-align: left; padding-left: 8px; }
table.pc3 thead th.pc3-h-sg { background: #9A3412; }
table.pc3 thead th.pc3-h-mi { background: #7A1E2C; }
table.pc3 tbody td { height: 36px; padding: 2px 4px; border-bottom: 1px solid #EEF0F2; text-align: center; vertical-align: middle; background: #fff; color: #374151; }
table.pc3 tbody tr.pc3-r:hover td { background: #FAFAFB; }
table.pc3 td.pc3-t { padding: 0; }
button.pc3-tg { border: 0; background: transparent; cursor: pointer; font-size: 13px; color: #6B7280; padding: 4px 6px; border-radius: 4px; }
button.pc3-tg:hover { background: #E5E7EB; color: #111; }
table.pc3 td.pc3-pn { text-align: left; padding-left: 4px; line-height: 1.25; }
.pc3-cod { display: block; font-size: 10.5px; color: #9CA3AF; }
.pc3-nm { font-size: 12.5px; color: #111827; margin-right: 4px; }
.pc3-b { font-size: 10px; font-weight: 700; padding: 1px 6px; border-radius: 999px; margin-right: 3px; }
.pc3-b-amb { background: #FFF4DC; color: #7A4A00; border: 1px solid #EBCB8B; }
.pc3-sin { font-size: 10px; font-weight: 600; padding: 1px 6px; border-radius: 999px; background: #E3EEFF; color: #1A57B8; }
table.pc3 td.pc3-num { color: #6B7280; }
.pc3-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #DC2626; vertical-align: middle; margin-left: 3px; cursor: help; }
table.pc3 tbody td.pc3-sg { background: #FFF1E3; color: #9A3412; font-size: 15px; font-weight: 800; }
table.pc3 tbody tr.pc3-r:hover td.pc3-sg { background: #FFE8D1; }
table.pc3 td.pc3-sg b.pc-zero { color: #C9A48A; font-weight: 600; }
table.pc3 td.pc3-sg b.pc-pos { color: #9A3412; font-weight: 800; }
table.pc3 td.pc3-mp { white-space: nowrap; }
table.pc3 .pc-mp-ctl { display: inline-flex; align-items: center; gap: 2px; }
table.pc3 .pc-mp-b { width: 22px; height: 24px; font-size: 14px; border-radius: 5px; }
table.pc3 .pc-mp-n { width: 40px; height: 24px; font-size: 13px; }
table.pc3 .pc-mp-rs { width: 20px; height: 24px; margin-left: 1px; visibility: hidden; }
table.pc3 tr.pc3-dif .pc-mp-rs { visibility: visible; }
table.pc3 tbody tr.pc3-dif td { background: #EEF4FF; }
table.pc3 tbody tr.pc3-dif td.pc3-sg { background: #FFF1E3; }
table.pc3 tr.pc3-dif .pc-mp-n { border-color: #1A57B8; background: #fff; }
table.pc3 td.pc3-cmp[data-s="ok"] { color: #111; font-weight: 800; font-size: 14px; }
table.pc3 td.pc3-cmp[data-s="df"] { color: #111; font-weight: 700; }
table.pc3 td.pc3-cmp[data-s="na"] { color: #BBB; }
table.pc3 tr.pc3-na td.pc3-pn .pc3-nm { color: #6B7280; }
table.pc3 tr.pc3-sec td, table.pc3 tr.pc3-gh td { background: #F3F4F6; color: #111; font-weight: 700; font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; text-align: left; padding-left: 10px; height: 26px; }
table.pc3 tr.pc3-gh td { background: #FFF1E3; color: #9A3412; }
table.pc3 tr.pc3-empty td { padding: 18px; color: #6B7280; }
table.pc3 tr.pc3-d td { background: #FAFAFA; padding: 8px 10px; height: auto; text-align: left; border-bottom: 1px solid #E5E7EB; }
.pc3-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px 18px; }
.pc3-g { display: flex; flex-direction: column; gap: 2px; font-size: 12px; min-width: 0; }
.pc3-gl { font-size: 10.5px; font-weight: 700; color: #6B7280; text-transform: uppercase; letter-spacing: .03em; }
.pc3-gv { color: #111827; }
.pc3-g .pc-in { width: 64px; }
.pc3-g .pc-ub { align-items: flex-start; }
.pc3-g button.pc-ub-btn { text-align: left; }
table.pc3 tfoot td { background: #1f2937; color: #fff; text-align: center; padding: 7px 4px; font-weight: 700; font-size: 13px; border: 0; }
table.pc3 tfoot td.pc3-fl { text-align: left; font-size: 12px; font-weight: 600; }
table.pc3 tfoot tr.pc3-f2 td { background: #374151; font-size: 11.5px; font-weight: 400; text-align: left; padding-left: 12px; }
table.pc3 tfoot tr.pc3-f2 span { margin-right: 18px; }
table.pc3 tfoot tr.pc3-f2 b { font-weight: 700; }
.pc-v3root .pc-form { margin: 0; }

.pc-v3root .pc-note { font-size: 11px; margin: 2px 0 6px; line-height: 1.3; }
.pc-v3root .pc-actions { margin: 0 0 4px; }
table.pc3 thead th { overflow-wrap: anywhere; font-size: 11px; }
@media (min-width: 1200px) { table.pc3 thead th { font-size: 11.5px; } }
table.pc3 { overflow: visible; }

/* ===== Pedido carnico v3b: paleta sobria de la app (sidebar #111111 / #2C2C2C, acento rojo #D71920 / #B3141A, tinte #FDECEC) ===== */
.pc3-ch { background: #fff; color: #666; border: 1px solid #D4D4D4; }
.pc3-ch b { color: #1A1A1A; font-weight: 700; }
.pc3-ch.pc3-ch-rd { background: #fff; color: #D71920; border-color: #D71920; }
.pc3-ch.pc3-ch-rd b { color: #D71920; }
.pc3-fp:hover, .pc3-btn:hover { background: #F5F5F5; }
.pc3-fp.on { background: #111111; border-color: #111111; color: #fff; font-weight: 600; }
table.pc3 thead th { background: #111111; color: #fff; border-bottom: 3px solid #111111; }
table.pc3 thead th.pc3-h-sg { background: #111111; border-bottom-color: #F2C7A5; }
table.pc3 thead th.pc3-h-mi { background: #111111; border-bottom-color: #C2540A; }
table.pc3 thead th.pc3-h-cb { background: #111111; }
table.pc3 tbody td { border-bottom: 1px solid #EDEDED; color: #333; }
table.pc3 tbody tr.pc3-r:hover td { background: #FAFAFA; }
.pc3-nm { color: #1A1A1A; }
table.pc3 td.pc3-pn .pc3-nm.pc3-nm-red, table.pc3 tr.pc3-na td.pc3-pn .pc3-nm.pc3-nm-red { color: #D71920; }
.pc3-sin { background: #F0F0F0; color: #444; }
table.pc3 tbody td.pc3-sg { background: #FDF1E6; color: #A8460A; }
table.pc3 tbody tr.pc3-r:hover td.pc3-sg { background: #FBE4D0; }
table.pc3 td.pc3-sg b.pc-pos { color: #A8460A; }
table.pc3 td.pc3-sg b.pc-zero { color: #B9A58F; }
table.pc3 tbody tr.pc3-dif td { background: #F7F7F7; }
table.pc3 tbody tr.pc3-dif td.pc3-sg { background: #FDF1E6; }
table.pc3 tr.pc3-dif .pc-mp-n { border-color: #C2540A; background: #fff; }
table.pc3 td.pc3-cmp[data-s="ok"] { color: #111; font-weight: 600; font-size: 12.5px; }
table.pc3 td.pc3-cmp[data-s="df"] { color: #111; font-weight: 600; font-size: 12.5px; }
table.pc3 td.pc3-cmp[data-s="na"] { color: #A0A0A0; }
table.pc3 tr.pc3-sec td { background: #F0F0F0; color: #1A1A1A; }
table.pc3 tr.pc3-gh td { background: #FDF1E6; color: #A8460A; }
table.pc3 tfoot td { background: #111111; }
table.pc3 tfoot tr.pc3-f2 td { background: #2C2C2C; }
.pc3-tcob { font-weight: 400; opacity: .85; }
table.pc3 td.pc3-cb { white-space: nowrap; }
.pc3-cob-ctl { display: inline-flex; align-items: center; gap: 2px; }
table.pc3 .pc3-cob-n { width: 46px; height: 24px; font-size: 12.5px; text-align: center; padding: 0 2px; border: 1px solid #D4D4D4; border-radius: 5px; background: #fff; color: #1A1A1A; }
table.pc3 .pc3-cob-n.pc3-bad { border-color: #D71920; background: #FDECEC; }
table.pc3 .pc3-cob-rs { width: 20px; height: 24px; padding: 0; font-size: 12px; border-radius: 5px; visibility: hidden; }
table.pc3 td.pc3-cb-lock { color: #6B7280; }

/* ===== Pedido carnico v3c: bandas Resumen / Filtrar / Ordenar, encabezados rojos, cobertura sin marcas ===== */
.pc3-bands { border-top: 1px solid #E3E3E3; margin: 0 0 8px; }
.pc3-band { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; padding: 8px 0; border-bottom: 1px solid #E3E3E3; }
.pc3-bl { flex: 0 0 72px; font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #8A8A8A; }
.pc3-band .pc3-chips, .pc3-band .pc3-fps { margin: 0; flex: 1 1 0; min-width: 0; }
.pc3-seg { display: inline-flex; }
.pc3-so { border: 1px solid #D1D5DB; background: #fff; color: #374151; padding: 4px 14px; font-size: 12px; cursor: pointer; font-family: inherit; }
.pc3-so:first-child { border-radius: 6px 0 0 6px; }
.pc3-so:last-child { border-radius: 0 6px 6px 0; margin-left: -1px; }
.pc3-so:hover { background: #F5F5F5; }
.pc3-so.on, .pc3-so.on:hover { background: #111111; border-color: #111111; color: #fff; font-weight: 600; }
.pc3-band-ord .pc3-act { margin-left: auto; padding-left: 14px; border-left: 1px solid #D4D4D4; }
@media (max-width: 700px) { .pc3-bl { flex-basis: 100%; } .pc3-band-ord .pc3-act { margin-left: 0; padding-left: 0; border-left: 0; } }
table.pc3 thead th.pc3-h-sg, table.pc3 thead th.pc3-h-mi { background: #C2540A; color: #fff; border-bottom-color: #A8460A; }

/* ===== Pedido carnico v3c: bandas Resumen / Filtrar / Ordenar, encabezados rojos, cobertura sin marcas ===== */
.pc3-bands { border-top: 1px solid #E3E3E3; margin: 0 0 8px; }
.pc3-band { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; padding: 8px 0; border-bottom: 1px solid #E3E3E3; }
.pc3-bl { flex: 0 0 72px; font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #8A8A8A; }
.pc3-band .pc3-chips, .pc3-band .pc3-fps { margin: 0; flex: 1 1 0; min-width: 0; }
.pc3-seg { display: inline-flex; }
.pc3-so { border: 1px solid #D1D5DB; background: #fff; color: #374151; padding: 4px 14px; font-size: 12px; cursor: pointer; font-family: inherit; }
.pc3-so:first-child { border-radius: 6px 0 0 6px; }
.pc3-so:last-child { border-radius: 0 6px 6px 0; margin-left: -1px; }
.pc3-so:hover { background: #F5F5F5; }
.pc3-so.on, .pc3-so.on:hover { background: #111111; border-color: #111111; color: #fff; font-weight: 600; }
.pc3-band-ord .pc3-act { margin-left: auto; padding-left: 14px; border-left: 1px solid #D4D4D4; }
@media (max-width: 700px) { .pc3-bl { flex-basis: 100%; } .pc3-band-ord .pc3-act { margin-left: 0; padding-left: 0; border-left: 0; } }
table.pc3 thead th.pc3-h-sg, table.pc3 thead th.pc3-h-mi { background: #C2540A; color: #fff; border-bottom-color: #A8460A; }
/* retoques3: bloque rojo Pedido sugerido + Mi pedido */
table.pc3 thead th.pc3-h-sg { border-top: 2px solid #C2540A; border-left: 2px solid #C2540A; }
table.pc3 thead th.pc3-h-mi { border-top: 2px solid #C2540A; border-right: 2px solid #C2540A; }
table.pc3 tbody td.pc3-sg { background: #fff; border-left: 2px solid #C2540A; border-right: 1px solid #F3CACB; text-align: center; }
table.pc3 tbody td.pc3-mp { border-right: 2px solid #C2540A; text-align: center; position: relative; }
table.pc3 tbody tr.pc3-r:hover td.pc3-sg { background: #FAFAFA; }
table.pc3 tbody tr.pc3-dif td.pc3-sg { background: #F7F7F7; }
table.pc3 tbody tr.pc3-dif:hover td.pc3-sg { background: #FAFAFA; }
table.pc3 td.pc3-mp .pc-mp-ctl { display: inline-flex; justify-content: center; align-items: center; }
table.pc3 td.pc3-mp .pc-mp-rs { position: absolute; right: 1px; top: 50%; margin: 0; transform: translateY(-50%); width: 16px; }
table.pc3 tbody tr.pc3-gh td, table.pc3 tbody tr.pc3-sec td, table.pc3 tbody tr.pc3-empty td { background-origin: border-box; background-image: linear-gradient(to right, transparent 55%, #C2540A 55%, #C2540A calc(55% + 2px), transparent calc(55% + 2px), transparent calc(76% - 2px), #C2540A calc(76% - 2px), #C2540A 76%, transparent 76%); }
table.pc3 tbody tr.pc3-d td:nth-child(2) { background-origin: border-box; background-image: linear-gradient(to right, transparent 53.608%, #C2540A 53.608%, #C2540A calc(53.608% + 2px), transparent calc(53.608% + 2px), transparent calc(75.258% - 2px), #C2540A calc(75.258% - 2px), #C2540A 75.258%, transparent 75.258%); }
table.pc3 tfoot tr.pc3-f1 td:nth-child(6) { border-left: 2px solid #C2540A; text-align: center; }
table.pc3 tfoot tr.pc3-f1 td:nth-child(7) { border-right: 2px solid #C2540A; text-align: center; }
table.pc3 tfoot tr.pc3-f1:last-child td:nth-child(6), table.pc3 tfoot tr.pc3-f1:last-child td:nth-child(7) { border-bottom: 2px solid #C2540A; }
table.pc3 tfoot tr.pc3-f2 td { background-origin: border-box; background-repeat: no-repeat; background-size: 100% 2px, 100% 100%; background-position: 0 100%, 0 0; background-image: linear-gradient(to right, transparent 55%, #C2540A 55%, #C2540A 76%, transparent 76%), linear-gradient(to right, transparent 55%, #C2540A 55%, #C2540A calc(55% + 2px), transparent calc(55% + 2px), transparent calc(76% - 2px), #C2540A calc(76% - 2px), #C2540A 76%, transparent 76%); }
table.pc3 td.pc3-mp .pc-mp-ctl { gap: 1px; }
table.pc3 td.pc3-mp .pc-mp-b { width: 20px; }
table.pc3 td.pc3-mp .pc-mp-n { width: 34px; }
table.pc3 td.pc3-mp .pc-mp-n:focus { border-color: #C2540A; outline: 2px solid rgba(194,84,10,.25); outline-offset: 0; }
table.pc3 td.pc3-cmp[data-s="ok"], table.pc3 td.pc3-cmp[data-s="df"] { color: #111; font-weight: 400; font-size: 13.5px; }
/* retoques5: detalle y Totales previos sin lineas verticales del recuadro */
table.pc3 tbody tr.pc3-d td:nth-child(2) { background-image: none; }
table.pc3 tfoot tr.pc3-f2 td { background-image: linear-gradient(to right, transparent 55%, #C2540A 55%, #C2540A 76%, transparent 76%); }

/* Pedido carnico: pestanas de configuracion apartadas (Equivalencias / Categorias) */
.pc-tabs .pc-tabsep { flex: 0 0 auto; margin-left: auto; margin-right: 4px; width: 0; align-self: stretch; min-height: 28px; border-left: 2px solid #c5ccd3; }
.pc-tabs a.btn.pc-tab-cfg { background: #f1f3f5; color: #444; border: 1px dashed #98a2ad; font-weight: 500; }
.pc-tabs a.btn.pc-tab-cfg:hover { background: #e4e8ec; border-color: #6c7783; }
.pc-tabs a.btn.pc-tab-cfg.on { background: var(--accent); color: #fff; border: 1px solid var(--accent); font-weight: 600; }
.pc-tabs a.btn.pc-tab-cfg.on:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.pc-tabcnt-neu { background: #D9822B; }
@media (max-width: 720px) {
  .pc-tabs .pc-tabsep { flex-basis: 100%; width: 100%; min-height: 0; margin: 2px 0; border-left: 0; border-top: 1px solid #c5ccd3; }
}
/* Pestana "Categorias de producto" */
.ct-sum { font-weight: 600; margin: 8px 0; }
.ct-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 8px 0; }
.ct-bar input[type=search] { min-width: 260px; padding: 6px 8px; border: 1px solid #b7bec6; border-radius: 6px; }
.ct-bar select { padding: 6px 8px; border: 1px solid #b7bec6; border-radius: 6px; }
.ct-count { color: #666; font-size: 12px; }
.ct-scroll { overflow-x: auto; }
table.ct-tab { border-collapse: collapse; width: 100%; font-size: 13px; }
.ct-tab th, .ct-tab td { border-bottom: 1px solid #e3e6ea; padding: 6px 8px; vertical-align: top; text-align: left; }
.ct-tab th { background: #f1f3f5; position: sticky; top: 0; z-index: 1; }
.ct-tab th small { display: block; font-weight: 400; color: #666; }
.ct-tab tr.ct-r[hidden] { display: none; }
.ct-cod { white-space: nowrap; color: #555; }
.ct-loc { min-width: 150px; }
.ct-lab { display: block; white-space: nowrap; cursor: pointer; }
.ct-pn { width: 100%; box-sizing: border-box; margin-top: 4px; padding: 4px 6px; border: 1px solid #b7bec6; border-radius: 4px; }
.ct-pn[hidden] { display: none; }
.ct-pn.ct-bad { border-color: #C62828; background: #fdecea; }
.ct-b { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 12px; font-weight: 600; color: #fff; }
.ct-b-sin { background: #8a939c; }
.ct-b-largo { background: #2e7d32; }
.ct-b-corto { background: #1565c0; }
.ct-prtag { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 12px; background: #fff3e0; color: #8a4b00; border: 1px solid #e0a050; }
.ct-prtag[hidden] { display: none; }
.ct-cob { color: #555; font-size: 12px; margin-top: 3px; }
.ct-st { font-size: 12px; white-space: nowrap; }
.ct-st-ok { color: #2e7d32; font-weight: 600; }
.ct-st-err { color: #C62828; white-space: normal; }

/* ===== Categorias de producto: encabezado y filas iguales a la tabla v3 (sb14) ===== */
table.ct-tab { font-size: 12.5px; background: #fff; }
table.ct-tab thead th { position: sticky; top: 0; z-index: 5; background: #111111; color: #fff; font-size: 11.5px; font-weight: 700; line-height: 1.2; padding: 7px 4px; text-align: center; vertical-align: middle; border-bottom: 3px solid #111111; overflow-wrap: anywhere; }
table.ct-tab thead th.ct-l { text-align: left; padding-left: 8px; }
table.ct-tab thead th small { display: block; font-size: 9.5px; font-weight: 400; opacity: .8; color: #fff; }
table.ct-tab tbody td { border-bottom: 1px solid #EDEDED; color: #333; }
table.ct-tab tbody tr.ct-r:hover td { background: #FAFAFA; }
.ct-b-pr { background: #fff3e0; color: #8a4b00; border: 1px solid #e0a050; }

/* Titulo de local (Control de Ingreso): barra gris oscuro (#444) centrada a todo el ancho de la tabla */
h3.local-titulo, table th.local-titulo { display: block; box-sizing: border-box; width: 100%; background: #666; color: #fff; text-align: center; font-size: 22px; font-weight: 700; letter-spacing: .04em; text-transform: none; padding: 10px 12px; }
h3.local-titulo { border-radius: 6px 6px 0 0; }
table th.local-titulo { display: table-cell; border-radius: 0; }
h3.local-titulo button { color: #fff !important; }
