* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-dark: #003366;
    --primary: #0f6600;
    --primary-light: #2596be;
    --secondary: #FF6600;
    --secondary-light: #FF9900;
    --accent-blue: #2596be;
    --accent-green: #2E7D32;
    --accent-red: #C62828;
    --accent-purple: #6A1B9A;
    --accent-orange: #F57C00;
    --accent-cyan: #0097A7;
    --accent-teal: #00796B;
    --accent-indigo: #3F51B5;
    --accent-pink: #C2185B;
    --accent-brown: #8D6E63;
    --light-bg: #F8F9FA;
    --card-bg: #FFFFFF;
    --text-primary: #1A237E;
    --text-secondary: #546E7A;
    --border-light: #E0E0E0;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
    --transition: all 0.3s ease;
}

body {
    font-family: 'Cairo', sans-serif;
    background: linear-gradient(135deg, #f0f4f8 0%, #e6ecf5 100%);
    min-height: 100vh;
    position: relative;
    color: var(--text-primary);
    line-height: 1.6;
}

/* خلفية مزخرفة */
.bg-pattern {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 5% 10%, rgba(0, 86, 179, 0.03) 0%, transparent 30%),
        radial-gradient(circle at 95% 90%, rgba(255, 102, 0, 0.03) 0%, transparent 30%),
        radial-gradient(circle at 80% 20%, rgba(46, 125, 50, 0.02) 0%, transparent 40%),
        radial-gradient(circle at 20% 80%, rgba(198, 40, 40, 0.02) 0%, transparent 40%);
    z-index: -1;
    pointer-events: none;
}

/* الحاوية الرئيسية */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 1.5rem;
    position: relative;
    z-index: 1;
}

/* ===== تنسيقات البطاقات الموسعة ===== */
.cpanel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.cpanel-card {
    background: var(--card-bg);
    border-radius: 28px;
    padding: 2rem 1.8rem;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
    display: flex;
    gap: 1.5rem;
    align-items: center;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(5px);
    background: rgba(255,255,255,0.95);
    min-height: 200px;
}

.cpanel-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-light);
}

.cpanel-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 6px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
}

.cpanel-card::after {
    content: '';
    position: absolute;
    bottom: -20px;
    right: -20px;
    width: 120px;
    height: 120px;
    background: radial-gradient(circle, rgba(15, 102, 0, 0.03) 0%, transparent 70%);
    border-radius: 50%;
    z-index: 0;
}

.cpanel-icon {
    width: 100px;
    height: 100px;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: white;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
    flex-shrink: 0;
    position: relative;
    z-index: 2;
}

.cpanel-card:hover .cpanel-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
}

.cpanel-icon i, .cpanel-icon .bi {
    font-size: 3rem;
    filter: drop-shadow(2px 4px 6px rgba(0,0,0,0.2));
}

.cpanel-content {
    flex: 1;
    position: relative;
    z-index: 2;
}

.cpanel-title {
    font-weight: 800;
    font-size: 1.4rem;
    margin: 0 0 0.5rem 0;
    color: var(--text-primary);
    line-height: 1.3;
}

.cpanel-desc {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin: 0 0 1rem 0;
    line-height: 1.6;
}

.cpanel-meta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cpanel-badge {
    font-weight: 700;
    font-size: 1rem;
    color: var(--primary);
    background: rgba(15, 102, 0, 0.1);
    padding: 0.4rem 1rem;
    border-radius: 50px;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    transition: var(--transition);
}

.cpanel-card:hover .cpanel-badge {
    background: var(--primary);
    color: white;
}

.cpanel-badge i {
    font-size: 0.9rem;
}

/* ===== Hero section موسع ===== */
.hero {
    background: linear-gradient(135deg, rgba(255,255,255,0.95), rgba(255,255,255,0.98));
    border-radius: 32px;
    padding: 2.5rem;
    box-shadow: var(--shadow-lg);
    margin-bottom: 2.5rem;
    border: 1px solid var(--border-light);
    backdrop-filter: blur(5px);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 60%;
    height: 200%;
    background: radial-gradient(circle, rgba(15, 102, 0, 0.03) 0%, transparent 70%);
    transform: rotate(15deg);
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 50%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 102, 0, 0.03) 0%, transparent 70%);
    transform: rotate(-10deg);
}

.hero h1 {
    font-size: 2.2rem;
    margin: 0 0 0.5rem 0;
    color: var(--primary-dark);
    font-weight: 800;
    position: relative;
    z-index: 2;
}

.hero p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 1.1rem;
    position: relative;
    z-index: 2;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    position: relative;
    z-index: 2;
}

.hero-actions a {
    margin-right: 0;
}

/* ===== أزرار محسنة ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    text-decoration: none;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    gap: 0.7rem;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-sm {
    padding: 0.6rem 1.3rem;
    font-size: 0.95rem;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.5s, height 0.5s;
    z-index: -1;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn-outline-info {
    background: transparent;
    border: 2px solid var(--accent-cyan);
    color: var(--accent-cyan);
}

.btn-outline-info:hover {
    background: var(--accent-cyan);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 151, 167, 0.3);
}

.btn-outline-primary {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline-primary:hover {
    background: var(--primary);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(15, 102, 0, 0.3);
}

.btn-outline-secondary {
    background: transparent;
    border: 2px solid var(--text-secondary);
    color: var(--text-secondary);
}

.btn-outline-secondary:hover {
    background: var(--text-secondary);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(84, 110, 122, 0.3);
}

/* ===== Dash card محسن ===== */
.dash-card {
    background: white;
    border-radius: 28px;
    padding: 2.2rem;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-light);
    margin-top: 2rem;
    position: relative;
    overflow: hidden;
}

.dash-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 6px;
    background: linear-gradient(90deg, var(--secondary), var(--secondary-light));
}

.dash-card h6 {
    color: var(--primary-dark);
    font-size: 1.3rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.dash-card h6 i {
    color: var(--secondary);
}

/* ===== Responsive ===== */
@media (max-width: 992px) {
    .container {
        padding: 1.5rem 1rem;
    }
    
    .hero h1 {
        font-size: 1.8rem;
    }
    
    .cpanel-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

@media (max-width: 768px) {
    .cpanel-grid {
        grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
        gap: 1.5rem;
    }
    
    .cpanel-card {
        padding: 1.5rem;
        min-height: 180px;
    }
    
    .cpanel-icon {
        width: 80px;
        height: 80px;
        font-size: 2.2rem;
    }
    
    .cpanel-icon i, .cpanel-icon .bi {
        font-size: 2.2rem;
    }
    
    .cpanel-title {
        font-size: 1.2rem;
    }
    
    .hero {
        padding: 1.8rem;
    }
    
    .hero .d-flex {
        flex-direction: column;
        text-align: center;
    }
    
    .hero-actions {
        justify-content: center;
    }
}

@media (max-width: 576px) {
    .cpanel-grid {
        grid-template-columns: 1fr;
    }
    
    .cpanel-card {
        padding: 1.5rem;
    }
    
    .cpanel-icon {
        width: 70px;
        height: 70px;
        font-size: 2rem;
    }
    
    .cpanel-icon i, .cpanel-icon .bi {
        font-size: 2rem;
    }
    
    .cpanel-title {
        font-size: 1.1rem;
    }
    
    .hero {
        padding: 1.5rem;
    }
    
    .hero h1 {
        font-size: 1.5rem;
    }
}

/* ألوان مختلفة ومميزة للبطاقات مع أيقونات فاخرة */
.cpanel-card:nth-child(1) .cpanel-icon { 
    background: linear-gradient(135deg, #06b6d4, #0891b2);
    box-shadow: 0 10px 20px rgba(6, 182, 212, 0.3);
}
.cpanel-card:nth-child(2) .cpanel-icon { 
    background: linear-gradient(135deg, #8b5cf6, #6d28d9);
    box-shadow: 0 10px 20px rgba(139, 92, 246, 0.3);
}
.cpanel-card:nth-child(3) .cpanel-icon { 
    background: linear-gradient(135deg, #f97316, #dc2626);
    box-shadow: 0 10px 20px rgba(249, 115, 22, 0.3);
}
.cpanel-card:nth-child(4) .cpanel-icon { 
    background: linear-gradient(135deg, #14b8a6, #0d9488);
    box-shadow: 0 10px 20px rgba(20, 184, 166, 0.3);
}
.cpanel-card:nth-child(5) .cpanel-icon { 
    background: linear-gradient(135deg, #10b981, #059669);
    box-shadow: 0 10px 20px rgba(16, 185, 129, 0.3);
}
/* ===== بطاقات الإحصائيات الحديثة ===== */
.stats-grid-modern {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.stat-card-modern {
    border-radius: 24px;
    padding: 1.8rem 1.5rem;
    color: white;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.stat-card-modern::before {
    content: '';
    position: absolute;
    top: -30%;
    right: -30%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255,255,255,0.2) 0%, transparent 70%);
    border-radius: 50%;
}

.stat-card-modern::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -30%;
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 70%);
    border-radius: 50%;
}

.stat-card-modern:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
}

.stat-icon {
    width: 70px;
    height: 70px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    position: relative;
    z-index: 2;
}

.stat-content {
    position: relative;
    z-index: 2;
}

.stat-number {
    font-size: 2.2rem;
    font-weight: 800;
    line-height: 1.2;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.stat-label {
    font-size: 1rem;
    opacity: 0.95;
    font-weight: 500;
}

/* ===== شبكة الملخص ===== */
.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 1rem 0;
}

.summary-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.8rem 1rem;
    background: var(--light-bg);
    border-radius: 12px;
    border: 1px solid var(--border-light);
    transition: var(--transition);
}

.summary-item:hover {
    background: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.summary-item i {
    font-size: 1.2rem;
}

.summary-item span {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.summary-item strong {
    color: var(--primary);
    font-size: 1.1rem;
    margin-right: 0.3rem;
}

/* ===== تحسينات للشاشات الصغيرة ===== */
@media (max-width: 768px) {
    .stats-grid-modern {
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
        gap: 1rem;
    }
    
    .stat-card-modern {
        padding: 1.2rem;
    }
    
    .stat-icon {
        width: 50px;
        height: 50px;
        font-size: 1.5rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .stat-label {
        font-size: 0.85rem;
    }
}

@media (max-width: 576px) {
    .stats-grid-modern {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .summary-grid {
        grid-template-columns: 1fr;
    }
}
.cpanel-card:nth-child(1)::before { background: linear-gradient(90deg, #06b6d4, #0891b2); }
.cpanel-card:nth-child(2)::before { background: linear-gradient(90deg, #8b5cf6, #6d28d9); }
.cpanel-card:nth-child(3)::before { background: linear-gradient(90deg, #f97316, #dc2626); }
.cpanel-card:nth-child(4)::before { background: linear-gradient(90deg, #14b8a6, #0d9488); }
.cpanel-card:nth-child(5)::before { background: linear-gradient(90deg, #10b981, #059669); }
