/* Carteles completos, incluidos el borde, el título y el UID, en hojas A4. Las medidas salen de
   src/carteles-formato.js, las mismas del PDF: el servidor las manda y comun.js las pone como
   variables --c-*. Los valores de acá son los del cartel de 4 × 4 cm (24 por hoja) y valen
   hasta que llegan. El QR ocupa lo que queda después de la banda, el hueco, la línea de
   instrucción (de alto 0 si no hay) y el UID.
   Misma tipografía que FS: Oswald en el título y Source Sans 3 en el UID (el PDF de
   src/pdf.js incrusta las mismas, en los mismos pesos: si cambian acá, cambian allá). Colores fijos
   (no los del tema): un cartel impreso es siempre blanco con tinta oscura. */

body { background: var(--fondo); }
.hojas, .carteles-muestra {
  --c-lado: 40mm; --c-borde: .3mm; --c-banda: 3mm; --c-hueco: .8mm; --c-pie: 3mm; --c-instr: 0mm; --c-qr: 32.6mm;
  --c-margen: 10mm; --c-espacio: 6mm; --c-columnas: 4; --c-titulo: 7.5pt; --c-uid: 7pt; --c-instr-fs: 9pt;
}
.hojas { display: flex; flex-direction: column; align-items: center; gap: 16px; padding: 16px; }
.hoja {
  width: 210mm; height: 297mm; overflow: hidden; background: #fff; padding: var(--c-margen);
  display: grid; grid-template-columns: repeat(var(--c-columnas), var(--c-lado)); grid-auto-rows: var(--c-lado); gap: var(--c-espacio);
  align-content: start; justify-content: center;
  border: 1px solid var(--borde); box-shadow: var(--sombra);
}
.cartel {
  box-sizing: border-box; width: var(--c-lado); height: var(--c-lado); display: grid;
  grid-template-rows: var(--c-banda) calc(var(--c-hueco) + var(--c-qr)) var(--c-instr) var(--c-pie); text-align: center;
  padding: 0; border: var(--c-borde) solid #101826; overflow: hidden;
  break-inside: avoid; color: #14181f; background: #fff; font-family: var(--fuente);
}
.cartel .t1 {
  display: flex; align-items: center; justify-content: center; margin: 0; padding: 0; background: #101826; color: #fff;
  font-family: var(--fuente-display); font-weight: 600; font-size: var(--c-titulo); letter-spacing: .025em; text-transform: uppercase; line-height: 1;
}
.cartel .qr { width: var(--c-qr); height: var(--c-qr); margin-top: var(--c-hueco); justify-self: center; }
.cartel .qr svg { width: 100%; height: 100%; display: block; }
.cartel .instr {
  display: flex; align-items: center; justify-content: center; overflow: hidden; padding: 0 1mm;
  font-weight: 600; font-size: var(--c-instr-fs); line-height: 1; white-space: nowrap;
}
.cartel .uid { display: flex; align-items: center; justify-content: center; font-family: var(--fuente); font-weight: 600; font-size: var(--c-uid); line-height: 1; white-space: nowrap; }

@page { size: A4; margin: 0; }
@media print {
  body { background: #fff; }
  .no-imprimir, .franja-entorno { display: none !important; }
  /* Sin esto el navegador no imprime fondos por defecto («Gráficos de fondo» apagado): la banda
     oscura del título se pierde y el «ASISTENCIA» blanco queda invisible sobre el papel. */
  .cartel, .cartel .t1 { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .hojas { padding: 0; gap: 0; }
  .hoja { border: 0; box-shadow: none; break-after: page; }
}
