*{box-sizing:border-box;margin:0;padding:0}body{font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;min-height:100vh}.app-container{margin:0;padding:1rem 2.5%;width:100%}.app-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:1rem;padding-bottom:.75rem;border-bottom:1px solid var(--color-border)}.header-left{display:flex;align-items:center;gap:2rem}.app-header h1{font-size:1.4rem;font-weight:600}.header-info{display:flex;gap:2rem;font-size:.95rem;align-items:center}.header-info-item{display:flex;gap:.5rem;align-items:center}.header-info-label{font-weight:500;opacity:.7}.header-info-value{font-weight:600}.theme-toggle{padding:.375rem .75rem;font-size:1.25rem;background:none;border:2px solid var(--color-border);border-radius:6px;cursor:pointer;transition:all .2s;color:var(--color-text-secondary)}.theme-toggle:hover{border-color:var(--color-border-strong);background:var(--color-bg-surface-alt)}.query-container{display:flex;flex-direction:column;gap:1rem}.query-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:.5rem}.query-header h2{font-size:1.25rem;font-weight:600}.predefined-btn{padding:.5rem 1rem;background:var(--color-accent);color:#fff;border:none;border-radius:6px;font-size:.875rem;font-weight:500;cursor:pointer;transition:background .2s}.predefined-btn:hover{background:var(--color-accent-hover)}.query-controls{display:flex;justify-content:space-between;align-items:center;padding:1rem;border-radius:8px;border:1px solid var(--color-border);background:var(--color-bg-surface);gap:2rem;flex-wrap:wrap}.control-options{display:flex;gap:2rem;align-items:center}.control-group{display:flex;align-items:center;gap:.75rem}.control-group label{font-size:.875rem;font-weight:500;white-space:nowrap}.control-group select{padding:.5rem 2rem .5rem .75rem;border-radius:4px;border:1px solid var(--color-border-input);font-size:.875rem;cursor:pointer;min-height:36px;min-width:100px;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:var(--color-bg-input);color:var(--color-text-secondary);background-image:url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");background-repeat:no-repeat;background-position:right .5rem center;background-size:1.25em}.view-toggle-btn{padding:.5rem 1rem;border:1px solid var(--color-autocomplete-on-border);border-radius:6px;font-size:.875rem;font-weight:500;cursor:pointer;transition:all .2s;position:relative;background:var(--color-autocomplete-on-bg);color:var(--color-autocomplete-on-text)}.view-toggle-btn:hover:not(:disabled){background:var(--color-autocomplete-on-hover-bg);border-color:var(--color-autocomplete-on-hover-border)}.view-toggle-btn.disabled{background:var(--color-autocomplete-off-bg);color:var(--color-autocomplete-off-text);border-color:var(--color-autocomplete-off-border)}.view-toggle-btn.disabled:hover:not(:disabled){background:var(--color-autocomplete-off-hover-bg);border-color:var(--color-autocomplete-off-hover-border)}.view-toggle-btn:disabled{opacity:.5;cursor:not-allowed}.autocomplete-toggle:hover:not(:disabled):after{content:"⌘+K";position:absolute;bottom:-2rem;left:50%;transform:translate(-50%);background:var(--color-tooltip-bg);color:var(--color-tooltip-text);padding:.25rem .5rem;border-radius:4px;font-size:.75rem;white-space:nowrap;pointer-events:none;z-index:var(--z-tooltip)}.action-buttons{display:flex;gap:.75rem}.action-buttons button{padding:.625rem 1.25rem;border:none;border-radius:6px;font-size:.95rem;font-weight:600;cursor:pointer;transition:all .2s;position:relative}.action-buttons button:disabled{opacity:.5;cursor:not-allowed}.btn-execute{background:var(--color-success);color:#fff}.btn-execute:hover:not(:disabled){background:var(--color-success-hover);transform:translateY(-1px);box-shadow:0 2px 8px #28a7454d}.btn-execute:hover:not(:disabled):after{content:"⌘+Enter";position:absolute;bottom:-2rem;left:50%;transform:translate(-50%);background:var(--color-tooltip-bg);color:var(--color-tooltip-text);padding:.25rem .5rem;border-radius:4px;font-size:.75rem;white-space:nowrap;pointer-events:none;z-index:var(--z-tooltip)}.btn-explain{background:var(--color-info);color:#fff}.btn-explain:hover:not(:disabled){background:var(--color-info-hover);transform:translateY(-1px);box-shadow:0 2px 8px #17a2b84d}.btn-explain:hover:not(:disabled):after{content:"⌘+Shift+Enter";position:absolute;bottom:-2rem;left:50%;transform:translate(-50%);background:var(--color-tooltip-bg);color:var(--color-tooltip-text);padding:.25rem .5rem;border-radius:4px;font-size:.75rem;white-space:nowrap;pointer-events:none;z-index:var(--z-tooltip)}.btn-analyze{background:var(--color-purple);color:#fff}.btn-analyze:hover:not(:disabled){background:var(--color-purple-hover);transform:translateY(-1px);box-shadow:0 2px 8px #6f42c14d}.btn-analyze:hover:not(:disabled):after{content:"⌘+Option+Enter";position:absolute;bottom:-2rem;left:50%;transform:translate(-50%);background:var(--color-tooltip-bg);color:var(--color-tooltip-text);padding:.25rem .5rem;border-radius:4px;font-size:.75rem;white-space:nowrap;pointer-events:none;z-index:var(--z-tooltip)}.error-message{padding:1rem;background:var(--color-bg-error-inner);color:var(--color-text-error-inner);border:1px solid var(--color-border-error-inner);border-radius:6px;margin-top:1rem}.loading{padding:2rem;text-align:center;font-size:1.1rem;opacity:.7}@media (max-width: 1024px){.header-left{flex-direction:column;gap:.5rem;align-items:flex-start}.query-controls{flex-direction:column;gap:1rem}.control-options,.action-buttons{width:100%;justify-content:center}}.query-editor-ace{border-radius:6px;border:1px solid var(--color-editor-border)!important}.query-results{margin-top:.5rem;position:relative}.loading-overlay{position:absolute;top:0;left:0;right:0;bottom:0;display:flex;align-items:center;justify-content:center;z-index:var(--z-loading-overlay);border-radius:4px;background:var(--color-bg-overlay)}.loading-overlay .loading{padding:2rem;text-align:center;font-size:1.1rem;opacity:1}.results-section{margin-top:1rem}.query-tabs{display:flex;gap:.5rem;margin-bottom:1rem;border-bottom:2px solid var(--color-border);overflow-x:auto}.query-tab{padding:.75rem 1.5rem;background:transparent;border:none;border-bottom:3px solid transparent;cursor:pointer;font-size:.95rem;font-weight:500;white-space:nowrap;transition:all .2s;margin-bottom:-2px;color:var(--color-text-muted)}.query-tab:hover{border-bottom-color:var(--color-text-muted);color:var(--color-text-secondary);background:var(--color-bg-surface-alt)}.query-tab.active{border-bottom-color:var(--color-accent);color:var(--color-text-primary)}.query-tab-error{border-bottom-color:#dc3545;color:#dc3545}.results-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:1rem}.header-content{flex:1}.query-label{font-size:.875rem;font-weight:600;margin-bottom:.25rem;text-transform:uppercase;letter-spacing:.5px;color:var(--color-text-muted)}.results-header h3{font-size:1.2rem;font-weight:700;margin:0}.executed-query{padding:.75rem;border-left:3px solid var(--color-accent);font-family:Monaco,Menlo,Ubuntu Mono,Consolas,source-code-pro,monospace;font-size:.9rem;margin-bottom:.5rem;background:var(--color-bg-code);color:var(--color-text-code)}.query-info{margin-bottom:1rem}.fullscreen-toggle{padding:.5rem .75rem;border:1px solid var(--color-border);cursor:pointer;border-radius:4px;font-size:1.25rem;transition:all .2s;background:transparent;line-height:1;flex-shrink:0;color:var(--color-text-secondary)}.fullscreen-toggle:hover{background:var(--color-bg-surface-raised);border-color:var(--color-border-strong)}.fullscreen-backdrop{position:fixed;top:0;left:0;right:0;bottom:0;background:#000000b3;z-index:var(--z-fullscreen-backdrop)}.query-results.fullscreen{position:fixed;top:0;left:0;right:0;bottom:0;z-index:var(--z-fullscreen);padding:1rem;overflow:auto;background:var(--color-bg)}.fullscreen-close{position:absolute;top:1rem;right:1rem;padding:.5rem .75rem;border:1px solid var(--color-border);cursor:pointer;border-radius:4px;font-size:1.5rem;transition:all .2s;background:transparent;line-height:1;z-index:var(--z-fullscreen-close);color:var(--color-text-secondary)}.fullscreen-close:hover{background:var(--color-bg-surface-raised);border-color:var(--color-border-strong)}.fullscreen-results-title{font-size:1.2rem;font-weight:700;margin-top:1rem;margin-bottom:1rem}.query-results.fullscreen .table-wrapper{max-height:calc(100vh - 100px)}.error-display{display:flex;align-items:flex-start;gap:1rem;padding:1.5rem;border-radius:4px;border:1px solid var(--color-border-error);border-left:4px solid var(--color-border-error-left);background:var(--color-bg-error)}.error-icon{font-size:2rem;flex-shrink:0;color:var(--color-icon-error)}.error-content{flex:1}.error-title{font-weight:600;font-size:1.1rem;margin-bottom:.5rem;color:var(--color-title-error)}.error-message{font-family:Monaco,Menlo,Ubuntu Mono,Consolas,source-code-pro,monospace;font-size:.95rem;line-height:1.5;white-space:pre-wrap;word-break:break-word;padding:.75rem;border-radius:4px;background:var(--color-bg-error-inner);color:var(--color-text-error-inner);border:1px solid var(--color-border-error-inner)}.table-wrapper{overflow-x:auto;border-radius:4px;max-height:calc(100vh - 550px);overflow-y:auto;border:1px solid var(--color-border)}.results-table{width:100%;border-collapse:collapse;background:var(--color-bg-surface);color:var(--color-text-primary)}.results-table thead{position:sticky;top:0;z-index:var(--z-table-header);background:var(--color-bg-surface-alt);border-bottom:2px solid var(--color-border)}.results-table th{padding:.75rem;text-align:left;font-weight:600;white-space:nowrap;border-right:1px solid var(--color-border);color:var(--color-text-secondary)}.results-table th:last-child{border-right:none}.results-table td{padding:.75rem;border-top:1px solid var(--color-border);border-right:1px solid var(--color-border)}.results-table td:last-child{border-right:none}.results-table tbody tr:hover{background:var(--color-bg-surface-alt)}.json-container{position:relative}.copy-button{position:absolute;top:.5rem;right:.5rem;padding:.5rem 1rem;border-radius:4px;border:1px solid var(--color-border-input);cursor:pointer;font-size:.875rem;font-weight:500;transition:all .2s;z-index:var(--z-table-header);background:var(--color-bg-surface);color:var(--color-text-secondary)}.copy-button:hover{background:var(--color-bg-surface-raised);border-color:var(--color-border-strong)}.json-view{padding:3rem 1.5rem 1.5rem;border-radius:4px;overflow-x:auto;font-family:Monaco,Menlo,Ubuntu Mono,Consolas,source-code-pro,monospace;font-size:.875rem;line-height:1.6;white-space:pre;background:var(--color-bg-code-alt);color:var(--color-text-primary);border:1px solid var(--color-border)}.no-results{padding:2rem;text-align:center;border-radius:4px;color:var(--color-text-muted);background:var(--color-bg-surface)}.modal-overlay{position:fixed;top:0;left:0;right:0;bottom:0;background:#000000b3;display:flex;align-items:center;justify-content:center;z-index:var(--z-modal)}.modal-content{width:90%;max-width:900px;max-height:85vh;display:flex;flex-direction:column;border-radius:8px;box-shadow:0 4px 20px #0000004d;background:var(--color-bg-surface)}.modal-header{display:flex;justify-content:space-between;align-items:center;padding:1.5rem;border-bottom:1px solid var(--color-border)}.modal-header h2{margin:0;font-size:1.5rem;font-weight:600;color:var(--color-text-primary)}.close-button{background:none;border:none;font-size:2rem;cursor:pointer;padding:0;width:2rem;height:2rem;display:flex;align-items:center;justify-content:center;line-height:1;border-radius:4px;transition:background .2s;color:var(--color-text-muted)}.close-button:hover{color:var(--color-text-primary);background:var(--color-bg-surface-raised)}.modal-body{padding:1.5rem;overflow-y:auto;flex:1}.search-container{margin-bottom:1rem}.search-input{width:100%;padding:.75rem;border:1px solid var(--color-border-input);border-radius:6px;font-size:1rem;background:var(--color-bg-input);color:var(--color-text-secondary)}.search-input::placeholder{color:var(--color-text-muted)}.queries-list{display:flex;flex-direction:column;gap:.75rem}.query-item{padding:1rem 1.25rem;border:1px solid var(--color-border);border-radius:6px;cursor:pointer;transition:all .2s;background:var(--color-bg-surface-alt)}.query-item:hover{background:var(--color-bg-surface-raised);border-color:var(--color-accent);transform:translate(4px)}.query-description{font-weight:500;font-size:.95rem;color:var(--color-text-primary)}.loading,.no-results{padding:2rem;text-align:center;color:var(--color-text-muted)}.error{padding:2rem;text-align:center;color:#dc3545}:root{font-family:Inter,system-ui,Avenir,Helvetica,Arial,sans-serif;line-height:1.5;font-weight:400;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;--z-table-header: 10;--z-loading-overlay: 1000;--z-modal: 1000;--z-fullscreen: 9999;--z-fullscreen-backdrop: 9998;--z-fullscreen-close: 10000;--z-tooltip: 100;--color-bg: #f5f5f5;--color-bg-surface: #ffffff;--color-bg-surface-alt: #f8f9fa;--color-bg-surface-raised: #e9ecef;--color-bg-input: #ffffff;--color-bg-code: #f5f5f5;--color-bg-code-alt: #f8f9fa;--color-bg-error: #fff3cd;--color-bg-error-inner: #f8d7da;--color-bg-overlay: rgba(255, 255, 255, .8);--color-text-primary: #212529;--color-text-secondary: #495057;--color-text-muted: #6c757d;--color-text-code: #333;--color-text-error: #856404;--color-text-error-inner: #721c24;--color-border: #dee2e6;--color-border-input: #ced4da;--color-border-strong: #adb5bd;--color-border-error: #ffc107;--color-border-error-left: #ff9800;--color-border-error-inner: #f5c6cb;--color-accent: #007bff;--color-accent-hover: #0056b3;--color-success: #28a745;--color-success-hover: #218838;--color-info: #17a2b8;--color-info-hover: #138496;--color-purple: #6f42c1;--color-purple-hover: #5a32a3;--color-icon-error: #ff9800;--color-title-error: #856404;--color-autocomplete-on-bg: #d3d3d3;--color-autocomplete-on-text: #333;--color-autocomplete-on-border: #aaa;--color-autocomplete-on-hover-bg: #c0c0c0;--color-autocomplete-on-hover-border: #999;--color-autocomplete-off-bg: #228b22;--color-autocomplete-off-text: white;--color-autocomplete-off-border: #1e7b1e;--color-autocomplete-off-hover-bg: #1e7b1e;--color-autocomplete-off-hover-border: #196b19;--color-tooltip-bg: #212529;--color-tooltip-text: white;--color-editor-border: #dee2e6}body.dark-mode{--color-bg: #1e1e1e;--color-bg-surface: #2a2a2a;--color-bg-surface-alt: #1e1e1e;--color-bg-surface-raised: #333333;--color-bg-input: #1e1e1e;--color-bg-code: #2a2a2a;--color-bg-code-alt: #1e1e1e;--color-bg-error: #3d2a1f;--color-bg-error-inner: #2a1f1a;--color-bg-overlay: rgba(30, 30, 30, .8);--color-text-primary: #e0e0e0;--color-text-secondary: #e0e0e0;--color-text-muted: #999999;--color-text-code: #e0e0e0;--color-text-error: #fbbf24;--color-text-error-inner: #fca5a5;--color-border: #444444;--color-border-input: #555555;--color-border-strong: #666666;--color-border-error: #6b4423;--color-border-error-left: #d97706;--color-border-error-inner: #7c2d12;--color-icon-error: #fbbf24;--color-title-error: #fbbf24;--color-autocomplete-on-bg: #555555;--color-autocomplete-on-text: #e0e0e0;--color-autocomplete-on-border: #666666;--color-autocomplete-on-hover-bg: #666666;--color-autocomplete-on-hover-border: #777777;--color-autocomplete-off-bg: #2d5016;--color-autocomplete-off-text: #90ee90;--color-autocomplete-off-border: #3d6b1f;--color-autocomplete-off-hover-bg: #3d6b1f;--color-autocomplete-off-hover-border: #4d7b2f;--color-editor-border: #444444}#root{max-width:none;margin:0;padding:0;width:100%}body{margin:0;display:block;min-width:320px;min-height:100vh;background-color:var(--color-bg);color:var(--color-text-primary);transition:background-color .3s,color .3s}h1{font-size:2em;line-height:1.1}button{border-radius:8px;border:1px solid transparent;padding:.6em 1.2em;font-size:1em;font-weight:500;font-family:inherit;background-color:var(--color-bg-surface);cursor:pointer;transition:border-color .25s;margin-right:.5em}button:hover{border-color:var(--color-accent)}button:focus,button:focus-visible{outline:4px auto -webkit-focus-ring-color}
