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

        body {
            font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
            background-color: #f5f5f5;
            padding: 20px;
        }

        /* Chat Button */
        .chat-button {
            position: fixed;
            bottom: 20px;
            right: 20px;
            width: 60px;
            height: 60px;
            background: linear-gradient(135deg, #ff6b35, #f7931e);
            border: none;
            border-radius: 50%;
            cursor: pointer;
            box-shadow: 0 4px 20px rgba(255, 107, 53, 0.3);
            z-index: 1000;
            transition: all 0.3s ease;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .chat-button:hover {
            transform: scale(1.1);
            box-shadow: 0 6px 25px rgba(255, 107, 53, 0.4);
        }

        .chat-button i {
            color: white;
            font-size: 24px;
        }

        /* Chat Panel */
        .chat-panel {
            position: fixed;
            top: 0;
            right: -400px;
            width: 400px;
            height: 100vh;
            background: white;
            box-shadow: -5px 0 20px rgba(0, 0, 0, 0.1);
            z-index: 1001;
            transition: right 0.3s ease;
            display: flex;
            flex-direction: column;
        }

        .chat-panel.open {
            right: 0;
        }

        /* Header */
        .chat-header {
            background: linear-gradient(135deg, #ff6b35, #f7931e);
            color: white;
            padding: 20px;
            position: relative;
        }

        .chat-header h3 {
            font-size: 18px;
            font-weight: 600;
            margin-bottom: 4px;
        }

        .chat-header p {
            font-size: 14px;
            opacity: 0.9;
            margin-bottom: 15px;
        }

        .close-btn {
            position: absolute;
            top: 15px;
            right: 15px;
            background: none;
            border: none;
            color: white;
            font-size: 20px;
            cursor: pointer;
            opacity: 0.8;
            transition: opacity 0.2s;
        }

        .close-btn:hover {
            opacity: 1;
        }

        /* Improved dropdown styling and layout */
        .filters {
            display: flex;
            gap: 10px;
            flex-wrap: wrap;
        }

        .filter-select {
            background: rgba(255, 255, 255, 0.15);
            border: 1px solid rgba(255, 255, 255, 0.25);
            color: white;
            padding: 8px 12px;
            border-radius: 8px;
            font-size: 13px;
            font-weight: 500;
            cursor: pointer;
            min-width: 120px;
            transition: all 0.2s ease;
            appearance: none;
            background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%23ffffff' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
            background-position: right 8px center;
            background-repeat: no-repeat;
            background-size: 16px;
            padding-right: 32px;
        }

        .filter-select:hover {
            background: rgba(255, 255, 255, 0.2);
            border-color: rgba(255, 255, 255, 0.4);
        }

        .filter-select:focus {
            outline: none;
            background: rgba(255, 255, 255, 0.25);
            border-color: rgba(255, 255, 255, 0.5);
        }

        .filter-select option {
            background: #2d2d2d;
            color: white;
            padding: 8px;
        }
        
        .filter-toggle.has-filters {
            background: #ff6b35;
            color: white;
            border-color: #ff6b35;
        }

        .filter-toggle.has-filters:hover {
            background: #e55a2b;
        }

        /* Chat Body */
        .chat-body {
            flex: 1;
            padding: 20px;
            overflow-y: auto;
            background: #f8f9fa;
            /* Added better scrollbar styling */
            scrollbar-width: thin;
            scrollbar-color: #ddd transparent;
        }

        .chat-body::-webkit-scrollbar {
            width: 6px;
        }

        .chat-body::-webkit-scrollbar-track {
            background: transparent;
        }

        .chat-body::-webkit-scrollbar-thumb {
            background: #ddd;
            border-radius: 3px;
        }

        .chat-body::-webkit-scrollbar-thumb:hover {
            background: #bbb;
        }

        .message {
            margin-bottom: 16px;
            display: flex;
            align-items: flex-end;
            /* Added clear fix for better message spacing */
            clear: both;
        }

        .message.user {
            justify-content: flex-end;
        }

        .message.bot {
            justify-content: flex-start;
        }

        .message-content {
            max-width: 85%;
            padding: 12px 16px;
            border-radius: 18px;
            font-size: 14px;
            line-height: 1.5;
            word-wrap: break-word;
            /* Added better text rendering */
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
        }

        .message.user .message-content {
            background: linear-gradient(135deg, #ff6b35, #f7931e);
            color: white;
            border-bottom-right-radius: 6px;
            box-shadow: 0 2px 8px rgba(255, 107, 53, 0.2);
        }

        .message.bot .message-content {
            min-width: 85px;
            background: white;
            color: #333;
            border: 1px solid #e8e8e8;
            border-bottom-left-radius: 6px;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
        }

        /* Added styles for trading indicator display */
        .indicator-card {
            background: white;
            border: 1px solid #e8e8e8;
            border-radius: 12px;
            padding: 16px;
            margin: 8px 0;
            box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
            max-width: 85%;
        }

        .indicator-header {
            display: flex;
            align-items: center;
            gap: 8px;
            margin-bottom: 12px;
            padding-bottom: 8px;
            border-bottom: 1px solid #f0f0f0;
        }

        .indicator-icon {
            width: 24px;
            height: 24px;
            background: linear-gradient(135deg, #ff6b35, #f7931e);
            border-radius: 6px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-size: 12px;
            font-weight: bold;
        }

        .indicator-title {
            font-weight: 600;
            color: #333;
            font-size: 15px;
        }

        .indicator-lines {
            margin-top: 12px;
        }

        .indicator-line {
            display: flex;
            align-items: center;
            gap: 8px;
            padding: 6px 0;
            font-size: 13px;
        }

        .line-color {
            width: 12px;
            height: 12px;
            border-radius: 2px;
            border: 1px solid rgba(0, 0, 0, 0.1);
        }

        .line-info {
            flex: 1;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .line-type {
            font-weight: 500;
            color: #555;
            text-transform: uppercase;
            font-size: 11px;
        }

        .line-length {
            color: #777;
            font-size: 12px;
        }

        .script-section {
            margin-top: 12px;
            padding-top: 12px;
            border-top: 1px solid #f0f0f0;
        }

        .script-label {
            font-size: 11px;
            color: #777;
            text-transform: uppercase;
            font-weight: 500;
            margin-bottom: 6px;
        }

        .script-code {
            background: #f8f9fa;
            border: 1px solid #e9ecef;
            border-radius: 6px;
            padding: 8px 10px;
            font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
            font-size: 11px;
            color: #495057;
            line-height: 1.4;
            white-space: pre-wrap;
            word-break: break-all;
        }

        /* Improved typing indicator positioning and styling */
        .typing-indicator {
            display: none;
            align-items: center;
            gap: 8px;
            padding: 12px 16px;
            background: white;
            border: 1px solid #e8e8e8;
            border-radius: 18px;
            border-bottom-left-radius: 6px;
            max-width: 70px;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
            margin-bottom: 0;
        }

        .typing-indicator.show {
            display: flex;
        }

        .typing-dots {
            display: flex;
            gap: 3px;
        }

        .typing-dot {
            width: 6px;
            height: 6px;
            background: #999;
            border-radius: 50%;
            animation: typing 1.4s infinite;
        }

        .typing-dot:nth-child(2) {
            animation-delay: 0.2s;
        }

        .typing-dot:nth-child(3) {
            animation-delay: 0.4s;
        }

        @keyframes typing {
            0%, 60%, 100% {
                transform: translateY(0);
                opacity: 0.4;
            }
            30% {
                transform: translateY(-8px);
                opacity: 1;
            }
        }

        /* Chat Footer */
        .chat-footer {
            padding: 20px;
            background: white;
            border-top: 1px solid #e8e8e8;
            /* Added subtle shadow for better separation */
            box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.05);
        }

        /* Added missing input container and input field styles */
        .input-container {
            display: flex;
            gap: 8px;
            align-items: center;
        }

        .chat-input {
            flex: 1;
            padding: 12px 16px;
            border: 1px solid #e8e8e8;
            border-radius: 24px;
            font-size: 14px;
            outline: none;
            background: #f8f9fa;
            transition: all 0.2s ease;
            resize: none;
            font-family: inherit;
        }

        .chat-input:focus {
            border-color: #ff6b35;
            background: white;
            box-shadow: 0 0 0 3px rgba(255, 107, 53, 0.1);
        }

        .chat-input::placeholder {
            color: #999;
        }

        .send-btn {
            width: 40px;
            height: 40px;
            background: linear-gradient(135deg, #ff6b35, #f7931e);
            border: none;
            border-radius: 50%;
            color: white;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: all 0.2s ease;
            flex-shrink: 0;
        }

        .send-btn:hover:not(:disabled) {
            transform: scale(1.05);
            box-shadow: 0 2px 8px rgba(255, 107, 53, 0.3);
        }

        .send-btn:disabled {
            opacity: 0.5;
            cursor: not-allowed;
            transform: none;
        }

        .send-btn i {
            font-size: 14px;
        }

        /* Added styles for suggestion buttons */
        .suggestions-container {
            margin-bottom: 16px;
        }

        .suggestions-header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            margin-bottom: 12px;
        }

        .suggestions-title {
            font-size: 12px;
            font-weight: 600;
            color: #666;
            text-transform: uppercase;
            letter-spacing: 0.5px;
        }

        .filter-toggle {
            background: none;
            border: 1px solid #e8e8e8;
            border-radius: 6px;
            padding: 4px 8px;
            font-size: 11px;
            color: #666;
            cursor: pointer;
            transition: all 0.2s ease;
            display: flex;
            align-items: center;
            gap: 4px;
        }

        .filter-toggle:hover {
            border-color: #ff6b35;
            color: #ff6b35;
        }

        .filter-toggle.active {
            background: #ff6b35;
            border-color: #ff6b35;
            color: white;
        }

        .suggestions-grid {
            display: flex;
            gap: 8px;
            margin-bottom: 12px;
            overflow-x: auto;
            padding-bottom: 4px;
        }

        .suggestions-grid::-webkit-scrollbar {
            height: 4px;
        }

        .suggestions-grid::-webkit-scrollbar-track {
            background: transparent;
        }

        .suggestions-grid::-webkit-scrollbar-thumb {
            background: #ddd;
            border-radius: 2px;
        }

        .suggestion-btn {
            background: #f8f9fa;
            border: 1px solid #e8e8e8;
            border-radius: 12px;
            padding: 10px 12px;
            font-size: 12px;
            font-weight: 500;
            color: #555;
            cursor: pointer;
            transition: all 0.2s ease;
            text-align: center;
            white-space: nowrap;
            flex-shrink: 0;
            min-width: 100px;
        }

        .filters-panel {
            display: none;
            background: #f8f9fa;
            border: 1px solid #e8e8e8;
            border-radius: 8px;
            padding: 12px;
            margin-bottom: 12px;
            animation: slideDown 0.2s ease;
        }

        .filters-panel.show {
            display: block;
        }

        /* Added missing filter styles */
        .filter-group {
            margin-bottom: 12px;
        }

        .filter-group:last-child {
            margin-bottom: 0;
        }

        .filter-label {
            font-size: 11px;
            font-weight: 600;
            color: #666;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            margin-bottom: 6px;
        }

        .filter-options {
            display: flex;
            gap: 6px;
        }

        .filter-option {
            background: white;
            border: 1px solid #e8e8e8;
            border-radius: 6px;
            padding: 6px 12px;
            font-size: 11px;
            font-weight: 500;
            color: #666;
            cursor: pointer;
            transition: all 0.2s ease;
        }

        .filter-option:hover {
            border-color: #ff6b35;
            color: #ff6b35;
        }

        .filter-option.active {
            background: #ff6b35;
            border-color: #ff6b35;
            color: white;
        }

        @keyframes slideDown {
            from {
                opacity: 0;
                transform: translateY(-10px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        /* Enhanced styles for formatted JSON display */
        .json-content {
            background: white !important;
            border: 1px solid #e8e8e8 !important;
            border-radius: 12px !important;
            padding: 0 !important;
            overflow: hidden;
            max-width: 90%;
            margin: 8px 0;
        }

        .json-container {
            width: 100%;
        }

        .json-header {
            background: linear-gradient(135deg, #6c757d, #495057);
            color: white;
            padding: 12px 16px;
            font-size: 13px;
            font-weight: 600;
            display: flex;
            align-items: center;
            justify-content: space-between;
            border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        }

        .json-header-left {
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .json-header i {
            font-size: 12px;
        }

        .json-copy-btn {
            background: rgba(255, 255, 255, 0.1);
            border: 1px solid rgba(255, 255, 255, 0.2);
            color: white;
            border-radius: 4px;
            padding: 4px 8px;
            font-size: 11px;
            cursor: pointer;
            transition: all 0.2s ease;
        }

        .json-copy-btn:hover {
            background: rgba(255, 255, 255, 0.2);
        }

        .json-body {
            padding: 16px;
            background: white;
            font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
            font-size: 13px;
            line-height: 1.5;
            max-height: 400px;
            overflow-y: auto;
        }

        .json-body::-webkit-scrollbar {
            width: 6px;
        }

        .json-body::-webkit-scrollbar-track {
            background: #f1f1f1;
            border-radius: 3px;
        }

        .json-body::-webkit-scrollbar-thumb {
            background: #c1c1c1;
            border-radius: 3px;
        }

        .json-item {
            margin: 4px 0;
            display: flex;
            align-items: flex-start;
            min-height: 20px;
        }

        .json-key {
            color: #0066cc;
            font-weight: 600;
            margin-right: 8px;
            flex-shrink: 0;
            min-width: fit-content;
        }

        .json-colon {
            color: #666;
            margin-right: 8px;
            flex-shrink: 0;
        }

        .json-value {
            color: #333;
            word-break: break-word;
            flex: 1;
        }

        .json-value.json-string {
            color: #22863a;
        }

        .json-value.json-number {
            color: #005cc5;
            font-weight: 500;
        }

        .json-value.json-boolean {
            color: #d73a49;
            font-weight: 500;
        }

        .json-value.json-null {
            color: #6f42c1;
            font-style: italic;
        }

        .json-value.json-array,
        .json-value.json-object {
            color: #6f42c1;
            font-style: italic;
        }

        .json-expandable {
            cursor: pointer;
            user-select: none;
        }

        .json-expandable:hover {
            background: rgba(0, 102, 204, 0.05);
            border-radius: 3px;
        }

        .json-expand-icon {
            color: #666;
            font-size: 10px;
            margin-right: 4px;
            transition: transform 0.2s ease;
            display: inline-block;
            width: 12px;
        }

        .json-expand-icon.expanded {
            transform: rotate(90deg);
        }

        .json-nested {
            margin-left: 20px;
            border-left: 2px solid #f0f0f0;
            padding-left: 12px;
            margin-top: 4px;
        }

        .json-array-item {
            color: #666;
            font-size: 12px;
        }

        .json-summary {
            color: #888;
            font-size: 12px;
            font-style: italic;
        }

        /* Enhanced table-like display for structured data */
        .json-table {
            width: 100%;
            border-collapse: collapse;
            margin-top: 8px;
        }

        .json-table th,
        .json-table td {
            padding: 8px 12px;
            text-align: left;
            border-bottom: 1px solid #f0f0f0;
            font-size: 12px;
        }

        .json-table th {
            background: #f8f9fa;
            font-weight: 600;
            color: #495057;
            border-bottom: 2px solid #e9ecef;
        }

        .json-table td {
            color: #333;
        }

        .json-highlight {
            background: rgba(255, 107, 53, 0.1);
            padding: 2px 4px;
            border-radius: 3px;
            border: 1px solid rgba(255, 107, 53, 0.2);
        }

        /* Chart container styles */
        .chart-container {
            margin-top: 12px;
            padding-top: 12px;
            border-top: 1px solid #f0f0f0;
        }

        .chart-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 10px;
        }

        .chart-title {
            font-size: 14px;
            font-weight: 600;
            color: #333;
        }

        .chart-period {
            font-size: 11px;
            color: #777;
            text-transform: uppercase;
        }

        .chart-canvas {
            position: relative;
            height: 200px; /* Fixed height for the chart */
        }

        .chart-canvas canvas {
            width: 100% !important;
            height: 100% !important;
        }

        /* Responsive Design */
        @media (max-width: 768px) {
            .chat-panel {
                width: 100vw;
                right: -100vw;
            }

            .chat-button {
                bottom: 15px;
                right: 15px;
                width: 55px;
                height: 55px;
            }

            .chat-button i {
                font-size: 22px;
            }
        }

        /* Overlay */
        .chat-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100vw;
            height: 100vh;
            background: rgba(0, 0, 0, 0.3);
            z-index: 1000;
            opacity: 0;
            visibility: hidden;
            transition: all 0.3s ease;
        }

        .chat-overlay.show {
            opacity: 1;
            visibility: visible;
        }

        @media (min-width: 769px) {
            .chat-overlay {
                display: none;
            }
        }

        /* Usage limit styles */
        .usage-info {
            background: rgba(255, 255, 255, 0.1);
            border: 1px solid rgba(255, 255, 255, 0.2);
            border-radius: 8px;
            padding: 8px 12px;
            margin-top: 10px;
            font-size: 12px;
            color: rgba(255, 255, 255, 0.9);
            display: flex;
            align-items: center;
            justify-content: space-between;
        }

        .usage-count {
            font-weight: 600;
        }

        .usage-warning {
            background: rgba(255, 193, 7, 0.2);
            border-color: rgba(255, 193, 7, 0.4);
            color: #ffc107;
        }

        .usage-expired {
            background: rgba(220, 53, 69, 0.2);
            border-color: rgba(220, 53, 69, 0.4);
            color: #dc3545;
        }

        .subscription-prompt {
            background: white;
            border: 1px solid #e8e8e8;
            border-radius: 12px;
            padding: 20px;
            margin: 16px 0;
            text-align: center;
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
        }

        .subscription-prompt h4 {
            color: #333;
            font-size: 16px;
            font-weight: 600;
            margin-bottom: 8px;
        }

        .subscription-prompt p {
            color: #666;
            font-size: 14px;
            line-height: 1.5;
            margin-bottom: 16px;
        }

        .subscription-buttons {
            display: flex;
            gap: 8px;
            justify-content: center;
        }

        .upgrade-btn {
            background: linear-gradient(135deg, #ff6b35, #f7931e);
            color: white;
            border: none;
            border-radius: 8px;
            padding: 10px 20px;
            font-size: 13px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.2s ease;
            text-decoration: none;
            display: inline-flex;
            align-items: center;
            gap: 6px;
        }

        .upgrade-btn:hover {
            transform: translateY(-1px);
            box-shadow: 0 4px 12px rgba(255, 107, 53, 0.3);
        }

        .learn-more-btn {
            background: transparent;
            color: #666;
            border: 1px solid #e8e8e8;
            border-radius: 8px;
            padding: 10px 16px;
            font-size: 13px;
            cursor: pointer;
            transition: all 0.2s ease;
        }

        .learn-more-btn:hover {
            border-color: #ff6b35;
            color: #ff6b35;
        }

        .input-disabled {
            opacity: 0.6;
            pointer-events: none;
        }
        
        /* Added styles for financial disclaimer */
        .financial-disclaimer {
            background: linear-gradient(135deg, #fff3cd, #ffeaa7);
            border: 1px solid #ffc107;
            border-radius: 8px;
            padding: 10px 12px;
            margin: 8px 0;
            font-size: 11px;
            color: #856404;
            line-height: 1.4;
            display: flex;
            align-items: flex-start;
            gap: 8px;
            box-shadow: 0 2px 4px rgba(255, 193, 7, 0.1);
            position: relative;
            z-index: 10;
        }

        .financial-disclaimer .disclaimer-content {
            display: flex;
            align-items: flex-start;
            gap: 8px;
            flex: 1;
        }

        .financial-disclaimer i {
            font-size: 12px;
            flex-shrink: 0;
        }
        
        /* Added styles for clear filters button */
        .clear-filters-btn {
            background: #ff4444;
            color: white;
            border: none;
            padding: 4px 8px;
            border-radius: 4px;
            font-size: 12px;
            cursor: pointer;
            transition: background-color 0.2s;
        }

        .clear-filters-btn:hover {
            background: #cc3333;
        }

        .filter-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 10px;
            font-weight: bold;
        }

        /* Added styling for active filter button */
        #filterToggle.has-filters {
            background: #ff6b35;
            color: white;
            border-color: #ff6b35;
        }

        #filterToggle.has-filters:hover {
            background: #e55a2b;
        }