@import url(fontiran.css);
body{
    font-family: IRANSans !important;
}
.layout {
    display: flex;
    flex-direction: row-reverse;
    width: 100%;
    height: 100vh;
}

.sidebar {
    width: 250px;
    background-color: #343a40;
    color: white;
    position: fixed;
    top: 0;
    bottom: 0;
    right: 0;
    box-shadow: -2px 0 5px rgba(0,0,0,0.3);
    transition: transform 0.3s ease-in-out;
    overflow-y: auto;
    z-index: 1100;
    transform: translateX(0);
}

.sidebar.closed {
    transform: translateX(100%);
}

.sidebar a {
    color: white;
    display: block;
    padding: 12px 20px;
    text-decoration: none;
    font-size: 12px;
    transition: background-color 0.3s;
}

.sidebar a:hover,
.sidebar a.active {
    background-color: #23272b;
    color: orange;
}

main.content {
    margin-right: 250px;
    padding: 1.5rem;
    transition: margin-right 0.3s ease-in-out;
    min-height: 100vh;
    background-color: #f8f9fa;
    direction: rtl;
}

/* --- ریسپانسیو --- */
@media (max-width: 767.98px) {
    header.topbar {
        display: flex;
    }

    .sidebar {
        top: 56px;
        height: calc(100vh - 56px);
        width: 250px;
        transform: translateX(100%);
        position: fixed;
        z-index: 1100;
    }

    .sidebar.open {
        transform: translateX(0);
    }

    main.content {
        margin-right: 0 !important;
        padding: 1rem;
        padding-top: 72px; /* فاصله از نوار بالا */
    }

}

/* دکمه همبرگر */
.hamburger-button {
    position: fixed;
    top: 10px;
    right: 10px;
    z-index: 1200;
    width: 40px;
    height: 40px;
    background-color: transparent;
    color: white;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.hamburger-button:hover {
    background-color: transparent !important;
    color: white; /* رنگ متن رو اگر خواستی ثابت بذار */
}

/* وقتی سایدبار مخفی است، رنگ دکمه قرمز شود */
nav.sidebar.closed ~ .hamburger-button {
    background-color: transparent !important;
    color: #343a40 !important;
}

/* رنگ دکمه همبرگر در موبایل قرمز شود */
@media (max-width: 767.98px) {
    .hamburger-button {
        background-color: transparent !important;
        color: #343a40 !important;
    }
}


/* کانتینر اصلی که rtl است */
/* برای dt-left باید چیدمان flex از چپ به راست باشد (LTR) */
/* چون container کلی rtl است، flex default راست به چپه، پس باید direction رو تغییر بدیم */

.dt-left {
    display: flex !important;  /* حتما flex باشه */
    flex-direction: row !important; /* از چپ به راست */
    gap: 10px;
    align-items: center;
    /*direction: ltr !important; !* جهت داخلی چپ به راست *!*/
    justify-content: flex-start; /* چیدمان به سمت شروع (سمت چپ برای LTR) */
}

/* برای سمت راست، راستچین و جهت rtl */
.dt-right {
    text-align: right;
    direction: rtl;
    display: flex;
    align-items: center;
    justify-content: flex-end; /* چیدمان به سمت انتهای خط که در rtl سمت راست است */
}

.dt-buttons .buttons-html5, .buttons-print, .btn-add-entity, .btn-add-checklist, .btn-add-summary-checklist, .btn-add-ticket {
    margin: 2px;
}

#courseTable_filter label {
}

.select2-container {
    width: 100% !important;
    direction: rtl;
    z-index: 1055 !important; /* بالاتر از z-index مدال Bootstrap */
}
.select2-container .select2-selection {
    border-radius: 0.375rem;
    height: calc(1.5em + 0.75rem + 2px);
    padding: 0.375rem 0.75rem;
    border: 1px solid #ced4da;
}
.select2-container--default .select2-selection--multiple {
    min-height: calc(1.5em + 0.75rem + 2px);
}
.select2-container--default .select2-results__option {
    text-align: right;
}
.select2-dropdown {
    z-index: 1055 !important; /* بالاتر از مدال */
}

.milad-tower {
    position: absolute;
    bottom: 0;
    left: 10px;
    width: 120px;
    opacity: 0.2;
    z-index: 0;
}




