/* =====================================================
   Mobile App Experience - منصة المهام
   تجربة تطبيق حقيقية على الجوال
   ===================================================== */

/* ---- متغيرات التطبيق ---- */
:root {
  --app-nav-h: 68px;
  --app-header-h: 62px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-top: env(safe-area-inset-top, 0px);
}

/* ===================================================
   إظهار/إخفاء عناصر التطبيق
   =================================================== */
.appTopBar,
.appBottomNav {
  display: none;
}

@media(max-width: 768px) {
  .appTopBar { display: flex; }
  .appBottomNav { display: flex; }
}

/* ===================================================
   شريط التنقل العلوي (App Header) - للجوال فقط
   =================================================== */
@media(max-width: 768px) {

  /* إخفاء الهيدر الأصلي */
  .nav { display: none !important; }

  /* هيدر التطبيق الثابت */
  .appTopBar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: calc(var(--app-header-h) + var(--safe-top));
    padding-top: var(--safe-top);
    background: linear-gradient(135deg, #15445a 0%, #1a5570 100%);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-right: 16px;
    padding-left: 16px;
    box-shadow: 0 2px 16px rgba(0,0,0,.3);
  }

  .appTopBar .appLogo {
    display: flex;
    align-items: center;
    gap: 10px;
  }

  .appTopBar .appLogo img {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    object-fit: contain;
    background: rgba(255,255,255,.15);
    padding: 4px;
  }

  .appTopBar .appLogoIcon {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: rgba(255,255,255,.18);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
  }

  .appTopBar .appTitle {
    font-weight: 900;
    font-size: 15px;
    color: #fff;
    line-height: 1.3;
  }

  .appTopBar .appSubtitle {
    font-size: 11px;
    color: rgba(255,255,255,.6);
    line-height: 1.2;
  }

  .appTopBar .appTopActions {
    display: flex;
    align-items: center;
    gap: 6px;
  }

  .appTopBtn {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: rgba(255,255,255,.13);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 18px;
    text-decoration: none;
    position: relative;
    transition: background .15s;
  }

  .appTopBtn:active {
    background: rgba(255,255,255,.22);
  }

  .appTopBtn .badge-dot {
    position: absolute;
    top: 7px;
    left: 7px;
    width: 8px;
    height: 8px;
    background: #e11d48;
    border-radius: 50%;
    border: 2px solid #15445a;
  }

  /* إضافة مسافة للمحتوى */
  .container {
    padding-top: calc(var(--app-header-h) + var(--safe-top) + 12px) !important;
    padding-bottom: calc(var(--app-nav-h) + var(--safe-bottom) + 12px) !important;
  }

  /* ===================================================
     شريط التنقل السفلي (Bottom Tab Bar)
     =================================================== */
  .appBottomNav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    height: calc(var(--app-nav-h) + var(--safe-bottom));
    padding-bottom: var(--safe-bottom);
    background: rgba(255,255,255,.96);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-top: 1px solid rgba(21,68,90,.08);
    box-shadow: 0 -4px 24px rgba(21,68,90,.12);
    display: flex;
    align-items: stretch;
  }

  .appNavItem {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    text-decoration: none;
    color: #94a3b8;
    font-size: 10px;
    font-weight: 700;
    padding: 8px 4px;
    border: none;
    background: transparent;
    cursor: pointer;
    transition: color .2s;
    position: relative;
    -webkit-tap-highlight-color: transparent;
  }

  .appNavItem.active {
    color: var(--primary, #1a7a5e);
  }

  .appNavItem .navIcon {
    font-size: 22px;
    line-height: 1;
    transition: transform .2s cubic-bezier(.34,1.56,.64,1);
  }

  .appNavItem.active .navIcon {
    transform: scale(1.2);
  }

  /* مؤشر النشاط */
  .appNavItem.active::after {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 24px;
    height: 3px;
    background: var(--primary, #1a7a5e);
    border-radius: 0 0 4px 4px;
  }

  /* زر الإضافة المركزي */
  .appNavItem.navAdd {
    flex: 0 0 68px;
  }

  .appNavItem.navAdd::after {
    display: none;
  }

  .appNavItem.navAdd .navAddBtn {
    width: 52px;
    height: 52px;
    border-radius: 18px;
    background: linear-gradient(135deg, #1a7a5e 0%, #15445a 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: #fff;
    box-shadow: 0 6px 20px rgba(21,68,90,.35);
    margin-top: -12px;
    transition: transform .2s cubic-bezier(.34,1.56,.64,1), box-shadow .2s;
  }

  .appNavItem.navAdd:active .navAddBtn {
    transform: scale(.9);
    box-shadow: 0 3px 10px rgba(21,68,90,.25);
  }

  /* نقطة الإشعارات */
  .appNavItem .navBadge {
    position: absolute;
    top: 6px;
    right: calc(50% - 14px);
    background: #e11d48;
    color: #fff;
    font-size: 9px;
    font-weight: 900;
    min-width: 16px;
    height: 16px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid #fff;
  }

  /* ===================================================
     الكروت العامة - تصميم تطبيق
     =================================================== */
  .card {
    border-radius: 20px !important;
    padding: 16px !important;
    box-shadow: 0 2px 12px rgba(21,68,90,.06) !important;
    border: 1px solid rgba(21,68,90,.07) !important;
  }

  /* كروت KPI الإحصائية */
  .kpi {
    border-radius: 18px !important;
    padding: 18px 14px !important;
    text-align: center !important;
    background: #fff !important;
    position: relative;
    overflow: hidden;
  }

  .kpi::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 60px;
    height: 60px;
    border-radius: 0 0 0 60px;
    background: rgba(21,68,90,.04);
  }

  .kpi .value {
    font-size: 30px !important;
    font-weight: 900 !important;
    line-height: 1.1;
  }

  .kpi .label {
    font-size: 12px !important;
    color: #64748b !important;
    margin-top: 4px;
    font-weight: 600;
  }

  /* ===================================================
     بطاقات المهام - تصميم تطبيق احترافي
     =================================================== */

  /* إخفاء رأس الجدول */
  .table thead { display: none !important; }

  /* كل صف يصبح بطاقة */
  .table tbody tr {
    display: block !important;
    background: #fff !important;
    border: 1px solid rgba(21,68,90,.08) !important;
    border-radius: 20px !important;
    margin-bottom: 12px !important;
    padding: 0 !important;
    box-shadow: 0 2px 12px rgba(21,68,90,.07) !important;
    overflow: hidden !important;
    transition: box-shadow .2s !important;
  }

  .table tbody tr:active {
    box-shadow: 0 1px 6px rgba(21,68,90,.12) !important;
  }

  /* كل خلية */
  .table tbody td {
    display: flex !important;
    align-items: flex-start !important;
    border-bottom: none !important;
    padding: 6px 16px !important;
    font-size: 14px !important;
    gap: 10px;
    line-height: 1.5;
  }

  /* تسمية العمود */
  .table tbody td::before {
    content: attr(data-label);
    font-weight: 800;
    color: #94a3b8;
    font-size: 11px;
    min-width: 60px;
    flex-shrink: 0;
    padding-top: 2px;
    text-transform: uppercase;
    letter-spacing: .3px;
  }

  /* إخفاء الخلايا الفارغة */
  .table tbody td:empty { display: none !important; }

  /* خلية عنوان المهمة - تصميم خاص */
  .table tbody td[data-label="المهمة"],
  .table tbody td:first-child {
    flex-direction: column !important;
    gap: 4px !important;
    padding: 14px 16px 10px !important;
    border-bottom: 1px solid rgba(21,68,90,.07) !important;
    background: linear-gradient(135deg, rgba(21,68,90,.03) 0%, transparent 100%);
  }

  .table tbody td[data-label="المهمة"]::before,
  .table tbody td:first-child::before {
    display: none !important;
  }

  .table tbody td[data-label="المهمة"] a,
  .table tbody td:first-child a {
    font-size: 15px !important;
    font-weight: 900 !important;
    color: #15445a !important;
    line-height: 1.4;
  }

  .table tbody td[data-label="المهمة"] .small,
  .table tbody td:first-child .small {
    color: #94a3b8;
    font-size: 12px;
  }

  /* خلية الإجراءات */
  .table tbody td[data-label="إجراءات"] {
    padding: 10px 16px 14px !important;
    border-top: 1px solid rgba(21,68,90,.07) !important;
    justify-content: flex-start !important;
    gap: 8px !important;
    flex-wrap: wrap;
  }

  .table tbody td[data-label="إجراءات"]::before {
    display: none !important;
  }

  .table tbody td[data-label="إجراءات"] .rowActions {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    width: 100%;
  }

  .table tbody td[data-label="إجراءات"] .btn {
    flex: 1;
    min-width: 80px;
    text-align: center !important;
    padding: 9px 14px !important;
    border-radius: 12px !important;
    font-size: 13px !important;
    font-weight: 700 !important;
  }

  /* خلية التقدم */
  .table tbody td[data-label="التقدم"] {
    align-items: center !important;
  }

  /* ===================================================
     شريط التقدم
     =================================================== */
  .progressWrap {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    width: 100%;
  }

  .bar {
    flex: 1;
    height: 7px !important;
    border-radius: 999px !important;
    background: rgba(21,68,90,.1) !important;
    overflow: hidden;
  }

  .bar span {
    border-radius: 999px !important;
  }

  /* ===================================================
     الشارات (Badges)
     =================================================== */
  .badge {
    border-radius: 999px !important;
    padding: 4px 12px !important;
    font-size: 12px !important;
    font-weight: 800 !important;
    display: inline-flex !important;
    align-items: center !important;
  }

  /* ===================================================
     الفلاتر والنماذج
     =================================================== */
  .card > form.grid,
  form.grid.noPrint {
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }

  .input, input[type="text"], input[type="date"], input[type="email"], select, textarea {
    border-radius: 14px !important;
    padding: 12px 14px !important;
    font-size: 15px !important;
    border: 1.5px solid rgba(21,68,90,.15) !important;
  }

  .input:focus, input:focus, select:focus, textarea:focus {
    border-color: var(--primary, #1a7a5e) !important;
    box-shadow: 0 0 0 3px rgba(26,122,94,.12) !important;
  }

  /* ===================================================
     التنبيهات
     =================================================== */
  .notice {
    border-radius: 18px !important;
    margin-top: 8px !important;
    padding: 14px 16px !important;
  }

  /* ===================================================
     الأزرار العامة
     =================================================== */
  .btn {
    border-radius: 12px !important;
    padding: 10px 16px !important;
    font-size: 14px !important;
    font-weight: 700 !important;
  }

  .btnGood {
    background: linear-gradient(135deg, #1a7a5e 0%, #15445a 100%) !important;
    color: #fff !important;
    border: none !important;
    box-shadow: 0 4px 12px rgba(21,68,90,.25) !important;
  }

  /* ===================================================
     عناوين الصفحات
     =================================================== */
  h2 {
    font-size: 20px !important;
    font-weight: 900 !important;
    color: #15445a !important;
    margin-bottom: 12px !important;
  }

  h3 {
    font-size: 16px !important;
    font-weight: 800 !important;
  }

  /* ===================================================
     تحسين الشبكة (Grid)
     =================================================== */
  .grid4 {
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
  }

  .grid {
    gap: 12px !important;
  }

  /* ===================================================
     قائمة المزيد - Bottom Sheet Drawer
     =================================================== */
}

/* ===================================================
   قائمة المزيد (خارج media query لتعمل على الجوال)
   =================================================== */
.moreMenuOverlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 1100;
  opacity: 0;
  transition: opacity .25s;
}

.moreMenuOverlay.open {
  display: block;
  opacity: 1;
}

.moreMenuDrawer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1200;
  background: #fff;
  border-radius: 28px 28px 0 0;
  padding: 12px 0 calc(20px + env(safe-area-inset-bottom, 0px));
  transform: translateY(100%);
  transition: transform .32s cubic-bezier(.32,.72,0,1);
  box-shadow: 0 -8px 40px rgba(21,68,90,.2);
}

.moreMenuDrawer.open {
  transform: translateY(0);
}

.moreMenuHandle {
  width: 44px;
  height: 4px;
  background: #e2e8f0;
  border-radius: 999px;
  margin: 0 auto 20px;
}

.moreMenuList {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 0 12px;
  max-height: 65vh;
  overflow-y: auto;
}

.moreMenuItem {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 16px;
  font-size: 16px;
  font-weight: 700;
  color: #15445a;
  text-decoration: none;
  background: transparent;
  border: none;
  cursor: pointer;
  width: 100%;
  text-align: right;
  font-family: Tajawal, sans-serif;
  transition: background .15s;
  -webkit-tap-highlight-color: transparent;
}

.moreMenuItem:active {
  background: rgba(21,68,90,.07);
}

.moreMenuLogout {
  color: #e11d48 !important;
  margin-top: 6px;
  border-top: 1px solid #f1f5f9;
  padding-top: 16px !important;
}

/* إخفاء الـ Drawer على سطح المكتب */
@media(min-width: 769px) {
  .moreMenuOverlay,
  .moreMenuDrawer { display: none !important; }
}

/* =====================================================
   تحسينات إضافية - أزرار أفقية وبطاقات أنيقة
   ===================================================== */

@media(max-width: 768px) {

  /* ===================================================
     إصلاح rowActions - أفقية دائماً
     =================================================== */
  .rowActions {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    align-items: center !important;
  }

  .rowActions .btn,
  .rowActions a.btn,
  .rowActions button.btn {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    text-align: center !important;
    padding: 10px 12px !important;
    font-size: 13px !important;
    border-radius: 12px !important;
    white-space: nowrap !important;
  }

  /* ===================================================
     صفحة تفاصيل المهمة - تحسين الأزرار
     =================================================== */
  /* الأزرار في أعلى الكارد */
  .card > div > .rowActions.noPrint {
    width: 100% !important;
    margin-top: 10px !important;
  }

  /* ===================================================
     صفحة المناسبات - بطاقات بدلاً من جدول
     =================================================== */
  .table tbody td[data-label="اسم المناسبة"] {
    flex-direction: column !important;
    gap: 4px !important;
    padding: 14px 16px 10px !important;
    border-bottom: 1px solid rgba(21,68,90,.07) !important;
    background: linear-gradient(135deg, rgba(21,68,90,.03) 0%, transparent 100%);
  }

  .table tbody td[data-label="اسم المناسبة"]::before {
    display: none !important;
  }

  .table tbody td[data-label="اسم المناسبة"] b {
    font-size: 15px !important;
    font-weight: 900 !important;
    color: #15445a !important;
  }

  /* أزرار المناسبات - شبكة 2×2 */
  .table tbody td[data-label="تقارير"],
  .table tbody td[data-label="ملفات"],
  .table tbody td[data-label="أرشيف"],
  .table tbody td[data-label="إجراءات"] {
    padding: 4px 16px !important;
    border: none !important;
  }

  .table tbody td[data-label="تقارير"]::before,
  .table tbody td[data-label="ملفات"]::before,
  .table tbody td[data-label="أرشيف"]::before,
  .table tbody td[data-label="إجراءات"]::before {
    display: none !important;
  }

  /* دمج أزرار المناسبات في صف واحد */
  .eventActionsRow {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    padding: 8px 16px 14px !important;
  }

  .eventActionsRow .btn {
    flex: 1 1 calc(50% - 4px) !important;
    text-align: center !important;
    padding: 10px 8px !important;
    font-size: 13px !important;
    border-radius: 12px !important;
    min-width: 0 !important;
  }

  /* ===================================================
     لوحة التحكم - أزرار الإجراءات السريعة
     =================================================== */
  .dashboardActions {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
    margin-top: 12px !important;
  }

  .dashboardActions .btn {
    text-align: center !important;
    padding: 12px 8px !important;
    border-radius: 14px !important;
    font-size: 13px !important;
    font-weight: 700 !important;
  }

  .dashboardActions .btnGood {
    grid-column: 1 / -1 !important;
  }

  /* ===================================================
     بطاقة تفاصيل المهمة - تحسينات إضافية
     =================================================== */
  .taskDetailCard {
    border-radius: 20px !important;
    overflow: hidden !important;
  }

  .taskDetailCard h2 {
    font-size: 18px !important;
    line-height: 1.4 !important;
  }

  /* شبكة المعلومات في تفاصيل المهمة */
  .grid2 {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }

  /* ===================================================
     تحسين الجدول العام - خلايا أكثر إحكاماً
     =================================================== */
  .table tbody td {
    padding: 7px 16px !important;
  }

  /* خلية الفترة في المناسبات */
  .table tbody td[data-label="الفترة"],
  .table tbody td[data-label="المشرف"] {
    color: #64748b !important;
    font-size: 13px !important;
  }

  /* ===================================================
     تحسين شريط التقدم في البطاقات
     =================================================== */
  .table tbody td[data-label="التقدم"] {
    padding: 8px 16px !important;
  }

  .table tbody td[data-label="التقدم"] .progressWrap {
    flex-direction: row !important;
    align-items: center !important;
    gap: 8px !important;
  }

  /* ===================================================
     تحسين الكروت الإحصائية في لوحة التحكم
     =================================================== */
  .grid4 {
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
  }

  .kpi .value {
    font-size: 28px !important;
  }

  /* ===================================================
     تحسين نموذج الإضافة على الجوال
     =================================================== */
  .formGrid2 {
    grid-template-columns: 1fr !important;
  }

  /* ===================================================
     إخفاء العناصر غير الضرورية على الجوال
     =================================================== */
  .desktopOnly {
    display: none !important;
  }

  /* ===================================================
     تحسين الفوتر
     =================================================== */
  footer, .footer {
    display: none !important;
  }

  /* ===================================================
     تحسين عناوين الصفحات
     =================================================== */
  .pageTitle {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
  }

  .pageTitle h2 {
    margin: 0 !important;
  }

  /* ===================================================
     تحسين الإشعارات والتنبيهات
     =================================================== */
  .notice, .error {
    border-radius: 16px !important;
    padding: 12px 16px !important;
    font-size: 14px !important;
  }

  /* ===================================================
     تحسين حقول النماذج
     =================================================== */
  label {
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #475569 !important;
    margin-bottom: 4px !important;
    display: block !important;
  }

  /* ===================================================
     تحسين أزرار الحفظ والإلغاء في النماذج
     =================================================== */
  .formActions {
    display: flex !important;
    gap: 10px !important;
    margin-top: 16px !important;
  }

  .formActions .btn {
    flex: 1 !important;
    text-align: center !important;
    padding: 14px !important;
    font-size: 15px !important;
    border-radius: 14px !important;
  }

  /* ===================================================
     تحسين جدول المهام - إخفاء الأعمدة الثانوية
     =================================================== */
  .table tbody td[data-label="المناسبة"],
  .table tbody td[data-label="المشرف"] {
    font-size: 12px !important;
    color: #64748b !important;
    padding: 4px 16px !important;
  }

  /* ===================================================
     تحسين صفحة مهامي
     =================================================== */
  .myTasksCard {
    border-radius: 20px !important;
    overflow: hidden !important;
  }

  /* ===================================================
     تحسين ألوان الحالات في البطاقات
     =================================================== */
  .table tbody tr:has(.badge.bBad) {
    border-right: 4px solid #ef4444 !important;
  }

  .table tbody tr:has(.badge.bGood) {
    border-right: 4px solid #10b981 !important;
  }

  .table tbody tr:has(.badge.bWarn) {
    border-right: 4px solid #f59e0b !important;
  }

  .table tbody tr:has(.badge.bInfo) {
    border-right: 4px solid #3b82f6 !important;
  }

}

/* =====================================================
   تحسينات متقدمة - المستخدمون والإشعارات ولوحة التحكم
   ===================================================== */

@media(max-width: 768px) {

  /* ===================================================
     صفحة المستخدمين - بطاقات أنيقة
     =================================================== */

  /* خلية الاسم كعنوان البطاقة */
  .table tbody td[data-label="الاسم"] {
    flex-direction: column !important;
    gap: 2px !important;
    padding: 14px 16px 10px !important;
    border-bottom: 1px solid rgba(21,68,90,.07) !important;
    background: linear-gradient(135deg, rgba(21,68,90,.04) 0%, transparent 100%) !important;
  }

  .table tbody td[data-label="الاسم"]::before {
    display: none !important;
  }

  .table tbody td[data-label="الاسم"] b {
    font-size: 16px !important;
    font-weight: 900 !important;
    color: #15445a !important;
  }

  /* خلية الإجراءات في المستخدمين */
  .table tbody td[data-label="إجراءات"] {
    padding: 10px 16px 14px !important;
    border-top: 1px solid rgba(21,68,90,.07) !important;
  }

  .table tbody td[data-label="إجراءات"]::before {
    display: none !important;
  }

  .table tbody td[data-label="إجراءات"] .btn,
  .table tbody td[data-label="إجراءات"] a.btn {
    width: 100% !important;
    text-align: center !important;
    padding: 11px !important;
    font-size: 14px !important;
  }

  /* إخفاء خلايا النوع والتخصص الأقل أهمية */
  .table tbody td[data-label="النوع"],
  .table tbody td[data-label="دخول"] {
    display: none !important;
  }

  /* ===================================================
     صفحة الإشعارات - تحسين البطاقات
     =================================================== */

  /* بطاقة الإشعار */
  .notifCard {
    border-radius: 18px !important;
    padding: 14px 16px !important;
    margin-bottom: 8px !important;
    border: 1.5px solid rgba(21,68,90,.08) !important;
    background: #fff !important;
    box-shadow: 0 2px 8px rgba(21,68,90,.05) !important;
  }

  .notifCard.unread {
    border-color: rgba(14,165,233,.4) !important;
    background: rgba(14,165,233,.03) !important;
  }

  /* أزرار الإشعارات - أفقية */
  .notifActions {
    display: flex !important;
    flex-direction: row !important;
    gap: 8px !important;
    margin-top: 10px !important;
    width: 100% !important;
  }

  .notifActions .btn {
    flex: 1 !important;
    text-align: center !important;
    padding: 9px 12px !important;
    font-size: 13px !important;
    border-radius: 12px !important;
  }

  /* ===================================================
     لوحة التحكم - إصلاح أزرار الإجراءات السريعة
     =================================================== */
  .dashboardActions {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
    width: 100% !important;
    margin-top: 14px !important;
  }

  .dashboardActions .btn {
    text-align: center !important;
    padding: 12px 8px !important;
    border-radius: 14px !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    width: 100% !important;
  }

  /* زر إضافة مهمة يمتد على العرض الكامل */
  .dashboardActions .btnGood:first-child {
    grid-column: 1 / -1 !important;
    padding: 14px !important;
    font-size: 15px !important;
  }

  /* ===================================================
     تحسين الكروت الإحصائية
     =================================================== */
  .kpi {
    padding: 16px 12px !important;
    text-align: center !important;
  }

  .kpi .label {
    font-size: 11px !important;
    color: #64748b !important;
    font-weight: 700 !important;
    margin-bottom: 6px !important;
  }

  .kpi .value {
    font-size: 32px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
  }

  /* ===================================================
     شريط التقدم في لوحة التحكم
     =================================================== */
  .progressWrap {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 10px !important;
    width: 100% !important;
  }

  .bar {
    flex: 1 !important;
    height: 8px !important;
    border-radius: 999px !important;
  }

  /* ===================================================
     تحسين عام للجداول - إزالة الحدود الزائدة
     =================================================== */
  .table tbody tr {
    margin-bottom: 14px !important;
  }

  /* تحسين خلية الحالة */
  .table tbody td[data-label="الحالة"] {
    padding: 8px 16px !important;
  }

  /* تحسين خلية الدور */
  .table tbody td[data-label="الدور"] {
    font-weight: 700 !important;
    color: #15445a !important;
  }

  /* ===================================================
     تحسين صفحة تفاصيل المهمة - شبكة المعلومات
     =================================================== */
  .taskInfoGrid {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
    margin-top: 12px !important;
  }

  .taskInfoItem {
    background: rgba(21,68,90,.03) !important;
    border-radius: 12px !important;
    padding: 10px 12px !important;
  }

  .taskInfoItem .taskInfoLabel {
    font-size: 11px !important;
    color: #94a3b8 !important;
    font-weight: 700 !important;
    margin-bottom: 4px !important;
  }

  .taskInfoItem .taskInfoValue {
    font-size: 14px !important;
    font-weight: 800 !important;
    color: #15445a !important;
  }

  /* ===================================================
     تحسين الـ Help text
     =================================================== */
  .help {
    font-size: 12px !important;
    color: #94a3b8 !important;
    padding: 8px 12px !important;
    background: rgba(21,68,90,.03) !important;
    border-radius: 10px !important;
    margin-top: 6px !important;
  }

}
