div.table-wrapper {
  overflow: auto;
  /*height: 800px;*/
  height: auto;
  max-height: 400px;
  clear: both;
}

table {
  /*--color: #d0d0f5;*/
  --color: #00ee0099;
  border-collapse: collapse;
  width: 100%;
  text-align: start;
}

caption {
  caption-side: top;
  font-weight: bold;
  text-decoration: underline;
}

table.filter td:not(:first-child) {
  border-left: 1px solid #cccccc;
}

td.numeric, th.numeric {
  text-align: right;
}

.decimal-table td.num {
  padding: 0;
  font-family: monospace;
  white-space: nowrap;
  vertical-align: bottom;
}

.decimal-table td.label {
  vertical-align: middle;
}

.decimal-table .integer-part {
  display: inline-block;
  width: 40%; /* adjust based on max length */
  text-align: right;
  padding-right: 0;
}

.decimal-table .decimal-part {
  display: inline-block;
  width: 60%; /* adjust for decimal precision length */
  text-align: left;
  padding-left: 0;
}

table.table-scroll {
  table-layout: fixed;
  margin-top: 10px;
}

table.table-scroll thead {
  border-block-start: 2px solid;
  border-block-end: 1px lightgrey;
  /*background: whitesmoke;*/
  background: var(--color);
}

table.table-scroll thead th {
  vertical-align: bottom;
  background: #00ee0099;
}

table.table-scroll thead tr th {
  width: 6rem;
}

table.table-scroll tbody th, table.table-scroll tbody td {
  border: 1px solid lightgrey;
  padding: 0.25rem;
  vertical-align: bottom;
}

table.table-scroll thead tr:first-child {
  position: sticky;
  top: 0;
  background: var(--color);
  z-index: 1000;
}

table.table-scroll thead th:first-child, table.table-scroll tbody tr th {
  position: sticky;
  left: 0;
}

table.table-scroll thead th:first-child {
  background: var(--color);
}

table.table-scroll tbody tr th:first-child {
  background: white;
}
