/* BES Pro Dashboard Styles */
.bes-pro-dashboard {
    min-height: 100vh;
    background: #f8f9fa;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Dashboard Header */
.dashboard-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1.5rem 2rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}

.dashboard-title {
    margin: 0;
    font-size: 1.8rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.dashboard-title i {
    font-size: 1.5rem;
}

.dashboard-subtitle {
    margin: 0.25rem 0 0 0;
    opacity: 0.9;
    font-size: 0.95rem;
}

.user-info {
    text-align: right;
}

.welcome-text {
    font-weight: 500;
}

/* Dashboard Container */
.dashboard-container {
    display: flex;
    max-width: 1400px;
    margin: 0 auto;
    min-height: calc(100vh - 120px);
}

/* Sidebar */
.dashboard-sidebar {
    width: 280px;
    background: white;
    border-right: 1px solid #e9ecef;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    padding: 1.5rem;
    border-bottom: 1px solid #e9ecef;
}

.sidebar-header h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #495057;
}

.sidebar-nav {
    flex: 1;
    padding: 1rem 0;
}

.nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-item {
    margin: 0.25rem 0;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1.5rem;
    color: #495057;
    text-decoration: none;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.nav-link:hover {
    background: #f8f9fa;
    color: #495057;
}

.nav-item.active .nav-link {
    background: #e7f1ff;
    color: #007bff;
    border-left-color: #007bff;
}

.nav-link i {
    width: 20px;
    text-align: center;
    font-size: 1.1rem;
}

.nav-link span {
    font-weight: 500;
}

.sidebar-footer {
    padding: 1.5rem;
    border-top: 1px solid #e9ecef;
}

.system-status {
    font-size: 0.875rem;
}

.status-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.status-label {
    color: #6c757d;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
}

.status-indicator.online {
    color: #28a745;
}

.status-indicator i {
    font-size: 0.5rem;
}

/* Main Content */
.dashboard-content {
    flex: 1;
    background: #f8f9fa;
    display: flex;
    flex-direction: column;
}

.content-header {
    background: white;
    padding: 1.25rem 2rem;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.breadcrumb {
    font-weight: 500;
    color: #495057;
}

.content-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-refresh {
    background: none;
    border: 1px solid #e9ecef;
    padding: 0.5rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #6c757d;
}

.btn-refresh:hover {
    background: #f8f9fa;
    color: #495057;
}

/* Content Area */
.content-area {
    flex: 1;
    padding: 2rem;
    overflow-y: auto;
}

/* Overview Styles */
.dashboard-overview {
    max-width: 100%;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border: 1px solid #e9ecef;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}

.stat-icon.total-campaigns {
    background: linear-gradient(135deg, #667eea, #764ba2);
}

.stat-icon.emails-sent {
    background: linear-gradient(135deg, #f093fb, #f5576c);
}

.stat-icon.active-campaigns {
    background: linear-gradient(135deg, #4facfe, #00f2fe);
}

.stat-icon.success-rate {
    background: linear-gradient(135deg, #43e97b, #38f9d7);
}

.stat-content h3 {
    margin: 0;
    font-size: 2rem;
    font-weight: 700;
    color: #495057;
}

.stat-content p {
    margin: 0.25rem 0 0 0;
    color: #6c757d;
    font-weight: 500;
}

/* Quick Actions */
.quick-actions-section {
    margin-bottom: 2rem;
}

.quick-actions-section h3 {
    margin-bottom: 1rem;
    color: #495057;
    font-weight: 600;
}

.quick-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.quick-action-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    text-decoration: none;
    color: inherit;
    border: 1px solid #e9ecef;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all 0.2s ease;
    cursor: pointer;
}

.quick-action-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    border-color: #007bff;
    color: inherit;
}

.action-icon {
    width: 50px;
    height: 50px;
    border-radius: 10px;
    background: #e7f1ff;
    color: #007bff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.action-content h4 {
    margin: 0;
    font-weight: 600;
    color: #495057;
}

.action-content p {
    margin: 0.25rem 0 0 0;
    color: #6c757d;
    font-size: 0.9rem;
}

/* Recent Activity */
.recent-activity-section h3 {
    margin-bottom: 1rem;
    color: #495057;
    font-weight: 600;
}

.activity-list {
    background: white;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    overflow: hidden;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid #e9ecef;
    transition: background 0.2s ease;
}

.activity-item:hover {
    background: #f8f9fa;
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: #e7f1ff;
    color: #007bff;
    display: flex;
    align-items: center;
    justify-content: center;
}

.activity-content h4 {
    margin: 0;
    font-weight: 600;
    color: #495057;
}

.activity-meta {
    margin: 0.25rem 0 0 0;
    display: flex;
    gap: 1rem;
    font-size: 0.875rem;
}

.status {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-weight: 500;
    font-size: 0.75rem;
}

.status.queued {
    background: #fff3cd;
    color: #856404;
}

.status.sent {
    background: #d1ecf1;
    color: #0c5460;
}

.status.completed {
    background: #d4edda;
    color: #155724;
}

.date {
    color: #6c757d;
}

.no-activity, .coming-soon {
    text-align: center;
    padding: 3rem 2rem;
    background: white;
    border-radius: 12px;
    border: 1px solid #e9ecef;
}

.no-activity i, .coming-soon i {
    font-size: 3rem;
    color: #6c757d;
    margin-bottom: 1rem;
}

.no-activity h3, .coming-soon h3 {
    margin: 0 0 0.5rem 0;
    color: #495057;
}

.no-activity p, .coming-soon p {
    margin: 0;
    color: #6c757d;
}

/* Loading and Error States */
.loading-spinner, .error-message {
    text-align: center;
    padding: 3rem 2rem;
}

.loading-spinner i {
    font-size: 2rem;
    color: #007bff;
    margin-bottom: 1rem;
}

.error-message i {
    font-size: 2rem;
    color: #dc3545;
    margin-bottom: 1rem;
}

/* Auth States */
.bes-pro-auth-required, .bes-pro-no-permission {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 400px;
}

.auth-message, .permission-message {
    text-align: center;
    padding: 2rem;
}

.auth-message i, .permission-message i {
    font-size: 4rem;
    color: #6c757d;
    margin-bottom: 1rem;
}

.auth-message h3, .permission-message h3 {
    margin: 0 0 1rem 0;
    color: #495057;
}

.auth-message p, .permission-message p {
    margin: 0 0 1.5rem 0;
    color: #6c757d;
}

.btn-login {
    display: inline-block;
    background: #007bff;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    transition: background 0.2s ease;
}

.btn-login:hover {
    background: #0056b3;
    color: white;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .dashboard-container {
        flex-direction: column;
    }
    
    .dashboard-sidebar {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #e9ecef;
    }
    
    .sidebar-nav {
        padding: 0;
    }
    
    .nav-menu {
        display: flex;
        overflow-x: auto;
    }
    
    .nav-item {
        flex-shrink: 0;
    }
    
    .nav-link {
        border-left: none;
        border-bottom: 3px solid transparent;
    }
    
    .nav-item.active .nav-link {
        border-left: none;
        border-bottom-color: #007bff;
    }
}

@media (max-width: 768px) {
    .dashboard-header {
        padding: 1rem;
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .content-header {
        padding: 1rem;
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .content-area {
        padding: 1rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .quick-actions-grid {
        grid-template-columns: 1fr;
    }
}