body {
  background: #f8f9fa;
}

/* ------------ Estilos de la matriz ---------------- */
.legend-table td {
  width: 36px;
  height: 24px;
}

.result-table td {
  text-align: center;
  font-weight: bold;
}

.selected-cell {
  background: black !important;
}

.tabla-criticidad {
  width: 100%;
  max-width: 800px; /* max ancho en desktop */
  border-collapse: collapse;
  table-layout: fixed; /* para que las columnas tengan ancho igual y fijo */
}

.tabla-criticidad th,
.tabla-criticidad td {
  padding: 0;
  margin: 0;
  border: 1px solid #ddd;
  text-align: center;
  font-weight: bold;
  /* Lo importante: hacerlas cuadradas con aspecto ratio 1:1 */
  width: calc(100% / 11); /* 11 columnas, incluyendo la primera */
  aspect-ratio: 1 / 1;
  vertical-align: middle;
  box-sizing: border-box;
  line-height: 3.5;
}

.tabla-criticidad th:first-child,
.tabla-criticidad td:first-child {
  background-color: #FCE4D6;
}

/* ---------------- Ejemplo de la matriz de diagnostico -------------- */

.matriz {
  display: flex;
  justify-content: center;
}

.matriz img {
  width: 70%;
  height: auto;
}

.tabla_colores {
  display: flex;
  justify-content: center;
}

.tabla_colores img {
  width: 55%;
  height: auto;
}

/* ---------------- Estilos generales ----------------- */

.label_pregunta_tema {
  font-size: 15px;
  /* font-family: Pier_Sans_Reg; */
  font-weight: bold;
  color: #313131;
}

.label_descripcion_pregunta {
  /* font-family: Pier_Sans_Reg; */
  color: #444444;
  font-size: 14.5px;
  line-height: 1.25;
}

.small-note {
  font-size: 14.5px;
  line-height: 1.25;
  color: #2f4881;
  padding-top: 5px;
}

.seccion{
  font-size: 16px;
  background-color: #444444;
  color: #fff;
  font-weight: bold;
  padding: 2px 8px;
  margin: 20px 0 0 0;
}

.calcu_texto_criticidad {
    font-size: 15px;
}

.form-select {
  font-size: 14.5px;
}

hr:not([size]) {
  background-color: #444444;
  margin: 0%;
  height: 1.5px;
}

/* ---------- Generacion del PDF */
/* ------------- Tableta -------------- */
@media (max-width: 1100px) {
  .tabla-criticidad th,
  .tabla-criticidad td {
    line-height: 3;
  }
}

/* Tableta */
@media (max-width: 750px) {
  .tabla-criticidad th,
  .tabla-criticidad td {
    line-height: 2.5;
  }

  .matriz img {
    width: 80%;
    height: auto;
  }

  .tabla_colores img {
    width: 65%;
    height: auto;
  }
}

/* ---------------- Movil -------------- */
@media (max-width: 600px) {
  .tabla-criticidad th,
  .tabla-criticidad td {
    line-height: 2;
    font-size: 12px;
  }

  .tabla_resultados th,
  .tabla_resultados td {
    line-height: 2;
    font-size: 14px;
    line-height: 1.5;
  }
}

/* Movil */
@media (max-width: 450px) {
  .tabla-criticidad th,
  .tabla-criticidad td {
    line-height: 1.8;
  }
}
