/* ==========================================================================
   XYZ HMS - custom additions on top of ki-admin
   ========================================================================== */

:root {
    --hms-primary: #6961e6;
    --hms-side: 260px;
}

body {
    font-size: 14px;
}

.app-nav .main-nav > li > a {
    font-size: 14px;
}

.app-nav .main-nav > li.active > a {
    background: var(--hms-primary);
    color: #fff !important;
}

.app-nav .main-nav > li > a i {
    width: 22px;
}

/* Receptionist OPD status filters. */
.opd-status-tabs {
    position: static;
    width: 100%;
    height: auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: .25rem;
    padding: .3rem;
    background: #e8ecea;
    box-shadow: none;
    z-index: auto;
}

.opd-status-counters {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: .85rem;
}

/* OPD dashboard: clear hierarchy and calm clinical colors. */
#opd-status-content {
    --opd-ink: #173b4a;
    --opd-muted: #718392;
    --opd-line: #e4ebf0;
    color: var(--opd-ink);
}

#opd-status-content .page-head {
    margin: .4rem 0 1.25rem;
    padding: 1.15rem 1.35rem;
    border: 1px solid var(--opd-line);
    border-left: 4px solid #178b87;
    border-radius: 12px;
    background: linear-gradient(110deg, #fff 0%, #f6fbfb 100%);
}

#opd-status-content .page-head h3 {
    color: var(--opd-ink);
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: -.02em;
}

#opd-status-content .page-head p {
    margin-top: .3rem;
    color: var(--opd-muted);
    font-size: .88rem;
}

#opd-status-content .opd-status-counters .stat-card {
    min-height: 96px;
    padding: 1rem 1.05rem;
    border: 1px solid var(--opd-line);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(29, 58, 75, .035);
    transition: transform .16s ease, box-shadow .16s ease;
}

#opd-status-content .opd-status-counters .stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(29, 58, 75, .08);
}

#opd-status-content .opd-status-counters .stat-card.accent {
    border-color: #f3dfb2;
    background: #fffaf0;
}

#opd-status-content .opd-status-counters .stat-value {
    color: var(--opd-ink);
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.15;
}

#opd-status-content .opd-status-counters .stat-label {
    margin-top: .4rem;
    color: var(--opd-muted);
    font-size: .78rem;
    font-weight: 600;
    line-height: 1.3;
}

#opd-status-content > .card {
    overflow: hidden;
    border: 1px solid var(--opd-line);
    border-radius: 12px;
    box-shadow: 0 3px 14px rgba(29, 58, 75, .045);
}

#opd-status-content > .card .card-body { padding: 1.1rem; }
#opd-status-content .form-label { color: #445b69; font-size: .78rem; font-weight: 600; }
#opd-status-content .form-control,
#opd-status-content .form-select { min-height: 42px; border-color: #dce5ea; border-radius: 8px; }

.opd-status-tabs {
    justify-content: flex-start;
    gap: .45rem;
    padding: .35rem 0 0;
    background: transparent;
}

.opd-status-tab {
    min-height: 42px;
    flex: 0 0 auto;
    gap: .45rem;
    padding: .55rem .75rem;
    border-color: var(--opd-line);
    border-radius: 8px;
    color: #536877;
    font-size: .75rem;
    font-weight: 600;
    letter-spacing: 0;
    text-transform: none;
    transition: color .15s ease, border-color .15s ease, background .15s ease;
}

.opd-status-tab.active {
    color: #fff;
    border-color: #147f7b;
    background: #147f7b;
    box-shadow: 0 3px 8px rgba(20, 127, 123, .18);
}

.opd-status-tab:hover:not(.active) { color: #147f7b; border-color: #a9cfcc; background: #f4fbfa; }
.opd-status-tab .opd-status-count { background: rgba(23, 59, 74, .07); }
.opd-status-tab.active .opd-status-count { background: rgba(255, 255, 255, .2); }

/* Reception appointments page */
.appointments-page-head {
    margin: .4rem 0 1rem;
    padding: 1rem 1.2rem;
    border: 1px solid #e4ebf0;
    border-left: 4px solid #147f7b;
    border-radius: 12px;
    background: linear-gradient(105deg, #fff 0%, #f6fbfb 100%);
    box-shadow: 0 3px 12px rgba(29, 58, 75, .045);
}

.appointments-page-head h3 { color: #173b4a; font-weight: 700; letter-spacing: -.015em; }
.appointments-page-head p { margin-top: .3rem; color: #718392; font-size: .86rem; }
.appointments-page-head .btn { min-height: 44px; padding: .65rem 1rem; border-radius: 8px; font-weight: 600; }

.appointment-stat-grid {
    grid-template-columns: repeat(auto-fit, minmax(135px, 1fr));
    gap: .75rem;
    margin-bottom: 1rem;
}

.appointment-stat-grid .stat-card {
    min-height: 88px;
    padding: .9rem 1rem;
    border: 1px solid #e4ebf0;
    border-radius: 11px;
    background: #fff;
    box-shadow: 0 3px 10px rgba(29, 58, 75, .045);
}

.appointment-stat-grid .stat-card.accent { border-color: #cce6e3; background: #f3faf9; }
.appointment-stat-grid .stat-value { color: #173b4a; font-size: 1.55rem; font-weight: 750; }
.appointment-stat-grid .stat-label { margin-top: .3rem; color: #718392; font-size: .77rem; font-weight: 600; }

.appointment-filter-card {
    overflow: hidden;
    border: 1px solid #e4ebf0;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 4px 15px rgba(29, 58, 75, .05);
}

.appointment-filter-card > .card-header { padding: 1rem 1.2rem; border-bottom: 1px solid #edf1f4; }
.appointment-filter-card .form-label { color: #445b69; font-size: .78rem; font-weight: 650; }
.appointment-filter-card .form-control,
.appointment-filter-card .form-select { min-height: 42px; border-color: #dce5ea; border-radius: 8px; }
.appointment-table thead th { padding: .8rem .75rem; background: #f5f8fa; color: #687d8a; font-size: .7rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
.appointment-table tbody td { padding: .8rem .75rem; border-color: #edf1f4; vertical-align: middle; }
.appointment-table tbody tr:hover { background: #f8fbfc; }

.patient-search-autocomplete { position: relative; z-index: 12; }

.patient-search-suggestions {
    position: absolute;
    top: calc(100% + .35rem);
    right: 0;
    left: 0;
    z-index: 1200;
    max-height: 280px;
    margin-top: .35rem;
    overflow-y: auto;
    border: 1px solid #dce5ea;
    border-radius: 9px;
    background: #fff;
    box-shadow: 0 10px 24px rgba(29, 58, 75, .12);
}

.patient-search-suggestion {
    display: flex;
    width: 100%;
    flex-direction: column;
    align-items: flex-start;
    gap: .15rem;
    padding: .65rem .85rem;
    border: 0;
    border-bottom: 1px solid #edf1f4;
    background: #fff;
    color: #173b4a;
    text-align: left;
}

.patient-search-suggestion:last-child { border-bottom: 0; }
.patient-search-suggestion:hover,
.patient-search-suggestion:focus-visible { background: #f2f9f8; outline: 0; }
.patient-search-suggestion-name { font-size: .87rem; font-weight: 650; }
.patient-search-suggestion-detail { color: #718392; font-size: .75rem; }

.ipd-patient-empty {
    display: flex;
    min-height: 46px;
    align-items: center;
    border-color: #dce5ea;
    background: #f7fafb;
    color: #718392;
}

.ipd-admit-disabled:disabled {
    border-color: #dce5ea;
    background: #e9eef1;
    color: #718392;
    cursor: not-allowed;
    opacity: 1;
}

@media (max-width: 575.98px) {
    .appointments-page-head { align-items: flex-start; padding: .9rem 1rem; }
    .appointment-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
    .appointment-stat-grid .stat-card { min-height: 78px; padding: .75rem; }
    .appointment-filter-card > .card-header { padding: .85rem; }
}

/* Shared invoice styling: pharmacy-inspired violet, lilac and clean paper. */
.invoice-sheet {
    --invoice-purple: #7137a8;
    --invoice-ink: #30233c;
    position: relative;
    overflow: hidden;
    border: 1px solid #eadcf4;
    border-radius: 14px;
    padding: 1.5rem;
    background: linear-gradient(145deg, #fff 0%, #fff 78%, #fbf6ff 100%);
    box-shadow: 0 12px 32px rgba(67, 34, 91, .09);
    color: var(--invoice-ink);
}
.invoice-sheet::before {
    content: "";
    display: block;
    height: 6px;
    position: absolute;
    inset: 0 0 auto;
    background: linear-gradient(90deg, #7137a8, #bd83d9 72%, #a3c9a1);
}
.invoice-sheet .report-head { border-bottom: 1px solid #eadcf4; padding-bottom: 1rem; }
.invoice-sheet .report-head h3 { color: var(--invoice-purple); font-weight: 800; letter-spacing: .02em; }
.invoice-sheet .table { --bs-table-striped-bg: #fbf7fd; }
.invoice-sheet .table thead th { color: #63338d; background: #f2e9f8; border-color: #e5d5ef; }
.invoice-sheet .table td, .invoice-sheet .table th { border-color: #eee4f3; }
.invoice-sheet .table tfoot tr.table-active td { background: #7137a8; color: #fff; border-color: #7137a8; }
.receipt-sheet { border-top: 6px solid #7137a8; }

.invoice-page ~ .patient-banner,
.invoice-page ~ .card,
.invoice-page ~ .row .card { border-color: #eadcf4; box-shadow: 0 7px 22px rgba(67, 34, 91, .06); }
.invoice-page ~ .patient-banner { background: linear-gradient(120deg, #67339b, #8e55b5 72%, #a979c8); }
.invoice-page ~ .card .card-header { border-bottom-color: #eadcf4; }
.invoice-page ~ .card .table thead th,
.invoice-page ~ .row .card .table thead th { background: #f4edf8; color: #63338d; }
.invoice-page ~ .row .card .table tbody tr:hover { --bs-table-hover-bg: #fbf7fd; }
.invoice-page ~ .card .mini-label,
.invoice-page ~ .row .card .mini-label { color: #80559e; }

#opd-status-content .opd-status-table thead th {
    padding-top: .85rem;
    padding-bottom: .85rem;
    background: #f5f8fa;
    color: #687d8a;
    font-size: .68rem;
    letter-spacing: .045em;
}

#opd-status-content .opd-status-table tbody tr:hover { background: #f8fbfc; }
#opd-status-content .opd-status-table tbody td { border-color: #edf1f4; }

@media (max-width: 575.98px) {
    #opd-status-content .page-head { padding: .95rem 1rem; }
    #opd-status-content .opd-status-counters { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
    #opd-status-content .opd-status-counters .stat-card { min-height: 84px; padding: .8rem; }
    .opd-status-tabs { overflow-x: auto; flex-wrap: nowrap; justify-content: flex-start; padding-bottom: .4rem; }
}

/* Reception dashboard metrics styled after the colorful compact-card reference. */
.hms-dashboard-stats > div > a { display: block; height: 100%; }

/* Keep dashboard content in one full-width column across every role. */
.hms-dashboard-stack {
    display: flex;
    flex-direction: column;
}

.hms-dashboard-stack > [class*="col-"] {
    flex: 0 0 100%;
    width: 100%;
    max-width: 100%;
}

/* Compact horizontal security metrics, matching the dashboard reference. */
.hms-dashboard-security-stats .stat-card {
    min-height: 106px;
    margin-top: 0;
    overflow: hidden;
    border: 1px solid #edf0f4;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 4px 12px rgba(30, 53, 71, .08);
}

.hms-dashboard-security-stats .stat-body {
    min-height: 104px;
    flex-direction: row;
    justify-content: flex-start;
    gap: 1.25rem !important;
    padding: 1rem 1.5rem;
    text-align: left;
}

.hms-dashboard-security-stats .stat-icon {
    position: static;
    flex: 0 0 58px;
    width: 58px;
    height: 58px;
    transform: none;
    border: 0;
    border-radius: 16px;
    box-shadow: none;
    font-size: 1.35rem;
}

.hms-dashboard-security-stats .stat-value {
    color: #123b43;
    font-size: 2rem;
    font-weight: 750;
}

.hms-dashboard-security-stats .stat-label {
    margin-top: .3rem;
    color: #778496;
    font-size: .95rem;
    font-weight: 600;
}

.hms-dashboard-security-stats .stat-card::before { display: none; }
.hms-dashboard-security-stats .stat-card.clickable:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(30, 53, 71, .11);
}

@media (max-width: 575.98px) {
    .hms-dashboard-security-stats .stat-card,
    .hms-dashboard-security-stats .stat-body { min-height: 92px; }
    .hms-dashboard-security-stats .stat-body { padding: .85rem 1rem; gap: 1rem !important; }
    .hms-dashboard-security-stats .stat-icon { flex-basis: 50px; width: 50px; height: 50px; }
}

.hms-dashboard-stats .stat-card {
    min-height: 250px;
    margin-top: .65rem;
    overflow: visible;
    border: 1px solid #e8edf1;
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 5px 18px rgba(30, 53, 71, .08);
    transition: transform .18s ease, box-shadow .18s ease;
}

/* Let each KPI row use its full width, including dashboards with fewer cards. */
.hms-dashboard-stats > [class*="col-"] { flex-grow: 1; }

@media (min-width: 1200px) {
    .hms-dashboard-stats > [class*="col-"] {
        flex-basis: 16.6667%;
        max-width: none;
    }
}

@media (min-width: 576px) and (max-width: 1199.98px) {
    .hms-dashboard-stats > [class*="col-"] {
        flex-basis: 33.3333%;
        max-width: none;
    }
}

@media (max-width: 575.98px) {
    .hms-dashboard-stats > [class*="col-"] {
        flex-basis: 50%;
        max-width: none;
    }
}

.hms-dashboard-stats .stat-card::before {
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 124px;
    border-radius: 15px 15px 50% 50%;
    background: radial-gradient(ellipse at 50% 0%, rgba(20, 127, 123, .13) 0 45%, rgba(20, 127, 123, .07) 46% 72%, transparent 73%);
    content: "";
    pointer-events: none;
}

.hms-dashboard-stats .stat-card.clickable:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 25px rgba(30, 53, 71, .13);
}

.hms-dashboard-stats .stat-body {
    position: relative;
    min-height: 248px;
    flex-direction: column;
    justify-content: center;
    gap: .35rem !important;
    padding: 4.4rem 1rem 1.1rem;
    text-align: center;
}

.hms-dashboard-stats .stat-icon {
    position: absolute;
    position: absolute;
    top: -1.05rem;
    left: 50%;
    width: 62px;
    height: 62px;
    transform: translateX(-50%);
    border: 4px solid #fff;
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(30, 53, 71, .16);
    font-size: 1.5rem;
}

.hms-dashboard-stats .stat-value {
    color: #147f7b;
    font-size: clamp(1.8rem, 2.2vw, 2.35rem);
    font-weight: 750;
    line-height: 1.1;
}

.hms-dashboard-stats .stat-label {
    max-width: 100%;
    margin-top: .35rem;
    color: #405665;
    font-size: .98rem;
    font-weight: 650;
    line-height: 1.3;
}

.hms-dashboard-stats > div:nth-child(6n + 2) .stat-card::before { background: radial-gradient(ellipse at 50% 0%, rgba(228, 71, 89, .14) 0 45%, rgba(228, 71, 89, .07) 46% 72%, transparent 73%); }
.hms-dashboard-stats > div:nth-child(6n + 2) .stat-value { color: #e44759; }
.hms-dashboard-stats > div:nth-child(6n + 3) .stat-card::before { background: radial-gradient(ellipse at 50% 0%, rgba(246, 177, 25, .17) 0 45%, rgba(246, 177, 25, .08) 46% 72%, transparent 73%); }
.hms-dashboard-stats > div:nth-child(6n + 3) .stat-value { color: #e5a20d; }
.hms-dashboard-stats > div:nth-child(6n + 4) .stat-card::before { background: radial-gradient(ellipse at 50% 0%, rgba(0, 174, 105, .14) 0 45%, rgba(0, 174, 105, .07) 46% 72%, transparent 73%); }
.hms-dashboard-stats > div:nth-child(6n + 4) .stat-value { color: #00a969; }

@media (max-width: 575.98px) {
    .hms-dashboard-stats { row-gap: 1rem !important; }
    .hms-dashboard-stats .stat-card,
    .hms-dashboard-stats .stat-body { min-height: 220px; }
}

.opd-status-tab {
    display: inline-flex;
    flex: 1 1 auto;
    min-width: max-content;
    min-height: 58px;
    align-items: center;
    justify-content: center;
    gap: .55rem;
    padding: .65rem .7rem;
    border: 1px solid #d7dcda;
    background: #fff;
    color: #26364a;
    text-decoration: none;
    font-size: .8rem;
    font-weight: 500;
    letter-spacing: .025em;
    text-align: center;
    line-height: 1.25;
    text-transform: uppercase;
    white-space: nowrap;
}

.opd-status-tab > i {
    flex: 0 0 auto;
    font-size: 1.1rem;
}

.opd-status-label {
    min-width: 0;
    white-space: nowrap;
}

.opd-status-tab .opd-status-count {
    min-width: 1.35rem;
    text-align: center;
    padding: .05rem .35rem;
    border-radius: 1rem;
    background: rgba(38, 54, 74, .08);
    font-size: .75rem;
}

.opd-status-tab.active {
    color: #fff;
    border-color: #22bd86;
    background: #22bd86;
    box-shadow: none;
}

.opd-status-tab.active .opd-status-count {
    color: #fff;
    background: rgba(255, 255, 255, .2);
}

.opd-status-tab:hover {
    color: var(--hms-primary);
    border-color: #bfc8c4;
    background: #f8faf9;
}

.opd-mobile-patient-meta { display: none; }
.opd-status-table { width: 100%; table-layout: fixed; font-size: .875rem; }
.opd-status-table th, .opd-status-table td { overflow-wrap: anywhere; padding: .7rem .55rem; }
#opd-status-content { position: relative; }
.opd-loading-overlay {
    position: absolute;
    inset: 0;
    z-index: 20;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: .65rem;
    padding: 2rem 1rem;
    background: rgba(255, 255, 255, .78);
    color: #174b52;
    font-weight: 600;
}
.opd-loading-spinner {
    width: 1.25rem;
    height: 1.25rem;
    border: 3px solid #d7e7e8;
    border-top-color: #11666f;
    border-radius: 50%;
    animation: opd-loading-spin .7s linear infinite;
}
@keyframes opd-loading-spin { to { transform: rotate(360deg); } }

@media (max-width: 991.98px) {
    .opd-status-tab { flex: 1 1 auto; min-height: 54px; }
    .opd-hide-mobile, .opd-hide-wide { display: none; }
    .opd-mobile-patient-meta { display: block; }
    .opd-status-table { font-size: .8rem; }
    .opd-status-table th, .opd-status-table td { padding: .55rem .35rem; }
}

/* ---------- page heading ---------- */
.page-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: .75rem;
    margin: 1.25rem 0;
}

.page-head h3 {
    font-size: 1.35rem;
    font-weight: 600;
    margin: 0;
}

.page-head p {
    color: #8a8f9c;
    font-size: .82rem;
    margin: 2px 0 0;
}

/* Shared heading treatment keeps every role dashboard visually aligned. */
.hms-dashboard-head {
    min-height: 82px;
    margin: .35rem 0 1rem;
    padding: 1rem 1.2rem;
    border: 1px solid #e4ebf0;
    border-left: 4px solid #147f7b;
    border-radius: 12px;
    background: linear-gradient(105deg, #fff 0%, #f7fbfb 100%);
    box-shadow: 0 3px 12px rgba(29, 58, 75, .045);
}

.hms-dashboard-head h3 {
    color: #173b4a;
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -.015em;
}

.hms-dashboard-head p {
    margin-top: .3rem;
    color: #718392;
    font-size: .84rem;
}

@media (max-width: 575.98px) {
    .hms-dashboard-head { padding: .85rem 1rem; }
    .hms-dashboard-head .btn { font-size: .78rem; }
}

/* ---------- stat cards ---------- */
.stat-card {
    border-radius: 14px;
    overflow: hidden;
    position: relative;
}

.stat-card .stat-body {
    padding: 1.1rem 1.25rem;
}

.stat-card .stat-value {
    font-size: 1.6rem;
    font-weight: 700;
    line-height: 1.1;
    margin: 0;
}

.stat-card .stat-label {
    color: #8a8f9c;
    font-size: .78rem;
    font-weight: 500;
    margin: 2px 0 0;
}

.stat-card .stat-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}

.stat-card.clickable {
    cursor: pointer;
    transition: transform .15s ease, box-shadow .15s ease;
}

.stat-card.clickable:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(0, 0, 0, .08);
}

/* ---------- tables ---------- */
.table-hms {
    font-size: .83rem;
}

.table-hms thead th {
    text-transform: uppercase;
    font-size: .7rem;
    letter-spacing: .04em;
    color: #8a8f9c;
    font-weight: 600;
    white-space: nowrap;
    background: #f7f8fb;
}

.table-hms tbody td {
    vertical-align: middle;
}

.table-hms tfoot td {
    font-weight: 600;
    background: #f7f8fb;
}

.table-hover tbody tr:hover {
    background: #f8f9ff;
}

.clickable-row {
    cursor: pointer;
}

/* ---------- filter bar ---------- */
.filter-bar {
    background: #fff;
    border-radius: 14px;
    padding: .85rem 1rem;
    margin-bottom: 1rem;
    border: 1px solid #f0f1f5;
}

/* ---------- workflow stepper ---------- */
.flow-step {
    display: flex;
    align-items: center;
    gap: .5rem;
    font-size: .75rem;
    color: #8a8f9c;
}

.flow-step .dot {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eef0f5;
    color: #8a8f9c;
    font-size: .7rem;
    font-weight: 600;
}

.flow-step.done .dot {
    background: #1eb36a;
    color: #fff;
}

.flow-step.current .dot {
    background: var(--hms-primary);
    color: #fff;
}

.flow-step.done, .flow-step.current {
    color: #3a3f4b;
    font-weight: 600;
}

/* ---------- patient banner ---------- */
.patient-banner {
    background: linear-gradient(135deg, #6961e6 0%, #8b7ff0 100%);
    border-radius: 16px;
    color: #fff;
    padding: 1.1rem 1.25rem;
}

.patient-banner .uhid-chip {
    background: rgba(255, 255, 255, .18);
    border: 1px solid rgba(255, 255, 255, .25);
    border-radius: 8px;
    padding: 2px 10px;
    font-size: .72rem;
    font-weight: 600;
}

.patient-banner .kv {
    font-size: .78rem;
    opacity: .92;
}
.billing-patient-banner {
    border: 1px solid rgba(13, 103, 109, .2);
    background: linear-gradient(115deg, #0d626b 0%, #117b7b 58%, #258f87 100%);
    box-shadow: 0 8px 22px rgba(13, 98, 107, .16);
}
.billing-patient-banner .uhid-chip {
    color: #fff;
    background: rgba(255, 255, 255, .15);
    border-color: rgba(255, 255, 255, .32);
}
.billing-patient-banner .btn-light,
.billing-patient-banner .btn-white {
    color: #145d65;
    background: #fff;
    border-color: rgba(255, 255, 255, .75);
    font-weight: 600;
}
.billing-patient-banner .btn-light:hover,
.billing-patient-banner .btn-white:hover { color: #104b52; background: #edf8f7; }

/* IPD admission form */
.ipd-admission-page { padding-bottom: 1.5rem; }
.ipd-admission-head { margin-bottom: 1rem; }
.ipd-admission-head h3 { color: #183b4a; font-size: 1.35rem; font-weight: 700; }
.ipd-admission-page > .patient-banner {
    margin-bottom: 1.1rem !important;
    padding: 1.25rem 1.4rem;
    border: 1px solid rgba(91, 91, 214, .12);
    background: linear-gradient(115deg, #514bd0 0%, #7669e8 58%, #877bed 100%);
    box-shadow: 0 8px 22px rgba(74, 71, 174, .16);
}
.ipd-admission-page > .patient-banner .uhid-chip { border-radius: 999px; padding: .28rem .68rem; }
.ipd-admission-page > .patient-banner .kv { gap: .5rem 1.25rem !important; }
.ipd-admission-layout { align-items: flex-start; }
.ipd-form-card, .ipd-action-card {
    overflow: hidden;
    border: 1px solid #e8edf2;
    border-radius: 14px;
    box-shadow: 0 4px 14px rgba(26, 54, 75, .06);
}
.ipd-form-card .card-header {
    display: flex;
    align-items: center;
    gap: .8rem;
    min-height: 68px;
    padding: .9rem 1.25rem;
    border-bottom: 1px solid #edf0f4;
    background: #fff;
}
.ipd-form-card .card-header h5 { color: #254454; font-size: 1rem; font-weight: 700; }
.ipd-form-card .card-header small { display: block; margin-top: .18rem; color: #8794a2; font-size: .75rem; }
.ipd-section-icon {
    display: inline-flex;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    background: #eaf5f5;
    color: #126b70;
    font-size: 1.15rem;
}
.ipd-form-card .card-body { padding: 1.25rem; }
.ipd-admission-page .form-label { margin-bottom: .42rem; color: #425667; font-size: .82rem; font-weight: 600; }
.ipd-admission-page .form-control, .ipd-admission-page .form-select {
    min-height: 42px;
    border-color: #dce4eb;
    border-radius: 8px;
    color: #263d4d;
    font-size: .88rem;
}
.ipd-admission-page .form-control:focus, .ipd-admission-page .form-select:focus {
    border-color: #348e91;
    box-shadow: 0 0 0 .2rem rgba(20, 127, 123, .12);
}
.ipd-admission-page .ipd-action-card { position: sticky; top: 1rem; }
.ipd-action-card .card-body { padding: 1rem; }
.ipd-action-card .btn { min-height: 43px; border-radius: 8px; font-weight: 600; }
.ipd-action-card .btn-primary { box-shadow: 0 4px 10px rgba(20, 127, 123, .2); }

/* Dashboard metrics use the same compact, structured card language as IPD. */
.hms-dashboard-stats { align-items: stretch; }
.hms-dashboard-stats .stat-card {
    min-height: 112px;
    margin-top: 0;
    overflow: hidden;
    border: 1px solid #e7edf2;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 4px 14px rgba(26, 54, 75, .06);
}
.hms-dashboard-stats .stat-card::before { display: none; }
.hms-dashboard-stats .stat-body {
    min-height: 110px;
    flex-direction: row;
    justify-content: flex-start;
    gap: .9rem !important;
    padding: 1rem;
    text-align: left;
}
.hms-dashboard-stats .stat-icon {
    position: static;
    flex: 0 0 48px;
    width: 48px;
    height: 48px;
    transform: none;
    border: 0;
    border-radius: 13px;
    box-shadow: none;
    font-size: 1.25rem;
}
.hms-dashboard-stats .stat-value { color: #173d49; font-size: 1.65rem; font-weight: 750; }
.hms-dashboard-stats .stat-label { margin-top: .25rem; color: #778694; font-size: .82rem; font-weight: 600; }
.hms-dashboard-stats .stat-card.clickable:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(26, 54, 75, .1); }
.hms-dashboard-security-stats { margin-top: .5rem !important; }
.hms-dashboard-security-stats .stat-card { border-radius: 14px; }
.hms-dashboard-security-stats .stat-icon { border-radius: 13px; }

/* Restore the Superadmin dashboard's Bootstrap column layout. */
.hms-dashboard-head ~ .hms-dashboard-stack {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
}
.hms-dashboard-head ~ .hms-dashboard-stack.hms-dashboard-security-stats > [class*="col-"] {
    flex: 0 0 50%;
    width: 50%;
    max-width: 50%;
}
@media (min-width: 768px) {
    .hms-dashboard-head ~ .hms-dashboard-stack.hms-dashboard-security-stats > [class*="col-"] {
        flex-basis: 33.3333%;
        width: 33.3333%;
        max-width: 33.3333%;
    }
}
.hms-dashboard-head ~ .hms-dashboard-stack:not(.hms-dashboard-security-stats) > .col-lg-8 {
    flex: 0 0 66.6667%;
    width: 66.6667%;
    max-width: 66.6667%;
}
.hms-dashboard-head ~ .hms-dashboard-stack:not(.hms-dashboard-security-stats) > .col-lg-4 {
    flex: 0 0 33.3333%;
    width: 33.3333%;
    max-width: 33.3333%;
}
@media (max-width: 991.98px) {
    .hms-dashboard-head ~ .hms-dashboard-stack:not(.hms-dashboard-security-stats) > [class*="col-"] {
        flex: 0 0 100%;
        width: 100%;
        max-width: 100%;
    }
}

/* Material inspired treatment for the doctor workspace. */
.doctor-dashboard-head {
    min-height: 112px;
    align-content: center;
    border: 1px solid #dfe7eb;
    border-left: 4px solid #008577;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(24, 50, 62, .05);
}
.doctor-dashboard-head h3 { color: #153b4a; font-size: 1.45rem; letter-spacing: -.025em; }
.doctor-dashboard-head p { color: #637987; font-size: .9rem; }
.doctor-dashboard-head ~ .hms-dashboard-stats .stat-card {
    min-height: 122px;
    border-color: #e3eaee;
    border-radius: 18px;
    box-shadow: 0 2px 7px rgba(20, 49, 61, .045), 0 8px 18px rgba(20, 49, 61, .035);
}
.doctor-dashboard-head ~ .hms-dashboard-stats .stat-body { min-height: 120px; padding: 1.15rem; }
.doctor-dashboard-head ~ .hms-dashboard-stats .stat-icon { border-radius: 14px; }
.doctor-dashboard-head ~ .hms-dashboard-stats .stat-card.clickable:hover {
    transform: translateY(-3px);
    border-color: #b7d8d4;
    box-shadow: 0 5px 12px rgba(20, 49, 61, .07), 0 12px 24px rgba(20, 49, 61, .08);
}
.doctor-dashboard-head ~ .hms-dashboard-stack .card {
    overflow: hidden;
    border: 1px solid #e1e8ec;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(20, 49, 61, .045);
}
.doctor-dashboard-head ~ .hms-dashboard-stack .card-header {
    min-height: 60px;
    padding: 1rem 1.2rem;
    border-bottom: 1px solid #edf1f3;
}
.doctor-dashboard-head ~ .hms-dashboard-stack .card-header h5 {
    color: #203f4c;
    font-size: 1rem;
    font-weight: 700;
}
.doctor-dashboard-head ~ .hms-dashboard-stack .table thead th {
    padding-top: .8rem;
    padding-bottom: .8rem;
    background: #f6f9fa;
    color: #71838d;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .045em;
    text-transform: uppercase;
}
.doctor-dashboard-head ~ .hms-dashboard-stack .table td { padding-top: .82rem; padding-bottom: .82rem; }
.doctor-dashboard-head ~ .hms-dashboard-stack .card-header .btn,
.doctor-dashboard-head ~ .hms-dashboard-stack .card-body > .d-flex .btn { border-radius: 10px; font-weight: 600; }

/* Material inspired treatment for the pharmacist workspace. */
.pharmacist-dashboard-head {
    min-height: 112px;
    align-content: center;
    border: 1px solid #dfe7eb;
    border-left: 4px solid #008577;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(24, 50, 62, .05);
}
.pharmacist-dashboard-head h3 { color: #153b4a; font-size: 1.45rem; letter-spacing: -.025em; }
.pharmacist-dashboard-head p { color: #637987; font-size: .9rem; }
.pharmacist-dashboard-head ~ .hms-dashboard-stats .stat-card {
    min-height: 122px;
    border: 1px solid #e3eaee;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 2px 7px rgba(20, 49, 61, .045), 0 8px 18px rgba(20, 49, 61, .035);
}
.pharmacist-dashboard-head ~ .hms-dashboard-stats .stat-body { min-height: 120px; padding: 1.15rem; }
.pharmacist-dashboard-head ~ .hms-dashboard-stats .stat-icon { border-radius: 14px; }
.pharmacist-dashboard-head ~ .hms-dashboard-stats .stat-card.clickable { transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.pharmacist-dashboard-head ~ .hms-dashboard-stats .stat-card.clickable:hover {
    transform: translateY(-3px);
    border-color: #b7d8d4;
    box-shadow: 0 5px 12px rgba(20, 49, 61, .07), 0 12px 24px rgba(20, 49, 61, .08);
}
.pharmacist-dashboard-head ~ .hms-dashboard-stack .card {
    overflow: hidden;
    border: 1px solid #e1e8ec;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 2px 8px rgba(20, 49, 61, .045);
}
.pharmacist-dashboard-head ~ .hms-dashboard-stack .card-header { min-height: 60px; padding: 1rem 1.2rem; border-bottom: 1px solid #edf1f3; }
.pharmacist-dashboard-head ~ .hms-dashboard-stack .card-header h5 { color: #203f4c; font-size: 1rem; font-weight: 700; }
.pharmacist-dashboard-head ~ .hms-dashboard-stack .table thead th {
    padding-top: .8rem;
    padding-bottom: .8rem;
    background: #f6f9fa;
    color: #71838d;
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .045em;
    text-transform: uppercase;
}
.pharmacist-dashboard-head ~ .hms-dashboard-stack .table td { padding-top: .82rem; padding-bottom: .82rem; }
.pharmacist-dashboard-head ~ .hms-dashboard-stack .card-header .btn { border-radius: 10px; font-weight: 600; }
@media (min-width: 1200px) {
    .pharmacist-dashboard-head ~ .hms-dashboard-stats > [class*="col-"] { flex: 0 0 20%; max-width: 20%; }
}

@media (min-width: 1200px) {
    .hms-dashboard-stats > [class*="col-"] { flex-basis: 16.6667%; }
}
@media (max-width: 767.98px) {
    .hms-dashboard-stats > [class*="col-"] { flex-basis: 50%; }
}
@media (max-width: 575.98px) {
    .hms-dashboard-stats .stat-card, .hms-dashboard-stats .stat-body { min-height: 88px; }
    .hms-dashboard-stats .stat-body { gap: .7rem !important; padding: .8rem; }
    .hms-dashboard-stats .stat-icon { flex-basis: 40px; width: 40px; height: 40px; font-size: 1.05rem; }
}

/* Keep the IPD page on one calm, high-contrast hospital palette. */
.ipd-admission-page > .patient-banner {
    border-color: rgba(13, 103, 109, .2);
    background: linear-gradient(115deg, #0d626b 0%, #117b7b 58%, #258f87 100%);
    box-shadow: 0 8px 22px rgba(13, 98, 107, .17);
}
.ipd-admission-page > .patient-banner .uhid-chip {
    border-color: rgba(255, 255, 255, .32);
    background: rgba(255, 255, 255, .15);
    color: #fff;
}
.ipd-admission-page > .patient-banner .btn-light,
.ipd-admission-page > .patient-banner .btn-white {
    border: 1px solid rgba(255, 255, 255, .75);
    background: #fff;
    color: #145d65;
    font-weight: 600;
}
.ipd-admission-page > .patient-banner .btn-light:hover,
.ipd-admission-page > .patient-banner .btn-white:hover { background: #edf8f7; color: #104b52; }
.ipd-admission-page .ipd-section-icon { background: #e8f4f3; color: #126b70; }
.ipd-admission-page .form-control:focus,
.ipd-admission-page .form-select:focus {
    border-color: #258f87;
    box-shadow: 0 0 0 .2rem rgba(18, 123, 123, .13);
}
.ipd-action-card .btn-light {
    border: 1px solid #dce5e9;
    background: #f5f8f9;
    color: #425667;
}
.ipd-action-card .btn-light:hover { border-color: #cbd9de; background: #edf3f5; color: #294553; }

/* OPD visit creation shares the same patient-facing visual system as IPD. */
.opd-visit-page { padding-bottom: 1.5rem; }
.opd-visit-head { margin-bottom: 1rem; }
.opd-visit-head h3 { color: #183b4a; font-size: 1.35rem; font-weight: 700; }
.opd-visit-page > .patient-banner {
    margin-bottom: 1.1rem !important;
    padding: 1.25rem 1.4rem;
    border: 1px solid rgba(13, 103, 109, .2);
    border-radius: 14px;
    background: linear-gradient(115deg, #0d626b 0%, #117b7b 58%, #258f87 100%);
    box-shadow: 0 8px 22px rgba(13, 98, 107, .17);
}
.opd-visit-page > .patient-banner .uhid-chip {
    border-color: rgba(255, 255, 255, .32);
    border-radius: 999px;
    background: rgba(255, 255, 255, .15);
    color: #fff;
    padding: .28rem .68rem;
}
.opd-visit-page > .patient-banner .kv { gap: .5rem 1.25rem !important; }
.opd-visit-page > .patient-banner .btn-light,
.opd-visit-page > .patient-banner .btn-white {
    border: 1px solid rgba(255, 255, 255, .75);
    background: #fff;
    color: #145d65;
    font-weight: 600;
}
.opd-visit-page > .patient-banner .btn-light:hover,
.opd-visit-page > .patient-banner .btn-white:hover { background: #edf8f7; color: #104b52; }
.opd-visit-card {
    overflow: hidden;
    border: 1px solid #e8edf2;
    border-radius: 14px;
    box-shadow: 0 4px 14px rgba(26, 54, 75, .06);
}
.opd-visit-card > .card-header {
    display: flex;
    align-items: center;
    gap: .8rem;
    min-height: 68px;
    padding: .9rem 1.25rem;
    border-bottom: 1px solid #edf0f4;
    background: #fff;
}
.opd-visit-card > .card-header h5 { color: #254454; font-size: 1rem; font-weight: 700; }
.opd-visit-card > .card-header small { display: block; margin-top: .18rem; color: #8794a2; font-size: .75rem; }
.opd-section-icon {
    display: inline-flex;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    background: #e8f4f3;
    color: #126b70;
    font-size: 1.15rem;
}
.opd-visit-card > .card-body { padding: 1.25rem; }
.opd-visit-page .form-label { margin-bottom: .42rem; color: #425667; font-size: .82rem; font-weight: 600; }
.opd-visit-page .form-control, .opd-visit-page .form-select {
    min-height: 42px;
    border-color: #dce4eb;
    border-radius: 8px;
    color: #263d4d;
    font-size: .88rem;
}
.opd-visit-page textarea.form-control { min-height: auto; }
.opd-visit-page .form-control:focus, .opd-visit-page .form-select:focus {
    border-color: #258f87;
    box-shadow: 0 0 0 .2rem rgba(18, 123, 123, .13);
}
.opd-visit-page .card-footer { padding: .9rem 1.25rem; border-top: 1px solid #edf0f4; background: #fbfcfd; }
.opd-visit-page .card-footer .btn { min-height: 42px; border-radius: 8px; font-weight: 600; }
.opd-recent-visits .card-header { min-height: 64px; }
.opd-recent-visits .table { color: #405565; font-size: .84rem; }
.opd-recent-visits .table thead th { padding: .7rem .8rem; border-bottom-color: #e8edf2; background: #f8fafb; color: #657786; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .035em; }
.opd-recent-visits .table tbody td { padding: .75rem .8rem; vertical-align: middle; }
.opd-recent-visits .table tbody tr:last-child td { border-bottom: 0; }
.opd-visit-steps .card-body { padding: 1.1rem 1.25rem; }
.opd-visit-steps .flow-step { display: flex; align-items: flex-start; gap: .65rem; color: #738290; line-height: 1.45; }
.opd-visit-steps .flow-step.done, .opd-visit-steps .flow-step.current { color: #355365; }
.opd-visit-steps .flow-step .dot { display: inline-flex; flex: 0 0 22px; width: 22px; height: 22px; align-items: center; justify-content: center; margin: 0; border-radius: 50%; background: #eef2f5; color: #738290; font-size: .72rem; font-weight: 700; }
.opd-visit-steps .flow-step.done .dot { background: #dff2ed; color: #168263; }
.opd-visit-steps .flow-step.current .dot { background: #147f7b; color: #fff; }
@media (min-width: 992px) { .opd-visit-steps { position: sticky; top: 1rem; } }
@media (max-width: 575.98px) {
    .opd-visit-page > .patient-banner { padding: 1rem; }
    .opd-visit-card > .card-body { padding: 1rem; }
    .opd-visit-card > .card-header { padding: .8rem 1rem; }
    .opd-recent-visits .table { min-width: 620px; }
}

@media (max-width: 991.98px) {
    .ipd-admission-page .ipd-action-card { position: static; }
}
@media (max-width: 575.98px) {
    .ipd-admission-page > .patient-banner { padding: 1rem; }
    .ipd-form-card .card-body { padding: 1rem; }
    .ipd-form-card .card-header { padding: .8rem 1rem; }
}

/* ---------- timeline ---------- */
.timeline-list {
    position: relative;
    padding-left: 26px;
}

.timeline-list::before {
    content: "";
    position: absolute;
    left: 8px;
    top: 6px;
    bottom: 6px;
    width: 2px;
    background: #eceef4;
}

.timeline-list .tl-item {
    position: relative;
    padding-bottom: 14px;
}

.timeline-list .tl-item::before {
    content: "";
    position: absolute;
    left: -22px;
    top: 5px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #6961e6;
    border: 2px solid #fff;
    box-shadow: 0 0 0 2px #e3e0fb;
}

/* ---------- report / print ---------- */
.report-sheet {
    background: #fff;
    border-radius: 14px;
    padding: 1.5rem;
    border: 1px solid #f0f1f5;
}

.report-head {
    border-bottom: 2px solid #6961e6;
    padding-bottom: .75rem;
    margin-bottom: 1rem;
}

.result-flag-HIGH, .result-flag-CRITICAL, .result-flag-POSITIVE {
    color: #d63939;
    font-weight: 700;
}

.result-flag-LOW, .result-flag-ABNORMAL {
    color: #f59e0b;
    font-weight: 700;
}

.result-flag-NORMAL, .result-flag-NEGATIVE {
    color: #1eb36a;
    font-weight: 600;
}

@media print {
    nav, header, footer, .no-print, .header-main, .go-top {
        display: none !important;
    }

    .app-content, .app-wrapper {
        margin: 0 !important;
        padding: 0 !important;
    }

    .card, .report-sheet {
        box-shadow: none !important;
        border: 1px solid #ddd !important;
    }
}

/* ---------- misc ---------- */
.hms-avatar {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: .8rem;
    background: #eeecfd;
    color: #6961e6;
}

.wf-pending { background: #f59e0b; }
.wf-progress { background: #3b82f6; }
.wf-done { background: #1eb36a; }
.wf-cancel { background: #d63939; }

.soft-divider {
    border-top: 1px dashed #e6e8f0;
    margin: .75rem 0;
}

.mini-label {
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: #8a8f9c;
    font-weight: 600;
}

.pointer { cursor: pointer; }

.select2-mini { max-width: 260px; }

/* ---------- stat grid ---------- */
.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: .75rem;
    margin-bottom: 1rem;
}

.stat-card.accent {
    border-color: #d9d5fb;
    background: #f7f6ff;
}

/* ---------- key / value grid ---------- */
.kv-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: .6rem .9rem;
}

.kv-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* ---------- patient master record ---------- */
.patient-record-page {
    --record-ink: #173b4a;
    --record-muted: #748493;
    --record-line: #e6edf0;
    color: var(--record-ink);
}

.patient-record-head {
    align-items: center;
    margin-bottom: 1.15rem;
}

.patient-record-head h3 {
    color: var(--record-ink);
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -.02em;
    margin-bottom: .25rem;
}

.patient-record-head p {
    color: var(--record-muted);
    margin: 0;
    font-size: .88rem;
}

.patient-record-head .btn {
    align-items: center;
    border-radius: 10px;
    font-weight: 600;
    padding: .62rem .95rem;
    box-shadow: 0 2px 5px rgba(23, 59, 74, .05);
    transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease;
}

.patient-record-head .btn:hover {
    box-shadow: 0 5px 12px rgba(23, 59, 74, .12);
    transform: translateY(-1px);
}

.patient-record-page > .patient-banner {
    border: 0;
    border-radius: 16px;
    padding: 1.35rem 1.5rem;
    background: linear-gradient(115deg, #0e6871 0%, #157f83 60%, #279392 100%);
    box-shadow: 0 10px 26px rgba(15, 104, 113, .14);
}

.patient-record-page > .patient-banner .uhid-chip {
    border: 1px solid rgba(255, 255, 255, .27);
    border-radius: 7px;
    background: rgba(255, 255, 255, .13);
    color: #fff;
    padding: .25rem .55rem;
    font-size: .73rem;
}

.patient-record-page > .patient-banner .kv {
    color: rgba(255, 255, 255, .92);
    font-size: .82rem;
}

.patient-record-page > .patient-banner .btn-light,
.patient-record-page > .patient-banner .btn-white {
    border: 1px solid rgba(255, 255, 255, .55);
    border-radius: 9px;
    color: #125e66;
    font-weight: 600;
    padding: .52rem .9rem;
    box-shadow: 0 3px 8px rgba(7, 56, 62, .12);
    transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease;
}

.patient-record-page > .patient-banner .btn-light:hover,
.patient-record-page > .patient-banner .btn-white:hover {
    background: #f0fbfa;
    box-shadow: 0 6px 14px rgba(7, 56, 62, .2);
    transform: translateY(-1px);
}

.patient-record-page .stat-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .8rem;
    margin: 0 0 1.25rem;
}

.patient-record-page .stat-card {
    min-height: 88px;
    padding: .95rem 1rem;
    border: 1px solid var(--record-line);
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 3px 12px rgba(29, 58, 75, .035);
}

.patient-record-page .stat-card.accent {
    border-color: #cce6e3;
    background: #f3faf9;
}

.patient-record-page .stat-value {
    color: #173b4a;
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.2;
}

.patient-record-page .stat-label {
    margin-top: .3rem;
    color: var(--record-muted);
    font-size: .77rem;
    font-weight: 500;
}

.patient-record-content .card {
    overflow: hidden;
    border: 1px solid var(--record-line);
    border-radius: 13px;
    box-shadow: 0 4px 15px rgba(29, 58, 75, .035);
}

.patient-record-content .card-header {
    padding: .95rem 1.1rem;
    border-bottom: 1px solid var(--record-line);
}

.patient-record-content .card-header h5 {
    color: var(--record-ink);
    font-size: .95rem;
    font-weight: 700;
}

.patient-record-content .table thead th {
    background: #f7fafb;
    color: #718392;
    font-size: .69rem;
    font-weight: 700;
    letter-spacing: .035em;
    text-transform: uppercase;
    white-space: nowrap;
}

.patient-record-content .table td,
.patient-record-content .table th {
    padding: .8rem .75rem;
    border-color: #edf1f3;
}

.patient-record-content .table tbody tr:hover {
    background: #f9fcfc;
}

.patient-record-content .kv-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .85rem;
}

.patient-record-content .card-body {
    padding: 1.15rem;
}

.patient-record-content .kv-item {
    min-height: 68px;
    justify-content: center;
    gap: .35rem;
    padding: .8rem .9rem;
    border: 1px solid #e8eef1;
    border-radius: 10px;
    background: #f9fbfc;
}

.patient-record-content .kv-label {
    color: #7c8c98;
    font-size: .7rem;
    letter-spacing: .055em;
}

.patient-record-content .kv-value {
    color: #294653;
    font-size: .92rem;
    font-weight: 600;
    overflow-wrap: anywhere;
}

.patient-record-content .record-list-row {
    min-height: 52px;
    padding: .65rem .25rem !important;
    border-bottom: 1px solid #edf1f3;
}

.patient-record-content .record-list-row:last-child {
    border-bottom: 0;
}

.patient-record-content .record-empty {
    padding: .5rem 0;
    color: #7c8c98;
    font-size: .85rem;
}

@media (max-width: 991.98px) {
    .patient-record-page .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .patient-record-content .kv-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 575.98px) {
    .patient-record-head { align-items: flex-start; gap: .8rem; }
    .patient-record-head > div:last-child { flex-wrap: wrap; }
    .patient-record-page > .patient-banner { padding: 1rem; }
    .patient-record-content .kv-grid { grid-template-columns: 1fr; }
}

.kv-label {
    font-size: .68rem;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #8a8f9c;
    font-weight: 600;
}

.kv-value {
    font-size: .85rem;
    color: #3a3f4b;
    word-break: break-word;
}

/* ---------- chips ---------- */
.uhid-chip {
    display: inline-block;
    background: #f1f0fe;
    color: #6961e6;
    border-radius: 8px;
    padding: 2px 9px;
    font-size: .72rem;
    font-weight: 600;
    white-space: nowrap;
}

.token-chip {
    display: inline-block;
    min-width: 58px;
    text-align: center;
    background: #1eb36a;
    color: #fff;
    border-radius: 8px;
    padding: 3px 10px;
    font-size: .75rem;
    font-weight: 700;
}

/* ---------- responsive table wrapper ---------- */
.table-wrap {
    width: 100%;
    overflow-x: auto;
}

/* ---------- bed card ---------- */
.bed-card {
    transition: transform .15s ease, box-shadow .15s ease;
}

.bed-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(58, 63, 75, .08);
}

/* ---------- timeline ---------- */
.timeline {
    position: relative;
    padding-left: 26px;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 8px;
    top: 6px;
    bottom: 6px;
    width: 2px;
    background: #eceef4;
}

.timeline-item {
    position: relative;
    padding-bottom: 14px;
}

.timeline-dot {
    position: absolute;
    left: -22px;
    top: 14px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 0 0 2px #e3e0fb;
}
/* Login page visual refresh based on the supplied hospital sign-in reference. */
.sign-in-bg {
    min-height: 100vh;
    background: #c7edf0;
}

.sign-in-bg .app-wrapper,
.sign-in-bg .app-wrapper > div {
    min-height: 100vh;
}

.sign-in-bg .main-container {
    max-width: 1440px;
    min-height: 100vh;
    padding: 24px;
}

.sign-in-bg .main-container .main-content-box {
    min-height: calc(100vh - 48px);
    align-items: center;
    background-color: #eff8f9;
    background-image: none;
    border-radius: 24px;
    box-shadow: 0 18px 55px rgba(34, 104, 116, .10);
    padding: clamp(24px, 4vw, 64px);
}

.sign-in-bg .image-content-box {
    align-self: stretch;
    display: flex;
    align-items: center;
}

.sign-in-bg .image-content-box .form-container {
    width: 100%;
}

.sign-in-bg .image-content-box .signup-content {
    margin-top: 0 !important;
}

.sign-in-bg .image-content-box .signup-content h4 {
    color: #173e4d !important;
}

.sign-in-bg .image-content-box .signup-content p {
    color: #54727d !important;
}

.sign-in-bg .image-content-box .signup-bg-img {
    margin-top: 22px;
}

.sign-in-bg .image-content-box .signup-bg-img img {
    max-height: 560px;
    object-fit: contain;
}

.sign-in-bg .form-content-box {
    align-self: center;
    padding: 28px;
}

.sign-in-bg .form-content-box > .form-container {
    width: 100%;
    max-width: 490px;
    padding: clamp(24px, 3vw, 42px);
    border: 1px solid #e4eff0;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 14px 38px rgba(33, 91, 102, .10);
}

.sign-in-bg .form-content-box h4,
.sign-in-bg .form-content-box .text-white,
.sign-in-bg .form-content-box .form-check-label {
    color: #183d4a !important;
}

.sign-in-bg .form-content-box p {
    color: #687f88 !important;
}

.sign-in-bg .form-content-box .form-container .form-control {
    min-height: 56px;
    border: 1px solid #d5e7e9 !important;
    border-radius: 9px;
    background: #f1f8f9 !important;
    color: #183d4a !important;
    box-shadow: none;
}

.sign-in-bg .form-content-box .form-container .form-control:focus {
    border-color: #35aeb8 !important;
    box-shadow: 0 0 0 3px rgba(53, 174, 184, .14);
}

.sign-in-bg .form-content-box .form-floating label,
.sign-in-bg .form-content-box .form-container .form-check-label,
.sign-in-bg .form-content-box a {
    color: #46636d !important;
}

.sign-in-bg .form-content-box .form-check-input {
    background-color: #fff !important;
    border-color: #9bbcc1 !important;
}

.sign-in-bg .form-content-box .form-check-input:checked {
    background-color: #159eaa !important;
    border-color: #159eaa !important;
}

.sign-in-bg .form-content-box .btn-primary {
    min-height: 50px;
    border: 0;
    border-radius: 9px;
    background: #12a5b0;
    color: #fff;
    font-weight: 700;
    box-shadow: 0 7px 16px rgba(18, 165, 176, .2);
}

.sign-in-bg .form-content-box .btn-primary:hover,
.sign-in-bg .form-content-box .btn-primary:focus {
    background: #0e8f99;
    color: #fff;
}

.sign-in-bg .form-content-box .app-divider-v p {
    padding: 3px 9px;
    border-radius: 5px;
    background: #e9f5f6;
    color: #28727b !important;
    font-size: 12px;
}

.sign-in-bg .form-content-box .btn-light-white {
    min-height: 54px;
    border: 1px solid #dcebed;
    border-radius: 8px;
    background: #f4f9fa;
    color: #244b57;
}

.sign-in-bg .form-content-box .btn-light-white:hover {
    background: #e9f5f6;
}

.sign-in-bg .form-content-box .btn-light-white .text-muted {
    color: #668089 !important;
}

@media (max-width: 991.98px) {
    .sign-in-bg .main-container {
        max-width: 680px;
        padding: 18px;
    }

    .sign-in-bg .main-container .main-content-box {
        min-height: calc(100vh - 36px);
    }

    .sign-in-bg .form-content-box {
        padding: 20px 8px;
    }
}

@media (max-width: 575.98px) {
    .sign-in-bg .main-container {
        padding: 10px;
    }

    .sign-in-bg .main-container .main-content-box {
        min-height: calc(100vh - 20px);
        padding: 14px;
        border-radius: 16px;
    }

    .sign-in-bg .form-content-box {
        padding: 14px 0;
    }

    .sign-in-bg .form-content-box > .form-container {
        padding: 22px 16px;
        border-radius: 15px;
    }
}

@media (min-width: 992px) {
    .sign-in-bg .main-content-box > .image-content-box,
    .sign-in-bg .main-content-box > .form-content-box {
        flex: 0 0 50%;
        max-width: 50%;
    }
}

@media (min-width: 992px) {
    .sign-in-bg .form-content-box > .form-container {
        box-sizing: border-box;
        max-width: 480px;
        width: 100%;
        margin-inline: auto;
    }
}

@media (min-width: 992px) {
    .sign-in-bg .form-content-box > .form-container {
        transform: translateX(clamp(24px, 2.1vw, 40px));
    }
}

/* Keep the main login panel centered with equal outer gutters. */
.sign-in-bg .main-container {
    width: 100%;
    max-width: none;
    margin-inline: auto;
    box-sizing: border-box;
}

@media (min-width: 992px) {
    .sign-in-bg .form-content-box > .form-container {
        transform: none;
        box-sizing: border-box;
        max-width: 480px;
        width: 100%;
        margin-inline: auto;
    }
}

@media (min-width: 992px) {
    .sign-in-bg .form-content-box {
        justify-content: flex-end;
    }

    .sign-in-bg .form-content-box > .form-container {
        margin-left: auto;
        margin-right: 0;
    }
}

@media (min-width: 992px) {
    .sign-in-bg .form-content-box {
        justify-content: center !important;
    }

    .sign-in-bg .form-content-box > .form-container {
        margin-left: auto !important;
        margin-right: auto !important;
        transform: none !important;
    }
}

@media (min-width: 992px) {
    .sign-in-bg .form-content-box > .form-container {
        transform: translateX(39px) !important;
    }
}

.main-content-box1 {
    margin-left: calc(4.9 * var(--bs-gutter-x)) !important;
}

/* Visit summary palette: calm teal with clear white contrast. */
.visit-summary-page > .patient-banner {
    background: linear-gradient(115deg, #0d626b 0%, #117b7b 58%, #258f87 100%);
    border: 1px solid rgba(13, 103, 109, .2);
    box-shadow: 0 8px 22px rgba(13, 98, 107, .16);
}
.visit-summary-page > .patient-banner .uhid-chip {
    color: #fff;
    background: rgba(255, 255, 255, .15);
    border-color: rgba(255, 255, 255, .32);
}
.visit-summary-page > .patient-banner .btn-light,
.visit-summary-page > .patient-banner .btn-white {
    color: #145d65;
    background: #fff;
    border-color: rgba(255, 255, 255, .75);
    font-weight: 600;
}
.visit-summary-page .flow-step.current .dot { background: #147f7b; }
.visit-summary-page .flow-step.done .dot { background: #dff2ed; color: #168263; }
.visit-summary-page .card {
    border-color: #e4ebef;
    box-shadow: 0 4px 14px rgba(26, 54, 75, .055);
}
.visit-summary-page .card-header h5 { color: #254454; }

/* Pharmacy prescription queue */
.pharmacy-prescriptions-page { --pharmacy-ink: #173b4a; --pharmacy-muted: #718392; }
.pharmacy-prescriptions-page .pharmacy-page-head {
    align-items: center;
    gap: 1rem;
    margin: .35rem 0 1.2rem;
    padding: 1.1rem 1.25rem;
    border: 1px solid #e3ebef;
    border-left: 4px solid #147f7b;
    border-radius: 14px;
    background: linear-gradient(110deg, #fff, #f7fbfb);
    box-shadow: 0 4px 14px rgba(26, 54, 75, .045);
}
.pharmacy-prescriptions-page .page-head h3 { color: var(--pharmacy-ink); font-weight: 700; letter-spacing: -.02em; }
.pharmacy-prescriptions-page .page-head p { margin: .35rem 0 0; color: var(--pharmacy-muted); font-size: .88rem; }
.pharmacy-prescriptions-page .page-head p.pharmacy-compact-subtitle { font-size: .74rem; }
.pharmacy-prescriptions-page .page-head .btn { min-height: 42px; display: inline-flex; align-items: center; justify-content: center; border-radius: 9px; font-weight: 600; }
.pharmacy-prescriptions-page .page-head .btn-light { color: #506777; background: #fff; border: 1px solid #dce6ea; }
.pharmacy-prescriptions-page .page-head .btn-light:hover { color: #147f7b; border-color: #9ccbc7; background: #f5fbfa; }
.pharmacy-prescriptions-page .pharmacy-stat-grid { gap: .9rem; margin-bottom: 1rem !important; }
.pharmacy-prescriptions-page .stat-card { min-height: 106px; border: 1px solid #e4ebef; background: #fff; box-shadow: 0 3px 12px rgba(26, 54, 75, .035); }
.pharmacy-prescriptions-page .stat-card .stat-body { min-height: 106px; gap: .9rem; padding: 1rem 1.15rem; }
.pharmacy-prescriptions-page .stat-value { color: var(--pharmacy-ink); font-size: 1.55rem; }
.pharmacy-prescriptions-page .stat-label { color: var(--pharmacy-muted); font-weight: 600; }
.pharmacy-prescriptions-page .pharmacy-filter-bar { margin: 0 0 1rem; padding: 1rem 1.1rem .8rem; border: 1px solid #e3ebef; border-radius: 14px; background: #fff; box-shadow: 0 3px 12px rgba(26, 54, 75, .035); }
.pharmacy-prescriptions-page .mini-label { color: #718392; font-size: .72rem; font-weight: 700; letter-spacing: .045em; text-transform: uppercase; }
.pharmacy-prescriptions-page .form-control, .pharmacy-prescriptions-page .form-select { min-height: 42px; border-color: #dce5ea; border-radius: 8px; color: #304958; }
.pharmacy-prescriptions-page .form-control:focus, .pharmacy-prescriptions-page .form-select:focus { border-color: #72b8b2; box-shadow: 0 0 0 .2rem rgba(20, 127, 123, .12); }
.pharmacy-prescriptions-page .pharmacy-table-card { overflow: hidden; border: 1px solid #e3ebef; border-radius: 14px; background: #fff; box-shadow: 0 4px 14px rgba(26, 54, 75, .055); }
.pharmacy-prescriptions-page .table-wrap { overflow-x: auto; }
.pharmacy-prescriptions-page .table-hms thead th { padding: .85rem 1rem; color: #718392; background: #f6f9fa; font-size: .72rem; font-weight: 700; letter-spacing: .035em; text-transform: uppercase; white-space: nowrap; }
.pharmacy-prescriptions-page .table-hms tbody td { padding: .85rem 1rem; border-color: #edf1f3; color: #405766; }
.pharmacy-prescriptions-page .table-hms tbody tr:hover { background: #f8fbfb; }
.pharmacy-prescriptions-page .table-hms tbody td[colspan] { padding: 2.5rem 1rem !important; }
@media (max-width: 767.98px) {
    .pharmacy-prescriptions-page .pharmacy-page-head { align-items: stretch; flex-direction: column; }
    .pharmacy-prescriptions-page .page-head > div:last-child { display: grid !important; grid-template-columns: 1fr; }
    .pharmacy-prescriptions-page .pharmacy-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Shared colorful vertical metric cards across every role dashboard. */
.hms-dashboard-stats .stat-card,
.hms-dashboard-security-stats .stat-card {
    position: relative;
    min-height: 218px;
    overflow: visible;
    border: 1px solid #e7ebef;
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 5px 14px rgba(34, 48, 65, .09);
    transition: transform .18s ease, box-shadow .18s ease;
}
.hms-dashboard-stats .stat-card::before,
.hms-dashboard-security-stats .stat-card::before {
    display: block;
    content: "";
    position: absolute;
    inset: 0 0 auto;
    height: 112px;
    border-radius: 14px 14px 50% 50% / 14px 14px 42% 42%;
    background: radial-gradient(circle at 50% 10%, rgba(16, 111, 119, .2) 0 34%, rgba(16, 111, 119, .13) 35% 56%, rgba(16, 111, 119, .07) 57% 74%, transparent 75%);
}
.hms-dashboard-stats .stat-body,
.hms-dashboard-security-stats .stat-body {
    position: relative;
    z-index: 1;
    background: transparent;
    min-height: 216px;
    flex-direction: column;
    justify-content: flex-start;
    gap: .35rem !important;
    padding: 74px .8rem 1rem;
    text-align: center;
}
.hms-dashboard-stats .stat-icon,
.hms-dashboard-security-stats .stat-icon {
    position: absolute;
    top: -13px;
    left: 50%;
    z-index: 1;
    width: 62px;
    height: 62px;
    border: 0;
    border-radius: 50%;
    background: #0d6870 !important;
    color: #fff !important;
    box-shadow: 0 5px 12px rgba(16, 75, 82, .2);
    font-size: 1.55rem;
    transform: translateX(-50%);
}
.hms-dashboard-stats .stat-value,
.hms-dashboard-security-stats .stat-value { margin: 0; color: #0d6870; font-size: clamp(1.75rem, 2.2vw, 2.35rem); font-weight: 750; line-height: 1.15; }
.hms-dashboard-stats .stat-label,
.hms-dashboard-security-stats .stat-label { max-width: 100%; margin-top: .35rem; color: #485463; font-size: .96rem; font-weight: 700; line-height: 1.3; }
.hms-dashboard-stats .stat-body::after,
.hms-dashboard-security-stats .stat-body::after {
    content: "Summary";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 31px;
    margin: auto auto 0;
    padding: .35rem .8rem;
    border-radius: 8px;
    background: #e8f0f0;
    color: #0d6870;
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .02em;
}
.hms-dashboard-stats .stat-card.clickable .stat-body::after,
.hms-dashboard-security-stats .stat-card.clickable .stat-body::after { content: "View Details"; }
.hms-dashboard-stats > div:nth-child(6n + 2) .stat-card::before,
.hms-dashboard-security-stats > div:nth-child(6n + 2) .stat-card::before { background: radial-gradient(circle at 50% 10%, rgba(230, 65, 83, .2) 0 34%, rgba(230, 65, 83, .13) 35% 56%, rgba(230, 65, 83, .07) 57% 74%, transparent 75%); }
.hms-dashboard-stats > div:nth-child(6n + 2) .stat-icon,
.hms-dashboard-security-stats > div:nth-child(6n + 2) .stat-icon { background: #e64153 !important; }
.hms-dashboard-stats > div:nth-child(6n + 2) .stat-value,
.hms-dashboard-security-stats > div:nth-child(6n + 2) .stat-value { color: #e64153; }
.hms-dashboard-stats > div:nth-child(6n + 3) .stat-card::before,
.hms-dashboard-security-stats > div:nth-child(6n + 3) .stat-card::before { background: radial-gradient(circle at 50% 10%, rgba(250, 184, 24, .22) 0 34%, rgba(250, 184, 24, .14) 35% 56%, rgba(250, 184, 24, .07) 57% 74%, transparent 75%); }
.hms-dashboard-stats > div:nth-child(6n + 3) .stat-icon,
.hms-dashboard-security-stats > div:nth-child(6n + 3) .stat-icon { background: #fabc19 !important; }
.hms-dashboard-stats > div:nth-child(6n + 3) .stat-value,
.hms-dashboard-security-stats > div:nth-child(6n + 3) .stat-value { color: #e9a900; }
.hms-dashboard-stats > div:nth-child(6n + 4) .stat-card::before,
.hms-dashboard-security-stats > div:nth-child(6n + 4) .stat-card::before { background: radial-gradient(circle at 50% 10%, rgba(0, 177, 105, .2) 0 34%, rgba(0, 177, 105, .13) 35% 56%, rgba(0, 177, 105, .07) 57% 74%, transparent 75%); }
.hms-dashboard-stats > div:nth-child(6n + 4) .stat-icon,
.hms-dashboard-security-stats > div:nth-child(6n + 4) .stat-icon { background: #00b169 !important; }
.hms-dashboard-stats > div:nth-child(6n + 4) .stat-value,
.hms-dashboard-security-stats > div:nth-child(6n + 4) .stat-value { color: #00a45f; }
.hms-dashboard-stats > div:nth-child(6n + 5) .stat-card::before,
.hms-dashboard-security-stats > div:nth-child(6n + 5) .stat-card::before { background: radial-gradient(circle at 50% 10%, rgba(51, 135, 230, .2) 0 34%, rgba(51, 135, 230, .13) 35% 56%, rgba(51, 135, 230, .07) 57% 74%, transparent 75%); }
.hms-dashboard-stats > div:nth-child(6n + 5) .stat-icon,
.hms-dashboard-security-stats > div:nth-child(6n + 5) .stat-icon { background: #3888e8 !important; }
.hms-dashboard-stats > div:nth-child(6n + 5) .stat-value,
.hms-dashboard-security-stats > div:nth-child(6n + 5) .stat-value { color: #3888e8; }
.hms-dashboard-stats > div:nth-child(6n) .stat-card::before,
.hms-dashboard-security-stats > div:nth-child(6n) .stat-card::before { background: radial-gradient(circle at 50% 10%, rgba(134, 87, 198, .2) 0 34%, rgba(134, 87, 198, .13) 35% 56%, rgba(134, 87, 198, .07) 57% 74%, transparent 75%); }
.hms-dashboard-stats > div:nth-child(6n) .stat-icon,
.hms-dashboard-security-stats > div:nth-child(6n) .stat-icon { background: #8657c6 !important; }
.hms-dashboard-stats > div:nth-child(6n) .stat-value,
.hms-dashboard-security-stats > div:nth-child(6n) .stat-value { color: #8657c6; }
.hms-dashboard-stats .stat-card.clickable:hover,
.hms-dashboard-security-stats .stat-card.clickable:hover { transform: translateY(-3px); box-shadow: 0 9px 20px rgba(34, 48, 65, .14); }
@media (max-width: 575.98px) {
    .hms-dashboard-stats .stat-card,
    .hms-dashboard-security-stats .stat-card { min-height: 190px; }
    .hms-dashboard-stats .stat-body,
    .hms-dashboard-security-stats .stat-body { min-height: 188px; padding: 70px .55rem .8rem; }
    .hms-dashboard-stats .stat-label,
    .hms-dashboard-security-stats .stat-label { font-size: .83rem; }
}

/* Match the supplied ki-admin ecommerce metric-card proportions. */
.hms-dashboard-stats .stat-card,
.hms-dashboard-security-stats .stat-card { min-height: 260px; }
.hms-dashboard-stats .stat-body,
.hms-dashboard-security-stats .stat-body { min-height: 258px; padding: 3.5rem .75rem 1.5rem; }
.hms-dashboard-stats .stat-icon,
.hms-dashboard-security-stats .stat-icon { top: -10px; width: 62px; height: 62px; }
.hms-dashboard-stats .stat-value,
.hms-dashboard-security-stats .stat-value {
    max-width: 100%;
    margin-top: 2.5rem !important;
    font-size: clamp(1.2rem, 1.55vw, 2.25rem);
    letter-spacing: -.035em;
    line-height: 1.12;
    overflow-wrap: anywhere;
}
.hms-dashboard-stats .stat-label,
.hms-dashboard-security-stats .stat-label { margin-top: .15rem; font-size: 1rem; }
@media (max-width: 575.98px) {
    .hms-dashboard-stats .stat-card,
    .hms-dashboard-security-stats .stat-card { min-height: 220px; }
    .hms-dashboard-stats .stat-body,
    .hms-dashboard-security-stats .stat-body { min-height: 218px; padding: 3.4rem .5rem 1rem; }
    .hms-dashboard-stats .stat-value,
    .hms-dashboard-security-stats .stat-value { font-size: clamp(1.1rem, 7vw, 1.55rem); }
    .hms-dashboard-stats .stat-label,
    .hms-dashboard-security-stats .stat-label { font-size: .85rem; }
}
