* {
    font-family: IRANSans-web;
}

/* این بخش ظاهر عمومی فیلدهای تاریخ شمسی و آیکون تقویم را تنظیم می‌کند. */
.contract-date-group {
    display: flex;
    width: 100%;
    direction: rtl;
}

.contract-date-input {
    flex: 1 1 auto;
    min-width: 0;
    border-left: 0;
    border-radius: 0 0.375rem 0.375rem 0 !important;
    text-align: right;
}

.contract-date-button {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    color: #495057;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.375rem 0 0 0.375rem !important;
    cursor: pointer;
}

    .contract-date-button:hover {
        color: #0d6efd;
        background-color: #e9ecef;
    }



/* این بخش گوشه‌های نوارهای جستجوی RTL را بر اساس ترتیب بصری صفحه تنظیم می‌کند.
   قانون فقط روی کلاس اختصاصی rtl-search-group اعمال می‌شود تا سایر input-groupها تغییر نکنند. */
.rtl-search-group {
    direction: rtl;
}

/* ورودی در سمت راست قرار می‌گیرد و فقط گوشه‌های بیرونی سمت راست را دارد. */
.rtl-search-group > :first-child {
    border-top-right-radius: 0.375rem !important;
    border-bottom-right-radius: 0.375rem !important;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}

/* اجزای میانی بدون فاصله و با هم‌پوشانی مرزها کنار هم قرار می‌گیرند. */
.rtl-search-group > :not(:first-child) {
    margin-left: 0 !important;
    margin-right: calc(var(--bs-border-width, 1px) * -1) !important;
    border-radius: 0 !important;
}

/* دکمه/آیکون در سمت چپ قرار می‌گیرد و فقط گوشه‌های بیرونی سمت چپ را دارد. */
.rtl-search-group > :last-child {
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    border-top-left-radius: 0.375rem !important;
    border-bottom-left-radius: 0.375rem !important;
}
/*.swal2-container .swal2-popup.swal2-toast {
    box-sizing: border-box !important;
    width: max-content !important;
    min-width: 320px !important;
    max-width: calc(100vw - 32px) !important;
    padding: 0.75rem 1rem !important;
    direction: rtl !important;
}

    .swal2-container .swal2-popup.swal2-toast .swal2-title,
    .swal2-container .swal2-popup.swal2-toast .swal2-html-container {
        width: auto !important;
        margin-inline: 8px !important;
        padding: 0 !important;
        white-space: nowrap !important;
        text-align: right !important;
    }*/
/* جلوگیری از بیرون‌زدگی در نمایشگرهای کوچک */
/*@media (max-width: 768px) {
    .swal2-container .swal2-popup.swal2-toast {
        width: calc(100vw - 32px) !important;
        min-width: 0 !important;
    }

        .swal2-container .swal2-popup.swal2-toast .swal2-title,
        .swal2-container .swal2-popup.swal2-toast .swal2-html-container {
            max-width: 100% !important;
            white-space: normal !important;
            overflow-wrap: anywhere !important;
        }
}*/
/* 
   Override کردن بج‌های سیستم برای تبدیل به حالت Outline 
   مهرداد عزیز، این کد تمام بج‌هایی که کلاس bg-*-light دارند را هدف قرار می‌دهد
*/
/* 1. تنظیمات پایه برای تمام بج‌ها */
.badge {
    border-width: 1px;
    border-style: solid;
    font-weight: 600 !important;
    padding: 0.5em 0.75em !important;
}

    /* 2. هدف قرار دادن ترکیب کلاس‌های رنگی OneUI/Bootstrap */

    /* حالت Primary (مثلاً مدیر سیستم) */
    .badge.bg-primary-light {
        background-color: #ffffff !important; /* پس‌زمینه سفید */
        color: #0665d0 !important; /* رنگ متن اصلی */
        border-color: rgba(6, 101, 208, 0.5) !important; /* خط دور نیمه‌شفاف */
    }

    /* حالت Success (مثلاً پرداخت شده) */
    .badge.bg-success-light {
        background-color: #ffffff !important;
        color: #198754 !important;
        border-color: rgba(25, 135, 84, 0.5) !important;
    }

    /* حالت Warning (مثلاً در انتظار یا بدون نقش) */
    .badge.bg-warning-light {
        background-color: #ffffff !important;
        color: #856404 !important;
        border-color: rgba(255, 193, 7, 0.6) !important;
    }

    /* حالت Danger (مثلاً فاکتور ابطال شده) */
    .badge.bg-danger-light {
        background-color: #ffffff !important;
        color: #d22d2d !important;
        border-color: rgba(210, 45, 45, 0.5) !important;
    }

    /* حالت Info */
    .badge.bg-info-light {
        background-color: #ffffff !important;
        color: #0b5766 !important;
        border-color: rgba(13, 202, 240, 0.5) !important;
    }

    /* 3. حذف کلاس‌های رنگ متن اضافه اگر همراه بج آمده باشند */
    /* گاهی بوت‌استرپ کلاس text-primary هم اضافه می‌کند که ممکن است تداخل ایجاد کند */
    .badge[class*="bg-"][class*="-light"] {
        box-shadow: none !important;
    }




.badge-uniform {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100px; /* عرض ثابت و یکسان برای همه بج‌ها */
    height: 28px; /* ارتفاع ثابت و دقیق */
    font-size: 11.5px; /* اندازه فونت خوانا و متناسب */
    font-weight: 600; /* ضخامت متن برای وضوح بیشتر */
    gap: 6px; /* فاصله استاندارد بین آیکون و متن */
    border-radius: 6px; /* گوشه‌های نرم و مدرن مطابق OneUI */
}

/* اصلاح جهت فلش دراپ‌داون در حالت RTL */
.form-select {
    background-position: left 0.75rem center !important;
    padding-left: 2.25rem !important;
    padding-right: 0.75rem !important;
}
/*.input-group {
    border-top-right-radius: 5px !important;
    border-bottom-right-radius: 5px !important;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}*/

/* برای ایجاد نشان‌های دایره‌ای و هم‌اندازه */
.badge-stat {
    width: 28px; /* عرض ثابت */
    height: 28px; /* ارتفاع ثابت */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0; /* حذف پدینگ پیش‌فرض نشان‌ها */
    border-radius: 50%; /* اگر دایره‌ای می‌خواهی 50% و اگر مربعی با گوشه گرد می‌خواهی 4px */
    font-size: 0.85rem;
    font-weight: 700;
}
.text-justify{
    text-align:justify;
}

.btn {
    font-weight: normal !important;
}
.pwt-btn-calendar {
    display: none !important;
}

#toast-container > div {
    width: auto !important;
    max-width: none !important;
    /*display: inline-block !important;*/
    direction:rtl;
}

.form-control {
    font-family: 'IRANSans-web';
/*    border-top-left-radius:0;
    border-bottom-left-radius:0;
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;*/
}
/*.input-group > :not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback) {
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
    border-top-right-radius: 5px !important;
    border-bottom-right-radius: 5px !important;
}*/

.rtl-search-group .search-input {
    border-top-right-radius: 0.5rem !important;
    border-bottom-right-radius: 0.5rem !important;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}

/*.input-group .input-group-text {
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    border-top-left-radius: .5rem !important;
    border-bottom-left-radius: .5rem !important;
}*/

.rtl-search-group .search-input:focus {
    position: relative;
    z-index: 3;
    border-color: #86b7fe;
    box-shadow: none;
}

.rtl-search-group:focus-within {
    border-radius: .5rem;
}

/* این بخش ظاهر فیلدهای تاریخ در فرم‌های RTL را یکسان می‌کند.
   ورودی در سمت راست و دکمه تقویم در سمت چپ قرار می‌گیرد. */
.rtl-date-group {
    display: flex;
    width: 100%;
    direction: rtl;
    flex-wrap: nowrap;
}

.rtl-date-group > .contract-date-input {
    flex: 1 1 auto;
    min-width: 0;
    text-align: right;
    border-top-right-radius: 0.375rem !important;
    border-bottom-right-radius: 0.375rem !important;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}

.rtl-date-group > .contract-date-button {
    flex: 0 0 48px;
    min-height: calc(1.5em + 0.75rem + 2px);
    margin-right: -1px;
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    border-top-left-radius: 0.375rem !important;
    border-bottom-left-radius: 0.375rem !important;
}

/* این بخش جستجوی هدر را مستقل از RTL فرم‌های داخلی، به‌صورت استاندارد LTR نگه می‌دارد. */
.standard-header-search {
    direction: ltr;
    width: min(320px, 32vw);
}

.standard-header-search > .form-control {
    min-width: 0;
    border-top-left-radius: 0.5rem !important;
    border-bottom-left-radius: 0.5rem !important;
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

.standard-header-search > .input-group-text {
    flex: 0 0 44px;
    justify-content: center;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
    border-top-right-radius: 0.5rem !important;
    border-bottom-right-radius: 0.5rem !important;
    border-left: 1px solid #e9ecef !important;
}

.standard-header-search:focus-within > .form-control {
    position: relative;
    z-index: 2;
    box-shadow: none;
}

.standard-login-group {
    direction: ltr;
}

.standard-login-group > .input-group-text {
    flex: 0 0 48px;
    justify-content: center;
    border-top-left-radius: 0.375rem !important;
    border-bottom-left-radius: 0.375rem !important;
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

.standard-login-group > .form-control {
    min-width: 0;
    direction: ltr;
    text-align: left;
    border-radius: 0 !important;
}

.standard-login-group:not(.password-group) > .form-control {
    border-top-right-radius: 0.375rem !important;
    border-bottom-right-radius: 0.375rem !important;
}

.standard-login-group > .password-toggle {
    flex: 0 0 48px;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
    border-top-right-radius: 0.375rem !important;
    border-bottom-right-radius: 0.375rem !important;
}

.standard-login-group:focus-within > .form-control {
    position: relative;
    z-index: 2;
}
/* گروه رمز در صفحات RTL مانند جستجوی هدر، ترتیب استاندارد ورودی و آیکن را حفظ می‌کند. */
.standard-password-group {
    direction: ltr;
}

.standard-password-group > .form-control {
    min-width: 0;
    direction: ltr;
    text-align: left;
    border-top-left-radius: 0.375rem !important;
    border-bottom-left-radius: 0.375rem !important;
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

.standard-password-group > .password-toggle {
    flex: 0 0 46px;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
    border-top-right-radius: 0.375rem !important;
    border-bottom-right-radius: 0.375rem !important;
}

.standard-password-group:focus-within > .form-control {
    position: relative;
    z-index: 2;
}

/* پیام جستجوی منوی کناری وقتی آیتم مطابق پیدا نمی‌شود. */
.header-menu-search-empty {
    list-style: none;
    padding: 0.75rem 1rem;
    opacity: 0.85;
}

.header-menu-search-empty .nav-main-link {
    cursor: default;
    pointer-events: none;
}

/* نمایش سازمان و نقش فعال در هدر و منوی پروفایل. */
.header-user-context {
    min-width: 0;
    width: 190px;
    max-width: 190px;
    line-height: 1.35;
    text-align: center !important;
}

.header-user-button {
    width: 285px;
    min-width: 285px;
    min-height: 54px;
    overflow: hidden;
    justify-content: center;
    text-align: center;
}

.header-user-name,
.header-user-organization {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.header-user-name {
    font-size: 0.88rem;
}

.header-user-organization {
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.72rem;
}

.header-user-name,
.header-user-organization {
    text-align: center;
}

.active-organization-card {
    border-color: rgba(13, 110, 253, 0.16) !important;
    background: linear-gradient(135deg, #f7fbff 0%, #ffffff 100%) !important;
    line-height: 1.45;
    text-align: center !important;
}

.active-context-label {
    color: #6c757d;
    font-size: 0.72rem;
    font-weight: 600;
}

.active-context-organization {
    margin-top: 0.3rem;
    color: #26364a;
    font-size: 0.96rem;
    font-weight: 700;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: center;
}

.active-context-role {
    display: flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    max-width: 100%;
    margin-top: 0.5rem;
    margin-right: auto;
    margin-left: auto;
    padding: 0.25rem 0.6rem;
    color: #087990;
    font-size: 0.76rem;
    font-weight: 600;
    background: #e8f8fc;
    border-radius: 999px;
}

/*
   تنظیم پنجره‌های معمولی SweetAlert.
   Toast اعلان است و نباید این عرض ثابت را از پنجره‌های معمولی به ارث ببرد.
*/
.swal2-popup:not(.swal2-toast) {
    width: min(92vw, 760px) !important;
    max-width: min(92vw, 760px) !important;
    box-sizing: border-box !important;
}

.swal2-popup:not(.swal2-toast) .swal2-title,
.swal2-popup:not(.swal2-toast) .swal2-html-container,
.swal2-popup:not(.swal2-toast) .swal2-content {
    max-width: 100% !important;
    white-space: normal !important;
    word-break: normal !important;
    overflow-wrap: break-word !important;
    overflow: visible !important;
    text-align: center !important;
    line-height: 1.8 !important;
}

.swal2-popup:not(.swal2-toast) .swal2-title {
    margin-right: auto !important;
    margin-left: auto !important;
    font-size: clamp(1rem, 2.1vw, 1.35rem) !important;
}

@media (max-width: 575.98px) {
    .header-user-context {
        width: 118px;
        max-width: 118px;
    }

    .header-user-button {
        width: 200px;
        min-width: 200px;
        min-height: 50px;
    }

    .header-user-name {
        font-size: 0.8rem;
    }

    .header-user-organization {
        font-size: 0.66rem;
    }
}

@media (max-width: 575.98px) {
    .standard-header-search {
        width: 100%;
    }
}


.badge {
    font-size:14px;
}
html {
    font-size: 14px;
}
.NotRtl{
    direction:ltr !important;
    text-align:left !important;
}

/* Keep grouped fields aligned and prevent controls from overflowing on narrow screens. */
.input-group {
    display: flex;
    flex-wrap: nowrap;
    /* Follow the page direction: in RTL the first field stays on the right and its action on the left. */
    flex-direction: row;
    align-items: stretch;
    width: 100%;
}

.input-group > .form-control,
.input-group > .form-select {
    flex: 1 1 0%;
    width: 1%;
    min-width: 0;
}

.input-group > .input-group-text {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}

.input-group > button.input-group-text {
    color: var(--bs-secondary-color, #6c757d);
    background-color: #fff;
    border: var(--bs-border-width, 1px) solid var(--bs-border-color, #dee2e6);
}

.input-group > button.input-group-text:not(:disabled) { cursor: pointer; }
.input-group > button.input-group-text:not(:disabled):hover { color: var(--bs-primary, #0d6efd); }

/* Match the joined edges and outer corners for RTL date and search groups. */
[dir="rtl"] .input-group > :first-child {
    border-top-right-radius: var(--bs-border-radius, .375rem) !important;
    border-bottom-right-radius: var(--bs-border-radius, .375rem) !important;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
}

[dir="rtl"] .input-group > :last-child {
    border-top-left-radius: var(--bs-border-radius, .375rem) !important;
    border-bottom-left-radius: var(--bs-border-radius, .375rem) !important;
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}

[dir="rtl"] .input-group > .input-group-text:last-child {
    border-right-width: 0;
}

[dir="rtl"] .input-group > .input-group-text:last-child > .btn {
    border-radius: inherit;
}

/* The header uses a separate search group; keep its input on the right and magnifier on the left. */
[dir="rtl"] .standard-header-search {
    direction: rtl;
    flex-direction: row;
}

[dir="rtl"] .standard-header-search > .form-control {
    direction: rtl;
    text-align: right;
    border-radius: 0 var(--bs-border-radius, .375rem) var(--bs-border-radius, .375rem) 0 !important;
}

[dir="rtl"] .standard-header-search > .input-group-text {
    border-radius: var(--bs-border-radius, .375rem) 0 0 var(--bs-border-radius, .375rem) !important;
    border-right: 0 !important;
}

/* Keep admin password input groups aligned and joined consistently in RTL pages. */
[dir="rtl"] .standard-password-group {
    direction: ltr;
    flex-direction: row;
}

[dir="rtl"] .standard-password-group > .form-control {
    min-width: 0;
    direction: ltr;
    text-align: left;
    border-radius: var(--bs-border-radius, .375rem) 0 0 var(--bs-border-radius, .375rem) !important;
}

[dir="rtl"] .standard-password-group > .password-toggle {
    flex: 0 0 46px;
    border-radius: 0 var(--bs-border-radius, .375rem) var(--bs-border-radius, .375rem) 0 !important;
}

.default-contracts-page {
    min-width: 0;
}

.default-contracts-table {
    min-width: 620px;
    margin-bottom: 0;
}

@media (max-width: 575.98px) {
    .default-contract-actions .btn {
        width: 100%;
    }

    .default-contracts-page h3 {
        font-size: 1.25rem;
        line-height: 1.5;
    }
}

/* GataLab AI assistant widget */
.gata-assistant {
    position: fixed;
    left: 1.25rem;
    bottom: 1.25rem;
    z-index: 1030;
    direction: rtl;
}

.gata-assistant-toggle {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    border: 0;
    border-radius: 999px;
    padding: .55rem .75rem;
    color: #fff;
    background: linear-gradient(135deg, #1261a0, #0b8f87);
    box-shadow: 0 .5rem 1.5rem rgba(18, 97, 160, .28);
    font-size: .875rem;
    font-weight: 600;
    cursor: pointer;
}

.gata-assistant-toggle-icon {
    font-size: 1.1rem;
}

.gata-assistant-panel {
    position: absolute;
    left: 0;
    bottom: 3.5rem;
    display: flex;
    flex-direction: column;
    width: min(370px, calc(100vw - 2rem));
    height: min(540px, calc(100vh - 6rem));
    overflow: hidden;
    border: 1px solid rgba(18, 97, 160, .15);
    border-radius: 1rem;
    background: var(--bs-body-bg, #fff);
    box-shadow: 0 1rem 3rem rgba(0, 0, 0, .2);
}

.gata-assistant-processing[hidden] {
    display: none !important;
}

.gata-assistant-processing {
    position: absolute;
    inset: 4.35rem 0 0;
    z-index: 20;
    isolation: isolate;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.25rem;
    overflow: hidden;
    background:
        radial-gradient(circle at 50% 38%, rgba(255, 190, 244, .2), transparent 30%),
        linear-gradient(145deg, rgba(8, 38, 78, .94), rgba(8, 119, 132, .95));
    backdrop-filter: blur(6px);
}

.gata-assistant-processing::before,
.gata-assistant-processing::after {
    position: absolute;
    z-index: -1;
    content: "";
    width: 165%;
    height: 58%;
    left: -32%;
    border-radius: 45%;
    opacity: .85;
    filter: blur(13px);
    transform: rotate(-9deg);
    pointer-events: none;
}

.gata-assistant-processing::before {
    top: 10%;
    background: linear-gradient(90deg, rgba(103, 215, 255, .16), rgba(255, 177, 238, .82), rgba(103, 215, 255, .2));
    animation: gata-assistant-wave 7s ease-in-out infinite alternate;
}

.gata-assistant-processing::after {
    bottom: 4%;
    background: linear-gradient(90deg, rgba(255, 176, 241, .18), rgba(80, 223, 255, .7), rgba(255, 176, 241, .18));
    animation: gata-assistant-wave-reverse 9s ease-in-out infinite alternate;
}

.gata-assistant-processing-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: min(250px, 90%);
    padding: 1.25rem 1rem 1.4rem;
    border: 1px solid rgba(255, 255, 255, .35);
    border-radius: 1.5rem;
    color: #fff;
    text-align: center;
    background: linear-gradient(160deg, rgba(255, 255, 255, .2), rgba(255, 255, 255, .07));
    box-shadow: 0 1rem 2.5rem rgba(0, 0, 0, .28), inset 0 1px rgba(255, 255, 255, .25);
    cursor: default;
}

.gata-assistant-processing-gif {
    display: block;
    width: 132px;
    height: 132px;
    margin-bottom: .35rem;
    object-fit: contain;
    filter: drop-shadow(0 0 1.1rem rgba(106, 226, 255, .65));
}

.gata-assistant-processing-card strong {
    font-size: 1rem;
}

.gata-assistant-processing-card span {
    margin-top: .35rem;
    color: rgba(255, 255, 255, .82);
    font-size: .8rem;
}

.gata-assistant.is-busy .gata-assistant-form textarea,
.gata-assistant.is-busy .gata-assistant-form button {
    cursor: wait;
}

.gata-assistant.is-recording .gata-assistant-processing,
.gata-assistant.is-recording .gata-assistant-processing-card {
    cursor: pointer;
}

.gata-assistant.is-recording .gata-assistant-processing-card {
    box-shadow: 0 1rem 2.5rem rgba(0, 0, 0, .28), 0 0 2rem rgba(255, 180, 244, .2), inset 0 1px rgba(255, 255, 255, .25);
}

@keyframes gata-assistant-wave {
    from { transform: translate3d(-5%, -5%, 0) rotate(-9deg) scale(1); }
    to { transform: translate3d(9%, 8%, 0) rotate(7deg) scale(1.12); }
}

@keyframes gata-assistant-wave-reverse {
    from { transform: translate3d(8%, 7%, 0) rotate(7deg) scale(1.08); }
    to { transform: translate3d(-8%, -4%, 0) rotate(-8deg) scale(1); }
}

.gata-assistant-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 1rem;
    color: #fff;
    background: linear-gradient(135deg, #1261a0, #0b8f87);
}

.gata-assistant-header small {
    display: block;
    margin-top: .25rem;
    opacity: .82;
    font-size: .72rem;
}

.gata-assistant-close {
    border: 0;
    color: #fff;
    background: transparent;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
}

.gata-assistant-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
    background: rgba(127, 127, 127, .06);
}

.gata-assistant-message {
    display: block;
    box-sizing: border-box;
    width: 88%;
    max-width: 88%;
    margin-bottom: .7rem;
    padding: .65rem .8rem;
    border-radius: .8rem;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    line-height: 1.8;
    font-size: .9rem;
    direction: rtl !important;
    text-align: right !important;
    unicode-bidi: embed;
}

.gata-assistant-message > span {
    display: block;
    width: 100%;
    direction: rtl;
    text-align: right;
    unicode-bidi: embed;
}

.gata-assistant-message.assistant {
    margin-left: auto;
    background: var(--bs-body-bg, #fff);
    border: 1px solid rgba(127, 127, 127, .18);
}

.gata-assistant-message.user {
    margin-right: auto;
    color: #fff;
    background: #1261a0;
}

.gata-assistant-form {
    display: flex;
    align-items: stretch;
    gap: .5rem;
    padding: .75rem;
    border-top: 1px solid rgba(127, 127, 127, .18);
}

.gata-assistant-form textarea {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
    min-height: 42px;
    padding: .55rem .75rem;
    border: 1px solid #d9dee5;
    border-radius: .75rem;
    background: var(--bs-body-bg, #fff);
    direction: rtl;
    text-align: right;
    box-shadow: none;
    resize: vertical;
}

.gata-assistant-form textarea:focus {
    border-color: #9aa8b8;
    box-shadow: 0 0 0 .15rem rgba(13, 202, 240, .12);
    outline: none;
}

.gata-assistant-send {
    flex: 0 0 46px;
    width: 46px;
    min-height: 42px;
    height: auto;
    padding: 0;
    border-radius: .65rem;
    font-size: 1.1rem;
}

.gata-assistant-mic {
    flex: 0 0 46px;
    width: 46px;
    min-height: 42px;
    height: auto;
    padding: 0;
    border-radius: .65rem;
    font-size: 1rem;
}

.gata-assistant-mic.is-recording {
    color: #fff;
    background-color: #dc3545;
    border-color: #dc3545;
    animation: gata-assistant-pulse 1.2s infinite;
}

@keyframes gata-assistant-pulse {
    50% { box-shadow: 0 0 0 .35rem rgba(220, 53, 69, .18); }
}

@media (max-width: 575.98px) {
    .gata-assistant {
        right: auto;
        left: .75rem;
        bottom: .75rem;
    }

    .gata-assistant-toggle {
        width: 2.9rem;
        height: 2.9rem;
        padding: 0;
        justify-content: center;
        gap: 0;
    }

    .gata-assistant-toggle > span:not(.gata-assistant-toggle-icon) {
        position: absolute;
        width: 1px;
        height: 1px;
        padding: 0;
        margin: -1px;
        overflow: hidden;
        clip: rect(0, 0, 0, 0);
        white-space: nowrap;
        border: 0;
    }

    .gata-assistant-toggle-icon {
        font-size: 1.25rem;
    }

    .gata-assistant-panel {
        right: auto;
        left: 0;
        width: min(370px, calc(100vw - 1.5rem));
    }
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  /*margin-bottom: 60px;*/
}


/* حل مشکل چیدمان فیلد جستجو در حالت RTL بدون تغییر HTML */

/* ۱. برگرداندن گردی لبه‌ها به آیکون (که در RTL در سمت راست قرار دارد) */
/*[dir="rtl"] .input-group > .form-control + .input-group-text {
    border-top-right-radius: 0.375rem !important;*/ /* مقدار استاندارد BS5 */
    /*border-bottom-right-radius: 0.375rem !important;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
    border-right: 1px solid #dfe3ea !important;*/ /* اگر مرز بینشان دیده نمی‌شود */
/*}*/

/* ۲. اصلاح لبه‌های اینپوت (که در RTL در سمت چپ قرار دارد) */
/*[dir="rtl"] .input-group > .form-control:first-child {
    border-top-left-radius: 0.375rem !important;
    border-bottom-left-radius: 0.375rem !important;
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
}*/

/* ۳. رفع تداخل بصری form-control-alt */
/*[dir="rtl"] .form-control-alt {
    padding-right: 0.75rem !important;
    padding-left: 0.75rem !important;
}*/

/* گزارش‌ها */
.report-export-excel,
.report-export-pdf,
.report-filter-button,
.report-clear-button {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
}

.report-filter-button {
    color: #3568a8;
    background: #dceaf9;
    border-color: #c6dcf3;
}

.report-filter-button:hover,
.report-filter-button:focus {
    color: #28558c;
    background: #c9def4;
}

.report-filter-form .contract-date-group {
    width: 100%;
    min-width: 205px;
    display: flex;
}

.report-filter-form .contract-date-input {
    min-width: 0;
    flex: 1 1 auto;
    white-space: nowrap;
}

.report-filter-form .contract-date-button {
    flex: 0 0 54px;
}

.report-filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-inline: 0;
}

.report-filter-field {
    flex: 1 1 159px;
    min-width: 0;
}

.report-filter-date {
    flex: 0 1 220px;
}

.report-filter-lab,
.report-filter-clinic {
    flex-basis: 159px;
}

.report-filter-actions {
    flex: 0 0 100%;
    align-self: flex-end;
    justify-content: flex-end;
}

.report-filter-form.report-filter-cartable {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    align-items: end;
    gap: 1rem;
    margin-inline: 0;
}

.report-filter-cartable .report-filter-field {
    width: 100%;
}

.report-filter-cartable .form-check {
    min-height: 38px;
    display: flex;
    align-items: center;
    gap: .5rem;
    margin-bottom: 0;
}

.report-filter-cartable .form-check-input {
    float: none;
    flex: 0 0 auto;
    margin: 0;
}

.report-filter-cartable .report-filter-actions {
    grid-column: 1 / -1;
}

@media (max-width: 991.98px) {
    .report-filter-form.report-filter-cartable {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767.98px) {
    .report-filter-field,
    .report-filter-date,
    .report-filter-lab,
    .report-filter-clinic,
    .report-filter-actions {
        flex: 1 1 100%;
    }

    .report-filter-actions {
        justify-content: flex-start;
    }

    .report-filter-form.report-filter-cartable {
        grid-template-columns: minmax(0, 1fr);
    }

    .report-filter-cartable .report-filter-actions {
        grid-column: auto;
    }
}

.report-export-excel {
    color: #267a4b;
    background: #d9f2e2;
    border-color: #c1e8d0;
}

.report-export-excel:hover,
.report-export-excel:focus {
    color: #1d623c;
    background: #c7ebd4;
}

.report-export-pdf {
    color: #b65368;
    background: #f9dfe5;
    border-color: #f1cbd4;
}

.report-export-pdf:hover,
.report-export-pdf:focus {
    color: #963e53;
    background: #f4ccd5;
}

.report-filter-button,
.report-clear-button {
    flex: 0 0 44px;
}
.ticket-upload-zone {
    border: 2px dashed #c9d3e1;
    border-radius: 14px;
    background: linear-gradient(180deg, #fbfdff 0%, #f4f8fc 100%);
    min-height: 150px;
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: border-color .2s ease, background-color .2s ease, box-shadow .2s ease;
}
.ticket-upload-zone:hover,
.ticket-upload-zone:focus,
.ticket-upload-zone.is-dragover {
    border-color: #3b82f6;
    background: #eef6ff;
    box-shadow: 0 0 0 4px rgba(59,130,246,.10);
    outline: none;
}
.ticket-upload-icon { color: #3b82f6; font-size: 28px; margin-bottom: 8px; }
.ticket-upload-title { color: #26364a; font-weight: 700; }
.ticket-upload-subtitle { color: #718096; font-size: .875rem; margin-top: 5px; }
.ticket-file-list { max-width: 560px; margin-inline: auto; text-align: start; }
.ticket-file-item { display: flex; gap: 8px; align-items: center; background: #fff; border: 1px solid #e2e8f0; border-radius: 8px; padding: 7px 10px; margin-top: 6px; color: #334155; }
.ticket-file-item i { color: #3b82f6; }
.ticket-file-item span { margin-inline-start: auto; color: #94a3b8; font-size: .8rem; }
.ticket-file-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ticket-file-remove { margin-inline-start: 8px; border: 0; background: transparent; color: #dc3545; cursor: pointer; padding: 2px 5px; }
.ticket-file-remove:hover { color: #a71d2a; }
.ticketing-page { --ticket-navy: #101b33; --ticket-navy-2: #172746; --ticket-orange: #f28c28; }
.ticketing-page .block { border: 1px solid #263858; background: #111d35; color: #eef4ff; box-shadow: 0 12px 30px rgba(8,15,31,.16); }
.ticketing-page .block-header { background: linear-gradient(135deg, var(--ticket-navy), var(--ticket-navy-2)); border-bottom: 1px solid #30466b; }
.ticketing-page .block-title, .ticketing-page label, .ticketing-page strong { color: #fff; }
.ticketing-page .table { color: #e9effb; }
.ticketing-page .table tbody td { color: #18243b !important; }
.ticketing-page .table thead th { color: #ffb15f; border-bottom-color: #3a4d70; }
.ticketing-page .table-striped > tbody > tr:nth-of-type(odd) > * { color: #18243b !important; background-color: rgba(39,58,91,.38); }
.ticketing-page .form-control, .ticketing-page .form-select { background-color: #f8fafc; color: #18243b; border-color: #64789c; }
.ticketing-page .btn-primary, .ticketing-page .btn-ticket-orange { background: var(--ticket-orange); border-color: var(--ticket-orange); color: #1b2437; font-weight: 700; }
.ticketing-page .btn-primary:hover, .ticketing-page .btn-ticket-orange:hover { background: #ffab4e; border-color: #ffab4e; }
.ticketing-page .ticket-upload-zone { background: linear-gradient(180deg, #172846 0%, #101c34 100%); border-color: #526b97; }
.ticketing-page .ticket-upload-zone:hover, .ticketing-page .ticket-upload-zone:focus, .ticketing-page .ticket-upload-zone.is-dragover { background: #1c3155; border-color: var(--ticket-orange); box-shadow: 0 0 0 4px rgba(242,140,40,.15); }
.ticketing-page .ticket-upload-title, .ticketing-page .ticket-upload-subtitle { color: #f5f8ff; }
.ticketing-page .ticket-upload-subtitle { color: #b8c6df; }
.ticketing-page .ticket-upload-icon { color: var(--ticket-orange); }
.ticketing-page .ticket-file-item { background: #f8fafc; color: #17243c; }
.ticket-create-actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
@media (max-width: 767.98px) {
    .ticket-create-page { padding-bottom: 5.5rem; }
    .ticket-create-actions {
        position: fixed;
        z-index: 1050;
        left: 0;
        right: 0;
        bottom: 0;
        padding: .75rem 1rem;
        background: rgba(17, 29, 53, .97);
        border-top: 1px solid #526b97;
        box-shadow: 0 -6px 18px rgba(8, 15, 31, .2);
    }
    .ticket-create-actions .btn { min-height: 44px; }
}
.ticket-success-card { max-width: 680px; margin: 4rem auto; padding: 3rem 2rem; text-align: center; border: 1px solid #2e4268; border-radius: 18px; background: linear-gradient(135deg, #101b33, #1b3155); color: #fff; box-shadow: 0 16px 38px rgba(8,15,31,.25); }
.ticket-success-icon { width: 72px; height: 72px; margin: 0 auto 1.25rem; display: grid; place-items: center; border-radius: 50%; background: var(--ticket-orange); color: #15213a; font-size: 2rem; }
.ticket-success-card h2 { color: #fff; }
.ticket-success-card .text-muted { color: #c5d0e4 !important; }
.global-page-loader {
    position: fixed;
    inset: 0;
    z-index: 20000;
    display: grid;
    place-items: center;
    background: rgba(248, 250, 252, .94);
    opacity: 1;
    visibility: visible;
    transition: opacity .2s ease, visibility .2s ease;
}

.global-page-loader.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.global-page-loader__content {
    text-align: center;
    color: #334155;
    font-weight: 700;
}

.global-page-loader__logo {
    width: 150px;
    height: 150px;
    object-fit: contain;
    margin-bottom: 14px;
    filter: drop-shadow(0 8px 18px rgba(30, 64, 175, .18));
}

.connection-warning {
    position: fixed;
    top: 76px;
    left: 50%;
    z-index: 19999;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 10px;
    width: min(92vw, 620px);
    padding: 12px 16px;
    border: 1px solid #f1b94e;
    border-radius: 12px;
    color: #6b4600;
    background: #fff3cd;
    box-shadow: 0 12px 30px rgba(15, 23, 42, .16);
}

/* Keep dialogs above page chrome and usable when their contents exceed the viewport. */
.modal {
    z-index: 1055;
}

.modal-backdrop {
    z-index: 1050;
}

.modal-dialog {
    max-height: calc(100vh - 1rem);
    max-height: calc(100dvh - 1rem);
}

.modal-content {
    max-height: calc(100vh - 1rem);
    max-height: calc(100dvh - 1rem);
}

.modal-content > .modal-body,
.modal-content > .block-content:not(.block-content-full) {
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.swal2-container {
    z-index: 1100 !important;
}

@media (max-width: 575.98px) {
    .modal-dialog {
        margin: .5rem;
        max-width: calc(100% - 1rem);
    }
}

.connection-warning[hidden] { display: none; }
.connection-warning .btn-close { margin-inline-start: auto; }

/* Login input groups must keep their LTR visual order after all generic RTL rules. */
html[dir="rtl"] .standard-login-group {
    direction: ltr !important;
    flex-direction: row !important;
}

html[dir="rtl"] .standard-login-group > .input-group-text {
    flex: 0 0 48px !important;
    justify-content: center !important;
    border-top-left-radius: 0.375rem !important;
    border-bottom-left-radius: 0.375rem !important;
    border-top-right-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    border-right-width: 1px !important;
}

html[dir="rtl"] .standard-login-group > .form-control {
    min-width: 0 !important;
    direction: ltr !important;
    text-align: left !important;
    border-radius: 0 !important;
}

html[dir="rtl"] .standard-login-group:not(.password-group) > .form-control {
    border-top-right-radius: 0.375rem !important;
    border-bottom-right-radius: 0.375rem !important;
}

html[dir="rtl"] .standard-login-group > .password-toggle {
    flex: 0 0 48px !important;
    border-top-left-radius: 0 !important;
    border-bottom-left-radius: 0 !important;
    border-top-right-radius: 0.375rem !important;
    border-bottom-right-radius: 0.375rem !important;
}

/* Keep mixed Persian text and numeric identifiers in notifications readable. */
#notification-items-container,
#notification-items-container > li > a,
#notification-items-container .notification-message,
#notification-items-container .notification-time {
    direction: rtl;
    unicode-bidi: plaintext;
    text-align: right;
}

#notification-items-container .notification-message {
    overflow-wrap: anywhere;
}

#notification-items-container .notification-time {
    font-size: 10px;
}

/* Notification dropdown polish */
#notification-dropdown .dropdown-menu {
    width: min(420px, calc(100vw - 2rem));
    margin-top: .75rem;
    border-radius: .85rem;
    overflow: hidden;
    box-shadow: 0 .75rem 2rem rgba(15, 23, 42, .16);
}

#notification-items-container {
    max-height: 320px !important;
    margin: .5rem .35rem !important;
    padding: 0 .25rem !important;
    scrollbar-width: thin;
    scrollbar-color: var(--bs-gray-500) transparent;
}

#notification-items-container::-webkit-scrollbar { width: .45rem; }
#notification-items-container::-webkit-scrollbar-track { background: transparent; }
#notification-items-container::-webkit-scrollbar-thumb {
    background: var(--bs-gray-500);
    border-radius: 999px;
}

#notification-items-container > li > a {
    margin: .2rem 0;
    padding: .75rem .5rem !important;
    border-radius: .55rem;
}

#notification-dropdown .text-primary { color: var(--bs-info) !important; }
#notification-dropdown .bg-primary { background-color: var(--bs-info) !important; }

/* OneUI side-scroll style for the notification list. */
#notification-items-container {
    scrollbar-width: auto;
    scrollbar-color: #8f8f8f transparent;
    overscroll-behavior: contain;
}

#notification-items-container::-webkit-scrollbar {
    width: 7px;
}

#notification-items-container::-webkit-scrollbar-track {
    background: transparent;
    border-radius: 0;
}

#notification-items-container::-webkit-scrollbar-thumb {
    min-height: 48px;
    background: #8f8f8f;
    border: 0;
    border-radius: 6px;
}

#notification-items-container::-webkit-scrollbar-thumb:hover {
    background: #737373;
}

/* OneUI scrollbar: notification list and the document scrollbar. */
html {
    scrollbar-color: #8f969e #edf0f4;
    scrollbar-width: auto;
}

html::-webkit-scrollbar,
#notification-items-container::-webkit-scrollbar {
    width: 14px;
    height: 14px;
}

html::-webkit-scrollbar-track,
#notification-items-container::-webkit-scrollbar-track {
    background: #edf0f4;
}

html::-webkit-scrollbar-thumb,
#notification-items-container::-webkit-scrollbar-thumb {
    min-height: 48px;
    background: #9299a1;
    border: 3px solid #edf0f4;
    border-radius: 7px;
}

html::-webkit-scrollbar-thumb:hover,
#notification-items-container::-webkit-scrollbar-thumb:hover {
    background: #747c85;
}

html::-webkit-scrollbar-button:single-button,
#notification-items-container::-webkit-scrollbar-button:single-button {
    display: block;
    height: 16px;
    background-color: #edf0f4;
    background-repeat: no-repeat;
    background-position: center;
}

html::-webkit-scrollbar-button:single-button:vertical:decrement,
#notification-items-container::-webkit-scrollbar-button:single-button:vertical:decrement {
    background-image: linear-gradient(135deg, transparent 50%, #9299a1 50%), linear-gradient(45deg, #9299a1 50%, transparent 50%);
    background-size: 7px 7px, 7px 7px;
    background-position: calc(50% - 3px) 7px, calc(50% + 3px) 7px;
}

html::-webkit-scrollbar-button:single-button:vertical:increment,
#notification-items-container::-webkit-scrollbar-button:single-button:vertical:increment {
    background-image: linear-gradient(45deg, transparent 50%, #9299a1 50%), linear-gradient(135deg, #9299a1 50%, transparent 50%);
    background-size: 7px 7px, 7px 7px;
    background-position: calc(50% - 3px) 2px, calc(50% + 3px) 2px;
}

/* Chrome may expose the document scrollbar on body rather than html. */
body {
    scrollbar-color: #9299a1 #edf0f4;
    scrollbar-width: auto;
}

body::-webkit-scrollbar {
    width: 14px;
    height: 14px;
}

body::-webkit-scrollbar-track { background: #edf0f4; }
body::-webkit-scrollbar-thumb {
    min-height: 48px;
    background: #9299a1;
    border: 3px solid #edf0f4;
    border-radius: 7px;
}

body::-webkit-scrollbar-button:single-button {
    display: block;
    height: 16px;
    background-color: #edf0f4;
}

/* OneUI SimpleBar is used by the notification list. */
#notification-items-container.simplebar-scrollable-y {
    max-height: 320px !important;
    margin: .5rem .35rem !important;
    padding: 0 !important;
}

#notification-items-container.simplebar-scrollable-y .simplebar-scrollbar:before {
    top: 2px;
    bottom: 2px;
    right: 2px;
    left: 2px;
    border-radius: 6px;
    background: #9299a1;
    opacity: 1;
}

#notification-items-container.simplebar-scrollable-y .simplebar-scrollbar.simplebar-visible:before,
#notification-items-container.simplebar-scrollable-y:hover .simplebar-scrollbar:before {
    opacity: 1;
}

#notification-items-container.simplebar-scrollable-y .simplebar-track.simplebar-vertical {
    top: 4px;
    right: 2px;
    bottom: 4px;
    width: 10px;
    border-radius: 6px;
    background: transparent;
}

#notification-items-container.simplebar-scrollable-y .simplebar-content-wrapper {
    scrollbar-width: none;
}

#notification-items-container.simplebar-scrollable-y .simplebar-content-wrapper::-webkit-scrollbar {
    display: none;
}

/* Notification list uses an actual OneUI SimpleBar instance. */
#notification-scroll {
    max-height: 320px;
    margin: .5rem .35rem;
    direction: rtl;
}

#notification-scroll .simplebar-content-wrapper {
    max-height: 320px;
    scrollbar-width: none;
}

#notification-scroll .simplebar-content-wrapper::-webkit-scrollbar {
    display: none;
}

#notification-scroll .simplebar-track.simplebar-vertical {
    top: 4px;
    right: 2px;
    bottom: 4px;
    width: 10px;
}

#notification-scroll .simplebar-scrollbar::before {
    top: 2px;
    right: 2px;
    bottom: 2px;
    left: 2px;
    border-radius: 6px;
    background: #9299a1;
    opacity: 1;
}

/* Remove the duplicate native scrollbar; SimpleBar is the only scrollbar for notifications. */
#notification-scroll {
    overflow: hidden !important;
}

#notification-scroll > #notification-items-container {
    max-height: none !important;
    overflow: visible !important;
    margin: 0 !important;
    padding: 0 .25rem !important;
}

#notification-scroll::-webkit-scrollbar,
#notification-scroll > #notification-items-container::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
}

/* Match the narrow OneUI document scrollbar without browser arrow buttons. */
html::-webkit-scrollbar,
body::-webkit-scrollbar {
    width: 10px !important;
    height: 10px !important;
}

html::-webkit-scrollbar-track,
body::-webkit-scrollbar-track {
    background: #edf0f4 !important;
}

html::-webkit-scrollbar-thumb,
body::-webkit-scrollbar-thumb {
    min-height: 48px;
    background: #9299a1 !important;
    border: 2px solid #edf0f4 !important;
    border-radius: 6px !important;
}

html::-webkit-scrollbar-button,
body::-webkit-scrollbar-button {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
}

/* SimpleBar owns the only scrollbars for the page content and notification list. */
html,
body {
    width: 100%;
    height: 100%;
    overflow: hidden !important;
}

#main-container {
    height: calc(100vh - 70px);
    min-height: 0;
    overflow: hidden;
}

#main-content-scroll {
    height: 100%;
    min-height: 0;
    overflow: hidden;
}

#main-content-scroll .simplebar-content {
    min-height: 100%;
}

#main-content-scroll .simplebar-content-wrapper,
#notification-scroll .simplebar-content-wrapper {
    scrollbar-width: none;
}

#main-content-scroll .simplebar-content-wrapper::-webkit-scrollbar,
#notification-scroll .simplebar-content-wrapper::-webkit-scrollbar {
    display: none;
    width: 0;
}

#main-content-scroll .simplebar-track.simplebar-vertical,
#notification-scroll .simplebar-track.simplebar-vertical {
    top: 4px;
    right: 2px;
    bottom: 4px;
    width: 8px;
    background: transparent;
}

#main-content-scroll .simplebar-scrollbar::before,
#notification-scroll .simplebar-scrollbar::before {
    top: 0;
    right: 2px;
    bottom: 0;
    left: 2px;
    border-radius: 999px;
    background: #9299a1;
    opacity: .8;
}

#notification-scroll {
    max-height: 320px;
    margin: .5rem .35rem;
    overflow: hidden !important;
    direction: rtl;
}

#notification-scroll > #notification-items-container {
    max-height: none !important;
    margin: 0 !important;
    padding: 0 .25rem !important;
    overflow: visible !important;
}

#notification-dropdown .dropdown-menu {
    margin-top: .75rem;
    border-radius: .85rem;
    overflow: hidden;
}

#notification-items-container .notification-message,
#notification-items-container .notification-time {
    direction: rtl;
    unicode-bidi: plaintext;
    text-align: right;
}

#notification-items-container .notification-message {
    overflow-wrap: anywhere;
}

#notification-items-container .notification-time {
    font-size: 10px;
}

html, body { overflow: hidden; }
#main-container { min-height: 0; overflow: hidden; }
#main-content-scroll { height: calc(100vh - 70px); min-height: 0; overflow: hidden; }
#main-content-scroll .simplebar-content { min-height: 100%; }
#main-content-scroll .simplebar-track.simplebar-vertical { top: 0; right: 2px; bottom: 0; width: 10px; }
#main-content-scroll .simplebar-scrollbar::before { top: 2px; right: 2px; bottom: 2px; left: 2px; border-radius: 6px; background: #9299a1; opacity: 1; }
#main-content-scroll .simplebar-content-wrapper { scrollbar-width: none; }
#main-content-scroll .simplebar-content-wrapper::-webkit-scrollbar { display: none; }

#main-content-scroll .simplebar-content-wrapper {
    overflow-x: hidden !important;
    overflow-y: auto !important;
    scrollbar-width: thin !important;
    scrollbar-color: #9299a1 #edf0f4 !important;
}

#main-content-scroll .simplebar-content-wrapper::-webkit-scrollbar {
    display: block !important;
    width: 7px;
}

#main-content-scroll .simplebar-content-wrapper::-webkit-scrollbar-track {
    background: #edf0f4;
    border-radius: 999px;
}

#main-content-scroll .simplebar-content-wrapper::-webkit-scrollbar-thumb {
    background: #9299a1;
    border: 1px solid #edf0f4;
    border-radius: 999px;
}

#main-content-scroll .simplebar-track.simplebar-vertical,
#notification-scroll .simplebar-track.simplebar-vertical {
    width: 8px;
}

#main-content-scroll .simplebar-scrollbar::before,
#notification-scroll .simplebar-scrollbar::before {
    top: 2px;
    right: 2px;
    bottom: 2px;
    left: 2px;
    border-radius: 6px;
    background: #9299a1;
    opacity: 1;
}

@media print {
    html,
    body,
    #main-container,
    #main-content-scroll,
    #main-content-scroll .simplebar-wrapper,
    #main-content-scroll .simplebar-mask,
    #main-content-scroll .simplebar-offset,
    #main-content-scroll .simplebar-content-wrapper,
    #main-content-scroll .simplebar-content {
        width: auto !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
        transform: none !important;
    }

    #main-content-scroll .simplebar-wrapper,
    #main-content-scroll .simplebar-mask,
    #main-content-scroll .simplebar-offset,
    #main-content-scroll .simplebar-content-wrapper {
        position: static !important;
    }

    #main-content-scroll .simplebar-track,
    #main-content-scroll .simplebar-scrollbar {
        display: none !important;
        visibility: hidden !important;
    }

    html,
    body,
    #main-content-scroll,
    #main-content-scroll .simplebar-content-wrapper {
        scrollbar-width: none !important;
    }

    html::-webkit-scrollbar,
    body::-webkit-scrollbar,
    #main-content-scroll::-webkit-scrollbar,
    #main-content-scroll .simplebar-content-wrapper::-webkit-scrollbar {
        display: none !important;
        width: 0 !important;
        height: 0 !important;
    }
}

#notification-scroll {
    height: min(320px, 55vh) !important;
    max-height: min(320px, 55vh) !important;
    min-height: 0;
}

#notification-scroll .simplebar-wrapper,
#notification-scroll .simplebar-content-wrapper {
    height: 100% !important;
    max-height: 100% !important;
}

#notification-scroll .simplebar-content-wrapper {
    overflow-x: hidden !important;
    overflow-y: auto !important;
}

#notification-scroll .simplebar-content {
    min-height: 100%;
}

#notification-scroll .simplebar-scrollbar {
    min-height: 24px;
}

#notification-scroll .simplebar-content-wrapper {
    overflow-x: hidden !important;
    overflow-y: auto !important;
    scrollbar-width: thin !important;
    scrollbar-color: #9299a1 #edf0f4 !important;
}

#notification-scroll .simplebar-content-wrapper::-webkit-scrollbar {
    display: block !important;
    width: 7px;
}

#notification-scroll .simplebar-content-wrapper::-webkit-scrollbar-track {
    background: #edf0f4;
    border-radius: 999px;
}

#notification-scroll .simplebar-content-wrapper::-webkit-scrollbar-thumb {
    background: #9299a1;
    border: 1px solid #edf0f4;
    border-radius: 999px;
}

#notification-scroll > .simplebar-track {
    display: none !important;
}

/* Tables retain their natural column widths while scrolling inside the page on narrow screens. */
.table-responsive {
    max-width: 100%;
    min-width: 0;
    -webkit-overflow-scrolling: touch;
}

.table-responsive > .table {
    margin-bottom: 0;
}
