/* Dashboard Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body.dashboard-body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: #f8fafc;
    color: #1e293b;
    line-height: 1.6;
}

/* Dashboard Layout */
.dashboard-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar Styles */
.sidebar {
    width: 280px;
    background: linear-gradient(180deg, #334155 0%, #1e293b 100%);
    color: white;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    z-index: 1000;
    overflow-y: auto;
}

.sidebar-header {
    padding: 24px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    color: white;
    text-decoration: none;
}

.sidebar-logo .logo-icon {
    width: 32px;
    height: 32px;
    background: #3b82f6;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.sidebar-logo .logo-text {
    font-size: 18px;
    font-weight: 600;
}

.sidebar-nav {
    padding: 20px 0;
}

.sidebar-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.sidebar-nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

.sidebar-nav-item.active {
    background: rgba(59, 130, 246, 0.2);
    color: white;
    border-left-color: #3b82f6;
}

.sidebar-nav-item i {
    width: 20px;
    text-align: center;
    font-size: 16px;
}

/* Main Content */
.main-content {
    margin-left: 280px;
    flex: 1;
    min-height: 100vh;
}

/* Header */
.dashboard-header {
    background: white;
    padding: 20px 32px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-title h1 {
    font-size: 24px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 4px;
}

.header-subtitle {
    color: #64748b;
    font-size: 14px;
}

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

.user-info {
    text-align: right;
}

.user-name {
    font-size: 14px;
    font-weight: 500;
    color: #1e293b;
}

.user-role {
    font-size: 12px;
    color: #64748b;
}

/* Dashboard Content */
.dashboard-content {
    padding: 32px;
}

/* Welcome Alert */
.welcome-alert {
    background: linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%);
    border: 1px solid #86efac;
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 32px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.welcome-alert i {
    color: #16a34a;
    font-size: 18px;
}

.welcome-alert .alert-text {
    color: #15803d;
    font-weight: 500;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.stat-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #f1f5f9;
    transition: all 0.2s ease;
}

.stat-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.stat-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.stat-card-title {
    color: #64748b;
    font-size: 14px;
    font-weight: 500;
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.stat-icon.blue { background: #dbeafe; color: #2563eb; }
.stat-icon.yellow { background: #fef3c7; color: #d97706; }
.stat-icon.green { background: #dcfce7; color: #16a34a; }
.stat-icon.purple { background: #ede9fe; color: #7c3aed; }
.stat-icon.pink { background: #fce7f3; color: #db2777; }
.stat-icon.orange { background: #fed7aa; color: #ea580c; }

.stat-value {
    font-size: 32px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1;
}

/* Main Grid Layout */
.main-grid {
    display: grid;
    grid-template-columns: 1fr 400px;
    gap: 32px;
}

/* Calendar Card */
.calendar-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #f1f5f9;
}

.calendar-header {
    display: flex;
    justify-content: between;
    align-items: center;
    margin-bottom: 20px;
}

.calendar-title {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
}

.calendar-nav {
    display: flex;
    align-items: center;
    gap: 16px;
}

.calendar-nav button {
    background: none;
    border: none;
    color: #64748b;
    font-size: 18px;
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.calendar-nav button:hover {
    background: #f1f5f9;
    color: #1e293b;
}

.calendar-month {
    font-size: 18px;
    font-weight: 600;
    color: #1e293b;
}

/* Calendar Grid */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1px;
    background: #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
}

.calendar-day-header {
    background: #f8fafc;
    padding: 12px 8px;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
}

.calendar-day {
    background: white;
    padding: 12px 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.calendar-day:hover {
    background: #f8fafc;
}

.calendar-day.today {
    background: #3b82f6;
    color: white;
    font-weight: 600;
}

.calendar-day.has-appointment::after {
    content: '';
    position: absolute;
    bottom: 6px;
    left: 50%;
    transform: translateX(-50%);
    width: 6px;
    height: 6px;
    background: #f59e0b;
    border-radius: 50%;
}

/* Upcoming Appointments */
.appointments-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #f1f5f9;
}

.appointments-header {
    margin-bottom: 20px;
}

.appointments-title {
    font-size: 16px;
    font-weight: 600;
    color: #1e293b;
}

.appointment-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid #f1f5f9;
}

.appointment-item:last-child {
    border-bottom: none;
}

.appointment-time {
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    min-width: 80px;
}

.appointment-details {
    flex: 1;
}

.appointment-patient {
    font-size: 14px;
    font-weight: 500;
    color: #1e293b;
    margin-bottom: 4px;
}

.appointment-type {
    font-size: 12px;
    color: #64748b;
}

.appointment-status {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    text-transform: capitalize;
}

.appointment-status.completed {
    background: #dcfce7;
    color: #16a34a;
}

.appointment-status.consulted {
    background: #fed7aa;
    color: #ea580c;
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: 16px;
    margin-bottom: 32px;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: #3b82f6;
    color: white;
}

.btn-primary:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.btn-secondary {
    background: #64748b;
    color: white;
}

.btn-secondary:hover {
    background: #475569;
    transform: translateY(-1px);
}

/* Date Info */
.date-info {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.date-info i {
    color: #2563eb;
}

.date-info-text {
    color: #1e40af;
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .main-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    }
}

@media (max-width: 768px) {
    .dashboard-content {
        padding: 20px;
    }
    
    .dashboard-header {
        padding: 16px 20px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .action-buttons {
        flex-direction: column;
    }
}