/* ============================================================
   LABCARE ELITE — PAGE-SPECIFIC STYLES (page.css)
   ============================================================
   All page-level and component-level styles live here.
   The shared design system (lc-*) lives in app.css.
   ============================================================ */

/* ============================================================
   1. MAIN LAYOUT
   ============================================================ */
.page {
    position: relative;
    display: flex;
    flex-direction: column;
}

main {
    flex: 1;
}

.content {
    padding: 24px 32px !important;
    background-color: #f8fafc !important;
    display: block;
}

.custom-layout-wrapper {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0;
}

@media (min-width: 641px) {
    .page {
        flex-direction: row;
    }

    .sidebar {
        width: 270px;
        height: 100vh;
        position: sticky;
        top: 0;
    }
}


/* ============================================================
   2. SIDEBAR / NAV MENU
   ============================================================ */

/* ── Sidebar toggle button — absolute at sidebar's right edge, half-protruding ── */
.sidebar-wrapper {
    position: relative;
    overflow: visible !important;
    /* allow button to peek out on the right */
}

.sidebar-toggle-btn {
    position: absolute;
    top: 24px;
    right: -13px;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    color: #475569;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.12);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
}

.sidebar-toggle-btn:hover {
    background: #4f46e5;
    color: #ffffff;
    border-color: #4f46e5;
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.4);
    transform: scale(1.14);
}

.sidebar-toggle-btn:active {
    transform: scale(0.92);
}

/* Collapsed state: button automatically moves with sidebar — no extra needed */
.nav-collapsed .sidebar-toggle-btn {
    right: -13px;
}

/* ══════════════════════════════════════════════════
   ✦ PREMIUM TOOLTIP — Collapsed Nav (Ultra Modern)
   ══════════════════════════════════════════════════ */

#sidebar.nav-collapsed .v-nav-link,
#sidebar.nav-collapsed .logout-btn {
    position: relative;
    overflow: visible;
}

.logout-btn-proper {
    border: none !important;
    outline: none !important;
    color: #ef4444 !important;
    background: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 4px;
}

.logout-btn-proper:hover {
    background-color: rgba(239, 68, 68, 0.08) !important;
    color: #dc2626 !important;
}

.logout-btn-proper span {
    color: inherit !important;
}

/* ── Viewport Portal Tooltip Bubble (Dark Capsule) ── */
.menu-tooltip-bubble {
    position: fixed;
    transform: translateY(-50%);
    background: #1f2937;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: #ffffff;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 12.5px;
    font-weight: 500;
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.5px;
    white-space: nowrap;
    z-index: 99999;
    pointer-events: none;
    display: none;
    transition: opacity 0.15s ease-out;
    opacity: 0;
}

.menu-tooltip-bubble.active {
    background: #111827;
    border-left: 3px solid #6366f1;
    padding-left: 10px;
}


.sidebar {
    background-color: #000000;
    padding: 0 !important;
    background: transparent !important;
}

.sidebar-wrapper {
    width: 270px;
    height: 100% !important;
    min-height: 100% !important;
    max-height: 100% !important;
    background-color: #f1f5f9;
    color: #334155;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    box-shadow: 4px 0 20px rgba(148, 163, 184, 0.15);
    border-right: 1px solid #cbd5e1;
    z-index: 100;
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative !important;
    top: 0 !important;
    bottom: 0 !important;
    align-self: stretch !important;
    flex-shrink: 0 !important;
}

/* ── Collapsed state ── */
.sidebar-wrapper.nav-collapsed {
    width: 68px;
}

/* Hide text/labels when collapsed */
.nav-collapsed .nav-link-text,
.nav-collapsed .nav-text-fade,
.nav-collapsed .nav-user-text {
    opacity: 0;
    width: 0;
    overflow: hidden;
    pointer-events: none;
    white-space: nowrap;
    transition: opacity 0.15s ease, width 0.3s ease;
}

.nav-link-text,
.nav-text-fade,
.nav-user-text {
    opacity: 1;
    transition: opacity 0.2s ease 0.05s, width 0.3s ease;
}

/* Center icons when collapsed */
.nav-collapsed .v-nav-link {
    justify-content: center;
    padding: 8px;
}

.nav-collapsed .v-nav-link .mr-3 {
    margin-right: 0 !important;
}

/* Force override utility margins/paddings on collapsed nav icons to keep them centered */
.nav-collapsed .v-nav-link .material-symbols-outlined {
    margin-right: 0 !important;
    margin-left: 0 !important;
}

/* Maintain exact center padding for active nav links when collapsed */
.nav-collapsed .v-nav-link.active {
    padding-left: 8px !important;
    padding-right: 8px !important;
}

.nav-collapsed .menu-scroll {
    padding: 10px 4px;
}

/* Collapsed user avatar centering */
.nav-collapsed .px-4.mb-4 {
    padding: 0 4px 8px;
}

.nav-collapsed .px-4.mb-4 .p-4 {
    padding: 6px;
}

.nav-collapsed .px-4.mb-4 .flex.items-center.gap-3 {
    justify-content: center;
}

/* Logout button collapsed */
.nav-collapsed .mt-auto.p-4 button {
    justify-content: center;
    padding: 8px;
}

/* ── Toggle Button ── */
.nav-toggle-btn {
    margin-left: auto;
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border-radius: 8px;
    border: 1.5px solid rgba(148, 163, 184, 0.25);
    background: rgba(241, 245, 249, 0.10);
    color: #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    backdrop-filter: blur(4px);
}

.nav-toggle-btn:hover {
    background: rgba(99, 102, 241, 0.18);
    border-color: #6366f1;
    color: #a5b4fc;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.nav-toggle-btn:active {
    transform: scale(0.93);
}

.nav-toggle-icon {
    font-size: 20px !important;
    transition: transform 0.3s ease;
}

/* Collapsed sidebar branding: center logo */
.nav-collapsed .sidebar-branding {
    justify-content: center;
    flex-wrap: nowrap;
    gap: 0;
    padding: 12px 8px;
}

.nav-collapsed .logo-box {
    flex-shrink: 0;
}

.sidebar-branding {
    padding: 14px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid #cbd5e1;
    position: relative;
}

.logo-box {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-box .material-symbols-outlined {
    color: white;
    font-size: 24px;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.main-title {
    font-size: 18px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #1e293b;
}

.main-title .highlight {
    color: #4f46e5;
}

.sub-title {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #64748b;
    font-weight: 600;
}

.sidebar-branch-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 16px 4px;
    padding: 8px 14px;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(124, 58, 237, 0.15) 100%);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 10px;
    animation: badgeFadeIn 0.4s ease;
}

.branch-badge-icon {
    font-size: 14px !important;
    color: #818cf8;
    flex-shrink: 0;
}

.branch-badge-text {
    font-size: 11px;
    font-weight: 700;
    color: #c7d2fe;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Show user profile card as a compact avatar + signout when sidebar is collapsed */
.nav-collapsed .user-profile-card {
    display: block !important;
    margin: 4px auto;
    width: 100%;
}

.nav-collapsed .profile-card-inner {
    padding: 8px 4px;
    align-items: center;
    border-radius: 10px;
    gap: 4px;
}

.nav-collapsed .profile-user-info {
    display: flex;
    justify-content: center;
    width: 100%;
}

/* Hide settings gear in collapsed mode to allow the profile avatar to center perfectly */
.nav-collapsed .settings-gear-icon {
    display: none !important;
}

.nav-collapsed .profile-avatar {
    width: 32px;
    height: 32px;
    font-size: 13px;
    margin: 0 auto;
}

.nav-collapsed .profile-divider {
    width: 80%;
    margin: 6px auto;
}

.nav-collapsed .profile-logout-btn {
    padding: 6px 0;
    justify-content: center;
}

.nav-collapsed .profile-logout-btn .logout-icon {
    margin-right: 0 !important;
}

/* Premium User Profile Card Design */
.user-profile-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.profile-card-inner {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.8) 0%, rgba(248, 250, 252, 0.6) 100%);
    border: 1px solid rgba(99, 102, 241, 0.12);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.04);
    border-radius: 14px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.profile-user-info {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
}

.profile-divider {
    height: 1px;
    background-color: rgba(99, 102, 241, 0.12);
    margin: 6px 0;
    width: 100%;
}

.profile-logout-btn {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 8px 10px;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: #ef4444 !important;
    cursor: pointer;
    font-size: 12.5px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.profile-logout-btn:hover {
    background-color: rgba(239, 68, 68, 0.08);
    color: #dc2626 !important;
}

.profile-logout-btn .logout-icon {
    margin-right: 12px;
    font-size: 18px;
    color: inherit !important;
}

.profile-card-inner:hover {
    transform: translateY(-2px);
    border-color: rgba(99, 102, 241, 0.25);
    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.08);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.95) 0%, rgba(248, 250, 252, 0.85) 100%);
}

.profile-avatar {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.2);
    border: 2px solid #ffffff;
    flex-shrink: 0;
}

.profile-info {
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.profile-name {
    font-size: 13px;
    font-weight: 700;
    color: #0f172a;
    margin: 0;
    line-height: 1.3;
}

.profile-role {
    font-size: 10.5px;
    font-weight: 600;
    color: #6366f1;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.profile-branch-row {
    margin-top: 4px;
    padding-top: 8px;
    border-top: 1px dashed rgba(226, 232, 240, 0.8);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.branch-info-wrapper {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
    min-width: 0;
    margin-right: 8px;
    font-size: 11px;
    font-weight: 500;
    color: #475569;
}

.branch-info-wrapper span.material-symbols-outlined {
    font-size: 13px;
    color: #6366f1;
}

.branch-change-btn {
    background: rgba(99, 102, 241, 0.08);
    border: none;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 10px;
    font-weight: 700;
    color: #4f46e5;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 2px;
    transition: all 0.2s ease;
}

.branch-change-btn:hover {
    background: rgba(99, 102, 241, 0.16);
    color: #4338ca;
}

.menu-scroll {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    overflow-y: auto !important;
    padding: 16px 14px 180px 14px !important;
}

.sidebar-footer {
    position: absolute !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    padding: 12px 14px !important;
    border-top: 1px solid #cbd5e1 !important;
    background: #f1f5f9 !important;
    z-index: 50 !important;
}

.menu-group {
    margin-bottom: 32px;
}

.group-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #64748b;
    margin-bottom: 8px;
    padding-left: 10px;
}

/* Sidebar search features */
.sidebar-search-container {
    padding: 12px 16px 8px;
    transition: all 0.3s ease;
}

.sidebar-search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    padding: 0 10px 0 32px;
    height: 36px;
    transition: all 0.2s ease;
}

.sidebar-search-wrapper:focus-within {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.sidebar-search-wrapper .search-icon {
    position: absolute;
    left: 10px;
    color: #64748b;
    font-size: 18px;
    pointer-events: none;
}

.sidebar-search-input {
    width: 100%;
    border: none;
    outline: none;
    font-size: 12.5px;
    color: #1e293b;
    background: transparent;
}

.clear-search-btn {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    color: #94a3b8;
}

.clear-search-btn:hover {
    color: #ef4444;
}

.clear-search-btn span {
    font-size: 16px;
}

.sidebar-collapsed-search {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 8px auto 4px;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    color: #4f46e5;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
    align-self: center; /* Center horizontally in flex layout */
}

.sidebar-collapsed-search:hover {
    background: rgba(99, 102, 241, 0.08);
    border-color: #4f46e5;
    transform: translateY(-1px);
}

.sidebar-collapsed-search span {
    font-size: 18px;
}

.v-nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.v-nav-link {
    display: flex;
    align-items: center;
    padding: 7px 10px;
    border-radius: 8px;
    color: #334155 !important;
    text-decoration: none !important;
    font-size: 13.5px;
    font-weight: 600;
    transition: all 0.2s ease;
}

.v-nav-link:hover {
    background-color: rgba(99, 102, 241, 0.08);
    color: #0f172a !important;
}

.v-nav-link.active {
    background: transparent !important;
    color: #0f172a !important;
    border: none !important;
    padding-left: 10px !important;
}

.v-nav-link .material-symbols-outlined {
    font-size: 18px;
}

.mr-3 {
    margin-right: 0.75rem;
}

.user-profile-section {
    padding: 24px 30px;
    display: flex;
    align-items: center;
    gap: 14px;
    border-top: 1px solid #232635;
    margin-top: auto;
}

.user-avatar {
    width: 38px;
    height: 38px;
    background-color: #2D334A;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94A3B8;
    font-size: 18px;
}

.user-details {
    display: flex;
    flex-direction: column;
}

.user-name {
    color: white;
    font-size: 13px;
    font-weight: 600;
}

.user-terminal {
    font-size: 10px;
    color: #64748B;
    font-weight: 600;
    margin-top: 2px;
    letter-spacing: 0.5px;
}

.navbar-toggler {
    appearance: none;
    cursor: pointer;
    width: 3.5rem;
    height: 2.5rem;
    color: white;
    position: absolute;
    top: 0.5rem;
    right: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.55%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e") no-repeat center/1.75rem rgba(255, 255, 255, 0.1);
}

.navbar-toggler:checked {
    background-color: rgba(255, 255, 255, 0.5);
}

.nav-scrollable {
    display: none;
}

.navbar-toggler:checked~.nav-scrollable {
    display: block;
}

@media (min-width: 641px) {
    .navbar-toggler {
        display: none;
    }

    .nav-scrollable {
        display: block;
        height: calc(100vh - 3.5rem);
        overflow-y: auto;
    }
}

.no-scrollbar::-webkit-scrollbar {
    display: none !important;
}

.no-scrollbar {
    -ms-overflow-style: none !important;
    scrollbar-width: none !important;
}

.menu-scroll::-webkit-scrollbar {
    width: 6px;
}

.menu-scroll::-webkit-scrollbar-track {
    background: transparent;
}

.menu-scroll::-webkit-scrollbar-thumb {
    background-color: #cbd5e1;
    border-radius: 10px;
}

.menu-scroll::-webkit-scrollbar-thumb:hover {
    background-color: #94a3b8;
}

/* ============================================================
   4. REGISTER PAGE (Moved to wwwroot/css/register.css)
   ============================================================ */





.form-section-card {
    background: white;
    padding: 40px;
    border-radius: 16px;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
    border: 1px solid #f0f0f0;
    max-width: 500px;
    margin: 40px auto;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.step-badge {
    padding: 0.25rem 0.75rem;
    background-color: #EFF6FF;
    color: #2563EB;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 9999px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.step-text {
    color: #94a3b8;
    font-size: 0.875rem;
    font-weight: 500;
}

.progress-bar {
    height: 0.375rem;
    background-color: #F1F5F9;
    border-radius: 9999px;
    overflow: hidden;
    margin-bottom: 2.5rem;
}

.progress-fill {
    height: 100%;
    background-color: var(--lc-primary);
    transition: width 0.3s ease;
}

.page-title {
    font-size: 1.875rem;
    font-weight: 700;
    margin: 0 0 0.5rem;
}

.page-subtitle {
    color: #94a3b8;
    margin: 0 0 2rem;
}

.security-reqs {
    background-color: #F8FAFC;
    border-radius: 0.75rem;
    padding: 1.5rem;
    border: 1px solid var(--lc-border);
    margin-top: 1.5rem;
}

.security-reqs h4 {
    font-size: 0.625rem;
    font-weight: 700;
    color: #94A3B8;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin: 0 0 1rem 0;
}

.req-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem 1rem;
}

.req-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: #94a3b8;
}

.req-icon {
    width: 1rem;
    height: 1rem;
    border-radius: 9999px;
    border: 1px solid #CBD5E1;
    display: flex;
    align-items: center;
    justify-content: center;
}

.req-item.valid .req-icon {
    border-color: var(--lc-success);
    background-color: #ECFDF5;
}

.req-item.valid .req-icon span {
    font-size: 0.625rem;
    color: var(--lc-success);
    font-weight: 700;
}

.req-item:not(.valid) .req-icon span {
    display: none;
}

.input-icon-wrapper {
    position: relative;
}

.input-icon-wrapper input {
    padding-left: 2.5rem;
    padding-right: 2.5rem;
}

.input-icon-left {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: #94A3B8;
}

.input-icon-right {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: #94A3B8;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
}

.input-icon-right:hover {
    color: #64748b;
}

.bg-decorator {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    opacity: 0.1;
    pointer-events: none;
}

.password-step-container {
    max-width: 28rem;
    margin: 2rem auto 0;
}

.password-group {
    margin-bottom: 1.5rem;
}


/* ============================================================
   5. FORGOT PASSWORD PAGE
   ============================================================ */
.auth-page-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    position: relative;
    overflow: hidden;
    font-family: 'Inter', sans-serif;
}

.background-mesh {
    position: absolute;
    width: 100%;
    height: 100%;
    background-color: #f8fafc;
    background-image:
        radial-gradient(at 0% 0%, hsla(253, 16%, 7%, 0.1) 0, transparent 50%),
        radial-gradient(at 50% 0%, hsla(225, 39%, 30%, 0.1) 0, transparent 50%),
        radial-gradient(at 100% 0%, hsla(339, 49%, 30%, 0.1) 0, transparent 50%);
    z-index: 0;
}

.auth-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 480px;
    padding: 20px;
}

.auth-card {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.brand-section {
    padding: 40px 40px 20px;
    text-align: center;
}

.logo-circle {
    width: 64px;
    height: 64px;
    background: #4F46E5;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.3);
}

.brand-section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 4px;
}

.brand-section p {
    color: #64748b;
    font-size: 0.875rem;
}

.auth-form-content {
    padding: 0 40px 40px;
}

.form-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 8px;
}

.form-subtitle {
    color: #64748b;
    font-size: 0.875rem;
    margin-bottom: 24px;
}

.auth-form-content .form-group {
    margin-bottom: 20px;
}

.auth-form-content .form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #475569;
    margin-bottom: 8px;
}

.auth-form-content .input-container {
    position: relative;
}

.auth-form-content .input-container i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
}

.auth-form-content .form-control {
    width: 100%;
    padding: 12px 16px 12px 44px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    transition: all 0.2s;
    font-size: 0.875rem;
}

.auth-form-content .form-control:focus {
    background: #fff;
    border-color: #4F46E5;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
    outline: none;
}

.btn-primary {
    width: 100%;
    padding: 12px;
    background: #4F46E5;
    border: none;
    border-radius: 12px;
    color: white;
    font-weight: 600;
    transition: all 0.2s;
    margin-top: 10px;
}

.btn-primary:hover:not(:disabled) {
    background: #4338ca;
    transform: translateY(-1px);
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.2);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-link {
    background: none;
    border: none;
    color: #4F46E5;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0;
    cursor: pointer;
}

.auth-form-content .alert {
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.auth-form-content .alert-danger {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fee2e2;
}

.auth-form-content .alert-success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #dcfce7;
}

.auth-footer {
    margin-top: 32px;
    text-align: center;
    font-size: 0.875rem;
    color: #64748b;
}

.auth-footer a {
    color: #4F46E5;
    font-weight: 600;
    text-decoration: none;
}

.auth-footer a:hover {
    text-decoration: underline;
}

.reset-account-info {
    background: rgba(79, 70, 229, 0.1);
    border: 1px solid rgba(79, 70, 229, 0.2);
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.875rem;
    color: #4F46E5;
}

.reset-account-info i {
    font-size: 1.1rem;
}


/* ============================================================
   6. REFERRAL / MASTER PAGES
   ============================================================ */
.referral-page {
    padding: 16px 24px;
    background-color: #f8fafc;
    height: 100%;
    min-height: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    font-family: 'Inter', sans-serif;
    overflow: hidden;
}

.referral-header {
    margin-bottom: 24px;
}

.referral-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 4px 0;
}

.referral-header p {
    font-size: 14px;
    color: #64748b;
    margin: 0;
}

.referral-header .branch-label,
.referral-header .header-counter {
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    display: flex;
    align-items: center;
    gap: 8px;
}

.referral-header .branch-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: white;
    padding: 3px 10px;
    border-radius: 100px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.25);
    vertical-align: middle;
    min-width: 30px;
    justify-content: center;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 24px;
}

.header-search-input {
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 8px 16px;
    font-size: 13px;
    outline: none;
    width: 250px;
    background-color: #f8fafc;
    transition: width 0.3s, border-color 0.2s;
}

.header-search-input:focus {
    width: 300px;
    border-color: var(--lc-primary);
    background-color: #fff;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.add-referral-section {
    background: #ffffff;
    border: 1px solid #f1f5f9;
    border-radius: 16px;
    padding: 24px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.add-referral-section:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
}

.section-header {
    display: flex;
    gap: 16px;
    align-items: center;
}

.section-icon-large {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #e0e7ff 0%, #ede9fe 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.5);
}

.section-header h3 {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 6px 0;
}

.section-header p {
    font-size: 14px;
    color: #64748b;
    margin: 0;
    margin-left: 64px;
}

.referral-content {
    background-color: white;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    padding: 32px;
}

.btn-new-entry {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.3px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-new-entry:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.4);
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
}

.search-controls {
    display: flex;
    align-items: center;
    gap: 12px;
}


/* ============================================================
   7. MASTER FORM MODAL
   ============================================================ */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 23, 42, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

/* Modal container (form-card inside overlay) */
.modal-form-card {
    position: relative;
    padding: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    width: 90%;
    max-width: 1000px;
    max-height: 90vh;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 20px 60px -12px rgba(0, 0, 0, 0.3);
    animation: slideDownFade 0.3s ease-out;
}

/* Lab Test Master Table Styles */
.tm-table-input,
.tm-table-select {
    width: 100%;
    height: 24px;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    padding: 0 8px;
    font-size: 11px;
    background-color: #fff;
    color: #1e293b;
    outline: none;
    transition: all 0.2s;
}

.tm-table-input:focus,
.tm-table-select:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.1);
}

.tm-btn-icon-red {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border: none;
    border-radius: 4px;
    background-color: #fef2f2;
    color: #ef4444;
    cursor: pointer;
    transition: all 0.2s;
}

.tm-btn-icon-red:hover {
    background-color: #fee2e2;
    color: #dc2626;
    transform: scale(1.05);
}

.tm-param-input {
    width: 100%;
    height: 24px;
    border: none;
    background: transparent;
    font-size: 11px;
    color: #1e293b;
    outline: none;
    padding: 0 4px;
}

.modal-form-card form {
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
    min-height: 0;
}

/* Modal header bar */
.modal-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 32px;
    border-bottom: 1px solid #e5e7eb;
    background-color: #ffffff;
}

.modal-header-bar h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #1e293b;
    letter-spacing: -0.3px;
}

.modal-close-btn {
    background: transparent;
    border: none;
    color: #cbd5e1;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    border-radius: 6px;
    line-height: 1;
}

.modal-close-btn:hover {
    color: #ef4444;
    background: #fef2f2;
}

/* Master Autocomplete Dropdown */
.master-search-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1000;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    max-height: 200px;
    overflow-y: auto;
    padding: 0;
    margin-top: 4px;
}

.master-search-item {
    width: 100%;
    text-align: left;
    padding: 10px 16px;
    border: none;
    border-bottom: 1px solid #f1f5f9;
    background: transparent;
    cursor: pointer;
    font-size: 13px;
    color: #475569;
    transition: background 0.2s;
}

.master-search-item:hover {
    background: #f8fafc;
    color: #4f46e5;
}

.master-search-item:last-child {
    border-bottom: none;
}

/* Modal scrollable body */
.modal-body {
    padding: 32px;
    overflow-y: auto;
    flex: 1;
    background-color: #ffffff;
}

/* Modal footer / action bar */
.modal-footer-bar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 16px;
    padding: 24px 32px;
    width: 100%;
    box-sizing: border-box;
    background-color: #fafbfc;
    border-top: 1px solid #e5e7eb;
}

/* Billing Patient Search Dropdown */
.customer-search-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1050;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
    max-height: 280px;
    overflow-y: auto;
    margin-top: 8px;
    padding: 8px;
}

.customer-search-item {
    padding: 12px 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid #f8fafc;
}

.customer-search-item:last-child {
    border-bottom: none;
}

.customer-search-item:hover {
    background-color: #f1f5f9;
}

.cs-name {
    font-size: 14px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 2px;
}

.cs-details {
    font-size: 11px;
    font-weight: 500;
    color: #64748b;
    display: flex;
    gap: 8px;
    align-items: center;
}

/* Test Search Dropdown */
.test-search-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1060;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
    max-height: 300px;
    overflow-y: auto;
    margin-top: 8px;
    padding: 8px;
}

.test-search-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    border-bottom: 1px solid #f8fafc;
}

.test-search-item:last-child {
    border-bottom: none;
}

.test-search-item:hover {
    background-color: #f1f5f9;
}

.ts-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ts-name {
    font-size: 14px;
    font-weight: 700;
    color: #1e293b;
}

.ts-code {
    font-size: 11px;
    font-weight: 500;
    color: #64748b;
}

.ts-price {
    font-size: 14px;
    font-weight: 800;
    color: #4f46e5;
}


/* ============================================================
   8. FORM CARD (inline, non-modal)
   ============================================================ */
.form-card {
    background: #ffffff;
    border: 1px solid #f1f5f9;
    border-radius: 16px;
    padding: 40px;
    margin-bottom: 32px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.04);
    animation: slideDownFade 0.4s ease-out;
}

.form-section {
    margin-bottom: 32px;
}

.form-section:last-child {
    margin-bottom: 0;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    font-weight: 700;
    color: #4f46e5;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 0;
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f1f5f9;
}

.section-icon {
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(99, 102, 241, 0.3);
}

.section-icon svg {
    width: 14px;
    height: 14px;
}

.form-row {
    display: grid;
    gap: 16px;
    margin-bottom: 20px;
}

.form-row:last-child {
    margin-bottom: 0;
}

.form-group {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    flex: 1 1 100%;
}

.form-group label {
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 8px;
}

/* Form control (legacy) */
.form-control {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 14px;
    color: #1e293b;
    outline: none;
    transition: all 0.3s ease;
    font-family: 'Inter', sans-serif;
    box-sizing: border-box;
    width: 100%;
}

.form-control:focus {
    background: #ffffff;
    border-color: #6366f1;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.form-control::placeholder {
    color: #94a3b8;
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 16px;
    padding-right: 40px;
    color: #1e293b !important;
    background-color: #ffffff !important;
    height: 40px !important;
    font-size: 14px !important;
    padding: 0 40px 0 16px !important;
    line-height: 40px !important;
}

select.form-control option {
    color: #1e293b !important;
    background-color: #ffffff !important;
    padding: 8px !important;
}

textarea.form-control {
    min-height: 80px;
    resize: vertical;
}

/* Form column layouts */
.form-cols-4 {
    grid-template-columns: 1fr 1fr 1fr 1fr;
}

.form-cols-5 {
    grid-template-columns: 1fr 1fr 1fr 1fr 1fr;
}

.form-cols-4-area {
    grid-template-columns: 120px 1.5fr 1.5fr 2fr;
}

.form-cols-3-city {
    grid-template-columns: 1fr 1fr;
}

/* ============================================================
   17. BRANCH MASTER - REFACTORED
   ============================================================ */
.branch-master-container {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 5rem);
    /* Adjust based on MainLayout header if any */
    background-color: #f8fafc;
}

.branch-master-header {
    background: white;
    border-bottom: 1px solid #e2e8f0;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.branch-master-content {
    flex: 1;
    overflow-y: auto;
    padding: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* ============================================================
   17. TEST MASTER REDESIGN (Dynamic Dashboard)
   ============================================================ */
.tm-container {
    padding: 24px;
    background-color: #f8fafc;
    min-height: 100vh;
}

.tm-dashboard-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 24px;
    padding: 32px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
    margin-bottom: 24px;
}

.tm-grid-row-1 {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr 1fr;
    gap: 16px;
    margin-bottom: 24px;
}

.tm-grid-row-2 {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 24px;
}

.tm-grid-row-3 {
    display: flex;
    align-items: center;
    gap: 32px;
}

.tm-label-upper {
    font-size: 10px;
    font-weight: 800;
    color: #6366f1;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    display: block;
}

.tm-input-premium {
    height: 44px !important;
    background: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    font-size: 14px !important;
    padding: 0 16px !important;
    transition: all 0.2s ease;
}

.tm-input-premium:focus {
    background: #ffffff !important;
    border-color: #6366f1 !important;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1) !important;
}

.tm-radio-tile-group {
    display: flex;
    gap: 24px;
    align-items: center;
}

.tm-radio-item {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
}

.tm-radio-dot {
    width: 20px;
    height: 20px;
    border: 2px solid #cbd5e1;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.tm-radio-item:hover .tm-radio-dot {
    border-color: #6366f1;
}

input[type="radio"]:checked+.tm-radio-dot {
    border-color: #6366f1;
    background-color: #ffffff;
}

input[type="radio"]:checked+.tm-radio-dot::after {
    content: '';
    width: 10px;
    height: 10px;
    background: #6366f1;
    border-radius: 50%;
}

/* Split Layout */
.tm-split-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 24px;
}

.tm-left-panel {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.tm-panel-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.tm-panel-header {
    padding: 16px 20px;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ffffff;
}

.tm-param-list-premium {
    padding: 8px 0;
}

.tm-param-row {
    padding: 12px 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    border-bottom: 1px solid #f8fafc;
    transition: background 0.2s;
}

.tm-param-row:hover {
    background: #f8fafc;
}

.tm-check-circle {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 2px solid #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.tm-check-circle.checked {
    background: #6366f1;
    border-color: #6366f1;
}

.tm-check-circle.checked span {
    font-size: 14px;
}

.tm-panel-footer {
    padding: 16px 20px;
    background: #fdfdfd;
    border-top: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Settings Card (Right Side) */
.tm-settings-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 24px;
    padding: 32px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.tm-settings-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
}

.tm-tabs-row {
    display: flex;
    gap: 32px;
    border-bottom: 1px solid #f1f5f9;
    margin-bottom: 24px;
    padding: 0 8px;
}

.tm-tab-item {
    font-size: 13px;
    font-weight: 700;
    color: #94a3b8;
    padding: 12px 0;
    cursor: pointer;
    position: relative;
    text-transform: uppercase;
}

.tm-tab-item.active {
    color: #6366f1;
}

.tm-tab-item.active::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 3px;
    background: #6366f1;
    border-radius: 3px 3px 0 0;
}

.tm-template-box {
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
    margin-top: 24px;
}

.tm-editor-toolbar {
    padding: 8px 16px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tm-editor-textarea {
    width: 100%;
    min-height: 140px;
    padding: 20px;
    border: none;
    outline: none;
    font-family: inherit;
    font-size: 14px;
    color: #475569;
    resize: none;
    background: #ffffff;
}

.tm-settings-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 32px;
}

.btn-update-premium {
    padding: 12px 32px;
    background: #ffffff;
    border: 1px solid #ffedd5;
    color: #f97316;
    border-radius: 12px;
    font-weight: 700;
    font-size: 14px;
    transition: all 0.2s;
}

.btn-update-premium:hover {
    background: #fff7ed;
    border-color: #fdba74;
}

.btn-profile-black {
    background: #1e293b;
    color: white;
    padding: 10px 24px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 13px;
    transition: all 0.2s;
}

.btn-profile-black:hover {
    background: var(--lc-secondary);
    transform: translateY(-1px);
}

.branch-master-footer {
    background: white;
    border-top: 1px solid #e2e8f0;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.form-cols-branch-1 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.form-cols-branch-2 {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 1.5rem;
}

.btn-branch-save {
    background-color: #4C51BF !important;
    color: white !important;
}

.btn-branch-delete {
    background-color: #E53E3E !important;
    color: white !important;
}

.btn-branch-close {
    background-color: #4A5568 !important;
    color: white !important;
}

.branch-alert {
    background-color: #FFF5F5 !important;
    border: 1px solid #FED7D7 !important;
    color: #C53030 !important;
    padding: 0.75rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.header-search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--lc-slate-400);
}

.branch-color-preview {
    width: 38px;
    height: 38px;
    padding: 2px;
    border-radius: 8px;
    border: 1px solid var(--lc-border);
    background: white;
    cursor: pointer;
}

.form-group-span-2 {
    grid-column: span 2;
}

.branch-table-wrapper {
    max-height: 400px;
    overflow-y: auto;
}

.btn-table-action {
    min-width: 32px;
}

.form-cols-counter-1 {
    grid-template-columns: 2fr 1fr 2fr 1fr;
}

.form-cols-counter-2 {
    grid-template-columns: 1fr 1fr 1fr 1fr;
}

.form-cols-counter-3 {
    grid-template-columns: 1fr 3fr;
}

.custom-grid-general-1 {
    grid-template-columns: 80px 1.2fr 1.2fr 1fr 1.2fr 1fr;
}

.custom-grid-general-2 {
    grid-template-columns: 1fr 1fr 2fr;
}

.custom-grid-billing-1 {
    grid-template-columns: 1.2fr 1.5fr 1fr 1fr;
}

.custom-grid-billing-2 {
    grid-template-columns: 1fr 1fr 2fr;
}

.custom-grid-comm-1,
.custom-grid-comm-2,
.custom-grid-comm-3 {
    grid-template-columns: repeat(4, 1fr);
}

.custom-grid-comm-4 {
    grid-template-columns: 2fr 1fr 1fr;
}

/* Pay type buttons */
.pay-type-buttons {
    display: flex;
    background: #f1f5f9;
    border-radius: 12px;
    padding: 4px;
    gap: 4px;
    box-sizing: border-box;
}

.pay-btn {
    flex: 1;
    border: none;
    background: transparent;
    padding: 8px 0;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
}

.pay-btn:hover {
    color: #1e293b;
}

.pay-btn.active {
    background: #ffffff;
    color: #6366f1;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
}

.sms-alert {
    color: #ef4444;
    font-size: 10px;
    margin-top: 6px;
}

/* Form actions bar */
.form-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 16px;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid #e2e8f0;
}

.running-total {
    margin-right: auto;
    display: flex;
    align-items: baseline;
    gap: 12px;
}

.total-label {
    font-size: 12px;
    font-weight: 600;
    color: #94a3b8;
    text-transform: uppercase;
}

.total-amount {
    font-size: 20px;
    font-weight: 700;
    color: #6366f1;
}

.btn-delete {
    background: transparent;
    border: none;
    color: #ef4444;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    padding: 8px 16px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.btn-close {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    color: #475569;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    padding: 12px 28px;
    border-radius: 12px;
    transition: all 0.2s;
}

.btn-close:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
}

.btn-save {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: white;
    border: none;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    padding: 12px 28px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-save:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.4);
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
}

.error-input {
    border-color: #ef4444 !important;
    background-color: #ffffff !important;
}

.error-text {
    color: #ef4444 !important;
}


/* ============================================================
   9. DIRECTORY TABLE
   ============================================================ */
.directory-section {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    overflow: hidden;
}

.directory-header {
    padding: 16px 24px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ffffff;
}

.directory-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
}

.directory-controls {
    display: flex;
    align-items: center;
    gap: 16px;
}

.search-controls {
    display: flex;
    gap: 12px;
}

.show-entries {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 6px 12px;
    font-size: 13px;
    color: #475569;
    outline: none;
    cursor: pointer;
    font-weight: 600;
}

.btn-filter,
.btn-export {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.btn-filter:hover,
.btn-export:hover {
    background: #f1f5f9;
}

.table-wrapper {
    overflow-x: auto;
}

.directory-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.directory-table th {
    position: sticky;
    top: 0;
    z-index: 10;
    background: #6366f1;
    color: #ffffff;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 10px 16px;
}

.directory-table td {
    padding: 8px 16px;
    border-bottom: 1px solid #e2e8f0;
    font-size: 13px;
    color: #475569;
    vertical-align: middle;
}

.directory-table tbody tr:hover {
    background: #f8fafc;
}

/* Directory table cell helpers */
.td-order-no {
    color: #6366f1;
    font-weight: 700;
}

.td-name {
    font-weight: 600;
    color: #1e293b;
}

.td-narration {
    color: #94a3b8;
    font-size: 13px;
}

.code-link {
    color: #6366f1;
    font-weight: 700;
    cursor: pointer;
}

.doctor-name {
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 4px;
}

.doctor-email {
    font-size: 12px;
    color: #94a3b8;
}

/* Status badges */
.status-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.status-active {
    background: #dcfce7;
    color: #16a34a;
}

.status-inactive {
    background: #fee2e2;
    color: #dc2626;
}

.status-progress {
    background: #fef3c7;
    color: #d97706;
}

/* Table action buttons */
.btn-action {
    background: transparent;
    border: none;
    cursor: pointer;
    color: #94a3b8;
    font-size: 14px;
    padding: 4px 8px;
    transition: color 0.2s;
}

.btn-edit:hover {
    color: #6366f1;
}

.btn-delete-action:hover {
    color: #ef4444;
}


/* ============================================================
   10. CUSTOM CARD (Counter / Branch inline layout)
   ============================================================ */
.custom-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.custom-card .form-control {
    height: 32px;
    padding: 0.25rem 0.5rem;
    font-size: 13px;
    border-radius: 6px;
}

.custom-card .form-label {
    font-size: 10px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    margin-bottom: 4px;
    letter-spacing: 0.5px;
}

.custom-card select.form-control {
    height: 40px !important;
    line-height: normal !important;
}

/* Lab header card */
.lab-header-card {
    background: transparent !important;
    border: none !important;
    border-bottom: 1.5px solid #e2e8f0 !important;
    box-shadow: none !important;
    padding: 8px 0 16px 0 !important;
    border-radius: 0 !important;
    display: flex;
    align-items: center;
    margin-bottom: 20px !important;
}

.lab-title-text {
    color: #0f172a !important;
    font-size: 1.35rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.025em;
}

/* Lab Header Variations */
.lab-header-card.flex-between {
    justify-content: space-between;
    margin-bottom: 20px !important;
}

/* Lab header sub-elements */
.lab-header-ops-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #f8fafc;
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.lab-header-ops-label {
    color: #64748b;
    font-size: 0.75rem;
    font-weight: 700;
}

.lab-header-ops-value {
    color: var(--lc-secondary);
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
}

.lab-header-ops-placeholder {
    color: #94a3b8;
    font-size: 0.75rem;
    font-weight: 600;
}

.lab-header-tenant-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: white;
    padding: 4px 14px;
    border-radius: 100px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.25);
}

.lab-header-active-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: linear-gradient(135deg, #0ea5e9 0%, #2563eb 100%);
    color: white;
    padding: 4px 14px;
    border-radius: 100px;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
}

/* Lab input (shared) */
.lab-input {
    width: 100%;
    padding: 0.625rem 0.875rem;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    background-color: #f8fafc;
    font-size: 0.875rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.lab-input:focus {
    outline: none;
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.lab-input-lg {
    padding: 1rem 1rem;
    font-size: 1rem;
    min-height: 48px;
}

.lab-input-lg:focus {
    outline: none;
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

/* Tab buttons */
.btn-tab {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-right: none;
    padding: 0.4rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 500;
    color: #1e293b;
    cursor: pointer;
    outline: none;
}

.btn-tab:last-child {
    border-right: 1px solid #e2e8f0;
}

.active-tab {
    background: white;
    color: #1e293b;
    border-top: 1px solid #e2e8f0;
    border-bottom: 1px solid white;
    border-left: 1px solid #e2e8f0;
    border-right: 1px solid #e2e8f0;
}

.active-tab+.btn-tab {
    border-left: none;
}


/* ============================================================
   11. BRANCH / COUNTER PAGE — SECTION CARDS
   ============================================================ */
.page-section-card {
    background: white;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.page-section-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-color, #e2e8f0);
    background: #f8fafc;
}

.page-section-card-header h3 {
    font-family: 'Inter', sans-serif;
    font-weight: 800;
    font-size: 1.1rem;
    color: #1e293b;
    margin: 0;
}

.page-section-card-count {
    font-family: 'Inter', sans-serif;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--primary, #4f46e5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Global Spacing Utilities */
.mb-0 {
    margin-bottom: 0 !important;
}

.mb-6 {
    margin-bottom: 24px !important;
}

.mt-6 {
    margin-top: 24px !important;
}

.text-center {
    text-align: center !important;
}

.p-24 {
    padding: 24px !important;
}

/* Color dot used in branch/counter lists */
.color-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}

/* Branch / counter table scrollable wrapper */
.scrollable-table-wrapper {
    max-height: 400px;
    overflow-y: auto;
}

/* Branch form sub-heading */
.form-section-heading {
    margin: 0 0 1.5rem 0;
    font-family: 'Inter', sans-serif;
    font-weight: 800;
    font-size: 1.1rem;
    color: #1e293b;
}

/* Branch Type checkbox row */
.branch-type-row {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    height: 40px;
    padding-left: 4px;
}

.branch-type-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.875rem;
    cursor: pointer;
    font-weight: 600;
    color: #1e293b;
}

/* Card footer actions */
.card-footer-actions {
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-color, #e2e8f0);
    background: white;
    border-radius: 1rem;
}

.footer-left-controls {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.footer-right-controls {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.display-active-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted, #64748b);
}

.btn-footer-cancel {
    background: transparent;
    border: none;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted, #64748b);
    cursor: pointer;
}

.btn-footer-delete {
    background: #ef4444;
    color: white;
    padding: 0.5rem 1.5rem;
    font-size: 0.875rem;
    border-radius: 0.5rem;
    font-weight: 700;
    border: none;
    cursor: pointer;
}

.btn-footer-save {
    background: var(--primary, #4f46e5);
    color: white;
    padding: 0.5rem 2rem;
    font-size: 0.875rem;
    border-radius: 0.5rem;
    font-weight: 700;
    border: none;
    cursor: pointer;
}

.btn-footer-close {
    background: #64748b;
    color: white;
    padding: 0.5rem 1.5rem;
    font-size: 0.875rem;
    border-radius: 0.5rem;
    font-weight: 700;
    border: none;
    cursor: pointer;
}

.btn-footer-delete:disabled,
.btn-footer-save:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Alert messages (branch / counter inline) */
.alert {
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 1rem;
}

.alert-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fee2e2;
}

.alert-success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #dcfce7;
}


/* ============================================================
   12. COUNTER PAGE — CARD HEADER / BODY
   ============================================================ */
.card-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color, #e2e8f0);
    padding: 1.5rem;
    background: white;
}

.card-header-left {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.card-header-title {
    font-family: 'Inter', sans-serif;
    font-weight: 800;
    font-size: 1.5rem;
    margin: 0;
    color: #1e293b;
    letter-spacing: -0.5px;
}

.card-header-subtitle {
    margin: 0;
    font-size: 0.875rem;
    color: #64748b;
    font-weight: 500;
}

.card-header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.search-input-wrapper {
    position: relative;
    width: 250px;
}

.search-input-wrapper .search-icon {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted, #64748b);
    font-size: 1.25rem;
    pointer-events: none;
}

/* Color input row */
.color-input-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    height: 40px;
}

.color-input-value {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted, #64748b);
}

.active-checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.active-checkbox-label span {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--primary, #4f46e5);
}


/* ============================================================
   13. BADGES (legacy support)
   ============================================================ */
.badge {
    padding: 0.25rem 0.625rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.badge-success {
    background-color: #dcfce7;
    color: #15803d;
}

.badge-warning {
    background-color: #fef3c7;
    color: #b45309;
}

.badge-danger {
    background-color: #fee2e2;
    color: #b91c1c;
}



/* ============================================================
   14. FORGOT PASSWORD PAGE
   ============================================================ */
.auth-page-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f8fafc;
    position: relative;
    overflow: hidden;
    font-family: 'Inter', sans-serif;
}

.background-mesh {
    position: absolute;
    width: 100%;
    height: 100%;
    background-color: #f8fafc;
    background-image:
        radial-gradient(at 0% 0%, hsla(253, 16%, 7%, 0.1) 0, transparent 50%),
        radial-gradient(at 50% 0%, hsla(225, 39%, 30%, 0.1) 0, transparent 50%),
        radial-gradient(at 100% 0%, hsla(339, 49%, 30%, 0.1) 0, transparent 50%);
    z-index: 0;
}

.auth-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 480px;
    padding: 20px;
}

.auth-card {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.brand-section {
    padding: 40px 40px 20px;
    text-align: center;
}

.logo-circle {
    width: 64px;
    height: 64px;
    background: #4F46E5;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.3);
}

.brand-section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 4px;
}

.brand-section p {
    color: #64748b;
    font-size: 0.875rem;
}

.auth-form-content {
    padding: 0 40px 40px;
}

.form-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 8px;
}

.form-subtitle {
    color: #64748b;
    font-size: 0.875rem;
    margin-bottom: 24px;
}

.auth-page-wrapper .form-group {
    margin-bottom: 20px;
}

.auth-page-wrapper .form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #475569;
    margin-bottom: 8px;
}

.input-container {
    position: relative;
}

.input-container i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
}

.auth-page-wrapper .form-control {
    width: 100%;
    padding: 12px 16px 12px 44px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    transition: all 0.2s;
    font-size: 0.875rem;
}

.auth-page-wrapper .form-control:focus {
    background: #fff;
    border-color: #4F46E5;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
    outline: none;
}

.auth-page-wrapper .btn-primary {
    width: 100%;
    padding: 12px;
    background: #4F46E5;
    border: none;
    border-radius: 12px;
    color: white;
    font-weight: 600;
    transition: all 0.2s;
    margin-top: 10px;
}

.auth-page-wrapper .btn-primary:hover:not(:disabled) {
    background: #4338ca;
    transform: translateY(-1px);
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.2);
}

.auth-page-wrapper .btn-primary:active {
    transform: translateY(0);
}

.btn-link {
    background: none;
    border: none;
    color: #4F46E5;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0;
    cursor: pointer;
}

.alert-danger {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fee2e2;
}

.auth-footer {
    margin-top: 32px;
    text-align: center;
    font-size: 0.875rem;
    color: #64748b;
}

.auth-footer a {
    color: #4F46E5;
    font-weight: 600;
    text-decoration: none;
}

.auth-footer a:hover {
    text-decoration: underline;
}

.reset-account-info {
    background: rgba(79, 70, 229, 0.1);
    border: 1px solid rgba(79, 70, 229, 0.2);
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.875rem;
    color: #4F46E5;
}

.reset-account-info i {
    font-size: 1.1rem;
}


/* ============================================================
   15. LOGIN PAGE
   ============================================================ */
.login-page-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: stretch;
    font-family: 'Inter', sans-serif;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, var(--lc-secondary) 0%, #1e1b4b 50%, var(--lc-secondary) 100%);
}

.login-bg-pattern {
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(ellipse 60% 60% at 10% 20%, rgba(99, 102, 241, 0.25) 0%, transparent 60%),
        radial-gradient(ellipse 50% 50% at 90% 80%, rgba(124, 58, 237, 0.2) 0%, transparent 60%),
        radial-gradient(ellipse 40% 40% at 50% 50%, rgba(79, 70, 229, 0.1) 0%, transparent 70%);
    z-index: 0;
    animation: bgShift 12s ease-in-out infinite alternate;
}

@keyframes bgShift {
    from {
        opacity: 1;
    }

    to {
        opacity: 0.7;
    }
}

.login-container {
    position: relative;
    z-index: 1;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px 20px;
    min-height: 100vh;
}

.login-content {
    width: 100%;
    max-width: 440px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.login-card {
    width: 100%;
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 28px;
    padding: 44px 40px;
    box-shadow: 0 32px 64px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1);
    animation: fadeInUp 0.5s ease-out;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 36px;
}

.brand-logo-rect {
    fill: #6366f1;
}

.brand-logo-path {
    fill: white;
}

.brand-name {
    font-size: 1.375rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: -0.5px;
}

.brand-subtitle {
    font-size: 0.6rem;
    font-weight: 700;
    color: #818cf8;
    letter-spacing: 2.5px;
    text-transform: uppercase;
    margin-top: 2px;
}

.login-title {
    font-size: 1.75rem;
    font-weight: 800;
    color: #ffffff;
    margin: 0 0 6px 0;
    letter-spacing: -0.75px;
}

.login-subtitle {
    color: rgba(148, 163, 184, 0.9);
    font-size: 0.825rem;
    margin-bottom: 32px;
    font-weight: 400;
    line-height: 1.6;
}

.login-form-group {
    margin-bottom: 14px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 14px;
    color: rgba(148, 163, 184, 0.7);
    pointer-events: none;
    display: flex;
    align-items: center;
    z-index: 1;
}

.login-input {
    width: 100%;
    padding: 14px 16px 14px 46px;
    background: rgba(255, 255, 255, 0.08);
    border: 1.5px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    font-size: 0.875rem;
    color: #ffffff;
    font-weight: 500;
    transition: all 0.25s ease;
    outline: none;
    font-family: 'Inter', sans-serif;
}

.login-input:focus {
    background: rgba(255, 255, 255, 0.12);
    border-color: #6366f1;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
}

.login-input::placeholder {
    color: rgba(148, 163, 184, 0.6);
    font-weight: 400;
}

.password-toggle {
    position: absolute;
    right: 14px;
    background: none;
    border: none;
    cursor: pointer;
    color: rgba(148, 163, 184, 0.7);
    padding: 4px;
    display: flex;
    align-items: center;
    transition: color 0.2s;
}

.password-toggle:hover {
    color: #a5b4fc;
}

.status-message {
    color: #fca5a5;
    font-size: 0.8rem;
    text-align: center;
    padding: 10px 14px;
    margin-bottom: 8px;
    font-weight: 500;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 10px;
}

.btn-login {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 60%, #4338ca 100%);
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s ease;
    letter-spacing: 0.3px;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.5);
    font-family: 'Inter', sans-serif;
    position: relative;
    overflow: hidden;
}

.btn-login::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.btn-login:hover:not(:disabled)::before {
    left: 100%;
}

.btn-login:hover:not(:disabled) {
    background: linear-gradient(135deg, #7c3aed 0%, #6366f1 60%, #4f46e5 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.6);
}

.btn-login:active {
    transform: translateY(0);
    box-shadow: 0 4px 10px rgba(99, 102, 241, 0.4);
}

.btn-login:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.forgot-password {
    text-align: right;
    margin: 14px 0 0;
}

.forgot-password a {
    color: rgba(148, 163, 184, 0.8);
    font-size: 0.8rem;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s;
}

.forgot-password a:hover {
    color: #a5b4fc;
}

.login-footer-text {
    text-align: center;
    margin-top: 28px;
    font-size: 0.825rem;
    color: rgba(148, 163, 184, 0.7);
    padding-top: 22px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.register-link {
    color: #a5b4fc;
    font-weight: 700;
    text-decoration: none;
}

.register-link:hover {
    color: #818cf8;
    text-decoration: underline;
}

.login-bottom-footer {
    text-align: center;
    padding: 24px 0 8px;
}

.footer-link {
    color: rgba(100, 116, 139, 0.7);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-link:hover {
    color: #818cf8;
}

.footer-separator {
    color: rgba(203, 213, 225, 0.3);
    margin: 0 12px;
    font-size: 0.5rem;
}

/* Branch color input */
.branch-color-input {
    width: 42px;
    height: 42px;
    padding: 2px;
    border-radius: 8px;
    border: 1.5px solid #e2e8f0;
    background: white;
    cursor: pointer;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.branch-color-input:hover {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

/* Table status indicator dot (replaces color-dot) */
.table-status-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
    display: inline-block;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.8);
}


/* ============================================================
   16. REFERRAL MASTER PAGE
   ============================================================ */
.referral-header-details {
    display: flex;
    flex-direction: column;
}

.referral-subtitle {
    font-size: 14px;
    color: #94a3b8;
    font-weight: 600;
    margin: 0;
}

.search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
}

.search-icon-inline {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
}

.search-input-pill {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 8px 16px 8px 36px;
    font-size: 13px;
    color: #1e293b;
    outline: none;
    width: 200px;
    transition: all 0.2s;
}

.search-input-pill:focus {
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.doctor-detail-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.doctor-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #e0e7ff;
    color: #4f46e5;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    flex-shrink: 0;
}

.tm-dropdown-item {
    padding: 10px 14px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.tm-dropdown-item:hover {
    background: #f1f5f9;
}

.tm-dropdown-name {
    font-size: 13.5px;
    font-weight: 700;
    color: #1e293b;
    text-transform: uppercase;
}

.tm-dropdown-shortname {
    font-size: 11px;
    font-weight: 600;
    color: #94a3b8;
    letter-spacing: 0.5px;
}

.tm-input-accent {
    border: 1.5px solid #cbd5e1 !important;
    background: white !important;
    font-weight: 500 !important;
}

.tm-input-accent:focus {
    border-color: #6366f1 !important;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1) !important;
}

.doctor-info-text {
    display: flex;
    flex-direction: column;
}

/* ============================================================
   12. TEST MASTER PANEL ACTIONS
   ============================================================ */
.tm-panel-header {
    display: flex;
    justify-content: space-between;
    align-center: items-center;
    padding: 16px 24px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    border: 1px solid #e2e8f0;
}

.tm-panel-badge {
    padding: 4px 12px;
    background: #eef2ff;
    color: #4f46e5;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
}

.tm-panel-title {
    font-size: 20px;
    font-weight: 800;
    color: #1e293b;
    margin: 0;
}

.tm-btn-outline {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: white;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    color: #475569;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.tm-btn-outline:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #1e293b;
}

.tm-btn-primary {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 24px;
    background: #4f46e5;
    border: none;
    border-radius: 12px;
    color: white;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.25);
    transition: all 0.2s;
}

.tm-btn-primary:hover {
    background: #4338ca;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(79, 70, 229, 0.3);
}

.tm-btn-danger {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: #fff1f2;
    border: 1.5px solid #fecdd3;
    border-radius: 12px;
    color: #e11d48;
    cursor: pointer;
    transition: all 0.2s;
}

.tm-btn-danger:hover {
    background: #ffe4e6;
    border-color: #fda4af;
    color: #be123c;
}

.doctor-name-text {
    font-weight: 600;
    color: #1e293b;
}

.doctor-email-text {
    font-size: 11px;
    color: #64748b;
}

.form-grid-prefix {
    display: grid;
    grid-template-columns: 80px 1fr;
    gap: 16px;
}

.form-grid-doctor-details {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.form-grid-two-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.pay-type-buttons {
    display: flex;
    gap: 8px;
}

.pay-btn {
    flex: 1;
    padding: 8px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #fff;
    color: #64748b;
    font-weight: 500;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s;
}

.pay-btn.active {
    background: #6366f1;
    color: #fff;
    border-color: #6366f1;
}

/* Directory Section & Table */
.directory-section {
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid #f1f5f9;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
    margin-top: 24px;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

.directory-header {
    padding: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #f1f5f9;
    flex-shrink: 0;
}

.directory-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 700;
    color: #1e293b;
}

.table-wrapper {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    overflow-x: auto;
    padding: 0;
}

.directory-table {
    width: 100%;
    border-collapse: collapse;
}

.directory-table th {
    position: sticky;
    top: 0;
    z-index: 10;
    background-color: #f8fafc;
    padding: 10px 16px;
    text-align: left;
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #f1f5f9;
}

.directory-table td {
    padding: 8px 16px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 14px;
    color: #475569;
}

.directory-table tr:hover {
    background-color: #f8fafc;
}

.code-link {
    font-weight: 700;
    color: #4f46e5;
}

.btn-action {
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
    margin: 0 2px;
}

.btn-edit:hover:not(:disabled) {
    border-color: #6366f1;
    color: #6366f1;
}

.btn-delete-action:hover:not(:disabled) {
    border-color: #ef4444;
    color: #ef4444;
}

.btn-action:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.doctor-name {
    font-weight: 700;
    color: #1e293b;
}

.doctor-email {
    font-size: 12px;
    color: #64748b;
}

.pagination-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    border-top: 1px solid #f1f5f9;
    background-color: #fff;
    border-bottom-left-radius: 16px;
    border-bottom-right-radius: 16px;
}

.pagination-info {
    font-size: 13px;
    color: #64748b;
}

.pagination-info-highlight {
    font-weight: 600;
    color: #334155;
}

.pagination-btns {
    display: flex;
    gap: 6px;
}

.page-btn {
    min-width: 32px;
    height: 32px;
    padding: 0 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    background: #fff;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 13px;
    font-weight: 500;
}

.page-btn:hover:not(:disabled) {
    border-color: #6366f1;
    color: #6366f1;
}

.page-btn:disabled {
    cursor: not-allowed;
    opacity: 0.5;
}

.page-btn.active {
    border-color: #6366f1;
    background: #6366f1;
    color: #fff;
    cursor: default;
    font-weight: 600;
}

.page-btn-icon {
    width: 32px;
}

/* ============================================================
   17. BRANCH MASTER PAGE
   ============================================================ */
.branch-ops-tag {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: #f8fafc;
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.branch-ops-label {
    color: #64748b;
    font-size: 0.75rem;
    font-weight: 700;
}

.branch-ops-value {
    color: var(--lc-secondary);
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
}

.branch-ops-placeholder {
    color: #94a3b8;
    font-size: 0.75rem;
    font-weight: 600;
}

.tenant-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    color: white;
    padding: 4px 14px;
    border-radius: 100px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.25);
}

.form-cols-branch-1 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.form-cols-branch-2 {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 1.5rem;
}

.color-input-container {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.branch-color-input {
    width: 3rem;
    height: 2.25rem;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 0.5rem;
    padding: 2px;
    background: white;
    cursor: pointer;
}

.branch-type-group {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    height: 40px;
    padding-left: 4px;
}

.branch-type-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.875rem;
    cursor: pointer;
    font-weight: 600;
    color: #1e293b;
}

.table-status-indicator {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
}

.btn-delete-solid {
    background: #ef4444;
    color: white;
    padding: 0.5rem 1.5rem;
    font-size: 0.875rem;
    border-radius: 0.5rem;
    font-weight: 700;
}

.btn-save-solid {
    background: var(--primary, #4f46e5);
    color: white;
    padding: 0.5rem 2rem;
    font-size: 0.875rem;
    border-radius: 0.5rem;
    font-weight: 700;
}

.btn-close-solid {
    background: #64748b;
    color: white;
    padding: 0.5rem 1.5rem;
    font-size: 0.875rem;
    border-radius: 0.5rem;
    font-weight: 700;
}

/* ============================================================
   18. MODIFY TEST MASTER PAGE
   ============================================================ */
.test-master-actions {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

.test-master-action-item {
    color: var(--primary, #4f46e5);
    font-weight: 700;
    cursor: pointer;
    font-size: 0.8125rem;
    text-transform: uppercase;
}

.test-master-grid-1 {
    display: grid;
    grid-template-columns: 2.2fr 1fr 1.5fr 2fr 2fr 1fr;
    gap: 1rem;
}

.test-master-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.test-master-grid-settings {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.test-dropdown-overlay {
    position: absolute;
    background: #ffffff;
    border: 1px solid var(--primary, #4f46e5);
    border-top: 0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    top: 100%;
    left: 0;
    right: -150%;
    z-index: 100;
    max-height: 15rem;
    overflow-y: auto;
}

.test-dropdown-item {
    display: flex;
    cursor: pointer;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.875rem;
}

.test-dropdown-name {
    flex-grow: 1;
    padding: 0.5rem 0.75rem;
    border-right: 1px solid #e2e8f0;
    color: #1e293b;
}

.test-dropdown-group {
    padding: 0.5rem 0.75rem;
    color: #64748b;
    width: 150px;
}

.param-list-card {
    background: #ffffff;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 0.75rem;
    overflow: hidden;
    width: 320px;
}

.param-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.param-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    width: 1.25rem;
    height: 1.25rem;
}

.template-editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--border-color, #e2e8f0);
    border-bottom: 0;
    border-radius: 0.5rem 0.5rem 0 0;
    padding: 0.5rem 0.75rem;
    background-color: #f8fafc;
}

.template-editor-toolbar {
    display: flex;
    gap: 0.75rem;
    font-weight: 700;
    font-size: 0.875rem;
    cursor: pointer;
    color: #1e293b;
}

.template-editor-textarea {
    border-color: var(--border-color, #e2e8f0);
    border-top: 0;
    border-radius: 0 0 0.5rem 0.5rem;
    resize: none;
    box-shadow: none;
}

.graph-toggle {
    position: relative;
    display: inline-block;
    border-radius: 100px;
    border: 1px solid #e2e8f0;
    width: 28px;
    height: 16px;
    background-color: #f1f5f9;
}

.graph-toggle-thumb {
    position: absolute;
    background-color: #ffffff;
    border-radius: 50%;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    width: 12px;
    height: 12px;
    left: 1px;
    top: 1px;
}

.btn-update-orange {
    background: transparent;
    border: 1px solid #f97316;
    color: #f97316;
    font-weight: 600;
    padding: 0.25rem 1.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    height: 32px;
    letter-spacing: 0.5px;
    transition: all 0.2s;
}

.btn-update-orange:hover {
    background: #f97316;
    color: #ffffff;
}

/* ============================================================
   20. COUNTER MASTER PAGE
   ============================================================ */
.form-cols-counter-1 {
    display: grid;
    grid-template-columns: 2fr 1fr 2fr 1fr;
    gap: 1.5rem;
}

.form-cols-counter-2 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 1.5rem;
}

.form-cols-counter-3 {
    display: grid;
    grid-template-columns: 1fr 3fr;
    gap: 1.5rem;
}

.counter-color-preview {
    width: 3rem;
    height: 2.25rem;
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 0.5rem;
    padding: 2px;
    background: #ffffff;
    cursor: pointer;
}

.counter-dot {
    width: 0.5rem;
    height: 0.5rem;
    border-radius: 50%;
}

/* ============================================================
   21. RESPONSIVE BREAKPOINTS
   ============================================================ */
@media (max-width: 1200px) {
    .custom-grid-general-1 {
        grid-template-columns: 80px 1fr 1.2fr 1fr;
    }

    .custom-grid-general-2 {
        grid-template-columns: 1fr 1fr;
    }

    .custom-grid-billing-1 {
        grid-template-columns: 1fr 1fr;
    }

    .custom-grid-comm-1,
    .custom-grid-comm-2,
    .custom-grid-comm-3 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .referral-page {
        padding: 16px;
    }

    .referral-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .header-actions {
        width: 100%;
        flex-wrap: wrap;
    }

    .header-search-input {
        width: 100% !important;
    }

    .form-row {
        display: flex;
        flex-direction: column;
        gap: 12px;
    }

    .form-cols-4,
    .form-cols-4-area,
    .form-cols-3-city,
    .form-cols-branch-1,
    .form-cols-branch-2,
    .form-cols-branch-3,
    .form-cols-counter-1,
    .form-cols-counter-2,
    .form-cols-counter-3,
    .custom-grid-general-1,
    .custom-grid-general-2,
    .custom-grid-billing-1,
    .custom-grid-billing-2,
    .custom-grid-comm-1,
    .custom-grid-comm-2,
    .custom-grid-comm-3,
    .custom-grid-comm-4 {
        grid-template-columns: 1fr !important;
    }
}

/* ============================================================
   22. MASTER DATA COMMON STYLES (Area, City, State, Country)
   ============================================================ */
.form-cols-4-area {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.form-cols-3-city {
    display: grid;
    grid-template-columns: repeat(2, 1fr) 2fr;
    gap: 1.5rem;
}

.master-search-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid var(--lc-border);
    border-radius: 8px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    z-index: 50;
    max-height: 200px;
    overflow-y: auto;
    display: none;
}

.master-search-dropdown.show {
    display: block;
}

.master-search-item {
    width: 100%;
    padding: 10px 16px;
    text-align: left;
    background: none;
    border: none;
    border-bottom: 1px solid var(--lc-slate-100);
    cursor: pointer;
    font-size: 14px;
    transition: background 0.2s;
}

.master-search-item:hover {
    background: var(--lc-slate-50);
}

.master-search-item:last-child {
    border-bottom: none;
}

/* ============================================================
   23. MODIFY TEST MASTER - TABS CONTENT
   ============================================================ */
.tab-scroller {
    margin-bottom: -1px;
}

.ref-table-wrapper {
    height: 15rem;
    overflow: auto;
    border: 1px solid var(--lc-border);
}

.ref-table {
    width: 100%;
    font-size: 0.8125rem;
    border-collapse: collapse;
}

.ref-table th,
.ref-table td {
    border: 1px solid var(--lc-border);
    padding: 0.25rem;
}

.ref-table .col-icon {
    width: 2rem;
}

.ref-table .col-sex {
    width: 25%;
}

.ref-table .star-big {
    font-size: 1rem;
}

.lab-checkbox-sm {
    width: 13px !important;
    height: 13px !important;
    margin: 0 !important;
    border-radius: 0 !important;
    cursor: pointer !important;
}

.lab-radio-sm {
    margin: 0 !important;
    cursor: pointer !important;
}

.lab-textarea-bordered {
    border: 1px solid #a1a1aa !important;
    resize: none !important;
    border-radius: 0 !important;
    background: white;
}

.specimen-table-container {
    border: 1px solid var(--lc-border);
    margin-bottom: 1.25rem;
    width: 100%;
    max-width: 500px;
}

.bg-specimen-active {
    background: #0ea5e9 !important;
    color: white !important;
}

.btn-row-action {
    width: 100%;
    background: #e2e8f0;
    height: 1.25rem;
    border: 1px solid var(--lc-slate-400);
    outline: none;
    cursor: pointer;
}

.text-update-orange {
    color: #f97316 !important;
    font-size: 0.875rem;
    font-weight: 600;
}

/* ============================================================
   24. MODIFY TEST MASTER - CONSOLE STYLES
   ============================================================ */
.custom-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    overflow: hidden;
    height: 100%;
}

.test-master-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.test-master-action-item {
    color: var(--lc-primary);
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s;
}

.test-master-action-item:hover {
    opacity: 0.8;
}

.avatar-pink {
    background: #FFD1DC;
    color: #E83F6F;
}

.test-master-grid-1 {
    display: grid;
    grid-template-columns: 2.2fr 1fr 1.5fr 2fr 2fr 1fr;
    gap: 1rem;
}

.test-master-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.test-master-grid-settings {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.test-dropdown-overlay {
    position: absolute;
    background: white;
    border: 1px solid var(--lc-primary);
    border-top: none;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    top: 100%;
    left: 0;
    right: -150%;
    z-index: 100;
    max-height: 15rem;
    overflow-y: auto;
}

.test-dropdown-item {
    display: flex;
    cursor: pointer;
    border-bottom: 1px solid var(--lc-border);
    font-size: 13px;
    transition: background 0.2s;
}

.test-dropdown-item:hover {
    background: var(--lc-slate-50);
}

.test-dropdown-name {
    flex-grow: 1;
    padding: 8px 16px;
    border-right: 1px solid var(--lc-border);
    color: var(--lc-slate-900);
}

.test-dropdown-group {
    padding: 8px 16px;
    color: var(--lc-slate-500);
    width: 150px;
}

.param-list-card {
    background: white;
    border: 1px solid var(--lc-border);
    border-radius: 12px;
    overflow: hidden;
}

.param-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid var(--lc-border);
}

.param-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    border: 1px solid var(--lc-border);
}

.template-editor-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--lc-border);
    border-bottom: none;
    border-radius: 8px 8px 0 0;
    padding: 8px 12px;
    background-color: #f8fafc;
}

.template-editor-toolbar {
    display: flex;
    gap: 12px;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    color: var(--lc-slate-900);
}

.template-editor-textarea {
    border-top: none !important;
    border-radius: 0 0 8px 8px !important;
    box-shadow: none !important;
    resize: none !important;
    height: 100px;
}

.graph-toggle {
    position: relative;
    display: inline-block;
    border-radius: 9999px;
    border: 1px solid var(--lc-border);
    width: 28px;
    height: 16px;
    background-color: #f1f5f9;
}

.graph-toggle-thumb {
    position: absolute;
    background-color: white;
    border-radius: 50%;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    width: 12px;
    height: 12px;
    left: 1px;
    top: 1px;
}

.btn-update-orange {
    background: transparent;
    font-weight: 600;
    border: 1px solid #f97316;
    color: #f97316 !important;
    padding: 4px 24px;
    border-radius: 4px;
    font-size: 12px;
    height: 32px;
    letter-spacing: 0.5px;
    transition: all 0.2s;
}

.btn-update-orange:hover {
    background: #f97316;
    color: white !important;
}

.btn-tab {
    padding: 12px 24px;
    font-size: 13px;
    font-weight: 700;
    color: var(--lc-slate-400);
    background: transparent;
    border: none;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-tab:hover {
    color: var(--lc-primary);
}

.btn-tab.active-tab {
    color: var(--lc-primary);
    border-bottom-color: var(--lc-primary);
    background: rgba(79, 70, 229, 0.05);
}

.hover-primary:hover {
    color: var(--lc-primary) !important;
}

.right-1 {
    right: 1px !important;
    left: auto !important;
}

.left-1 {
    left: 1px !important;
    right: auto !important;
}

.bg-specimen-active {
    background-color: #f0fdf4 !important;
    color: #166534 !important;
    font-weight: 700;
}

.ref-table {
    width: 100%;
    border-collapse: collapse;
}

.ref-table th {
    padding: 10px 12px;
    font-size: 12px;
    font-weight: 700;
    color: var(--lc-slate-400);
    text-transform: uppercase;
    border-bottom: 1px solid var(--lc-border);
}

.ref-table td {
    padding: 8px 12px;
    font-size: 13px;
    border-bottom: 1px solid var(--lc-slate-100);
}

.hover-slate-50:hover {
    background-color: var(--lc-slate-50);
}

.col-icon {
    width: 40px;
    text-align: center;
}

.col-sex {
    width: 100px;
}

/* ============================================================
   24.1 DIRECT MAPPING - TEST MASTER REFACTOR
   ============================================================ */
.tm-page-container {
    padding: 1.5rem;
    background: #f1f5f9;
    min-height: 100vh;
}

.tm-main-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    overflow: hidden;
}

.tm-header-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--lc-border);
    padding: 1.5rem;
}

.tm-actions-row {
    display: flex;
    gap: 1rem;
    align-items: center;
    font-size: 0.875rem;
}

.tm-action-label {
    font-weight: 600;
    color: var(--lc-slate-500);
    text-transform: uppercase;
}

.tm-action-item {
    color: var(--lc-primary);
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.2s;
}

.tm-action-item:hover {
    opacity: 0.8;
}

.tm-profile-section {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.tm-user-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-left: 1rem;
}

.tm-user-details {
    text-align: right;
}

.tm-user-name {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--lc-slate-900);
}

.tm-user-role {
    font-size: 0.625rem;
    color: var(--lc-slate-500);
    text-transform: uppercase;
}

.tm-avatar-circle {
    width: 2.5rem;
    height: 2.5rem;
    background: #FFD1DC;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    color: #E83F6F;
    font-weight: 600;
}

.tm-section-inner {
    background: white;
    border: 1px solid var(--lc-border);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.tm-grid-layout-1 {
    display: grid;
    grid-template-columns: 2.2fr 1fr 1.5fr 2fr 2fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.tm-form-label-small {
    font-size: 0.65rem;
    text-transform: uppercase;
    display: block;
    margin-bottom: 0.5rem;
    color: #64748b;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.tm-input-accent {
    background-color: white !important;
    border: 1px solid var(--lc-primary) !important;
    border-radius: 12px !important;
    padding: 12px 16px !important;
    color: var(--lc-primary) !important;
    font-weight: 700;
    height: 48px !important;
}

.tm-input-muted {
    background-color: #f8fafc !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    padding: 0 16px !important;
    font-weight: 600;
    font-size: 0.95rem;
    color: #1e293b;
    height: 48px !important;
    display: flex;
    align-items: center;
    transition: all 0.2s;
}

textarea.tm-input-muted {
    height: auto !important;
    min-height: 80px !important;
    padding: 12px 16px !important;
    line-height: 1.5;
}

.tm-grid-layout-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.tm-special-ops {
    background: #fdfdfd;
    border: 1px dashed #e2e8f0;
    padding: 1rem;
    border-radius: 12px;
}

.tm-dropdown-box {
    position: absolute;
    top: 100%;
    left: 0;
    right: -150%;
    background: white;
    border: 1px solid var(--lc-primary);
    border-top: none;
    z-index: 100;
    max-height: 15rem;
    overflow-y: auto;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.tm-dropdown-row {
    display: flex;
    cursor: pointer;
    border-bottom: 1px solid var(--lc-border);
    font-size: 0.875rem;
}

.tm-dropdown-cell-primary {
    flex: 1;
    padding: 0.5rem 0.75rem;
    border-right: 1px solid var(--lc-border);
    color: var(--lc-slate-900);
}

.tm-dropdown-cell-secondary {
    width: 150px;
    padding: 0.5rem 0.75rem;
    color: var(--lc-slate-500);
}

.tm-split-panel {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.tm-side-panel {
    width: 320px;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.tm-content-panel {
    flex: 1;
    background: white;
    border: 1px solid var(--lc-border);
    border-radius: 1rem;
    padding: 1.5rem;
}

.tm-settings-hdr {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.tm-footer-bar {
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--lc-border);
}

.tm-btn-row {
    display: flex;
    gap: 0.75rem;
    align-items: center;
}

.tm-btn-row .lc-btn {
    height: 44px !important;
    padding: 0 24px !important;
    font-size: 0.85rem !important;
    font-weight: 700 !important;
    border-radius: 10px !important;
    min-width: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
}

.tm-grid-layout-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.tm-special-ops {
    background: #fdfdfd;
    border: 1px dashed #e2e8f0;
    padding: 1.25rem;
    border-radius: 12px;
}

.tm-param-card {
    background: white;
    border: 1px solid var(--lc-border);
    border-radius: 12px;
    overflow: hidden;
}

.tm-param-header {
    background: #f8fafc;
    border-bottom: 1px solid var(--lc-border);
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tm-param-list {
    padding: 0.5rem 0;
}

.tm-param-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem 1.5rem;
    border-bottom: 1px solid #f1f5f9;
}

.tm-param-check {
    width: 1.25rem;
    height: 1.25rem;
    background: var(--lc-primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
}

.tm-param-circle {
    width: 1.25rem;
    height: 1.25rem;
    border: 1.5px solid #cbd5e1;
    border-radius: 50%;
}

.tm-tab-btn {
    background: transparent;
    border: none;
    padding: 0.75rem 0;
    font-size: 0.75rem;
    font-weight: 700;
    color: #94a3b8;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
    cursor: pointer;
}

.tm-tab-btn:hover {
    color: var(--lc-primary);
}

.tm-tab-btn.active-tab {
    color: var(--lc-primary);
    border-bottom-color: var(--lc-primary);
}

/* LC Section Dividers */
.lc-section-divider {
    display: flex;
    align-items: center;
    gap: 12px;
}

.lc-divider-label {
    font-size: 10px;
    font-weight: 800;
    color: #94a3b8;
    letter-spacing: 0.1em;
    white-space: nowrap;
}

.lc-divider-line {
    height: 1px;
    background: linear-gradient(to right, #e2e8f0, transparent);
    flex-grow: 1;
}

/* Input with Prefix Icons */
.input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.prefix-icon {
    position: absolute;
    left: 12px;
    font-size: 18px !important;
    color: #94a3b8;
    pointer-events: none;
    transition: color 0.2s;
}

.lab-input:focus+.prefix-icon {
    color: var(--lc-primary);
}

.pl-36 {
    padding-left: 36px !important;
}

/* Select Wrapper Customization */
.lc-select-wrapper {
    position: relative;
}

.lc-select-wrapper::after {
    content: '\e5cf';
    font-family: 'Material Symbols Rounded' !important;
    font-weight: normal !important;
    font-style: normal !important;
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #64748b;
    pointer-events: none;
    font-size: 18px;
    line-height: 1;
    letter-spacing: normal;
    text-transform: none !important;
    display: inline-block;
    white-space: nowrap;
    word-wrap: normal;
    direction: ltr;
    -webkit-font-smoothing: antialiased;
}

.lc-select-wrapper .lab-input {
    appearance: none;
    background-image: none !important;
    padding-right: 36px;
}

.h-40 {
    height: 40px !important;
}

/* Container Master Image Specific Styles */
.image-preview-mt {
    margin-top: 8px;
    border-radius: 8px;
    overflow: hidden;
    width: 64px;
    height: 64px;
    border: 1px solid var(--lc-border);
}

.container-img-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.container-img-small {
    width: 32px;
    height: 32px;
    object-fit: cover;
    border-radius: 4px;
    border: 1px solid var(--lc-border);
    background-color: white;
}

/* ============================================================
   BILLING PAGE STYLES
   ============================================================ */
.billing-page-wrapper {
    background-color: #f1f5f9;
    width: 100% !important;
    flex: 1 !important;
    min-height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    font-family: 'Inter', sans-serif;
    color: #1e293b;
    position: relative;
    padding-bottom: 0 !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
}

/* TOP HEADER */
.bl-header-bar {
    background: #ffffff;
    display: flex;
    align-items: center;
    padding: 6px 20px;
    /* Reduced vertical padding (header width) */
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    gap: 20px;
    max-width: 100%;
}

.bl-header-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.bl-label {
    font-size: 9px;
    font-weight: 700;
    color: #94a3b8;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.bl-value {
    font-size: 12px;
    color: #1e293b;
}

.bl-header-divider {
    width: 1px;
    height: 20px;
    background: #e2e8f0;
}

.bl-header-spacer {
    flex: 1;
}

.bl-system-status {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #ecfdf5;
    color: #059669;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.bl-status-dot {
    width: 6px;
    height: 6px;
    background: #10b981;
    border-radius: 50%;
    box-shadow: 0 0 4px #10b981;
}

/* MAIN GRID */
.bl-main-grid {
    display: grid;
    grid-template-columns: 480px 1fr 290px;
    gap: 16px;
    padding: 16px 0 95px 0;
    align-items: start;
}

/* CARDS COMMON */
.bl-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px -1px rgba(0, 0, 0, 0.02);
    border: 1px solid #f1f5f9;
}

.bl-card-title {
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 10px;
}

.bl-card-title .material-symbols-outlined {
    font-size: 16px;
}

.text-blue {
    color: #4f46e5 !important;
}

.text-gray {
    color: #64748b !important;
}

.text-green {
    color: #059669 !important;
}

.text-red {
    color: #ef4444 !important;
}

.text-white {
    color: #ffffff !important;
}

.fw-600 {
    font-weight: 600 !important;
}

.fw-700 {
    font-weight: 700 !important;
}

.mt-12 {
    margin-top: 10px !important;
}

.mt-16 {
    margin-top: 14px !important;
}

.mb-16 {
    margin-bottom: 14px !important;
}

.mb-20 {
    margin-bottom: 16px !important;
}

.ml-16 {
    margin-left: 12px !important;
}

.ml-24 {
    margin-left: 18px !important;
}

.ml-32 {
    margin-left: 24px !important;
}

.ml-auto {
    margin-left: auto !important;
}

.m-0 {
    margin: 0 !important;
}

.py-4 {
    padding-top: 12px;
    padding-bottom: 12px;
}

.flex-1 {
    flex: 1;
}

.flex-2 {
    flex: 2;
}

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

.text-sm {
    font-size: 11px !important;
}

.no-underline {
    text-decoration: none;
}

/* FORMS & INPUTS */
.bl-form-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.bl-input-label {
    font-size: 10px;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.bl-input {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 15px;
    color: #0f172a;
    font-weight: 600;
    width: 100%;
    outline: none;
    transition: border-color 0.2s;
}

.bl-input:focus {
    border-color: #4f46e5;
    background: #ffffff;
}

.bl-input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.bl-input-with-icon .search-icon {
    position: absolute;
    left: 10px;
    font-size: 16px;
    color: #94a3b8;
    pointer-events: none;
}

.bl-input-with-icon .bl-input {
    padding-left: 30px;
}

.bl-select-wrapper {
    position: relative;
    width: 100%;
}

.bl-select-wrapper::after {
    content: '\e5cf';
    font-family: 'Material Symbols Outlined' !important;
    font-weight: normal !important;
    font-style: normal !important;
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    color: #64748b;
    pointer-events: none;
    font-size: 18px;
    line-height: 1;
    letter-spacing: normal;
    text-transform: none !important;
    display: inline-block;
    white-space: nowrap;
    word-wrap: normal;
    direction: ltr;
    -webkit-font-smoothing: antialiased;
}

.bl-select {
    appearance: none;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 8px 30px 8px 12px;
    font-size: 11px;
    font-weight: 500;
    color: #1e293b;
    width: 100%;
    outline: none;
}

.bl-select:focus {
    border-color: #4f46e5;
    background: #ffffff;
}

.bl-select.small {
    padding: 4px 30px 4px 10px;
}

/* PATIENT CARD SPECIFIC */
.bl-patient-badges {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 16px;
}

.bl-segmented-control {
    display: inline-flex;
    background: #e2e8f0;
    border-radius: 6px;
    padding: 2px;
    gap: 2px;
    margin-bottom: 12px;
    box-sizing: border-box;
}

.bl-segment-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 2px 8px;
    background: transparent;
    border: none;
    border-radius: 4px;
    color: #475569;
    font-size: 10px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
    height: 20px;
    line-height: 1;
}

.bl-segment-btn:hover {
    color: #0f172a;
}

.bl-segment-btn.active {
    background: #ffffff;
    color: #4f46e5;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.bl-segment-btn .material-symbols-outlined {
    font-size: 12px !important;
}

.bl-badge-paid {
    background: #10b981;
    color: #ffffff;
    font-size: 9px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 4px;
}

.bl-badge-uid {
    font-size: 11px;
    color: #64748b;
    font-weight: 500;
}

.bl-gender-age-row {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.bl-gender-age-row>div:first-child {
    flex: 1 1 30% !important;
}

.bl-gender-age-row>div:last-child {
    flex: 2 1 70% !important;
}

.bl-gender-age-row .bl-select {
    height: 36px;
    box-sizing: border-box;
}

.bl-age-group {
    display: flex;
    gap: 8px;
}

.bl-age-box {
    display: flex;
    align-items: center;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    height: 36px;
    padding: 0 8px;
    flex: 1;
    transition: all 0.2s;
}

.bl-age-box:focus-within {
    border-color: #4f46e5;
    background: #ffffff;
}

.bl-age-input {
    border: none;
    background: transparent;
    width: 40px;
    font-size: 11px;
    font-weight: 600;
    color: #1e293b;
    text-align: center;
    outline: none;
    height: 100%;
    padding: 0;
    -moz-appearance: textfield;
}

/* Hide number spin arrows on age inputs */
.bl-age-input::-webkit-outer-spin-button,
.bl-age-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.bl-age-lbl {
    font-size: 9px;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-left: 2px;
}

.bl-patient-info-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.bl-id-type-combo {
    display: flex;
    flex-direction: column;
    border-radius: 6px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
}

.bl-id-type-header {
    background: #4f46e5;
    padding: 4px 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    border-radius: 4px;
    width: 60px;
    height: 28px;
    box-sizing: border-box;
}

.bl-id-type-header .bl-id-type-select {
    font-size: 10px;
    padding: 0 4px;
}

.bl-id-type-header .material-symbols-outlined {
    font-size: 14px !important;
    color: #ffffff;
}

.bl-id-label {
    font-size: 10px;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.5px;
}

.bl-id-input {
    border: none;
    background: #f8fafc;
    padding: 8px 12px;
    font-size: 11px;
    font-weight: 500;
    color: #1e293b;
    outline: none;
}

.bl-more-info {
    font-size: 11px;
    color: #1e293b;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    gap: 6px;
    padding: 5px 12px;
    border-radius: 6px;
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    width: fit-content;
    transition: all 0.2s ease;
    user-select: none;
}

.bl-more-info:hover {
    background: #e2e8f0;
    color: #0f172a;
    border-color: #94a3b8;
}

.bl-more-info-icon {
    font-size: 16px !important;
    color: #1e293b;
}

.bl-more-info-arrow {
    font-size: 14px !important;
    color: #64748b;
}

.bl-more-info-badge {
    background: #10b981;
    color: #ffffff;
    border-radius: 10px;
    padding: 1px 6px;
    font-size: 9px;
    font-weight: 700;
    margin-left: 2px;
}

/* REFERRAL CARD */
.bl-grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.bl-grid-3 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
}

.bl-hospital-combo {
    display: flex;
    border: 1px solid #e2e8f0 !important;
    border-radius: 6px;
    overflow: hidden;
    background: #ffffff !important;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05) !important;
    height: 36px;
    box-sizing: border-box;
}

.bl-hospital-sel {
    display: flex;
    align-items: center;
    padding: 0 8px;
    font-size: 10px;
    font-weight: 600;
    color: #64748b;
    border-right: 1px solid #e2e8f0;
    cursor: pointer;
    background: #f8fafc;
}

.bl-hospital-sel .material-symbols-outlined {
    font-size: 14px;
}

.bl-hospital-input {
    border: none;
    background: transparent;
    padding: 0 12px;
    font-size: 11px;
    font-weight: 500;
    color: #1e293b;
    width: 100%;
    outline: none;
    height: 100%;
}

/* TESTS SELECTION CARD */
.bl-tests-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: none;
    padding-bottom: 0;
}

.bl-tests-stats {
    display: flex;
    gap: 20px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-lbl {
    font-size: 9px;
    font-weight: 700;
    color: #64748b;
    letter-spacing: 0.5px;
}

.stat-val {
    font-size: 20px;
    font-weight: 800;
    color: #1e293b;
    line-height: 1.1;
}

.bl-search-test-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.bl-input-with-icon.full-width {
    flex: 1;
}

.bl-btn-add {
    background: #4f46e5;
    color: #ffffff;
    border: none;
    border-radius: 6px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
}

.bl-sample-grid-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 6px 4px;
    border-bottom: 1px solid #e2e8f0;
}

.sg-title {
    font-size: 11px;
    font-weight: 700;
    color: #1e293b;
}

.sg-action {
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
}

/* TABLE */
.bl-table-container {
    border: 1px solid #e2e8f0;
    border-top: none;
    border-radius: 0 0 6px 6px;
    overflow-y: auto;
    min-height: 280px;
    background: #ffffff;
}

.bl-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12.5px;
}

.bl-table thead {
    background: #f8fafc !important;
    color: #475569 !important;
}

.bl-table th {
    padding: 9px 12px;
    text-align: left;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 11px;
    letter-spacing: 0.5px;
    background: #f8fafc !important;
    color: #475569 !important;
    border-bottom: 1px solid #e2e8f0 !important;
}

.bl-table th:last-child,
.bl-table td:last-child {
    text-align: center;
}

.bl-table td {
    padding: 8px 10px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
}

.test-name {
    font-weight: 600;
    color: #1e293b;
}

.comm-text {
    font-weight: 600;
}

.hover-delete {
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s;
}

.hover-delete:hover {
    opacity: 1;
}

.bl-remarks-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.bl-report-date {
    display: inline-flex;
    align-items: center;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 0 10px;
    height: 36px;
    gap: 6px;
    flex-shrink: 0;
}

.bl-report-date .lbl {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    margin-right: 2px;
    white-space: nowrap;
}

.bl-report-date .small-input {
    border: none;
    background: transparent;
    width: 105px;
    font-size: 14.5px;
    font-weight: 700;
    padding: 0;
    outline: none;
    color: #0f172a;
    text-align: center;
}

.bl-report-date .icon {
    color: #64748b;
    font-size: 18px;
    margin-left: 2px;
}

/* RIGHT COLUMN: Collection */
.c-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.bl-toggle {
    position: relative;
    width: 36px;
    height: 20px;
}

.bl-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.bl-toggle label {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #e2e8f0;
    border-radius: 20px;
    cursor: pointer;
    transition: 0.3s;
}

.bl-toggle label:before {
    content: "";
    position: absolute;
    height: 14px;
    width: 14px;
    left: 3px;
    bottom: 3px;
    background: #fff;
    border-radius: 50%;
    transition: 0.3s;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.bl-toggle input:checked+label {
    background: #4f46e5;
}

.bl-toggle input:checked+label:before {
    transform: translateX(16px);
}

.bl-area-row {
    display: flex;
    gap: 6px;
}

/* FINANCIAL SUMMARY */
.fin-title {
    font-size: 10px;
    font-weight: 700;
    color: #94a3b8;
    letter-spacing: 0.5px;
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 10px;
}

.fin-row {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #1e293b;
}

.fin-concession {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.conc-header {
    display: flex;
    justify-content: space-between;
    font-size: 9px;
    font-weight: 700;
    color: #94a3b8;
}

.conc-labels span {
    display: inline-block;
    width: 50px;
    text-align: center;
    background: #f1f5f9;
    border-radius: 4px;
    padding: 2px 0;
    margin-left: 6px;
}

.conc-inputs {
    display: flex;
    justify-content: flex-end;
    gap: 6px;
}

.conc-inputs .bl-input {
    width: 50px;
}

.fin-discount {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8fafc;
    padding: 8px;
    border-radius: 6px;
    font-size: 12px;
}

.fin-net {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    font-weight: 700;
    color: #1e293b;
}

.net-val {
    font-size: 16px;
    color: #4f46e5;
}

/* PAYMENT INTERFACE */
.payment-card {
    background: linear-gradient(135deg, #4f46e5, #4338ca);
    position: relative;
    overflow: hidden;
    border: none;
}

.pay-bg-pattern {
    position: absolute;
    top: -20px;
    right: -20px;
    width: 80px;
    height: 80px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 10%, transparent 10.01%);
    background-size: 16px 16px;
    opacity: 0.5;
    pointer-events: none;
}

.pay-title-row {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: #c7d2fe;
    position: relative;
    z-index: 1;
}

.pay-split-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 10px;
    font-weight: 600;
    color: #e0e7ff;
}

.pay-add-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    color: #fff;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.pay-mode-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 6px 10px;
}

.pay-mode-lbl {
    font-size: 11px;
    font-weight: 700;
    color: #ffffff;
}

.pay-input-wrap {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pay-input {
    background: rgba(255, 255, 255, 0.15);
    border: none;
    border-radius: 4px;
    padding: 4px 8px;
    color: #ffffff;
    font-size: 11px;
    font-weight: 600;
    width: 80px;
    text-align: right;
    outline: none;
}

.pay-check {
    font-size: 16px;
}

.pay-due-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-top: 20px;
}

.due-title {
    font-size: 11px;
    font-weight: 700;
    color: #c7d2fe;
}

.due-sub {
    font-size: 9px;
    color: #818cf8;
}

.due-val {
    font-size: 18px;
    font-weight: 800;
    color: #ffffff;
}

/* BOTTOM BAR */
.bl-bottom-bar {
    position: sticky !important;
    bottom: 0 !important;
    bottom: env(safe-area-inset-bottom, 0px) !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    background: #ffffff !important;
    min-height: 48px !important;
    height: auto !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 10px 18px calc(10px + env(safe-area-inset-bottom, 0px)) 18px !important;
    box-shadow: 0 -4px 20px rgba(15, 23, 42, 0.16) !important;
    border-top: 1.5px solid #cbd5e1 !important;
    z-index: 100 !important;
    box-sizing: border-box !important;
    backdrop-filter: blur(8px) !important;
    margin-top: auto !important;
}

html.dark-mode .bl-bottom-bar {
    background: #1e293b !important;
    border-top-color: #334155 !important;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.5) !important;
}

.sidebar-wrapper.nav-collapsed ~ #main-content .bl-bottom-bar,
.sidebar-wrapper.nav-collapsed ~ main .bl-bottom-bar,
#sidebar.nav-collapsed ~ #main-content .bl-bottom-bar,
.nav-collapsed ~ main .bl-bottom-bar {
    left: 0 !important;
}

@media (max-width: 767px) {
    .bl-bottom-bar,
    .sidebar-wrapper.nav-collapsed ~ #main-content .bl-bottom-bar,
    .sidebar-wrapper.nav-collapsed ~ main .bl-bottom-bar,
    #sidebar.nav-collapsed ~ #main-content .bl-bottom-bar,
    .nav-collapsed ~ main .bl-bottom-bar {
        left: 0 !important;
    }
}

.bbar-stats {
    display: flex;
    align-items: center;
}

.bbar-stat-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.bbar-lbl {
    font-size: 8px;
    font-weight: 700;
    color: #94a3b8;
    line-height: 1.2;
}

.bbar-val {
    font-size: 16px;
    font-weight: 800;
}

.text-black {
    color: var(--lc-secondary) !important;
}

.bbar-printer {
    display: flex;
    flex-direction: column;
    gap: 2px;
    width: 180px;
}

.bbar-printer label {
    font-size: 8px;
    font-weight: 700;
    color: #94a3b8;
}

.bbar-links {
    display: flex;
    align-items: center;
}

.bbar-actions {
    display: flex;
    gap: 8px;
}

/* ── LabCare Design System: Action Buttons ── */
.bl-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 0 18px;
    height: 36px;
    border-radius: 8px;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.18s ease, box-shadow 0.18s ease, transform 0.12s ease;
    user-select: none;
    -webkit-font-smoothing: antialiased;
}

.bl-btn:active {
    transform: scale(0.96);
}

.bl-btn:disabled,
.bl-btn[disabled] {
    opacity: 0.45;
    cursor: not-allowed;
    pointer-events: none;
}

/* SAVE — indigo primary */
.bl-btn-save {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.bl-btn-save:hover:not(:disabled) {
    background: linear-gradient(135deg, #4338ca 0%, #3730a3 100%);
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.45);
    transform: translateY(-1px);
}

/* CLEAR — rose danger */
.bl-btn-clear {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.30),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.bl-btn-clear:hover:not(:disabled) {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    box-shadow: 0 4px 14px rgba(239, 68, 68, 0.40);
    transform: translateY(-1px);
}

/* PRINT — slate neutral */
.bl-btn-print {
    background: linear-gradient(135deg, #475569 0%, #334155 100%);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(71, 85, 105, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.10);
}

/* CLOSE MODAL — slate neutral with danger hover */
.bl-btn-close-modal {
    background: linear-gradient(135deg, #475569 0%, #334155 100%);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(71, 85, 105, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.10);
}

.bl-btn-close-modal:hover:not(:disabled) {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    box-shadow: 0 4px 14px rgba(220, 38, 38, 0.40);
    transform: translateY(-1px);
}

.bl-header-close-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 32px;
    padding: 0 14px;
    border-radius: 8px;
    background: #fee2e2;
    border: 1.5px solid #fca5a5;
    color: #dc2626;
    font-size: 11.5px;
    font-weight: 800;
    letter-spacing: 0.5px;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(220, 38, 38, 0.12);
    transition: all 0.15s ease;
}

.bl-header-close-btn:hover {
    background: #dc2626;
    color: #ffffff;
    border-color: #dc2626;
    box-shadow: 0 3px 8px rgba(220, 38, 38, 0.35);
    transform: translateY(-1px);
}

/* Keep the popup close control anchored to the viewport's top-right corner. */
.vb-billing-modal-fullscreen .bl-header-close-btn {
    position: fixed !important;
    top: 12px !important;
    right: 16px !important;
    z-index: 100001 !important;
}

/* ============================================================
   X. RATE PAGE
   ============================================================ */
.rate-container {
    background-color: #f8fafc;
    min-height: 100vh;
    padding: 16px 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.rate-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #ffffff;
    padding: 12px 20px;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px -1px rgba(0, 0, 0, 0.02);
    border: 1px solid #f1f5f9;
}

.rate-header-title {
    color: #1e293b;
    font-size: 15px;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.rate-header-radios {
    display: flex;
    align-items: center;
    gap: 20px;
    background: #f1f5f9;
    padding: 4px 12px;
    border-radius: 999px;
    border: 1px solid #e2e8f0;
}

.rate-radio-label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 11px;
    color: #475569;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.rate-radio-input {
    width: 12px;
    height: 12px;
    accent-color: #4f46e5;
}

.rate-main-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 16px 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px -1px rgba(0, 0, 0, 0.02);
    border: 1px solid #f1f5f9;
}

.rate-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.rate-form-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.rate-form-group {
    display: flex;
    align-items: center;
}

.rate-form-group-gap {
    display: flex;
    align-items: center;
    gap: 8px;
}

.rate-label {
    width: 8rem;
    font-size: 10px;
    font-weight: 700;
    color: #64748b;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.rate-label-small {
    width: 6rem;
    font-size: 10px;
    font-weight: 700;
    color: #64748b;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.rate-input {
    flex: 1;
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 12px;
    color: #1e293b;
    font-weight: 600;
    outline: none;
    transition: all 0.2s ease;
}

.rate-input:focus {
    background: white;
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.rate-input-small {
    width: 4rem;
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 12px;
    color: #1e293b;
    font-weight: 600;
    outline: none;
    text-align: right;
    transition: all 0.2s ease;
}

.rate-input-small:focus {
    background: white;
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.rate-radio-group {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
}

.rate-radio-item {
    display: flex;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    font-size: 11px;
    color: #475569;
    font-weight: 600;
}

.rate-radio-item-input {
    width: 12px;
    height: 12px;
    accent-color: #4f46e5;
}

.rate-btn-default {
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 6px 16px;
    background: #f8fafc;
    font-size: 11px;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.2s ease;
}

.rate-btn-default:hover {
    background: #e2e8f0;
    color: #1e293b;
}

.rate-btn-set {
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 6px 16px;
    background: #ffffff;
    font-size: 11px;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    cursor: pointer;
    transition: all 0.2s ease;
}

.rate-btn-set:hover {
    background: #f8fafc;
}

.rate-btn-set-blue {
    border: none;
    border-radius: 6px;
    padding: 6px 16px;
    background: #eff6ff;
    font-size: 11px;
    font-weight: 700;
    color: #2563eb;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.2s ease;
}

.rate-btn-set-blue:hover {
    background: #dbeafe;
}

.rate-right-action-group {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-top: 8px;
}

.rate-nested-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
    flex: 1;
}

.rate-btn-big {
    border: none;
    border-radius: 8px;
    padding: 12px 20px;
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    color: white;
    font-size: 12px;
    font-weight: 700;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    line-height: 1.4;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
    transition: all 0.2s ease;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.rate-btn-big:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(79, 70, 229, 0.4);
}

.rate-grid-container {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px -1px rgba(0, 0, 0, 0.02);
    border: 1px solid #f1f5f9;
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.rate-grid-scroll {
    overflow: auto;
    max-height: calc(100vh - 340px);
}

.rate-grid-scroll::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.rate-grid-scroll::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

.rate-grid-scroll::-webkit-scrollbar-track {
    background: transparent;
}

.rate-table {
    width: 100%;
    text-align: left;
    border-collapse: separate;
    border-spacing: 0;
    min-width: max-content;
}

.rate-table thead {
    position: sticky;
    top: 0;
    z-index: 10;
    background: #f8fafc;
}

.rate-table th {
    padding: 10px 12px;
    font-size: 10px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid #e2e8f0;
    border-right: 1px dashed #e2e8f0;
}

.rate-table th:last-child {
    border-right: none;
}

.rate-table th.col-w-10 {
    width: 3rem;
}

.rate-table th.col-w-12 {
    width: 4rem;
}

.rate-table th.col-w-16 {
    width: 4.5rem;
}

.rate-table th.col-w-24 {
    width: 6rem;
}

.rate-table th.col-w-32 {
    width: 8rem;
}

.rate-table th.text-center {
    text-align: center;
}

.rate-table th.text-right {
    text-align: right;
}

.rate-table tbody tr {
    transition: background-color 0.2s ease;
}

.rate-table td {
    padding: 8px 12px;
    font-size: 11px;
    font-weight: 600;
    border-bottom: 1px solid #f1f5f9;
    border-right: 1px dashed #f1f5f9;
    color: #1e293b;
}

.rate-table td:last-child {
    border-right: none;
}

.rate-table tbody tr:hover:not(.rate-row-active) {
    background-color: #f8fafc;
}

.rate-table tbody tr.rate-row-active td {
    background: #eff6ff;
    color: #1e293b;
    border-bottom: 1px solid #bfdbfe;
    border-right: 1px dashed #bfdbfe;
}

.rate-table tbody tr.rate-row-active td:last-child {
    border-right: none;
}

.rate-table td.text-center {
    text-align: center;
}

.rate-table td.text-right {
    text-align: right;
}

.rate-table td.col-sno {
    font-weight: 700;
    color: #64748b;
    position: relative;
}

.rate-row-pointer {
    position: absolute;
    left: 4px;
    color: #4f46e5;
    font-size: 10px;
}

.rate-table td.col-group-name,
.rate-table td.col-margin-type {
    color: #64748b;
    font-weight: 500;
}

.rate-table td.col-patient-rate,
.rate-table td.col-special-amount {
    color: #4f46e5;
    font-weight: 700;
}

.rate-footer-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding: 8px 0;
}

.rate-btn-footer {
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 8px 16px;
    background: white;
    font-size: 11px;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
}

.rate-btn-footer:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #1e293b;
}

.rate-btn-footer.wide {
    padding-left: 24px;
    padding-right: 24px;
}

.rate-btn-footer.primary {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    color: white;
    border: none;
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
}

.rate-btn-footer.primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(79, 70, 229, 0.4);
    color: white;
}

.rate-btn-footer.danger {
    background: #ef4444;
    color: white;
    border: none;
}

.rate-btn-footer.danger:hover {
    background: #dc2626;
    color: white;
}

.cm-container {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 1.5rem;
    padding: 1rem 0;
}

.cm-col-2 {
    grid-column: span 2;
}

.cm-col-3 {
    grid-column: span 3;
}

.cm-col-4 {
    grid-column: span 4;
}

.cm-col-6 {
    grid-column: span 6;
}

.cm-col-10 {
    grid-column: span 10;
}

.cm-col-12 {
    grid-column: span 12;
    display: flex;
    justify-content: flex-end;
    gap: 1.5rem;
}

.cm-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.cm-field-inline {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.cm-label-top {
    font-size: 0.75rem;
    /* 12px for smaller labels like screenshot */
    font-weight: 600;
    color: #7c8fa3;
    /* slate-500 - matches screenshot exactly */
    text-transform: capitalize;
    letter-spacing: 0.3px;
}

.cm-input {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.625rem 1rem;
    font-size: 0.875rem;
    color: #334155;
    width: 100%;
    outline: none;
    transition: all 0.2s ease;
    height: 2.5rem;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

.cm-input::placeholder {
    color: #cbd5e1;
}

.cm-input:focus {
    background: #ffffff;
    border-color: #cbd5e1;
    box-shadow: 0 0 0 2px rgba(200, 213, 225, 0.15);
}

/* Date input styling */
input[type="date"].cm-input {
    padding: 0.5rem 0.75rem;
}

input[type="date"].cm-input::-webkit-calendar-picker-indicator {
    cursor: pointer;
    opacity: 0.6;
    filter: invert(0.2);
}

select.cm-input {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23cbd5e1'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 1.2rem;
    padding-right: 2.5rem;
    cursor: pointer;
}

.cm-flex-1 {
    flex: 1;
}

/* Width utilities for different field sizes */
.cm-w-prefix {
    flex: 0 0 auto;
    width: 5.5rem;
}

.cm-w-initial {
    flex: 0 0 auto;
    width: 4.5rem;
}

.cm-w-age {
    flex: 0 0 auto;
    width: 2.75rem;
    /* 44px */
    padding-left: 0.2rem !important;
    padding-right: 0.2rem !important;
    text-align: center;
}

.cm-w-custcode {
    flex: 0 0 auto;
    width: 100px;
}

.cm-w-cardno {
    flex: 0 0 auto;
    width: 120px;
}

.cm-w-dob {
    flex: 0 0 auto;
    width: 100px;
}

.cm-w-gender {
    flex: 1 1 auto;
    min-width: 120px;
}

.cm-field-small {
    flex: 0 0 auto;
    width: 110px;
}

.cm-field-medium {
    flex: 1 1 auto;
    min-width: 150px;
    max-width: 200px;
}

.cm-field-large {
    flex: 2 1 auto;
    min-width: 250px;
}

.cm-file-upload {
    border: 1px dashed #d1d5db;
    border-radius: 8px;
    padding: 1.5rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    color: #9ca3af;
    font-weight: 500;
    font-size: 0.875rem;
    cursor: pointer;
    background: #fafbfc;
    transition: all 0.2s ease;
}

.cm-file-upload:hover {
    background: #f3f4f6;
    border-color: #cbd5e1;
    color: #6b7280;
}

.cm-checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-size: 0.875rem;
    color: #6b7280;
    font-weight: 500;
    cursor: pointer;
    user-select: none;
}

.cm-checkbox {
    width: 1.125rem;
    height: 1.125rem;
    border: 1.5px solid #cbd5e1;
    border-radius: 0.375rem;
    cursor: pointer;
    accent-color: #4f46e5;
}

/* ============================================================
   9. SEARCH & FILTER INPUTS
   ============================================================ */
.search-input {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 20px;
    padding: 8px 16px 8px 36px;
    font-size: 13px;
    color: #1e293b;
    outline: none;
    width: 220px;
    transition: all 0.2s;
}

.search-input:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

/* ============================================================
   10. ALERT MESSAGES
   ============================================================ */
.alert-message {
    margin: 20px 0;
    padding: 15px;
    border-radius: 8px;
    font-weight: 500;
}

/* ============================================================
   11. CUSTOMER MASTER FORM - WIDTH UTILITIES
   ============================================================ */
.cm-w-custcode {
    width: 120px !important;
}

.cm-w-cardno {
    width: 200px !important;
}

.cm-w-dob {
    width: 100%;
}

.cm-w-gender {
    width: 100%;
}

/* ============================================================
   12. DIRECTORY SECTION
   ============================================================ */
.directory-section-form {
    border-top-left-radius: 0;
    border-top-right-radius: 0;
    margin-top: -4px;
}

/* ============================================================
   13. TABLE HEADERS
   ============================================================ */
.th-custcode {
    width: 64px;
}

.th-actions {
    width: 128px;
}

/* ============================================================
   14. MODAL FOOTER BUTTON ICONS
   ============================================================ */
.btn-icon-save {
    margin-right: 8px;
}

/* ============================================================
   15. CHECKBOX ROW SPACING
   ============================================================ */
.cm-checkbox-row {
    margin-top: 0.5rem;
}

/* ============================================================
   16. UNIT MASTER STYLES
   ============================================================ */
.um-grid-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-bottom: 20px;
}

.um-grid-cols-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 20px;
}

.um-grid-cols-3 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 16px;
    margin-bottom: 20px;
}

/* ============================================================
   25. IMAGE UPLOAD STYLES (CONTAINER MASTER)
   ============================================================ */
.image-upload-section {
    grid-column: 1 / -1;
}

.image-upload-empty {
    border: 2px dashed #cbd5e1;
    border-radius: 12px;
    padding: 48px 24px;
    background: #f8fafc;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    position: relative;
    overflow: hidden;
}

.image-upload-icon {
    width: 40px;
    height: 40px;
    color: #94a3b8;
    position: relative;
    z-index: 1;
}

.image-upload-text {
    text-align: center;
    position: relative;
    z-index: 1;
}

.image-upload-title {
    font-size: 14px;
    font-weight: 500;
    color: #94a3b8;
    margin-bottom: 0;
}

.image-upload-subtitle {
    font-size: 13px;
    color: #cbd5e1;
    margin-bottom: 0;
    display: none;
}

.image-upload-hint {
    font-size: 12px;
    color: #cbd5e1;
    display: none;
}

.image-upload-input {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.image-upload-success {
    border: 2px solid #10b981;
    border-radius: 12px;
    padding: 24px;
    background: #f0fdf4;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 16px;
    align-items: center;
}

.image-upload-status {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.image-upload-status-header {
    display: flex;
    align-items: center;
    gap: 8px;
}

.image-upload-status-icon {
    width: 18px;
    height: 18px;
    color: #10b981;
}

.image-upload-status-text {
    font-size: 13px;
    font-weight: 600;
    color: #10b981;
}

.image-upload-status-subtext {
    font-size: 11px;
    color: #059669;
}

.image-upload-preview {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    object-fit: cover;
    border: 1px solid #dcfce7;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.15);
}

.image-upload-actions {
    margin-top: 12px;
    display: flex;
    gap: 8px;
}

.btn-remove-image {
    flex: 1;
    padding: 8px 12px;
    font-size: 12px;
    background-color: #fee2e2;
    color: #dc2626;
    border: 1px solid #fecaca;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.btn-remove-image:hover {
    background-color: #fecaca;
    color: #991b1b;
}

.btn-remove-image-icon {
    width: 12px;
    height: 12px;
}

.sym-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.sym-btn {
    background-color: #f1f5f9;
    border: 1px solid #e2e8f0;
    color: #475569;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.sym-btn:hover {
    background-color: #6366f1;
    color: white;
    border-color: #6366f1;
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(99, 102, 241, 0.2);
}

.sym-btn:active {
    transform: translateY(0);
}

/* Unit Master specific styles extracted from inline css */
.um-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 4px;
}

.um-label {
    margin-bottom: 0;
}

.um-error-text {
    font-size: 11px;
    font-weight: 500;
}

.symbol-helper-section {
    background: #f8fafc;
    padding: 16px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.symbol-helper-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.symbol-title {
    font-size: 13px;
    color: #475569;
    font-weight: 500;
}

.symbol-subtitle {
    font-size: 12px;
    color: #94a3b8;
    font-style: italic;
    margin-left: 8px;
}

.sym-btn-new {
    min-width: 38px;
    height: 38px;
    padding: 0 12px;
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    cursor: pointer;
    color: #334155;
    font-size: 14px;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
    transition: all 0.2s;
}

.sym-btn-new:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
    color: var(--lc-secondary);
}

/* ============================================================
   26. BILLING SEARCH DROPDOWN
   ============================================================ */
.bl-search-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
    z-index: 1000;
    max-height: 300px;
    overflow-y: auto;
    scroll-behavior: smooth;
    margin-top: 4px;
    animation: slideDownFade 0.2s ease-out;
}

.bl-search-dropdown-up {
    position: absolute;
    bottom: 100% !important;
    top: auto !important;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 -10px 25px -5px rgba(0, 0, 0, 0.15), 0 -8px 10px -6px rgba(0, 0, 0, 0.08);
    z-index: 1050;
    max-height: 250px;
    overflow-y: auto;
    scroll-behavior: smooth;
    margin-bottom: 6px !important;
    margin-top: 0 !important;
}


.bl-search-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
    transition: all 0.2s ease;
}

.bl-search-item:hover {
    background: #f8fafc;
    padding-left: 20px;
}

.bl-search-item:last-child {
    border-bottom: none;
}

.bl-item-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.bl-item-name {
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.bl-item-meta {
    font-size: 11px;
    color: #64748b;
    font-weight: 600;
}

.bl-item-date {
    font-size: 10px;
    font-weight: 700;
    color: #6366f1;
    background: #eef2ff;
    padding: 4px 10px;
    border-radius: 999px;
    text-transform: uppercase;
}

.bl-search-no-results {
    padding: 24px 16px;
    text-align: center;
    font-size: 12px;
    color: #94a3b8;
    font-weight: 600;
    letter-spacing: 0.5px;
}

/* --- DUE COLLECTION SCREEN --- */
.dc-top-section {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.dc-type-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.dc-type-radios {
    display: flex;
    align-items: center;
    gap: 20px;
}

.dc-type-radios label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #475569;
    cursor: pointer;
}

.dc-type-radios input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: #4f46e5;
    cursor: pointer;
}

.dc-filter-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    background: transparent;
    border: none;
    color: #64748b;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
}

.dc-panels-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.dc-panel {
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
}

.dc-panel-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.dc-panel-row.cols-2 {
    grid-template-columns: 1fr 1fr;
}

.dc-panel-row.cols-3 {
    grid-template-columns: 1fr 1fr 1fr;
}

.dc-form-group {
    display: flex;
    flex-direction: column;
}

.dc-form-group label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dc-input {
    width: 100%;
    height: 40px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0 12px;
    font-size: 14px;
    color: #1e293b;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.dc-input:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

select.dc-input {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2364748b' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
}

.dc-search-btn-wrapper {
    display: flex;
    justify-content: flex-end;
    margin-top: 16px;
}

.dc-btn-search {
    background-color: #4f46e5;
    color: white;
    border: none;
    border-radius: 8px;
    height: 40px;
    padding: 0 24px;
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.dc-btn-search:hover {
    background-color: #4338ca;
}

/* Bottom Card */
.dc-bottom-section {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.dc-actions-bar {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 24px;
    width: 100%;
}

.dc-actions-left-group {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 16px;
    flex: 1;
    min-width: 280px;
}

.dc-actions-right-group {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    flex-wrap: wrap;
}

.dc-search-input-container {
    position: relative;
    width: 240px;
}

.dc-search-input-container svg {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    width: 16px;
    height: 16px;
    pointer-events: none;
}

.dc-search-input-container input {
    width: 100%;
    height: 40px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0 12px 0 36px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    background: white;
}

.dc-search-input-container input:focus {
    border-color: #4f46e5;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.dc-filter-circle-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid #e2e8f0;
    background: white;
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.dc-filter-circle-btn:hover {
    background: #f8fafc;
    color: #4f46e5;
    border-color: #cbd5e1;
}

.dc-btn-auto-select {
    color: #4f46e5;
    font-weight: 700;
    font-size: 14px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0 8px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    transition: color 0.2s;
}

.dc-btn-auto-select:hover:not(:disabled) {
    color: #312e81;
}

.dc-btn-auto-select:disabled {
    color: #cbd5e1;
    cursor: not-allowed;
}

.dc-btn-save {
    background-color: #4f46e5;
    color: white;
    border: none;
    border-radius: 8px;
    height: 40px;
    padding: 0 20px;
    font-size: 14px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: background-color 0.2s;
    box-shadow: 0 2px 4px rgba(79, 70, 229, 0.15);
}

.dc-btn-save:hover:not(:disabled) {
    background-color: #4338ca;
}

.dc-btn-save:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Table */
.dc-table-wrapper {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow-x: auto;
    margin-bottom: 24px;
}

.dc-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 900px;
}

.dc-table th {
    background: #4f46e5 !important;
    padding: 8px 12px !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    color: #ffffff !important;
    text-transform: uppercase !important;
    text-align: left;
    border-bottom: 2px solid #4338ca !important;
}

.dc-table td {
    padding: 12px 16px;
    font-size: 13px;
    color: #1e293b;
    border-bottom: 1px solid #e2e8f0;
    vertical-align: middle;
}

.dc-table tr:last-child td {
    border-bottom: none;
}

.dc-table input[type="text"],
.dc-table input[type="number"] {
    width: 80px;
    height: 32px;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    padding: 0 8px;
    font-size: 13px;
    text-align: right;
}

.dc-table input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: #4f46e5;
    cursor: pointer;
}

.text-red {
    color: #ef4444;
    font-weight: 600;
}

.font-bold {
    font-weight: 700;
}

.text-slate {
    color: #64748b;
}

/* Footers */
.dc-footers {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.dc-footer-card {
    background: #f8fafc;
    border-radius: 8px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.dc-footer-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dc-footer-icon.red {
    background: #fee2e2;
    color: #ef4444;
}

.dc-footer-icon.blue {
    background: #e0e7ff;
    color: #3b82f6;
}

.dc-footer-icon.green {
    background: #dcfce3;
    color: #22c55e;
}

.dc-footer-icon.gray {
    background: #f1f5f9;
    color: #64748b;
}

.dc-footer-info label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    margin-bottom: 4px;
    text-transform: uppercase;
}

.dc-footer-info .value {
    font-size: 20px;
    font-weight: 700;
    color: var(--lc-secondary);
}

/* ============================================================
   DUE COLLECTION HISTORY
   ============================================================ */
.filter-body-anim {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.4s ease-out, opacity 0.3s ease-out;
    opacity: 0;
}

.filter-body-anim.open {
    grid-template-rows: 1fr;
    opacity: 1;
}

.filter-body-anim.closed {
    grid-template-rows: 0fr;
    opacity: 0;
}

.filter-body-inner {
    overflow: hidden;
}

.dch-filter-card {
    background: white;
    border-radius: 12px;
    padding: 12px 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    border: 1px solid #f1f5f9;
    margin-bottom: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.dch-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 16px;
    align-items: flex-end;
}

.dch-row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.dch-form-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dch-label {
    font-size: 10px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
}

.dch-input {
    width: 100%;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 6px 10px;
    font-size: 12px;
    background: #f8fafc;
    outline: none;
    color: #334155;
    transition: border-color 0.2s, background-color 0.2s;
}

.dch-input:focus {
    border-color: #4f46e5;
    background: white;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.dch-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 8px;
}

/* ── LabCare Design System: Page-level Buttons (dch) ── */
.dch-btn-search {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 38px;
    padding: 0 20px;
    background: #ffffff;
    color: #334155;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 600;
    font-size: 13px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease, transform 0.1s ease;
    user-select: none;
}

.dch-btn-search:hover {
    background: #f8fafc;
    border-color: #94a3b8;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.dch-btn-search:active {
    transform: scale(0.97);
}

.dch-btn-print {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 38px;
    padding: 0 20px;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 700;
    font-size: 13px;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.30),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
    cursor: pointer;
    transition: background 0.18s ease, box-shadow 0.18s ease, transform 0.12s ease;
    user-select: none;
}

.dch-btn-print:hover {
    background: linear-gradient(135deg, #1d4ed8 0%, #1e3a8a 100%);
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.40);
    transform: translateY(-1px);
}

.dch-btn-print:active {
    transform: scale(0.97);
}

.master-search-item-title {
    font-weight: 600;
    font-size: 13px;
    color: #1e293b;
}

.master-search-item-subtitle {
    font-size: 11px;
    color: #64748b;
}

/* Extra classes for DueCollectionHistory UI & View Bills */
.dch-page-container {
    width: 100% !important;
    max-width: 100% !important;
    flex: 1 !important;
    min-height: 100% !important;
    padding: 14px 18px 40px 18px !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    background-color: #f8fafc;
    box-sizing: border-box !important;
}

.dch-header-margin {
    margin-bottom: 24px;
}

.dch-filter-toggle-container {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 12px;
}

.dch-btn-filter-toggle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 38px;
    padding: 0 16px;
    background: #ffffff;
    color: #475569;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-family: 'Inter', system-ui, sans-serif;
    font-weight: 600;
    font-size: 13px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    user-select: none;
}

.dch-btn-filter-toggle:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
    color: #1e293b;
}

.dch-btn-filter-toggle:active {
    transform: scale(0.97);
}

.dch-grid-2-cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.dch-filter-grid-row {
    display: grid;
    grid-template-columns: 280px 1fr 1fr 200px auto;
    gap: 16px;
    align-items: flex-end;
    margin-bottom: 16px;
}

.dch-filter-actions-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #f1f5f9;
    margin-top: 12px;
    padding-top: 12px;
}

.dch-actions-left {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.dch-actions-right {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.dch-table-wrapper {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    border: 1px solid #f1f5f9;
    padding: 24px;
    margin-bottom: 24px;
}

.dch-table-inner {
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    margin-bottom: 24px;
}

.dch-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    text-align: left;
    font-size: 12px;
}

.dch-table-thead {
    background: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%) !important;
    border-bottom: 2px solid #4338ca !important;
}

.dch-table-th {
    padding: 11px 14px !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    color: #ffffff !important;
    text-transform: uppercase !important;
    background: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%) !important;
    border-bottom: 2px solid #4338ca !important;
    letter-spacing: 0.6px !important;
}

.dch-table-th-center {
    padding: 11px 14px !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    color: #ffffff !important;
    text-transform: uppercase !important;
    text-align: center !important;
    background: linear-gradient(135deg, #1e1b4b 0%, #312e81 100%) !important;
    border-bottom: 2px solid #4338ca !important;
    letter-spacing: 0.6px !important;
}

.dch-table-tr {
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.2s;
}

.dch-table-td {
    padding: 8px 10px;
    color: #64748b;
}

.dch-table-td-bold {
    padding: 8px 10px;
    font-weight: 600;
    color: #334155;
}

.dch-table-td-blue {
    padding: 8px 10px;
    font-weight: 700;
    color: #2563eb;
}

.dch-table-td-dark {
    padding: 8px 10px;
    font-weight: 700;
    color: #1e293b;
}

.dch-table-td-center {
    padding: 8px 10px;
    text-align: center;
}

.dch-btn-tr-icon,
.dch-btn-tr-icon-danger {
    background: none;
    border: none;
    color: #4f46e5;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    outline: none;
    transition: all 0.2s;
    padding: 4px;
    border-radius: 4px;
}

.dch-btn-tr-icon:hover {
    background: #f1f5f9;
    color: #312e81;
}

.dch-btn-tr-icon-danger {
    color: #ef4444;
}

.dch-btn-tr-icon-danger:hover {
    background: #fee2e2;
    color: #991b1b;
}

.dch-btn-tr-icon .material-symbols-outlined,
.dch-btn-tr-icon-danger .material-symbols-outlined {
    font-size: 18px !important;
}

.dch-table-empty {
    text-align: center;
    padding: 32px;
    color: #64748b;
    font-size: 14px;
}

.dch-footer-summary {
    display: flex;
    gap: 24px;
    justify-content: flex-end;
}

.dch-summary-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 24px;
    background: #f0fdf4;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    border: 1px solid #dcfce3;
    min-width: 250px;
}

.dch-summary-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: white;
    color: #16a34a;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 1px 2px rgba(22, 163, 74, 0.1);
}

.dch-summary-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dch-summary-label {
    font-size: 11px;
    font-weight: 800;
    color: #14532d;
    text-transform: uppercase;
}

.dch-summary-value {
    font-size: 24px;
    font-weight: 800;
    color: #052e16;
}

/* ============================================================
   DUE COLLECTION
   ============================================================ */
.filter-types-anim {
    transition: max-width 0.4s ease-in-out, opacity 0.3s ease-in-out, margin 0.4s ease-in-out;
    overflow: hidden;
    display: flex;
    align-items: center;
    white-space: nowrap;
}

.filter-types-anim.open {
    max-width: 600px;
    opacity: 1;
}

.filter-types-anim.closed {
    max-width: 0;
    opacity: 0;
    margin: 0 !important;
    padding: 0 !important;
    border: none;
}

.dc-pagination-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px;
    padding-top: 16px;
    margin-bottom: 24px;
    background: white;
    border-radius: 12px;
    border: 1px solid #f1f5f9;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

/* ============================================================
   27. NAVIGATION MENU (SUBMENUS)
   ============================================================ */
.nav-submenu-btn {
    display: flex;
    align-items: center;
    width: 100%;
    padding: 9px 12px;
    border-radius: 8px;
    color: #475569;
    background: transparent;
    border: none;
    font-size: 12.5px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    justify-content: space-between;
}

.nav-submenu-btn:hover {
    background-color: rgba(99, 102, 241, 0.08);
    color: #1e293b;
}

.nav-submenu-icon {
    font-size: 16px !important;
    transition: transform 0.3s ease;
}

.nav-submenu-icon.is-expanded {
    transform: rotate(90deg);
}

.nav-submenu-items {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-top: 4px;
    padding-left: 28px;
    border-left: 1px solid #e2e8f0;
    margin-left: 20px;
    overflow: hidden;
    max-height: 0;
    transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-submenu-items.is-expanded {
    max-height: 800px;
}

.v-nav-link.submenu-item {
    font-size: 13px;
    padding: 6px 10px;
}

.nav-collapsed .nav-submenu-btn {
    justify-content: center;
    padding: 12px;
}

.nav-collapsed .nav-submenu-icon {
    display: none;
}

.nav-collapsed .nav-submenu-items {
    display: none;
}

/* ============================================================
   28. BILLING PAGE
   ============================================================ */
.billing-page-wrapper {
    padding: 24px;
    background-color: #f8fafc;
    min-height: 100vh;
}

.bl-header-bar {
    display: flex;
    align-items: center;
    background: white;
    padding: 12px 24px;
    border-radius: 16px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
    margin-bottom: 24px;
    border: 1px solid #e2e8f0;
    max-width: 100%;
}

.bl-header-item {
    display: flex;
    flex-direction: column;
    padding: 0 20px;
}

.bl-label {
    font-size: 10px;
    font-weight: 800;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.bl-select {
    border: none;
    font-weight: 700;
    color: #1e293b;
    background: transparent;
    cursor: pointer;
    font-size: 14px;
    outline: none;
}

.bl-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
    transition: all 0.3s;
}

.bl-card:hover {
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

.bl-card-title {
    font-size: 14px;
    font-weight: 800;
    color: #1e293b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 20px;
}

.bl-input {
    width: 100%;
    height: 42px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0 16px;
    font-weight: 600;
    color: #1e293b;
    transition: all 0.2s;
}

.bl-input:focus {
    background: white;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* bl-btn-save override for finance section — inherits from .bl-btn above */
.bl-btn-save {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    color: #ffffff;
    font-weight: 700;
    padding: 0 28px;
    height: 38px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-size: 12px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    transition: background 0.18s ease, box-shadow 0.18s ease, transform 0.12s ease;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.bl-btn-save:hover {
    background: linear-gradient(135deg, #4338ca 0%, #3730a3 100%);
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.45);
    transform: translateY(-1px);
}

.finance-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
}

.pay-val {
    font-size: 24px;
    font-weight: 900;
    color: #1e293b;
}

.payment-card {
    background: linear-gradient(135deg, #1e293b 0%, var(--lc-secondary) 100%);
    color: white;
}

/* ============================================================
   29. MODIFY TEST MASTER
   ============================================================ */
.tm-page-container {
    padding: 32px;
    background: #f1f5f9;
    min-height: 100vh;
    font-family: 'Inter', sans-serif;
}

.tm-main-card {
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    border: 1px solid #e2e8f0;
}

.tm-header-grid {
    display: grid;
    grid-template-columns: 0.5fr 2fr 1.2fr 1fr 1fr 0.8fr 0.5fr 0.8fr;
    gap: 16px;
    margin-bottom: 24px;
}

.tm-flags-container {
    background: #f8fafc;
    padding: 16px 24px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.tm-flags-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.tm-split-panel {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 32px;
}

.tm-param-card {
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.tm-param-header {
    padding: 14px 20px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tm-param-item {
    padding: 12px 20px;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    cursor: pointer;
    transition: 0.2s;
}

.active-param {
    background: #eff6ff !important;
    border-left: 4px solid #2563eb;
}

.tm-red-header {
    background: #ef4444;
    padding: 12px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 12px 12px 0 0;
}

.tm-tab-btn {
    background: none;
    border: none;
    font-size: 11px;
    font-weight: 800;
    color: #94a3b8;
    letter-spacing: 0.1em;
    padding-bottom: 12px;
    border-bottom: 2px solid transparent;
    cursor: pointer;
    margin-right: 32px;
}

.active-tab {
    color: #6366f1;
    border-bottom-color: #6366f1;
}

.tm-footer-bar {
    padding: 20px 32px;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tm-form-label-tiny {
    font-size: 9px;
    font-weight: 800;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 2px;
    display: block;
}

.tm-subtab-bar {
    padding: 0 32px;
    border-top: 1px solid #e2e8f0;
}

/* ============================================================
   30. CUSTOMER MASTER
   ============================================================ */
.cm-input option {
    color: #1e293b !important;
    background: #ffffff !important;
}

/* ============================================================
   31. RECONNECT MODAL
   ============================================================ */
#components-reconnect-modal {
    background-color: white;
    width: 20rem;
    margin: 20vh auto;
    padding: 2rem;
    border: 0;
    border-radius: 0.5rem;
    box-shadow: 0 3px 6px 2px rgba(0, 0, 0, 0.3);
    opacity: 0;
    transition: display 0.5s allow-discrete, overlay 0.5s allow-discrete;
    animation: components-reconnect-modal-fadeOutOpacity 0.5s both;
}

#components-reconnect-modal[open] {
    animation: components-reconnect-modal-slideUp 1.5s cubic-bezier(.05, .89, .25, 1.02) 0.3s, components-reconnect-modal-fadeInOpacity 0.5s ease-in-out 0.3s;
    animation-fill-mode: both;
}

#components-reconnect-modal::backdrop {
    background-color: rgba(0, 0, 0, 0.4);
    animation: components-reconnect-modal-fadeInOpacity 0.5s ease-in-out;
    opacity: 1;
}

@keyframes components-reconnect-modal-slideUp {
    0% {
        transform: translateY(30px) scale(0.95);
    }

    100% {
        transform: translateY(0);
    }
}

@keyframes components-reconnect-modal-fadeInOpacity {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

@keyframes components-reconnect-modal-fadeOutOpacity {
    0% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

.components-reconnect-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

#components-reconnect-modal p {
    margin: 0;
    text-align: center;
}

#components-reconnect-modal button {
    border: 0;
    background-color: #6b9ed2;
    color: white;
    padding: 4px 24px;
    border-radius: 4px;
}

#components-reconnect-modal button:hover {
    background-color: #3b6ea2;
}

.components-rejoining-animation {
    position: relative;
    width: 80px;
    height: 80px;
}

.components-rejoining-animation div {
    position: absolute;
    border: 3px solid #0087ff;
    opacity: 1;
    border-radius: 50%;
    animation: components-rejoining-animation 1.5s cubic-bezier(0, 0.2, 0.8, 1) infinite;
}

.components-rejoining-animation div:nth-child(2) {
    animation-delay: -0.5s;
}

@keyframes components-rejoining-animation {
    0% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 0;
    }

    5% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 1;
    }

    100% {
        top: 0px;
        left: 0px;
        width: 80px;
        height: 80px;
        opacity: 0;
    }
}


.dc-type-label {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
}

.dc-type-radio-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
    font-size: 14px;
    color: #334155;
    cursor: pointer;
}

.dc-type-radio-input {
    width: 16px;
    height: 16px;
    accent-color: #4f46e5;
    margin: 0;
    cursor: pointer;
}

.dc-panel-inner {
    background: white;
    border-radius: 12px;
    padding: 16px 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    border: 1px solid #f1f5f9;
    margin-bottom: 20px;
}

.dc-panel-type-container {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
    gap: 20px;
}

.dc-actions-group {
    display: flex;
    gap: 16px;
    min-width: 300px;
}

.dc-actions-select {
    width: 100%;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 14px;
    background: white;
    outline: none;
}

.dc-actions-input {
    width: 100%;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 14px;
    background: white;
    outline: none;
}

.dc-table-tr {
    border-bottom: 1px solid #f1f5f9;
}

.dc-table-th-checkbox {
    width: 48px;
    padding: 12px 16px;
}

.dc-table-checkbox {
    width: 16px;
    height: 16px;
    border-radius: 4px;
    border: 1px solid #cbd5e1;
}

.dc-table-td {
    padding: 12px 16px;
}

.dc-table-td-bold {
    padding: 12px 16px;
    font-weight: 700;
}

.dc-table-td-number {
    width: 80px;
    text-align: right;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    padding: 4px 8px;
}

.dc-search-input {
    width: 100%;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px 36px 8px 12px;
    font-size: 14px;
    background: white;
    outline: none;
}



.dc-footers-container {
    display: flex;
    gap: 16px;
    justify-content: space-between;
}

.dc-footer-card-inner {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    border: 1px solid #f1f5f9;
}

.dc-empty-row {
    text-align: center;
    padding: 20px;
    color: #64748b;
}

/* ============================================================
   32. GLOBAL UTILITY CLASSES (LC-*)
   ============================================================ */
.lc-flex-between-center {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
}

.lc-mb-0 {
    margin-bottom: 0 !important;
}

.lc-mb-4 {
    margin-bottom: 4px !important;
}

.lc-font-11 {
    font-size: 11px !important;
}

.lc-font-14 {
    font-size: 14px !important;
}

.lc-font-16 {
    font-size: 16px !important;
}

.lc-font-500 {
    font-weight: 500 !important;
}

.lc-font-700 {
    font-weight: 700 !important;
}

.lc-cursor-pointer {
    cursor: pointer !important;
}

.lc-grid-span-2 {
    grid-column: span 2 !important;
}

.lc-overflow-auto-max-480 {
    max-height: 480px !important;
    overflow-y: auto !important;
}

.lc-text-uppercase {
    text-transform: uppercase !important;
}

.lc-letter-spacing-05 {
    letter-spacing: 0.5px !important;
}

.lc-bg-none {
    background: none !important;
}

.lc-border-slate {
    border: 1px solid #e2e8f0 !important;
}

.lc-width-100 {
    width: 100px !important;
}

.lc-position-relative {
    position: relative !important;
}

.lc-top-100 {
    top: 100% !important;
}

.lc-left-0 {
    left: 0 !important;
}

.lc-right-0 {
    right: 0 !important;
}

.lc-bg-success-light {
    background: rgba(34, 197, 94, 0.1) !important;
}

.lc-bg-danger-light {
    background: rgba(239, 68, 68, 0.1) !important;
}

.lc-status-pill {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    padding: 4px 10px !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    border-radius: 12px !important;
}

.lc-status-pill-success {
    background: #ecfdf5 !important;
    color: #059669 !important;
}

.lc-status-pill-danger {
    background: #fef2f2 !important;
    color: #dc2626 !important;
}

.lc-dot {
    width: 6px !important;
    height: 6px !important;
    border-radius: 50% !important;
    display: inline-block !important;
}

.lc-dot-success {
    background: #059669 !important;
}

.lc-dot-danger {
    background: #dc2626 !important;
}

.lc-font-13 {
    font-size: 13px !important;
}

.lc-color-slate-500 {
    color: #64748b !important;
}

.lc-text-blue {
    color: #2563eb !important;
}

.lc-text-white {
    color: white !important;
}

.lc-text-red {
    color: #ef4444 !important;
}

.lc-search-input {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 20px !important;
    padding: 8px 16px 8px 36px !important;
    font-size: 13px !important;
    color: #1e293b !important;
    outline: none !important;
    width: 220px !important;
}

.lc-alert {
    margin: 20px 0 !important;
    padding: 15px !important;
    border-radius: 8px !important;
    font-weight: 500 !important;
}

.lc-textarea {
    height: auto !important;
    min-height: 80px !important;
}

.lc-mr-8 {
    margin-right: 8px !important;
}

.lc-mr-4 {
    margin-right: 4px !important;
}

.lc-font-10 {
    font-size: 10px !important;
}

.lc-font-12 {
    font-size: 12px !important;
}

.lc-mt-neg-4 {
    margin-top: -4px !important;
}

.lc-initials-avatar {
    width: 36px !important;
    height: 36px !important;
    border-radius: 50% !important;
    background: #eef2ff !important;
    color: #4f46e5 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-weight: 700 !important;
    font-size: 11px !important;
}

.lc-m-0 {
    margin: 0 !important;
}

.lc-mt-3 {
    margin-top: 3px !important;
}

.lc-mt-2 {
    margin-top: 2px !important;
}

.lc-max-width-150-ellipsis {
    max-width: 150px !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
}

.lc-pt-0 {
    padding-top: 0 !important;
}

.lc-shadow-none {
    box-shadow: none !important;
}

.lc-border-none {
    border: none !important;
}

.lc-flex-start {
    display: flex !important;
    justify-content: flex-start !important;
}

.lc-gap-16 {
    gap: 16px !important;
}

.lc-flex-center-inline {
    display: inline-flex !important;
    align-items: center !important;
}

.lc-gap-6 {
    gap: 6px !important;
}

.lc-bg-slate-50 {
    background: #f8fafc !important;
}

.lc-rounded-8 {
    border-radius: 8px !important;
}

.lc-color-slate-800 {
    color: #1e293b !important;
}

.lc-mb-12 {
    margin-bottom: 12px !important;
}

.lc-gap-8 {
    gap: 8px !important;
}

.lc-marker-icon-purple {
    font-size: 18px !important;
    color: #4f46e5 !important;
}

.lc-alert-info {
    background: #eff6ff !important;
    border: 1px solid #3b82f6 !important;
    color: #1e40af !important;
    border-left-width: 4px !important;
    border-radius: 8px !important;
}

.lc-text-blue-500 {
    color: #3b82f6 !important;
}

.lc-color-indigo-900 {
    color: #1e3a8a !important;
}

.lc-alert-warning {
    background: #fffbeb !important;
    border: 1px solid #f59e0b !important;
    color: #92400e !important;
    border-left-width: 4px !important;
    border-radius: 8px !important;
}

.lc-text-orange-500 {
    color: #f59e0b !important;
}

.lc-color-orange-900 {
    color: #78350f !important;
}

.lc-color-slate-400 {
    color: #94a3b8 !important;
}

.lc-p-10 {
    padding: 10px !important;
}

.lc-checkbox-scroll-container {
    max-height: 100px !important;
    overflow-y: auto !important;
    border: 1px solid #e2e8f0 !important;
    padding: 6px !important;
    border-radius: 4px !important;
    background: white !important;
}

.lc-btn-indigo-sm {
    padding: 4px 12px !important;
    height: auto !important;
    font-size: 12px !important;
    background: #4f46e5 !important;
    color: white !important;
    border: none !important;
    border-radius: 4px !important;
    cursor: pointer !important;
}

.lc-bg-indigo-50 {
    background: #eef2ff !important;
}

.lc-border-indigo-200 {
    border: 1px solid #c7d2fe !important;
}

.lc-mx-neg-5 {
    margin-left: -5px !important;
    margin-right: -5px !important;
}

.lc-color-indigo-700 {
    color: #4338ca !important;
}

.lc-font-800 {
    font-weight: 800 !important;
}

.lc-color-indigo-800 {
    color: #1e40af !important;
}

.lc-block {
    display: block !important;
}

.lc-grid-auto-fill-180 {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)) !important;
}

.lc-overflow-auto-max-150 {
    max-height: 150px !important;
    overflow-y: auto !important;
}

.lc-mapping-tag {
    background: #eef2ff !important;
    border: 1px solid #bfdbfe !important;
    border-radius: 6px !important;
    padding: 6px 10px !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    shadow: 0 1px 2px rgba(0, 0, 0, 0.05) !important;
}

.lc-gap-2 {
    gap: 2px !important;
}

.lc-color-blue-400 {
    color: #60a5fa !important;
}

.lc-btn-cancel-icon {
    color: #f87171 !important;
    border: none !important;
    background: transparent !important;
    padding: 0 4px !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
}

.lc-pt-16 {
    padding-top: 16px !important;
}

.lc-rounded-t-0 {
    border-top-left-radius: 0 !important;
    border-top-right-radius: 0 !important;
}

.lc-width-80 {
    width: 80px !important;
}

.lc-color-slate-600 {
    color: #475569 !important;
}

.lc-search-input-field-custom {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 20px !important;
    padding: 8px 16px 8px 36px !important;
    font-size: 13px !important;
    color: #1e293b !important;
    outline: none !important;
    width: 220px !important;
}

.lc-role-filter-select {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 20px !important;
    padding: 8px 14px !important;
    font-size: 13px !important;
    color: #1e293b !important;
    outline: none !important;
}

.lc-alert-danger-custom {
    margin: 20px 0 !important;
    padding: 15px !important;
    border-radius: 8px !important;
    font-weight: 500 !important;
}

.lc-modal-max-700 {
    max-width: 700px !important;
}

.lc-alert-danger-sm {
    padding: 10px 15px !important;
    border-radius: 8px !important;
    font-size: 13px !important;
}

.lc-text-danger {
    color: #ef4444 !important;
}

.lc-relative {
    position: relative !important;
}

.lc-pr-40 {
    padding-right: 40px !important;
}

.lc-pwd-toggle-btn {
    position: absolute !important;
    right: 10px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    background: none !important;
    border: none !important;
    cursor: pointer !important;
    color: #94a3b8 !important;
    display: flex !important;
    align-items: center !important;
}

.lc-width-fit {
    width: fit-content !important;
}

.lc-mt-0 {
    margin-top: 0 !important;
}

.lc-mt-16 {
    margin-top: 16px !important;
}

.lc-mt-8 {
    margin-top: 8px !important;
}

.lc-p-8-18 {
    padding: 8px 18px !important;
}

.lc-vertical-middle {
    vertical-align: middle !important;
}

.lc-mr-4 {
    margin-right: 4px !important;
}

.lc-color-green-500 {
    color: #22c55e !important;
}

.lc-mr-6 {
    margin-right: 6px !important;
}

.lc-animate-spin {
    animation: spin 1s linear infinite !important;
}

.lc-avatar-initials-mini {
    width: 28px !important;
    height: 28px !important;
    border-radius: 50% !important;
    background: #e0e7ff !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    color: #4f46e5 !important;
    flex-shrink: 0 !important;
}

.lc-color-orange-500 {
    color: #f59e0b !important;
}

.lc-width-120 {
    width: 120px !important;
}

.lc-role-badge {
    font-size: 11px !important;
    font-weight: 700 !important;
    padding: 2px 8px !important;
    border-radius: 12px !important;
    display: inline-block !important;
}

.lc-role-badge-admin {
    background: #ede9fe !important;
    color: #7c3aed !important;
}

.lc-role-badge-staff {
    background: #dbeafe !important;
    color: #1d4ed8 !important;
}

.lc-role-badge-labtech {
    background: #dcfce7 !important;
    color: #15803d !important;
}

.lc-role-badge-receptionist {
    background: #fef9c3 !important;
    color: #b45309 !important;
}

.lc-role-badge-unknown {
    background: #f1f5f9 !important;
    color: #64748b !important;
}

.lc-status-pill-gray {
    background: rgba(15, 23, 42, 0.05) !important;
    border: 1px solid rgba(15, 23, 42, 0.1) !important;
    cursor: pointer !important;
    gap: 10px !important;
    font-weight: 700 !important;
    color: #1e293b !important;
    font-size: 11px !important;
    letter-spacing: 0.5px !important;
}

.lc-status-dot-green {
    background: #10b981 !important;
    width: 8px !important;
    height: 8px !important;
    border-radius: 50% !important;
}

.lc-dropdown-pos-top-100 {
    top: 100% !important;
    left: 0 !important;
    right: 0 !important;
}

.lc-toast-success {
    border: 1px solid #16a34a !important;
    padding: 6px 8px !important;
    display: block !important;
    border-radius: 6px !important;
    background: #f0fdf4 !important;
}

.lc-gap-10 {
    gap: 10px !important;
}

.lc-height-40 {
    height: 40px !important;
}

.lc-width-64 {
    width: 64px !important;
}

.lc-width-128 {
    width: 128px !important;
}

.lc-p-48 {
    padding: 48px !important;
}

.lc-italic {
    font-style: italic !important;
}

.lc-font-mono {
    font-family: monospace !important;
}

.lc-color-slate-900 {
    color: #1e293b !important;
}

/* ─────────────────────────────────────────────────────────────────────────
   VIEW BILLS PAGE STYLES
   ───────────────────────────────────────────────────────────────────────── */
.view-bills-page {
    padding: 24px;
    background: #f8fafc;
    min-height: 100vh;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

.view-bills-page .header-section {
    margin-bottom: 24px;
}

.view-bills-page .page-title {
    font-size: 28px;
    font-weight: 800;
    color: #1e293b;
    margin: 0;
}

.view-bills-page .page-subtitle {
    font-size: 14px;
    color: #64748b;
    margin-top: 4px;
}

.view-bills-page .filter-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    padding: 24px;
    margin-bottom: 24px;
}

.view-bills-page .filter-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr) auto;
    gap: 16px;
    align-items: flex-end;
    margin-bottom: 20px;
}

.view-bills-page .filter-item label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    color: #475569;
    margin-bottom: 6px;
    text-transform: uppercase;
}

.view-bills-page .form-control,
.view-bills-page .form-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #f8fafc;
    font-size: 13px;
    color: #1e293b;
}

.view-bills-page .btn-refresh,
.view-bills-page .btn-close-counter {
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: 0.2s;
    font-size: 12px;
    text-transform: uppercase;
}

.view-bills-page .btn-refresh {
    background: #2563eb;
}

.view-bills-page .btn-refresh:hover {
    background: #1d4ed8;
}

.view-bills-page .btn-close-counter {
    background: #475569;
}

.view-bills-page .btn-close-counter:hover {
    background: #334155;
}

.view-bills-page .filter-action {
    display: flex;
    gap: 12px;
}

.view-bills-page .search-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.view-bills-page .search-item {
    position: relative;
}

.view-bills-page .search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 20px;
}

.view-bills-page .search-input {
    width: 100%;
    padding: 12px 12px 12px 40px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #ffffff;
    font-size: 13px;
    transition: 0.2s;
}

.view-bills-page .table-container {
    background: white;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    overflow-x: auto;
    overflow-y: hidden;
    position: relative;
    max-width: 100%;
}

.view-bills-page .premium-table {
    width: 100%;
    min-width: 1200px;
    border-collapse: separate;
    border-spacing: 0;
    font-size: 13px;
}

.view-bills-page .premium-table th {
    background: #ffffff;
    border-bottom: 2px solid #f1f5f9;
    padding: 16px;
    text-align: left;
    font-weight: 700;
    color: #475569;
    font-size: 11px;
    text-transform: uppercase;
    position: sticky;
    top: 0;
    z-index: 5;
}

.view-bills-page .premium-table td {
    padding: 16px;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
}

.view-bills-page .sid-text {
    font-weight: 700;
    color: #2563eb;
}

.view-bills-page .pat-id {
    font-weight: 600;
    color: #1e293b;
}

.view-bills-page .pat-name {
    font-weight: 700;
    color: var(--lc-secondary);
}

.view-bills-page .mobile-text {
    color: #64748b;
    font-size: 12px;
}

.view-bills-page .action-icons {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.view-bills-page .icon-btn {
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    transition: 0.2s;
    padding: 4px;
    border-radius: 4px;
}

.view-bills-page .icon-btn:hover {
    background: #f1f5f9;
    color: #1e293b;
}

.view-bills-page .icon-btn.text-danger:hover {
    background: #fee2e2;
    color: #ef4444;
}

.view-bills-page .footer-section {
    margin-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.view-bills-page .results-info {
    font-size: 13px;
    color: #64748b;
}

.view-bills-page .pagination {
    display: flex;
    gap: 4px;
}

.view-bills-page .pg-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #e2e8f0;
    background: white;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: 0.2s;
}

.view-bills-page .pg-btn:hover {
    border-color: #2563eb;
    color: #2563eb;
}

.view-bills-page .pg-btn.active {
    background: #2563eb;
    color: white;
    border-color: #2563eb;
}

.view-bills-page .loader-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.view-bills-page .loader {
    width: 32px;
    height: 32px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #2563eb;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.view-bills-page .settled-row {
    border-left: 4px solid #10b981;
}

.view-bills-page .pending-row {
    border-left: 4px solid #f59e0b;
}

.lc-text-center {
    text-align: center !important;
}

.lc-text-right {
    text-align: right !important;
}

.lc-text-left {
    text-align: left !important;
}

.lc-font-700 {
    font-weight: 700 !important;
}

.lc-font-600 {
    font-weight: 600 !important;
}

.lc-font-800 {
    font-weight: 800 !important;
}

.lc-color-green-500 {
    color: #10b981 !important;
}

.lc-color-red-500 {
    color: #ef4444 !important;
}

.lc-color-orange-500 {
    color: #f97316 !important;
}

.lc-cursor-pointer {
    cursor: pointer !important;
}

.lc-rounded-pill-input {
    border-radius: 20px !important;
    border: 1px solid #e2e8f0 !important;
    background: #ffffff !important;
    padding: 10px 18px !important;
    transition: all 0.2s ease !important;
}

.lc-rounded-pill-input:focus {
    border-color: #4f46e5 !important;
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1) !important;
    background: white !important;
    outline: none !important;
}

.lc-modal-close-btn-effect {
    transition: transform 0.2s !important;
}

.lc-modal-close-btn-effect:hover {
    transform: scale(1.1) !important;
    color: #ef4444 !important;
}

.lc-fadeInUp {
    animation: fadeInUp 0.4s ease-out !important;
}

.lc-width-100 {
    width: 100px !important;
}

.lc-width-150 {
    width: 150px !important;
}

.lc-width-180 {
    width: 180px !important;
}

.lc-w-220 {
    width: 220px !important;
}

.lc-circle-btn-32 {
    border: 1px solid #e2e8f0 !important;
    border-radius: 50% !important;
    width: 32px !important;
    height: 32px !important;
    background: white !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.2s ease !important;
}

/* ─────────────────────────────────────────────────────────────────────────
   RATE MASTER PAGE STYLES
   ───────────────────────────────────────────────────────────────────────── */
.rate-container {
    background: #f8fafc;
    padding: 24px;
    min-height: 100vh;
    font-family: 'Inter', sans-serif;
}

.rate-header {
    padding: 16px 24px;
    border-radius: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    color: white;
    background: white;
}

.rate-header-radios {
    display: flex;
    gap: 24px;
}

.rate-radio-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: 700;
    font-size: 11px;
    text-transform: uppercase;
}

.rate-radio-input {
    appearance: none;
    width: 16px;
    height: 16px;
    border: 2px solid #cbd5e1;
    border-radius: 50%;
    outline: none;
    transition: 0.2s;
}

.rate-radio-input:checked {
    background: #4f46e5;
    border-color: #4f46e5;
    box-shadow: inset 0 0 0 3px white;
}

.rate-main-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: 0 4px 6px -1px #00000010;
    border: 1px solid #e2e8f0;
}

.rate-form-grid {
    display: grid;
    grid-template-columns: 1.2fr 1.8fr;
    gap: 48px;
}

.rate-form-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.rate-form-group {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 8px;
}

.rate-label {
    font-weight: 800;
    font-size: 10px;
    text-transform: uppercase;
    color: #475569;
    width: 100px;
}

.rate-input {
    flex: 1;
    height: 36px;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    padding: 0 12px;
    font-size: 12px;
    outline: none;
}

.rate-input:focus {
    border-color: #4f46e5;
}

.rate-radio-group {
    display: flex;
    gap: 16px;
    flex: 1;
}

.rate-radio-item {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-weight: 700;
    font-size: 11px;
}

.rate-radio-item-input {
    cursor: pointer;
    width: 14px;
    height: 14px;
}

.rate-form-group-gap {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    width: 100%;
}

.rate-label-small {
    font-weight: 800;
    font-size: 10px;
    text-transform: uppercase;
    color: #475569;
    width: 100px;
}

.rate-btn-default {
    height: 36px;
    padding: 0 16px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 800;
    cursor: pointer;
}

.rate-right-action-group {
    display: flex;
    gap: 16px;
    align-items: flex-start;
}

.rate-nested-group {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.rate-input-small {
    width: 60px;
    height: 36px;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    text-align: center;
}

.rate-btn-set {
    height: 36px;
    padding: 0 12px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    cursor: pointer;
}

.rate-btn-set-blue {
    height: 36px;
    padding: 0 12px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    cursor: pointer;
}

.rate-btn-big {
    width: 140px;
    height: 84px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.rate-grid-container {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px #00000010;
}

.rate-grid-scroll {
    max-height: 500px;
    overflow-y: auto;
}

.rate-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
}

.rate-table th {
    padding: 12px 16px;
    text-align: left;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    font-weight: 800;
    white-space: nowrap;
}

.rate-table td {
    padding: 8px 16px;
    border-bottom: 1px solid #f1f5f9;
    font-weight: 600;
    white-space: nowrap;
}

.rate-row-active {
    background: #f1f5f9;
}

.rate-row-pointer {
    color: #555;
    margin-right: 4px;
}

.rate-footer-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.rate-btn-footer {
    height: 40px;
    padding: 0 16px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    font-weight: 800;
    font-size: 10px;
    text-transform: uppercase;
    cursor: pointer;
}

.rate-btn-footer.wide {
    min-width: 100px;
}

.rate-btn-footer.primary {
    background: #4f46e5;
    color: white;
    border: none;
}

.cm-input option,
.form-control option {
    color: #1e293b !important;
    background: #ffffff !important;
}

.lc-width-25p {
    width: 25% !important;
}

.lc-width-15p {
    width: 15% !important;
}

.lc-width-20p {
    width: 20% !important;
}

.lc-width-140 {
    width: 140px !important;
}

.lc-p-40 {
    padding: 40px !important;
}

.lc-mb-0 {
    margin-bottom: 0px !important;
}

.lc-mb-20 {
    margin-bottom: 20px !important;
}

.lc-mt-2px {
    margin-top: 2px !important;
}

.lc-mt-neg-4 {
    margin-top: -4px !important;
}

.lc-mr-8 {
    margin-right: 8px !important;
}

.lc-gap-16 {
    gap: 16px !important;
}

.lc-gap-12 {
    gap: 12px !important;
}

.lc-gap-8 {
    gap: 8px !important;
}

.lc-rounded-lg {
    border-radius: 8px !important;
}

.lc-rounded-12 {
    border-radius: 12px !important;
}

.lc-rounded-20 {
    border-radius: 20px !important;
}

.lc-rounded-full {
    border-radius: 50% !important;
}

.lc-rounded-t-0 {
    border-top-left-radius: 0px !important;
    border-top-right-radius: 0px !important;
}

.lc-shadow-sm {
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
}

.lc-icon-24 {
    font-size: 24px !important;
}

.lc-icon-18 {
    font-size: 18px !important;
}

.lc-text-10 {
    font-size: 10px !important;
}

.lc-text-11 {
    font-size: 11px !important;
}

.lc-text-12 {
    font-size: 12px !important;
}

.lc-text-13 {
    font-size: 13px !important;
}

.lc-text-18 {
    font-size: 18px !important;
}

.lc-uppercase {
    text-transform: uppercase !important;
}

.lc-ls-05 {
    letter-spacing: 0.5px !important;
}

.lc-w-40 {
    width: 40px !important;
}

.lc-h-40 {
    height: 40px !important;
}

.lc-w-6 {
    width: 6px !important;
}

.lc-h-6 {
    height: 6px !important;
}

.lc-w-200 {
    width: 200px !important;
}

.lc-w-220 {
    width: 220px !important;
}

.lc-text-white {
    color: #ffffff !important;
}

.lc-animate-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite !important;
}

.lc-alert-danger-custom {
    margin: 20px 0 !important;
    padding: 15px !important;
    border-radius: 8px !important;
    font-weight: 500 !important;
}

.lc-alert-danger-sm {
    padding: 10px 15px !important;
    border-radius: 8px !important;
    font-size: 13px !important;
}

.lc-alert-success-custom {
    margin-bottom: 20px !important;
    padding: 15px !important;
    border-radius: 8px !important;
    font-weight: 500 !important;
}

.lc-bg-danger-light {
    background-color: #fef2f2 !important;
}

.lc-bg-success-light {
    background-color: #f0fdf4 !important;
}

.lc-abs-center-y {
    position: absolute !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
}

.lc-left-12 {
    left: 12px !important;
}

.lc-right-12 {
    right: 12px !important;
}

.lc-p-8-16-8-36 {
    padding: 8px 16px 8px 36px !important;
}

.lc-grid {
    display: grid !important;
}

.lc-grid-cols-80-1fr {
    grid-template-columns: 80px 1fr !important;
}

.lc-grid-cols-3 {
    grid-template-columns: repeat(3, 1fr) !important;
}

.lc-grid-cols-4 {
    grid-template-columns: repeat(4, 1fr) !important;
}

.lc-grid-cols-5 {
    grid-template-columns: repeat(5, 1fr) !important;
}

.lc-flex-between {
    justify-content: space-between !important;
}

.lc-mb-4px {
    margin-bottom: 4px !important;
}

.lc-font-500 {
    font-weight: 500 !important;
}





/* Styles from Billing.razor */
.no-spin::-webkit-inner-spin-button,
.no-spin::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.no-spin {
    -moz-appearance: textfield;
}

.pay-input.no-spin {
    appearance: textfield;
}

.bl-id-type-select {
    background: transparent;
    color: white;
    border: none;
    width: 100%;
    height: 100%;
    padding: 0 8px;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    outline: none;
}

.bl-id-type-select option {
    color: #1e293b !important;
    background: #ffffff !important;
    text-transform: none;
}



.bl-id-input {
    flex: 1;
    border: none;
    padding: 10px 12px;
    font-size: 13px;
    outline: none;
}

.lc-bg-white {
    background-color: #ffffff !important;
}

.lc-border-slate-200 {
    border: 1px solid #e2e8f0 !important;
}

.lc-outline-none {
    outline: none !important;
}

/* ─────────────────────────────────────────────────────────────────────────
   TOAST NOTIFICATION STYLES
   ───────────────────────────────────────────────────────────────────────── */
.toast-container {
    position: fixed;
    top: 24px;
    right: 24px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

.toast-item {
    min-width: 300px;
    max-width: 450px;
    padding: 16px;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    pointer-events: auto;
    animation: toast-in 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    border-left: 6px solid #ccc;
}

.toast-item.show {
    opacity: 1;
    transform: translateX(0);
}

.toast-item.hide {
    opacity: 0;
    transform: translateX(100%);
    transition: all 0.3s ease;
}

.toast-item.success {
    border-left-color: #22c55e;
}

.toast-item.error {
    border-left-color: #ef4444;
}

.toast-item.warning {
    border-left-color: #f59e0b;
}

.toast-item.info {
    border-left-color: #3b82f6;
}

.toast-item.success .icon {
    color: #22c55e;
}

.toast-item.error .icon {
    color: #ef4444;
}

.toast-item.warning .icon {
    color: #f59e0b;
}

.toast-item.info .icon {
    color: #3b82f6;
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.toast-content .icon {
    font-variation-settings: 'FILL' 1;
}

.toast-content .message {
    font-size: 14px;
    font-weight: 500;
    color: #1e293b;
}

.toast-item .close-btn {
    background: transparent;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.toast-item .close-btn:hover {
    color: #475569;
}

@keyframes toast-in {
    from {
        opacity: 0;
        transform: translateX(100%) scale(0.9);
    }
}

/* ─────────────────────────────────────────────────────────────────────────
   PREMIUM BILLING SHARED STYLES
   ───────────────────────────────────────────────────────────────────────── */
:root {
    --premium-blue: #2563eb;
    --premium-blue-light: #eff6ff;
    --premium-blue-dark: #1e40af;
    --premium-green: #10b981;
    --premium-green-light: #ecfdf5;
    --premium-red: #ef4444;
    --premium-red-light: #fef2f2;
    --premium-gray-text: #64748b;
    --premium-dark-text: #1e293b;
    --premium-border: #e2e8f0;
    --premium-bg: #f8fafc;
    --premium-card-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --premium-card-shadow-hover: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.premium-page-container {
    padding: 24px;
    background-color: var(--premium-bg);
    min-height: 100vh;
    font-family: 'Public Sans', sans-serif;
}

.premium-header {
    margin-bottom: 32px;
}

.premium-title {
    font-size: 28px;
    font-weight: 800;
    color: var(--premium-dark-text);
    text-transform: uppercase;
    letter-spacing: -0.5px;
    margin-bottom: 8px;
}

.premium-subtitle {
    font-size: 14px;
    color: var(--premium-gray-text);
    font-weight: 500;
}

.premium-filter-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    box-shadow: var(--premium-card-shadow);
    border: 1px solid var(--premium-border);
    margin-bottom: 24px;
}

.premium-filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    align-items: flex-end;
}

.premium-form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.premium-label {
    font-size: 11px;
    font-weight: 700;
    color: var(--premium-gray-text);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.premium-input,
.premium-select {
    height: 44px;
    border-radius: 8px;
    border: 1.5px solid var(--premium-border);
    padding: 0 16px;
    font-size: 14px;
    font-weight: 600;
    color: var(--premium-dark-text);
    background-color: #fff;
    transition: all 0.2s;
    outline: none;
}

.premium-input:focus,
.premium-select:focus {
    border-color: var(--premium-blue);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.premium-search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.premium-search-icon {
    position: absolute;
    left: 12px;
    color: var(--premium-gray-text);
    font-size: 18px;
}

.premium-search-input {
    padding-left: 40px !important;
}

.premium-btn-refresh {
    height: 44px;
    background: var(--premium-blue);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 0 24px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.premium-btn-refresh:hover {
    background: var(--premium-blue-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

.premium-search-bar-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 20px;
}

.premium-table-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--premium-card-shadow);
    border: 1px solid var(--premium-border);
}

.premium-table {
    width: 100%;
    border-collapse: collapse;
}

.premium-table th {
    background: #f8fafc;
    padding: 16px 12px;
    text-align: left;
    font-size: 11px;
    font-weight: 700;
    color: var(--premium-gray-text);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid var(--premium-border);
}

.premium-table td {
    padding: 16px 12px;
    font-size: 13px;
    border-bottom: 1px solid #f1f5f9;
    color: var(--premium-dark-text);
    vertical-align: middle;
}

.premium-table tbody tr:hover {
    background-color: #f8fafc;
}

.sid-text {
    font-weight: 700;
    color: #475569;
}

.patient-id {
    font-weight: 800;
    color: #1e293b;
}

.patient-name {
    font-weight: 700;
    display: block;
}

.mobile-text {
    font-size: 12px;
    color: var(--premium-gray-text);
    font-weight: 500;
}

.amount-text {
    font-weight: 700;
}

.discount-text {
    color: var(--premium-red);
    font-weight: 600;
}

.total-text {
    font-weight: 800;
    color: var(--premium-dark-text);
}

.paid-text {
    font-weight: 700;
    color: var(--premium-green);
}

.balance-text {
    font-weight: 700;
}

.action-buttons {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

.action-btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--premium-border);
    background: white;
    color: var(--premium-gray-text);
    cursor: pointer;
    transition: all 0.2s;
}

.action-btn:hover {
    background: var(--premium-blue-light);
    color: var(--premium-blue);
    border-color: var(--premium-blue);
}

.premium-footer {
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    border-top: 1px solid var(--premium-border);
}

.pagination-info {
    font-size: 13px;
    color: var(--premium-gray-text);
    font-weight: 500;
}

.pagination-controls {
    display: flex;
    gap: 4px;
}

.page-btn {
    width: 36px;
    height: 36px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--premium-border);
    background: white;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s;
}

.page-btn.active {
    background: var(--premium-blue);
    color: white;
    border-color: var(--premium-blue);
}

.page-btn:hover:not(.active) {
    background: #f1f5f9;
}

.totals-row {
    background: #f8fafc !important;
}

.totals-label {
    font-weight: 800;
    text-transform: uppercase;
    text-align: right;
    padding-right: 24px !important;
}

.total-val {
    font-weight: 800;
    font-size: 15px;
}

.bl-datetime-inline {
    border: none !important;
    background: transparent !important;
    outline: none !important;
    font-family: inherit !important;
    font-size: inherit !important;
    font-weight: inherit !important;
    color: inherit !important;
    cursor: pointer !important;
}

/* ─────────────────────────────────────────────────────────────────────────
   TEST MASTER (MODIFY TEST) UI STYLES
   ───────────────────────────────────────────────────────────────────────── */
.tm-page-wrapper {
    padding: 20px;
    background: #f8fafc;
    min-height: 100vh;
    font-family: 'Public Sans', sans-serif;
}

.tm-top-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.tm-action-links {
    display: flex;
    gap: 20px;
}

.tm-action-link {
    font-size: 11px;
    font-weight: 700;
    color: #4f46e5;
    text-transform: uppercase;
    text-decoration: none;
    cursor: pointer;
}

.tm-action-link:hover {
    text-decoration: underline;
}

.tm-user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
}

.tm-user-info {
    text-align: right;
}

.tm-user-name {
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    display: block;
}

.tm-user-role {
    font-size: 10px;
    color: #64748b;
    font-weight: 600;
    text-transform: uppercase;
}

.tm-user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #fff;
    shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.tm-main-grid {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 20px;
}

.tm-card {
    background: #fff;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    padding: 24px;
    position: relative;
}

/* Test Details Header Section */
.tm-test-details-card {
    grid-column: 1 / span 2;
    margin-bottom: 20px;
}

.tm-test-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr 1fr;
    gap: 12px;
    margin-bottom: 8px;
}

.tm-form-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.tm-label {
    font-size: 10px;
    font-weight: 800;
    color: #4f46e5;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tm-input {
    height: 36px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 0 12px;
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
    transition: all 0.2s;
    background: #f8fafc;
}

.tm-input:focus {
    border-color: #4f46e5;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
    outline: none;
}

.tm-input-accent {
    border-color: #4f46e5;
    background: #eff6ff;
}

.tm-table-select {
    width: 100%;
    height: 24px;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    padding: 0 4px;
    font-size: 11px;
    font-weight: 600;
    color: #1e293b;
    background: #f8fafc;
    outline: none;
    cursor: pointer;
}

.tm-table-select:focus {
    border-color: #4f46e5;
    background: #fff;
}

/* Type & Status Section */
.tm-flex-row {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-top: 12px;
}

.tm-type-item,
.tm-status-item {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.tm-type-item span,
.tm-status-item span {
    font-size: 12px;
    font-weight: 600;
    color: #475569;
}

.tm-radio,
.tm-checkbox {
    width: 16px;
    height: 16px;
    border: 1.5px solid #cbd5e1;
    border-radius: 50%;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.tm-radio:checked {
    border-color: #4f46e5;
    border-width: 5px;
}

.tm-checkbox {
    border-radius: 4px;
}

.tm-checkbox:checked {
    background-color: #4f46e5;
    border-color: #4f46e5;
}

.tm-checkbox:checked::after {
    content: '✔';
    position: absolute;
    color: white;
    font-size: 10px;
    left: 2px;
    top: -1px;
}

/* Parameters Panel */
.tm-params-panel {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.tm-params-card {
    padding: 0;
    overflow: hidden;
}

.tm-card-header-slim {
    padding: 12px 20px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
}

.tm-card-title-slim {
    font-size: 12px;
    font-weight: 800;
    color: #1e293b;
}

.tm-link-blue {
    font-size: 10px;
    font-weight: 700;
    color: #4f46e5;
    cursor: pointer;
    text-decoration: none;
}

.tm-link-red {
    font-size: 10px;
    font-weight: 700;
    color: #ef4444;
    cursor: pointer;
    text-decoration: none;
}

.tm-param-table {
    width: 100%;
    border-collapse: collapse;
}

.tm-param-table th {
    background: #f8fafc;
    padding: 10px 16px;
    text-align: left;
    font-size: 10px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    border-bottom: 1px solid #e2e8f0;
}

.tm-param-row {
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
    transition: background 0.2s;
}

.tm-param-row:hover {
    background: #f8fafc;
}

.tm-param-row.active {
    background: #eff6ff;
}

.tm-param-cell {
    padding: 12px 16px;
    font-size: 13px;
    font-weight: 600;
    color: #334155;
}

.tm-param-input {
    border: none;
    background: transparent;
    width: 100%;
    outline: none;
    font-family: inherit;
    font-size: inherit;
    font-weight: inherit;
}

/* Normal Values Panel */
.tm-values-card {
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.tm-values-header {
    padding: 16px 24px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tm-tabs {
    display: flex;
    gap: 24px;
    border-bottom: 1px solid #e2e8f0;
    padding: 0 24px;
    background: #f8fafc;
}

.tm-tab {
    padding: 14px 0;
    font-size: 12px;
    font-weight: 700;
    color: #94a3b8;
    cursor: pointer;
    position: relative;
    transition: all 0.2s;
    border: none;
    background: transparent;
}

.tm-tab.active {
    color: #4f46e5;
}

.tm-tab.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: #4f46e5;
}

.tm-value-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    padding: 24px;
}

.tm-quill-editor {
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    min-height: 120px;
    margin-top: 8px;
}

.tm-editor-toolbar {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 4px 8px;
    display: flex;
    gap: 12px;
}

.tm-editor-btn {
    background: transparent;
    border: none;
    color: #64748b;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
}

.tm-editor-btn:hover {
    background: #e2e8f0;
}

.tm-editor-content {
    padding: 16px;
    min-height: 100px;
    font-size: 14px;
    outline: none;
}

/* Bottom Action Bar */
.tm-bottom-bar {
    position: sticky;
    bottom: 0;
    background: #fff;
    border-top: 1px solid #e2e8f0;
    padding: 16px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.05);
    border-radius: 0 0 16px 16px;
    margin-top: 20px;
}

.tm-date-range {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 4px 12px;
}

.tm-date-input {
    border: none;
    background: transparent;
    outline: none;
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
    width: 90px;
    cursor: pointer;
}

.tm-btn-row {
    display: flex;
    gap: 10px;
}

.tm-btn {
    height: 38px;
    padding: 0 20px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 11px;
    text-transform: uppercase;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.tm-btn-outline {
    background: #fff;
    border: 1px solid #e2e8f0;
    color: #64748b;
}

.tm-btn-primary {
    background: #4f46e5;
    color: #fff;
}

.tm-btn-danger {
    background: #ef4444;
    color: #fff;
}

.tm-btn-dark {
    background: #1e293b;
    color: #fff;
}

.tm-btn-secondary {
    background: #f3f4f6;
    color: #4b5563;
}

.tm-update-btn {
    background: #fff;
    border: 1.5px solid #f97316;
    color: #f97316;
    padding: 8px 24px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s;
    align-self: flex-end;
    margin: 24px;
    margin-top: 0;
}

.tm-update-btn:hover {
    background: #fff7ed;
    transform: translateY(-1px);
}

/* Special styling for input groups in image */
.tm-input-group {
    position: relative;
    border-radius: 8px;
    border: 1.5px solid #e2e8f0;
    background: #f8fafc;
    display: flex;
    align-items: center;
    padding: 0 12px;
    height: 36px;
}

.tm-input-group input {
    border: none;
    background: transparent;
    outline: none;
    flex: 1;
    font-size: 13px;
    font-weight: 600;
}

.tm-input-group .material-symbols-outlined {
    color: #94a3b8;
    font-size: 18px;
}

.tm-btn-blue {
    background: #4f46e5;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
}

.tm-btn-black {
    background: #000;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
}

/* Status section checkboxes specifically matching the image style */
.tm-status-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    align-items: center;
    margin-left: 20px;
    margin-top: 4px;
}

.tm-status-box {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    padding: 2px 0;
}

.tm-status-check {
    width: 12px;
    height: 12px;
    border: 1.5px solid #cbd5e1;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.tm-status-box:hover .tm-status-check {
    border-color: #4f46e5;
}

.tm-status-box.active .tm-status-check {
    border-color: #4f46e5;
    border-width: 4px;
}

.tm-status-label {
    font-size: 10px;
    font-weight: 700;
    color: #475569;
    white-space: nowrap;
}

.tm-sep-row {
    height: 1px;
    background: #f1f5f9;
    width: 100%;
    margin: 2px 0;
}

/* Flex & Layout Utilities */
.display-flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.flex-1 {
    flex: 1;
}

.align-center {
    align-items: center;
}

.justify-center {
    justify-content: center;
}

.justify-between {
    justify-content: space-between;
}

.justify-end {
    justify-content: flex-end;
}

.gap-4 {
    gap: 4px;
}

.gap-8 {
    gap: 8px;
}

.gap-12 {
    gap: 12px;
}

.gap-16 {
    gap: 16px;
}

.gap-24 {
    gap: 24px;
}

.gap-32 {
    gap: 32px;
}

/* Spacing Utilities */
.mt-4 {
    margin-top: 4px;
}

.mt-8 {
    margin-top: 8px;
}

.mt-12 {
    margin-top: 12px;
}

.mt-20 {
    margin-top: 20px;
}

.mb-16 {
    margin-bottom: 16px;
}

.my-16 {
    margin: 16px 0;
}

.ml-4 {
    margin-left: 4px;
}

.ml-20 {
    margin-left: 20px;
}

.p-12 {
    padding: 12px;
}

.p-24 {
    padding: 24px;
}

/* Sizing Utilities */
.w-full {
    width: 100%;
}

.w-48 {
    width: 48px;
}

.h-24 {
    height: 24px;
}

.h-28 {
    height: 28px;
}

.h-32 {
    height: 32px;
}

.h-80 {
    height: 80px;
}

/* Font Utilities */
.font-11 {
    font-size: 11px;
}

.font-14 {
    font-size: 14px;
}

.lc-outline-none {
    outline: none;
}

/* NORMAL VALUES TAB LAYOUTS */
.tm-tab-content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    flex: 1;
}

.tm-tab-left-col,
.tm-tab-right-col {
    display: flex;
    flex-direction: column;
}

.tm-specimen-table-wrapper {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    overflow: hidden;
}

.tm-specimen-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
}

.tm-specimen-table th {
    background: #f8fafc;
    padding: 8px 12px;
    text-align: left;
    font-weight: 600;
    color: #475569;
    border-bottom: 1px solid #e2e8f0;
}

.tm-specimen-table td {
    padding: 8px 12px;
    border-bottom: 1px solid #f1f5f9;
    color: #1e293b;
}

.tm-specimen-table tr:last-child td {
    border-bottom: none;
}

.tm-specimen-table tr:hover {
    background: #f1f5f9;
}

.tm-checkbox {
    width: 14px;
    height: 14px;
    accent-color: #2563eb;
    cursor: pointer;
}

.tm-btn-icon-gray {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    color: #64748b;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
}

.tm-btn-icon-gray:hover {
    background: #e2e8f0;
    color: #1e293b;
}

.tm-btn-icon-red {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: none;
    background: #fee2e2;
    color: #ef4444;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.tm-btn-icon-red:hover {
    background: #fecaca;
    color: #dc2626;
    transform: scale(1.05);
}

.tm-update-btn {
    background: #fff;
    border: 1px solid #f97316;
    color: #f97316;
    padding: 4px 20px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.tm-update-btn:hover {
    background: #fff7ed;
    box-shadow: 0 2px 4px rgba(249, 115, 22, 0.1);
}

.tm-values-header-accent {
    background: #e11d48;
    color: #fff;
    padding: 6px 16px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.tm-values-subheader {
    padding: 12px 24px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

.tm-link-orange {
    color: #f97316;
    text-decoration: none;
}

.tm-link-orange:hover {
    text-decoration: underline;
}

.tm-detailed-range-section {
    border-top: 1px solid #e2e8f0;
}

.tm-specimen-table-container {
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 12px;
}

.tm-specimen-table-modern {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
}

.tm-specimen-table-modern th {
    background: #fff;
    padding: 6px 10px;
    text-align: left;
    font-weight: 500;
    color: #1e293b;
    border-bottom: 1px solid #cbd5e1;
    border-right: 1px solid #cbd5e1;
}

.tm-specimen-table-modern th:last-child {
    border-right: none;
}

.tm-specimen-table-modern td {
    padding: 4px 10px;
    border-bottom: 1px solid #e2e8f0;
    border-right: 1px solid #cbd5e1;
    color: #334155;
}

.tm-specimen-table-modern td:last-child {
    border-right: none;
}

.tm-specimen-table-modern tr:last-child td {
    border-bottom: none;
}

.tm-specimen-table-modern tr:hover td {
    background: #f8fafc;
}

.tm-specimen-row-active td {
    background: #eff6ff !important;
    border-left: 3px solid #4f46e5;
}

.text-red {
    color: #ef4444 !important;
}

.fw-600 {
    font-weight: 600;
}

.bl-scan-btn {
    background: #4f46e5;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(79, 70, 229, 0.2);
}

.bl-scan-btn:hover {
    background: #4338ca;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(79, 70, 229, 0.3);
}

.bl-scan-btn .material-symbols-outlined {
    font-size: 16px;
}


.bl-scan-icon-only {
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: white;
    border: none;
    padding: 8px;
    border-radius: 10px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 6px -1px rgba(79, 70, 229, 0.2), 0 2px 4px -1px rgba(79, 70, 229, 0.1);
}

.bl-scan-icon-only:hover {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.3);
}

.bl-yt-search-group {
    display: flex;
    align-items: center;
    background: #f8fafc;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.2s;
    height: 40px;
}

.bl-yt-search-group:focus-within {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
    background: white;
}

.bl-yt-input {
    flex: 1;
    border: none !important;
    background: transparent !important;
    padding: 0 12px !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    color: #1e293b !important;
    outline: none !important;
    height: 100% !important;
}

.bl-yt-button {
    background: #f1f5f9;
    border: none;
    border-left: 1.5px solid #e2e8f0;
    color: #4f46e5;
    width: 44px;
    height: 100%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    flex-shrink: 0;
}

.bl-yt-button:hover {
    background: #e2e8f0;
    color: #1e293b;
}

.bl-yt-button.has-scan {
    color: #10b981;
}

.bl-yt-button .material-icons {
    font-size: 24px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1 !important;
    width: 24px;
    height: 24px;
}

.bl-scan-status-container {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #ecfdf5;
    padding: 4px 10px;
    border-radius: 8px;
    border: 1px solid #10b981;
}

.bl-scan-tick {
    color: #10b981;
    font-size: 18px !important;
}

.bl-scan-cancel {
    color: #ef4444;
    font-size: 16px !important;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.bl-scan-cancel:hover {
    opacity: 1;
}

.bl-scan-path-badge {
    background: #f1f5f9;
    color: #64748b;
    font-size: 10px;
    padding: 4px 8px;
    border-radius: 6px;
    margin-top: 6px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    border: 1px solid #e2e8f0;
}

/* ===============================================
   Result Entry - Premium Modern Design
   =============================================== */

/* Container */
.re-container {
    padding: 16px 20px 80px;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: #1e293b;
    background: #f8fafc;
    min-height: calc(100vh - 64px);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Common form elements */
.re-label {
    font-size: 0.7rem;
    font-weight: 650;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.re-input,
.re-select,
.re-input-date,
.re-input-time,
.re-textarea {
    padding: 4px 8px;
    border-radius: 6px;
    border: 1.5px solid #e2e8f0;
    font-size: 0.8rem;
    color: #1e293b;
    background: #fff;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    transition: all 0.2s ease;
    outline: none;
    box-sizing: border-box;
}

.re-input:focus,
.re-select:focus,
.re-input-date:focus,
.re-input-time:focus,
.re-textarea:focus {
    border-color: #6366f1;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

.re-input,
.re-select,
.re-input-date,
.re-input-time {
    height: 30px;
}

.re-select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24'%3E%3Cpath fill='%2394a3b8' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 8px center;
    padding-right: 24px;
    cursor: pointer;
}

.re-input-yellow {
    background-color: #fefce8;
    border-color: #fde68a;
    color: #92400e;
}

.re-input-yellow:focus {
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.15);
}

/* Header Section */
.re-header-section {
    background: #f8fafc;
    border-radius: 8px;
    padding: 12px 16px;
    border: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.re-breadcrumb {
    display: flex;
    align-items: center;
    font-family: inherit;
    font-size: 0.9rem;
}

.re-breadcrumb i.fa-home {
    color: #4f46e5;
    font-size: 1rem;
    margin-right: 12px;
}

.re-breadcrumb span.text-muted {
    color: #64748b;
    margin-right: 12px;
}

.re-breadcrumb i.fa-chevron-right {
    color: #cbd5e1;
    font-size: 0.7rem;
    margin-right: 12px;
}

.re-breadcrumb span.text-active {
    color: var(--lc-secondary);
    font-weight: 600;
}

.re-header-right {
    display: flex;
    align-items: center;
    gap: 16px;
    z-index: 1;
}

/* Sample Card */
.re-sample-card {
    background: #fff;
    border-radius: 12px;
    padding: 12px 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
    border: 1px solid #e9edf3;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.re-field-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Custom Checkbox/Radio */
.re-check-label,
.re-radio-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #334155;
    cursor: pointer;
    user-select: none;
}

.re-check-label input[type="checkbox"],
.re-radio-label input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border: 2px solid #cbd5e1;
    border-radius: 4px;
    outline: none;
    transition: all 0.2s;
    position: relative;
    cursor: pointer;
}

.re-radio-label input[type="radio"] {
    border-radius: 50%;
}

.re-check-label input[type="checkbox"]:checked,
.re-radio-label input[type="radio"]:checked {
    background-color: #6366f1;
    border-color: #6366f1;
}

.re-check-label input[type="checkbox"]:checked::after {
    content: '\f00c';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 10px;
}

.re-radio-label input[type="radio"]:checked::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
}

/* Tabs */
.re-tabs-container {
    display: flex;
    gap: 8px;
    margin-top: 6px;
    margin-bottom: 2px;
    padding: 0 4px;
}

.re-tab {
    background: transparent;
    border: none;
    padding: 8px 16px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    border-radius: 8px 8px 0 0;
    border-bottom: 3px solid transparent;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.re-tab:hover {
    color: #4f46e5;
    background: rgba(99, 102, 241, 0.05);
}

.re-tab.active {
    color: #4f46e5;
    border-bottom-color: #4f46e5;
    background: rgba(99, 102, 241, 0.08);
}

/* Main Content Area */
.re-main-content {
    display: flex;
    gap: 24px;
    flex-grow: 1;
    align-items: flex-start;
    position: relative;
}

.re-panel-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #e9edf3;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.re-left-panel {
    width: 100%;
    min-height: 390px;
}

.re-right-panel {
    position: absolute;
    top: 10px;
    right: 16px;
    width: 320px;
    z-index: 50;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.08);
    border: 1px solid #cbd5e1;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
}

/* Table Actions */
.re-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-bottom: 1px solid #f1f5f9;
    background: #fafbff;
}

/* ===== BILLED TESTS DROPDOWN ===== */
.re-bt-wrapper {
    position: relative;
}

.re-billed-tests {
    color: #ef4444;
    font-weight: 700;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 6px;
    background: #fef2f2;
    padding: 4px 10px;
    border-radius: 6px;
    border: 1px solid #fecaca;
    cursor: pointer;
    user-select: none;
    transition: all 0.2s;
}

.re-billed-tests:hover,
.re-billed-tests.active {
    background: #fee2e2;
    border-color: #fca5a5;
}

.re-bt-chevron {
    font-size: 0.6rem;
    transition: transform 0.25s ease;
    margin-left: 2px;
}

.re-bt-chevron.up {
    transform: rotate(180deg);
}

/* ===== ADVANCE FILTER DROPDOWN ===== */
.re-af-wrapper {
    position: relative;
}

.re-advance-filter {
    background: #f1f5f9;
    border: 1.5px solid #e2e8f0;
    padding: 0 12px;
    height: 30px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 650;
    color: #475569;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
    user-select: none;
}

.re-advance-filter:hover,
.re-advance-filter.active {
    background: #e2e8f0;
    border-color: #cbd5e1;
    color: #1e293b;
}

.re-af-chevron {
    font-size: 0.65rem;
    transition: transform 0.25s ease;
    color: #94a3b8;
}

.re-af-chevron.up {
    transform: rotate(180deg);
}

.re-af-dropdown {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 220px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
    z-index: 200;
    overflow: hidden;
    animation: re-bt-appear 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.re-af-dropdown-header {
    padding: 8px 12px;
    background: #f8fafc;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.7rem;
    font-weight: 800;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.re-af-dropdown-body {
    max-height: 280px;
    overflow-y: auto;
}

.re-af-item {
    padding: 8px 12px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #334155;
    cursor: pointer;
    transition: all 0.15s;
}

.re-af-item:hover {
    background: #f8fafc;
    color: #4f46e5;
}

.re-af-item.selected {
    background: #eff6ff;
    color: #2563eb;
    position: relative;
    padding-left: 28px;
}

.re-af-item.selected::before {
    content: '\f00c';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    position: absolute;
    left: 10px;
    font-size: 0.7rem;
}

.re-af-overlay {
    position: fixed;
    inset: 0;
    z-index: 199;
}

/* ===== TEST SEARCH ===== */
.re-search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.re-test-search {
    min-width: 180px;
    padding-right: 28px !important;
}

.re-clear-search {
    position: absolute;
    right: 6px;
    background: none;
    border: none;
    color: #cbd5e1;
    cursor: pointer;
    padding: 4px;
    font-size: 0.75rem;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.re-clear-search:hover {
    color: #ef4444;
}

/* Dropdown Panel */
.re-bt-dropdown {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    min-width: 240px;
    max-width: 320px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12), 0 4px 8px rgba(0, 0, 0, 0.06);
    z-index: 200;
    overflow: hidden;
    animation: re-bt-appear 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes re-bt-appear {
    from {
        opacity: 0;
        transform: translateY(-6px) scale(0.97);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Dropdown Header */
.re-bt-dropdown-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    background: linear-gradient(to right, #fef2f2, #fff);
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.75rem;
    font-weight: 700;
    color: #ef4444;
    gap: 8px;
}

.re-bt-count {
    background: #fecaca;
    color: #b91c1c;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 20px;
}

/* Dropdown Body */
.re-bt-dropdown-body {
    max-height: 220px;
    overflow-y: auto;
    padding: 4px 0;
}

.re-bt-dropdown-body::-webkit-scrollbar {
    width: 4px;
}

.re-bt-dropdown-body::-webkit-scrollbar-thumb {
    background: #e2e8f0;
    border-radius: 4px;
}

/* Individual Test Item */
.re-bt-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 12px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #334155;
    cursor: pointer;
    transition: background 0.15s;
    user-select: none;
}

.re-bt-item:hover {
    background: #f8fafc;
}

.re-bt-item.selected {
    color: #1e293b;
}

.re-bt-item input[type="checkbox"] {
    width: 14px;
    height: 14px;
    accent-color: #ef4444;
    cursor: pointer;
    flex-shrink: 0;
}

.re-bt-item-name {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Empty State */
.re-bt-empty {
    padding: 16px 12px;
    text-align: center;
    color: #94a3b8;
    font-size: 0.78rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

/* Dropdown Footer */
.re-bt-dropdown-footer {
    display: flex;
    gap: 8px;
    padding: 8px 12px;
    border-top: 1px solid #f1f5f9;
    background: #fafbff;
}

.re-bt-apply-btn {
    flex: 1;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #fff;
    border: none;
    border-radius: 7px;
    padding: 5px 10px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    transition: all 0.2s;
    box-shadow: 0 3px 8px rgba(239, 68, 68, 0.25);
}

.re-bt-apply-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 5px 12px rgba(239, 68, 68, 0.35);
}

.re-bt-reset-btn {
    background: #fff;
    color: #64748b;
    border: 1.5px solid #e2e8f0;
    border-radius: 7px;
    padding: 5px 10px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: all 0.2s;
}

.re-bt-reset-btn:hover {
    background: #f8fafc;
    border-color: #94a3b8;
    color: #334155;
}

/* Click-outside Overlay */
.re-bt-overlay {
    position: fixed;
    inset: 0;
    z-index: 199;
    background: transparent;
    cursor: default;
}

.re-delta-link {
    color: #4f46e5;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s;
    padding: 6px 10px;
    border-radius: 6px;
}

.re-delta-link:hover {
    color: #4338ca;
    background: #eef2ff;
}

.re-btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 14px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.25);
}

.re-btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.35);
}

/* Table Area */
.re-table-wrapper {
    flex-grow: 1;
    overflow-y: auto;
    max-height: 500px;
    padding-bottom: 80px;
}

.re-data-table {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    table-layout: auto;
}

.re-data-table th {
    padding: 10px 12px;
    font-size: 0.7rem;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: #f1f5f9;
    border-bottom: 2px solid #94a3b8;
    text-align: left;
    white-space: nowrap;
    position: sticky;
    top: 0;
    z-index: 2;
}

.re-data-table td {
    padding: 6px 12px;
    font-size: 0.8rem;
    color: #334155;
    font-weight: 600;
    border-bottom: 1px solid #b8c4d0;
    border-right: 1px solid #c8d2dc;
    vertical-align: middle;
    background: #fff;
}

.re-data-table td:last-child {
    border-right: none;
}

.re-col-center {
    text-align: center;
}

.re-edit-cell {
    padding: 6px 8px !important;
    background: #ffffff !important;
}

.re-t-input {
    width: 100%;
    height: 32px;
    border: 1.5px solid #94a3b8;
    border-radius: 6px;
    background: #f1f5f9;
    padding: 0 10px;
    outline: none;
    font-family: inherit;
    font-size: 0.9rem;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    color: var(--lc-secondary);
    font-weight: 700;
    box-sizing: border-box;
}

.re-t-input:focus {
    background: #ffffff;
    border-color: #4f46e5;
    box-shadow: 0 0 0 3.5px rgba(79, 70, 229, 0.15);
}

.re-bg-red {
    background-color: #fef2f2 !important;
    border-color: #fca5a5 !important;
    color: #dc2626 !important;
    font-weight: 700;
}

.re-bg-yellow {
    background-color: #fffbeb !important;
    border-color: #fde68a !important;
    color: #b45309 !important;
    font-weight: 700;
}

.re-bg-green {
    background-color: #f0fdf4 !important;
    border-color: #86efac !important;
    color: #166534 !important;
    font-weight: 700;
}

.re-input-calculated,
.re-input-calculated:disabled,
.re-input-calculated[readonly] {
    background-color: #f8fafc !important;
    color: #0f172a !important;
    border-color: #cbd5e1 !important;
    cursor: default !important;
    font-weight: 700;
    user-select: none;
}

/* ===============================================
   Result Search - Premium Modern Design
   =============================================== */

.re-header-main {
    display: flex;
    align-items: center;
    gap: 24px;
}

.re-patient-info {
    display: flex;
    align-items: center;
    gap: 16px;
}

.re-avatar {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    color: #fff;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1.2rem;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.re-patient-details {
    display: flex;
    flex-direction: column;
}

.re-patient-name {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--lc-secondary);
    margin: 0;
}

.re-patient-meta {
    font-size: 0.85rem;
    color: #64748b;
    margin: 0;
}

.re-header-actions {
    display: flex;
    gap: 12px;
}

.re-entry-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.re-select-minimal {
    border: none;
    background: transparent;
    font-weight: 700;
    color: #4f46e5;
    cursor: pointer;
    outline: none;
}

.re-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.re-card-header {
    padding: 12px 16px;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    background: #fafbff;
}

.re-card-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #334155;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.re-card-body {
    padding: 16px;
}

.re-grid-search {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
    align-items: flex-end;
}

.re-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.re-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.re-item-primary {
    font-weight: 600;
    color: #1e293b;
}

.re-item-secondary {
    font-size: 0.75rem;
    color: #64748b;
}

.re-dropdown-item {
    padding: 8px 12px;
    cursor: pointer;
    border-bottom: 1px solid #f1f5f9;
}

.re-dropdown-item:hover {
    background: #f8fafc;
}

.re-search-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    z-index: 100;
    max-height: 250px;
    overflow-y: auto;
}

.re-search-input-wrap {
    position: relative;
}

.re-content-layout {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.re-main-panel {
    flex: 1;
    min-width: 0;
}

.re-side-panel {
    width: 350px;
    flex-shrink: 0;
    position: sticky;
    top: 20px;
}

.re-table-container {
    width: 100%;
    overflow-x: auto;
}

.re-table {
    width: 100%;
    border-collapse: collapse;
    border-spacing: 0;
    table-layout: auto;
}

.re-table th {
    padding: 12px 16px;
    text-align: left;
    font-size: 0.75rem;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: #f8fafc;
    border-bottom: 2px solid #e2e8f0;
}

.re-table td {
    padding: 12px 16px;
    font-size: 0.85rem;
    color: #334155;
    border-bottom: 1px solid #f1f5f9;
    background: #fff;
}

.re-row-selected {
    background: #eff6ff !important;
}

.re-empty-state {
    padding: 48px;
    text-align: center;
    color: #94a3b8;
}

.re-empty-icon {
    font-size: 3rem;
    margin-bottom: 16px;
    opacity: 0.2;
}

.re-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 10px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
}

.re-badge-warning {
    background: #fef3c7;
    color: #b45309;
}

.re-badge-success {
    background: #dcfce7;
    color: #15803d;
}

.re-badge-info {
    background: #e0e7ff;
    color: #4338ca;
}

.re-pill-group {
    display: flex;
    gap: 4px;
    background: #f1f5f9;
    padding: 4px;
    border-radius: 8px;
    width: fit-content;
}

.re-pill {
    padding: 4px 16px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
}

.re-pill.active {
    background: #fff;
    color: #4f46e5;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.re-pill input {
    display: none;
}

.re-filter-row {
    display: flex;
    gap: 32px;
    align-items: center;
}

.re-btn-primary {
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.re-btn-secondary {
    background: #fff;
    color: #64748b;
    border: 1px solid #e2e8f0;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.re-input-calculated {
    background-color: #f0f9ff !important;
    border-color: #bae6fd !important;
    color: #0369a1 !important;
    font-weight: 700 !important;
    cursor: default;
}

/* Status Indicator Dots */
.re-status-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-left: 8px;
}

.re-status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #cbd5e1;
    /* Default/None */
    flex-shrink: 0;
}

.re-status-dot.normal {
    background-color: #22c55e;
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.4);
}

.re-status-dot.high {
    background-color: #ef4444;
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.4);
}

.re-status-dot.low {
    background-color: #f59e0b;
    box-shadow: 0 0 8px rgba(245, 158, 11, 0.4);
}

/* Table Footer */
.re-table-footer {
    display: flex;
    justify-content: space-between;
    padding: 12px 16px;
    border-top: 1px solid #f1f5f9;
    background: #fafbff;
}

.re-tf-left,
.re-tf-right {
    display: flex;
    gap: 12px;
    align-items: center;
}

.re-link-btn {
    background: none;
    border: none;
    color: #4f46e5;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.re-link-btn:hover {
    background: #eef2ff;
    color: #4338ca;
}

.re-text-danger {
    color: #ef4444;
}

.re-text-danger:hover {
    background: #fef2f2;
    color: #dc2626;
}

/* Right Panel Styles */
.re-rp-header {
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    padding: 10px 12px;
    font-weight: 700;
    font-size: 0.9rem;
    color: #1e293b;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.re-rp-header i {
    color: #4f46e5;
    font-size: 1rem;
}

.re-btn-close-popup {
    background: transparent;
    border: none;
    color: #64748b;
    cursor: pointer;
    border-radius: 4px;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.re-btn-close-popup:hover {
    background: #f1f5f9;
    color: #ef4444;
}

.re-btn-close-popup i {
    color: inherit;
    font-size: 1rem;
}

.re-rp-tabs {
    display: flex;
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
    padding: 0 8px;
}

.re-rp-tab {
    background: none;
    border: none;
    padding: 8px 12px;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    color: #64748b;
    border-bottom: 3px solid transparent;
    transition: all 0.2s;
    margin-bottom: -1px;
}

.re-rp-tab:hover {
    color: #4f46e5;
}

.re-rp-tab.active {
    color: #4f46e5;
    border-bottom-color: #4f46e5;
}

.re-rp-content {
    padding: 8px 12px;
    flex-grow: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.re-form-group {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.re-row-group {
    display: flex;
    align-items: center;
    gap: 6px;
}

.re-control {
    display: flex;
    align-items: center;
    gap: 6px;
}

.re-textarea {
    resize: vertical;
    min-height: 24px;
}

.re-flex-spacer {
    flex-grow: 1;
}

.re-rp-footer {
    display: flex;
    align-items: center;
    padding: 6px 12px;
    gap: 8px;
    border-top: 1px solid #f1f5f9;
    background: #fafbff;
}

.re-btn-update {
    background: #fff;
    color: #4f46e5;
    border: 1.5px solid #c7d2fe;
    border-radius: 6px;
    padding: 6px 16px;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.re-btn-update:hover {
    background: #eef2ff;
    border-color: #818cf8;
    transform: translateY(-1px);
}

/* Bottom Bar */
.re-footer-bar {
    position: fixed;
    bottom: 0;
    left: var(--sidebar-width, 240px);
    right: 0;
    background: transparent;
    padding: 12px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 100;
    flex-wrap: nowrap !important;
    gap: 6px;
}

.re-footer-centered {
    justify-content: center;
}

.re-footer-left {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.re-label-bold {
    font-weight: 700;
    color: #1e293b;
    font-size: 0.85rem;
}

.re-footer-divider {
    width: 1px;
    height: 20px;
    background: #cbd5e1;
    margin: 0 4px;
}

.re-footer-right {
    display: flex;
    gap: 12px;
}

.re-btn-action {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px 16px;
    font-size: 0.85rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    color: #334155;
    font-family: 'Inter', sans-serif;
}

.re-btn-action:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.re-btn-action-primary {
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    color: #fff;
    border: none;
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
}

.re-btn-action-primary:hover {
    background: linear-gradient(135deg, #4f46e5, #4338ca);
    color: #fff;
    border: none;
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.45);
}

/* Responsive Layout */
@media (max-width: 1200px) {
    .re-main-content {
        flex-direction: column;
    }

    .re-left-panel,
    .re-right-panel {
        width: 100%;
    }
}

@media (max-width: 768px) {

    .re-header-section,
    .re-sample-card {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }

    .re-header-right {
        justify-content: flex-start;
    }

    .re-container {
        padding: 16px 16px 120px;
    }

    .re-footer-bar {
        padding: 12px 16px;
    }
}

/* Fixed Values Modal - Premium Design */
.re-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.5);
    /* Sleek backdrop */
    z-index: 1000;
    backdrop-filter: blur(4px);
    animation: fadeInModal 0.2s ease-out;
}

@keyframes fadeInModal {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.re-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 480px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.15), 0 10px 10px -5px rgba(0, 0, 0, 0.08);
    z-index: 1001;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    font-family: inherit;
    border: 1px solid rgba(255, 255, 255, 0.5);
    /* Soft border for elegance */
    animation: scaleInModal 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes scaleInModal {
    from {
        transform: translate(-50%, -45%) scale(0.96);
        opacity: 0;
    }

    to {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
}

.re-modal-titlebar {
    background: #f8fafc;
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e2e8f0;
    font-size: 0.95rem;
    color: #1e293b;
    font-weight: 700;
    letter-spacing: 0.01em;
}

.re-modal-titlebar button {
    background: none;
    border: none;
    cursor: pointer;
    color: #94a3b8;
    font-size: 1.2rem;
    line-height: 1;
    transition: color 0.15s ease;
}

.re-modal-titlebar button:hover {
    color: #ef4444;
}

.re-modal-header {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 10px 16px;
    font-weight: 600;
    font-size: 0.85rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.re-modal-body {
    padding: 18px 16px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    background: #fdfdfd;
}

.re-modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    padding: 12px 16px;
    border-top: 1px solid #f1f5f9;
    background: #f8fafc;
}

/* Modal Buttons */
.re-btn-outline {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 6px 16px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.re-btn-outline:hover:not(:disabled) {
    background: #f8fafc;
    border-color: #94a3b8;
    color: #1e293b;
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.06);
}

.re-btn-outline:active:not(:disabled) {
    transform: translateY(0);
}

.re-btn-outline:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: #f1f5f9;
}

/* Destructive Button Exception */
.btn-delete:hover:not(:disabled) {
    border-color: #fca5a5 !important;
    color: #ef4444 !important;
    background: #fef2f2 !important;
}

/* Primary Button Exception */
.re-btn-save {
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 20px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 10px rgba(99, 102, 241, 0.3);
}

.re-btn-save:hover {
    background: linear-gradient(135deg, #4f46e5, #4338ca);
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(99, 102, 241, 0.4);
}

/* Print Button */
.re-btn-print {
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 18px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 10px rgba(14, 165, 233, 0.3);
    display: flex;
    align-items: center;
    gap: 6px;
}

.re-btn-print:hover {
    background: linear-gradient(135deg, #0284c7, #0369a1);
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(14, 165, 233, 0.4);
}

/* Improved Table styling inside Modal */
.re-fv-table-wrapper {
    height: 150px;
    overflow-y: auto;
    flex: 1;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.02);
}

.re-fv-table {
    border-collapse: collapse;
    width: 100%;
}

.re-fv-table th {
    background: #f8fafc !important;
    border-bottom: 2px solid #e2e8f0 !important;
    padding: 8px 12px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.7rem;
    color: #64748b;
    font-weight: 700;
    position: sticky;
    top: 0;
    z-index: 2;
}

.re-fv-table td {
    padding: 8px 12px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.85rem;
    color: #334155;
    transition: background-color 0.15s;
    font-weight: 500;
}

.re-fv-table tbody tr:hover:not(.active-row) td {
    background-color: #f8fafc;
}

.re-fv-table .active-row td {
    background: #eef2ff !important;
    color: #4f46e5 !important;
    border-bottom-color: #e0e7ff;
    font-weight: 600;
}

.re-fv-table .active-row i.fa-caret-right {
    color: #4f46e5;
}

.re-fv-table .active-row input.re-t-input {
    color: #4f46e5;
    font-weight: 600;
}

/* ===== SAVE TOAST NOTIFICATION ===== */
.re-save-toast {
    position: fixed;
    bottom: 72px;
    /* sit just above the footer bar */
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 22px;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 700;
    z-index: 500;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.14);
    animation: re-toast-in 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    white-space: nowrap;
}

.re-save-toast.success {
    background: #f0fdf4;
    color: #15803d;
    border: 1.5px solid #bbf7d0;
}

.re-save-toast.success i {
    color: #16a34a;
    font-size: 1rem;
}

.re-save-toast.error {
    background: #fef2f2;
    color: #b91c1c;
    border: 1.5px solid #fecaca;
}

.re-save-toast.error i {
    color: #dc2626;
    font-size: 1rem;
}

@keyframes re-toast-in {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(12px);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

/* ===== SAVE BUTTON SPINNER ===== */
.re-save-spinner {
    width: 14px;
    height: 14px;
    border: 2.5px solid rgba(255, 255, 255, 0.35);
    border-top-color: #fff;
    border-radius: 50%;
    animation: re-spin 0.65s linear infinite;
    flex-shrink: 0;
}

@keyframes re-spin {
    to {
        transform: rotate(360deg);
    }
}

/* ===== SAVING OVERLAY BANNER ===== */
.re-saving-overlay {
    position: fixed;
    bottom: 72px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 28px;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 700;
    color: #fff;
    background: linear-gradient(135deg, #4f46e5, #6366f1);
    box-shadow: 0 8px 28px rgba(79, 70, 229, 0.45);
    z-index: 600;
    white-space: nowrap;
    animation: re-toast-in 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    letter-spacing: 0.01em;
}

/* Save button pulsing glow while saving */
.re-btn-saving {
    animation: re-btn-pulse 1.2s ease-in-out infinite !important;
    pointer-events: none;
}

@keyframes re-btn-pulse {
    0% {
        box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
    }

    50% {
        box-shadow: 0 4px 24px rgba(79, 70, 229, 0.7);
    }

    100% {
        box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
    }
}

/* ===== DOT BUTTON (…) ===== */
.re-dot-btn {
    background: transparent;
    border: 1.5px solid #e2e8f0;
    border-radius: 6px;
    width: 28px;
    height: 22px;
    font-size: 0.9rem;
    line-height: 1;
    color: #64748b;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: all 0.18s ease;
    letter-spacing: 0.05em;
}

.re-dot-btn:hover {
    background: #eef2ff;
    border-color: #6366f1;
    color: #4f46e5;
    box-shadow: 0 2px 6px rgba(99, 102, 241, 0.18);
    transform: translateY(-1px);
}

/* ===== COMBINED ROW (Text + PrintResultOnly) ===== */
.re-row-combined td {
    background-color: transparent;
}

.re-combined-cell {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
}

.re-combined-label {
    font-size: 0.82rem;
    font-weight: 700;
    color: #1e293b;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.re-combined-result {
    flex: 1;
}

/* ===== ROW DETAIL POPUP ===== */
.re-row-detail-modal {
    width: 560px;
    max-width: 96vw;
    max-height: 85vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.re-row-detail-body {
    overflow-y: auto;
    padding: 16px !important;
    gap: 0 !important;
}

.re-rd-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px 16px;
}

.re-rd-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.re-rd-field-span {
    grid-column: 1 / -1;
}

.re-rd-field .re-input {
    width: 100%;
    box-sizing: border-box;
}

.re-rd-field input[readonly] {
    background: #f8fafc;
    color: #94a3b8;
    cursor: default;
}

/* Authorization Buttons */
.re-btn-action-primary {
    background: linear-gradient(135deg, #4f46e5, #4338ca);
    color: white;
    border-color: #4f46e5;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.25);
}

.re-btn-action-primary:hover:not(:disabled) {
    box-shadow: 0 6px 16px rgba(79, 70, 229, 0.35);
    background: linear-gradient(135deg, #4338ca, #3730a3);
}

.re-btn-action-info {
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
    color: white;
    border-color: #0ea5e9;
    box-shadow: 0 4px 12px rgba(14, 165, 233, 0.25);
}

.re-btn-action-info:hover:not(:disabled) {
    box-shadow: 0 6px 16px rgba(14, 165, 233, 0.35);
    background: linear-gradient(135deg, #0284c7, #0369a1);
}

.re-btn-action-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border-color: #10b981;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
}

.re-btn-action-success:hover:not(:disabled) {
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.35);
    background: linear-gradient(135deg, #059669, #047857);
}

.re-footer-names {
    background: #f1f5f9;
    padding: 8px 16px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    margin-right: 16px;
}

.re-footer-names div {
    min-width: 120px;
}

.re-footer-names small {
    font-size: 0.65rem;
    color: #94a3b8;
    text-transform: uppercase;
    font-weight: 700;
}

/* Detailed Normal Values Table */
.re-nv-table-container {
    max-height: 250px;
    overflow-y: auto;
}

.re-nv-row:hover {
    background-color: #f1f5f9;
}

.re-nv-row.active {
    background-color: #eef2ff;
}

.re-dual-input-container {
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    margin-top: 4px;
}

.re-focus-blue {
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1) !important;
}

.re-check-row-right {
    display: flex;
    justify-content: flex-end;
    margin-top: 4px;
}

.re-row-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.re-form-grid {
    display: grid;
    grid-template-columns: 110px 1fr;
    gap: 8px;
    align-items: center;
    margin-bottom: 8px;
}

.re-form-grid .re-label {
    margin-bottom: 0;
    font-weight: 500;
    color: #334155;
    font-size: 0.8rem;
}

.re-row-flex {
    display: flex;
    gap: 8px;
    align-items: center;
}

.re-panel-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px;
    border-top: 1px solid #e2e8f0;
    background: #f8fafc;
    border-radius: 0 0 12px 12px;
}

.re-grid-input {
    width: 100%;
    border: 1px solid transparent;
    background: transparent;
    padding: 4px;
    font-size: 0.8rem;
    text-align: center;
    color: #1e293b;
}

.re-grid-input:focus {
    border-color: #6366f1;
    background: #fff;
    outline: none;
    box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.1);
    border-radius: 4px;
}

.re-btn-add-nv {
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    color: #64748b;
    padding: 6px;
    width: 100%;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
}

.re-btn-add-nv:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
    color: #475569;
}

.re-btn-mini {
    height: 32px;
    width: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #cbd5e1;
    background: #fff;
    border-radius: 6px;
    cursor: pointer;
    color: #64748b;
    font-weight: 700;
}

.re-btn-mini:hover {
    background: #f1f5f9;
    border-color: #94a3b8;
}

.re-nv-header {
    background: #f8fafc;
    padding: 8px 12px;
    border: 1px solid #e2e8f0;
    border-bottom: none;
    border-radius: 8px 8px 0 0;
    font-size: 0.75rem;
    font-weight: 700;
    color: #475569;
    display: flex;
    align-items: center;
    gap: 8px;
}

.re-nv-mini-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85rem;
    border: 1px solid #e2e8f0;
    border-radius: 0 0 8px 8px;
    overflow: hidden;
    background: #fff;
}

.re-nv-mini-table th {
    background: #f1f5f9;
    padding: 8px;
    text-align: center;
    color: #64748b;
    font-weight: 600;
    border-bottom: 1px solid #e2e8f0;
}

.re-nv-mini-table td {
    padding: 8px;
    text-align: center;
    border-bottom: 1px solid #f1f5f9;
}

.re-btn-primary {
    background: #4f46e5;
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.re-btn-primary:hover {
    background: #4338ca;
}

/* GLOBAL INPUT FONT WEIGHT OVERRIDE */
input:not([type="checkbox"]):not([type="radio"]),
select,
textarea {
    font-weight: 700 !important;
}

input:not([type="checkbox"]):not([type="radio"])::placeholder,
textarea::placeholder {
    font-weight: 300 !important;
}

input:not([type="checkbox"]):not([type="radio"])::-webkit-input-placeholder,
textarea::-webkit-input-placeholder {
    font-weight: 300 !important;
}

input:not([type="checkbox"]):not([type="radio"])::-moz-placeholder,
textarea::-moz-placeholder {
    font-weight: 300 !important;
}

input:not([type="checkbox"]):not([type="radio"]):-ms-input-placeholder,
textarea:-ms-input-placeholder {
    font-weight: 300 !important;
}

select option {
    font-weight: 300 !important;
}

select.select-placeholder {
    font-weight: 300 !important;
    color: #94a3b8 !important;
}

select.select-placeholder option:not([value=""]):not([value="0"]) {
    font-weight: 300 !important;
    color: #1e293b !important;
}

/* ============================================================
   DNA LOADER SYSTEM
   ============================================================ */
.dna-loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(248, 250, 252, 0.45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
}

.dna-loader-card {
    background: transparent;
    padding: 0;
    border-radius: 0;
    box-shadow: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    border: none;
}

.dna-loader-inline {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 24px;
}

.dna-loader {
    display: flex;
    gap: 6px;
    align-items: center;
    justify-content: center;
    height: 48px;
}

.dna-strand {
    position: relative;
    width: 4px;
    height: 36px;
    background: rgba(79, 70, 229, 0.12);
    border-radius: 2px;
}

.dna-strand::before,
.dna-strand::after {
    content: '';
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    left: -2px;
    animation: dna-rotate 1.8s ease-in-out infinite;
}

.dna-strand::before {
    background: #4f46e5;
    animation-delay: calc(var(--i) * -0.15s);
}

.dna-strand::after {
    background: #818cf8;
    animation-delay: calc(var(--i) * -0.15s - 0.9s);
}

@keyframes dna-rotate {
    0%, 100% {
        top: 0%;
        transform: scale(1.2);
        z-index: 2;
    }
    50% {
        top: 80%;
        transform: scale(0.7);
        z-index: 1;
        opacity: 0.7;
    }
}

.dna-loader-text {
    font-size: 13px;
    font-weight: 800;
    color: #4f46e5;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* ============================================================
   GLOBAL VIEWPORT & MASTER LAYOUT SCROLLING LOCK & POLISH
   ============================================================ */
html,
body {
    width: 100% !important;
    max-width: 100vw !important;
    height: 100% !important;
    max-height: 100vh !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

html:has(.empty-layout-page),
body:has(.empty-layout-page),
html:has(.register-container),
body:has(.register-container),
html:has(.register-page),
body:has(.register-page) {
    height: auto !important;
    max-height: none !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
}

#lc-app-root {
    zoom: 0.85 !important;
    width: 117.6470588% !important;
    max-width: 117.6470588vw !important;
    height: 117.6470588vh !important;
    height: 117.6470588dvh !important;
    max-height: 117.6470588vh !important;
    max-height: 117.6470588dvh !important;
    min-height: 117.6470588vh !important;
    min-height: 117.6470588dvh !important;
    display: flex !important;
    overflow: hidden !important;
}

#main-content {
    flex: 1 !important;
    width: 100% !important;
    max-width: 100% !important;
    height: 100% !important;
    max-height: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    background-color: #f1f5f9 !important;
}

/* Fullscreen Billing View under zoom: 0.85 */
.vb-billing-modal-fullscreen {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 117.6470588% !important;
    min-width: 117.6470588vw !important;
    max-width: 117.6470588vw !important;
    height: 117.6470588% !important;
    min-height: 117.6470588vh !important;
    max-height: 117.6470588vh !important;
    z-index: 99999 !important;
    background: #f1f5f9 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

.vb-billing-modal-fullscreen .billing-page-wrapper {
    width: 100% !important;
    max-width: 100% !important;
    height: 100% !important;
    min-height: 100% !important;
    padding: 16px 24px !important;
    box-sizing: border-box !important;
    flex: 1 !important;
}

.workspace-tabs-bar {
    width: 100% !important;
    flex-shrink: 0 !important;
}

.referral-page {
    padding: 10px 14px 12px 14px !important;
    background-color: #f1f5f9 !important;
    width: 100% !important;
    height: 100% !important;
    max-height: 100% !important;
    min-height: 0 !important;
    min-width: 0 !important;
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
}

.lab-header-card {
    width: 100% !important;
    flex-shrink: 0 !important;
    padding: 10px 18px !important;
    border-radius: 12px 12px 0 0 !important;
    margin-bottom: 0 !important;
    border-bottom: 1px solid rgba(79, 70, 229, 0.12) !important;
}

.directory-section {
    width: 100% !important;
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    min-height: 0 !important;
    min-width: 0 !important;
    overflow: hidden !important;
    margin-top: 0 !important;
    border-top: none !important;
    border-radius: 0 0 12px 12px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04) !important;
}

.table-wrapper {
    width: 100% !important;
    flex: 1 !important;
    min-height: 0 !important;
    min-width: 0 !important;
    overflow-y: auto !important;
    overflow-x: auto !important;
    padding: 0 !important;
}

.directory-table {
    width: 100% !important;
    min-width: 100% !important;
    border-collapse: collapse !important;
}

.directory-table th {
    padding: 10px 14px !important;
    background-color: #f8fafc !important;
    font-size: 11.5px !important;
    letter-spacing: 0.03em !important;
    border-bottom: 1.5px solid #e2e8f0 !important;
}

.directory-table td {
    padding: 8px 14px !important;
    font-size: 13px !important;
}

.pagination-footer {
    width: 100% !important;
    flex-shrink: 0 !important;
    padding: 8px 18px !important;
    background-color: #ffffff !important;
    border-top: 1px solid #f1f5f9 !important;
}

.tm-elite-container {
    height: 100% !important;
    width: 100% !important;
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    min-height: 0 !important;
    overflow: hidden !important;
}

.tm-elite-container form {
    display: flex !important;
    flex-direction: column !important;
    flex: 1 !important;
    min-height: 0 !important;
    height: 100% !important;
    overflow: hidden !important;
}

.tm-elite-header {
    flex-shrink: 0 !important;
}

.tm-elite-content {
    flex: 1 !important;
    min-height: 0 !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    padding-bottom: 50px !important;
}

.tm-filter-select {
    min-width: 190px !important;
    padding: 0 32px 0 14px !important;
}

/* Form and Editor dropdowns pop downward */
.tm-elite-content .master-search-dropdown,
.tm-elite-card .master-search-dropdown,
.form-section .master-search-dropdown {
    top: 100% !important;
    bottom: auto !important;
    margin-top: 4px !important;
    margin-bottom: 0 !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18) !important;
    border-radius: 8px !important;
    border: 1px solid #cbd5e1 !important;
    background: #ffffff !important;
    max-height: 240px !important;
    z-index: 99999 !important;
}

/* ─── Normal Values Card Scrolling & Overflow ─── */
.tm-elite-red-card {
    background: white !important;
    border-radius: 16px !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05) !important;
    display: flex !important;
    flex-direction: column !important;
    flex: 1 !important;
    min-height: 0 !important;
    min-width: 0 !important;
    overflow-x: auto !important;
    overflow-y: auto !important;
}

.tm-elite-red-header {
    flex-shrink: 0 !important;
    min-width: 820px !important;
}

.normal-values-body {
    padding: 16px 20px !important;
    flex: 1 !important;
    display: flex !important;
    flex-direction: column !important;
    min-height: 0 !important;
    min-width: 820px !important;
    overflow-y: auto !important;
    overflow-x: auto !important;
    background: #ffffff !important;
}

.normal-values-body > div.pt-20,
.normal-values-body > div:last-child {
    padding-top: 12px !important;
    padding-bottom: 30px !important;
    flex: 1 !important;
    min-height: 0 !important;
    min-width: 0 !important;
    overflow-y: auto !important;
    overflow-x: auto !important;
}

.normal-values-body .display-flex.gap-24 {
    min-width: 780px !important;
}

.tm-elite-red-card::-webkit-scrollbar,
.normal-values-body::-webkit-scrollbar {
    height: 8px !important;
    width: 8px !important;
}

.tm-elite-red-card::-webkit-scrollbar-track,
.normal-values-body::-webkit-scrollbar-track {
    background: #f1f5f9 !important;
    border-radius: 4px !important;
}

.tm-elite-red-card::-webkit-scrollbar-thumb,
.normal-values-body::-webkit-scrollbar-thumb {
    background: #a5b4fc !important;
    border-radius: 4px !important;
}

.tm-elite-red-card::-webkit-scrollbar-thumb:hover,
.normal-values-body::-webkit-scrollbar-thumb:hover {
    background: #6366f1 !important;
}

.tm-age-table {
    min-width: 800px !important;
    width: 100% !important;
    border-collapse: collapse !important;
}

.tm-age-table th {
    background: #f8fafc !important;
    color: #475569 !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    padding: 8px 10px !important;
    border-bottom: 2px solid #e2e8f0 !important;
    white-space: nowrap !important;
}

.tm-age-table td {
    padding: 6px 8px !important;
    border-bottom: 1px solid #f1f5f9 !important;
    vertical-align: middle !important;
}

.tm-age-input {
    width: 100% !important;
    height: 32px !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 6px !important;
    padding: 0 8px !important;
    font-size: 12px !important;
    background: #fff !important;
    min-width: 60px !important;
    box-sizing: border-box !important;
}

select.tm-age-input {
    padding-right: 20px !important;
    min-width: 90px !important;
}

/* ─── Global Scrollbar Polish ─── */
.table-wrapper::-webkit-scrollbar,
#main-content::-webkit-scrollbar,
.referral-page::-webkit-scrollbar,
.tm-elite-content::-webkit-scrollbar {
    width: 8px !important;
    height: 8px !important;
}

.table-wrapper::-webkit-scrollbar-track,
#main-content::-webkit-scrollbar-track,
.referral-page::-webkit-scrollbar-track,
.tm-elite-content::-webkit-scrollbar-track {
    background: #f1f5f9 !important;
    border-radius: 4px !important;
}

.table-wrapper::-webkit-scrollbar-thumb,
#main-content::-webkit-scrollbar-thumb,
.referral-page::-webkit-scrollbar-thumb,
.tm-elite-content::-webkit-scrollbar-thumb {
    background: #cbd5e1 !important;
    border-radius: 4px !important;
}

.table-wrapper::-webkit-scrollbar-thumb:hover,
#main-content::-webkit-scrollbar-thumb:hover,
.referral-page::-webkit-scrollbar-thumb:hover,
.tm-elite-content::-webkit-scrollbar-thumb:hover,
.dch-page-container::-webkit-scrollbar-thumb:hover,
.billing-page-wrapper::-webkit-scrollbar-thumb:hover,
.rate-master-page::-webkit-scrollbar-thumb:hover,
.rs-container::-webkit-scrollbar-thumb:hover {
    background: #94a3b8 !important;
}

/* ─── Global Page Scrollability ─── */
.dch-page-container,
.billing-page-wrapper,
.referral-page,
.tm-elite-container,
.customer-logs-container,
.container-master-page,
.method-master-page,
.package-master-page,
.lab-setting-page,
.result-entry-container,
.result-search-container,
.re-page-container,
.rate-master-page,
.rs-container,
.lc-page-wrapper {
    width: 100% !important;
    max-width: 100% !important;
    flex: 1 !important;
    min-height: 100% !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
}

.rs-container .re-card {
    overflow-y: hidden !important;
    overflow-x: hidden !important;
    max-height: none !important;
    flex: 1 1 auto !important;
    height: 100% !important;
}

.rs-container .re-card-body {
    padding: 20px 24px !important;
    overflow-y: visible !important;
}
