@import url('open-iconic/font/css/open-iconic-bootstrap.min.css');

html, body {
    font-family: Nunito,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";
}
    body:not(.rz-default-scrollbars)::-webkit-scrollbar {
        width: 8px;
    }

    body:not(.rz-default-scrollbars)::-webkit-scrollbar-track {
        background: #ffffff;
    }

    /* Handle */
    body:not(.rz-default-scrollbars)::-webkit-scrollbar-thumb {
        background: #888;
    }

        /* Handle on hover */
        body:not(.rz-default-scrollbars)::-webkit-scrollbar-thumb:hover {
            background: #555;
        }


    body:not(.rz-default-scrollbars)::-webkit-scrollbar {
        width: 8px;
    }

    body:not(.rz-default-scrollbars)::-webkit-scrollbar-track {
        background: #ffffff;
    }
h1:focus {
    outline: none;
}

a, .btn-link {
    color: #0071c1;
}
.pa-6 {
    padding: 0px !important;
}
.mud-table-root .mud-table-head {
    background: #f3f4f6;
}
hr {
    box-sizing: border-box;
    margin-top: 10px;
}
.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.content {
    padding-top: 1.1rem;
}
.sidebar {
    background: #111827;
}
.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid red;
}

.validation-message {
    color: red;
}
.ant-form-item-label {
    text-align:left;
}
#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

    #blazor-error-ui .dismiss {
        cursor: pointer;
        position: absolute;
        right: 0.75rem;
        top: 0.5rem;
    }

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm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Dg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }
.brand-text {
    text-transform: uppercase;
    line-height: 2.1;
    font-size: 1.5em;
}
    .brand-text h3 {
        color: #7c5cc4;
        font-weight: 600;
        font-size: 16px;
        margin-top: -22px;
    }
        .brand-text h3 span {
            font-weight: 500;
        }

span {
    display: inline-block;
}
.filter-toggle {
    float: right;
    list-style: none;
    margin-top: -8px;
}
.payment-options {
    background-color: #fff;
    bottom: 0;
    left: 0;
    padding: 0 10px;
    position: fixed;
    width: 100%;
    z-index: 1;
}
    .payment-options .column-5 {
        float: right;
        margin: 10px 0;
        padding: 0 5px;
    }
.loader {
    border: 16px solid silver;
    border-top: 16px solid orange;
    border-radius: 50%;
    width: 80px;
    height: 80px;
    animation: spin 700ms linear infinite;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    position: fixed;
}

.loading-container {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 999;
}
.loading-container2 {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

.loading-spinner2 {
    border: 16px solid #f3f3f3;
    border-radius: 50%;
    border-top: 16px solid #3498db;
    width: 120px;
    height: 120px;
    animation: spin2 2s linear infinite;
}

@keyframes spin2 {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Font Awesome Fallback and Fixes */
.fas, .fa {
  font-family: "Font Awesome 5 Free" !important;
  font-weight: 900 !important;
  font-style: normal !important;
  font-variant: normal !important;
  text-rendering: auto !important;
  -webkit-font-smoothing: antialiased !important;
  -moz-osx-font-smoothing: grayscale !important;
}

/* Specific fix for print icon */
.fa-print:before {
  content: "\f02f" !important;
}

/* Alternative: Use Unicode character as fallback */
.fa-print:before {
  content: "\f02f" !important;
}

/* If Font Awesome fails, show a text fallback */
.fa-print:before {
  content: "\f02f" !important;
}

/* Ensure icon elements are properly styled */
i.fas, i.fa {
  display: inline-block !important;
  width: auto !important;
  height: auto !important;
  line-height: 1 !important;
}

/* Modern Action Buttons for Accounting Users */
.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    margin: 0 4px;
    text-decoration: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    cursor: pointer;
    border: 1px solid transparent;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    min-width: 100px;
    justify-content: center;
}

.action-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
    text-decoration: none;
}

.action-btn i {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Print Button - Professional Gray */
.print-btn {
    background: linear-gradient(135deg, #6c757d, #5a6268);
    color: white;
    border-color: #5a6268;
}

.print-btn:hover {
    background: linear-gradient(135deg, #5a6268, #495057);
    color: white;
}

/* Edit/Update Button - Professional Blue */
.edit-btn {
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    border-color: #0056b3;
}

.edit-btn:hover {
    background: linear-gradient(135deg, #0056b3, #004085);
    color: white;
}

/* Approve Button - Success Green */
.approved-btn {
    background: linear-gradient(135deg, #28a745, #1e7e34);
    color: white;
    border-color: #1e7e34;
}

.approved-btn:hover {
    background: linear-gradient(135deg, #1e7e34, #155724);
    color: white;
}

/* Cancel Button - Danger Red */
.cancel-btn {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white;
    border-color: #c82333;
}

.cancel-btn:hover {
    background: linear-gradient(135deg, #c82333, #a71e2a);
    color: white;
}

/* Alternative: Flat Design (if you prefer) */
.action-btn-flat {
    background: white;
    border: 2px solid;
    box-shadow: none;
}

.action-btn-flat.print-btn {
    color: #6c757d;
    border-color: #6c757d;
}

.action-btn-flat.edit-btn {
    color: #007bff;
    border-color: #007bff;
}

.action-btn-flat.approved-btn {
    color: #28a745;
    border-color: #28a745;
}

.action-btn-flat.cancel-btn {
    color: #dc3545;
    border-color: #dc3545;
}

.action-btn-flat:hover {
    color: white;
    transform: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.action-btn-flat.print-btn:hover {
    background: #6c757d;
}

.action-btn-flat.edit-btn:hover {
    background: #007bff;
}

.action-btn-flat.approved-btn:hover {
    background: #28a745;
}

.action-btn-flat.cancel-btn:hover {
    background: #dc3545;
}

/* Responsive Design */
@media (max-width: 768px) {
    .action-btn {
        padding: 8px 12px;
        font-size: 13px;
        min-width: 80px;
        margin: 2px;
    }
    
    .action-btn i {
        width: 14px;
        height: 14px;
        font-size: 14px;
    }
}

/* Card Sales Split Container Styling */
.card-sales-split ul {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    justify-content: flex-end;
    margin: 0;
    padding: 0;
    list-style: none;
}

.card-sales-split li {
    margin: 0;
}

/* CSS-Only Icons using Unicode (Alternative to Font Awesome) */
.action-btn-css-only {
    position: relative;
    padding-left: 35px;
}

.action-btn-css-only::before {
    content: "";
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 16px;
    font-weight: normal;
}

.print-btn-css::before {
    content: "🖨";
}

.edit-btn-css::before {
    content: "✏";
}

.approved-btn-css::before {
    content: "✓";
}

.cancel-btn-css::before {
    content: "✕";
}

/* Alternative Unicode icons */
.print-btn-css-alt::before {
    content: "⎙";
}

.edit-btn-css-alt::before {
    content: "📝";
}

.approved-btn-css-alt::before {
    content: "✅";
}

.cancel-btn-css-alt::before {
    content: "❌";
}

/* Sales Invoice View Action Buttons */
.action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    justify-content: flex-end;
    margin: 0;
    padding: 0;
}

.btn-action {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    border: 2px solid;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: white;
    color: #333;
    min-width: 120px;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.btn-action:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
    text-decoration: none;
}

.btn-action i {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Print Button */
.btn-print {
    color: #6c757d;
    border-color: #6c757d;
}

.btn-print:hover {
    background: #6c757d;
    color: white;
}

/* Mail Button */
.btn-mail {
    color: #17a2b8;
    border-color: #17a2b8;
}

.btn-mail:hover {
    background: #17a2b8;
    color: white;
}

/* Update Button */
.btn-update {
    color: #007bff;
    border-color: #007bff;
}

.btn-update:hover {
    background: #007bff;
    color: white;
}

/* Approve Button */
.btn-approve {
    color: #28a745;
    border-color: #28a745;
}

.btn-approve:hover {
    background: #28a745;
    color: white;
}

/* Payment Button */
.btn-payment {
    color: #6f42c1;
    border-color: #6f42c1;
}

.btn-payment:hover {
    background: #6f42c1;
    color: white;
}

/* Debit Note Button */
.btn-debit {
    color: #fd7e14;
    border-color: #fd7e14;
}

.btn-debit:hover {
    background: #fd7e14;
    color: white;
}

/* Responsive Design for Action Buttons */
@media (max-width: 768px) {
    .action-buttons {
        justify-content: center;
        gap: 6px;
    }
    
    .btn-action {
        padding: 8px 12px;
        font-size: 13px;
        min-width: 100px;
        gap: 6px;
    }
    
    .btn-action i {
        width: 14px;
        height: 14px;
        font-size: 14px;
    }
}

/* Debit Note Reason Field Styling */
.debit-note-reason {
    border: 2px solid #fd7e14;
    background-color: #fff8f0;
    font-weight: 500;
}

.debit-note-reason:focus {
    border-color: #fd7e14;
    box-shadow: 0 0 0 0.2rem rgba(253, 126, 20, 0.25);
}

.debit-note-reason-label {
    color: #fd7e14;
    font-weight: 600;
}

/* Sales Order Info Styling */
.sales-order-info {
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 15px;
    margin: 10px 0;
}

.sales-order-info p {
    margin-bottom: 8px;
    font-size: 14px;
}

.sales-order-info p:last-child {
    margin-bottom: 0;
}

.sales-order-info strong {
    color: #495057;
    min-width: 100px;
    display: inline-block;
}

/* ================================
   DASHBOARD STYLING
   ================================ */

/* Dashboard Header */
.dashboard-header h2 {
    color: #2c3e50;
    font-weight: 600;
}

/* Date Filter Buttons */
.date-filter-group .btn {
    border-radius: 0;
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

    .date-filter-group .btn:first-child {
        border-top-left-radius: 0.375rem;
        border-bottom-left-radius: 0.375rem;
    }

    .date-filter-group .btn:last-child {
        border-top-right-radius: 0.375rem;
        border-bottom-right-radius: 0.375rem;
    }

    .date-filter-group .btn:hover {
        transform: translateY(-1px);
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    }

.date-btn i {
    font-size: 0.8rem;
}

/* Dashboard Metric Cards Enhancement */
.dash-widget {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

    .dash-widget:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    }

/* Bank Balance Styling */
.bank-account-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f1f3f4;
    transition: background-color 0.2s ease;
}

    .bank-account-item:last-child {
        border-bottom: none;
    }

    .bank-account-item:hover {
        background-color: #f8f9fa;
        border-radius: 4px;
        margin: 0 -0.5rem;
        padding: 0.75rem 0.5rem;
    }

.account-name {
    font-weight: 500;
    color: #495057;
}

.account-balance {
    font-weight: 600;
}

    .account-balance.positive {
        color: #28a745;
    }

    .account-balance.negative {
        color: #dc3545;
    }

/* Chart Card Enhancements */
.card {
    transition: box-shadow 0.2s ease;
}

    .card:hover {
        box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    }

/* Responsive Design */
@media (max-width: 768px) {
    .date-filter-group {
        width: 100%;
    }

        .date-filter-group .btn {
            flex: 1;
            font-size: 0.75rem;
            padding: 0.4rem 0.5rem;
        }

    .date-btn i {
        display: none;
    }

    .dash-widget {
        margin-bottom: 1rem;
    }

    .bank-account-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }
}

