﻿@font-face {
    font-family: "Cairo";
    src: url("Fonts/Cairo-Regular.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

body, button, input, select, textarea {
    font-family: "Cairo", sans-serif;
}

    body,
    body *:not(i):not(.micon):not(.icon-copy):not(.fa):not(.ion):not([class*="dw-"]) {
        font-family: "Cairo", sans-serif !important;
    }

/* تنسيق قسم الشعار في القائمة الجانبية */
.brand-logo-custom {
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.brand-logo-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 8px 12px;
    text-decoration: none;
}

/* خلفية بيضاء دائرية لإبراز اللوجو وحمايته من لون الثيم الداكن */
.brand-logo-badge {
    background-color: #ffffff;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px;
    margin-left: 10px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

    .brand-logo-badge img {
        max-height: 36px;
        max-width: 36px;
        object-fit: contain;
    }

/* نصوص الشعار */
.brand-logo-text {
    display: flex;
    flex-direction: column;
    text-align: right;
}

.brand-logo-title {
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.2;
}

.brand-logo-subtitle {
    color: #17a2b8;
    font-size: 11px;
    font-weight: 600;
}


/* ضبط الخط العربي ومحاذاة الحقول */
.form-control,
.custom-select,
.custom-file-input,
.custom-file-label {
    font-size: 14px;
    color: #2c3e50;
    height: 48px;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    background-color: #ffffff;
    transition: all 0.2s ease-in-out;
}

/* تنسيق القائمة المنسدلة وسهم الاختيار للغة العربية */
.custom-select {
    padding: 0 16px;
    line-height: 48px;
    vertical-align: middle;
    /* ضبط مكان السهم ليكون على اليسار بما يتناسب مع الواجهة العربية RTL */
    background: #fff url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='4' height='5' viewBox='0 0 4 5'%3e%3cpath fill='%2364748b' d='M2 0L0 2h4zm0 5L0 3h4z'/%3e%3c/svg%3e") no-repeat left 1rem center/8px 10px !important;
}

    /* تأثير التركيز عند النقر داخل الحقل */
    .form-control:focus,
    .custom-select:focus {
        border-color: #1b00ff;
        box-shadow: 0 0 0 3px rgba(27, 0, 255, 0.12);
        background-color: #ffffff;
        outline: none;
    }

    /* تحسين شكل النصوص داخل خيارات القائمة */
    .custom-select option {
        font-size: 14px;
        padding: 10px;
        color: #1e293b;
    }

    .message-center-rtl {
        direction: rtl;
        text-align: right;
    }

    .message-center-rtl .form-control {
        direction: rtl;
        text-align: right;
    }

    .message-center-rtl .alert,
    .message-center-rtl .border {
        text-align: right;
    }

/* هوية نشأة للقائمة الجانبية */
.left-side-bar {
    background: #102b30;
}

    .left-side-bar .brand-logo-custom {
        height: 92px;
        border-bottom: 1px solid rgba(255, 255, 255, .12);
    }

    .left-side-bar .brand-logo-link {
        direction: rtl;
        justify-content: flex-start;
        gap: 12px;
        padding: 12px 18px;
    }

    .left-side-bar .brand-logo-badge {
        flex: 0 0 52px;
        width: 52px;
        height: 52px;
        margin: 0;
        padding: 6px;
        background: #fff;
        border-radius: 15px;
        box-shadow: 0 3px 12px rgba(0, 0, 0, .15);
    }

        .left-side-bar .brand-logo-badge img {
            width: 100%;
            height: 100%;
            max-width: none;
            max-height: none;
            object-fit: contain;
        }

    .left-side-bar .brand-logo-text {
        text-align: right;
        font-family: 'Cairo', Tahoma, sans-serif;
    }

    .left-side-bar .brand-logo-title {
        color: #fff;
        font-family: 'Cairo', Tahoma, sans-serif;
        font-size: 18px;
        font-weight: 800;
        line-height: 1.5;
    }

    .left-side-bar .brand-logo-subtitle {
        color: #83d4ce;
        font-family: 'Cairo', Tahoma, sans-serif;
        font-size: 11px;
        font-weight: 600;
    }

    .left-side-bar .sidebar-menu {
        direction: rtl;
        padding-top: 14px;
    }

        .left-side-bar .sidebar-menu > ul > li {
            padding: 3px 12px;
        }

        .left-side-bar .sidebar-menu .dropdown-toggle {
            min-height: 50px;
            padding: 12px 58px 12px 14px;
            text-align: right;
            color: #d7e9e7;
            font-family: 'Cairo', Tahoma, sans-serif;
            font-size: 14px;
            font-weight: 700;
            line-height: 26px;
            border-radius: 10px;
        }

            .left-side-bar .sidebar-menu .dropdown-toggle .micon {
                left: auto;
                right: 10px;
                width: 38px;
                height: 38px;
                font-size: 20px;
                color: #a9e2dd;
            }

            .left-side-bar .sidebar-menu .dropdown-toggle:hover,
            .left-side-bar .sidebar-menu .dropdown-toggle:focus {
                color: #fff;
                background: #1c5357;
            }

                .left-side-bar .sidebar-menu .dropdown-toggle:hover .micon,
                .left-side-bar .sidebar-menu .dropdown-toggle:focus .micon {
                    color: #fff;
                }


    /* ترتيب رأس القائمة */
    .left-side-bar .brand-logo-custom {
        position: relative;
        display: block;
        height: 82px;
    }

    .left-side-bar .brand-logo-link {
        width: 100%;
        height: 100%;
        display: flex;
        flex-direction: row;
        direction: rtl;
        align-items: center;
        justify-content: flex-start;
        gap: 11px;
        padding: 10px 18px;
    }

    .left-side-bar .brand-logo-badge {
        flex: 0 0 48px;
        width: 48px;
        height: 48px;
        margin: 0;
        padding: 4px;
    }

    .left-side-bar .brand-logo-text {
        flex: 1;
        min-width: 0;
        text-align: right;
    }

    .left-side-bar .brand-logo-title {
        font-size: 16px;
        line-height: 1.5;
    }

    .left-side-bar .brand-logo-subtitle {
        font-size: 11px;
        line-height: 1.6;
    }

    /* لا يظهر زر إغلاق القائمة على الكمبيوتر */
    .left-side-bar .close-sidebar {
        display: none !important;
    }

/* على الهاتف يظهر زر إغلاق أبيض في يسار رأس القائمة */
@media (max-width: 1300px) {
    .left-side-bar .brand-logo-link {
        padding-left: 52px;
    }

    .left-side-bar .close-sidebar {
        display: flex !important;
        position: absolute;
        left: 12px;
        top: 50%;
        transform: translateY(-50%);
        width: 30px;
        height: 30px;
        align-items: center;
        justify-content: center;
        color: #ffffff !important;
        font-size: 21px;
        cursor: pointer;
        z-index: 2;
    }

        .left-side-bar .close-sidebar i {
            color: #ffffff !important;
        }
}

.bootstrap-select .dropdown-menu,
.bootstrap-select .dropdown-menu .inner,
.bootstrap-select .dropdown-menu .dropdown-item,
.bootstrap-select .dropdown-menu li a,
.bootstrap-select .filter-option-inner-inner {
    direction: rtl;
    text-align: right;
}

.dropdown-item.active, .dropdown-item:active {
    background-color: #102b30;

}
.btn-outline-primary {
    color: #0a4d53;
    border-color: #0a4d53
}

    .btn-outline-primary:hover {
        color: #fff;
        background-color: #0a4d53 !important;
        border-color: #0a4d53
    }


.btn-primary {
    color: #fff;
    background-color: #0a4d53;
    border-color: #0a4d53;
}



.login-page .header {
    width: 100%;
    left: 0;
    flex-wrap: nowrap;
    direction: rtl;
    padding: 0 16px;
    padding-right: 16px !important
}

    .login-page .header .header-left,
    .login-page .header .header-right {
        display: flex;
        align-items: center;
        width: 50%;
        height: 70px;
    }

.login-page .header .header-left {
    justify-content: flex-start;
}

.login-page .header .header-right {
    justify-content: flex-end;
}

.login-page .header .header-left h4 {
    margin: 0;
}

@media (max-width: 767px) {
    .login-page .header .header-left h4 {
        font-size: 18px;
    }

    .login-page .header .user-name {
        display: none;
    }
}



/* شريط الأدوات العلوي للجدول */
.customer-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 15px;
    padding: 0 15px 15px 15px;
}

.customer-toolbar-right {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 15px;
}

.customer-status-filter-wrapper {
    min-width: 220px;
}

/* تنسيق خانة البحث الخاصة بـ DataTables */
#searchBoxContainer .dataTables_filter {
    margin-bottom: 0 !important;
    text-align: left;
}

    #searchBoxContainer .dataTables_filter label {
        display: inline-flex;
        align-items: center;
        margin-bottom: 0;
        gap: 8px;
        font-weight: 600;
    }

    #searchBoxContainer .dataTables_filter input {
        height: 42px;
        border-radius: 8px;
        border: 1.5px solid #d4d4d4;
        padding: 0 12px;
    }

/* أزرار التصدير */
.dt-buttons .btn {
    height: 42px;
    display: inline-flex;
    align-items: center;
    border-radius: 8px;
    font-weight: 600;
}

/* إصلاح وتنسيق أزرار التصدير في RTL */
#exportButtonsContainer .dt-buttons {
    display: inline-flex !important;
    gap: 8px !important;
}

    #exportButtonsContainer .dt-buttons .btn {
        border-radius: 6px !important; /* تدوير منتظم لكل زر من كل الجهات */
        margin: 0 !important;
        padding: 6px 14px !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        font-size: 13px !important;
        line-height: 1.5 !important;
        box-shadow: none !important;
    }

        #exportButtonsContainer .dt-buttons .btn i {
            margin-left: 6px !important; /* مسافة بين الأيقونة والنص بالعربي */
            margin-right: 0 !important;
        }

.btn-primary:not(:disabled):not(.disabled).active, .btn-primary:not(:disabled):not(.disabled):active, .show > .btn-primary.dropdown-toggle {
    background-color: #0a4d53!important;
}