* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: #f8f9fa;
    overflow-x: hidden;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 70px;
    background: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px;
    z-index: 1000;
}

.navbar-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.menu-toggle {
    font-size: 24px;
    cursor: pointer;
    color: #1f2937;
    transition: color 0.3s;
}

.menu-toggle:hover {
    color: #667eea;
}

.search-bar {
    display: flex;
    align-items: center;
    background: #f3f4f6;
    border-radius: 12px;
    padding: 10px 20px;
    gap: 10px;
    width: 350px;
}

.search-bar input {
    border: none;
    background: none;
    outline: none;
    width: 100%;
    font-size: 14px;
    color: #1f2937;
}

.navbar-right {
    display: flex;
    align-items: center;
    gap: 25px;
}

.nav-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    color: #6b7280;
    position: relative;
}

.nav-icon:hover {
    background: #f3f4f6;
    color: #667eea;
}

.notification-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 8px;
    height: 8px;
    background: #ef4444;
    border-radius: 50%;
    border: 2px solid white;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 12px;
    transition: background 0.3s;
}

.user-profile:hover {
    background: #f3f4f6;
}

.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 14px;
}

.user-name {
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
}

/* Sidebar */
.sidebar {
    position: fixed;
    left: 0;
    top: 70px;
    bottom: 0;
    width: 260px;
    background: white;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.05);
    padding: 30px 0;
    overflow-y: auto;
    transition: transform 0.3s ease;
    z-index: 999;
}

.sidebar.collapsed {
    transform: translateX(-260px);
}

.sidebar-section {
    margin-bottom: 30px;
}

.sidebar-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #9ca3af;
    padding: 0 25px;
    margin-bottom: 10px;
    font-weight: 600;
}

.sidebar-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 25px;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
}

.sidebar-item:hover {
    background: #f3f4f6;
    color: #667eea;
}

.sidebar-item.active {
    background: linear-gradient(90deg, rgba(102, 126, 234, 0.1) 0%, transparent 100%);
    color: #667eea;
    font-weight: 600;
}

.sidebar-item.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, #667eea 0%, #764ba2 100%);
}

.sidebar-icon {
    font-size: 20px;
    width: 24px;
    text-align: center;
}

/* Main Content */
.main-content {
    margin-left: 260px;
    margin-top: 70px;
    padding: 30px;
    transition: margin-left 0.3s ease;
    min-height: calc(100vh - 70px);
}

.main-content.expanded {
    margin-left: 0;
}

.page-header {
    margin-bottom: 30px;
}

.page-title {
    font-size: 28px;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 8px;
}

.page-subtitle {
    font-size: 14px;
    color: #6b7280;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    cursor: pointer;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.stat-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.icon-blue {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.icon-green {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.icon-orange {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.icon-purple {
    background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
}

.stat-trend {
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: 600;
}

.trend-up {
    background: #d1fae5;
    color: #059669;
}

.trend-down {
    background: #fee2e2;
    color: #dc2626;
}

.stat-title {
    font-size: 13px;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.stat-value {
    font-size: 32px;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 5px;
}

.stat-description {
    font-size: 13px;
    color: #9ca3af;
}

.content-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

.chart-card {
    background: white;
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
}

.time-filters {
    display: flex;
    gap: 8px;
}

.time-btn {
    padding: 6px 14px;
    border: none;
    border-radius: 8px;
    background: #f3f4f6;
    color: #6b7280;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 500;
}

.time-btn:hover,
.time-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}


/* Table */
.table-container {
    background: white;
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    margin-bottom: 30px;
    overflow-x: auto;
}

.table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.table-title {
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
}

.table-actions {
    display: flex;
    gap: 10px;
}

.btn {
    padding: 8px 16px;
    border-radius: 8px;
    border: none;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 500;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: #f3f4f6;
    color: #6b7280;
}

.btn-secondary:hover {
    background: #e5e7eb;
}

.table {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background: #f9fafb;
}

th {
    padding: 12px 16px;
    text-align: left;
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 2px solid #e5e7eb;
}

td {
    padding: 16px;
    font-size: 14px;
    color: #1f2937;
    border-bottom: 1px solid #f3f4f6;
}

tbody tr {
    transition: background 0.2s;
}

tbody tr:hover {
    background: #f9fafb;
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.status-active {
    background: #d1fae5;
    color: #059669;
}

.status-pending {
    background: #fef3c7;
    color: #d97706;
}

.status-inactive {
    background: #fee2e2;
    color: #dc2626;
}

.user-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 12px;
    flex-shrink: 0;
}

.user-info {
    display: flex;
    flex-direction: column;
}

.user-name-cell {
    font-weight: 600;
    color: #1f2937;
}

.user-email {
    font-size: 12px;
    color: #9ca3af;
}

.action-buttons {
    display: flex;
    gap: 8px;
}

.action-btn {
    padding: 6px 12px;
    border-radius: 6px;
    border: none;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
    background: #f3f4f6;
    color: #6b7280;
}

.action-btn:hover {
    background: #e5e7eb;
    color: #1f2937;
}

.activity-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 15px;
    border-radius: 12px;
    transition: background 0.3s;
    cursor: pointer;
}

.activity-item:hover {
    background: #f9fafb;
}

.activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 18px;
}

.activity-content {
    flex: 1;
}

.activity-text {
    font-size: 14px;
    color: #1f2937;
    margin-bottom: 4px;
    font-weight: 500;
}

.activity-time {
    font-size: 12px;
    color: #9ca3af;
}

@media (max-width: 968px) {
    .content-grid {
        grid-template-columns: 1fr;
    }

    .search-bar {
        width: 250px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-260px);
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }

    .search-bar {
        display: none;
    }
}