        :root {
            --bg-color: #ffffff;
            --sidebar-bg: #f0f4f9;
            --text-primary: #1f1f1f;
            --text-secondary: #444746;
            --border-color: #e0e3e1;
            --hover-bg: #dfe4ea;
            --accent-blue: #0b57d0;
            --font-main: 'Outfit', sans-serif;
            --font-serif: 'Georgia', serif;
            
            --tag-bg: #e0e7ff;
            --tag-text: #3730a3;
            --green-bg: #ecfdf5;
            --green-text: #065f46;
            --amber-bg: #fffbeb;
            --amber-text: #92400e;
        }

        * { box-sizing: border-box; }
        body { margin: 0; font-family: var(--font-main); background: var(--bg-color); color: var(--text-primary); height: 100vh; display: flex; overflow: hidden; }

        /* Scrollbar */
        ::-webkit-scrollbar { width: 8px; }
        ::-webkit-scrollbar-track { background: transparent; }
        ::-webkit-scrollbar-thumb { background: #c4c7c5; border-radius: 4px; }
        ::-webkit-scrollbar-thumb:hover { background: #8e918f; }

        /*Logo*/
        .top-logo {
            position: absolute;
            top: 24px;
            right: 32px;
            font-family: var(--font-mono);
            font-size: 20px;
            font-weight: 700;
            color: var(--text-primary);
            text-decoration: none;
            z-index: 100;
            letter-spacing: -0.5px;
        }
        
        .logo-accent { color: var(--accent-blue); }

        /* Sidebar */
        #sidebar { 
            width: 280px; 
            background: var(--sidebar-bg); 
            display: flex; 
            flex-direction: column; 
            flex-shrink: 0; 
            transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1); 
            z-index: 50; 
            overflow: hidden;
            white-space: nowrap;
        }
        body.sidebar-collapsed #sidebar { width: 0; }
        
        /* Mobile Overlay */
        #mobile-overlay { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.4); z-index: 40; display: none; }
        body.mobile-sidebar-open #mobile-overlay { display: block; }
        
        @media (max-width: 1024px) {
            #sidebar { position: fixed; height: 100%; left: 0; top: 0; transform: translateX(-100%); width: 280px; transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1); }
            body.mobile-sidebar-open #sidebar { transform: translateX(0); }
            body.sidebar-collapsed #sidebar { width: 280px; }
        }

        /* Sidebar Elements */
        .sidebar-header { padding: 16px; display: flex; align-items: center; min-height: 64px; }
        .btn-icon { background: none; border: none; cursor: pointer; padding: 8px; border-radius: 50%; color: var(--text-secondary); display: flex; align-items: center; justify-content: center; min-width: 40px; min-height: 40px; }
        .btn-icon:hover { background: var(--hover-bg); }
        .brand-text { margin-left: 8px; font-weight: 500; color: var(--text-secondary); opacity: 1; transition: opacity 0.2s; }
        
        .action-btn-container { padding: 0 16px; margin-bottom: 16px; }
        .action-btn { width: 100%; background: white; border: none; border-radius: 12px; padding: 12px 16px; display: flex; align-items: center; gap: 12px; cursor: pointer; font-weight: 500; color: var(--text-primary); font-family: var(--font-main); white-space: nowrap; }
        .action-btn:hover{ background: var(--hover-bg); }
        .action-btn svg { flex-shrink: 0; }
        
        .archive-container { flex: 1; overflow-y: auto; padding: 8px; }
        .archive-label { padding: 8px 16px; font-size: 11px; font-weight: 600; text-transform: uppercase; color: var(--text-secondary); margin-bottom: 4px; }
        .archive-item { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-radius: 50px; cursor: pointer; font-size: 14px; margin-bottom: 2px; color: var(--text-primary); }
        .archive-item:hover { background: var(--hover-bg); }
        .archive-item svg { flex-shrink: 0; }

        /* Main Content */
        main { flex: 1; display: flex; flex-direction: column; width: 100%; position: relative; }
        header { height: 64px; display: flex; align-items: center; justify-content: space-between; padding: 0 20px; position: sticky; top: 0; background: rgba(255,255,255,0.95); z-index: 10; border-bottom: 1px solid transparent; }
        .header-title { display: flex; align-items: center; gap: 12px; font-size: 20px; color: var(--text-secondary); }
        .user-avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--accent-blue); color: white; display: flex; align-items: center; justify-content: center; font-weight: bold; font-size: 14px; }
        
        #content-scroll { flex: 1; overflow-y: auto; padding-bottom: 40px; }
        .container { max-width: 900px; margin: 0 auto; padding: 24px; width: 100%; }
        .page-header { text-align: center; margin-bottom: 40px; }
        .date-badge { display: inline-block; background: #eff6ff; color: var(--accent-blue); padding: 4px 12px; border-radius: 50px; font-size: 12px; font-weight: 600; text-transform: uppercase; margin-bottom: 12px; }
        .main-headline { font-size: 32px; font-weight: 500; margin: 0; line-height: 1.2; }

        /* Article Card */
        .article-card { background: white; border: 1px solid var(--border-color); border-radius: 16px; padding: 32px; margin-bottom: 32px; transition: 0.2s; position: relative; }
        .article-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,0.08); border-color: #c7c7c7; }
        
        .meta-row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; font-size: 12px; font-weight: 500; align-items: center; }
        .chip { padding: 4px 10px; border-radius: 50px; text-transform: uppercase; letter-spacing: 0.5px; background: var(--tag-bg); color: var(--tag-text); }
        .article-title { font-family: var(--font-serif); font-size: 24px; font-weight: 500; margin: 0 0 16px 0; line-height: 1.4; }
        .content-label { display: block; font-size: 13px; font-weight: 600; text-transform: uppercase; margin-bottom: 6px; color: #111827; }
        .content-block { margin-bottom: 20px; line-height: 1.6; color: #374151; }
        .content-list { padding-left: 20px; margin: 0; }
        .content-list li { margin-bottom: 6px; }
        
        .grid-2-col { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 20px; }
        @media (max-width: 768px) { .grid-2-col { grid-template-columns: 1fr; } }

        .info-box { padding: 16px; border-radius: 12px; }
        .box-green { background: var(--green-bg); border: 1px solid #d1fae5; color: var(--green-text); }
        .box-amber { background: var(--amber-bg); border: 1px solid #fef3c7; color: var(--amber-text); }
        .box-label { display: block; font-size: 12px; font-weight: 700; text-transform: uppercase; margin-bottom: 8px; }
        .no-bullet-list { list-style: none; padding: 0; margin: 0; font-size: 14px; }
        .no-bullet-list li { margin-bottom: 4px; display: flex; align-items: flex-start; }
        .bullet-icon { margin-right: 8px; margin-top: 4px; }
        
        .key-val-row { display: flex; font-size: 14px; margin-bottom: 4px; }
        .key-label { font-weight: 700; min-width: 80px; text-transform: capitalize; }
        .question-box { margin-top: 24px; padding-top: 16px; border-top: 1px solid #f3f4f6; }
        .question-text { font-family: var(--font-serif); font-style: italic; font-weight: 500; color: #1f2937; font-size: 16px; }

        .card-actions { margin-top: 24px; display: flex; gap: 12px; flex-wrap: wrap; }
        .btn-deep-dive { background: var(--accent-blue); color: white; border: none; padding: 10px 20px; border-radius: 25px; font-weight: 500; cursor: pointer; transition: 0.2s; display: flex; align-items: center; gap: 8px; font-size: 14px; }
        .btn-deep-dive:hover { background: #0842a0; box-shadow: 0 2px 5px rgba(0,0,0,0.2); }
        .btn-outline { background: transparent; color: var(--text-secondary); border: 1px solid var(--border-color); padding: 10px 20px; border-radius: 25px; font-weight: 500; cursor: pointer; transition: 0.2s; font-size: 14px; text-decoration: none; display: inline-block; }
        .btn-outline:hover { background: #f3f4f6; color: var(--text-primary); }

        /* Wiki Button Style */
        .btn-wiki { background: #f3f4f6; color: #4b5563; border: 1px solid #d1d5db; padding: 10px 20px; border-radius: 25px; font-weight: 600; cursor: pointer; transition: 0.2s; font-size: 14px; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
        .btn-wiki:hover { background: #e5e7eb; color: #1f2937; }

        /* Model Answer Button */
        .btn-answer { 
            background: transparent; 
            color: var(--accent-blue); 
            border: 1px solid var(--accent-blue); 
            padding: 8px 16px; 
            border-radius: 8px; 
            font-weight: 600; 
            cursor: pointer; 
            transition: 0.2s; 
            font-size: 13px; 
            margin-top: 12px;
            display: inline-flex;
            align-items: center;
            gap: 6px;
        }
        .btn-answer:hover { background: #eff6ff; }
        .model-answer-container {
            display: none;
            margin-top: 16px;
            padding: 20px;
            background: #f8fafc;
            border-radius: 12px;
            border-left: 4px solid var(--accent-blue);
            font-size: 15px;
            color: #334155;
            line-height: 1.7;
        }
        .model-answer-container.active { display: block; animation: fadeIn 0.3s ease-out; }
        @keyframes fadeIn { from { opacity: 0; transform: translateY(-5px); } to { opacity: 1; transform: translateY(0); } }

        /* MODAL */
        .modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.6); z-index: 100; display: flex; justify-content: center; align-items: center; opacity: 0; pointer-events: none; transition: opacity 0.2s; backdrop-filter: blur(4px); }
        .modal-overlay.active { opacity: 1; pointer-events: auto; }
        .modal-content { background: white; width: 90%; max-width: 700px; max-height: 85vh; border-radius: 24px; padding: 0; display: flex; flex-direction: column; transform: translateY(20px); transition: transform 0.3s; box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1); }
        .modal-overlay.active .modal-content { transform: translateY(0); }
        .modal-header { padding: 20px 32px; border-bottom: 1px solid var(--border-color); display: flex; justify-content: space-between; align-items: start; }
        .modal-title { font-size: 22px; font-family: var(--font-serif); margin: 0; color: var(--text-primary); line-height: 1.3; }
        .modal-close { background: none; border: none; font-size: 28px; cursor: pointer; color: var(--text-secondary); line-height: 1; padding: 0; margin-left: 16px; }
        .modal-body { padding: 32px; overflow-y: auto; color: #374151; font-size: 16px; line-height: 1.8; }
        .modal-body h3 { font-size: 18px; color: var(--accent-blue); margin-top: 24px; margin-bottom: 12px; font-weight: 600; }
        
        .disclaimer { text-align: center; font-size: 12px; color: #9ca3af; padding-bottom: 32px; margin-top: 40px; }

        /* --- NOTEPAD & HIGHLIGHTER STYLES --- */
        
        /* Floating Buttons */
        .fab-container {
            position: fixed;
            bottom: 30px;
            right: 30px;
            display: flex;
            flex-direction: column;
            gap: 16px;
            z-index: 90;
            align-items: center;
        }

        .fab {
            width: 60px;
            height: 60px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
            cursor: pointer;
            transition: transform 0.2s, background-color 0.2s;
            color: white;
        }
        .fab:hover { transform: scale(1.05); }

        #notepad-fab { background-color: var(--accent-blue); }
        #notepad-fab:hover { background-color: #0842a0; }

        #pdf-fab { background-color: #3b82f6; } /* Blue for Print */
        #pdf-fab:hover { background-color: #2563eb; }
        
        /* Notepad Container */
        #notepad-container {
            position: fixed;
            bottom: 170px; /* Moved up to clear both buttons */
            right: 30px;
            width: 320px;
            height: 450px;
            background: white;
            border-radius: 20px;
            box-shadow: 0 8px 30px rgba(0,0,0,0.15);
            display: flex;
            flex-direction: column;
            z-index: 90;
            transform: scale(0.9) translateY(20px);
            opacity: 0;
            pointer-events: none;
            transition: all 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
            border: 1px solid var(--border-color);
        }
        #notepad-container.active {
            transform: scale(1) translateY(0);
            opacity: 1;
            pointer-events: auto;
        }
        .notepad-header {
            padding: 16px;
            border-bottom: 1px solid #f0f0f0;
            display: flex;
            justify-content: space-between;
            align-items: center;
            background: #f8fafc;
            border-radius: 20px 20px 0 0;
        }
        .notepad-title { font-weight: 600; color: var(--text-primary); font-size: 16px; }
        .notepad-actions button { background: none; border: none; cursor: pointer; color: var(--text-secondary); padding: 4px; margin-left: 4px; }
        .notepad-actions button:hover { color: var(--accent-blue); }
        
        #notepad-area {
            flex: 1;
            border: none;
            padding: 16px;
            font-family: 'Roboto', sans-serif;
            font-size: 14px;
            line-height: 1.6;
            color: #333;
            resize: none;
            outline: none;
            background: #fff;
        }
        #notepad-area::placeholder { color: #ccc; }
        
        /* Highlighter Tooltip */
        #highlight-tooltip {
            position: absolute;
            background: white;
            padding: 8px 12px;
            border-radius: 50px;
            box-shadow: 0 4px 15px rgba(0,0,0,0.15);
            display: flex;
            gap: 8px;
            z-index: 80;
            opacity: 0;
            pointer-events: none;
            transition: opacity 0.2s;
            border: 1px solid var(--border-color);
        }
        #highlight-tooltip.active { opacity: 1; pointer-events: auto; }
        .color-btn {
            width: 24px;
            height: 24px;
            border-radius: 50%;
            cursor: pointer;
            border: 2px solid transparent;
            transition: transform 0.1s;
        }
        .color-btn:hover { transform: scale(1.2); border-color: #ddd; }
        .color-btn.remove { 
            background: #fff; border: 1px solid #ddd; 
            display: flex; align-items: center; justify-content: center;
            font-size: 16px; color: #666;
        }
        
        /* Highlight Class */
        .highlight-span { border-radius: 4px; padding: 2px 0; cursor: pointer; transition: background-color 0.2s; }
        .highlight-span:hover { filter: brightness(0.95); }

        /* Save Button Style */
        .btn-save {
            background: transparent;
            border: 1px solid #d1d5db;
            color: #64748b;
            padding: 10px 20px;
            border-radius: 25px;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.2s ease;
        }
        
        .btn-save:hover {
            background: #f1f5f9;
            color: #0b57d0;
            border-color: #0b57d0;
        }
        
        /* State when article is saved */
        .btn-save.active {
            background: #eff6ff;
            color: #0b57d0;
            border-color: #0b57d0;
        }
        
        .btn-save.active svg {
            fill: currentColor; /* Fills the icon */
        }








