/* HealthCare Clinical Portal — enterprise console chrome */
:root {
  --ent-ink: #2b1a1a;
  --ent-slate: #3b2020;
  --ent-slate-2: #4f2d2d;
  --ent-line: #edd6d6;
  --ent-line-soft: #f8eeee;
  --ent-surface: #faf7f7;
  --ent-panel: #ffffff;
  --ent-teal: #921a1d;
  --ent-teal-deep: #731315;
  --ent-amber: #c48b2a;
  --ent-coral: #d9534f;
  --ent-muted: #5a4f4f;
  --ent-ok: #1f7a4d;
  --ent-sidebar-w: 260px;
  --font-ent: "IBM Plex Sans", "Segoe UI", sans-serif;
  --font-ent-display: "IBM Plex Serif", Georgia, serif;
  --ent-shadow-sm: 0 2px 8px rgba(146, 26, 29, 0.04);
  --ent-shadow-md: 0 6px 20px rgba(146, 26, 29, 0.06);
  --ent-shadow-lg: 0 12px 35px rgba(146, 26, 29, 0.1);
  --ent-radius-sm: 8px;
  --ent-radius-md: 14px;
  --ent-radius-lg: 24px;
}

*, *::before, *::after {
  box-sizing: border-box;
}

.ent-body {
  margin: 0;
  font-family: var(--font-ent);
  color: var(--ent-ink);
  background: var(--ent-surface);
  max-width: 100vw;
  overflow-x: hidden;
  min-height: 100vh;
}

.ent-app {
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.ent-sidebar {
  width: var(--ent-sidebar-w);
  flex-shrink: 0;
  background: linear-gradient(180deg, #241516 0%, #1a0f10 100%);
  color: #e8eef3;
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 40;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
}

.ent-side-brand {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  padding: 1.15rem 1.1rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.ent-side-mark {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background:
    linear-gradient(135deg, #921a1d 0%, #d9534f 55%, #c4a35a 100%);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.ent-side-product {
  font-family: var(--font-ent-display);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
}

.ent-side-edition {
  font-size: 0.72rem;
  color: #8fa3b3;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
}

.ent-side-section {
  padding: 1rem 1.1rem 0.4rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #7d93a5;
}

.ent-nav {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0 0.65rem;
  flex: 1;
  overflow-y: auto;
}

.ent-nav-item {
  display: block;
  padding: 0.7rem 0.75rem;
  border-radius: 8px;
  text-decoration: none;
  color: #c5d4df;
  border: 1px solid transparent;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.ent-nav-item:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

.ent-nav-item.is-active {
  background: rgba(146, 26, 29, 0.28);
  border-color: rgba(146, 26, 29, 0.35);
  color: #fff;
}

.ent-nav-label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
}

.ent-nav-hint {
  display: block;
  font-size: 0.72rem;
  color: #8094a5;
  margin-top: 0.12rem;
}

.ent-nav-item.is-active .ent-nav-hint { color: #a8d4cf; }

.ent-side-foot {
  padding: 0.85rem 1.1rem 1.1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.ent-side-meta {
  font-size: 0.72rem;
  color: #8fa3b3;
  line-height: 1.55;
  margin-bottom: 0.75rem;
}

.ent-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  margin-right: 0.35rem;
  vertical-align: middle;
}
.ent-dot--ok { background: #3dba7a; box-shadow: 0 0 0 2px rgba(61, 186, 122, 0.25); }
.ent-dot--warn { background: #d4a017; }
.ent-dot--bad { background: #d9534f; }

.ent-side-logout {
  display: block;
  text-align: center;
  padding: 0.55rem;
  border-radius: 6px;
  background: rgba(169, 68, 56, 0.2);
  border: 1px solid rgba(217, 83, 79, 0.35);
  color: #f0c4c0;
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 600;
}
.ent-side-logout:hover { background: rgba(169, 68, 56, 0.35); color: #fff; }

/* Main column */
.ent-main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.ent-topbar {
  background: var(--ent-panel);
  border-bottom: 1px solid var(--ent-line);
  padding: 0.85rem 1.25rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
  position: sticky;
  top: 0;
  z-index: 30;
}

.ent-topbar-left {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  min-width: 0;
}

.ent-menu-btn {
  border: 1px solid var(--ent-line);
  background: #fff;
  border-radius: 6px;
  width: 36px;
  height: 36px;
  font-size: 1.1rem;
  line-height: 1;
  margin-top: 0.15rem;
}

.ent-breadcrumb {
  font-size: 0.72rem;
  color: var(--ent-muted);
  font-weight: 500;
  letter-spacing: 0.02em;
}
.ent-bc-sep { margin: 0 0.35rem; opacity: 0.5; }

.ent-page-title {
  margin: 0.15rem 0 0;
  font-family: var(--font-ent-display);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--ent-ink);
  line-height: 1.25;
}

.ent-patient-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.45rem;
}

.ent-pill {
  display: inline-flex;
  align-items: center;
  padding: 0.15rem 0.55rem;
  border-radius: 4px;
  background: var(--ent-line-soft);
  border: 1px solid var(--ent-line);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--ent-slate);
}
.ent-pill--accent {
  background: rgba(146, 26, 29, 0.1);
  border-color: rgba(146, 26, 29, 0.25);
  color: var(--ent-teal-deep);
}

.ent-topbar-right {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}

.ent-clock {
  font-size: 0.78rem;
  color: var(--ent-muted);
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}

.ent-user-chip {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.35rem 0.65rem 0.35rem 0.35rem;
  border: 1px solid var(--ent-line);
  border-radius: 8px;
  background: #fafcfd;
}

.ent-user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: var(--ent-slate);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
}

.ent-user-name { font-size: 0.85rem; font-weight: 600; line-height: 1.2; }
.ent-user-role { font-size: 0.7rem; color: var(--ent-muted); text-transform: uppercase; letter-spacing: 0.06em; font-weight: 600; }

.ent-content {
  flex: 1;
  padding: 1.1rem 1.25rem 2rem;
  max-width: 1400px;
  width: 100%;
  min-width: 0;
  overflow-x: hidden;
}

.ent-footer {
  border-top: 1px solid var(--ent-line);
  padding: 0.75rem 1.25rem;
  font-size: 0.72rem;
  color: var(--ent-muted);
  background: #eef2f5;
}
.ent-footer-sep { margin: 0 0.4rem; opacity: 0.5; }

/* Panels & KPIs */
.ent-kpi-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.65rem;
  margin-bottom: 1rem;
}

@media (min-width: 768px) {
  .ent-kpi-row { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1100px) {
  .ent-kpi-row { grid-template-columns: repeat(6, 1fr); }
}

.ent-kpi {
  background: var(--ent-panel);
  border: 1px solid var(--ent-line-soft);
  border-radius: var(--ent-radius-md);
  padding: 1rem;
  min-height: 90px;
  box-shadow: var(--ent-shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ent-kpi-label {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ent-muted);
  margin: 0 0 0.35rem;
}

.ent-kpi-value {
  font-family: var(--font-ent-display);
  font-size: 1.55rem;
  font-weight: 600;
  line-height: 1;
  color: var(--ent-ink);
}

.ent-kpi-sub {
  margin-top: 0.35rem;
  font-size: 0.72rem;
  color: var(--ent-muted);
}

.ent-panel {
  background: rgba(255, 255, 255, 0.97) !important;
  border-radius: var(--ent-radius-md) !important;
  border: 1px solid #e5e7eb !important;
  box-shadow: 0 12px 40px 0 rgba(146, 26, 29, 0.06), inset 0 0 0 1px rgba(255,255,255,0.4) !important;
  overflow: hidden;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
}
@supports (backdrop-filter: blur(1px)) {
  .ent-panel {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.8)) !important;
    backdrop-filter: blur(24px) !important;
    -webkit-backdrop-filter: blur(24px) !important;
    border: 1px solid rgba(255, 255, 255, 0.8) !important;
  }
}

.ent-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  padding: 0.85rem 1.15rem;
  border-bottom: 1px solid var(--ent-line);
  background: linear-gradient(180deg, #ffffff 0%, var(--ent-line-soft) 100%);
}

.ent-panel-title {
  margin: 0;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--ent-slate);
}

.ent-panel-tools {
  display: flex;
  gap: 0.4rem;
  align-items: center;
  flex-wrap: wrap;
}

.ent-panel-body { padding: 0.85rem 0.95rem; }
.ent-panel-body--flush { padding: 0; }

.ent-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: flex-end;
  margin-bottom: 1rem;
  padding: 0.85rem 0.95rem;
  background: var(--ent-panel);
  border: 1px solid var(--ent-line);
  border-radius: 8px;
}

.ent-field { flex: 1; min-width: 140px; }
.ent-field label {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ent-muted);
  margin-bottom: 0.25rem;
}

.ent-input, .ent-select {
  width: 100%;
  border: 1px solid var(--ent-line);
  border-radius: 6px;
  padding: 0.5rem 0.65rem;
  font-size: 0.9rem;
  font-family: var(--font-ent);
  background: #fff;
}
.ent-input:focus, .ent-select:focus,
.ent-input:focus-visible, .ent-select:focus-visible {
  outline: none !important;
  border-color: var(--ent-teal) !important;
  box-shadow: 0 0 0 3px rgba(146, 26, 29, 0.18) !important;
}

.ent-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.5rem 0.9rem;
  border-radius: 6px;
  border: 1px solid transparent;
  font-family: var(--font-ent);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}
.ent-btn--primary {
  background: var(--ent-teal);
  color: #fff;
}
.ent-btn--primary:hover { background: var(--ent-teal-deep); color: #fff; }
.ent-btn--ghost {
  background: #fff;
  border-color: var(--ent-line);
  color: var(--ent-slate);
}
.ent-btn--ghost:hover { background: var(--ent-line-soft); color: var(--ent-ink); }
.ent-btn--danger {
  background: #fff;
  border-color: rgba(169, 68, 56, 0.35);
  color: var(--ent-coral);
}

.ent-table-responsive {
  width: 100% !important;
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch !important;
  margin-bottom: 1rem;
}

.ent-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}
.ent-table th {
  text-align: left;
  padding: 0.55rem 0.85rem;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ent-muted);
  background: #f7fafc;
  border-bottom: 1px solid var(--ent-line);
  font-weight: 700;
  white-space: nowrap;
}
.ent-table td {
  padding: 0.6rem 0.85rem;
  border-bottom: 1px solid var(--ent-line-soft);
  vertical-align: middle;
}
.ent-table tr:hover td { background: #f8fbfc; }
.ent-table a {
  color: var(--ent-teal-deep);
  font-weight: 600;
  text-decoration: none;
}
.ent-table a:hover { text-decoration: underline; }

.ent-badge {
  display: inline-block;
  padding: 0.12rem 0.45rem;
  border-radius: 4px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.ent-badge--ok { background: #e6f5ec; color: var(--ent-ok); }
.ent-badge--warn { background: #f8f0d8; color: var(--ent-amber); }
.ent-badge--bad { background: #f8e6e4; color: var(--ent-coral); }
.ent-badge--info { background: #faebec; color: #6b1416; }
.ent-badge--muted { background: var(--ent-line-soft); color: var(--ent-muted); }

.ent-empty {
  padding: 1.5rem 1rem;
  text-align: center;
  color: var(--ent-muted);
  font-size: 0.9rem;
}

.ent-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 2rem 1rem;
  text-align: center;
  color: var(--ent-muted);
}
.ent-empty-state i {
  font-size: 2rem;
  opacity: 0.55;
  margin-bottom: 0.25rem;
}
.ent-empty-state strong {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ent-ink);
}
.ent-empty-state span {
  font-size: 0.82rem;
}
.ent-empty-state a {
  font-size: 0.82rem;
  margin-top: 0.25rem;
}

.ent-list-dense {
  list-style: none;
  margin: 0;
  padding: 0;
}
.ent-list-dense li {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid var(--ent-line-soft);
  font-size: 0.84rem;
}
.ent-list-dense li:last-child { border-bottom: 0; }
.ent-list-dense .k { color: var(--ent-muted); }
.ent-list-dense .v { font-weight: 600; text-align: right; }

.ent-grid-2 {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
  width: 100%;
  min-width: 0;
}
.ent-grid-2 > * {
  min-width: 0;
  width: 100%;
}
@media (min-width: 992px) {
  .ent-grid-2 { grid-template-columns: 1.6fr 1fr; }
}

.ent-grid-3 {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
  width: 100%;
  min-width: 0;
}
.ent-grid-3 > * {
  min-width: 0;
  width: 100%;
}
@media (min-width: 992px) {
  .ent-grid-3 { grid-template-columns: 1fr 1fr 1fr; }
}

.ent-module-link {
  display: block;
  padding: 0.75rem 0.85rem;
  border: 1px solid var(--ent-line);
  border-radius: 8px;
  background: #fff;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.ent-module-link:hover {
  border-color: rgba(146, 26, 29, 0.4);
  box-shadow: 0 4px 14px rgba(18, 26, 34, 0.06);
  color: inherit;
}
.ent-module-link h3 {
  margin: 0 0 0.25rem;
  font-size: 0.92rem;
  font-weight: 700;
}
.ent-module-link p {
  margin: 0;
  font-size: 0.78rem;
  color: var(--ent-muted);
  line-height: 1.4;
}
.ent-module-link .ent-module-code {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ent-teal);
  margin-bottom: 0.3rem;
}

/* Compat: chart pages inside enterprise shell */
.ent-body .mc-wrap { max-width: none; padding: 0; margin: 0; }
.ent-body .mc-header { display: none; }
.ent-body .mc-footer { display: none; }
.ent-body .mc-body { background: transparent; min-height: 0; }

/* Mobile sidebar */
@media (max-width: 991.98px) {
  .ent-sidebar {
    position: fixed;
    left: 0;
    top: 0;
    transform: translateX(-105%);
    transition: transform 0.2s ease;
    box-shadow: 8px 0 30px rgba(0, 0, 0, 0.25);
  }
  .ent-nav-open .ent-sidebar { transform: translateX(0); }
  .ent-sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 26, 34, 0.45);
    z-index: 35;
  }
  .ent-nav-open .ent-sidebar-backdrop:not([hidden]) {
    display: block;
  }
}

/* —— Enterprise login —— */
.ent-login-body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-ent);
  background:
    linear-gradient(135deg, rgba(32, 18, 19, 0.9) 0%, rgba(20, 10, 11, 0.95) 100%),
    url('../images/clinical_bg.jpg') no-repeat center center fixed;
  background-size: cover;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

.ent-login-frame {
  width: 100%;
  max-width: 960px;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.ent-login-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(32, 18, 19, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 12px;
  font-size: 0.78rem;
  color: #9bb0c0;
}

.ent-login-bar strong { color: #e8eef3; }

.ent-login-workspace {
  display: grid;
  grid-template-columns: 1fr;
  background: rgba(255, 255, 255, 0.97) !important;
  border: 1px solid #e5e7eb !important;
  border-radius: 24px !important;
  overflow: hidden;
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35) !important;
  animation: springUp 0.65s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}
@supports (backdrop-filter: blur(1px)) {
  .ent-login-workspace {
    background: rgba(255, 255, 255, 0.05) !important;
    backdrop-filter: blur(16px) !important;
    -webkit-backdrop-filter: blur(16px) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
  }
}

@media (min-width: 860px) {
  .ent-login-workspace {
    grid-template-columns: 1.15fr 0.85fr;
  }
}

.ent-login-info {
  position: relative;
  padding: 3rem 2.5rem !important;
  background: rgba(146, 26, 29, 0.22) !important;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
}

.ent-login-info-inner { max-width: 520px; }

.ent-login-product {
  font-family: var(--font-ent-display);
  font-size: clamp(1.8rem, 3vw, 2.35rem);
  font-weight: 600;
  margin: 0 0 0.35rem;
  color: #fff;
}

.ent-login-subhead {
  margin: 0 0 1.5rem;
  color: #e6c1c3;
  font-size: 0.95rem;
  line-height: 1.5;
}

.ent-login-matrix {
  display: grid;
  gap: 0.55rem;
  margin-bottom: 1.5rem;
}

.ent-login-matrix-row {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 0.75rem;
  padding: 0.65rem 0.75rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 6px;
  font-size: 0.84rem;
}
.ent-login-matrix-row .k { color: #e6c1c3; font-weight: 600; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.05em; padding-top: 0.15rem; }
.ent-login-matrix-row .v { color: #e8eef3; }

.ent-login-checklist {
  margin: 0;
  padding: 0;
  list-style: none;
}
.ent-login-checklist li {
  display: flex;
  gap: 0.55rem;
  align-items: flex-start;
  padding: 0.45rem 0;
  font-size: 0.84rem;
  color: #fae6e7;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.ent-login-checklist li:last-child { border-bottom: 0; }

.ent-login-auth {
  background: rgba(255, 255, 255, 0.88) !important;
  backdrop-filter: blur(8px) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  padding: 3rem 2.5rem !important;
  display: flex;
  flex-direction: column;
  align-items: stretch !important;
  justify-content: center;
  color: #1a0f10;
}

.ent-login-auth form {
  width: 100% !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: stretch !important;
}

/* 3D Floating Heart Icon */
.ent-login-icon-wrap {
  margin-bottom: 1.5rem;
  display: flex;
  justify-content: center;
}

.ent-login-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #ff4d5a 0%, #921a1d 85%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 2.15rem;
  box-shadow: 
    0 12px 28px rgba(146, 26, 29, 0.45),
    inset -6px -6px 14px rgba(0, 0, 0, 0.35),
    inset 6px 6px 14px rgba(255, 255, 255, 0.45);
  animation: floatPulse 4s ease-in-out 3;
}

.ent-login-icon i {
  animation: beatPulse 1.8s ease-in-out 3;
  display: inline-block;
}

@keyframes floatPulse {
  0%, 100% {
    transform: translateY(0) rotateY(0deg);
  }
  50% {
    transform: translateY(-8px) rotateY(12deg);
  }
}

@keyframes beatPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.15); }
}

/* Form alignment adjustments */
.ent-login-form-title {
  font-family: var(--font-ent-display);
  font-size: 1.35rem;
  font-weight: 600;
  margin: 0 0 0.25rem;
  text-align: center;
  color: #1a0f10;
}
.ent-login-form-subtitle {
  font-size: 0.84rem;
  color: #6a5354;
  margin-bottom: 1.5rem;
  text-align: center;
}

.ent-login-card {
  width: 100%;
  max-width: 420px;
  background: #ffffff;
  border: 1px solid rgba(146, 26, 29, 0.12);
  border-radius: var(--ent-radius-md);
  box-shadow: var(--ent-shadow-lg);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.ent-login-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 40px rgba(146, 26, 29, 0.08);
}

.ent-login-card-head {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--ent-line);
  background: linear-gradient(180deg, #ffffff, #faf1f2);
}
.ent-login-card-head h1 {
  margin: 0;
  font-size: 1.15rem;
  font-family: var(--font-ent-display);
  font-weight: 600;
}
.ent-login-card-head p {
  margin: 0.25rem 0 0;
  font-size: 0.82rem;
  color: var(--ent-muted);
}

.ent-login-card-body { padding: 1.5rem; }

.ent-login-err {
  background: #f8e6e4;
  color: var(--ent-coral);
  border: 1px solid rgba(169, 68, 56, 0.25);
  border-radius: 6px;
  padding: 0.65rem 0.75rem;
  font-size: 0.85rem;
  margin-bottom: 0.85rem;
}

.ent-login-timeout {
  background: #fef9ec;
  color: #7c5900;
  border: 1px solid rgba(124, 89, 0, 0.25);
  border-radius: 6px;
  padding: 0.65rem 0.75rem;
  font-size: 0.85rem;
  margin-bottom: 0.85rem;
}

.ent-login-card-foot {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--ent-line);
  background: #FAF2F3;
  font-size: 0.75rem;
  color: var(--ent-muted);
  line-height: 1.45;
}

.ent-login-footnote {
  margin-top: 2rem;
  font-size: 0.76rem;
  color: #6a5354;
  line-height: 1.45;
  text-align: center;
  border-top: 1px solid rgba(146, 26, 29, 0.08);
  padding-top: 1.25rem;
}

/* —— Accessibility & mobile shell —— */
.ent-skip {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 1000;
  padding: 0.65rem 1rem;
  background: var(--ent-teal);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
  border-radius: 0 0 8px 0;
}
.ent-skip:focus {
  left: 0;
  outline: 3px solid #c4a35a;
  outline-offset: 2px;
}

:focus-visible {
  outline: 3px solid rgba(146, 26, 29, 0.4) !important;
  outline-offset: 2px;
}
.ent-nav-item:focus-visible,
.ent-menu-btn:focus-visible,
.ent-btn:focus-visible {
  outline: 3px solid rgba(146, 26, 29, 0.6) !important;
  outline-offset: 2px;
}
.ent-input:focus-visible, .ent-select:focus-visible {
  outline: none !important;
}

.ent-menu-btn {
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  touch-action: manipulation;
}
.ent-menu-btn[aria-expanded="true"] {
  background: rgba(146, 26, 29, 0.12);
  border-color: rgba(146, 26, 29, 0.4);
}

.ent-table-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

@media (max-width: 991.98px) {
  .ent-content {
    padding: 0.75rem 0.75rem 1.5rem;
    padding-left: max(0.75rem, env(safe-area-inset-left));
    padding-right: max(0.75rem, env(safe-area-inset-right));
    padding-bottom: max(1.5rem, env(safe-area-inset-bottom));
    overflow-x: hidden;
    max-width: 100vw;
  }
  .ent-topbar {
    padding: 0.7rem 0.75rem;
    padding-top: max(0.7rem, env(safe-area-inset-top));
    flex-wrap: wrap;
    align-items: center;
  }
  .ent-page-title {
    font-size: 1.15rem;
    word-break: break-word;
  }
  .ent-clock {
    display: none;
  }
  .ent-user-chip .ent-user-role {
    display: none;
  }
  /* KPI grid */
  .ent-kpi-row {
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
  }
  .ent-kpi-value--accent {
    font-size: 1.45rem !important;
  }
  .ent-kpi {
    padding: 0.65rem 0.7rem;
    min-width: 0;
  }
  .ent-kpi-value {
    font-size: 1.25rem;
  }
  /* Panel containment */
  .ent-panel,
  .ent-glass-card {
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
  }
  .ent-panel-head {
    flex-wrap: wrap;
    gap: 0.4rem;
  }
  .ent-panel-body {
    padding: 0.75rem;
  }
  .ent-panel-body--flush {
    overflow-x: auto;
  }
  /* Canvas / chart containment */
  canvas {
    max-width: 100% !important;
  }
  /* Module directory grid stacks */
  .ent-grid-3 {
    grid-template-columns: 1fr;
  }
  /* Toolbar */
  .ent-toolbar {
    flex-direction: column;
    align-items: stretch;
  }
  .ent-toolbar .ent-field,
  .ent-toolbar .ent-btn,
  .ent-toolbar a.ent-btn {
    width: 100%;
  }
  /* Table font */
  .ent-table {
    font-size: 0.82rem;
  }
  .ent-table th,
  .ent-table td {
    padding: 0.55rem 0.5rem;
    white-space: nowrap;
  }
  /* Status mix / list panels */
  .ent-list-dense {
    width: 100%;
  }
  .ent-list-dense li {
    flex-wrap: wrap;
    gap: 0.25rem;
  }
  .ent-list-dense .v {
    text-align: left;
    word-break: break-word;
  }
  /* Footer */
  .ent-footer {
    flex-wrap: wrap;
    gap: 0.25rem;
    line-height: 1.4;
  }
  .ent-footer-sep { display: none; }
  .ent-sidebar {
    padding-top: env(safe-area-inset-top);
    width: min(var(--ent-sidebar-w), 88vw);
  }
  .ent-nav-item {
    min-height: 48px;
    padding: 0.8rem 0.85rem;
  }
  body.ent-nav-open {
    overflow: hidden;
  }
}

/* ── 3.3 Navigation loading bar ──────────────────────────────── */
.ent-nav-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0;
  height: 3px;
  background: var(--ent-teal);
  z-index: 9999;
  transition: width 2s linear;
  pointer-events: none;
}
.ent-nav-progress.is-loading {
  width: 85%;
}

@media (max-width: 479.98px) {
  .ent-kpi-row {
    grid-template-columns: 1fr;
  }
  .ent-login-matrix-row {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }
  .ent-patient-meta {
    gap: 0.3rem;
  }
  .ent-pill {
    font-size: 0.7rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .ent-login-icon,
  .ent-login-icon i {
    animation: none !important;
    transform: none !important;
  }
}

@media (prefers-contrast: more) {
  .ent-nav-item.is-active {
    outline: 2px solid #fff;
  }
  .ent-pill,
  .ent-panel,
  .ent-kpi {
    border-color: #000;
  }
}

/* Mobile Bottom Navigation Redesign */
.mobile-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 65px;
  background: var(--ent-panel);
  border-top: 1px solid var(--ent-line);
  display: flex;
  justify-content: space-around;
  align-items: center;
  z-index: 1050;
  padding-bottom: env(safe-area-inset-bottom);
  box-shadow: 0 -4px 20px rgba(146, 26, 29, 0.06);
}

.mobile-bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--ent-muted);
  text-decoration: none;
  font-size: 0.72rem;
  font-weight: 500;
  flex: 1;
  height: 100%;
  transition: color 0.2s ease, transform 0.2s ease;
  gap: 2px;
}

.mobile-bottom-nav-item i {
  font-size: 1.25rem;
}

.mobile-bottom-nav-item:hover {
  color: var(--ent-teal);
}

.mobile-bottom-nav-item.is-active {
  color: var(--ent-teal);
  font-weight: 600;
}

@media (max-width: 991.98px) {
  .ent-content {
    padding-bottom: calc(65px + 2rem) !important;
  }
  .ent-footer {
    margin-bottom: 75px !important;
  }
}

/* ==========================================================================
   Centralized Design System Utilities (No Inline CSS)
   ========================================================================== */

/* Spring motion loader keyframes */
@keyframes springUp {
  0% {
    opacity: 0;
    transform: translateY(20px) scale(0.98);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.motion-stagger {
  opacity: 0;
  animation: springUp 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.motion-stagger-1 { animation-delay: 0.04s; }
.motion-stagger-2 { animation-delay: 0.08s; }
.motion-stagger-3 { animation-delay: 0.12s; }
.motion-stagger-4 { animation-delay: 0.16s; }
.motion-stagger-5 { animation-delay: 0.20s; }

/* Spring tap scaling */
.motion-press {
  transition: transform 0.1s cubic-bezier(0.25, 1, 0.5, 1), box-shadow 0.1s ease;
}
.motion-press:active {
  transform: scale(0.97) !important;
}

/* Glassmorphism system card */
.ent-glass-card {
  background: rgba(255, 255, 255, 0.97) !important;
  border: 1px solid #e5e7eb !important;
  box-shadow: 0 8px 32px 0 rgba(146, 26, 29, 0.05), inset 0 0 0 1px rgba(255,255,255,0.4) !important;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
}
@supports (backdrop-filter: blur(1px)) {
  .ent-glass-card {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0.6)) !important;
    backdrop-filter: blur(24px) !important;
    -webkit-backdrop-filter: blur(24px) !important;
    border: 1px solid rgba(255, 255, 255, 0.8) !important;
  }
}
.ent-glass-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 48px rgba(146, 26, 29, 0.08), inset 0 0 0 1px rgba(255,255,255,0.6) !important;
}

/* Focus shadow pulse keyframes */
@keyframes focusPulse {
  0% { box-shadow: 0 0 0 0 rgba(146, 26, 29, 0.4); }
  70% { box-shadow: 0 0 0 6px rgba(146, 26, 29, 0.05); }
  100% { box-shadow: 0 0 0 4px rgba(146, 26, 29, 0.15); }
}

.ent-input:focus, .ent-select:focus {
  animation: focusPulse 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards !important;
}

/* Layout and Flex Grid */
.u-flex-2 { flex: 2 !important; }
.u-grid-3c { grid-template-columns: repeat(3, 1fr) !important; }

/* Widths and Heights */
.u-w-full { width: 100% !important; }
.u-h-lg { height: 48px !important; }

/* Border Radii */
.u-rounded-md { border-radius: 8px !important; }

/* Spacing */
.u-mb-sm { margin-bottom: 0.55rem !important; }
.u-mb-md { margin-bottom: 0.85rem !important; }
.u-mb-lg { margin-bottom: 1rem !important; }
.u-p-xs { padding: 0.35rem !important; }
.u-p-sm { padding: 0.5rem !important; }
.u-p-md { padding: 1rem !important; }

/* Typography formatting */
.u-text-nowrap { white-space: nowrap !important; }
.u-text-xs { font-size: 0.72rem !important; }
.u-text-sm { font-size: 0.78rem !important; }
.u-text-muted-xs { font-size: 0.72rem !important; color: var(--ent-muted) !important; }

.u-text-truncate-sm {
  max-width: 180px !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}
.u-text-truncate-md {
  max-width: 220px !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
}
.u-font-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace !important; }

/* Module codes indicators */
.ent-module-code--primary {
  background: rgba(146, 26, 29, 0.08) !important;
  color: var(--ent-teal) !important;
}

/* Large inputs / buttons */
.ent-input--large {
  height: 42px !important;
  border-radius: 8px !important;
}
.ent-select--large {
  height: 42px !important;
  border-radius: 8px !important;
}
.ent-btn--large {
  height: 42px !important;
  border-radius: 8px !important;
  font-size: 0.9rem !important;
  padding: 0 1.25rem !important;
  display: inline-flex !important;
  align-items: center !important;
}
.ent-btn--full-large {
  width: 100% !important;
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
}

/* Custom header mark background */
.ent-side-mark-gradient {
  background: linear-gradient(135deg, var(--ent-teal) 0%, #e63946 100%) !important;
}

/* Dashboard KPI Values & Glows */
.ent-kpi-value--accent {
  font-size: 2.2rem !important;
  font-weight: 700 !important;
  color: var(--ent-teal) !important;
  line-height: 1.1;
  margin-top: 0.25rem;
}

/* Utility formatting */
.u-text-center { text-align: center !important; }
.u-text-right { text-align: right !important; }
.u-text-truncate-sm {
  max-width: 150px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.u-text-sm { font-size: 0.85rem !important; }
.u-text-lg { font-size: 1.1rem !important; }
.u-text-xl { font-size: 1.4rem !important; }
.u-fw-bold { font-weight: 700 !important; }
.u-fw-semibold { font-weight: 600 !important; }
.u-text-danger { color: var(--ent-coral) !important; }
.u-text-success { color: var(--ent-ok) !important; }

/* Premium visual typography */
.mc-text-gradient {
  background: linear-gradient(135deg, var(--ent-ink) 0%, var(--ent-teal) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: inline-block;
}
@media (forced-colors: active) {
  .mc-text-gradient,
  .ent-kpi-value--accent {
    -webkit-text-fill-color: ButtonText !important;
    background: none !important;
    color: ButtonText !important;
  }
}

/* Print Styles */
@media print {
  .ent-sidebar, .ent-toolbar, .mc-hide-print, .ent-topbar {
    display: none !important;
  }
  .ent-body {
    background: #fff !important;
  }
  .ent-panel, .ent-glass-card {
    border: none !important;
    box-shadow: none !important;
    filter: none !important;
    background: transparent !important;
    margin-bottom: 2rem !important;
    page-break-inside: avoid;
  }
  .ent-main {
    margin-left: 0 !important;
    padding: 0 !important;
  }
  .ent-table {
    border-collapse: collapse !important;
  }
  .ent-table th, .ent-table td {
    border: 1px solid #ccc !important;
  }
  @page { margin: 1cm; }
}

.ent-kpi-icon-glow {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(146, 26, 29, 0.08);
  color: var(--ent-teal);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  box-shadow: 0 4px 10px rgba(146, 26, 29, 0.06);
}

/* Status Badges */
.ent-badge--admitted {
  background: rgba(146, 26, 29, 0.09) !important;
  color: var(--ent-teal) !important;
  font-weight: 700 !important;
}

.ent-badge--discharged {
  background: rgba(31, 122, 77, 0.09) !important;
  color: var(--ent-ok) !important;
  font-weight: 700 !important;
}

/* Ratio Bar indicator */
.ent-ratio-bar {
  height: 6px;
  background: #edd6d6;
  border-radius: 3px;
  overflow: hidden;
  display: flex;
  margin: 0.75rem 0;
}
.ent-ratio-bar--segment {
  height: 100%;
}
.ent-ratio-bar--admitted { background: var(--ent-teal); }
.ent-ratio-bar--discharged { background: var(--ent-ok); }

/* Table hover highlighting */
.ent-table tbody tr {
  transition: background-color 0.2s ease, transform 0.2s ease;
}
.ent-table tbody tr:hover {
  background-color: rgba(146, 26, 29, 0.02) !important;
  transform: translateX(2px);
}

/* Pulsing Status Dot */
.status-dot-pulse {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--ent-ok);
  box-shadow: 0 0 0 0 rgba(31, 122, 77, 0.4);
  animation: pulseDot 2s infinite;
  margin-right: 0.5rem;
  vertical-align: middle;
}
@keyframes pulseDot {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(31, 122, 77, 0.5);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 6px rgba(31, 122, 77, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(31, 122, 77, 0);
  }
}

/* Chart toggle buttons */
.btn-sm {
  padding: 0.25rem 0.65rem !important;
  font-size: 0.75rem !important;
  height: auto !important;
  border-radius: 6px !important;
}
.ent-btn--ghost.active {
  background: var(--ent-teal) !important;
  color: #fff !important;
  border-color: var(--ent-teal) !important;
}

/* ── Doctor Queue: Progress Ring ─────────────────────────────── */
.ent-queue-hero {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding: 1.25rem 1.5rem;
  background: var(--ent-panel);
  border: 1px solid var(--ent-line-soft);
  border-radius: var(--ent-radius-lg);
  box-shadow: var(--ent-shadow-md);
  margin-bottom: 1rem;
  flex-wrap: wrap;
}
.ent-ring-wrap {
  position: relative;
  width: 130px;
  height: 130px;
  flex-shrink: 0;
}
.ent-ring-svg {
  width: 130px;
  height: 130px;
  transform: rotate(-90deg);
}
.ent-ring-track {
  fill: none;
  stroke: rgba(146, 26, 29, 0.08);
  stroke-width: 10;
}
.ent-ring-fill {
  fill: none;
  stroke: var(--ent-teal);
  stroke-width: 10;
  stroke-linecap: round;
  transition: stroke-dashoffset 1.2s cubic-bezier(0.4,0,0.2,1);
}
.ent-ring-fill--amber { stroke: var(--ent-amber) !important; }
.ent-ring-fill--green { stroke: var(--ent-ok) !important; }
.ent-ring-text {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  pointer-events: none;
}
.ent-ring-fraction {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--ent-ink);
  line-height: 1;
}
.ent-ring-label {
  font-size: 0.62rem;
  color: var(--ent-muted);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-top: 0.2rem;
}
.ent-queue-meta {
  flex: 1;
  min-width: 0;
}
.ent-queue-doctor {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--ent-ink);
  margin: 0 0 0.3rem;
}
.ent-queue-specialty {
  font-size: 0.78rem;
  color: var(--ent-muted);
  margin-bottom: 0.75rem;
}
.ent-queue-stats {
  display: flex;
  gap: 1.25rem;
  flex-wrap: wrap;
}
.ent-queue-stat {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}
.ent-queue-stat-num {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--ent-teal);
  line-height: 1;
}
.ent-queue-stat-lbl {
  font-size: 0.68rem;
  color: var(--ent-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ── Efficiency Badge ─────────────────────────────────────────── */
.ent-efficiency {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  background: rgba(146, 26, 29, 0.08);
  color: var(--ent-teal);
}
.ent-efficiency--amber { background: rgba(196, 139, 42, 0.1) !important; color: var(--ent-amber) !important; }
.ent-efficiency--green { background: rgba(31, 122, 77, 0.1) !important; color: var(--ent-ok) !important; }

/* ── Wait-Time Badges ─────────────────────────────────────────── */
.wait-badge {
  display: inline-block;
  padding: 0.18rem 0.55rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
}
.wait-badge--ok  { background: rgba(31,122,77,0.1);  color: var(--ent-ok); }
.wait-badge--warn { background: rgba(196,139,42,0.12); color: var(--ent-amber); }
.wait-badge--bad  { background: rgba(146,26,29,0.1);  color: var(--ent-teal); }

/* ── Complaint Tags ───────────────────────────────────────────── */
.ent-complaint-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding: 0.6rem 0.85rem;
  border-bottom: 1px solid var(--ent-line-soft);
}
.ent-ctag {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, transform 0.15s;
  background: rgba(146,26,29,0.07);
  color: var(--ent-teal);
  border: 1px solid rgba(146,26,29,0.15);
  user-select: none;
}
.ent-ctag:hover { background: rgba(146,26,29,0.15); transform: translateY(-1px); }
.ent-ctag.active { background: var(--ent-teal); color: #fff; border-color: var(--ent-teal); }
.ent-ctag-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: rgba(0,0,0,0.12);
  font-size: 0.62rem;
  margin-left: 0.25rem;
}
/* highlighted row from tag filter */
.ent-table tbody tr.row-dim { opacity: 0.25; }
.ent-table tbody tr.row-highlight { background: rgba(146,26,29,0.04) !important; }

/* ── Auto-Refresh Pill ────────────────────────────────────────── */
.ent-refresh-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.25rem 0.7rem;
  border-radius: 999px;
  border: 1px solid var(--ent-line);
  background: #fff;
  font-size: 0.72rem;
  color: var(--ent-muted);
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
  white-space: nowrap;
}
.ent-refresh-pill:hover { border-color: var(--ent-teal); color: var(--ent-teal); }
.ent-refresh-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--ent-ok);
  animation: pulseDot 2s infinite;
}

/* ── Chart panels ─────────────────────────────────────────────── */
.ent-chart-panel {
  height: 190px;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  position: relative;
}

@media (max-width: 991.98px) {
  .ent-queue-hero { gap: 1rem; padding: 1rem; }
  .ent-ring-wrap { width: 100px; height: 100px; }
  .ent-ring-svg  { width: 100px; height: 100px; }
  .ent-ring-fraction { font-size: 1.15rem; }
  .ent-queue-doctor { font-size: 1rem; }
  .ent-queue-stats { gap: 0.75rem; }
}


/* ── Audit table sticky first column ─────────────────────────── */
.ent-table--sticky-first th:first-child,
.ent-table--sticky-first td:first-child {
  position: sticky;
  left: 0;
  background: #f7fafc;
  z-index: 1;
  box-shadow: 2px 0 4px rgba(0, 0, 0, 0.05);
}

/* Global Loader Overlay */
.ent-loader-overlay {
  position: fixed;
  inset: 0;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.ent-loader-overlay.is-loading {
  opacity: 1;
  pointer-events: auto;
}

.ent-spinner {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 4px solid rgba(146, 26, 29, 0.2);
  border-top-color: var(--ent-teal);
  background: radial-gradient(circle, rgba(146, 26, 29, 0.1) 0%, transparent 60%);
  animation: ent-spin 1.2s linear infinite;
}

@keyframes ent-spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}
