@import '_content/Microsoft.AspNetCore.Components.QuickGrid/Microsoft.AspNetCore.Components.QuickGrid.boiwgh0w5b.bundle.scp.css';

/* /Components/Layout/MainLayout.razor.rz.scp.css */
.page[b-dq5417sx1h] {
    position: relative;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
}

main[b-dq5417sx1h] {
    flex: 1;
    min-width: 0;
    max-width: 100%;
    position: relative;
}

.sidebar[b-dq5417sx1h] {
    background-color: var(--bg-primary);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: sticky;
}

.sidebar-backdrop[b-dq5417sx1h] {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    backdrop-filter: blur(2px);
}

.mobile-sidebar[b-dq5417sx1h] {
    display: none !important;
}

.mobile-menu-btn[b-dq5417sx1h] {
    display: none !important;
}

.mobile-only-backdrop[b-dq5417sx1h] {
    display: none !important;
}

.sidebar-close-btn[b-dq5417sx1h] {
    display: none !important;
}

.mobile-only-logo[b-dq5417sx1h] {
    display: none !important;
}


@media (max-width: 640.98px) {
    /* Mobile: fixed topbar shell — only content scrolls */
    .page[b-dq5417sx1h] {
        height: 100vh;
        height: 100dvh;
        max-height: 100vh;
        max-height: 100dvh;
        overflow: hidden;
    }

    main[b-dq5417sx1h] {
        width: 100%;
        height: 100%;
        display: flex;
        flex-direction: column;
        overflow: hidden;
        min-height: 0;
    }

    main .top-row[b-dq5417sx1h] {
        flex-shrink: 0;
        position: sticky;
        top: 0;
        z-index: 1000;
        background: var(--bg-primary);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    }

    main .content[b-dq5417sx1h] {
        flex: 1;
        min-height: 0;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
    }

    .sidebar[b-dq5417sx1h] {
        position: fixed;
        top: 0;
        right: 0;
        left: auto;
        width: 280px;
        height: 100vh;
        z-index: 9999;
        transform: translateX(100%);
        transition: transform 0.3s ease;
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
        background: var(--bg-primary);
    }

    .sidebar.mobile-open[b-dq5417sx1h] {
        transform: translateX(0);
    }

    .sidebar-header[b-dq5417sx1h] {
        height: 60px;
        display: flex;
        align-items: center;
        justify-content: space-between;
        border-bottom: 1px solid var(--border-color);
        background: var(--bg-primary);
        flex-shrink: 0;
    }

    .sidebar-close-btn[b-dq5417sx1h] {
        display: flex !important;
        align-items: center;
        justify-content: center;
        background: var(--bg-tertiary);
        border: 1px solid var(--border-color);
        color: var(--text-primary);
        font-size: 1rem;
        cursor: pointer;
        width: 32px;
        height: 32px;
        margin-right: 0.3rem;
        border-radius: 8px;
        flex-shrink: 0;
        transition: background 0.2s, color 0.2s;
    }

    .sidebar-close-btn:hover[b-dq5417sx1h] {
        background: var(--border-color);
        color: var(--primary-color);
    }

    .sidebar-footer[b-dq5417sx1h] {
        display: none;
    }

    .topbar-left[b-dq5417sx1h] {
        display: none !important;
    }

    .desktop-only-logo[b-dq5417sx1h] {
        display: none !important;
    }

    .mobile-only-logo[b-dq5417sx1h] {
        display: inline !important;
    }

    .logo-full[b-dq5417sx1h] {
        font-weight: 800;
        font-size: 1.2rem;
        color: var(--primary-color);
        white-space: nowrap;
        letter-spacing: -0.5px;
        margin-left: 0.3rem;
    }

    .mobile-sidebar[b-dq5417sx1h] {
        display: flex !important;
        flex-direction: column;
    }

    .sidebar .sidebar-content[b-dq5417sx1h],
    .mobile-sidebar .sidebar-content[b-dq5417sx1h] {
        flex: 1;
        overflow-y: auto;
        overflow-x: hidden;
    }

    .mobile-only-backdrop[b-dq5417sx1h] {
        display: block !important;
        z-index: 9998;
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
    }

    .topbar-nav[b-dq5417sx1h] {
        display: none !important;
    }

    .mobile-menu-btn[b-dq5417sx1h] {
        display: flex !important;
        align-items: center;
        justify-content: center;
        background: var(--bg-tertiary);
        border: 1px solid var(--border-color);
        color: var(--text-primary);
        font-size: 1.3rem;
        cursor: pointer;
        width: 32px;
        height: 36px;
        border-radius: 8px;
        flex-shrink: 0;
        transition: background 0.2s, color 0.2s;
    }

    .top-row[b-dq5417sx1h],
    article[b-dq5417sx1h] {
        padding-left: 0rem !important;
        padding-right: 0rem !important;
    }

    .top-row .user-info[b-dq5417sx1h] {
        margin-left: 0 !important;
    }
}


.top-row[b-dq5417sx1h]  a,
.top-row[b-dq5417sx1h]  .btn-link {
    white-space: nowrap;
    margin-left: 1.5rem;
    text-decoration: none;
}

.top-row[b-dq5417sx1h]  a:hover,
.top-row[b-dq5417sx1h]  .btn-link:hover {
    text-decoration: underline;
}

.top-row[b-dq5417sx1h]  a:first-child {
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 640.98px) {
    main .top-row[b-dq5417sx1h] {
        justify-content: flex-end;
    }

    .top-row[b-dq5417sx1h]  a,
    .top-row[b-dq5417sx1h]  .btn-link {
        margin-left: 0;
    }
}

@media (min-width: 641px) {
    .page[b-dq5417sx1h] {
        flex-direction: row;
        height: 100vh;
        max-height: 100vh;
        overflow: hidden;
    }

    /* Fixed sidebar — only content area scrolls */
    .vertical-layout .sidebar[b-dq5417sx1h] {
        width: 250px;
        height: 100vh;
        position: fixed;
        left: 0;
        top: 0;
        transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        overflow-x: hidden;
        background-color: var(--bg-primary);
        border-right: 1px solid var(--border-color);
        display: flex;
        flex-direction: column;
        z-index: 1040;
    }

    .vertical-layout .sidebar.collapsed[b-dq5417sx1h] {
        width: 64px;
    }

    .vertical-layout main[b-dq5417sx1h] {
        margin-left: 250px;
        width: calc(100% - 250px);
        height: 100vh;
        display: flex;
        flex-direction: column;
        overflow: hidden;
        transition: margin-left 0.3s cubic-bezier(0.4, 0, 0.2, 1),
            width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .vertical-layout .sidebar.collapsed ~ main[b-dq5417sx1h] {
        margin-left: 64px;
        width: calc(100% - 64px);
    }

    .horizontal-layout main[b-dq5417sx1h] {
        width: 100%;
        height: 100vh;
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }

    main .content[b-dq5417sx1h] {
        flex: 1;
        min-height: 0;
        overflow-y: auto;
        overflow-x: hidden;
    }

    .sidebar-header[b-dq5417sx1h] {
        height: 60px;
        display: flex;
        align-items: center;
        padding: 0 1.5rem;
        margin: 0 0.1rem;
        border-bottom: 1px solid var(--border-color);
        background: var(--bg-primary);
        flex-shrink: 0;
        overflow: hidden;
    }

    .sidebar.collapsed .sidebar-header[b-dq5417sx1h] {
        padding: 0;
        margin-left: 0 !important;
        justify-content: center;
    }

    .logo-full[b-dq5417sx1h] {
        font-weight: 800;
        font-size: 1.2rem;
        color: var(--primary-color);
        white-space: nowrap;
        letter-spacing: -0.5px;
    }

    .logo-abbr[b-dq5417sx1h] {
        max-height: 36px;
        width: auto;
        object-fit: contain;
        display: block;
        transition: transform 0.2s ease;
        margin: 0 auto;
    }

    .logo-abbr:hover[b-dq5417sx1h] {
        transform: scale(1.08);
    }

    .sidebar-content[b-dq5417sx1h] {
        flex: 1;
        overflow-y: auto;
        overflow-x: hidden;
    }

    .sidebar-footer[b-dq5417sx1h] {
        padding: 1rem;
        border-top: 1px solid var(--border-color);
        background: var(--bg-secondary);
    }

    .collapse-toggle-btn[b-dq5417sx1h] {
        width: 100%;
        padding: 10px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: var(--bg-tertiary);
        border: 1px solid var(--border-color);
        border-radius: 8px;
        color: var(--primary-color);
        cursor: pointer;
        transition: all 0.2s;
        font-weight: 600;
        font-size: 0.875rem;
        white-space: nowrap;
    }

    .collapse-toggle-btn:hover[b-dq5417sx1h] {
        background: var(--border-color);
        transform: scale(1.02);
    }

    main .top-row[b-dq5417sx1h] {
        flex-shrink: 0;
        position: sticky;
        top: 0;
        z-index: 1000;
        display: flex;
        align-items: center;
        background: var(--bg-primary);
        overflow: visible !important;
    }

    .topbar-left[b-dq5417sx1h] {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .mobile-toggle-btn[b-dq5417sx1h] {
        background: none;
        border: none;
        color: var(--text-primary);
        font-size: 1.5rem;
        padding: 0;
        display: flex;
        align-items: center;
        cursor: pointer;
    }

    .main.full-width[b-dq5417sx1h] {
        padding-left: 0 !important;
    }

    .topbar-nav[b-dq5417sx1h] {
        flex: 1;
        display: flex;
        align-items: center;
        height: 100%;
        margin-right: 20px;
    }

    .horizontal-layout .top-row[b-dq5417sx1h]     {
        height: 3.5rem;
        padding-left: 1.5rem !important;
        border-bottom: 2px solid var(--primary-light);
    }

    .horizontal-layout .sidebar[b-dq5417sx1h] {
        display: none;
    }

    .app-title[b-dq5417sx1h] {
        font-weight: 700;
        font-size: 1.1rem;
        color: var(--primary-color);
        white-space: nowrap;
    }

    .top-row.auth[b-dq5417sx1h]  a:first-child {
        flex: 1;
        text-align: right;
        width: 0;
    }

    .top-row[b-dq5417sx1h],
    article[b-dq5417sx1h] {
        padding-left: 0rem !important;
        padding-right: 0rem !important;
    }

}

#blazor-error-ui[b-dq5417sx1h] {
    color-scheme: light only;
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    box-sizing: border-box;
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .dismiss[b-dq5417sx1h] {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

.layout-loading-fullscreen[b-dq5417sx1h] {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: var(--bg-primary, #020617);
    z-index: 9999;
}

/* Menu Search Styles */
.menu-search-container[b-dq5417sx1h] {
    position: relative;
    width: 180px;
    z-index: 1001;
    margin-right: 0;
    overflow: visible !important;
}

.search-input-wrapper[b-dq5417sx1h] {
    position: relative;
    display: flex;
    align-items: center;
}

.search-icon[b-dq5417sx1h] {
    position: absolute;
    left: 12px;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.menu-search-input[b-dq5417sx1h] {
    width: 180px;
    padding: 8px 12px 8px 36px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--text-primary);
    outline: none;
}

.menu-search-input:focus[b-dq5417sx1h] {
    border-color: var(--border-color);
    background: var(--bg-tertiary);
}

.search-results-dropdown[b-dq5417sx1h] {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    width: 280px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    max-height: 400px;
    overflow-y: auto;
    z-index: 2000;
    /* Extremely high to prevent clipping */
    padding: 8px;
    animation: slideDown-b-dq5417sx1h 0.2s ease;
}

.search-results-overlay[b-dq5417sx1h] {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1000;
}

.search-result-item[b-dq5417sx1h] {
    display: flex;
    align-items: center;
    padding: 10px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s ease;
    color: var(--text-primary);
    font-size: 0.9rem;
}

.search-result-item:hover[b-dq5417sx1h] {
    background: var(--bg-tertiary);
    color: var(--primary-color);
    padding-left: 16px;
}

.search-result-item i[b-dq5417sx1h] {
    width: 24px;
    font-size: 1.1rem;
}

@keyframes slideDown-b-dq5417sx1h {
    from {
        transform: translateY(-10px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@media (max-width: 768px) {
    .menu-search-container[b-dq5417sx1h] {
        display: block !important;
        position: absolute !important;
        left: 12px !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
        width: calc(100% - 150px) !important;
        max-width: 300px !important;
        margin: 0 !important;
        z-index: 1050 !important;
    }

    .menu-search-input[b-dq5417sx1h] {
        width: 100% !important;
        margin: 0 !important;
        font-size: 0.85rem;
        padding: 7px 10px 7px 32px !important;
    }

    .search-results-dropdown[b-dq5417sx1h] {
        width: 100%;
        left: 0;
        right: 0;
    }
}


/*.razor css*/

.user-profile-dropdown[b-dq5417sx1h] {
    position: relative;
    margin-left: 10px;
}

.user-info[b-dq5417sx1h] {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 4px 12px;
    border-radius: 12px;
    cursor: pointer;
    transition: background 0.2s;
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
}

.user-info:hover[b-dq5417sx1h] {
    background: var(--bg-tertiary);
}

.user-avatar[b-dq5417sx1h] {
    width: 32px;
    height: 32px;
    background: var(--primary-color);
    color: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
}

.user-details[b-dq5417sx1h] {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.user-name[b-dq5417sx1h] {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
}

.user-company[b-dq5417sx1h] {
    font-size: 0.7rem;
    color: var(--text-secondary);
}

@media (max-width: 576px) {
    .user-info[b-dq5417sx1h] {
        padding: 4px 8px;
        gap: 5px;
    }

    .user-avatar[b-dq5417sx1h] {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
}

.dropdown-backdrop[b-dq5417sx1h] {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: transparent;
    z-index: 999;
}

.dropdown-menu-custom[b-dq5417sx1h] {
    position: fixed;
    top: 65px;
    right: 1rem;
    width: 220px;
    background: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    z-index: 1050;
    overflow: hidden;
    animation: slideDown-b-dq5417sx1h 0.2s ease;
}

.dropdown-header-custom[b-dq5417sx1h] {
    padding: 12px 16px;
    background: var(--bg-secondary);
}

.dropdown-header-custom p[b-dq5417sx1h] {
    margin: 0 !important;
    font-size: 0.75rem !important;
    color: var(--text-secondary) !important;
}

.dropdown-header-custom strong[b-dq5417sx1h] {
    color: var(--text-primary) !important;
    display: block !important;
    margin-top: 2px !important;
    font-weight: 700 !important;
}

.dropdown-item-custom[b-dq5417sx1h] {
    width: 100% !important;
    padding: 12px 16px !important;
    display: flex !important;
    align-items: center !important;
    border: none !important;
    background: transparent !important;
    color: var(--text-primary) !important;
    font-size: 0.875rem !important;
    cursor: pointer !important;
    text-align: left !important;
    transition: background 0.2s !important;
    font-weight: 600 !important;
}

.dropdown-item-custom:hover[b-dq5417sx1h] {
    background: var(--bg-tertiary);
    color: var(--primary-color);
}

.dropdown-divider[b-dq5417sx1h] {
    height: 1px;
    background: var(--border-color);
    margin: 4px 0;
}

@keyframes slideDown-b-dq5417sx1h {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.top-row[b-dq5417sx1h] {
    background-color: var(--bg-primary) !important;
    border-bottom: 1px solid var(--border-color) !important;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 60px;
    padding-left: 1rem !important;
    padding-right: 1rem !important;
    z-index: 99 !important;
}

@media (max-width: 768px) {
    .top-row[b-dq5417sx1h] {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
        justify-content: flex-end;
    }

    .app-title[b-dq5417sx1h] {
        font-size: 1rem;
    }
}

.app-title[b-dq5417sx1h] {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary-color);
    letter-spacing: -0.5px;
}


.topbar-left[b-dq5417sx1h] {
    flex-shrink: 0;
    display: flex;
    align-items: center;
}

/* ====================== HORIZONTAL MENU SCROLL FIX ====================== */

.topbar-nav[b-dq5417sx1h] {
    flex: 1;
    min-width: 0;
    height: 100%;
    margin: 0 10px;
    overflow: visible;
    /* Changed to visible to not clip dropdown */
    max-width: calc(100% - 380px);
    /* Adjust according to your right side elements */
    position: relative;
    /* Key part! Allows dropdowns to escape the scrollable area below if static positioned */
}

.navmenu-container.horizontal[b-dq5417sx1h] {
    height: 100%;
    width: 100%;
}

.navmenu-container.horizontal .nav-scrollable[b-dq5417sx1h] {
    height: 100%;
    width: 100%;
    overflow-x: auto !important;
    overflow-y: visible !important;
    scrollbar-width: thin;
    scrollbar-color: #2563eb transparent;
    padding-bottom: 6px;
    -webkit-overflow-scrolling: touch;
}

/* Webkit Scrollbar */
.navmenu-container.horizontal .nav-scrollable[b-dq5417sx1h]::-webkit-scrollbar {
    height: 5px;
}

.navmenu-container.horizontal .nav-scrollable[b-dq5417sx1h]::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 10px;
}

.navmenu-container.horizontal .nav-scrollable[b-dq5417sx1h]::-webkit-scrollbar-thumb {
    background: var(--primary-color, #2563eb);
    border-radius: 10px;
}

.navmenu-container.horizontal .nav-scrollable[b-dq5417sx1h]::-webkit-scrollbar-thumb:hover {
    background: #1e40af;
}

/* Nav Items Container */
.navmenu-container.horizontal .nav[b-dq5417sx1h] {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center;
    gap: 6px;
    width: max-content !important;
    min-width: 100%;
    padding: 0 8px;
}

/* Individual items */
.navmenu-container.horizontal .nav-item[b-dq5417sx1h] {
    padding: 0 !important;
    margin: 0 2px;
    flex: 0 0 auto;
    white-space: nowrap;
}

.navmenu-container.horizontal .nav-link[b-dq5417sx1h] {
    height: 42px !important;
    padding: 0 9px !important;
    white-space: nowrap;
    display: flex;
    align-items: center;
}

.topbar-actions[b-dq5417sx1h] {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 5px;
    overflow: visible !important;
    /* Fix: Allow search dropdown to be seen */
}

@media (max-width: 576px) {
    .topbar-actions[b-dq5417sx1h] {
        flex: 1;
        display: flex;
        align-items: center;
        justify-content: flex-end;
        gap: 8px;
    }
}

.topbar-icon[b-dq5417sx1h] {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: var(--bg-tertiary);
    color: var(--text-primary);
    font-size: 1.1rem;
}

.topbar-icon:hover[b-dq5417sx1h] {
    background: var(--border-color);
    transform: scale(1.05);
    color: var(--primary-color);
}

.page[b-dq5417sx1h] {
    background-color: var(--bg-secondary) !important;
}

main[b-dq5417sx1h] {
    background-color: var(--bg-secondary) !important;
}

main .content[b-dq5417sx1h] {
    padding-top: 20px;
}

.layout-loading[b-dq5417sx1h] {
    display: flex;
    align-items: center;
    justify-content: center;
    height: calc(100vh - 60px);
    width: 100%;
    background: var(--bg-secondary);
}

.logo-full-img[b-dq5417sx1h] {
    max-height: 32px;
    width: auto;
    object-fit: contain;
    display: block;
}
/* /Components/Layout/NavMenu.razor.rz.scp.css */
.top-row[b-x6mkdwrqdg] {
    min-height: 3.5rem;
    background-color: rgba(0, 0, 0, 0.4);
}

.navbar-brand[b-x6mkdwrqdg] {
    font-size: 1.1rem;
}

.bi[b-x6mkdwrqdg] {
    display: inline-block;
    position: relative;
    width: 1.25rem;
    height: 1.25rem;
    margin-right: 0.75rem;
    top: -1px;
    background-size: cover;
}

.bi-house-door-fill-nav-menu[b-x6mkdwrqdg] {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%231e293b' class='bi bi-house-door-fill' viewBox='0 0 16 16'%3E%3Cpath d='M6.5 14.5v-3.505c0-.245.25-.495.5-.495h2c.25 0 .5.25.5.5v3.5a.5.5 0 0 0 .5.5h4a.5.5 0 0 0 .5-.5v-7a.5.5 0 0 0-.146-.354L13 5.793V2.5a.5.5 0 0 0-.5-.5h-1a.5.5 0 0 0-.5.5v1.293L8.354 1.146a.5.5 0 0 0-.708 0l-6 6A.5.5 0 0 0 1.5 7.5v7a.5.5 0 0 0 .5.5h4a.5.5 0 0 0 .5-.5Z'/%3E%3C/svg%3E");
}

.bi-plus-square-fill-nav-menu[b-x6mkdwrqdg] {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%231e293b' class='bi bi-plus-square-fill' viewBox='0 0 16 16'%3E%3Cpath d='M2 0a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V2a2 2 0 0 0-2-2H2zm6.5 4.5v3h3a.5.5 0 0 1 0 1h-3v3a.5.5 0 0 1-1 0v-3h-3a.5.5 0 0 1 0-1h3v-3a.5.5 0 0 1 1 0z'/%3E%3C/svg%3E");
}

.bi-list-nested-nav-menu[b-x6mkdwrqdg] {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%231e293b' class='bi bi-list-nested' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M4.5 11.5A.5.5 0 0 1 5 11h10a.5.5 0 0 1 0 1H5a.5.5 0 0 1-.5-.5zm-2-4A.5.5 0 0 1 3 7h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5zm-2-4A.5.5 0 0 1 1 3h10a.5.5 0 0 1 0 1H1a.5.5 0 0 1-.5-.5z'/%3E%3C/svg%3E");
}

.bi-gear-fill-nav-menu[b-x6mkdwrqdg] {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%231e293b' class='bi bi-gear-fill' viewBox='0 0 16 16'%3E%3Cpath d='M9.405 1.05c-.413-1.4-2.397-1.4-2.81 0l-.1.34a1.464 1.464 0 0 1-2.105.872l-.31-.17c-1.283-.698-2.686.705-1.987 1.987l.17.311c.586 1.066.077 2.399-.872 2.105l-.34-.1c-1.4.413-1.4 2.397 0 2.81l.34.1a1.464 1.464 0 0 1 .872 2.105l-.17.31c-.699 1.283.705 2.686 1.987 1.987l.311-.17a1.464 1.464 0 0 1 2.105.872l.1.34c.413 1.4 2.397 1.4 2.81 0l.1-.34a1.464 1.464 0 0 1 2.105-.872l.31.17c1.283.699 2.686-.705 1.987-1.987l-.17-.311a1.464 1.464 0 0 1 .872-2.105l.34.1c1.4-.413 1.4-2.397 0-2.81l-.34-.1a1.464 1.464 0 0 1-.872-2.105l.17-.31c.699-1.283-.705-2.686-1.987-1.987l-.311.17a1.464 1.464 0 0 1-2.105-.872l-.1-.34zM8 10.93a2.929 2.929 0 1 1 0-5.86 2.929 2.929 0 0 1 0 5.858z'/%3E%3C/svg%3E");
}

.nav-item[b-x6mkdwrqdg] {
    font-size: 0.9rem;
    padding-bottom: 0.5rem;
}

.nav-item:first-of-type[b-x6mkdwrqdg] {
    padding-top: 1rem;
}

.nav-item:last-of-type[b-x6mkdwrqdg] {
    padding-bottom: 1rem;
}

.nav-item[b-x6mkdwrqdg]  .nav-link {
    color: var(--text-primary);
    background: none;
    border: none;
    border-radius: 8px;
    min-height: 2.8rem;
    height: auto;
    display: flex;
    align-items: center;
    width: 100%;
    margin-bottom: 2px;
    transition: all 0.2s;
    font-weight: 500;
    padding-left: 1rem;
    padding-right: 0.5rem;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
    text-decoration: none !important;
}

.nav-item[b-x6mkdwrqdg]  a.active {
    background-color: rgba(var(--primary-rgb, 37, 99, 235), 0.1) !important;
    color: var(--primary-color) !important;
    font-weight: 600;
    box-shadow: none !important;
}

/* .nav-item ::deep a.active .bi inherits color from parent link */

.nav-item[b-x6mkdwrqdg]  .nav-link:hover:not(.active) {
    background-color: var(--bg-tertiary);
    color: var(--primary-color);
    text-decoration: none !important;
}

.nav-scrollable[b-x6mkdwrqdg] {
    display: block;
    height: 100%;
    overflow-y: auto;
}

/* Collapsed Sidebar Styles */
.navmenu-container.collapsed .bi[b-x6mkdwrqdg] {
    margin-right: 0 !important;
    font-size: 1.25rem;
}

/* Each icon row: fixed height, center icon both axes */
.navmenu-container.collapsed .nav-item[b-x6mkdwrqdg] {
    padding: 0 !important;
    margin: 0 !important;
    width: 100%;
    height: 52px;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

/* The icon link itself — 44×44 square, perfectly centered */
.navmenu-container.collapsed[b-x6mkdwrqdg]  .nav-link {
    color: var(--text-primary) !important;
    background: transparent;
    border: none !important;
    border-radius: 8px !important;
    height: 44px !important;
    width: 44px !important;
    min-width: 44px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 !important;
    transition: background 0.2s, color 0.2s;
    text-decoration: none !important;
}

/* Icon spans — no extra margin, perfectly centered inside the 44px box */
.navmenu-container.collapsed[b-x6mkdwrqdg]  .nav-link>span:first-child,
.navmenu-container.collapsed[b-x6mkdwrqdg]  .nav-link .bi,
.navmenu-container.collapsed[b-x6mkdwrqdg]  .nav-link [class*='bi-'] {
    margin: 0 !important;
    padding: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 1;
}

/* Active — same 44×44 box, theme background */
.navmenu-container.collapsed[b-x6mkdwrqdg]  .nav-link.parent-link.active,
.navmenu-container.collapsed[b-x6mkdwrqdg]  .nav-link.active {
    background-color: rgba(var(--primary-rgb, 37, 99, 235), 0.12) !important;
    color: var(--primary-color) !important;
}

/* Hover — IDENTICAL box to active */
.navmenu-container.collapsed[b-x6mkdwrqdg]  .nav-link:hover:not(.active) {
    background-color: rgba(var(--primary-rgb, 37, 99, 235), 0.08) !important;
    color: var(--primary-color) !important;
}

/* ── Collapsed Flyout Submenu ── */
.collapsed-flyout-wrapper[b-x6mkdwrqdg] {
    position: relative;
    display: flex;
    justify-content: center;
    width: 100%;
}

.collapsed-flyout[b-x6mkdwrqdg] {
    display: flex;
    position: fixed;
    left: 64px;
    /* Naturally aligns top with clicked parent menu item */
    max-height: 420px;
    /* sidebar width when collapsed */
    min-width: 250px;
    background: var(--bg-primary, #ffffff);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    z-index: 9999;
    padding: 6px;
    flex-direction: column;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    scrollbar-width: thin !important;
    -ms-overflow-style: auto !important;
}

.flyout-label[b-x6mkdwrqdg] {
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary-color);
    padding: 6px 12px 4px;
    border-bottom: 1px solid var(--border-color, #e2e8f0);
    margin-bottom: 4px;
}

/* ── Flyout child links ── */
.collapsed-flyout[b-x6mkdwrqdg]  .flyout-link {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    width: 100% !important;
    height: 2.4rem !important;
    padding: 10px 10px !important;
    margin: 1px !important;
    margin-bottom: 5px !important;
    border-radius: 8px !important;
    font-size: 0.875rem;
    color: var(--text-primary) !important;
    text-decoration: none !important;
    transition: background 0.15s ease, color 0.15s ease;
    white-space: nowrap !important;
    background: transparent !important;
    gap: 10px;
}

.collapsed-flyout[b-x6mkdwrqdg]  .flyout-link:hover {
    background-color: var(--bg-tertiary) !important;
    color: var(--primary-color) !important;
}

.collapsed-flyout[b-x6mkdwrqdg]  .flyout-link.active {
    background-color: rgba(var(--primary-rgb, 37, 99, 235), 0.1) !important;
    color: var(--primary-color) !important;
    font-weight: 600;
}

.collapsed-flyout[b-x6mkdwrqdg]  .flyout-link>span,
.collapsed-flyout[b-x6mkdwrqdg]  .flyout-link .bi,
.collapsed-flyout[b-x6mkdwrqdg]  .flyout-link [class*='bi-'] {
    font-size: 0.8rem !important;
    flex-shrink: 0;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.navmenu-container.collapsed .navbar-brand[b-x6mkdwrqdg] {
    display: flex;
    justify-content: center;
    width: 100%;
}

.navmenu-container.horizontal[b-x6mkdwrqdg] {
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;
    margin-top: 0.6%;
    margin-left: 0%;
}

.navmenu-container.horizontal .nav-scrollable[b-x6mkdwrqdg] {
    height: 100%;
    width: 100%;
    flex: 1;
    display: flex;
    align-items: center;
    overflow-x: auto;
    overflow-y: visible;
    /* Firefox — scrollbar completely hidden */
    scrollbar-width: none;
    /* IE/Edge legacy */
    -ms-overflow-style: none;
}

/* Chrome / Safari / Edge (Chromium) — scrollbar completely hidden */
.navmenu-container.horizontal .nav-scrollable[b-x6mkdwrqdg]::-webkit-scrollbar {
    height: 0 !important;
    width: 0 !important;
    background: transparent !important;
}

.navmenu-container.horizontal .nav[b-x6mkdwrqdg] {
    display: flex;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center;
    justify-content: center !important;
    /* JS override karega flex-start jab scroll ho */
    height: 100%;
    width: max-content;
    margin-left: auto !important;
    margin-right: auto !important;
    min-width: 100%;
    /* Important */
    padding: 0 8px;
}

.navmenu-container.horizontal .nav-item[b-x6mkdwrqdg] {
    padding: 0 !important;
    margin: 0 0px;
    flex: 0 0 auto;
}

.navmenu-container.horizontal[b-x6mkdwrqdg]  .nav-link,
.navmenu-container.horizontal .nav-link[b-x6mkdwrqdg] {
    justify-content: flex-start !important;
    height: 40px !important;
    white-space: nowrap;
    width: max-content !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

.navmenu-container.horizontal .bi[b-x6mkdwrqdg] {
    margin-right: 0px;
}

.parent-link[b-x6mkdwrqdg] {
    cursor: pointer;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 0px;
}

.parent-link .toggle-icon[b-x6mkdwrqdg] {
    transition: transform 0.25s ease;
    font-size: 0.75rem;
    flex-shrink: 0;
    /* Size fixed rahe */
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    /* Fixed width for stable rotation */
    height: 20px;
    margin-left: auto !important;
}

.parent-link.expanded .toggle-icon[b-x6mkdwrqdg] {
    transform: rotate(180deg);
}

.submenu[b-x6mkdwrqdg] {
    display: flex;
    flex-direction: column;
    margin-top: 0.2rem;
}

.submenu .nav-link[b-x6mkdwrqdg] {
    min-height: 2.2rem !important;
    height: auto !important;
    font-size: 0.85rem;
    opacity: 0.9;
    padding-top: 0.35rem !important;
    padding-bottom: 0.35rem !important;
    padding-right: 0.5rem !important;
    line-height: 1.3;
}

/* Horizontal specific submenu */
.navmenu-container.horizontal .has-children[b-x6mkdwrqdg] {
    position: static !important;
}

.navmenu-container.horizontal .submenu.dropdown-menu-custom[b-x6mkdwrqdg] {
    position: fixed;
    min-width: 240px;
    width: max-content !important;
    background: var(--bg-primary, #ffffff);
    border: 1px solid var(--border-color, #e2e8f0);
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    z-index: 9999;
    padding: 2px !important;
    display: flex;
    flex-direction: column;
    max-height: 40%;
    /* ~5 items ke baad scroll */
    overflow-y: auto !important;
    overflow-x: hidden !important;
    /* Firefox - Hide scrollbar */
    scrollbar-width: none;
    /* Edge/IE - Hide scrollbar */
    -ms-overflow-style: none;
    user-select: none;
    /* Text selection disable for dragging */
}

/* Hide focus outline since it's focused programmatically for keyboard support */
.navmenu-container.horizontal .submenu.dropdown-menu-custom:focus[b-x6mkdwrqdg] {
    outline: none;
}

/* Submenu Custom Scrollbar - Hidden completely as requested */
.navmenu-container.horizontal .submenu.dropdown-menu-custom[b-x6mkdwrqdg]::-webkit-scrollbar {
    width: 0px;
    display: none;
}

/* Inner items - perfectly fitting the parent padding */
.navmenu-container.horizontal .submenu.dropdown-menu-custom[b-x6mkdwrqdg]  .nav-link,
.navmenu-container.horizontal .submenu.dropdown-menu-custom[b-x6mkdwrqdg]  a {
    -webkit-user-drag: none;
    user-drag: none;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    color: var(--text-primary) !important;
    border-radius: 8px !important;
    margin: 2px 0 !important;
    /* No horizontal margin, rely on parent padding */
    width: auto !important;
    align-self: stretch !important;
    /* Fill parent's content box */
    box-sizing: border-box !important;
    padding: 10px 16px !important;
    min-height: 2.8rem !important;
    font-size: 0.875rem !important;
    font-weight: 500 !important;
    background: transparent !important;
    transition: background 0.15s ease, color 0.15s ease, padding 0.1s ease !important;
    white-space: nowrap;
    text-decoration: none !important;
}

/* Active & Hover states */
.navmenu-container.horizontal .submenu.dropdown-menu-custom[b-x6mkdwrqdg]  .nav-link.active,
.navmenu-container.horizontal .submenu.dropdown-menu-custom[b-x6mkdwrqdg]  a.active {
    background-color: rgba(var(--primary-rgb, 37, 99, 235), 0.1) !important;
    margin: 2px 0 !important;
    color: var(--primary-color) !important;
    box-shadow: none !important;
}

.navmenu-container.horizontal .submenu.dropdown-menu-custom[b-x6mkdwrqdg]  .nav-link:hover:not(.active),
.navmenu-container.horizontal .submenu.dropdown-menu-custom[b-x6mkdwrqdg]  a:hover:not(.active) {
    background-color: var(--bg-tertiary) !important;
    color: var(--primary-color) !important;
    margin: 2px 0 !important;
}

/* .dropdown-menu-custom ::deep a.active .bi inherits primary color from parent */

.dropdown-backdrop[b-x6mkdwrqdg] {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: transparent;
    z-index: 9998;
}

.nested-submenu-title[b-x6mkdwrqdg] {
    color: var(--text-secondary, #64748b) !important;
    font-weight: 700 !important;
    opacity: 0.8 !important;
}

/* ── Collapsed Flyout Styling Overrides ── */
.collapsed-flyout[b-x6mkdwrqdg]  .nav-link {
    width: 100% !important;
    height: auto !important;
    min-height: 2.2rem !important;
    min-width: unset !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    padding-left: 0.5rem !important;
    padding-right: 0.5rem !important;
    margin: 0 !important;
    font-size: 0.85rem !important;
    white-space: nowrap !important;
    opacity: 0.9 !important;
    background: transparent !important;
}

.collapsed-flyout[b-x6mkdwrqdg]  .nav-link:hover:not(.active) {
    background-color: var(--bg-tertiary) !important;
    color: var(--primary-color) !important;
}

.collapsed-flyout[b-x6mkdwrqdg]  .nav-link.active {
    background-color: rgba(var(--primary-rgb, 37, 99, 235), 0.1) !important;
    color: var(--primary-color) !important;
    font-weight: 600 !important;
}

.collapsed-flyout[b-x6mkdwrqdg]  .nav-link .bi,
.collapsed-flyout[b-x6mkdwrqdg]  .nav-link [class*='fa-'] {
    margin-right: 8px !important;
    font-size: 0.85rem !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.collapsed-flyout[b-x6mkdwrqdg]  .nav-text {
    display: inline !important;
    font-size: 0.85rem !important;
}

.collapsed-flyout[b-x6mkdwrqdg]  .toggle-icon {
    font-size: 0.65rem !important;
    margin-left: auto !important;
}

.collapsed-flyout[b-x6mkdwrqdg]::-webkit-scrollbar {
    width: 6px !important; 
    display: block !important;
}

/* ── Vertical Sidebar Spacing & Width Customizations ── */
.navmenu-container.vertical .nav-item[b-x6mkdwrqdg] {
    padding-left: 6px !important;
    padding-right: 6px !important;
}

.navmenu-container.vertical[b-x6mkdwrqdg]  .nav-link {
    padding-left: 1.25rem !important;
    padding-right: 1.25rem !important;
}
/* /Components/Layout/ReconnectModal.razor.rz.scp.css */
.components-reconnect-first-attempt-visible[b-jszmmrag17],
.components-reconnect-repeated-attempt-visible[b-jszmmrag17],
.components-reconnect-failed-visible[b-jszmmrag17],
.components-pause-visible[b-jszmmrag17],
.components-resume-failed-visible[b-jszmmrag17],
.components-rejoining-animation[b-jszmmrag17] {
    display: none;
}

#components-reconnect-modal.components-reconnect-show .components-reconnect-first-attempt-visible[b-jszmmrag17],
#components-reconnect-modal.components-reconnect-show .components-rejoining-animation[b-jszmmrag17],
#components-reconnect-modal.components-reconnect-paused .components-pause-visible[b-jszmmrag17],
#components-reconnect-modal.components-reconnect-resume-failed .components-resume-failed-visible[b-jszmmrag17],
#components-reconnect-modal.components-reconnect-retrying[b-jszmmrag17],
#components-reconnect-modal.components-reconnect-retrying .components-reconnect-repeated-attempt-visible[b-jszmmrag17],
#components-reconnect-modal.components-reconnect-retrying .components-rejoining-animation[b-jszmmrag17],
#components-reconnect-modal.components-reconnect-failed[b-jszmmrag17],
#components-reconnect-modal.components-reconnect-failed .components-reconnect-failed-visible[b-jszmmrag17] {
    display: block;
}


#components-reconnect-modal[b-jszmmrag17] {
    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-b-jszmmrag17 0.5s both;
    &[open]

{
    animation: components-reconnect-modal-slideUp-b-jszmmrag17 1.5s cubic-bezier(.05, .89, .25, 1.02) 0.3s, components-reconnect-modal-fadeInOpacity-b-jszmmrag17 0.5s ease-in-out 0.3s;
    animation-fill-mode: both;
}

}

#components-reconnect-modal[b-jszmmrag17]::backdrop {
    background-color: rgba(0, 0, 0, 0.4);
    animation: components-reconnect-modal-fadeInOpacity-b-jszmmrag17 0.5s ease-in-out;
    opacity: 1;
}

@keyframes components-reconnect-modal-slideUp-b-jszmmrag17 {
    0% {
        transform: translateY(30px) scale(0.95);
    }

    100% {
        transform: translateY(0);
    }
}

@keyframes components-reconnect-modal-fadeInOpacity-b-jszmmrag17 {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

@keyframes components-reconnect-modal-fadeOutOpacity-b-jszmmrag17 {
    0% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

.components-reconnect-container[b-jszmmrag17] {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

#components-reconnect-modal p[b-jszmmrag17] {
    margin: 0;
    text-align: center;
}

#components-reconnect-modal button[b-jszmmrag17] {
    border: 0;
    background-color: #6b9ed2;
    color: white;
    padding: 4px 24px;
    border-radius: 4px;
}

    #components-reconnect-modal button:hover[b-jszmmrag17] {
        background-color: #3b6ea2;
    }

    #components-reconnect-modal button:active[b-jszmmrag17] {
        background-color: #6b9ed2;
    }

.components-rejoining-animation[b-jszmmrag17] {
    position: relative;
    width: 80px;
    height: 80px;
}

    .components-rejoining-animation div[b-jszmmrag17] {
        position: absolute;
        border: 3px solid #0087ff;
        opacity: 1;
        border-radius: 50%;
        animation: components-rejoining-animation-b-jszmmrag17 1.5s cubic-bezier(0, 0.2, 0.8, 1) infinite;
    }

        .components-rejoining-animation div:nth-child(2)[b-jszmmrag17] {
            animation-delay: -0.5s;
        }

@keyframes components-rejoining-animation-b-jszmmrag17 {
    0% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 0;
    }

    4.9% {
        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;
    }
}
/* /Components/Pages/Devam/Trading/PurchaseSGBill.razor.rz.scp.css */
/* ========== Voucher Popup Styling (Matching Image) ========== */
.sgbill-popup-voucher[b-iaqmi9i901] {
    width: 90vw !important;
    max-width: 1400px !important;
    max-height: 95vh !important;
    /* Keep it within view always */
    border: 2px solid var(--primary-blue) !important;
    border-radius: 4px !important;
    padding: 0 !important;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    /* Ensure vertical layout for header/body/footer */
}

.voucher-popup-header[b-iaqmi9i901] {
    background: linear-gradient(to right, var(--primary-blue), #242488);
    color: white;
    padding: 8px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #1e1b4b;
}

.voucher-popup-title[b-iaqmi9i901] {
    font-weight: 700;
    font-size: 16px;
    letter-spacing: 0.5px;
}

.voucher-popup-close[b-iaqmi9i901] {
    cursor: pointer;
    font-size: 18px;
    opacity: 0.8;
}

.voucher-popup-close:hover[b-iaqmi9i901] {
    opacity: 1;
}

.voucher-popup-body[b-iaqmi9i901] {
    padding: 15px;
    background: #ffffff;
    flex: 1;
    /* Take all available space between header and footer */
    overflow-y: auto;
    /* Enable scroll if content is tall */
    min-height: 0;
    /* Flex overflow fix */
}

.voucher-entry-row[b-iaqmi9i901] {
    display: flex;
    flex-wrap: nowrap;
    gap: 3px;
    /* Minimal gap */
    align-items: flex-end;
    margin-bottom: 8px;
    padding: 4px 6px;
    /* Very tight padding */
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    overflow: hidden;
    /* Force hide any scrolling */
}

.voucher-field-group[b-iaqmi9i901] {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 0 0 auto;
}

/* Even smaller widths for ultra-compact fit */
.field-voucher[b-iaqmi9i901] {
    width: 110px;
}

.field-type[b-iaqmi9i901] {
    width: 150px;
}

.field-gross[b-iaqmi9i901] {
    width: 70px;
}

.field-purity[b-iaqmi9i901] {
    width: 60px;
}

.field-wast[b-iaqmi9i901] {
    width: 60px;
}

.field-wb[b-iaqmi9i901] {
    width: 120px;
}

.field-fine[b-iaqmi9i901] {
    width: 75px;
}

.field-rate[b-iaqmi9i901] {
    width: 85px;
}

.field-amount[b-iaqmi9i901] {
    width: 85px;
}

.field-remarks[b-iaqmi9i901] {
    flex: 1;
    min-width: 60px;
}

/* Ultra-shrinking textboxes and components */
.voucher-entry-row .e-input-group[b-iaqmi9i901],
.voucher-entry-row .e-input-group.e-control-wrapper[b-iaqmi9i901],
.voucher-entry-row .e-control-wrapper[b-iaqmi9i901] {
    height: 22px !important;
    min-height: 22px !important;
    min-width: 0 !important;
    /* Force respect parent */
}

.voucher-entry-row .e-input[b-iaqmi9i901] {
    font-size: 9px !important;
    padding: 0 3px !important;
    height: 20px !important;
}

.voucher-entry-row .e-ddl.e-input-group .e-input-group-icon[b-iaqmi9i901],
.voucher-entry-row .e-numeric.e-input-group .e-input-group-icon[b-iaqmi9i901] {
    min-height: 20px !important;
    font-size: 9px !important;
    width: 20px !important;
}

.voucher-field-group label[b-iaqmi9i901] {
    font-size: 13px;
    font-weight: 700;
    color: #334155;
    white-space: nowrap;
    margin-bottom: 5px;
    /* Increased from 3px to keep border/box far from label */
    line-height: 1.2;
}

.voucher-action-cell[b-iaqmi9i901] {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.voucher-entry-btn[b-iaqmi9i901] {
    background: var(--primary-blue) !important;
    color: white !important;
    border: none !important;
    height: 32px !important;
    width: 38px !important;
    border-radius: 4px !important;
}

.voucher-grid-container[b-iaqmi9i901] {
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    margin-bottom: 15px;
    max-height: 250px;
    /* Reduced height to keep UI compact */
    overflow-y: auto;
    /* Scroll only if content exceeds 250px */
}

.voucher-grid[b-iaqmi9i901] {
    border: none !important;
}

.voucher-grid .e-headercell[b-iaqmi9i901] {
    background: #f1f5f9 !important;
    color: #334155 !important;
    font-weight: 700 !important;
    text-transform: capitalize !important;
    border-bottom: 2px solid #cbd5e1 !important;
}

.voucher-footer[b-iaqmi9i901] {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    /* Changed from flex-start to align better at the bottom */
    margin-top: 15px;
    margin-bottom: 20px;
    gap: 15px;
}

.voucher-footer-left[b-iaqmi9i901] {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.total-gross-label[b-iaqmi9i901] {
    font-weight: 700;
    font-size: 13px;
    /* Reduced to 13px as requested */
    color: #475569;
    margin-bottom: 2px;
}

.total-boxes[b-iaqmi9i901] {
    display: flex;
    gap: 10px;
}

.total-box[b-iaqmi9i901] {
    width: 120px;
    height: 32px;
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0 8px;
    font-weight: 700;
    font-size: 13px;
    border-radius: 4px;
}

.voucher-footer-right[b-iaqmi9i901] {
    min-width: 320px;
    /* Reduced from 420px to ensure it fits "inside the form" */
    max-width: 400px;
    flex: 0 1 auto;
}

.summary-card[b-iaqmi9i901] {
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 15px 5px;
    /* Increased top/bottom, set horizontal for lines to manage edge spacing */
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
}

.summary-line[b-iaqmi9i901] {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 6px;
    /* Adjusted padding for 13px font */
    border-bottom: 1px dashed #e2e8f0;
    margin: 0 !important;
}

.summary-line:last-child[b-iaqmi9i901] {
    border-bottom: none;
}

.voucher-summary-label[b-iaqmi9i901] {
    font-weight: 700 !important;
    font-size: 13px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
    white-space: nowrap !important;
    color: inherit;
    margin: 0 !important;
    line-height: normal !important;
    padding-left: 15px;
    /* Indent label from border */
}

.summary-value[b-iaqmi9i901] {
    font-weight: 700 !important;
    font-size: 13px !important;
    text-align: right !important;
    margin: 0 !important;
    line-height: normal !important;
    padding-right: 15px;
    /* Indent value from border */
}

.voucher-save-section[b-iaqmi9i901] {
    padding: 10px 15px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    background: #f8fafc;
    flex-shrink: 0;
    /* Ensure it stays visible at the bottom */
}

.action-buttons-container[b-iaqmi9i901] {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.action-icon-btn[b-iaqmi9i901] {
    width: 28px !important;
    height: 28px !important;
    padding: 0 !important;
    border-radius: 6px !important;
    min-width: 28px !important;
}

.delete-btn:hover[b-iaqmi9i901] {
    background-color: #fee2e2 !important;
    color: #ef4444 !important;
}

.delete-icon-wrapper[b-iaqmi9i901] {
    background: #fef2f2;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

/* ========== Payment Section Redesign ========== */
.payment-section-layout[b-iaqmi9i901] {
    display: flex;
    gap: 0;
    border: 1px solid var(--slate-300);
    border-radius: 4px;
    background: #fff;
    min-height: 80px;
    max-height: 120px;
    overflow: hidden;
}

.payment-sidebar[b-iaqmi9i901] {
    display: flex;
    flex-direction: column;
    flex: 0 0 100px;
    /* Increased from 55px */
    border-right: 1px solid var(--slate-300);
    background: var(--primary-blue);
    height: auto;
}

.payment-sidebar-btn[b-iaqmi9i901],
.payment-sidebar-btn.e-btn[b-iaqmi9i901],
.payment-sidebar .e-btn[b-iaqmi9i901],
.payment-sidebar button.e-btn[b-iaqmi9i901],
.payment-sidebar .e-css.e-btn[b-iaqmi9i901] {
    flex: 1;
    width: 100% !important;
    border-radius: 0 !important;
    font-size: 10px !important;
    /* Increased from 8px */
    font-weight: 700 !important;
    text-transform: uppercase;
    border: none !important;
    box-shadow: none !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2) !important;
    background: var(--primary-blue) !important;
    background-color: var(--primary-blue) !important;
    color: #ffffff !important;
    padding: 4px 3px !important;
    white-space: normal !important;
    line-height: 1.1 !important;
    opacity: 1 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    visibility: visible !important;
    min-height: 35px !important;
}

.payment-sidebar-btn:last-child[b-iaqmi9i901],
.payment-sidebar .e-btn:last-child[b-iaqmi9i901] {
    border-bottom: none !important;
}

.payment-sidebar-btn:hover[b-iaqmi9i901],
.payment-sidebar .e-btn:hover[b-iaqmi9i901] {
    background: #312e81 !important;
    background-color: #312e81 !important;
    color: #ffffff !important;
}

.payment-main-content[b-iaqmi9i901] {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    border: none !important;
}

.payment-grid-container[b-iaqmi9i901] {
    flex: 1;
    overflow-y: auto;
    overflow-x: auto;
}

.btn-delete-row[b-iaqmi9i901] {
    background: none;
    border: none;
    color: #ef4444;
    cursor: pointer;
    padding: 0 4px;
    font-size: 1.2rem;
    line-height: 1;
    border-radius: 4px;
}

.btn-delete-row:hover[b-iaqmi9i901] {
    background-color: #fee2e2;
}

/* ========== CSS Variables ========== */
:root[b-iaqmi9i901] {
    --primary-brand: var(--primary-blue);
    --accent-glow: var(--primary-blue);
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-300: #cbd5e1;
    --slate-400: #94a3b8;
    --slate-500: #64748b;
    --slate-600: #475569;
    --slate-700: #334155;
    --shadow-soft: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
    --border-radius-md: 8px;
    --silver-btn: var(--primary-blue);
    --gold-btn: var(--primary-blue);
}

/* ========== Base Layout ========== */
.page-container[b-iaqmi9i901] {
    max-width: 100%;
    height: auto !important;
    min-height: min-content !important;
    overflow: visible !important;
    font-family: 'Inter', system-ui, -apple-system, sans-serif !important;
    animation: fadeIn-b-iaqmi9i901 0.2s ease-in;
}

@keyframes fadeIn-b-iaqmi9i901 {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.full-width-content[b-iaqmi9i901] {
    padding: 6px 15px !important;
    background: #ffffff;
    height: auto !important;
    overflow: visible !important;
}

/*.sgbill-layout {
    display: flex;
    flex-direction: column;
    gap: 8px;*/
    /* Increased gap for better spacing */
    /*max-width: 100%;
    height: auto !important;
    min-height: 0 !important;
    padding-bottom: 120px !important;*/
    /* Force extra space at bottom for footer visibility */
    /*overflow: visible !important;
}*/

.sgbill-layout[b-iaqmi9i901] {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    padding-left: 0 !important;
    margin-left: 0 !important;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

.main-form-section[b-iaqmi9i901] {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-left: 0 !important;
    margin-left: 0 !important;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

/* Removed fixed desktop height to prevent grid being pushed off by expanded headers */

/* ========== Card Components ========== */
.premium-card[b-iaqmi9i901] {
    background: #ffffff;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--slate-100);
    overflow: visible;
    max-width: 100%;
    contain: layout style;
    flex-shrink: 0;
}

.premium-card:last-child[b-iaqmi9i901] {
    border-bottom: none;
}

.card-body-premium[b-iaqmi9i901] {
    padding: 8px 12px;
}

.header-card .card-body-premium[b-iaqmi9i901] {
    padding: 6px 12px;
}

.footer-card .card-body-premium[b-iaqmi9i901] {
    padding: 4px 10px;
    padding-right: 0 !important;
}

/* ========== Header Section ========== */
.header-main-container[b-iaqmi9i901] {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
}

.header-left-col[b-iaqmi9i901] {
    flex: 1 1 500px;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.header-right-col[b-iaqmi9i901] {
    flex: 0 1 500px;
    min-width: 300px;
}

.header-row[b-iaqmi9i901] {
    display: flex;
    gap: 8px;
    align-items: center;
}

.header-field[b-iaqmi9i901] {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.w-60[b-iaqmi9i901] {
    flex: 0 0 60px;
}

.w-150[b-iaqmi9i901] {
    flex: 0 0 150px;
}

.w-168[b-iaqmi9i901] {
    flex: 0 0 168px;
}

.w-225[b-iaqmi9i901] {
    flex: 0 0 225px;
}

.w-240[b-iaqmi9i901] {
    flex: 0 0 240px;
}

.flex-row-gap[b-iaqmi9i901] {
    display: flex;
    flex-direction: row;
    gap: 6px;
}


.history-grid-wrapper[b-iaqmi9i901] {
    background: var(--slate-50);
    border: none !important;
    box-shadow: none !important;
    border-radius: 6px;
    overflow: auto;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.history-table[b-iaqmi9i901] {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
    table-layout: fixed;
    border: none !important;
}

.history-table thead th[b-iaqmi9i901] {
    background: var(--slate-100);
    padding: 5px 6px;
    font-weight: 600;
    font-size: 10px;
    text-align: left;
    border: none !important;
    white-space: nowrap;
    position: sticky;
    top: 0;
    z-index: 1;
    color: var(--slate-600);
}

.history-table tbody tr[b-iaqmi9i901] {
    color: var(--slate-700);
}

.history-table tbody td[b-iaqmi9i901] {
    padding: 4px 6px;
    border: none !important;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.history-table tbody tr:hover[b-iaqmi9i901] {
    background: var(--slate-100);
}

.history-table th:nth-child(1)[b-iaqmi9i901],
.history-table td:nth-child(1)[b-iaqmi9i901] {
    width: 15%;
}

.history-table th:nth-child(2)[b-iaqmi9i901],
.history-table td:nth-child(2)[b-iaqmi9i901] {
    width: 18%;
}

.history-table th:nth-child(3)[b-iaqmi9i901],
.history-table td:nth-child(3)[b-iaqmi9i901] {
    width: 18%;
}

.history-table th:nth-child(4)[b-iaqmi9i901],
.history-table td:nth-child(4)[b-iaqmi9i901] {
    width: 18%;
}

.history-table th:nth-child(5)[b-iaqmi9i901],
.history-table td:nth-child(5)[b-iaqmi9i901] {
    width: 31%;
}

/* ========== Table Section ========== */
.table-card .card-body-premium[b-iaqmi9i901] {
    padding: 0;
}

.table-scroll-wrapper[b-iaqmi9i901] {
    overflow: auto;
    flex: 0 1 auto;
    min-height: 100px;
    max-width: 100%;
    border: 1px solid var(--slate-200);
    content-visibility: auto;
}

.table-card[b-iaqmi9i901] {
    flex: 0 1 auto !important;
    /* Shrink to content */
    min-height: 0 !important;
    overflow: hidden !important;
    display: flex;
    flex-direction: column;
}

.table-card .card-body-premium[b-iaqmi9i901] {
    flex: 0 1 auto;
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.table-scroll-wrapper[b-iaqmi9i901] {
    width: 100%;
    overflow: auto;
    position: relative;
}

.main-item-grid-wrapper[b-iaqmi9i901] {
    max-height: 155px !important;
    /* header + ~3 rows forced */
    min-height: 0 !important;
    overflow-y: auto !important;
}

.footer-card[b-iaqmi9i901] {
    flex-shrink: 0 !important;
}

.summary-section-wrapper[b-iaqmi9i901] {
    max-width: 100%;
    background: #ffffff;
    border-bottom: 1px solid var(--slate-200);
    margin: 5px 15px;
}

.summary-row-fields[b-iaqmi9i901] {
    padding: 4px 8px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sgbill-table[b-iaqmi9i901] {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
    min-width: 1700px;
    background: #ffffff;
    table-layout: fixed;
}

.sgbill-table thead th[b-iaqmi9i901] {
    background: var(--slate-50);
    padding: 6px 4px;
    font-weight: 600;
    font-size: 10px;
    text-align: center;
    border: 1px solid var(--slate-300);
    white-space: nowrap;
    position: sticky;
    top: 0;
    z-index: 10;
    color: var(--slate-600);
}

.sgbill-table tbody td[b-iaqmi9i901] {
    padding: 8px 2px 2px 2px;
    border: 1px solid var(--slate-200);
    vertical-align: top;
    background: #ffffff;
}

/* Row colors matching legacy grdDetails_CellFormatting */
/* Pink/Red for Sale items: rgb(255,192,192) */
.sgbill-table tbody tr.row-pink[b-iaqmi9i901],
.sgbill-table tbody tr.row-pink td[b-iaqmi9i901] {
    background-color: rgb(255, 192, 192) !important;
}

/* Green for Return items: rgb(192,255,192) */
.sgbill-table tbody tr.row-green[b-iaqmi9i901],
.sgbill-table tbody tr.row-green td[b-iaqmi9i901] {
    background-color: rgb(192, 255, 192) !important;
}

/* Main Grid Header - Neutral theme */
.main-grid-pink thead th[b-iaqmi9i901] {
    background: #f1f5f9 !important;
    color: #475569 !important;
    border-color: #cbd5e1 !important;
}

/* Payment Grid - Neutral theme */
.payment-grid-green[b-iaqmi9i901] {
    background-color: #ffffff !important;
}

.payment-grid-green thead th[b-iaqmi9i901] {
    background: #f1f5f9 !important;
    color: #475569 !important;
    border-color: #cbd5e1 !important;
}

.payment-grid-green tbody tr[b-iaqmi9i901] {
    background-color: #ffffff !important;
}

/* Row-highlighted takes priority over sale/return colors (validation errors) */
.sgbill-table tbody tr.row-highlighted[b-iaqmi9i901],
.sgbill-table tbody tr.row-highlighted td[b-iaqmi9i901],
.sgbill-table tbody tr.row-highlighted.row-sale[b-iaqmi9i901],
.sgbill-table tbody tr.row-highlighted.row-sale td[b-iaqmi9i901],
.sgbill-table tbody tr.row-highlighted.row-return[b-iaqmi9i901],
.sgbill-table tbody tr.row-highlighted.row-return td[b-iaqmi9i901] {
    background-color: #ff6b6b !important;
}

.sgbill-popup-actions .e-outline:hover[b-iaqmi9i901] {
    background-color: transparent !important;
    color: inherit !important;
}

.sgbill-popup-section-title[b-iaqmi9i901] {
    font-size: 11px;
    font-weight: 700;
    color: var(--slate-600);
    margin: 12px 0 8px 0;
    padding-bottom: 4px;
    border-bottom: 1px dashed #e2e8f0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.sgbill-popup-grid-row[b-iaqmi9i901] {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 10px;
}

.sgbill-popup-opening-row[b-iaqmi9i901] {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    align-items: end;
}

.sgbill-popup-opening-field-group[b-iaqmi9i901] {
    display: flex;
    align-items: center;
    gap: 0;
    border: 1px solid var(--slate-200);
    border-radius: 4px;
    overflow: hidden;
}

.sgbill-popup-opening-field-group .e-numeric[b-iaqmi9i901],
.sgbill-popup-opening-field-group .e-ddl[b-iaqmi9i901] {
    border: none !important;
}

.sgbill-popup-opening-field-group .e-numeric[b-iaqmi9i901] {
    flex: 1;
}

.sgbill-popup-opening-field-group .e-ddl[b-iaqmi9i901] {
    width: 100px;
    background: #f8fafc;
    border-left: 1px solid var(--slate-200) !important;
}

.sgbill-popup-opening-date-row[b-iaqmi9i901] {
    display: grid;
    grid-template-columns: 1fr 1fr 1.5fr;
    gap: 12px;
    margin-top: 8px;
}

.table-input[b-iaqmi9i901] {
    width: 100%;
    font-size: 11px;
}

.calculation-group .e-numerictextbox.e-small .e-input[b-iaqmi9i901] {
    padding: 0 6px !important;
    font-size: 11px !important;
}

.table-input .e-input-group[b-iaqmi9i901],
.table-input.e-input-group[b-iaqmi9i901] {
    min-height: 28px !important;
    max-height: 28px !important;
    border: none;
    background: transparent;
}

.table-input .e-input[b-iaqmi9i901],
.table-input.e-input[b-iaqmi9i901] {
    font-size: 11px;
    height: 26px !important;
    line-height: 26px !important;
    padding: 1px 7px;
    background: transparent;
    border: none;
    transition: background-color 0.15s ease;
}

.table-input .e-input:focus[b-iaqmi9i901] {
    background: #f0f9ff;
}

/* ========== Summary Section ========== */
.summary-label-cell[b-iaqmi9i901] {
    width: 50px;
    text-align: center;
    font-weight: 700;
    font-size: 14px;
    vertical-align: middle !important;
}

.label-s[b-iaqmi9i901] {
    color: #fff;
}

.label-r[b-iaqmi9i901] {
    color: #fff;
}

/* ========== Footer Section ========== */
.footer-layout[b-iaqmi9i901] {
    display: flex;
    gap: 32px;
    /* Increased gap for better separation */
    flex-wrap: nowrap;
    align-items: stretch;
    margin-top: 2px;
}

.footer-left-pack[b-iaqmi9i901] {
    flex: 1 1 70%;
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.footer-right-pack[b-iaqmi9i901] {
    flex: 0 0 200px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 4px;
    background: var(--slate-50);
    border-left: 1px solid var(--slate-200);
}

.compact-footer-row[b-iaqmi9i901] {
    display: flex;
    gap: 6px;
    align-items: stretch;
}

.remarks-group[b-iaqmi9i901] {
    flex: 0 0 300px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.calculation-group[b-iaqmi9i901] {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    align-content: start;
}

.calc-row[b-iaqmi9i901] {
    display: contents;
}

.footer-col[b-iaqmi9i901] {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.payment-sidebar[b-iaqmi9i901] {
    display: flex;
    flex-direction: column;
    flex: 0 0 65px;
    border-right: 1px solid var(--slate-300);
    background: #f8fafc;
    /* Neutral Sidebar as requested */
    height: 100px;
}

.footer-table-container[b-iaqmi9i901] {
    max-height: 400px;
    height: 180px;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
    border: none !important;
    box-shadow: none !important;
}

.compact-footer-table[b-iaqmi9i901] {
    min-width: 800px !important;
    margin-bottom: 0 !important;
}

.compact-footer-table thead th[b-iaqmi9i901] {
    background: var(--slate-100) !important;
    font-size: 10px !important;
    padding: 4px !important;
    border: 1px solid var(--slate-200) !important;
    color: var(--slate-700) !important;
}

.compact-footer-table tbody td[b-iaqmi9i901] {
    padding: 3px 5px !important;
    font-size: 10px !important;
    height: 22px !important;
    border: 1px solid var(--slate-100) !important;
}

.compact-footer-table .text-right[b-iaqmi9i901] {
    text-align: right !important;
}

.payment-tabs.e-tab[b-iaqmi9i901] {
    border: none !important;
}

.payment-tabs .e-tab-header[b-iaqmi9i901] {
    height: 30px !important;
    background: var(--slate-100) !important;
    border-bottom: 1px solid var(--slate-200) !important;
}

.payment-tabs .e-tab-header .e-toolbar-item .e-tab-text[b-iaqmi9i901] {
    font-size: 11px !important;
    font-weight: 600 !important;
}

.footer-grid-2[b-iaqmi9i901] {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

/* Summary Inputs */
.summary-item[b-iaqmi9i901] {
    width: 80px;
    flex: 0 0 auto;
}

.summary-input[b-iaqmi9i901] {
    width: 100%;
    height: 24px;
    font-size: 11px;
    text-align: right;
    border: 1px solid #cbd5e1;
    border-radius: 2px;
    padding: 2px 4px;
    background: #fff;
    color: #1e293b;
    font-weight: 600;
}

.summary-input:read-only[b-iaqmi9i901] {
    background: #f8fafc;
}

.summary-input:focus[b-iaqmi9i901] {
    outline: 1px solid #3b82f6;
    border-color: #3b82f6;
}



.final-summary[b-iaqmi9i901] {
    padding: 4px 8px;
    background: var(--slate-50);
    border: 1px solid var(--slate-200);
    border-radius: var(--border-radius-md);
    margin-top: 4px;
}

.final-summary.no-margin[b-iaqmi9i901] {
    margin-top: 0 !important;
    border: none !important;
    background: transparent !important;
    padding: 0 !important;
}

.summary-item[b-iaqmi9i901] {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.summary-label[b-iaqmi9i901] {
    font-size: 10px;
    font-weight: 600;
    color: var(--slate-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.summary-value[b-iaqmi9i901] {
    font-weight: 700;
    font-size: 14px;
    color: var(--primary-brand);
}

.footer-actions-row[b-iaqmi9i901] {
    margin-top: auto;
    padding: 8px 16px;
    /*border-top: 2px solid var(--slate-100);*/
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    /*background: #f8fafc;*/
    flex-wrap: nowrap;
    position: sticky;
    bottom: 0;
    z-index: 1000;
    /*box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--slate-200);*/
}

.footer-actions-left[b-iaqmi9i901],
.footer-actions-right[b-iaqmi9i901] {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* ========== Input Styles ========== */
.e-numerictextbox input[b-iaqmi9i901],
.e-numeric input[b-iaqmi9i901] {
    text-align: right !important;
}

.e-input-group:not(.e-success):not(.e-error)[b-iaqmi9i901],
.e-input-group.e-control-wrapper:not(.e-success):not(.e-error)[b-iaqmi9i901] {
    border-color: var(--slate-300);
}

.e-input-group:not(.e-success):not(.e-error):hover[b-iaqmi9i901],
.e-input-group.e-control-wrapper:not(.e-success):not(.e-error):hover[b-iaqmi9i901],
.e-input-group.e-input-focus:not(.e-success):not(.e-error)[b-iaqmi9i901],
.e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-error)[b-iaqmi9i901] {
    border-color: var(--accent-glow);
}

.e-input-group.e-input-focus[b-iaqmi9i901],
.e-input-group.e-control-wrapper.e-input-focus[b-iaqmi9i901] {
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.1);
}




*[b-iaqmi9i901] {
    touch-action: manipulation;
}

*:focus-visible[b-iaqmi9i901] {
    outline: 2px solid var(--accent-glow);
    outline-offset: 2px;
}

/* ========== Responsive Design ========== */
@media (max-width: 1200px) {
    .header-main-container[b-iaqmi9i901] {
        flex-direction: column;
        gap: 20px;
    }

    .header-left-col[b-iaqmi9i901],
    .header-right-col[b-iaqmi9i901] {
        max-width: 100%;
        width: 100%;
    }
}

@media (max-width: 1024px) {
    .footer-layout[b-iaqmi9i901] {
        flex-direction: column;
        gap: 20px;
    }

    .footer-right-side[b-iaqmi9i901] {
        width: 100%;
    }
}

@media (max-width: 767px) {
    .full-width-content[b-iaqmi9i901] {
        padding: 10px !important;
    }

    .header-row[b-iaqmi9i901] {
        flex-wrap: wrap;
        gap: 8px;
    }

    .header-field[b-iaqmi9i901] {
        flex: 1 1 calc(50% - 8px) !important;
        min-width: 120px;
    }

    .w-60[b-iaqmi9i901],
    .w-150[b-iaqmi9i901],
    .w-168[b-iaqmi9i901],
    .w-240[b-iaqmi9i901] {
        flex: 1 1 auto !important;
        width: auto !important;
    }

    .footer-right-side .row[b-iaqmi9i901] {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .footer-right-side .row .col[b-iaqmi9i901] {
        width: 100% !important;
        flex: 0 0 100% !important;
        padding: 0 !important;
    }

    .footer-grid-2[b-iaqmi9i901],
    .footer-grid-3[b-iaqmi9i901] {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .footer-actions-row[b-iaqmi9i901] {
        flex-direction: row;
        flex-wrap: nowrap;
    }

    .footer-actions-left[b-iaqmi9i901],
    .footer-actions-right[b-iaqmi9i901] {
        justify-content: center;
        width: 100%;
    }

    .footer-actions-left .e-btn[b-iaqmi9i901],
    .footer-actions-right .e-btn[b-iaqmi9i901] {
        flex: 1;
    }
}

@media (max-width: 480px) {
    .header-field[b-iaqmi9i901] {
        flex: 1 1 100% !important;
    }

    .footer-right-side .row[b-iaqmi9i901] {
        grid-template-columns: 1fr;
    }
}

.footer-right-side[b-iaqmi9i901] {
    flex: 0 0 550px;
    /* Base width for footer section to ensure all boxes fit inside the form */
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 8px 16px;
    /* Increased horizontal padding */
    background: #f8fafc;
    border-left: 1px solid var(--slate-200);
    border-radius: 8px;
    /* Added border radius for better look */
}

.footer-right-side .row[b-iaqmi9i901] {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 4px;
}

.footer-right-side .col[b-iaqmi9i901] {
    flex: 1;
    min-width: 0;
}

.print-closing-balance .e-label[b-iaqmi9i901] {
    font-size: 14px !important;
}

/* ========== Overlay Popup (shared) ========== */
.sgbill-overlay[b-iaqmi9i901] {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* Placeholder Centering */
.e-input-group.e-control-wrapper.e-small .e-input[b-iaqmi9i901],
.e-outline.e-small .e-input[b-iaqmi9i901],
.e-ddl.e-small .e-input[b-iaqmi9i901] {
    text-align: center !important;
}

.e-numeric.e-small .e-input[b-iaqmi9i901] {
    text-align: right !important;
    /* Changed to right-aligned for numeric clarity */
    padding-right: 8px !important;
}

.e-input-group.e-control-wrapper.e-small .e-input[b-iaqmi9i901]::placeholder,
.e-outline.e-small .e-input[b-iaqmi9i901]::placeholder {
    text-align: center !important;
}

/* Legibility */
.no-records-msg[b-iaqmi9i901] {
    text-align: center;
    padding: 24px !important;
    color: var(--slate-500);
    font-size: 18px !important;
    font-weight: 600;
}

/* ========== Popup Styles ========== */
.sgbill-popup-panel[b-iaqmi9i901] {
    background: #ffffff;
    border: 1px solid var(--slate-300);
    border-radius: 6px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    width: 320px;
    max-height: 98vh;
    overflow-y: hidden;
    /* Removed vertical scroll as requested */
}

.sgbill-popup-wide[b-iaqmi9i901] {
    width: 520px;
}

.sgbill-popup-title[b-iaqmi9i901] {
    text-align: center;
    font-weight: 700;
    font-size: 13px;
    padding: 8px 12px;
    border-bottom: 1px solid var(--slate-200);
    color: var(--slate-700);
}

.sgbill-popup-body[b-iaqmi9i901] {
    padding: 10px 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sgbill-popup-field[b-iaqmi9i901] {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

.sgbill-popup-field label[b-iaqmi9i901] {
    flex: 0 0 130px;
    font-size: 11px;
    font-weight: 600;
    color: var(--slate-600);
    white-space: nowrap;
}

.sgbill-popup-field .e-input-group[b-iaqmi9i901],
.sgbill-popup-field .e-ddl[b-iaqmi9i901] {
    flex: 1;
    min-width: 0;
}

.sgbill-popup-row[b-iaqmi9i901] {
    display: flex;
    gap: 10px;
}

.sgbill-popup-row .sgbill-popup-field label[b-iaqmi9i901] {
    flex: 0 0 auto;
    min-width: 60px;
}

.sgbill-popup-actions[b-iaqmi9i901] {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 6px 14px;
    border-top: 1px solid var(--slate-200);
}

/* ========== Summary Section Enhancements ========== */
.summary-rows-container[b-iaqmi9i901] {
    background: #f1f5f9;
    /* Light grey as requested */
    padding: 2px 4px;
    border: 1px solid #cbd5e1;
    border-top: none;
    font-family: inherit;
    border-bottom-left-radius: 4px;
    border-bottom-right-radius: 4px;
    width: fit-content;
    margin-right: auto;
}

.summary-flex-row[b-iaqmi9i901] {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-bottom: 2px;
}

.summary-flex-row:last-child[b-iaqmi9i901] {
    margin-bottom: 0;
}

/* Removed conflicting .summary-label that forced width: 20px */
.summary-dot-label[b-iaqmi9i901] {
    width: 20px;
    height: 19px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    border-radius: 2px;
    font-size: 10px;
    color: white;
    flex-shrink: 0;
}

.label-s[b-iaqmi9i901] {
    background: #3b82f6;
}

/* Blue for Sale */
.label-r[b-iaqmi9i901] {
    background: #ef4444;
}

/* Red for Return */

.summary-item[b-iaqmi9i901] {
    width: 78px;
    /* Even more compact as requested */
    flex-shrink: 0;
}

.summary-input[b-iaqmi9i901] {
    width: 100%;
    height: 20px;
    padding: 0 4px;
    font-size: 10px;
    text-align: right;
    border: 1px solid #cbd5e1;
    border-radius: 2px;
    background: #ffffff;
    font-weight: 600;
    color: #334155;
    outline: none;
}

.summary-input:read-only[b-iaqmi9i901] {
    background: #fdfdfd;
}

/* Payment grid summary rows override */
.sgbill-table.payment-grid-green tbody tr.summary-row[b-iaqmi9i901],
.sgbill-table.payment-grid-green tbody tr.summary-row td[b-iaqmi9i901] {
    background-color: #f1f5f9 !important;
    /* Consistent light grey for totals */
    color: #1e293b !important;
    font-weight: 700 !important;
    border-top: 1px solid #cbd5e1 !important;
}

.summary-input[b-iaqmi9i901] {
    width: 80px;
    height: 24px;
    font-size: 11px;
    padding: 0 4px;
    border: 1px solid #cbd5e1;
    border-radius: 2px;
    background-color: white;
    text-align: right;
    font-weight: 600;
    color: #334155;
}

.summary-input:focus[b-iaqmi9i901] {
    outline: none;
    border-color: #3b82f6;
}

.summary-item[b-iaqmi9i901] {
    display: flex;
    align-items: center;
}

/* Grid Row Colors */
.row-sale[b-iaqmi9i901] {
    background-color: #fee2e2 !important;
    /* Soft Red */
}

.row-return[b-iaqmi9i901] {
    background-color: #dcfce7 !important;
    /* Soft Green */
}

.row-sale.e-row:hover .e-rowcell[b-iaqmi9i901] {
    background-color: #fecaca !important;
}

.row-return.e-row:hover .e-rowcell[b-iaqmi9i901] {
    background-color: #bbf7d0 !important;
}



/* Compact Inputs */
.quick-entry-section .e-input-group.e-control-wrapper[b-iaqmi9i901] {
    margin-bottom: 0 !important;
}

.quick-entry-section .e-numerictextbox .e-input-group[b-iaqmi9i901] {
    width: 100% !important;
}

.sgbill-popup-close[b-iaqmi9i901] {
    position: absolute;
    top: 6px;
    right: 12px;
    cursor: pointer;
    font-size: 18px;
    color: var(--slate-400);
    transition: color 0.2s;
    z-index: 10;
}

.sgbill-popup-close:hover[b-iaqmi9i901] {
    color: var(--danger-red);
}

.bg-light-yellow[b-iaqmi9i901] {
    background-color: #fffbeb !important;
}

/* ========== Mobile Responsiveness ========== */
@media (max-width: 991.98px) {
    .header-main-container .d-flex.flex-nowrap[b-iaqmi9i901] {
        flex-direction: column !important;
        flex-wrap: wrap !important;
    }

    .header-main-container .col-auto[b-iaqmi9i901],
    .header-main-container .col[b-iaqmi9i901] {
        width: 100% !important;
        flex: 1 1 100% !important;
        max-width: 100% !important;
        margin-bottom: 8px;
    }

    .ms-auto[b-iaqmi9i901] {
        margin-left: 0 !important;
    }

    .footer-layout[b-iaqmi9i901] {
        flex-direction: column !important;
        gap: 16px !important;
    }

    .remarks-group[b-iaqmi9i901] {
        flex: 1 1 100% !important;
        width: 100% !important;
    }

    .footer-right-side[b-iaqmi9i901] {
        flex: 1 1 100% !important;
        width: 100% !important;
        border-left: none !important;
        border-top: 1px solid var(--slate-200);
        padding: 16px 8px !important;
    }

    .footer-right-side .d-flex.flex-nowrap[b-iaqmi9i901] {
        flex-direction: column !important;
        gap: 16px !important;
    }

    .footer-right-side .col-auto[b-iaqmi9i901],
    .footer-right-side .col[b-iaqmi9i901] {
        width: 100% !important;
        flex: 1 1 100% !important;
    }

    .calculation-group[b-iaqmi9i901] {
        grid-template-columns: repeat(3, 1fr) !important;
        /* 3 columns on tablets too */
        width: 100% !important;
    }

    .payment-grid-container[b-iaqmi9i901] {
        height: auto !important;
        min-height: 200px;
        overflow-x: auto;
    }

    .history-grid-wrapper[b-iaqmi9i901] {
        height: auto !important;
        max-height: 200px;
    }

    .premium-card[b-iaqmi9i901] {
        margin-bottom: 12px;
    }
}

@media (max-width: 575.98px) {
    .calculation-group[b-iaqmi9i901] {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    .calculation-group .d-flex[b-iaqmi9i901] {
        flex-direction: row !important;
        flex-wrap: nowrap !important;
        gap: 2px !important;
        align-items: flex-end !important;
        width: 100% !important;
    }

    .calculation-group .d-flex .e-btn[b-iaqmi9i901] {
        flex: 0 0 auto !important;
        width: 24px !important;
        height: 28px !important;
        padding: 0 !important;
    }

    .calculation-group .d-flex .e-control-wrapper[b-iaqmi9i901] {
        flex: 1 !important;
        min-width: 0 !important;
        width: auto !important;
    }

    .footer-actions-right[b-iaqmi9i901] {
        flex-direction: row !important;
        justify-content: flex-end !important;
        gap: 8px !important;
    }

    .footer-actions-right .e-btn[b-iaqmi9i901] {
        width: auto !important;
        flex: 1 !important;
    }

    .summary-rows-container[b-iaqmi9i901] {
        width: 100% !important;
        overflow-x: auto;
    }

    .page-content[b-iaqmi9i901] {
        padding: 4px 8px !important;
    }
}

.bg-light-green[b-iaqmi9i901] {
    background-color: #f0fdf4 !important;
}
/* /Components/Pages/Devam/Trading/SgBill.razor.rz.scp.css */
/* ========== Voucher Popup Styling (Matching Image) ========== */
.sgbill-popup-voucher[b-f0151pmxg3] {
    width: 90vw !important;
    max-width: 1400px !important;
    max-height: 95vh !important;
    /* Keep it within view always */
    border: 2px solid var(--primary-blue) !important;
    border-radius: 4px !important;
    padding: 0 !important;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    /* Ensure vertical layout for header/body/footer */
}

.voucher-popup-header[b-f0151pmxg3] {
    background: linear-gradient(to right, var(--primary-blue), #242488);
    color: white;
    padding: 8px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #1e1b4b;
}

.voucher-popup-title[b-f0151pmxg3] {
    font-weight: 700;
    font-size: 16px;
    letter-spacing: 0.5px;
}

.voucher-popup-close[b-f0151pmxg3] {
    cursor: pointer;
    font-size: 18px;
    opacity: 0.8;
}

    .voucher-popup-close:hover[b-f0151pmxg3] {
        opacity: 1;
    }

.voucher-popup-body[b-f0151pmxg3] {
    padding: 15px;
    background: #ffffff;
    flex: 1;
    /* Take all available space between header and footer */
    overflow-y: auto;
    /* Enable scroll if content is tall */
    min-height: 0;
    /* Flex overflow fix */
}

.voucher-entry-row[b-f0151pmxg3] {
    display: flex;
    flex-wrap: nowrap;
    gap: 3px;
    /* Minimal gap */
    align-items: flex-end;
    margin-bottom: 8px;
    padding: 4px 6px;
    /* Very tight padding */
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    overflow: hidden;
    /* Force hide any scrolling */
}

.voucher-field-group[b-f0151pmxg3] {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 0 0 auto;
}

/* Even smaller widths for ultra-compact fit */
.field-voucher[b-f0151pmxg3] {
    width: 110px;
}

.field-type[b-f0151pmxg3] {
    width: 150px;
}

.field-gross[b-f0151pmxg3] {
    width: 70px;
}

.field-purity[b-f0151pmxg3] {
    width: 60px;
}

.field-wast[b-f0151pmxg3] {
    width: 60px;
}

.field-wb[b-f0151pmxg3] {
    width: 120px;
}

.field-fine[b-f0151pmxg3] {
    width: 75px;
}

.field-rate[b-f0151pmxg3] {
    width: 85px;
}

.field-amount[b-f0151pmxg3] {
    width: 85px;
}

.field-remarks[b-f0151pmxg3] {
    flex: 1;
    min-width: 60px;
}

/* Ultra-shrinking textboxes and components */
.voucher-entry-row .e-input-group[b-f0151pmxg3],
.voucher-entry-row .e-input-group.e-control-wrapper[b-f0151pmxg3],
.voucher-entry-row .e-control-wrapper[b-f0151pmxg3] {
    height: 22px !important;
    min-height: 22px !important;
    min-width: 0 !important;
    /* Force respect parent */
}

.voucher-entry-row .e-input[b-f0151pmxg3] {
    font-size: 9px !important;
    padding: 0 3px !important;
    height: 20px !important;
}

.voucher-entry-row .e-ddl.e-input-group .e-input-group-icon[b-f0151pmxg3],
.voucher-entry-row .e-numeric.e-input-group .e-input-group-icon[b-f0151pmxg3] {
    min-height: 20px !important;
    font-size: 9px !important;
    width: 20px !important;
}

.voucher-field-group label[b-f0151pmxg3] {
    font-size: 13px;
    font-weight: 700;
    color: #334155;
    white-space: nowrap;
    margin-bottom: 5px;
    /* Increased from 3px to keep border/box far from label */
    line-height: 1.2;
}

.voucher-action-cell[b-f0151pmxg3] {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.voucher-entry-btn[b-f0151pmxg3] {
    background: var(--primary-blue) !important;
    color: white !important;
    border: none !important;
    height: 32px !important;
    width: 38px !important;
    border-radius: 4px !important;
}

.voucher-grid-container[b-f0151pmxg3] {
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    margin-bottom: 15px;
    max-height: 250px;
    /* Reduced height to keep UI compact */
    overflow-y: auto;
    /* Scroll only if content exceeds 250px */
}

.voucher-grid[b-f0151pmxg3] {
    border: none !important;
}

    .voucher-grid .e-headercell[b-f0151pmxg3] {
        background: #f1f5f9 !important;
        color: #334155 !important;
        font-weight: 700 !important;
        text-transform: capitalize !important;
        border-bottom: 2px solid #cbd5e1 !important;
    }

.voucher-footer[b-f0151pmxg3] {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    /* Changed from flex-start to align better at the bottom */
    margin-top: 15px;
    margin-bottom: 20px;
    gap: 15px;
}

.voucher-footer-left[b-f0151pmxg3] {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.total-gross-label[b-f0151pmxg3] {
    font-weight: 700;
    font-size: 13px;
    /* Reduced to 13px as requested */
    color: #475569;
    margin-bottom: 2px;
}

.total-boxes[b-f0151pmxg3] {
    display: flex;
    gap: 10px;
}

.total-box[b-f0151pmxg3] {
    width: 120px;
    height: 32px;
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0 8px;
    font-weight: 700;
    font-size: 13px;
    border-radius: 4px;
}

.voucher-footer-right[b-f0151pmxg3] {
    min-width: 320px;
    /* Reduced from 420px to ensure it fits "inside the form" */
    max-width: 400px;
    flex: 0 1 auto;
}

.summary-card[b-f0151pmxg3] {
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 15px 5px;
    /* Increased top/bottom, set horizontal for lines to manage edge spacing */
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
}

.summary-line[b-f0151pmxg3] {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 6px;
    /* Adjusted padding for 13px font */
    border-bottom: 1px dashed #e2e8f0;
    margin: 0 !important;
}

    .summary-line:last-child[b-f0151pmxg3] {
        border-bottom: none;
    }

.voucher-summary-label[b-f0151pmxg3] {
    font-weight: 700 !important;
    font-size: 13px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
    white-space: nowrap !important;
    color: inherit;
    margin: 0 !important;
    line-height: normal !important;
    padding-left: 15px;
    /* Indent label from border */
}

.summary-value[b-f0151pmxg3] {
    font-weight: 700 !important;
    font-size: 13px !important;
    text-align: right !important;
    margin: 0 !important;
    line-height: normal !important;
    padding-right: 15px;
    /* Indent value from border */
}

.voucher-save-section[b-f0151pmxg3] {
    padding: 10px 15px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    background: #f8fafc;
    flex-shrink: 0;
    /* Ensure it stays visible at the bottom */
}

.action-buttons-container[b-f0151pmxg3] {
    display: flex;
    gap: 8px;
    justify-content: center;
}

.action-icon-btn[b-f0151pmxg3] {
    width: 28px !important;
    height: 28px !important;
    padding: 0 !important;
    border-radius: 6px !important;
    min-width: 28px !important;
}

.delete-btn:hover[b-f0151pmxg3] {
    background-color: #fee2e2 !important;
    color: #ef4444 !important;
}

.delete-icon-wrapper[b-f0151pmxg3] {
    background: #fef2f2;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

/* ========== Payment Section Redesign ========== */
.payment-section-layout[b-f0151pmxg3] {
    display: flex;
    gap: 0;
    border: 1px solid var(--slate-300);
    border-radius: 4px;
    background: #fff;
    min-height: 80px;
    max-height: 120px;
    overflow: hidden;
}

.payment-sidebar[b-f0151pmxg3] {
    display: flex;
    flex-direction: column;
    flex: 0 0 100px;
    /* Increased from 55px */
    border-right: 1px solid var(--slate-300);
    background: var(--primary-blue);
    height: auto;
}

    .payment-sidebar-btn[b-f0151pmxg3],
    .payment-sidebar-btn.e-btn[b-f0151pmxg3],
    .payment-sidebar .e-btn[b-f0151pmxg3],
    .payment-sidebar button.e-btn[b-f0151pmxg3],
    .payment-sidebar .e-css.e-btn[b-f0151pmxg3] {
        flex: 1;
        width: 100% !important;
        border-radius: 0 !important;
        font-size: 10px !important;
        /* Increased from 8px */
        font-weight: 700 !important;
        text-transform: uppercase;
        border: none !important;
        box-shadow: none !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.2) !important;
        background: var(--primary-blue) !important;
        background-color: var(--primary-blue) !important;
        color: #ffffff !important;
        padding: 4px 3px !important;
        white-space: normal !important;
        line-height: 1.1 !important;
        opacity: 1 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        visibility: visible !important;
        min-height: 35px !important;
    }

        .payment-sidebar-btn:last-child[b-f0151pmxg3],
        .payment-sidebar .e-btn:last-child[b-f0151pmxg3] {
            border-bottom: none !important;
        }

        .payment-sidebar-btn:hover[b-f0151pmxg3],
        .payment-sidebar .e-btn:hover[b-f0151pmxg3] {
            background: #312e81 !important;
            background-color: #312e81 !important;
            color: #ffffff !important;
        }

.payment-main-content[b-f0151pmxg3] {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    border: none !important;
}

.payment-grid-container[b-f0151pmxg3] {
    flex: 1;
    overflow-y: auto;
    overflow-x: auto;
}

.btn-delete-row[b-f0151pmxg3] {
    background: none;
    border: none;
    color: #ef4444;
    cursor: pointer;
    padding: 0 4px;
    font-size: 1.2rem;
    line-height: 1;
    border-radius: 4px;
}

    .btn-delete-row:hover[b-f0151pmxg3] {
        background-color: #fee2e2;
    }

/* ========== CSS Variables ========== */
:root[b-f0151pmxg3] {
    --primary-brand: var(--primary-blue);
    --accent-glow: var(--primary-blue);
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-300: #cbd5e1;
    --slate-400: #94a3b8;
    --slate-500: #64748b;
    --slate-600: #475569;
    --slate-700: #334155;
    --shadow-soft: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
    --border-radius-md: 8px;
    --silver-btn: var(--primary-blue);
    --gold-btn: var(--primary-blue);
}

/* ========== Base Layout ========== */
.page-container[b-f0151pmxg3] {
    max-width: 100%;
    height: auto !important;
    min-height: min-content !important;
    overflow: visible !important;
    font-family: 'Inter', system-ui, -apple-system, sans-serif !important;
    animation: fadeIn-b-f0151pmxg3 0.2s ease-in;
}

@keyframes fadeIn-b-f0151pmxg3 {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.full-width-content[b-f0151pmxg3] {
    padding: 6px 15px !important;
    background: #ffffff;
    height: auto !important;
    overflow: visible !important;
}

/*.sgbill-layout {
    display: flex;
    flex-direction: column;
    gap: 8px;*/
/* Increased gap for better spacing */
/*max-width: 100%;
    height: auto !important;
    min-height: 0 !important;
    padding-bottom: 120px !important;*/
/* Force extra space at bottom for footer visibility */
/*overflow: visible !important;
}*/

.sgbill-layout[b-f0151pmxg3] {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    padding-left: 0 !important;
    margin-left: 0 !important;
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
}

.main-form-section[b-f0151pmxg3] {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-left: 0 !important;
    margin-left: 0 !important;
    width: 100%;
    max-width: 100%;
    overflow-x: visible;
}

/* Removed fixed desktop height to prevent grid being pushed off by expanded headers */

/* ========== Card Components ========== */
.premium-card[b-f0151pmxg3] {
    background: #ffffff;
    border-radius: var(--border-radius-md);
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--slate-100);
    overflow: visible;
    max-width: 100%;
    contain: layout style;
    flex-shrink: 0;
}

    .premium-card:last-child[b-f0151pmxg3] {
        border-bottom: none;
    }

.card-body-premium[b-f0151pmxg3] {
    padding: 8px 12px;
}

.header-card .card-body-premium[b-f0151pmxg3] {
    padding: 6px 12px;
}

.footer-card .card-body-premium[b-f0151pmxg3] {
    padding: 4px 10px;
    padding-right: 0 !important;
}

/* ========== Header Section ========== */
.header-main-container[b-f0151pmxg3] {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
}

.header-left-col[b-f0151pmxg3] {
    flex: 1 1 500px;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.header-right-col[b-f0151pmxg3] {
    flex: 0 1 500px;
    min-width: 300px;
}

.header-row[b-f0151pmxg3] {
    display: flex;
    gap: 8px;
    align-items: center;
}

.header-field[b-f0151pmxg3] {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.w-60[b-f0151pmxg3] {
    flex: 0 0 60px;
}

.w-150[b-f0151pmxg3] {
    flex: 0 0 150px;
}

.w-168[b-f0151pmxg3] {
    flex: 0 0 168px;
}

.w-225[b-f0151pmxg3] {
    flex: 0 0 225px;
}

.w-240[b-f0151pmxg3] {
    flex: 0 0 240px;
}

.flex-row-gap[b-f0151pmxg3] {
    display: flex;
    flex-direction: row;
    gap: 6px;
}


.history-grid-wrapper[b-f0151pmxg3] {
    background: var(--slate-50);
    border: none !important;
    box-shadow: none !important;
    border-radius: 6px;
    overflow: auto;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.history-table[b-f0151pmxg3] {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
    table-layout: fixed;
    border: none !important;
}

    .history-table thead th[b-f0151pmxg3] {
        background: var(--slate-100);
        padding: 5px 6px;
        font-weight: 600;
        font-size: 10px;
        text-align: left;
        border: none !important;
        white-space: nowrap;
        position: sticky;
        top: 0;
        z-index: 1;
        color: var(--slate-600);
    }

    .history-table tbody tr[b-f0151pmxg3] {
        color: var(--slate-700);
    }

    .history-table tbody td[b-f0151pmxg3] {
        padding: 4px 6px;
        border: none !important;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .history-table tbody tr:hover[b-f0151pmxg3] {
        background: var(--slate-100);
    }

    .history-table th:nth-child(1)[b-f0151pmxg3],
    .history-table td:nth-child(1)[b-f0151pmxg3] {
        width: 15%;
    }

    .history-table th:nth-child(2)[b-f0151pmxg3],
    .history-table td:nth-child(2)[b-f0151pmxg3] {
        width: 18%;
    }

    .history-table th:nth-child(3)[b-f0151pmxg3],
    .history-table td:nth-child(3)[b-f0151pmxg3] {
        width: 18%;
    }

    .history-table th:nth-child(4)[b-f0151pmxg3],
    .history-table td:nth-child(4)[b-f0151pmxg3] {
        width: 18%;
    }

    .history-table th:nth-child(5)[b-f0151pmxg3],
    .history-table td:nth-child(5)[b-f0151pmxg3] {
        width: 31%;
    }

/* ========== Table Section ========== */
.table-card .card-body-premium[b-f0151pmxg3] {
    padding: 0;
}

.table-scroll-wrapper[b-f0151pmxg3] {
    overflow: auto;
    flex: 0 1 auto;
    min-height: 100px;
    max-width: 100%;
    border: 1px solid var(--slate-200);
    content-visibility: auto;
}

.table-card[b-f0151pmxg3] {
    flex: 0 1 auto !important;
    /* Shrink to content */
    min-height: 0 !important;
    overflow: hidden !important;
    display: flex;
    flex-direction: column;
}

    .table-card .card-body-premium[b-f0151pmxg3] {
        flex: 0 1 auto;
        min-height: 0;
        overflow: hidden;
        display: flex;
        flex-direction: column;
    }

.table-scroll-wrapper[b-f0151pmxg3] {
    width: 100%;
    overflow: auto;
    position: relative;
}

.main-item-grid-wrapper[b-f0151pmxg3] {
    max-height: 155px !important;
    /* header + ~3 rows forced */
    min-height: 0 !important;
    overflow-y: auto !important;
}

.footer-card[b-f0151pmxg3] {
    flex-shrink: 0 !important;
}

.summary-section-wrapper[b-f0151pmxg3] {
    max-width: 100%;
    background: #ffffff;
    border-bottom: 1px solid var(--slate-200);
    margin: 5px 15px;
}

.summary-row-fields[b-f0151pmxg3] {
    padding: 4px 8px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.sgbill-table[b-f0151pmxg3] {
    width: 100%;
    border-collapse: collapse;
    font-size: 11px;
    min-width: 1700px;
    background: #ffffff;
    table-layout: fixed;
}

    .sgbill-table thead th[b-f0151pmxg3] {
        background: var(--slate-50);
        padding: 6px 4px;
        font-weight: 600;
        font-size: 10px;
        text-align: center;
        border: 1px solid var(--slate-300);
        white-space: nowrap;
        position: sticky;
        top: 0;
        z-index: 10;
        color: var(--slate-600);
    }

    .sgbill-table tbody td[b-f0151pmxg3] {
        padding: 8px 2px 2px 2px;
        border: 1px solid var(--slate-200);
        vertical-align: top;
        background: #ffffff;
    }

    /* Row colors matching legacy grdDetails_CellFormatting */
    /* Pink/Red for Sale items: rgb(255,192,192) */
    .sgbill-table tbody tr.row-pink[b-f0151pmxg3],
    .sgbill-table tbody tr.row-pink td[b-f0151pmxg3] {
        background-color: rgb(255, 192, 192) !important;
    }

    /* Green for Return items: rgb(192,255,192) */
    .sgbill-table tbody tr.row-green[b-f0151pmxg3],
    .sgbill-table tbody tr.row-green td[b-f0151pmxg3] {
        background-color: rgb(192, 255, 192) !important;
    }

/* Main Grid Header - Neutral theme */
.main-grid-pink thead th[b-f0151pmxg3] {
    background: #f1f5f9 !important;
    color: #475569 !important;
    border-color: #cbd5e1 !important;
}

/* Payment Grid - Neutral theme */
.payment-grid-green[b-f0151pmxg3] {
    background-color: #ffffff !important;
}

    .payment-grid-green thead th[b-f0151pmxg3] {
        background: #f1f5f9 !important;
        color: #475569 !important;
        border-color: #cbd5e1 !important;
    }

    .payment-grid-green tbody tr[b-f0151pmxg3] {
        background-color: #ffffff !important;
    }

/* Row-highlighted takes priority over sale/return colors (validation errors) */
.sgbill-table tbody tr.row-highlighted[b-f0151pmxg3],
.sgbill-table tbody tr.row-highlighted td[b-f0151pmxg3],
.sgbill-table tbody tr.row-highlighted.row-sale[b-f0151pmxg3],
.sgbill-table tbody tr.row-highlighted.row-sale td[b-f0151pmxg3],
.sgbill-table tbody tr.row-highlighted.row-return[b-f0151pmxg3],
.sgbill-table tbody tr.row-highlighted.row-return td[b-f0151pmxg3] {
    background-color: #ff6b6b !important;
}

.sgbill-popup-actions .e-outline:hover[b-f0151pmxg3] {
    background-color: transparent !important;
    color: inherit !important;
}

.sgbill-popup-section-title[b-f0151pmxg3] {
    font-size: 11px;
    font-weight: 700;
    color: var(--slate-600);
    margin: 12px 0 8px 0;
    padding-bottom: 4px;
    border-bottom: 1px dashed #e2e8f0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.sgbill-popup-grid-row[b-f0151pmxg3] {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 10px;
}

.sgbill-popup-opening-row[b-f0151pmxg3] {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    align-items: end;
}

.sgbill-popup-opening-field-group[b-f0151pmxg3] {
    display: flex;
    align-items: center;
    gap: 0;
    border: 1px solid var(--slate-200);
    border-radius: 4px;
    overflow: hidden;
}

    .sgbill-popup-opening-field-group .e-numeric[b-f0151pmxg3],
    .sgbill-popup-opening-field-group .e-ddl[b-f0151pmxg3] {
        border: none !important;
    }

    .sgbill-popup-opening-field-group .e-numeric[b-f0151pmxg3] {
        flex: 1;
    }

    .sgbill-popup-opening-field-group .e-ddl[b-f0151pmxg3] {
        width: 100px;
        background: #f8fafc;
        border-left: 1px solid var(--slate-200) !important;
    }

.sgbill-popup-opening-date-row[b-f0151pmxg3] {
    display: grid;
    grid-template-columns: 1fr 1fr 1.5fr;
    gap: 12px;
    margin-top: 8px;
}

.table-input[b-f0151pmxg3] {
    width: 100%;
    font-size: 11px;
}

.calculation-group .e-numerictextbox.e-small .e-input[b-f0151pmxg3] {
    padding: 0 6px !important;
    font-size: 11px !important;
}

.table-input .e-input-group[b-f0151pmxg3],
.table-input.e-input-group[b-f0151pmxg3] {
    min-height: 28px !important;
    max-height: 28px !important;
    border: none;
    background: transparent;
}

.table-input .e-input[b-f0151pmxg3],
.table-input.e-input[b-f0151pmxg3] {
    font-size: 11px;
    height: 26px !important;
    line-height: 26px !important;
    padding: 1px 7px;
    background: transparent;
    border: none;
    transition: background-color 0.15s ease;
}

    .table-input .e-input:focus[b-f0151pmxg3] {
        background: #f0f9ff;
    }

/* ========== Summary Section ========== */
.summary-label-cell[b-f0151pmxg3] {
    width: 50px;
    text-align: center;
    font-weight: 700;
    font-size: 14px;
    vertical-align: middle !important;
}

.label-s[b-f0151pmxg3] {
    color: #fff;
}

.label-r[b-f0151pmxg3] {
    color: #fff;
}

/* ========== Footer Section ========== */
.footer-layout[b-f0151pmxg3] {
    display: flex;
    gap: 32px;
    /* Increased gap for better separation */
    flex-wrap: nowrap;
    align-items: stretch;
    margin-top: 2px;
}

.footer-left-pack[b-f0151pmxg3] {
    flex: 1 1 70%;
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.footer-right-pack[b-f0151pmxg3] {
    flex: 0 0 200px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 4px;
    background: var(--slate-50);
    border-left: 1px solid var(--slate-200);
}

.compact-footer-row[b-f0151pmxg3] {
    display: flex;
    gap: 6px;
    align-items: stretch;
}

.remarks-group[b-f0151pmxg3] {
    flex: 0 0 300px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.calculation-group[b-f0151pmxg3] {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    align-content: start;
}

.calc-row[b-f0151pmxg3] {
    display: contents;
}

.footer-col[b-f0151pmxg3] {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.payment-sidebar[b-f0151pmxg3] {
    display: flex;
    flex-direction: column;
    flex: 0 0 65px;
    border-right: 1px solid var(--slate-300);
    background: #f8fafc;
    /* Neutral Sidebar as requested */
    height: 100px;
}

.footer-table-container[b-f0151pmxg3] {
    max-height: 400px;
    height: 180px;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
    border: none !important;
    box-shadow: none !important;
}

.compact-footer-table[b-f0151pmxg3] {
    min-width: 800px !important;
    margin-bottom: 0 !important;
}

    .compact-footer-table thead th[b-f0151pmxg3] {
        background: var(--slate-100) !important;
        font-size: 10px !important;
        padding: 4px !important;
        border: 1px solid var(--slate-200) !important;
        color: var(--slate-700) !important;
    }

    .compact-footer-table tbody td[b-f0151pmxg3] {
        padding: 3px 5px !important;
        font-size: 10px !important;
        height: 22px !important;
        border: 1px solid var(--slate-100) !important;
    }

    .compact-footer-table .text-right[b-f0151pmxg3] {
        text-align: right !important;
    }

.payment-tabs.e-tab[b-f0151pmxg3] {
    border: none !important;
}

.payment-tabs .e-tab-header[b-f0151pmxg3] {
    height: 30px !important;
    background: var(--slate-100) !important;
    border-bottom: 1px solid var(--slate-200) !important;
}

    .payment-tabs .e-tab-header .e-toolbar-item .e-tab-text[b-f0151pmxg3] {
        font-size: 11px !important;
        font-weight: 600 !important;
    }

.footer-grid-2[b-f0151pmxg3] {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

/* Summary Inputs */
.summary-item[b-f0151pmxg3] {
    width: 80px;
    flex: 0 0 auto;
}

.summary-input[b-f0151pmxg3] {
    width: 100%;
    height: 24px;
    font-size: 11px;
    text-align: right;
    border: 1px solid #cbd5e1;
    border-radius: 2px;
    padding: 2px 4px;
    background: #fff;
    color: #1e293b;
    font-weight: 600;
}

    .summary-input:read-only[b-f0151pmxg3] {
        background: #f8fafc;
    }

    .summary-input:focus[b-f0151pmxg3] {
        outline: 1px solid #3b82f6;
        border-color: #3b82f6;
    }



.final-summary[b-f0151pmxg3] {
    padding: 4px 8px;
    background: var(--slate-50);
    border: 1px solid var(--slate-200);
    border-radius: var(--border-radius-md);
    margin-top: 4px;
}

    .final-summary.no-margin[b-f0151pmxg3] {
        margin-top: 0 !important;
        border: none !important;
        background: transparent !important;
        padding: 0 !important;
    }

.summary-item[b-f0151pmxg3] {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.summary-label[b-f0151pmxg3] {
    font-size: 10px;
    font-weight: 600;
    color: var(--slate-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 2px;
}

.summary-value[b-f0151pmxg3] {
    font-weight: 700;
    font-size: 14px;
    color: var(--primary-brand);
}

.footer-actions-row[b-f0151pmxg3] {
    margin-top: 20px;
    padding: 8px 16px;
    border-top: 2px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    width: 100%;
    max-width: 100%;
    bottom: 0;
    background: #f8fafc;
    z-index: 1000; /* Increased z-index for better visibility */
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.1);
    border-radius: 0 0 12px 12px;
    backdrop-filter: blur(8px);
    border-bottom: 1px solid #e2e8f0;
}

.footer-actions-left[b-f0151pmxg3], .footer-actions-right[b-f0151pmxg3] {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

/* ========== Input Styles ========== */
.e-numerictextbox input[b-f0151pmxg3],
.e-numeric input[b-f0151pmxg3] {
    text-align: right !important;
}

.e-input-group:not(.e-success):not(.e-error)[b-f0151pmxg3],
.e-input-group.e-control-wrapper:not(.e-success):not(.e-error)[b-f0151pmxg3] {
    border-color: var(--slate-300);
}

    .e-input-group:not(.e-success):not(.e-error):hover[b-f0151pmxg3],
    .e-input-group.e-control-wrapper:not(.e-success):not(.e-error):hover[b-f0151pmxg3],
    .e-input-group.e-input-focus:not(.e-success):not(.e-error)[b-f0151pmxg3],
    .e-input-group.e-control-wrapper.e-input-focus:not(.e-success):not(.e-error)[b-f0151pmxg3] {
        border-color: var(--accent-glow);
    }

.e-input-group.e-input-focus[b-f0151pmxg3],
.e-input-group.e-control-wrapper.e-input-focus[b-f0151pmxg3] {
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.1);
}




*[b-f0151pmxg3] {
    touch-action: manipulation;
}

    *:focus-visible[b-f0151pmxg3] {
        outline: 2px solid var(--accent-glow);
        outline-offset: 2px;
    }

/* ========== Responsive Design ========== */
@media (max-width: 1200px) {
    .header-main-container[b-f0151pmxg3] {
        flex-direction: column;
        gap: 20px;
    }

    .header-left-col[b-f0151pmxg3],
    .header-right-col[b-f0151pmxg3] {
        max-width: 100%;
        width: 100%;
    }
}

@media (max-width: 1024px) {
    .footer-layout[b-f0151pmxg3] {
        flex-direction: column;
        gap: 20px;
    }

    .footer-right-side[b-f0151pmxg3] {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .full-width-content[b-f0151pmxg3] {
        padding: 10px !important;
    }

    .header-row[b-f0151pmxg3] {
        flex-wrap: wrap;
        gap: 8px;
    }

    .header-field[b-f0151pmxg3] {
        flex: 1 1 calc(50% - 8px) !important;
        min-width: 120px;
    }

    .main-form-section[b-f0151pmxg3] {
        min-width: 100%;
    }

    .w-60[b-f0151pmxg3],
    .w-150[b-f0151pmxg3],
    .w-168[b-f0151pmxg3],
    .w-240[b-f0151pmxg3] {
        flex: 1 1 auto !important;
        width: auto !important;
    }

    .footer-right-side .row[b-f0151pmxg3] {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .footer-right-side .row .col[b-f0151pmxg3] {
        width: 100% !important;
        flex: 0 0 100% !important;
        padding: 0 !important;
    }

    .footer-grid-2[b-f0151pmxg3],
    .footer-grid-3[b-f0151pmxg3] {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .footer-actions-row[b-f0151pmxg3] {
        flex-direction: column;
        align-items: stretch;
    }

    .footer-actions-left[b-f0151pmxg3], .footer-actions-right[b-f0151pmxg3] {
        justify-content: center;
        width: 100%;
    }

    .footer-actions-left .e-btn[b-f0151pmxg3],
    .footer-actions-right .e-btn[b-f0151pmxg3] {
        flex: 1;
        min-width: 120px;
    }
}

@media (max-width: 480px) {
    .header-field[b-f0151pmxg3] {
        flex: 1 1 100% !important;
    }

    .footer-right-side .row[b-f0151pmxg3] {
        grid-template-columns: 1fr;
    }
}

.footer-right-side[b-f0151pmxg3] {
    flex: 0 0 550px;
    /* Base width for footer section to ensure all boxes fit inside the form */
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 8px 16px;
    /* Increased horizontal padding */
    background: #f8fafc;
    border-left: 1px solid var(--slate-200);
    border-radius: 8px;
    /* Added border radius for better look */
}

    .footer-right-side .row[b-f0151pmxg3] {
        display: flex;
        gap: 8px;
        align-items: center;
        margin-bottom: 4px;
    }

    .footer-right-side .col[b-f0151pmxg3] {
        flex: 1;
        min-width: 0;
    }

.print-closing-balance .e-label[b-f0151pmxg3] {
    font-size: 14px !important;
}

/* ========== Overlay Popup (shared) ========== */
.sgbill-overlay[b-f0151pmxg3] {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* Placeholder Centering */
.e-input-group.e-control-wrapper.e-small .e-input[b-f0151pmxg3],
.e-outline.e-small .e-input[b-f0151pmxg3],
.e-ddl.e-small .e-input[b-f0151pmxg3] {
    text-align: center !important;
}

.e-numeric.e-small .e-input[b-f0151pmxg3] {
    text-align: right !important;
    /* Changed to right-aligned for numeric clarity */
    padding-right: 8px !important;
}

.e-input-group.e-control-wrapper.e-small .e-input[b-f0151pmxg3]::placeholder,
.e-outline.e-small .e-input[b-f0151pmxg3]::placeholder {
    text-align: center !important;
}

/* Legibility */
.no-records-msg[b-f0151pmxg3] {
    text-align: center;
    padding: 24px !important;
    color: var(--slate-500);
    font-size: 18px !important;
    font-weight: 600;
}

/* ========== Popup Styles ========== */
.sgbill-popup-panel[b-f0151pmxg3] {
    background: #ffffff;
    border: 1px solid var(--slate-300);
    border-radius: 6px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    width: 320px;
    max-height: 98vh;
    overflow-y: hidden;
    /* Removed vertical scroll as requested */
}

.sgbill-popup-wide[b-f0151pmxg3] {
    width: 520px;
}

.sgbill-popup-title[b-f0151pmxg3] {
    text-align: center;
    font-weight: 700;
    font-size: 13px;
    padding: 8px 12px;
    border-bottom: 1px solid var(--slate-200);
    color: var(--slate-700);
}

.sgbill-popup-body[b-f0151pmxg3] {
    padding: 10px 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sgbill-popup-field[b-f0151pmxg3] {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

    .sgbill-popup-field label[b-f0151pmxg3] {
        flex: 0 0 130px;
        font-size: 11px;
        font-weight: 600;
        color: var(--slate-600);
        white-space: nowrap;
    }

    .sgbill-popup-field .e-input-group[b-f0151pmxg3],
    .sgbill-popup-field .e-ddl[b-f0151pmxg3] {
        flex: 1;
        min-width: 0;
    }

.sgbill-popup-row[b-f0151pmxg3] {
    display: flex;
    gap: 10px;
}

    .sgbill-popup-row .sgbill-popup-field label[b-f0151pmxg3] {
        flex: 0 0 auto;
        min-width: 60px;
    }

.sgbill-popup-actions[b-f0151pmxg3] {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 6px 14px;
    border-top: 1px solid var(--slate-200);
}

/* ========== Summary Section Enhancements ========== */
.summary-rows-container[b-f0151pmxg3] {
    background: #f1f5f9;
    /* Light grey as requested */
    padding: 2px 4px;
    border: 1px solid #cbd5e1;
    border-top: none;
    font-family: inherit;
    border-bottom-left-radius: 4px;
    border-bottom-right-radius: 4px;
    width: fit-content;
    margin-right: auto;
}

.summary-flex-row[b-f0151pmxg3] {
    display: flex;
    align-items: center;
    gap: 2px;
    margin-bottom: 2px;
}

    .summary-flex-row:last-child[b-f0151pmxg3] {
        margin-bottom: 0;
    }

/* Removed conflicting .summary-label that forced width: 20px */
.summary-dot-label[b-f0151pmxg3] {
    width: 20px;
    height: 19px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    border-radius: 2px;
    font-size: 10px;
    color: white;
    flex-shrink: 0;
}

.label-s[b-f0151pmxg3] {
    background: #3b82f6;
}

/* Blue for Sale */
.label-r[b-f0151pmxg3] {
    background: #ef4444;
}

/* Red for Return */

.summary-item[b-f0151pmxg3] {
    width: 78px;
    /* Even more compact as requested */
    flex-shrink: 0;
}

.summary-input[b-f0151pmxg3] {
    width: 100%;
    height: 20px;
    padding: 0 4px;
    font-size: 10px;
    text-align: right;
    border: 1px solid #cbd5e1;
    border-radius: 2px;
    background: #ffffff;
    font-weight: 600;
    color: #334155;
    outline: none;
}

    .summary-input:read-only[b-f0151pmxg3] {
        background: #fdfdfd;
    }

/* Payment grid summary rows override */
.sgbill-table.payment-grid-green tbody tr.summary-row[b-f0151pmxg3],
.sgbill-table.payment-grid-green tbody tr.summary-row td[b-f0151pmxg3] {
    background-color: #f1f5f9 !important;
    /* Consistent light grey for totals */
    color: #1e293b !important;
    font-weight: 700 !important;
    border-top: 1px solid #cbd5e1 !important;
}

.summary-input[b-f0151pmxg3] {
    width: 80px;
    height: 24px;
    font-size: 11px;
    padding: 0 4px;
    border: 1px solid #cbd5e1;
    border-radius: 2px;
    background-color: white;
    text-align: right;
    font-weight: 600;
    color: #334155;
}

    .summary-input:focus[b-f0151pmxg3] {
        outline: none;
        border-color: #3b82f6;
    }

.summary-item[b-f0151pmxg3] {
    display: flex;
    align-items: center;
}

/* Grid Row Colors */
.row-sale[b-f0151pmxg3] {
    background-color: #fee2e2 !important;
    /* Soft Red */
}

.row-return[b-f0151pmxg3] {
    background-color: #dcfce7 !important;
    /* Soft Green */
}

.row-sale.e-row:hover .e-rowcell[b-f0151pmxg3] {
    background-color: #fecaca !important;
}

.row-return.e-row:hover .e-rowcell[b-f0151pmxg3] {
    background-color: #bbf7d0 !important;
}



/* Compact Inputs */
.quick-entry-section .e-input-group.e-control-wrapper[b-f0151pmxg3] {
    margin-bottom: 0 !important;
}

.quick-entry-section .e-numerictextbox .e-input-group[b-f0151pmxg3] {
    width: 100% !important;
}

.sgbill-popup-close[b-f0151pmxg3] {
    position: absolute;
    top: 6px;
    right: 12px;
    cursor: pointer;
    font-size: 18px;
    color: var(--slate-400);
    transition: color 0.2s;
    z-index: 10;
}

    .sgbill-popup-close:hover[b-f0151pmxg3] {
        color: var(--danger-red);
    }

.bg-light-yellow[b-f0151pmxg3] {
    background-color: #fffbeb !important;
}

/* ========== Mobile Responsiveness ========== */
@media (max-width: 991.98px) {
    .header-main-container .d-flex.flex-nowrap[b-f0151pmxg3] {
        flex-direction: column !important;
        flex-wrap: wrap !important;
    }

    .header-main-container .col-auto[b-f0151pmxg3],
    .header-main-container .col[b-f0151pmxg3] {
        width: 100% !important;
        flex: 1 1 100% !important;
        max-width: 100% !important;
        margin-bottom: 8px;
    }

    .ms-auto[b-f0151pmxg3] {
        margin-left: 0 !important;
    }

    .footer-layout[b-f0151pmxg3] {
        flex-direction: column !important;
        gap: 16px !important;
    }

    .remarks-group[b-f0151pmxg3] {
        flex: 1 1 100% !important;
        width: 100% !important;
    }

    .footer-right-side[b-f0151pmxg3] {
        flex: 1 1 100% !important;
        width: 100% !important;
        border-left: none !important;
        border-top: 1px solid var(--slate-200);
        padding: 16px 8px !important;
    }

        .footer-right-side .d-flex.flex-nowrap[b-f0151pmxg3] {
            flex-direction: column !important;
            gap: 16px !important;
        }

        .footer-right-side .col-auto[b-f0151pmxg3],
        .footer-right-side .col[b-f0151pmxg3] {
            width: 100% !important;
            flex: 1 1 100% !important;
        }

    .calculation-group[b-f0151pmxg3] {
        grid-template-columns: repeat(3, 1fr) !important;
        /* 3 columns on tablets too */
        width: 100% !important;
    }

    .payment-grid-container[b-f0151pmxg3] {
        height: auto !important;
        min-height: 200px;
        overflow-x: auto;
    }

    .history-grid-wrapper[b-f0151pmxg3] {
        height: auto !important;
        max-height: 200px;
    }

    .premium-card[b-f0151pmxg3] {
        margin-bottom: 12px;
    }
}

@media (max-width: 575.98px) {
    .calculation-group[b-f0151pmxg3] {
        grid-template-columns: repeat(3, 1fr) !important;
    }

        .calculation-group .d-flex[b-f0151pmxg3] {
            flex-direction: row !important;
            flex-wrap: nowrap !important;
            gap: 2px !important;
            align-items: flex-end !important;
            width: 100% !important;
        }

            .calculation-group .d-flex .e-btn[b-f0151pmxg3] {
                flex: 0 0 auto !important;
                width: 24px !important;
                height: 28px !important;
                padding: 0 !important;
            }

            .calculation-group .d-flex .e-control-wrapper[b-f0151pmxg3] {
                flex: 1 !important;
                min-width: 0 !important;
                width: auto !important;
            }

    .footer-actions-right[b-f0151pmxg3] {
        flex-direction: row !important;
        justify-content: flex-end !important;
        gap: 8px !important;
    }

    .footer-actions-right .e-btn[b-f0151pmxg3] {
        width: auto !important;
        flex: 1 !important;
    }

    .summary-rows-container[b-f0151pmxg3] {
        width: 100% !important;
        overflow-x: auto;
    }

    .page-content[b-f0151pmxg3] {
        padding: 4px 8px !important;
    }
}

.bg-light-green[b-f0151pmxg3] {
    background-color: #f0fdf4 !important;
}
/* /Components/Pages/Login.razor.rz.scp.css */
.login-page[b-n9hm1p47od] {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: #f8fafc;
    font-family: 'Inter', system-ui, sans-serif;
    position: relative;
    overflow: hidden;
}

.video-bg[b-n9hm1p47od] {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.video-overlay[b-n9hm1p47od] {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(2, 6, 23, 0.55);
    z-index: 1;
}

.login-container[b-n9hm1p47od] {
    width: 100%;
    max-width: 400px;
    z-index: 2;
}

.login-card[b-n9hm1p47od] {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(24px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 24px;
    padding: 40px 32px 24px 32px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    gap: 24px;
    text-align: center;
}

.brand-name[b-n9hm1p47od] {
    font-size: 1.8rem;
    font-weight: 800;
    color: #1e293b;
    margin: 0;
}

.login-content h2[b-n9hm1p47od] {
    font-size: 2.2rem;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 0.5rem;
    letter-spacing: -1px;
}

.login-content p[b-n9hm1p47od] {
    color: #475569;
    opacity: 0.9;
    margin-bottom: 2.5rem;
}

.form-group label[b-n9hm1p47od] {
    color: #1e293b !important;
    font-weight: 700;
}

.custom-login-input.e-input-group[b-n9hm1p47od] {
    background: rgba(0, 0, 0, 0.05) !important;
    border: 1px solid rgba(0, 0, 0, 0.1) !important;
    border-radius: 16px !important;
    color: #1e293b !important;
}

/* Force pure black font for the input text as requested */
[b-n9hm1p47od] .e-input-group.e-outline .e-input {
    color: #000000 !important;
    font-weight: 500 !important;
    background-color: transparent !important;
    transition: background-color 5000s ease-in-out 0s, color 5000s ease-in-out 0s !important;
}

/* Bold and darker color for the placeholder/floating label as requested */
[b-n9hm1p47od] .e-input-group.e-outline .e-float-text {
    font-weight: 700 !important;
    color: #475569 !important;
    /* Dark slate */
    font-size: 0.95rem !important;
}

/* Fix Google Autofill background hiding Syncfusion's rounded borders */
[b-n9hm1p47od] input:-webkit-autofill,
[b-n9hm1p47od] input:-webkit-autofill:hover,
[b-n9hm1p47od] input:-webkit-autofill:focus,
[b-n9hm1p47od] input:-webkit-autofill:active,
[b-n9hm1p47od] .e-input-group.e-outline .e-input:-webkit-autofill {
    transition: background-color 5000s ease-in-out 0s, color 5000s ease-in-out 0s !important;
    -webkit-text-fill-color: #000000 !important;
    background-color: transparent !important;
}

.custom-login-input .e-input[b-n9hm1p47od]::placeholder {
    color: rgba(0, 0, 0, 0.4) !important;
}

.remember-me[b-n9hm1p47od],
.forgot-password[b-n9hm1p47od] {
    color: #1e293b !important;
    font-weight: 600;
}

.forgot-password:hover[b-n9hm1p47od] {
    text-decoration: underline;
    color: var(--primary-color, #2563eb) !important;
}

.login-footer p[b-n9hm1p47od] {
    color: #64748b;
    font-weight: 500;
    margin: 0;
}

.btn-login[b-n9hm1p47od] {
    background: linear-gradient(135deg, var(--primary-color, #2563eb), #4f46e5) !important;
    border-radius: 18px !important;
    height: 56px !important;
    font-size: 1.1rem !important;
    box-shadow: 0 15px 30px rgba(37, 99, 235, 0.5) !important;
}



.brand-section[b-n9hm1p47od] {
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-logo-img[b-n9hm1p47od] {
    max-height: 52px;
    width: auto;
    object-fit: contain;
    display: block;
}

.login-content[b-n9hm1p47od] {
    text-align: center;
}

.login-content h2[b-n9hm1p47od] {
    font-size: 2rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.login-content p[b-n9hm1p47od] {
    color: #64748b;
    margin-bottom: 2rem;
}

.form-group[b-n9hm1p47od] {
    margin-bottom: 0.8rem;
    text-align: left;
}

.form-group label[b-n9hm1p47od] {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: #475569;
    margin-bottom: 0.8rem;
}

.custom-login-input.e-input-group[b-n9hm1p47od] {
    border-radius: 12px !important;
    border: 2px solid #e2e8f0 !important;
    background: rgba(248, 250, 252, 0.8) !important;
    padding: 2px 10px !important;
    transition: all 0.2s !important;
    height: 52px !important;
}

.custom-login-input.e-input-group.e-input-focus[b-n9hm1p47od] {
    border-color: var(--primary-color, #2563eb) !important;
    background: white !important;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1) !important;
}

.form-options[b-n9hm1p47od] {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.remember-me[b-n9hm1p47od] {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    color: #64748b;
    cursor: pointer;
}

.forgot-password[b-n9hm1p47od] {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--primary-color, #2563eb);
    text-decoration: none;
}

.btn-login[b-n9hm1p47od] {
    width: 100%;
    padding: 16px;
    background: var(--primary-color, #2563eb);
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 1rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 10px 15px -3px rgba(37, 99, 235, 0.2);
}

.btn-login:hover[b-n9hm1p47od] {
    transform: translateY(-2px);
    box-shadow: 0 20px 25px -5px rgba(37, 99, 235, 0.3);
}

.login-footer[b-n9hm1p47od] {
    text-align: center;
    font-size: 0.875rem;
    color: #94a3b8;
}

/* =====================
   LOGO SECTION
   ===================== */
.logo-section[b-n9hm1p47od] {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 10px;
    position: relative;
    z-index: 1;
}

/* Custom Popup Modal */
.custom-modal-overlay[b-n9hm1p47od] {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(2, 6, 23, 0.6);
    backdrop-filter: blur(8px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    animation: fadeIn-b-n9hm1p47od 0.3s ease-out forwards;
}

.custom-modal[b-n9hm1p47od] {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(24px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: 24px;
    padding: 40px;
    width: 90%;
    max-width: 420px;
    text-align: center;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
    transform: translateY(20px);
    animation: slideUp-b-n9hm1p47od 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.modal-icon[b-n9hm1p47od] {
    font-size: 3rem;
    margin-bottom: 20px;
}
.modal-icon.error[b-n9hm1p47od] { color: #dc2626; }
.modal-icon.warning[b-n9hm1p47od] { color: #f59e0b; }

.custom-modal h3[b-n9hm1p47od] {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1e293b;
    margin-bottom: 12px;
}

.custom-modal p[b-n9hm1p47od] {
    color: #475569;
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 30px;
}

@keyframes fadeIn-b-n9hm1p47od {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp-b-n9hm1p47od {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
