/* Modern Dashboard Styles */

:root {
    --dashboard-card-bg: #ffffff;
    --dashboard-card-border: rgba(0, 0, 0, 0.05);
    --dashboard-text-color: #2c3e50;
    --dashboard-muted-text: #95a5a6;
    --card-hover-transform: translateY(-5px);
    --card-hover-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    --stat-card-gradient-1: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --stat-card-gradient-2: linear-gradient(135deg, #2af598 0%, #009efd 100%);
    --stat-card-gradient-3: linear-gradient(135deg, #ff9a9e 0%, #fecfef 99%, #fecfef 100%);
    --stat-card-gradient-4: linear-gradient(120deg, #f093fb 0%, #f5576c 100%);
}

[data-theme="dark"] {
    --dashboard-card-bg: #1e1e2f;
    --dashboard-card-border: rgba(255, 255, 255, 0.05);
    --dashboard-text-color: #ecf0f1;
    --dashboard-muted-text: #bdc3c7;
    --card-hover-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.dashboard-header {
    background: var(--bg-secondary);
    padding: 2rem;
    border-radius: 1rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--border-color);
}

.dashboard-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
}

.dashboard-date {
    color: var(--text-muted);
    font-weight: 500;
}

/* Stat Cards */
.stat-card {
    border: none;
    border-radius: 1rem;
    overflow: hidden;
    position: relative;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    background: var(--dashboard-card-bg);
}

.stat-card:hover {
    transform: var(--card-hover-transform);
    box-shadow: var(--card-hover-shadow);
}

.stat-card .card-body {
    padding: 1.5rem;
    position: relative;
    z-index: 2;
}

.stat-card-icon {
    position: absolute;
    right: -10px;
    bottom: -10px;
    font-size: 5rem;
    opacity: 0.1;
    transform: rotate(-15deg);
    z-index: 1;
    color: var(--text-primary);
}

.stat-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
}

.stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.2;
}

/* Specific Stat Card Colors (Left Borders / Accents) */
.stat-card.primary {
    border-left: 5px solid #4e73df;
}

.stat-card.success {
    border-left: 5px solid #1cc88a;
}

.stat-card.info {
    border-left: 5px solid #36b9cc;
}

.stat-card.warning {
    border-left: 5px solid #f6c23e;
}


/* Module Cards */
.module-card {
    border: none;
    border-radius: 1rem;
    transition: all 0.3s ease;
    background: var(--dashboard-card-bg);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
    height: 100%;
    border: 1px solid var(--border-color);
}

.module-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.module-card .card-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.module-icon-wrapper {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
}

.module-card:hover .module-icon-wrapper {
    background: var(--primary-color);
    color: white;
}

.module-title {
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.module-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Recent Activity */
.activity-card {
    border: none;
    border-radius: 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    background: var(--dashboard-card-bg);
    overflow: hidden;
}

.activity-header {
    background: transparent;
    border-bottom: 1px solid var(--border-color);
    padding: 1.5rem;
}

.activity-header h6 {
    font-weight: 700;
    color: var(--primary-color);
    margin: 0;
}

.activity-item {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    transition: background-color 0.2s;
    display: flex;
    align-items: flex-start;
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-item:hover {
    background-color: var(--bg-tertiary);
}

.activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
    flex-shrink: 0;
}

.activity-content {
    flex-grow: 1;
}

.activity-time {
    font-size: 0.75rem;
    color: var(--text-muted);
    white-space: nowrap;
    margin-left: 1rem;
}

/* Quick Actions */
.action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    border-radius: 0.75rem;
    font-weight: 600;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    height: 100%;
}

.action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.action-btn i {
    font-size: 1.2rem;
    margin-right: 0.5rem;
}

/* Section Title */
.section-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
}

.section-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-color);
    margin-left: 1rem;
}

/* Generic UI Utilities */

/* Page Header */
.page-header {
    background: var(--bg-secondary);
    padding: 1.5rem 2rem;
    border-radius: 1rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.02);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid var(--border-color);
}

.page-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    display: flex;
    align-items: center;
}

/* Content Cards (Tables/Forms) */
.content-card {
    border: none;
    border-radius: 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    background: var(--dashboard-card-bg);
    overflow: hidden;
    margin-bottom: 2rem;
}

.content-card .card-header {
    background: transparent;
    border-bottom: 1px solid var(--border-color);
    padding: 1.25rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.content-card .card-header h6 {
    font-weight: 700;
    color: var(--primary-color);
    margin: 0;
    font-size: 1rem;
}

/* Filter Bar */
.filter-bar {
    background: var(--bg-tertiary);
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

/* Modern Table */
.modern-table {
    margin-bottom: 0;
}

.modern-table thead th {
    background-color: var(--bg-secondary);
    border-bottom: 2px solid var(--border-color);
    color: var(--text-secondary);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    padding: 1rem 1.5rem;
    white-space: nowrap;
}

.modern-table tbody td {
    padding: 1rem 1.5rem;
    vertical-align: middle;
    color: var(--text-primary);
    border-bottom: 1px solid var(--border-color);
    font-size: 0.9rem;
}

.modern-table tbody tr:hover {
    background-color: var(--bg-tertiary);
}

/* Status Badges */
.badge-modern {
    padding: 0.5em 0.8em;
    font-weight: 600;
    border-radius: 2rem;
    font-size: 0.75rem;
    letter-spacing: 0.5px;
}

/* Action Buttons in Grid */
.btn-icon {
    width: 32px;
    height: 32px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
    transition: all 0.2s;
}

.btn-icon:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}