:root {
    --primary-color: #2564cf;
    --sidebar-width: 280px;
    --sidebar-collapsed-width: 60px;
    --header-height: 60px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f5f5;
    overflow-x: hidden;
}

/* Sidebar Styles */
.sidebar-wrapper {
    position: relative;
}

.sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
    overflow-y: auto;
    overflow-x: hidden;
}

.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-thumb {
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

.sidebar-header {
    height: var(--header-height);
    display: flex;
    align-items: center;
}

.user-info .user-avatar {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sidebar .nav-link {
    color: #5a5a5a;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 4px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
}

.sidebar .nav-link:hover {
    background-color: #e9ecef;
    color: #000;
}

.sidebar .nav-link.active {
    background-color: var(--primary-color);
    color: white;
}

.sidebar .nav-link i {
    font-size: 1.2rem;
    min-width: 24px;
}

/* Main Content */
.main-content {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    transition: margin-left 0.3s ease;
}

.content-wrapper {
    background-color: #fff;
    min-height: 100vh;
}

.content-header {
    height: var(--header-height);
    z-index: 999;
}

.task-container {
    max-width: 900px;
   
}

/* Task Items */
.task-item {
    transition: all 0.2s;
    border-radius: 8px;
}

.task-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
}

.task-checkbox {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    cursor: pointer;
}

.task-title {
    font-size: 1rem;
    color: #323130;
}

.task-meta .badge {
    font-weight: 500;
    padding: 6px 10px;
}

/* Add Task Input */
.add-task .input-group {
    border: 2px solid #e1e1e1;
    border-radius: 8px;
    overflow: hidden;
    transition: border-color 0.2s;
}

.add-task .input-group:focus-within {
    border-color: var(--primary-color);
}

.add-task input {
    border: none;
    box-shadow: none;
}

.add-task input:focus {
    box-shadow: none;
}

/* Task Detail Panel */
.task-detail-panel {
    width: 360px;
    height: 100vh;
    position: fixed;
    right: -360px;
    top: 0;
    transition: right 0.3s ease;
    overflow-y: auto;
    z-index: 1001;
}

.task-detail-panel.show {
    right: 0;
}

.task-detail-panel::-webkit-scrollbar {
    width: 6px;
}

.task-detail-panel::-webkit-scrollbar-thumb {
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

/* Mobile Toggle Button */
.mobile-toggle {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 1001;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Completed Tasks */
.completed-section .task-item {
    opacity: 0.6;
}

.completed-section .task-title {
    text-decoration: line-through;
    color: #a19f9d;
}

/* Empty State */
.empty-state i {
    font-size: 5rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .sidebar {
        left: -280px;
    }
    
    .sidebar.show {
        left: 0;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .mobile-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .task-detail-panel {
        width: 100%;
        right: -100%;
    }
    
    .sidebar-toggle {
        display: block;
    }
    
    .task-container {
        padding: 1rem !important;
    }
    
    .task-item .card-body {
        padding: 1rem !important;
    }
    
    .task-actions {
        flex-wrap: wrap;
    }
}

@media (min-width: 769px) and (max-width: 992px) {
    .sidebar {
        width: var(--sidebar-collapsed-width);
    }
    
    .sidebar-text {
        display: none;
    }
    
    .sidebar .nav-link {
        justify-content: center;
    }
    
    .main-content {
        margin-left: var(--sidebar-collapsed-width);
    }
}

/* Animation for checkboxes */
.task-checkbox:checked ~ .task-title {
    text-decoration: line-through;
    color: #a19f9d;
}

/* Badge Colors */
.bg-danger-subtle {
    background-color: #f8d7da !important;
}

.bg-warning-subtle {
    background-color: #fff3cd !important;
}

.bg-success-subtle {
    background-color: #d1e7dd !important;
}

.bg-primary-subtle {
    background-color: #cfe2ff !important;
}

/* Button Hover Effects */
.btn-light:hover {
    background-color: #e9ecef;
}

/* Timeline */
.timeline-item {
    padding-left: 20px;
    position: relative;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: 6px;
    top: 8px;
    width: 2px;
    height: calc(100% + 8px);
    background-color: #e1e1e1;
}

.timeline-item:last-child::before {
    display: none;
}

.timeline-item i {
    position: relative;
    z-index: 1;
    background-color: white;
}

/* Modal Styles */
.modal-content {
    border: none;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

/* Form Controls */
.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(37, 100, 207, 0.25);
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}
