html {
  box-sizing: border-box;
}

*,
*:before,
*:after {
  box-sizing: inherit;
}

body.gi-mat-page {
  margin: 0;
  background: #f4f7fb;
  color: #1f2933;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  line-height: 1.35;
}

body.gi-mat-page form {
  margin: 0;
  padding: 10px;
}

body.gi-mat-page table {
  max-width: 100%;
}

body.gi-mat-page td {
  vertical-align: top;
}

body.gi-mat-page td.tit {
  height: 30px;
  padding: 7px 12px !important;
  background: #19984f !important;
  color: #ffffff;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0;
}

body.gi-mat-page td[background] {
  background-image: none !important;
  background-color: #157f44 !important;
}

body.gi-mat-page input[type="button"],
body.gi-mat-page button {
  min-height: 28px;
  margin: 2px 3px 2px 0;
  padding: 5px 11px;
  border: 1px solid #b8c5d4;
  border-radius: 6px;
  background: #ffffff;
  color: #1f2933;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

body.gi-mat-page input[type="button"]:hover,
body.gi-mat-page button:hover {
  border-color: #ff9700;
  background: #fff6ea;
}

body.gi-mat-page input[type="button"][disabled],
body.gi-mat-page button[disabled] {
  border-color: #c9d2dd !important;
  background: #eef2f6 !important;
  color: #7b8794 !important;
  cursor: not-allowed;
  opacity: 0.75;
}

body.gi-mat-toolbar-page input.gi-mat-top-active,
body.gi-mat-toolbar-page input.gi-mat-top-active:hover {
  border-color: #19984f !important;
  background: #19984f !important;
  color: #ffffff !important;
}

body.gi-mat-page input[value="Buscar"],
body.gi-mat-page input[value="Grabar"],
body.gi-mat-page input[value="Registrar"],
body.gi-mat-page input[value="Vista"],
body.gi-mat-page input[value="Adjuntar"] {
  border-color: #ff9700;
  background: #ff9700;
  color: #ffffff;
}

body.gi-mat-page input[value="Buscar"]:hover,
body.gi-mat-page input[value="Grabar"]:hover,
body.gi-mat-page input[value="Registrar"]:hover,
body.gi-mat-page input[value="Vista"]:hover,
body.gi-mat-page input[value="Adjuntar"]:hover {
  border-color: #ff9700;
  background: #fff6ea;
  color: #1f2933;
}

body.gi-mat-page input[value="Parametros"] {
  border-color: #b8c5d4;
  background: #ffffff;
  color: #1f2933;
}

body.gi-mat-page input[value="Parametros"]:hover {
  border-color: #ff9700;
  background: #fff6ea;
  color: #1f2933;
}

body.gi-mat-page input[value="Cerrar"],
body.gi-mat-page input[value="Volver"],
body.gi-mat-page input[value="Volver a Vista General"] {
  border-color: #19984f !important;
  background: #effaf3 !important;
  color: #126b38 !important;
}

body.gi-mat-page select,
body.gi-mat-page input[type="text"],
body.gi-mat-page input[type="password"],
body.gi-mat-page input[type="file"],
body.gi-mat-page textarea {
  min-height: 26px;
  border: 1px solid #b8c5d4 !important;
  border-radius: 5px;
  background-color: #ffffff;
  color: #1f2933;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 12px;
}

body.gi-mat-page select:focus,
body.gi-mat-page input[type="text"]:focus,
body.gi-mat-page input[type="password"]:focus,
body.gi-mat-page textarea:focus {
  outline: 2px solid rgba(255, 151, 0, 0.25);
  border-color: #ff9700 !important;
}

body.gi-mat-page textarea {
  width: 100% !important;
  max-width: 100%;
  min-height: 82px;
  padding: 8px;
  resize: vertical;
}

body.gi-mat-page .tittable td,
body.gi-mat-page tr.tittable td {
  padding: 7px 6px;
  background: #e8eef6 !important;
  color: #1f2933;
  font-weight: 700;
}

body.gi-mat-page table[border="1"] {
  border-color: #d5dee9 !important;
}

body.gi-mat-page table[border="1"] td {
  border-color: #d5dee9 !important;
}

body.gi-mat-toolbar-page form,
body.gi-mat-list-page form,
body.gi-mat-form-page form,
body.gi-mat-files-page form,
body.gi-mat-param-nav-page form,
body.gi-mat-param-page form {
  padding: 8px 10px;
}

body.gi-mat-toolbar-page > form > table,
body.gi-mat-list-page > form > table,
body.gi-mat-form-page > form > table,
body.gi-mat-files-page > form > table,
body.gi-mat-param-nav-page > form > table,
body.gi-mat-param-page > form > table {
  width: 100% !important;
  border: 1px solid #d5dee9 !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
  background: #ffffff;
  border-radius: 8px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

body.gi-mat-toolbar-page {
  background: #f8fbfe;
}

body.gi-mat-toolbar-page form {
  padding-bottom: 6px;
}

body.gi-mat-toolbar-page > form > table {
  box-shadow: none;
}

body.gi-mat-toolbar-page table table td {
  padding: 5px 4px;
  vertical-align: middle;
}

body.gi-mat-toolbar-page img[src="../images/excel.png"] {
  width: 22px;
  height: 22px;
  padding: 3px;
  border: 1px solid #b8c5d4;
  border-radius: 6px;
  background: #ffffff;
  vertical-align: middle;
}

body.gi-mat-toolbar-page img[src="../images/excel.png"]:hover {
  border-color: #ff9700;
  background: #fff6ea;
}

body.gi-mat-list-page {
  overflow: auto;
}

body.gi-mat-list-page > form > table {
  min-width: 1120px;
}

body.gi-mat-list-page > form > table > tbody > tr:nth-child(2) > td,
body.gi-mat-list-page > form > table > tr:nth-child(2) > td {
  padding: 8px 10px;
  background: #f8fbfe;
  border-bottom: 1px solid #d5dee9;
}

body.gi-mat-list-page > form > table > tbody > tr:nth-child(2) table td,
body.gi-mat-list-page > form > table > tr:nth-child(2) table td {
  padding: 4px 5px;
  vertical-align: middle;
}

body.gi-mat-list-page > form > table table[width="2100"],
body.gi-mat-list-page > form > table table[width="2300"],
body.gi-mat-list-page > form > table table[width="2400"] {
  border-color: #d5dee9 !important;
  background: #ffffff;
}

body.gi-mat-list-page > form > table table[width="2100"] td,
body.gi-mat-list-page > form > table table[width="2300"] td,
body.gi-mat-list-page > form > table table[width="2400"] td {
  padding: 6px;
  border-color: #d5dee9 !important;
}

body.gi-mat-list-page img[src="../images/borrar.gif"],
body.gi-mat-list-page img[src="../images/editar.gif"],
body.gi-mat-files-page img[src="../images/borrar.gif"],
body.gi-mat-files-page img[src="../images/editar.gif"] {
  width: 17px;
  height: 17px;
  margin: 0 2px;
  cursor: pointer;
  vertical-align: middle;
}

body.gi-mat-form-page > form > table {
  margin-bottom: 8px;
}

body.gi-mat-form-page > form > table + table {
  width: 100% !important;
  border: 1px solid #d5dee9 !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
  background: #ffffff;
  border-radius: 8px;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

body.gi-mat-form-page > form > table + table > tbody > tr > td,
body.gi-mat-form-page > form > table + table > tr > td {
  padding: 12px;
}

body.gi-mat-form-page table table td {
  padding: 4px 5px;
}

body.gi-mat-form-page input[type="text"] {
  padding: 4px 6px;
}

body.gi-mat-form-page input[readonly],
body.gi-mat-form-page textarea[readonly] {
  border-color: #d5dee9 !important;
  background: #f3f7fb !important;
  color: #38516b;
}

body.gi-mat-form-page b {
  color: #126b38;
}

body.gi-mat-files-page > form > table td {
  padding: 7px 8px;
}

body.gi-mat-files-page .gi-mat-files-form-cell {
  background: #ffffff;
}

body.gi-mat-files-page .gi-mat-files-form {
  display: grid;
  grid-template-columns: minmax(260px, 1.4fr) minmax(180px, 0.8fr) minmax(260px, 1fr) auto;
  gap: 12px;
  align-items: end;
  padding: 6px 2px;
}

body.gi-mat-files-page .gi-mat-files-field label {
  display: block;
  margin-bottom: 5px;
  color: #17212f;
  font-weight: 700;
}

body.gi-mat-files-page input[type="text"] {
  width: 100% !important;
  max-width: 100%;
  padding: 4px 6px;
}

body.gi-mat-files-page input[type="file"] {
  width: 100% !important;
  max-width: 100%;
  padding: 4px 6px;
}

body.gi-mat-files-page .gi-mat-files-actions {
  display: flex;
  gap: 7px;
  align-items: center;
  justify-content: flex-end;
  white-space: nowrap;
}

body.gi-mat-files-page .gi-mat-files-message {
  margin: 6px 2px 0;
  padding: 7px 9px;
  border: 1px solid #acd9bc;
  border-radius: 6px;
  background: #effaf3;
  color: #126b38;
}

body.gi-mat-files-page .gi-mat-files-list {
  padding: 2px;
}

body.gi-mat-files-page .gi-mat-files-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin: 0 0 8px;
  padding: 7px 9px;
  border: 1px solid #d5dee9;
  border-radius: 6px;
  background: #f8fbfe;
  color: #38516b;
  font-weight: 700;
}

body.gi-mat-files-page .gi-mat-files-legend span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

body.gi-mat-files-page .gi-mat-files-legend img {
  width: 16px;
  height: 16px;
}

body.gi-mat-files-page .gi-mat-files-scroll {
  width: 100%;
  max-height: 330px;
  overflow: auto;
  border: 1px solid #d5dee9;
  border-radius: 7px;
  background: #ffffff;
}

body.gi-mat-files-page .gi-mat-files-grid {
  width: 100%;
  table-layout: fixed;
  border: 0 !important;
}

body.gi-mat-files-page .gi-mat-files-grid th,
body.gi-mat-files-page .gi-mat-files-grid td {
  padding: 7px 8px;
  border: 0 !important;
  border-right: 1px solid #d5dee9 !important;
  border-bottom: 1px solid #d5dee9 !important;
  text-align: left;
  vertical-align: middle;
  overflow-wrap: anywhere;
}

body.gi-mat-files-page .gi-mat-files-grid th:last-child,
body.gi-mat-files-page .gi-mat-files-grid td:last-child {
  border-right: 0 !important;
}

body.gi-mat-files-page .gi-mat-files-grid tbody tr:last-child td {
  border-bottom: 0 !important;
}

body.gi-mat-files-page .gi-mat-files-grid th {
  background: #e8eef6 !important;
  color: #1f2933;
  font-weight: 700;
}

body.gi-mat-files-page .gi-mat-files-num {
  width: 48px;
  text-align: center !important;
}

body.gi-mat-files-page .gi-mat-files-icon {
  width: 42px;
  text-align: center !important;
}

body.gi-mat-files-page .gi-mat-files-owner {
  width: 220px;
}

body.gi-mat-files-page .gi-mat-files-file {
  width: 260px;
}

body.gi-mat-param-nav-page table table td {
  padding: 6px 8px;
  vertical-align: middle;
}

body.gi-mat-param-nav-page .gi-mat-param-shell {
  min-height: calc(100vh - 20px);
  padding: 8px 10px;
}

body.gi-mat-param-nav-page .gi-mat-param-shell form {
  height: calc(100vh - 20px);
  min-height: 520px;
  padding: 0;
}

body.gi-mat-param-nav-page .gi-mat-param-shell > form > table {
  height: 100%;
}

body.gi-mat-param-nav-page .gi-mat-param-menu-cell {
  padding: 10px 12px !important;
  border-bottom: 1px solid #d5dee9 !important;
  background: #f8fbfe;
}

body.gi-mat-param-nav-page .gi-mat-param-menu {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

body.gi-mat-param-nav-page input.gi-mat-param-active,
body.gi-mat-param-nav-page input.gi-mat-param-active:hover {
  border-color: #19984f !important;
  background: #19984f !important;
  color: #ffffff !important;
}

body.gi-mat-param-nav-page .gi-mat-param-frame-cell {
  height: 100%;
  padding: 0 !important;
  background: #edf4fa;
}

body.gi-mat-param-nav-page .gi-mat-param-frame {
  display: block;
  width: 100%;
  height: calc(100vh - 112px);
  min-height: 430px;
  border: 0;
  background: #edf4fa;
}

body.gi-mat-param-page > form > table td {
  padding: 7px 8px;
}

body.gi-mat-param-page > form > table table {
  border-color: #d5dee9 !important;
}

body.gi-mat-param-page input[type="text"] {
  padding: 4px 6px;
}
body.gi-mat-list-page .gi-mat-filter-panel {
  display: grid;
  grid-template-columns: auto minmax(150px, 0.8fr) minmax(120px, 0.7fr) minmax(230px, 1.2fr) minmax(150px, 0.8fr) auto;
  gap: 8px 12px;
  align-items: end;
}

body.gi-mat-list-page .gi-mat-filter-title {
  align-self: center;
  color: #17212f;
  font-weight: 700;
  white-space: nowrap;
}

body.gi-mat-list-page .gi-mat-filter-field label {
  display: block;
  margin-bottom: 3px;
  color: #17212f;
  font-weight: 700;
}

body.gi-mat-list-page .gi-mat-filter-field select {
  width: 100% !important;
  min-width: 0;
}

body.gi-mat-list-page .gi-mat-filter-actions {
  display: flex;
  gap: 7px;
  align-items: center;
  justify-content: flex-end;
  white-space: nowrap;
}
/* Matrices: botones tipo 3 retorno/cierre */
body.gi-mat-page input[value="Cerrar"]:hover,
body.gi-mat-page input[value="Volver"]:hover,
body.gi-mat-page input[value="Volver a Vista General"]:hover {
  border-color: #ff9700 !important;
  background: #effaf3 !important;
  color: #126b38 !important;
}
/* Matriz de Riesgos: barra superior sin margen claro en prefijo. */
body.gi-mat-toolbar-page > form > table > tbody > tr:first-child > td,
body.gi-mat-toolbar-page > form > table > tr:first-child > td,
body.gi-mat-list-page > form > table > tbody > tr:first-child > td,
body.gi-mat-list-page > form > table > tr:first-child > td,
body.gi-mat-form-page > form > table > tbody > tr:first-child > td,
body.gi-mat-form-page > form > table > tr:first-child > td,
body.gi-mat-files-page > form > table > tbody > tr:first-child > td,
body.gi-mat-files-page > form > table > tr:first-child > td,
body.gi-mat-param-nav-page .gi-mat-param-shell > table > tbody > tr:first-child > td,
body.gi-mat-param-nav-page .gi-mat-param-shell > table > tr:first-child > td {
  border: 0 !important;
}

body.gi-mat-toolbar-page > form > table > tbody > tr:first-child > td[background],
body.gi-mat-toolbar-page > form > table > tr:first-child > td[background],
body.gi-mat-list-page > form > table > tbody > tr:first-child > td[background],
body.gi-mat-list-page > form > table > tr:first-child > td[background],
body.gi-mat-form-page > form > table > tbody > tr:first-child > td[background],
body.gi-mat-form-page > form > table > tr:first-child > td[background],
body.gi-mat-files-page > form > table > tbody > tr:first-child > td[background],
body.gi-mat-files-page > form > table > tr:first-child > td[background],
body.gi-mat-param-nav-page .gi-mat-param-shell > table > tbody > tr:first-child > td[background],
body.gi-mat-param-nav-page .gi-mat-param-shell > table > tr:first-child > td[background] {
  width: 26px !important;
  min-width: 26px;
  background-color: #137A32 !important;
}

body.gi-mat-toolbar-page > form > table > tbody > tr:first-child > td.tit,
body.gi-mat-toolbar-page > form > table > tr:first-child > td.tit,
body.gi-mat-list-page > form > table > tbody > tr:first-child > td.tit,
body.gi-mat-list-page > form > table > tr:first-child > td.tit,
body.gi-mat-form-page > form > table > tbody > tr:first-child > td.tit,
body.gi-mat-form-page > form > table > tr:first-child > td.tit,
body.gi-mat-files-page > form > table > tbody > tr:first-child > td.tit,
body.gi-mat-files-page > form > table > tr:first-child > td.tit,
body.gi-mat-param-nav-page .gi-mat-param-shell > table > tbody > tr:first-child > td.tit,
body.gi-mat-param-nav-page .gi-mat-param-shell > table > tr:first-child > td.tit {
  background: #18A058 !important;
}
/* Matriz de Riesgos adjuntos: prefijo de titulo homologado. */
body.gi-mat-files-page .gi-mat-files-panel {
  table-layout: fixed;
}

body.gi-mat-files-page .gi-mat-files-panel col.gi-mat-title-prefix {
  width: 26px;
}

body.gi-mat-files-page .gi-mat-files-panel > tbody > tr:first-child > td,
body.gi-mat-files-page .gi-mat-files-panel > tr:first-child > td {
  height: 30px;
  border: 0 !important;
}

body.gi-mat-files-page .gi-mat-files-panel > tbody > tr:first-child > td[background],
body.gi-mat-files-page .gi-mat-files-panel > tr:first-child > td[background] {
  width: 26px !important;
  min-width: 26px !important;
  max-width: 26px !important;
  padding: 0 !important;
}

body.gi-mat-files-page .gi-mat-files-panel > tbody > tr:first-child > td.tit,
body.gi-mat-files-page .gi-mat-files-panel > tr:first-child > td.tit {
  height: 30px;
  padding: 7px 12px !important;
}
/* Matriz de Riesgos parametros: prefijo de titulo homologado. */
body.gi-mat-param-nav-page .gi-mat-param-panel {
  table-layout: fixed;
}

body.gi-mat-param-nav-page .gi-mat-param-panel col.gi-mat-title-prefix {
  width: 26px;
}

body.gi-mat-param-nav-page .gi-mat-param-panel > tbody > tr:first-child > td,
body.gi-mat-param-nav-page .gi-mat-param-panel > tr:first-child > td {
  height: 30px;
  border: 0 !important;
}

body.gi-mat-param-nav-page .gi-mat-param-panel > tbody > tr:first-child > td[background],
body.gi-mat-param-nav-page .gi-mat-param-panel > tr:first-child > td[background] {
  width: 26px !important;
  min-width: 26px !important;
  max-width: 26px !important;
  padding: 0 !important;
}

body.gi-mat-param-nav-page .gi-mat-param-panel > tbody > tr:first-child > td.tit,
body.gi-mat-param-nav-page .gi-mat-param-panel > tr:first-child > td.tit {
  height: 30px;
  padding: 7px 12px !important;
}
/* Matriz de Riesgos parametros: panel redondeado. */
body.gi-mat-param-nav-page .gi-mat-param-shell > form > table.gi-mat-param-panel {
  overflow: hidden;
  border: 1px solid #d5dee9 !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

/* Matriz de Riesgos: cabecera y filtros sin marco interior. */
body.gi-mat-list-page > form > table {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible !important;
}

body.gi-mat-list-page > form > table > tbody > tr:nth-child(-n+2) > td,
body.gi-mat-list-page > form > table > tr:nth-child(-n+2) > td {
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}

body.gi-mat-list-page > form > table > tbody > tr:nth-child(2) > td {
  padding: 8px 10px;
  background: transparent;
}

body.gi-mat-list-page > form > table > tbody > tr:nth-child(2) > td > table,
body.gi-mat-list-page > form > table > tbody > tr:nth-child(2) > td > table td {
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}
/* Matriz de Riesgos: tablas unificadas de parametros. */
body.gi-mat-param-page .gi-mat-param-grid-scroll {
  width: 100%;
  overflow: auto;
  border: 1px solid #d5dee9;
  border-radius: 7px;
  background: #ffffff;
}

body.gi-mat-param-page .gi-mat-param-grid {
  width: 100%;
  table-layout: fixed;
  border: 0 !important;
}

body.gi-mat-param-page .gi-mat-param-grid td {
  padding: 6px 8px;
  border: 0 !important;
  border-right: 1px solid #d5dee9 !important;
  border-bottom: 1px solid #d5dee9 !important;
  vertical-align: middle;
}

body.gi-mat-param-page .gi-mat-param-grid td:last-child {
  border-right: 0 !important;
}

body.gi-mat-param-page .gi-mat-param-grid tbody tr:last-child td {
  border-bottom: 0 !important;
}

body.gi-mat-param-page .gi-mat-param-grid thead td {
  background: #e8eef6 !important;
  color: #1f2933;
  font-weight: 700;
}
/* Matriz de Riesgos: formularios compactos de parametros. */
body.gi-mat-param-page .gi-mat-param-entry {
  display: grid;
  gap: 10px 16px;
  align-items: end;
  padding: 11px 14px 12px;
}

body.gi-mat-param-page .gi-mat-param-entry-single {
  grid-template-columns: minmax(320px, 620px) minmax(40px, 1fr) auto;
}

body.gi-mat-param-page .gi-mat-param-entry-dual {
  grid-template-columns: minmax(280px, 560px) 90px minmax(40px, 1fr) auto;
}

body.gi-mat-param-page .gi-mat-param-entry-field label {
  display: block;
  margin-bottom: 4px;
  color: #17212f;
  font-weight: 700;
}

body.gi-mat-param-page .gi-mat-param-entry-field input[type="text"],
body.gi-mat-param-page .gi-mat-param-entry-field textarea {
  width: 100% !important;
  max-width: 100%;
}

body.gi-mat-param-page .gi-mat-param-entry-value input[type="text"] {
  width: 56px !important;
}

body.gi-mat-param-page .gi-mat-param-entry-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
  white-space: nowrap;
}

body.gi-mat-param-page .gi-mat-param-entry-message {
  align-self: center;
  color: #c93636;
}

body.gi-mat-param-page .gi-mat-param-entry-classification {
  grid-template-columns: minmax(300px, 1.2fr) 170px minmax(190px, 0.7fr) auto;
  align-items: end;
}

body.gi-mat-param-page .gi-mat-param-entry-classification .gi-mat-param-entry-actions {
  grid-column: 4;
  grid-row: 1;
}

body.gi-mat-param-page .gi-mat-param-entry-range {
  display: flex;
  gap: 7px;
  align-items: center;
}

body.gi-mat-param-page .gi-mat-param-entry-range input[type="text"] {
  width: 58px !important;
}

body.gi-mat-param-page .gi-mat-param-entry-color input[type="text"] {
  width: 72px !important;
}

body.gi-mat-param-page .gi-mat-param-entry-description {
  grid-column: 1;
  grid-row: 2;
}

body.gi-mat-param-page .gi-mat-param-entry-description textarea {
  min-height: 58px;
}

body.gi-mat-param-page .gi-mat-param-entry-palette {
  grid-column: 2 / 4;
  grid-row: 2;
  align-self: center;
}

body.gi-mat-param-page .gi-mat-param-entry-classification .gi-mat-param-entry-message {
  grid-column: 4;
  grid-row: 2;
  align-self: center;
}

@media (max-width: 900px) {
  body.gi-mat-param-page .gi-mat-param-entry-single,
  body.gi-mat-param-page .gi-mat-param-entry-dual,
  body.gi-mat-param-page .gi-mat-param-entry-classification {
    grid-template-columns: minmax(220px, 1fr) auto;
  }

  body.gi-mat-param-page .gi-mat-param-entry-classification > * {
    grid-column: auto;
    grid-row: auto;
  }

  body.gi-mat-param-page .gi-mat-param-entry-actions {
    justify-content: flex-start;
  }
}
/* Matriz de Riesgos: panel uniforme y tablas con altura natural. */
html,
body.gi-mat-param-page {
  height: 100%;
}

body.gi-mat-param-page > form {
  height: 100%;
}

body.gi-mat-param-page > form > table {
  height: calc(100% - 1cm);
}

body.gi-mat-param-page > form > table > tbody > tr:first-child,
body.gi-mat-param-page > form > table > tbody > tr:first-child > td {
  height: 1px;
  vertical-align: top;
}

body.gi-mat-param-page > form > table > tbody > tr:nth-child(2) > td {
  padding: 0.5cm 8px 8px !important;
  vertical-align: top;
}

body.gi-mat-param-page .gi-mat-param-grid-cell {
  display: block;
  height: auto;
}

body.gi-mat-param-page .gi-mat-param-grid-scroll {
  height: auto !important;
  min-height: 0;
  max-height: calc(100vh - 245px);
  overflow: auto;
}
body.gi-mat-param-page .gi-mat-param-entry-note {
  display: block;
  margin-bottom: 8px;
  color: #38516b;
  font-weight: 700;
}

/* Matrices 1, 2 y 3: el retorno ocupa una celda final, alineada al borde derecho. */
body.gi-mat-page.gi-mat-toolbar-page table.gi-mat-main-toolbar {
  width: 100% !important;
}

body.gi-mat-page.gi-mat-toolbar-page td.gi-mat-main-toolbar-spacer {
  width: 100%;
}

body.gi-mat-page.gi-mat-toolbar-page td.gi-mat-main-toolbar-close {
  width: 112px;
  padding-right: 12px !important;
  text-align: right;
  white-space: nowrap;
}