﻿/* =================================================================
   AppStyles - كلاس عام يحتوي على جميع استايلات الواجهات (منظف)
   ================================================================= */

/* 1. الخطوط والأساسيات */
@font-face {
    font-family: 'Cairo';
    src: url('../fonts/Cairo-Regular.ttf') format('truetype');
    font-weight: 400;
}

@font-face {
    font-family: 'Cairo';
    src: url('../fonts/Cairo-Bold.ttf') format('truetype');
    font-weight: 700;
}

@font-face {
    font-family: 'Cairo';
    src: url('../fonts/Cairo-Black.ttf') format('truetype');
    font-weight: 900;
}

/* تعريف الخطوط العالمي */
* {
    font-family: 'Cairo', sans-serif !important;
}

/* حماية FontAwesome - تعريف موحد */
.fas, .far, .fa, .fa-solid, .fa-regular, .fa-brands,
[class*="fa-"],
i[class*="fa-"] {
    font-family: 'Font Awesome 5 Free', 'Font Awesome 6 Free' !important;
    font-weight: 900 !important;
    font-style: normal !important;
}


body.home-page { 
    font-family: 'Cairo', sans-serif !important;
    background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 100%);
    height: 100vh;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

body.login-page { 
    font-family: 'Cairo', sans-serif !important; 
    background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 100%);  
    min-height: 100vh;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 30px;
}

/* 3. البطاقات (Cards) */
.header-card {
    background: white;
    padding: 10px 25px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border-bottom: 1px solid #e2e8f0;
    margin-bottom: 15px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.main-glass-card {
    background: white;
    padding: 25px 30px;
    border-radius: 15px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    border: 1px solid #e2e8f0;
}

.main-glass-box {
    background: rgba(255, 255, 255, 0.75);
    border-radius: 15px;
    border: 1px solid #e2e8f0;
    width: 98%;
    max-width: 1450px;
    height: 94vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    font-family: 'Cairo', sans-serif !important;
}

.print-container {
    max-width: 6xl;
    margin: 0 auto;
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    border: 1px solid #e5e7eb;
}



.report-container { 
    width: 210mm; 
    height: 270mm; 
    background: white; 
    padding: 15mm 20mm; 
    border: 1px solid #1e3a8a; 
    display: none; 
    flex-direction: column; 
    position: fixed; 
    top: 0;  
    left: 50%; 
    transform: translateX(-50%); 
    box-shadow: 0 0 20px rgba(0,0,0,0.2);
    box-sizing: border-box; 
    overflow: hidden; 
    font-size: 0.85rem;
    z-index: 1000;
}



.signature-section {
    position: absolute;
    bottom: 20px;
    left: 10mm;
    right: 10mm;
    width: auto;
}

.signature-line { 
    border-top: 3px solid #1e3a8a; 
    margin-top: 10px; 
}

/* 4. الحاويات الخاصة */
.login-container { 
    background: rgba(255, 255, 255, 0.75); 
    backdrop-filter: blur(12px); 
    -webkit-backdrop-filter: blur(12px);
    border-radius: 20px; 
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
    padding: 25px;
    width: 340px;
    display: inline-block;
    margin: 10px;
    vertical-align: top;
    text-align: right;
}

.login-container .field-input {
    background: rgba(255, 255, 255, 0.8) !important;
    border: 1px solid rgba(226, 232, 240, 0.5) !important;
}

/* 5. العناوين */
.section-header {
    font-size: 1.1rem; 
    font-weight: 700 !important;
    color: #1e3a8a;
    border-right: 4px solid #3b82f6;
    padding-right: 12px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-title { 
    font-size: 1.2rem; 
    font-weight: 900; 
    color: #1e3a8a; 
    border-right: 5px solid #3b82f6; 
    padding-right: 12px; 
    margin-bottom: 15px; 
}

.logo { text-align: center; margin-bottom: 25px; }
.logo i { font-size: 80px; color: #3b82f6; display: block; margin-bottom: 10px; }
.logo h1 { font-size: 32px; font-weight: 900; color: #1e3a8a; margin: 0; }
.logo p { color: #64748b; font-weight: 700; font-size: 18px; }

.grid-wrapper { text-align: center; width: 100%; }

/* 6. الحقول (Inputs) */
.field-input {
    background: #ffffff;
    border: 1.5px solid #cbd5e1;
    border-radius: 10px;
    padding: 0 12px;
    outline: none;
    width: 100%;
    font-size: 0.90rem;
    height: 42px;
    font-weight: 700;
    color: #1e293b;
    text-align: center;
    transition: all 0.3s;
}

.field-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.field-label {
    display: block;
    font-size: 0.90rem;
    font-weight: 700;
    color: #475569;
    margin-bottom: 5px;
}

.form-control {
    width: 100%;
    padding: 10px;
    border: 2px solid #cbd5e1; 
    border-radius: 8px;
    font-family: 'Cairo', sans-serif;
    font-weight: bold;
    color: #1e3a8a;
    background-color: #ffffff;
    outline: none;
    transition: all 0.3s ease;
    margin-top: 3px;
}

.form-control:focus {
    border-color: #1e3a8a; 
    box-shadow: 0 0 0 3px rgba(30, 58, 138, 0.1);
}

.form-control[readonly] {
    background-color: #f8fafc;
    color: #64748b;
    cursor: not-allowed;
    border-color: #e2e8f0;
}

.report-input {
    height: 40px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    text-align: center;
    width: 100%;
}

.action-label {
    display: block;
    font-weight: 700;
    color: #475569;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.field-group {
    margin-bottom: 12px;
}

.input-group { position: relative; margin-bottom: 15px; }
.input-group i.left-icon { position: absolute; right: 15px; top: 15px; color: #3b82f6; z-index: 10; }

/* تعديلات خاصة بـ login-container */
.login-container .field-input,
.login-container select { 
    width: 100% !important;
    padding: 10px 45px 10px 15px !important;
    border: 2px solid #e2e8f0 !important; 
    border-radius: 10px;
    font-size: 16px;
    height: 48px !important;
    box-sizing: border-box;
    text-align: center !important;
}

.login-container .universal-btn { 
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    line-height: 48px !important;
    width: 100% !important; 
    height: 48px; 
    padding: 0 16px !important;
    background: #2563eb; 
    color: white !important; 
    border-radius: 10px; 
    font-weight: 700; 
    text-decoration: none !important; 
    margin-bottom: 10px;
    cursor: pointer;
}

.login-container .input-group i.left-icon {
    position: absolute;
    left: 15px;
    right: auto;
    top: 50%;
    transform: translateY(-50%);
    color: #3b82f6;
    z-index: 10;
}

/* 7. الأزرار */
.universal-btn { 
    display: inline-flex !important; 
    align-items: center; 
    justify-content: center; 
    gap: 8px;
    padding: 8px 16px !important;
    border-radius: 10px !important; 
    font-weight: 900 !important; 
    cursor: pointer;
    border: none !important;
    color: white !important;
    transition: all 0.3s ease !important;
    font-size: 0.9rem !important;
    box-sizing: border-box;
    font-family: 'Cairo', sans-serif !important;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    text-decoration: none !important;
    background: #2563eb;
}

.universal-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.universal-btn:hover::before {
    left: 100%;
}

.universal-btn:hover { 
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.universal-btn i {
    font-family: 'Font Awesome 5 Free' !important;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    position: relative;
    z-index: 2;
}

.universal-btn:hover i {
    transform: rotate(180deg) scale(1.1);
}

.btn-modern {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 10px;
    font-weight: 700;
    color: white !important;
    transition: 0.3s;
    border: none;
    cursor: pointer;
}

.btn-modern:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

/* ألوان الأزرار */
.btn-blue { 
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 50%, #1d4ed8 100%) !important;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3) !important;
}

.btn-blue:hover { 
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 50%, #1e40af 100%) !important;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4) !important;
}

.btn-emerald { 
    background: linear-gradient(135deg, #10b981 0%, #059669 50%, #047857 100%) !important;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.3) !important;
}

.btn-emerald:hover { 
    background: linear-gradient(135deg, #059669 0%, #047857 50%, #065f46 100%) !important;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4) !important;
}

.btn-red { 
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 50%, #b91c1c 100%) !important;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3) !important;
}

.btn-red:hover { 
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 50%, #991b1b 100%) !important;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.4) !important;
}

.btn-indigo { 
    background: linear-gradient(135deg, #4338ca 0%, #3730a3 50%, #312e81 100%) !important;
    box-shadow: 0 2px 8px rgba(67, 56, 202, 0.3) !important;
}

.btn-indigo:hover { 
    background: linear-gradient(135deg, #3730a3 0%, #312e81 50%, #1e1b4b 100%) !important;
    box-shadow: 0 4px 15px rgba(67, 56, 202, 0.4) !important;
}

.btn-generate { 
    background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 50%, #d97706 100%) !important;
    box-shadow: 0 2px 8px rgba(251, 191, 36, 0.3) !important;
    color: #1e293b !important;
}

.btn-generate:hover { 
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 50%, #b45309 100%) !important;
    box-shadow: 0 4px 15px rgba(251, 191, 36, 0.4) !important;
    color: #1e293b !important;
}

.btn-print { 
    background: linear-gradient(135deg, #64748b 0%, #475569 50%, #334155 100%) !important;
    box-shadow: 0 2px 8px rgba(100, 116, 139, 0.3) !important;
}

.btn-print:hover { 
    background: linear-gradient(135deg, #475569 0%, #334155 50%, #1e293b 100%) !important;
    box-shadow: 0 4px 15px rgba(100, 116, 139, 0.4) !important;
}

.btn-filter { 
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 50%, #b91c1c 100%) !important;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3) !important;
}

.btn-filter:hover { 
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 50%, #991b1b 100%) !important;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.4) !important;
}

.btn-green {
    background: linear-gradient(135deg, #10b981, #059669);
}

.btn-green:hover {
    background: linear-gradient(135deg, #059669, #047857);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
}

.btn-amber { 
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%) !important; 
}

.btn-amber:hover { 
    background: linear-gradient(135deg, #d97706 0%, #b45309 100%) !important; 
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.4) !important; 
}

.btn-save {
    background: linear-gradient(135deg, #10b981 0%, #059669 50%, #047857 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 900;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
}

.btn-save:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 50%, #065f46 100%);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.4);
    transform: translateY(-2px);
}

.btn-edit {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 50%, #1d4ed8 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 900;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
    margin-left: 10px;
}

.btn-edit:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 50%, #1e40af 100%);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.4);
    transform: translateY(-2px);
}

.btn-sm {
    padding: 6px 12px !important;
    font-size: 0.8rem !important;
    border-radius: 8px !important;
}

/* أزرار خاصة */
.btn-settings { background: #475569 !important; }
.btn-test { background: #10b981 !important; }
.btn-save.login { background: #4338ca !important; }

/* 8. حقول البحث */
.search-input {
    width: 100%;
    height: 38px;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 20px;
    padding: 0 40px 0 15px;
    font-size: 0.85rem;
    font-weight: 700;
}

.search-input-top { 
    width: 100%; 
    height: 38px; 
    background: #f8fafc; 
    border: 2px solid #e2e8f0; 
    border-radius: 20px; 
    padding: 0 35px 0 15px; 
    font-size: 0.85rem; 
    font-weight: 700; 
}

/* 9. الجداول */
.custom-grid {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
}

.custom-grid th {
    background-color: #1e3a8a;
    color: white;
    padding: 12px;
    font-weight: 700;
    font-size: 0.85rem;
    text-align: center;
    font-family: 'Cairo', sans-serif !important;
}

.custom-grid td {
    background: white;
    padding: 10px;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.85rem;
    font-weight: 700;
    color: #334155;
    text-align: center;
    font-family: 'Cairo', sans-serif !important;
}

.gv-style {
    width: 100%;
    border-collapse: collapse;
}

.gv-style th {
    background-color: #fef2f2;
    color: #991b1b;
    padding: 12px;
    font-weight: 900;
    border-bottom: 2px solid #fecaca;
    font-family: 'Cairo', sans-serif !important;
}

.gv-style td {
    padding: 12px;
    border-bottom: 1px solid #f1f5f9;
    text-align: center;
    font-family: 'Cairo', sans-serif !important;
}

.merged-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.7rem;
    table-layout: fixed;
}

.merged-table th {
    background: #1e3a8a;
    color: white;
    border: 1px solid #cbd5e1;
    padding: 6px 2px;
    font-size: 0.75rem;
}

.merged-table td {
    border: 1px solid #cbd5e1;
    text-align: center;
    padding: 4px 2px;
    overflow: hidden;
}

.donor-name-cell {
    background: #f8fafc;
    font-weight: 900;
    color: #1e3a8a;
    width: 150px;
    text-align: right !important;
    padding-right: 10px !important;
}

.amount-val {
    font-weight: 900;
    color: #1d4ed8;
}

.date-row {
    background: #fdfdfd;
    font-size: 0.65rem;
    color: #64748b;
}

.total-cell {
    background: #eff6ff;
    font-weight: 900;
    color: #000;
    font-size: 0.8rem;
}

/* 10. أزرار خاصة بالجداول */
.edit-btn {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 6px 12px !important;
    border-radius: 8px !important;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 50%, #1d4ed8 100%) !important;
    color: white !important;
    transition: all 0.3s ease !important;
    font-size: 0.8rem !important;
    font-weight: 900 !important;
    text-decoration: none !important;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(59, 130, 246, 0.3) !important;
}

.edit-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.edit-btn:hover::before {
    left: 100%;
}

.edit-btn:hover { 
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4) !important;
}

.edit-btn i {
    font-family: 'Font Awesome 5 Free' !important;
    transition: all 0.3s ease;
    position: relative;
    z-index: 2;
}

.edit-btn:hover i {
    transform: rotate(180deg) scale(1.1);
}

/* 11. استايلات أخرى */
.member-row { 
    border-radius: 10px; 
    margin-bottom: 8px; 
    border: 1px solid #e2e8f0; 
    transition: all 0.2s ease; 
}

.error-message { 
    background: #fee2e2; color: #ef4444; padding: 10px; border-radius: 8px;
    margin-bottom: 15px; text-align: center; font-weight: bold; font-size: 14px;
    border: 1px solid #fecaca;
}

.success-message {
    background: #d1fae5; color: #065f46; padding: 10px; border-radius: 8px;
    margin-bottom: 15px; text-align: center; font-weight: bold; font-size: 14px;
    border: 1px solid #a7f3d0;
}

#pnlDbSettings { display: none; }
.show-db #pnlDbSettings { display: inline-block !important; }

/* 12. التقارير والإحصائيات */
.stat-card {
    background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 100%);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    border-right: 5px solid #3b82f6;
    position: relative;
    overflow: hidden;
}

.report-card {
    background-color: #ffffff !important;
    background-image: none !important;
    border: 1px solid rgba(226,232,240,1) !important;
    border-right: none !important;
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
}
.report-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    transition: left 0.6s ease;
}

.stat-card:hover::before {
    left: 100%;
}

.stat-card:hover { 
    transform: translateY(-5px); 
    box-shadow: 0 8px 25px rgba(0,0,0,0.1); 
}

.stat-card i {
    transition: all 0.4s ease;
}

.stat-card:hover i {
    transform: rotate(360deg) scale(1.1);
}

.stat-card.updating {
    transform: scale(0.98);
    opacity: 0.7;
}

.report-link-card {
    background: white;
    border-radius: 12px;
    padding: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    border: 1px solid #e2e8f0;
    transition: all 0.3s;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.report-link-card:hover { 
    border-color: #3b82f6; 
    background: #eff6ff; 
    transform: scale(1.02);
    box-shadow: 0 4px 15px rgba(59,130,246,0.2);
}

.report-link-card .icon-circle {
    transition: all 0.3s ease;
}

.report-link-card:hover .icon-circle {
    transform: scale(1.1) rotate(180deg);
}

/* 13. استمارات البيانات والطباعة */
.report-page {
    background-color: white;
    width: 210mm; 
    min-height: 296mm;
    padding: 8mm; 
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    margin: 10px auto;
    font-size: 0.85rem;
}

.report-box { 
    border: 2.5px solid #1e3a8a; 
    padding: 15px; 
    border-radius: 10px; 
    display: flex;
    flex-direction: column;
    height: 100%;
}

.data-label { 
    font-weight: 800; 
    color: #1e3a8a; 
    font-size: 13px; 
}

.data-value { 
    font-weight: 700; 
    color: #111827; 
    border-bottom: 1.5px dashed #9ca3af; 
    padding: 0 4px; 
    font-size: 15px;
    display: inline-block;
}

.report-table { 
    width: 100%; 
    border-collapse: collapse; 
    margin-top: 5px;
}

.report-table th { 
    background-color: #1e3a8a !important; 
    color: white !important; 
    padding: 6px; 
    border: 1px solid #1e3a8a;
    font-weight: 900;
}

.report-table td { 
    padding: 4px; 
    border: 1px solid #cbd5e1; 
    color: #000; 
    text-align: center;
    font-weight: 700;
}

/* 14. الطباعة */
@media print {
    .no-print { display: none !important; }
    #printArea { display: block !important; }
    body { background: white; padding: 0; }
    * { font-family: 'Cairo', sans-serif !important; }
    
    @page {
        size: A4;
        margin: 0;
    }
    
    body { 
        background-color: white; 
        padding: 0; 
        display: block; 
    }
    
    .report-page { 
        box-shadow: none; 
        margin: 0; 
        width: 210mm; 
        height: 297mm; 
        padding-top: 6mm;
        padding-bottom: 8mm;
        padding-right: 6mm;
        padding-left: 6mm;
        page-break-after: auto;
    }
    
    .print-container { 
        box-shadow: none !important; 
        border: none !important; 
        width: 100% !important; 
        max-width: 100% !important; 
    }
    
    .gv-header { 
        background-color: #f1f5f9 !important; 
        -webkit-print-color-adjust: exact; 
    }
    
    .report-container { 
        display: flex !important; 
        border: none; 
        box-shadow: none; 
        margin: 0; 
        width: 210mm; 
        height: 297mm; 
        page-break-after: avoid;
        page-break-before: avoid;
        font-size: 0.85rem;
    }
    
    .signature-section {
        position: absolute;
        bottom: 20px;
        left: 10mm;
        right: 10mm;
        width: auto;
    }
}

/* 15. واجهة DataExchange */
.tabs-wrapper {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 30px;
    background: #f1f5f9;
    padding: 5px;
    border-radius: 15px;
}

.tab-btn {
    padding: 10px 25px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.3s ease;
    color: #64748b;
    font-size: 0.9rem;
}

.tab-btn.active {
    background: white;
    color: #1e3a8a;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.central-upload-zone {
    background: #f8fafc;
    border: 3px dashed #3b82f6;
    border-radius: 20px;
    padding: 40px 20px;
    text-align: center;
    transition: all 0.3s ease;
    margin-bottom: 30px;
}

.central-upload-zone.families {
    border-color: #10b981;
}

.central-upload-zone.donations {
    border-color: #f59e0b;
}

.tab-content { 
    display: none; 
}

.tab-content.active { 
    display: block; 
    animation: fadeIn 0.5s ease; 
}

.file-upload-wrapper {
    display: inline-block;
    position: relative;
}

.file-upload-wrapper input[type="file"] {
    position: absolute;
    opacity: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.file-upload-label {
    display: inline-block;
    padding: 10px 20px;
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: white;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.3s ease;
}

.file-upload-label:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

/* 16. واجهة Home_Optimized */
.top-bar {
    height: 75px;
    background: rgba(255, 255, 255, 0.75);
    padding: 0 30px;
    border-bottom: 4px solid #3b82f6;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
    font-family: 'Cairo', sans-serif !important;
    border-radius: 15px;
}

.top-bar span {
    color: #1e3a8a;
    font-weight: 900;
    font-size: 1.2rem;
    font-family: 'Cairo', sans-serif !important;
}

.top-bar .fas.fa-seedling {
    color: #3b82f6 !important;
    transition: all 0.3s ease;
    font-family: 'Font Awesome 5 Free' !important;
}

.top-bar .fas.fa-seedling:hover {
    color: #2563eb !important;
    transform: rotate(180deg) scale(1.1);
}

.notification-bell {
    color: #3b82f6 !important;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.notification-bell:hover {
    color: #2563eb !important;
    transform: scale(1.1);
}

.notification-bell .fas.fa-bell {
    color: #3b82f6 !important;
    font-family: 'Font Awesome 5 Free' !important;
}

.notification-bell:hover .fas.fa-bell {
    color: #2563eb !important;
}

.notification-bell .notification-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #ef4444 !important;
    color: white !important;
    font-size: 10px;
    font-weight: 900;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Cairo', sans-serif !important;
    border: 2px solid white;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.notification-panel {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    width: 280px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.16);
    overflow: hidden;
    z-index: 9999;
    display: none;
}

.notification-panel.active {
    display: block;
}

.notification-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
    font-size: 13px;
    font-weight: 700;
}

.notification-header button {
    background: transparent;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 12px;
    font-weight: 700;
}

.notification-list {
    max-height: 280px;
    overflow-y: auto;
}

.notification-item {
    padding: 10px 12px;
    border-bottom: 1px solid #f1f5f9;
}

.notification-item:last-child {
    border-bottom: none;
}

.notif-title {
    font-size: 12px;
    font-weight: 800;
    color: #0f172a;
}

.notif-message {
    font-size: 11px;
    color: #475569;
    margin-top: 3px;
    line-height: 1.45;
}

.empty-notif {
    padding: 18px 12px;
    text-align: center;
    color: #94a3b8;
    font-size: 12px;
}

.layout-container {
    display: flex;
    flex: 1;
    overflow: hidden;
    font-family: 'Cairo', sans-serif !important;
}

.sidebar-right {
    width: 260px;
    padding: 20px 10px;
    display: flex;
    flex-direction: column;
    margin-right: 12px;
    background: rgba(255, 255, 255, 0.75);
    border-left: 1px solid #e2e8f0;
    overflow-y: auto;
    font-family: 'Cairo', sans-serif !important;
    border-radius: 15px;
    height: 81vh;
    border: 1px solid #f1f5f9;
    margin-top: 16px;
}

.nav-button {
    width: 100%;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    padding: 14px 18px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #475569;
    font-weight: 700;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
    text-align: right;
    font-family: 'Cairo', sans-serif !important;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    margin-bottom: 12px;
}

.nav-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.6s;
}

.nav-button:hover::before {
    left: 100%;
}

.nav-button:hover {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 50%, #1d4ed8 100%) !important;
    color: white !important;
    border-color: #1e40af;
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4), 0 0 20px rgba(59, 130, 246, 0.2);
    transform: translateY(-2px) scale(1.02);
    font-family: 'Cairo', sans-serif !important;
}

.nav-button.active {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 50%, #1d4ed8 100%) !important;
    color: white !important;
    border-color: #1e40af;
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4), 0 0 20px rgba(59, 130, 246, 0.2);
    transform: translateY(-1px);
    font-family: 'Cairo', sans-serif !important;
}

.nav-button i {
    color: #3b82f6;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 1.5rem;
    font-family: 'Font Awesome 5 Free' !important;
    position: relative;
    z-index: 2;
}

.nav-button:hover i, .nav-button.active i {
    color: white !important;
    transform: rotate(360deg) scale(1.2);
    font-family: 'Font Awesome 5 Free' !important;
    filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.8));
}

.dropdown-container {
    max-height: 0;
    overflow: hidden;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 100%);
    border-radius: 12px;
    margin: 0 5px;
    font-family: 'Cairo', sans-serif !important;
    position: relative;
}

.dropdown-container::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #3b82f6, #8b5cf6, #ec4899, #3b82f6);
    border-radius: 15px;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: -1;
}

.dropdown-container.show::before {
    opacity: 0.3;
}

.dropdown-container.show {
    max-height: 400px;
    padding: 8px;
    border: 2px solid transparent;
    margin-top: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

.dropdown-item {
    width: 100%;
    padding: 12px 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #1e293b !important;
    font-weight: 700;
    font-size: 0.95rem;
    border-radius: 15px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    border: 2px solid transparent;
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    margin-bottom: 6px;
    font-family: 'Cairo', sans-serif !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    position: relative;
    overflow: hidden;
}

.dropdown-item::before {
    content: '';
    position: absolute;
    top: 0;
    right: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(59, 130, 246, 0.1), transparent);
    transition: right 0.6s;
}

.dropdown-item:hover::before {
    right: 100%;
}

.dropdown-item:hover {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 50%, #1d4ed8 100%) !important;
    color: white !important;
    border-color: #1e40af;
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4), 0 0 20px rgba(59, 130, 246, 0.3);
    transform: translateY(-3px) scale(1.03);
    font-family: 'Cairo', sans-serif !important;
}

.dropdown-item:last-child {
    margin-bottom: 0;
}

.dropdown-item i {
    font-family: 'Font Awesome 5 Free' !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 1.2rem;
    position: relative;
    z-index: 2;
}

.dropdown-item:hover i {
    transform: rotateY(360deg) scale(1.3);
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.9));
}

.content-area {
    flex: 1;
    background: rgba(255, 255, 255, 0.75);
    margin: 15px;
    border-radius: 15px;
    border: 1px solid #f1f5f9;
    overflow-y: auto;
    position: relative;
    font-family: 'Cairo', sans-serif !important;
}

/* 17. أيقونة الأدمن */
.admin-avatar {
    width: 42px;
    height: 42px;
    border-radius: 20%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: 'Cairo', sans-serif !important;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.admin-avatar::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: 20%;
    background: linear-gradient(45deg, #3b82f6, #8b5cf6, #ec4899, #3b82f6);
    z-index: -1;
    animation: rotate 3s linear infinite;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.admin-avatar:hover::before {
    opacity: 1;
}

.admin-avatar::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.6s ease;
}

.admin-avatar:hover::after {
    left: 100%;
}

.admin-avatar i {
    font-family: 'Font Awesome 5 Free' !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    z-index: 2;
}

.admin-avatar:hover i {
    transform: rotate(360deg) scale(1.2);
    filter: drop-shadow(0 0 10px rgba(59, 130, 246, 0.5));
}

/* أدوار الأدمن */
.admin-avatar.role-admin {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 50%, #fef3c7 100%);
    color: #d97706;
    border: 3px solid #fbbf24;
    box-shadow: 0 4px 12px rgba(217, 119, 6, 0.4), inset 0 2px 4px rgba(255, 255, 255, 0.6);
}

.admin-avatar.role-admin:hover {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 50%, #f59e0b 100%);
    color: white;
    transform: scale(1.15) translateY(-2px) rotate(5deg);
    box-shadow: 0 8px 25px rgba(217, 119, 6, 0.6), 0 0 20px rgba(251, 191, 36, 0.4);
    border-color: #d97706;
}

.admin-avatar.role-manager {
    background: linear-gradient(135deg, #fed7aa 0%, #fdba74 50%, #fed7aa 100%);
    color: #c2410c;
    border: 3px solid #fb923c;
    box-shadow: 0 4px 12px rgba(194, 65, 12, 0.3), inset 0 2px 4px rgba(255, 255, 255, 0.5);
}

.admin-avatar.role-manager:hover {
    background: linear-gradient(135deg, #ea580c 0%, #c2410c 50%, #ea580c 100%);
    color: white;
    transform: scale(1.15) translateY(-2px) rotate(5deg);
    box-shadow: 0 8px 25px rgba(194, 65, 12, 0.5), 0 0 20px rgba(251, 146, 60, 0.3);
    border-color: #c2410c;
}

.admin-avatar.role-user {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 50%, #dbeafe 100%);
    color: #1e40af;
    border: 3px solid #60a5fa;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2), inset 0 2px 4px rgba(255, 255, 255, 0.7);
}

.admin-avatar.role-user:hover {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 50%, #3b82f6 100%);
    color: white;
    transform: scale(1.15) translateY(-2px) rotate(5deg);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4), 0 0 20px rgba(96, 165, 250, 0.3);
    border-color: #2563eb;
}

.admin-avatar.role-default {
    background: linear-gradient(135deg, #f3f4f6 0%, #e5e7eb 50%, #f3f4f6 100%);
    color: #374151;
    border: 3px solid #9ca3af;
    box-shadow: 0 4px 12px rgba(107, 114, 128, 0.15), inset 0 2px 4px rgba(255, 255, 255, 0.6);
}

.admin-avatar.role-default:hover {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 50%, #6b7280 100%);
    color: white;
    transform: scale(1.15) translateY(-2px) rotate(5deg);
    box-shadow: 0 8px 25px rgba(107, 114, 128, 0.3), 0 0 20px rgba(156, 163, 175, 0.3);
    border-color: #4b5563;
}

/* اسم المستخدم */
.admin-name {
    font-weight: 900 !important;
    transition: all 0.3s ease;
    color: #4b5563 !important;
    text-shadow: 0 0 10px rgba(75, 85, 99, 0.3);
}

.admin-name.role-admin {
    color: #f59e0b !important;
    text-shadow: 0 0 10px rgba(245, 158, 11, 0.3);
}

.admin-name.role-manager {
    color: #6b7280 !important;
    text-shadow: 0 0 10px rgba(107, 114, 128, 0.3);
}

.admin-name.role-user {
    color: #ea580c !important;
    text-shadow: 0 0 10px rgba(234, 88, 12, 0.3);
}

.admin-name.role-default {
    color: #4b5563 !important;
    text-shadow: 0 0 10px rgba(75, 85, 99, 0.3);
}

/* 18. الإشعارات */
#notifBox {
    display: block;
    opacity: 0;
    visibility: hidden;
    transform: scale(0.9) translateY(-10px);
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 9999;
}

#notifBox.active {
    opacity: 1;
    visibility: visible;
    transform: scale(1) translateY(0);
}

.notif-item {
    border-bottom: 1px solid #f1f5f9;
    transition: background 0.2s;
}

.notif-item:last-child {
    border-bottom: none;
}

.notif-item:hover {
    background-color: #f8fafc;
}

.new-badge-animate {
    animation: pulse-soft 2s infinite;
}

/* 19. الأنيميشن */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes pulse-soft {
    0% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.4);
    }
    70% {
        box-shadow: 0 0 0 6px rgba(59, 130, 246, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(59, 130, 246, 0);
    }
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* 20. تصميم الصور */
.img-thumbnail {
    border: 3px solid #fbbf24 !important;
    border-radius: 8px !important;
    box-shadow: 0 4px 6px -1px rgba(251, 191, 36, 0.3) !important;
    transition: all 0.3s ease !important;
}

.img-thumbnail:hover {
    transform: scale(1.05) !important;
    box-shadow: 0 8px 12px -2px rgba(251, 191, 36, 0.4) !important;
}

.text-muted {
    color: #92400e !important;
    font-size: 0.85rem !important;
    font-weight: 600 !important;
    font-family: 'Cairo', sans-serif !important;
    margin-top: 8px !important;
    display: block !important;
}

.special-field {
    border: 2px solid #3b82f6 !important;
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%) !important;
    color: #1e40af !important;
    font-weight: 800 !important;
}

.health-field {
    border: 2px solid #ef4444 !important;
    background: linear-gradient(135deg, #fef2f2 0%, #fee2e2 100%) !important;
    color: #991b1b !important;
    font-weight: 800 !important;
}