/* General Dashboard Layout */
body {
    font-family: 'Vazir', 'Tahoma', sans-serif;
    background-color: #f8f9fa;
    overflow-x: hidden;
}

/* Sidebar Styles */
#sidebar {
    min-width: 220px;
    max-width: 220px;
    background: #1e3a8a; /* Navy Blue */
    color: #fff;
    transition: all 0.3s;
    height: 100vh;
    position: fixed;
    right: 0;
    top: 0;
    z-index: 1000;
    box-shadow: -2px 0 5px rgba(0,0,0,0.1);
}

#sidebar .sidebar-header {
    padding: 15px;
    background: #172554; /* Darker Navy */
    text-align: center;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

#sidebar .sidebar-header h3 {
    margin-top: 10px;
    font-size: 1rem;
    font-weight: bold;
}

#sidebar ul.components {
    padding: 10px 0;
}

#sidebar ul li {
    padding: 0;
    list-style: none;
}

#sidebar ul li a {
    padding: 12px 15px;
    font-size: 0.9rem;
    display: block;
    color: rgba(255,255,255,0.8);
    text-decoration: none;
    transition: all 0.3s;
    border-right: 4px solid transparent;
}

#sidebar ul li a:hover {
    color: #fff;
    background: rgba(255,255,255,0.05);
}

#sidebar ul li a i {
    margin-left: 8px;
    width: 20px;
    text-align: center;
}

/* Active State - Orange */
#sidebar ul li a.active {
    background: #f97316; /* Orange */
    color: #fff;
    border-right: 4px solid #fff;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

/* Main Content Wrapper */
#content {
    width: calc(100% - 220px);
    margin-right: 220px; /* RTL Support */
    min-height: 100vh;
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
}

/* Page Content Padding */
.page-content {
    padding: 0 50px 30px 50px;
    flex: 1;
}

/* Header & Navbar */
.main-header-custom {
    background: white;
    padding: 15px 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 15px rgba(0,0,0,0.03);
    margin-bottom: 30px;
    position: relative;
    z-index: 900;
}

.header-title-section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0;
}

.header-user-section {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-profile-badge {
    display: flex;
    align-items: center;
    padding: 6px 12px;
    background: #f1f5f9;
    border-radius: 50px;
    color: #334155;
    font-weight: 500;
    font-size: 0.9rem;
    transition: all 0.3s;
    cursor: pointer;
}

.user-profile-badge:hover {
    background: #e2e8f0;
}

.logout-btn-header {
    color: #ef4444;
    font-size: 0.9rem;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 8px;
    transition: all 0.3s;
    background: rgba(239, 68, 68, 0.1);
}

.logout-btn-header:hover {
    background: #ef4444;
    color: white;
}

/* Cards & Widgets */
.card-custom {
    border: none;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    transition: transform 0.3s, box-shadow 0.3s;
    margin-bottom: 25px;
    position: relative;
    overflow: hidden;
    background: white;
}

/* Card Animation - Moving Light */
.card-custom::before {
    content: '';
    position: absolute;
    top: 0;
    left: -150%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent 0%,
        rgba(255, 255, 255, 0.4) 50%,
        transparent 100%
    );
    transform: skewX(-25deg);
    animation: shimmer 6s infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes shimmer {
    0% {
        left: -150%;
    }
    30% {
        left: 150%;
    }
    100% {
        left: 150%;
    }
}

.card-custom:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.06);
}

.card-body {
    padding: 25px;
    position: relative;
    z-index: 2;
}

/* Gradient Classes */
.card-gradient-green { background: linear-gradient(135deg, #10b981 0%, #059669 100%); color: white; }
.card-gradient-purple { background: linear-gradient(135deg, #8b5cf6 0%, #6d28d9 100%); color: white; }
.card-gradient-blue { background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%); color: white; }
.card-gradient-red { background: linear-gradient(135deg, #ef4444 0%, #b91c1c 100%); color: white; }
.card-gradient-orange { background: linear-gradient(135deg, #f59e0b 0%, #b45309 100%); color: white; }

.card-gradient-green .stat-title,
.card-gradient-purple .stat-title,
.card-gradient-blue .stat-title,
.card-gradient-red .stat-title,
.card-gradient-orange .stat-title {
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    font-weight: 500;
}

.card-gradient-green .stat-value,
.card-gradient-purple .stat-value,
.card-gradient-blue .stat-value,
.card-gradient-red .stat-value,
.card-gradient-orange .stat-value {
    color: white;
    font-size: 28px;
    font-weight: bold;
    margin-top: 10px;
}

.card-gradient-green small,
.card-gradient-purple small,
.card-gradient-blue small,
.card-gradient-red small,
.card-gradient-orange small {
    color: rgba(255, 255, 255, 0.8) !important;
}

/* Tables */
.table-custom {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    border-collapse: separate;
    border-spacing: 0;
    width: 100%;
    margin-bottom: 1rem;
}

.table-custom thead th {
    background-color: #f8fafc;
    color: #64748b;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    padding: 16px;
    border-bottom: 2px solid #e2e8f0;
}

.table-custom tbody td {
    padding: 16px;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
    vertical-align: middle;
}

.table-custom tbody tr:last-child td {
    border-bottom: none;
}

.table-custom tbody tr:hover {
    background-color: #f8fafc;
}

/* Buttons */
.btn-action-edit {
    background-color: #1e3a8a;
    color: white;
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 12px;
    border: none;
    transition: background-color 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-action-edit:hover {
    background-color: #172554;
    color: white;
}

.btn-action-delete {
    background-color: #ef4444;
    color: white;
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 12px;
    border: none;
    transition: background-color 0.2s;
    text-decoration: none;
    display: inline-block;
}

.btn-action-delete:hover {
    background-color: #dc2626;
    color: white;
}

/* Utilities */
.text-white-50 {
    color: rgba(255, 255, 255, 0.5) !important;
}

.fs-6 {
    font-size: 1rem !important;
}

/* Footer */
.main-footer {
    padding: 20px;
    text-align: center;
    font-size: 0.8rem;
    color: #94a3b8;
    background: transparent;
    border-top: 1px solid #e2e8f0;
    margin-top: auto;
    width: 100%;
}

.main-footer a {
    color: #64748b;
    text-decoration: none;
    font-weight: 500;
}

.main-footer a:hover {
    color: #1e3a8a;
}
