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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
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>NovelCraft - Writing & Organization</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <script src="https://unpkg.com/lucide@latest"></script>
    <style>
        /* Custom scrollbar */
        ::-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;
        }
        
        /* Custom animations */
        @keyframes fadeIn {
            from { opacity: 0; }
            to { opacity: 1; }
        }
        .fade-in {
            animation: fadeIn 0.2s ease-in-out;
        }
        
        /* Custom dropdown */
        .dropdown-content {
            display: none;
            position: absolute;
            z-index: 50;
            min-width: 220px;
            background-color: white;
            border: 1px solid #e5e7eb;
            border-radius: 0.375rem;
            box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
        }
        .dropdown:hover .dropdown-content {
            display: block;
        }
        
        /* Message bubbles */
        .user-message {
            background-color: #6366f1;
            color: white;
            border-radius: 1rem 1rem 0 1rem;
        }
        .ai-message {
            background-color: #f3f4f6;
            color: #1f2937;
            border-radius: 1rem 1rem 1rem 0;
        }
    </style>
</head>
<body class="bg-gray-50 text-gray-800 font-sans antialiased flex h-screen overflow-hidden">
    <!-- Left Sidebar -->
    <div class="w-64 bg-white border-r border-gray-200 flex flex-col h-full">
        <div class="p-4 border-b border-gray-200">
            <h1 class="text-xl font-semibold text-gray-800 flex items-center">
                <i data-lucide="book-open" class="w-5 h-5 mr-2 text-indigo-500"></i>
                NovelCraft
            </h1>
        </div>
        
        <div class="p-3 border-b border-gray-200">
            <div class="relative">
                <input type="text" placeholder="Search all entries..." class="w-full pl-9 pr-3 py-2 border border-gray-300 rounded-md text-sm focus:outline-none focus:ring-1 focus:ring-indigo-500 focus:border-indigo-500">
                <i data-lucide="search" class="absolute left-3 top-2.5 text-gray-400 w-4 h-4"></i>
            </div>
        </div>
        
        <div class="flex-1 overflow-y-auto">
            <div class="px-3 pt-3">
                <button class="w-full flex items-center justify-between px-3 py-2 bg-indigo-50 text-indigo-600 rounded-md text-sm font-medium">
                    <span class="flex items-center">
                        <i data-lucide="plus" class="w-4 h-4 mr-2"></i>
                        New Entry
                    </span>
                </button>
            </div>
            
            <div class="mt-4">
                <div class="px-3">
                    <button class="w-full flex items-center justify-between px-3 py-2 bg-indigo-600 text-white rounded-md text-sm font-medium">
                        <span class="flex items-center">
                            <i data-lucide="library" class="w-4 h-4 mr-2"></i>
                            Codex
                        </span>
                        <i data-lucide="chevron-down" class="w-4 h-4"></i>
                    </button>
                </div>
                
                <div class="mt-1 pl-8">
                    <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md flex items-center">
                        <i data-lucide="users" class="w-4 h-4 mr-2 text-gray-500"></i>
                        Characters
                    </a>
                    <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md flex items-center">
                        <i data-lucide="map-pin" class="w-4 h-4 mr-2 text-gray-500"></i>
                        Locations
                    </a>
                    <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md flex items-center">
                        <i data-lucide="package" class="w-4 h-4 mr-2 text-gray-500"></i>
                        Items
                    </a>
                    <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md flex items-center">
                        <i data-lucide="scroll" class="w-4 h-4 mr-2 text-gray-500"></i>
                        Lore
                    </a>
                    <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md flex items-center">
                        <i data-lucide="file-text" class="w-4 h-4 mr-2 text-gray-500"></i>
                        Snippets
                    </a>
                </div>
            </div>
            
            <div class="mt-2">
                <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md mx-2 flex items-center">
                    <i data-lucide="calendar" class="w-4 h-4 mr-2 text-gray-500"></i>
                    Timeline
                </a>
                <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md mx-2 flex items-center">
                    <i data-lucide="bar-chart-2" class="w-4 h-4 mr-2 text-gray-500"></i>
                    Stats
                </a>
            </div>
        </div>
        
        <div class="p-3 border-t border-gray-200">
            <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md flex items-center">
                <i data-lucide="settings" class="w-4 h-4 mr-2 text-gray-500"></i>
                Settings
            </a>
            <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md flex items-center">
                <i data-lucide="help-circle" class="w-4 h-4 mr-2 text-gray-500"></i>
                Help & Feedback
            </a>
        </div>
    </div>
    
    <!-- Main Content -->
    <div class="flex-1 flex flex-col h-full overflow-hidden">
        <!-- Top Navigation -->
        <div class="bg-white border-b border-gray-200">
            <div class="flex items-center px-4 h-14">
                <div class="flex space-x-1">
                    <a href="#" class="px-3 py-2 text-sm font-medium text-gray-500 hover:text-gray-700 rounded-md">Plan</a>
                    <a href="#" class="px-3 py-2 text-sm font-medium text-gray-500 hover:text-gray-700 rounded-md">Write</a>
                    <a href="#" class="px-3 py-2 text-sm font-medium text-indigo-600 bg-indigo-50 rounded-md">Chat</a>
                    <a href="#" class="px-3 py-2 text-sm font-medium text-gray-500 hover:text-gray-700 rounded-md">Review</a>
                </div>
                
                <div class="ml-auto flex items-center space-x-3">
                    <button class="p-1 rounded-md hover:bg-gray-100">
                        <i data-lucide="bell" class="w-5 h-5 text-gray-500"></i>
                    </button>
                    <div class="relative">
                        <button class="flex items-center space-x-2 focus:outline-none">
                            <div class="w-8 h-8 rounded-full bg-indigo-100 flex items-center justify-center text-indigo-600 font-medium">JD</div>
                            <span class="text-sm font-medium text-gray-700">John Doe</span>
                            <i data-lucide="chevron-down" class="w-4 h-4 text-gray-500"></i>
                        </button>
                    </div>
                </div>
            </div>
        </div>
        
        <!-- Content Area -->
        <div class="flex-1 flex overflow-hidden">
            <!-- Left Threads Panel -->
            <div class="w-64 bg-white border-r border-gray-200 flex flex-col h-full overflow-hidden">
                <div class="p-3 border-b border-gray-200">
                    <button class="w-full flex items-center justify-center px-3 py-2 bg-indigo-600 text-white rounded-md text-sm font-medium">
                        <i data-lucide="plus" class="w-4 h-4 mr-2"></i>
                        New Thread
                    </button>
                </div>
                
                <div class="flex-1 overflow-y-auto">
                    <div class="px-3 pt-3">
                        <div class="flex items-center justify-between">
                            <h3 class="text-xs font-semibold text-gray-500 uppercase tracking-wider">Pinned</h3>
                            <span class="text-xs text-gray-400">1 thread</span>
                        </div>
                        
                        <div class="mt-2">
                            <a href="#" class="block px-3 py-2 text-sm text-gray-700 bg-gray-100 rounded-md flex items-center justify-between">
                                <span>Main Story Brainstorm</span>
                                <i data-lucide="star" class="w-4 h-4 text-yellow-500"></i>
                            </a>
                        </div>
                    </div>
                    
                    <div class="px-3 pt-4">
                        <div class="flex items-center justify-between">
                            <h3 class="text-xs font-semibold text-gray-500 uppercase tracking-wider">Recent</h3>
                            <span class="text-xs text-gray-400">3 threads</span>
                        </div>
                        
                        <div class="mt-2 space-y-1">
                            <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md">
                                <div>Fantasy Novels</div>
                                <div class="text-xs text-gray-400 mt-1">yesterday at 3:45 PM</div>
                            </a>
                            <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md">
                                <div>Character Development</div>
                                <div class="text-xs text-gray-400 mt-1">2 days ago</div>
                            </a>
                            <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded-md">
                                <div>World Building</div>
                                <div class="text-xs text-gray-400 mt-1">Mar 12</div>
                            </a>
                        </div>
                    </div>
                </div>
            </div>
            
            <!-- Main Chat Area -->
            <div class="flex-1 flex flex-col h-full overflow-hidden bg-gray-50">
                <!-- Chat Header -->
                <div class="bg-white border-b border-gray-200 p-3">
                    <div class="flex items-center justify-between">
                        <div class="flex items-center space-x-4">
                            <div class="relative">
                                <select class="appearance-none bg-white border border-gray-300 rounded-md pl-3 pr-8 py-2 text-sm focus:outline-none focus:ring-1 focus:ring-indigo-500 focus:border-indigo-500">
                                    <option>General Purpose GPT-4 Turbo</option>
                                    <option>General Purpose Claude 3 Haiku</option>
                                    <option>Writing Assistant GPT-4</option>
                                    <option>Creative Writing Claude 3</option>
                                </select>
                                <i data-lucide="chevron-down" class="absolute right-3 top-2.5 text-gray-400 w-4 h-4 pointer-events-none"></i>
                            </div>
                            
                            <div class="flex items-center">
                                <span class="text-sm text-gray-500 mr-2">Name:</span>
                                <input type="text" value="Fantasy Novels" class="border-0 border-b border-gray-300 focus:border-indigo-500 focus:ring-0 px-1 py-0 text-sm w-48">
                            </div>
                        </div>
                        
                        <div class="relative dropdown">
                            <button class="p-1 rounded-md hover:bg-gray-100">
                                <i data-lucide="more-horizontal" class="w-5 h-5 text-gray-500"></i>
                            </button>
                            
                            <div class="dropdown-content right-0 mt-1 py-1 w-48">
                                <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 flex items-center">
                                    <i data-lucide="star" class="w-4 h-4 mr-2 text-gray-500"></i>
                                    Pin Thread
                                </a>
                                <div class="relative sub-dropdown">
                                    <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100 flex items-center justify-between">
                                        <span class="flex items-center">
                                            <i data-lucide="copy" class="w-4 h-4 mr-2 text-gray-500"></i>
                                            Copy conversation
                                        </span>
                                        <i data-lucide="chevron-right" class="w-4 h-4 text-gray-400"></i>
                                    </a>
                                    <div class="sub-dropdown-content absolute left-full top-0 ml-1 py-1 w-40 bg-white border border-gray-200 rounded-md shadow-lg hidden">
                                        <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">JSON</a>
                                        <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">YAML</a>
                                        <a href="#" class="block px-4 py-2 text-sm text-gray-700 hover:bg-gray-100">Markdown</a>
                                    </div>
                                </div>
                                <a href="#" class="block px-4 py-2 text-sm text-red-600 hover:bg-gray-100 flex items-center">
                                    <i data-lucide="trash-2" class="w-4 h-4 mr-2 text-red-500"></i>
                                    Delete Thread
                                </a>
                            </div>
                        </div>
                    </div>
                </div>
                
                <!-- Chat Messages -->
                <div class="flex-1 overflow-y-auto p-4 space-y-4">
                    <div class="max-w-3xl mx-auto">
                        <div class="bg-gray-100 p-4 rounded-lg text-center text-sm text-gray-500">
                            This is a new thread. Start by typing a message in the box below. Any codex entries you mention will be included in the context. Alternatively, you can customize the context with the button at the bottom.
                        </div>
                    </div>
                    
                    <div class="max-w-3xl mx-auto fade-in">
                        <div class="flex justify-end">
                            <div class="user-message px-4 py-3 max-w-xl">
                                <p>I'm writing a fantasy novel set in a world where magic is derived from music. Can you help me brainstorm some unique magical systems based on different musical concepts?</p>
                            </div>
                        </div>
                    </div>
                    
                    <div class="max-w-3xl mx-auto fade-in">
                        <div class="flex justify-start">
                            <div class="ai-message px-4 py-3 max-w-xl">
                                <p>That's a fascinating concept! Here are some musical magic system ideas:</p>
                                <ul class="list-disc pl-5 mt-2 space-y-1">
                                    <li><strong>Harmonic Resonance:</strong> Wizards must maintain perfect pitch to cast spells, with dissonance causing magical backlash.</li>
                                    <li><strong>Rhythmic Patterns:</strong> Combat magic follows strict time signatures - break the rhythm and the spell collapses.</li>
                                    <li><strong>Instrument Specialization:</strong> Different instruments produce different magical effects (strings for illusions, percussion for elemental magic, etc.)</li>
                                </ul>
                                <div class="mt-3 pt-2 border-t border-gray-200 flex items-center justify-between text-xs text-gray-500">
                                    <span>GPT-4 Turbo · 299 words</span>
                                    <div class="flex space-x-2">
                                        <button class="hover:text-gray-700 flex items-center">
                                            <i data-lucide="refresh-cw" class="w-3 h-3 mr-1"></i> Retry
                                        </button>
                                        <button class="hover:text-gray-700 flex items-center">
                                            <i data-lucide="save" class="w-3 h-3 mr-1"></i> Save as Snippet
                                        </button>
                                        <button class="hover:text-gray-700 flex items-center">
                                            <i data-lucide="copy" class="w-3 h-3 mr-1"></i> Copy
                                        </button>
                                        <button class="hover:text-gray-700 flex items-center">
                                            <i data-lucide="file-text" class="w-3 h-3 mr-1"></i> Extract
                                        </button>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                
                <!-- Message Input -->
                <div class="bg-white border-t border-gray-200 p-4">
                    <div class="max-w-3xl mx-auto">
                        <div class="relative">
                            <div class="absolute left-3 top-2.5">
                                <button id="context-button" class="text-gray-400 hover:text-gray-600">
                                    <i data-lucide="file-text" class="w-5 h-5"></i>
                                </button>
                                
                                <!-- Context Dropdown -->
                                <div id="context-dropdown" class="hidden absolute left-0 bottom-full mb-2 w-64 bg-white border border-gray-200 rounded-md shadow-lg z-10 p-2">
                                    <div class="text-xs font-semibold text-gray-500 px-2 py-1">INCLUDE IN CONTEXT</div>
                                    <div class="space-y-1">
                                        <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded">Full Novel Outline</a>
                                        <div class="relative">
                                            <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded flex justify-between items-center">
                                                <span>Scene Context</span>
                                                <span class="text-xs text-gray-400">No selection</span>
                                            </a>
                                        </div>
                                        <a href="#" class="block px-3 py-2 text-sm text-gray-700 hover:bg-gray-100 rounded">Full Novel Text</a>
                                        <div class="px-3 py-2 flex items-center">
                                            <input type="checkbox" id="codex-entries" class="h-4 w-4 text-indigo-600 focus:ring-indigo-500 border-gray-300 rounded">
                                            <label for="codex-entries" class="ml-2 block text-sm text-gray-700">Codex Entries in Thread</label>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            
                            <textarea placeholder="Type your message..." rows="1" class="w-full pl-10 pr-16 py-3 border border-gray-300 rounded-md resize-none focus:outline-none focus:ring-1 focus:ring-indigo-500 focus:border-indigo-500"></textarea>
                            
                            <div class="absolute right-3 top-2.5 flex items-center">
                                <button class="p-1 text-gray-400 hover:text-gray-600 mr-1">
                                    <i data-lucide="paperclip" class="w-5 h-5"></i>
                                </button>
                                <button class="px-3 py-1.5 bg-indigo-600 text-white rounded-md text-sm font-medium hover:bg-indigo-700">
                                    <i data-lucide="send" class="w-4 h-4"></i>
                                </button>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
    
    <script>
        // Initialize Lucide icons
        lucide.createIcons();
        
        // Toggle context dropdown
        const contextButton = document.getElementById('context-button');
        const contextDropdown = document.getElementById('context-dropdown');
        
        contextButton.addEventListener('click', (e) => {
            e.stopPropagation();
            contextDropdown.classList.toggle('hidden');
        });
        
        // Close dropdown when clicking outside
        document.addEventListener('click', () => {
            contextDropdown.classList.add('hidden');
        });
        
        // Handle sub-dropdowns
        document.querySelectorAll('.sub-dropdown').forEach(dropdown => {
            const trigger = dropdown.querySelector('a');
            const content = dropdown.querySelector('.sub-dropdown-content');
            
            trigger.addEventListener('mouseenter', () => {
                content.classList.remove('hidden');
            });
            
            dropdown.addEventListener('mouseleave', () => {
                content.classList.add('hidden');
            });
        });
        
        // Auto-resize textarea
        const textarea = document.querySelector('textarea');
        textarea.addEventListener('input', function() {
            this.style.height = 'auto';
            this.style.height = (this.scrollHeight) + 'px';
        });
    </script>
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=algovenus/novelapp" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>