/* Clean Dashboard Styles */
:root {
    --primary: #2563eb;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --dark: #1f2937;
    --gray: #6b7280;
    --light-gray: #f3f4f6;
    --white: #ffffff;
}

/* Improved Pagination Styles */
.pagination {
    margin: 0;
}

.pagination .page-item {
    margin: 0 2px;
}

.pagination .page-item .page-link {
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    color: #5762d5;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    border: none;
}

.pagination .page-item.active .page-link {
    background-color: #5762d5;
    color: white;
    box-shadow: 0 3px 6px rgba(87, 98, 213, 0.3);
}

.pagination .page-item.disabled .page-link {
    opacity: 0.5;
}

/* Fix for Action Buttons to ensure text is on single line */
.action-btn {
    background-color: white;
    font-weight: 500;
    padding: 0.75rem 1.25rem;
    border-radius: 50px;
    transition: all 0.3s ease;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 170px;
}

.contribution-btn, .withdrawal-btn {
    min-width: 180px;
}
body {
    font-family: 'Tajawal', sans-serif;
    background-color: #f9fafb;
    margin: 0;
    padding: 0;
}

/* Dashboard Layout */
.dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

.dashboard-header {
    text-align: right;
    margin-bottom: 2.5rem;
}

.dashboard-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 0.5rem;
}

.dashboard-header p {
    color: var(--gray);
    margin: 0;
    font-size: 1.1rem;
}

/* Stats Grid */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

/* Stat Cards */
.stat-card {
    background-color: var(--white);
    border-radius: 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    padding: 1.75rem;
    text-align: right;
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.08);
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 5px;
    height: 100%;
    background-color: var(--primary);
    opacity: 0.7;
}

.stat-card:nth-child(1)::before {
    background-color: var(--success);
}

.stat-card:nth-child(2)::before {
    background-color: var(--danger);
}

.stat-card:nth-child(3)::before {
    background-color: var(--primary);
}

.stat-card h2 {
    color: var(--gray);
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.25rem;
}

.stat-value {
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    line-height: 1;
}

.value-success {
    color: var(--success);
}

.value-danger {
    color: var(--danger);
}

.value-warning {
    color: var(--warning);
}

.value-primary {
    color: var(--primary);
}

.stat-card .context {
    color: var(--gray);
    font-size: 0.95rem;
}

.stat-icon {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    font-size: 2.5rem;
    opacity: 0.15;
}

/* Member Stats */
.member-stats {
    background-color: var(--white);
    border-radius: 1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    padding: 1.75rem;
    margin-bottom: 2rem;
}

.member-stats h2 {
    color: var(--dark);
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    text-align: right;
}

.member-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    border-bottom: 1px solid var(--light-gray);
}

.member-row:last-child {
    border-bottom: none;
}

.member-type {
    color: var(--gray);
    font-size: 1.1rem;
}

.member-count {
    font-weight: 600;
    color: var(--dark);
    font-size: 1.25rem;
}

/* Footer */
.updated-text {
    text-align: center;
    color: var(--gray);
    font-size: 0.875rem;
    margin-top: 2.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--light-gray);
}

/* Search and Filter Styles */
.page-header {
    background-color: #5762d5;
    color: white;
}

.page-title {
    font-size: 1.75rem;
}

.add-member-btn {
    color: #5762d5;
    border: none;
    transition: all 0.3s ease;
}

.add-member-btn:hover {
    background-color: #f0f2ff;
    transform: translateY(-2px);
}

.card {
    border-radius: 0.75rem;
    overflow: hidden;
    border: none;
}

.filter-title {
    font-weight: 700;
    color: #333;
}

/* Updated search input styles */
.search-input {
    height: 46px;
    border: 1px solid #e0e0e0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    border-radius: 50px; /* Rounded search box */
}

/* Updated filter select styles */
.filter-select {
    height: 46px;
    border: 1px solid #e0e0e0;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    border-radius: 4px; /* Rectangular dropdown with slight rounding */
}

/* Table styles */
.member-table {
    border-collapse: separate;
    border-spacing: 0 8px;
}

.member-table thead th {
    border-bottom: none;
    padding-bottom: 15px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.member-table tbody tr {
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    background-color: white;
    border-radius: 10px;
    transition: transform 0.2s ease;
}

.member-table tbody tr:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.08);
}

.member-table tbody td {
    border: none;
    background-color: white;
    padding: 1rem 0.75rem;
}

.member-table tbody td:first-child {
    border-radius: 0 10px 10px 0;
}

.member-table tbody td:last-child {
    border-radius: 10px 0 0 10px;
}

/* Avatar */
.avatar {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Status and gender indicators */
.gender-male, .gender-female, .status-active, .status-inactive {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.gender-male {
    color: #5762d5;
    background-color: rgba(87, 98, 213, 0.1);
}

.gender-female {
    color: #d4237a;
    background-color: rgba(212, 35, 122, 0.1);
}

.status-active {
    color: #2e7d32;
    background-color: rgba(46, 125, 50, 0.1);
}

.status-inactive {
    color: #757575;
    background-color: rgba(117, 117, 117, 0.1);
}

/* Action buttons */
.action-buttons {
    display: flex;
    gap: 8px;
}

.action-btn {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    color: white;
}

.view-btn {
    background-color: #5762d5;
}

.edit-btn {
    background-color: #4CAF50;
}

.delete-btn {
    background-color: #f44336;
}

.action-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
    text-decoration: none;
    color: white;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

/* Responsive Design */
@media (max-width: 992px) {
    .stats-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .stats-container {
        grid-template-columns: 1fr;
    }
    
    .stat-card {
        padding: 1.5rem;
    }
    
    .stat-value {
        font-size: 2rem;
    }
    
    .dashboard-header h1 {
        font-size: 1.75rem;
    }
}

/* Animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.stat-card, .member-stats {
    animation: fadeIn 0.5s ease-out forwards;
}

.stat-card:nth-child(1) {
    animation-delay: 0.1s;
}

.stat-card:nth-child(2) {
    animation-delay: 0.2s;
}

.stat-card:nth-child(3) {
    animation-delay: 0.3s;
}

.member-stats {
    animation-delay: 0.4s;
}