/* MELANIN_PATIENT_PACKAGE_LEGACY_GRID_V1 */
.legacy-package-grid-wrap{width:100%;overflow:auto;margin-top:6px;border:1px solid #dce5e3;border-radius:7px;background:#fff}
.legacy-package-grid{width:100%;min-width:1900px;border-collapse:collapse;table-layout:auto;color:#263d38;font-size:10px}
.legacy-package-grid th,.legacy-package-grid td{padding:9px 8px;border-right:1px solid #dce4e2;border-bottom:1px solid #e5ebe9;text-align:center;vertical-align:middle;white-space:nowrap}
.legacy-package-grid th:last-child,.legacy-package-grid td:last-child{border-right:0}
.legacy-package-grid thead th{position:sticky;z-index:2;top:0;color:#102723;background:#d9f3ff;font-size:9.5px;font-weight:900;letter-spacing:.01em}
.legacy-package-grid thead th:first-child,.legacy-package-grid thead th:last-child{color:#0872ce}
.legacy-package-grid tbody tr[data-package-row]:hover{background:#f6fbfa}
.legacy-package-grid td.wide-text,.legacy-package-grid th:nth-child(10),.legacy-package-grid th:nth-child(11){min-width:210px;max-width:330px;white-space:normal;line-height:1.35}
.legacy-package-grid td.numeric{font-variant-numeric:tabular-nums;font-weight:800}
.legacy-package-grid tfoot td{border-bottom:0;background:#fafcfc;font-weight:900}
.legacy-package-grid .report-total-label{text-align:left;padding-left:14px;font-size:10.5px}
.legacy-package-status{display:inline-flex;align-items:center;gap:5px;color:#064ee8;font-weight:900}
.legacy-package-status i{width:11px;height:11px;flex:0 0 11px;border-radius:50%;background:linear-gradient(#3ea7ff,#005bc5);box-shadow:inset 0 0 0 1px rgba(0,40,120,.25)}
.legacy-package-status.expired,.legacy-package-status.withdrawn,.legacy-package-status.cancelled{color:#a43c35}
.legacy-package-status.expired i,.legacy-package-status.withdrawn i,.legacy-package-status.cancelled i{background:linear-gradient(#ff8c82,#bd3027)}
.legacy-package-status.completed{color:#14715f}.legacy-package-status.completed i{background:linear-gradient(#55c6a4,#0d8065)}
.legacy-package-used-link{padding:0;border:0;background:transparent;color:#0877d1;font:inherit;font-weight:900;cursor:pointer}
.legacy-package-used-link:hover{text-decoration:underline;text-underline-offset:2px}
.legacy-package-usage-row td{padding:0!important;background:#f8fcfb}
.legacy-package-usage{min-height:38px;padding:9px 12px;text-align:left;color:#58716b}.legacy-package-usage.error{color:#9f3d36}
.legacy-package-usage-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(240px,1fr));gap:7px}
.legacy-package-usage-grid article{padding:8px 9px;border:1px solid #dce8e4;border-radius:8px;background:#fff}
.legacy-package-usage-grid strong,.legacy-package-usage-grid span,.legacy-package-usage-grid small{display:block}
.legacy-package-usage-grid strong{color:#244d45}.legacy-package-usage-grid span{margin-top:3px;color:#607a74;font-size:9px}.legacy-package-usage-grid small{margin-top:3px;color:#84958f;font-size:8.5px}
@media(max-width:760px){.legacy-package-grid-wrap{margin-inline:-2px}.legacy-package-grid{font-size:9px}.legacy-package-grid th,.legacy-package-grid td{padding:7px 6px}}

/* MELANIN_PACKAGE_TABLE_OVERFLOW_FIX_V1 */

/* Keep the drawer and tabs fixed inside the viewport. */
.module-layer,
.medical-drawer {
  max-width: 100vw;
  overflow: hidden;
}

.medical-drawer-body {
  min-width: 0;
  max-width: 100%;
  overflow-x: hidden;
}

.module-tabs {
  position: relative;
  z-index: 5;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  overflow-y: hidden;
  flex-wrap: nowrap;
}

/* Horizontal scrolling must happen inside the package table only. */
.legacy-package-grid-host {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow: hidden;
}

.legacy-package-grid-wrap {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-x: auto;
  overflow-y: visible;
  overscroll-behavior-x: contain;
  scrollbar-gutter: stable;
  -webkit-overflow-scrolling: touch;
}

.legacy-package-grid {
  width: 2050px;
  min-width: 2050px;
  max-width: none;
  table-layout: fixed;
}

/* Fixed professional column widths. */
.legacy-package-grid th:nth-child(1),
.legacy-package-grid td:nth-child(1) { width: 80px; }

.legacy-package-grid th:nth-child(2),
.legacy-package-grid td:nth-child(2) { width: 90px; }

.legacy-package-grid th:nth-child(3),
.legacy-package-grid td:nth-child(3) { width: 110px; }

.legacy-package-grid th:nth-child(4),
.legacy-package-grid td:nth-child(4) { width: 115px; }

.legacy-package-grid th:nth-child(5),
.legacy-package-grid td:nth-child(5) { width: 115px; }

.legacy-package-grid th:nth-child(6),
.legacy-package-grid td:nth-child(6),
.legacy-package-grid th:nth-child(7),
.legacy-package-grid td:nth-child(7) { width: 115px; }

.legacy-package-grid th:nth-child(8),
.legacy-package-grid td:nth-child(8),
.legacy-package-grid th:nth-child(9),
.legacy-package-grid td:nth-child(9) { width: 85px; }

.legacy-package-grid th:nth-child(10),
.legacy-package-grid td:nth-child(10) { width: 270px; }

.legacy-package-grid th:nth-child(11),
.legacy-package-grid td:nth-child(11) { width: 260px; }

.legacy-package-grid th:nth-child(12),
.legacy-package-grid td:nth-child(12) { width: 105px; }

.legacy-package-grid th:nth-child(13),
.legacy-package-grid td:nth-child(13) { width: 120px; }

.legacy-package-grid th:nth-child(14),
.legacy-package-grid td:nth-child(14) { width: 95px; }

.legacy-package-grid th:nth-child(15),
.legacy-package-grid td:nth-child(15) { width: 120px; }

.legacy-package-grid th:nth-child(16),
.legacy-package-grid td:nth-child(16) { width: 115px; }

.legacy-package-grid th:nth-child(17),
.legacy-package-grid td:nth-child(17) { width: 120px; }

/* Allow only package/service text to wrap. */
.legacy-package-grid td:nth-child(10),
.legacy-package-grid td:nth-child(11) {
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.35;
}

.legacy-package-grid th,
.legacy-package-grid td {
  box-sizing: border-box;
  overflow: hidden;
  text-overflow: ellipsis;
}
