Spaces:
Running

File size: 9,985 Bytes
2abd282
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
830a4f4
 
2abd282
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
<!DOCTYPE html>
<html lang="en" class="scroll-smooth">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>FlowState - Dashboard</title>
    <link rel="stylesheet" href="style.css">
    <script src="https://cdn.tailwindcss.com"></script>
    <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
    <script>
        tailwind.config = {
            darkMode: 'class',
            theme: {
                extend: {
                    colors: {
                        primary: {
                            50: '#ecfdf5',
                            100: '#d1fae5',
                            500: '#10b981',
                            600: '#059669',
                            700: '#047857',
                            900: '#064e3b',
                        },
                        secondary: {
                            50: '#f5f3ff',
                            100: '#ede9fe',
                            500: '#8b5cf6',
                            600: '#7c3aed',
                            700: '#6d28d9',
                        }
                    },
                    animation: {
                        'float': 'float 3s ease-in-out infinite',
                        'pulse-slow': 'pulse 4s cubic-bezier(0.4, 0, 0.6, 1) infinite',
                    },
                    keyframes: {
                        float: {
                            '0%, 100%': { transform: 'translateY(0)' },
                            '50%': { transform: 'translateY(-10px)' },
                        }
                    }
                }
            }
        }
    </script>
</head>
<body class="bg-gray-50 dark:bg-gray-900 text-gray-800 dark:text-gray-100 transition-colors duration-300">
    <flow-navbar></flow-navbar>
    <main class="pt-28 pb-12 px-4 sm:px-6 lg:px-8 max-w-7xl mx-auto">
<!-- Hero Section -->
        <div class="mb-12 relative overflow-hidden rounded-3xl bg-gradient-to-br from-primary-500 to-secondary-600 p-8 sm:p-12 text-white shadow-2xl">
            <div class="absolute top-0 right-0 -mt-16 -mr-16 w-64 h-64 bg-white opacity-10 rounded-full blur-3xl"></div>
            <div class="absolute bottom-0 left-0 -mb-16 -ml-16 w-48 h-48 bg-white opacity-10 rounded-full blur-2xl"></div>
            
            <div class="relative z-10">
                <h1 class="text-4xl sm:text-5xl font-bold mb-4 animate-float">Welcome back, Creator 🌟</h1>
                <p class="text-lg opacity-90 mb-6 max-w-2xl">Stay in the flow. You have <span id="pending-count" class="font-bold underline">0</span> tasks waiting for your attention today.</p>
                <a href="tasks.html" class="inline-flex items-center px-6 py-3 bg-white text-primary-600 rounded-full font-semibold hover:bg-gray-100 transition-all transform hover:scale-105 shadow-lg">
                    <i data-feather="plus-circle" class="w-5 h-5 mr-2"></i>
                    Quick Add Task
                </a>
            </div>
        </div>

        <!-- Stats Grid -->
        <div class="grid grid-cols-1 md:grid-cols-3 gap-6 mb-12">
            <div class="glass-card p-6 rounded-2xl border border-gray-200 dark:border-gray-700 bg-white dark:bg-gray-800 shadow-lg hover:shadow-xl transition-shadow">
                <div class="flex items-center justify-between mb-4">
                    <div class="p-3 bg-primary-100 dark:bg-primary-900 rounded-xl">
                        <i data-feather="check-circle" class="w-6 h-6 text-primary-600"></i>
                    </div>
                    <span class="text-sm text-gray-500 dark:text-gray-400">Today</span>
                </div>
                <h3 class="text-3xl font-bold mb-1" id="completed-stat">0</h3>
                <p class="text-sm text-gray-600 dark:text-gray-400">Tasks completed</p>
                <div class="mt-4 h-2 bg-gray-200 dark:bg-gray-700 rounded-full overflow-hidden">
                    <div id="completion-bar" class="h-full bg-primary-500 rounded-full transition-all duration-500" style="width: 0%"></div>
                </div>
            </div>

            <div class="glass-card p-6 rounded-2xl border border-gray-200 dark:border-gray-700 bg-white dark:bg-gray-800 shadow-lg hover:shadow-xl transition-shadow">
                <div class="flex items-center justify-between mb-4">
                    <div class="p-3 bg-secondary-100 dark:bg-secondary-900 rounded-xl">
                        <i data-feather="zap" class="w-6 h-6 text-secondary-600"></i>
                    </div>
                    <span class="text-sm text-gray-500 dark:text-gray-400">Focus Time</span>
                </div>
                <h3 class="text-3xl font-bold mb-1" id="focus-stat">0h</h3>
                <p class="text-sm text-gray-600 dark:text-gray-400">Deep work sessions</p>
                <div class="mt-4 flex items-center text-sm text-secondary-600">
                    <i data-feather="trending-up" class="w-4 h-4 mr-1"></i>
                    <span>+12% from last week</span>
                </div>
            </div>

            <div class="glass-card p-6 rounded-2xl border border-gray-200 dark:border-gray-700 bg-white dark:bg-gray-800 shadow-lg hover:shadow-xl transition-shadow">
                <div class="flex items-center justify-between mb-4">
                    <div class="p-3 bg-orange-100 dark:bg-orange-900 rounded-xl">
                        <i data-feather="award" class="w-6 h-6 text-orange-600"></i>
                    </div>
                    <span class="text-sm text-gray-500 dark:text-gray-400">Streak</span>
                </div>
                <h3 class="text-3xl font-bold mb-1" id="streak-stat">5</h3>
                <p class="text-sm text-gray-600 dark:text-gray-400">Days in a row</p>
                <div class="mt-4 flex gap-1">
                    <div class="h-2 w-full bg-primary-500 rounded-full"></div>
                    <div class="h-2 w-full bg-primary-500 rounded-full"></div>
                    <div class="h-2 w-full bg-primary-500 rounded-full"></div>
                    <div class="h-2 w-full bg-primary-500 rounded-full"></div>
                    <div class="h-2 w-full bg-primary-500 rounded-full"></div>
                    <div class="h-2 w-full bg-gray-300 dark:bg-gray-600 rounded-full"></div>
                    <div class="h-2 w-full bg-gray-300 dark:bg-gray-600 rounded-full"></div>
                </div>
            </div>
        </div>

        <!-- Recent Tasks Preview -->
        <div class="grid grid-cols-1 lg:grid-cols-2 gap-8">
            <div class="bg-white dark:bg-gray-800 rounded-2xl p-6 shadow-lg border border-gray-200 dark:border-gray-700">
                <div class="flex items-center justify-between mb-6">
                    <h2 class="text-xl font-bold flex items-center">
                        <i data-feather="clock" class="w-5 h-5 mr-2 text-primary-500"></i>
                        Recent Tasks
                    </h2>
                    <a href="tasks.html" class="text-sm text-primary-600 hover:text-primary-700 font-medium">View all</a>
                </div>
                <div id="recent-tasks-list" class="space-y-3">
                    <!-- Tasks injected here -->
                    <div class="text-center py-8 text-gray-500">
                        <i data-feather="inbox" class="w-12 h-12 mx-auto mb-3 opacity-50"></i>
                        <p>No tasks yet. Start by adding one!</p>
                    </div>
                </div>
            </div>

            <div class="bg-white dark:bg-gray-800 rounded-2xl p-6 shadow-lg border border-gray-200 dark:border-gray-700">
                <div class="flex items-center justify-between mb-6">
                    <h2 class="text-xl font-bold flex items-center">
                        <i data-feather="target" class="w-5 h-5 mr-2 text-secondary-500"></i>
                        Categories
                    </h2>
                </div>
                <div class="space-y-4" id="categories-list">
                    <div class="flex items-center justify-between p-3 bg-gray-50 dark:bg-gray-700 rounded-xl">
                        <div class="flex items-center">
                            <div class="w-3 h-3 rounded-full bg-primary-500 mr-3"></div>
                            <span>Work</span>
                        </div>
                        <span class="text-sm text-gray-500" id="count-work">0 tasks</span>
                    </div>
                    <div class="flex items-center justify-between p-3 bg-gray-50 dark:bg-gray-700 rounded-xl">
                        <div class="flex items-center">
                            <div class="w-3 h-3 rounded-full bg-secondary-500 mr-3"></div>
                            <span>Personal</span>
                        </div>
                        <span class="text-sm text-gray-500" id="count-personal">0 tasks</span>
                    </div>
                    <div class="flex items-center justify-between p-3 bg-gray-50 dark:bg-gray-700 rounded-xl">
                        <div class="flex items-center">
                            <div class="w-3 h-3 rounded-full bg-orange-500 mr-3"></div>
                            <span>Learning</span>
                        </div>
                        <span class="text-sm text-gray-500" id="count-learning">0 tasks</span>
                    </div>
                </div>
            </div>
        </div>
    </main>

    <flow-footer></flow-footer>

    <script src="components/navbar.js"></script>
    <script src="components/footer.js"></script>
    <script src="script.js"></script>
    <script>
        feather.replace();
        // Dashboard specific initialization
        document.addEventListener('DOMContentLoaded', () => {
            updateDashboardStats();
        });
    </script>
<script src="https://huggingface.co/deepsite/deepsite-badge.js"></script>
</body>
</html>