/* 
 * نظام التخاطب الإلكتروني المتكامل للدوائر الحكومية
 * Custom Stylesheet
 */

/* ===== خطوط النظام ===== */
@import url('https://fonts.googleapis.com/css2?family=Tajawal:wght@300;400;500;700;800&display=swap');

body {
    font-family: 'Tajawal', sans-serif;
    background-color: #f8f9fa;
}

/* ===== القائمة الجانبية ===== */
.sidebar {
    min-height: 100vh;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s;
}

.sidebar .nav-link {
    color: rgba(255, 255, 255, 0.7);
    padding: 0.75rem 1rem;
    margin: 0.25rem 0;
    border-radius: 0.5rem;
    transition: all 0.3s;
}

.sidebar .nav-link:hover {
    color: #fff;
    background-color: rgba(255, 255, 255, 0.1);
}

.sidebar .nav-link.active {
    color: #fff;
    background-color: #0d6efd;
}

.sidebar .nav-link i {
    margin-left: 0.5rem;
    width: 1.25rem;
    text-align: center;
}

/* ===== لوحة التحكم ===== */
.card {
    border-radius: 0.75rem;
    overflow: hidden;
    transition: all 0.3s;
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
}

.card-header {
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

/* ===== صفحة تسجيل الدخول ===== */
.login-page {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

/* ===== ألوان النص والتنسيقات ===== */
.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ===== الأزرار وعناصر النموذج ===== */
.btn {
    border-radius: 0.5rem;
    padding: 0.5rem 1.25rem;
    font-weight: 500;
}

.btn-sm {
    border-radius: 0.3rem;
    padding: 0.25rem 0.75rem;
}

.form-control,
.input-group-text {
    border-radius: 0.5rem;
    padding: 0.6rem 1rem;
}

.input-group .form-control:not(:first-child) {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.input-group-text {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

/* ===== الجداول ===== */
.table th {
    font-weight: 700;
    padding: 1rem 0.75rem;
}

.table td {
    padding: 0.75rem;
    vertical-align: middle;
}

/* ===== التوقيع الالكتروني ===== */
.signature-pad {
    border: 2px dashed #dee2e6;
    border-radius: 0.5rem;
    background-color: #fff;
}

/* ===== تخصيص المخططات البيانية ===== */
.chart-container {
    position: relative;
    height: 250px;
}

/* ===== وضع الطباعة ===== */
@media print {
    .sidebar,
    .no-print {
        display: none !important;
    }
    
    .col {
        flex: 0 0 100%;
        max-width: 100%;
    }
    
    .card {
        border: none !important;
        box-shadow: none !important;
    }
}

/* ===== تخصيص الهواتف الذكية ===== */
@media (max-width: 767.98px) {
    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 1050;
        transform: translateX(-100%);
    }
    
    .sidebar.show {
        transform: translateX(0);
    }
    
    .col {
        padding-right: 0.75rem;
        padding-left: 0.75rem;
    }
}
