/* --- NexTask - Timeline/Calendar View Styles --- */

#timeline-view-container {
    padding: 20px;
    height: calc(100vh - 140px);
    display: flex;
    flex-direction: column;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    padding: 16px 20px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
    flex: 1;
    grid-auto-rows: minmax(100px, 1fr);
}

.calendar-day {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 10px;
    aspect-ratio: 1 / 0.9;
    min-height: 110px;
}

.calendar-day.today {
    border-color: #f59e0b;
    border-width: 2px;
}

.calendar-task-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

/* Responsive */
/* Responsive */
@media (max-width: 768px) {
    .calendar-grid {
        gap: 4px;
    }

    .calendar-day {
        min-height: 80px;
        padding: 8px;
    }

    .calendar-day-number {
        font-size: 14px;
    }

    .calendar-task-dot {
        width: 18px;
        height: 18px;
    }

    .calendar-header {
        flex-direction: column;
        gap: 16px;
        align-items: flex-start;
    }
}

/* Expanded Timeline Styles */

/* Empty State */
.timeline-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    text-align: center;
}

/* Calendar Wrapper */
.calendar-wrapper {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* Calendar Navigation */
.calendar-nav {
    display: flex;
    align-items: center;
    gap: 20px;
}

.calendar-nav-btn {
    background: var(--bg-main);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    color: var(--text-main);
}

.calendar-nav-btn:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
    transform: scale(1.05);
}

.calendar-month-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0;
    text-transform: capitalize;
    min-width: 200px;
    text-align: center;
}

/* Legend */
.calendar-legend {
    display: flex;
    gap: 20px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-muted);
}

.legend-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

/* Weekdays */
.calendar-weekdays {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
    margin-bottom: 8px;
    flex-shrink: 0;
}

.calendar-weekday {
    text-align: center;
    padding: 8px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}

/* Day Cell Enhancements */
.calendar-day {
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
    cursor: default;
    position: relative;
    overflow: hidden;
}

.calendar-day.empty {
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed var(--border);
    opacity: 0.3;
}

.calendar-day.has-tasks {
    cursor: pointer;
}

.calendar-day.has-tasks:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.calendar-day.today {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(249, 115, 22, 0.05));
    border-color: #f59e0b;
    border-width: 2px;
}

.calendar-day.today .calendar-day-number {
    background: linear-gradient(135deg, #f59e0b, #f97316);
    color: white;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calendar-day-number {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-main);
    margin-bottom: 6px;
    flex-shrink: 0;
}

/* Task Visuals */
.calendar-day-tasks {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: auto;
}

.calendar-task-dot {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.calendar-task-dot:hover {
    transform: scale(1.2);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.calendar-task-more {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    padding: 4px 8px;
    background: var(--bg-main);
    border-radius: 6px;
    display: flex;
    align-items: center;
}

/* Day Tasks Modal (Pop-up) */
.day-tasks-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: fadeIn 0.2s ease-out;
}

.day-tasks-content {
    background: var(--bg-main);
    border-radius: var(--radius-xl);
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: slideUp 0.3s ease-out;
}

.day-tasks-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px;
    border-bottom: 1px solid var(--border);
}

.day-tasks-header h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0;
    text-transform: capitalize;
}

.close-day-modal {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.close-day-modal:hover {
    background: var(--danger);
    border-color: var(--danger);
    color: white;
}

.day-tasks-list {
    padding: 16px 24px 24px;
    overflow-y: auto;
    flex: 1;
}

.day-task-item {
    display: flex;
    gap: 12px;
    padding: 16px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.day-task-item:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}

.day-task-checkbox {
    width: 20px;
    height: 20px;
    border: 2px solid var(--border);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
}

.day-task-checkbox.checked {
    background: linear-gradient(135deg, #10b981, #059669);
    border-color: #10b981;
}

.day-task-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.day-task-title {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-main);
}

.day-task-project {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    align-self: flex-start;
}
