:root{--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light;--bg:#eef9fb;--panel:#fff;--ink:#00384d;--muted:#5c7280;--line:#d9edf2;--line-strong:#b9dce5;--accent:#00384d;--accent-strong:#00293a;--accent-soft:#e5f5f8;--blue:#004c6a;--cyan:#59c2d8;--coral:#ef6b51;--coral-soft:#ffbeac;--danger:#b42318;--danger-soft:#fff0ee;--warning:#a04731;--warning-soft:#fff2ed;--shadow:0 18px 45px #00384d21}*{box-sizing:border-box}html,body{min-height:100%}body{background:var(--bg);color:var(--ink);margin:0;font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif}button,input,textarea{font:inherit}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.5}.login-shell{justify-content:center;align-items:center;min-height:100vh;padding:24px;display:flex}.login-panel{background:var(--panel);border:1px solid var(--line);box-shadow:var(--shadow);border-radius:8px;gap:18px;width:100%;max-width:380px;padding:28px;display:grid}.login-mark{background:var(--accent-soft);border:1px solid var(--line-strong);color:var(--blue);border-radius:8px;justify-content:center;align-items:center;width:42px;height:42px;display:flex}h1,h2,p{margin:0}.login-panel h1{font-size:28px;font-weight:680}label{color:var(--muted);gap:7px;font-size:13px;font-weight:620;display:grid}input,textarea{border:1px solid var(--line-strong);color:var(--ink);background:#fff;border-radius:6px;outline:none;width:100%;padding:10px 11px}textarea{resize:vertical;min-height:42px}input:focus,textarea:focus,.ProseMirror-focused{border-color:var(--cyan);box-shadow:0 0 0 3px #59c2d833}.primary-button,.ghost-button,.icon-button{border-radius:6px;justify-content:center;align-items:center;gap:8px;display:inline-flex}.primary-button{background:var(--coral);border:1px solid var(--coral);color:#fff;white-space:nowrap;flex:none;min-height:42px;padding:0 14px;font-weight:680}.primary-button:hover{background:#d85740}.primary-button.compact,.ghost-button{min-height:36px}.ghost-button{border:1px solid var(--line-strong);color:var(--ink);background:#fff;padding:0 12px}.icon-button{border:1px solid var(--line-strong);color:var(--ink);background:#fff;width:34px;height:34px;padding:0}.icon-button:hover,.ghost-button:hover{border-color:var(--cyan);color:var(--blue)}.icon-button.danger:hover{background:var(--danger-soft);border-color:var(--danger);color:var(--danger)}.form-error,.app-error{background:var(--danger-soft);color:var(--danger);border:1px solid #ffc8c2;border-radius:6px;padding:10px 12px;font-size:14px}.app-shell{grid-template-rows:max-content max-content 1fr;gap:10px;min-width:0;min-height:100vh;padding:18px;display:grid}.topbar,.table-header{justify-content:space-between;align-items:center;gap:16px;min-width:0;display:flex}.topbar{min-height:72px;padding:10px 0}.topbar h1{font-size:24px;font-weight:760}.topbar p,.table-header p,.dialog-header p{color:var(--muted);margin-top:3px;font-size:13px}.topbar-actions,.table-actions,.row-actions,.dialog-footer{align-items:center;gap:8px;display:flex}.table-header-right{grid-template-columns:minmax(220px,420px) max-content;justify-content:end;align-items:center;gap:10px;width:min(720px,62%);min-width:0;display:grid}.session-pill,.dirty-pill{border-radius:999px;padding:7px 10px;font-size:13px;font-weight:680}.session-pill{color:var(--ink);background:#00384d0d}.dirty-pill{background:var(--warning-soft);color:var(--warning)}.table-header{background:var(--panel);border:1px solid var(--line);border-radius:8px;min-height:44px;padding:8px 10px}.table-header h2,.dialog-header h2{font-size:16px}.table-header p{margin-top:1px;line-height:1.2}.table-search{border:1px solid var(--line);color:var(--muted);background:#fff;border-radius:6px;grid-template-columns:max-content minmax(0,1fr) max-content;align-items:center;gap:8px;width:100%;min-width:0;min-height:34px;padding:3px 9px;display:grid}.table-search input{border-color:#0000;min-height:26px;padding:5px 4px}.search-clear{color:var(--muted);background:0 0;border:0;border-radius:6px;justify-content:center;align-items:center;width:28px;height:28px;padding:0;display:flex}.search-clear:hover{background:var(--accent-soft);color:var(--ink)}.sheet-wrap{background:var(--panel);border:1px solid var(--line);border-radius:8px;min-width:0;min-height:480px;overflow:auto}.sheet-table{border-collapse:separate;border-spacing:0;table-layout:fixed}.sheet-table th{border-bottom:1px solid var(--line-strong);border-right:1px solid var(--line);color:var(--ink);text-align:left;-webkit-user-select:none;user-select:none;z-index:1;background:#e5f5f8;height:38px;padding:0 10px;font-size:12px;font-weight:760;position:sticky;top:0}.column-sort-button{color:inherit;font:inherit;font-weight:inherit;text-align:left;background:0 0;border:0;justify-content:flex-start;align-items:center;gap:6px;width:100%;height:100%;margin:0;padding:0 12px 0 0;display:flex}.column-sort-button span{text-overflow:ellipsis;white-space:nowrap;display:block;overflow:hidden}.column-sort-button svg{color:var(--coral);flex:none}.column-resizer{cursor:col-resize;z-index:2;width:8px;position:absolute;top:0;bottom:0;right:-4px}.column-resizer:after{content:"";background:0 0;width:2px;height:100%;margin-left:3px;display:block}.column-resizer:hover:after,.column-resizer:active:after{background:var(--cyan)}.sheet-table td{border-bottom:1px solid var(--line);border-right:1px solid var(--line);vertical-align:top;min-height:72px;padding:8px}.readonly-cell{color:var(--blue);font-weight:760;padding-top:16px!important}.sheet-input,.sheet-textarea{border-color:#0000;min-height:40px;padding:8px}.sheet-textarea{resize:none;min-height:56px;line-height:1.35;overflow:hidden}.content-open{color:var(--ink);text-align:left;background:#fff;border:1px solid #0000;border-radius:6px;justify-content:space-between;align-items:center;gap:10px;width:100%;height:56px;padding:8px;line-height:1.35;display:flex}.content-open span{color:var(--muted);line-clamp:2;-webkit-line-clamp:2;-webkit-box-orient:vertical;display:-webkit-box;overflow:hidden}.content-open:hover{background:var(--accent-soft);border-color:var(--cyan);color:var(--blue)}.action-column{width:100px}.empty-row{color:var(--muted);text-align:center;vertical-align:middle!important;height:180px!important}.dialog-backdrop{z-index:20;background:#00384d6b;justify-content:center;align-items:center;padding:20px;display:flex;position:fixed;inset:0}.editor-dialog{background:var(--panel);box-shadow:var(--shadow);border-radius:8px;gap:14px;width:min(1100px,100%);max-width:1100px;max-height:calc(100vh - 40px);padding:18px;display:grid;overflow:auto}.dialog-header{border-bottom:1px solid var(--line);justify-content:space-between;align-items:center;padding-bottom:12px;display:flex}.dialog-search{border:1px solid var(--line);color:var(--muted);background:#fff;border-radius:6px;grid-template-columns:max-content minmax(0,1fr) max-content max-content max-content;align-items:center;gap:8px;min-height:38px;padding:4px 9px;display:grid}.dialog-search input{border-color:#0000;min-height:28px;padding:5px 4px}.dialog-search-count{color:var(--muted);white-space:nowrap;font-size:12px}.dialog-search-navigation{align-items:center;gap:3px;display:flex}.compact-icon{width:26px;height:26px}.record-fields{grid-template-columns:minmax(180px,280px) minmax(260px,1fr);gap:12px;display:grid}.notes-field textarea{min-height:80px}.markdown-editor{border:1px solid var(--line-strong);border-radius:8px;overflow:hidden}.editor-toolbar{border-bottom:1px solid var(--line);background:#e5f5f8;flex-wrap:wrap;align-items:center;gap:6px;padding:8px;display:flex}.toolbar-divider{background:var(--line-strong);width:1px;height:24px;margin:0 2px}.editor-surface{background:#fff}.editor-surface .ProseMirror{border:1px solid #0000;outline:none;min-height:380px;padding:22px 26px}.editor-surface .ProseMirror p{margin:0 0 14px;line-height:1.65}.editor-surface .ProseMirror h1,.editor-surface .ProseMirror h2,.editor-surface .ProseMirror h3{margin:22px 0 12px;line-height:1.2}.editor-surface .ProseMirror h1{font-size:30px}.editor-surface .ProseMirror h2{font-size:24px}.editor-surface .ProseMirror h3{font-size:19px}.editor-surface .ProseMirror ul,.editor-surface .ProseMirror ol{margin:0 0 14px;padding-left:28px}.editor-surface .ProseMirror blockquote{border-left:3px solid var(--coral);color:var(--blue);margin:18px 0;padding-left:14px}.editor-surface .ProseMirror .tableWrapper{margin:18px 0;overflow-x:auto}.editor-surface .ProseMirror table{border-collapse:collapse;table-layout:fixed;width:100%;min-width:520px;font-size:14px;line-height:1.45}.editor-surface .ProseMirror th,.editor-surface .ProseMirror td{border:1px solid var(--line-strong);vertical-align:top;min-width:120px;padding:10px 12px;position:relative}.editor-surface .ProseMirror th{color:var(--ink);background:#e5f5f8;font-weight:760}.editor-surface .ProseMirror td{background:#fff}.editor-surface .ProseMirror th p,.editor-surface .ProseMirror td p{margin:0}.editor-surface .ProseMirror .selectedCell:after{content:"";pointer-events:none;z-index:2;background:#59c2d833;position:absolute;inset:0}.editor-surface .ProseMirror .column-resize-handle{background:var(--cyan);pointer-events:none;width:4px;position:absolute;top:0;bottom:-1px;right:-2px}.editor-surface .ProseMirror .search-highlight{color:inherit;background:#ffe794;border-radius:3px;padding:1px 0;box-shadow:0 0 0 1px #e4b52547}.editor-surface .ProseMirror .search-highlight-active{background:#ffbd59;box-shadow:0 0 0 2px #e5534480}.editor-surface .ProseMirror p.is-editor-empty:first-child:before{color:#8aaebb;content:attr(data-placeholder);float:left;pointer-events:none;height:0}.dialog-footer{border-top:1px solid var(--line);justify-content:flex-end;padding-top:12px}@media (max-width:780px){.app-shell{padding:12px}.topbar,.table-header,.record-fields{grid-template-columns:1fr;align-items:stretch;display:grid}.topbar-actions,.table-actions{justify-content:space-between}.table-header-right{grid-template-columns:1fr;width:100%}.dialog-search{grid-template-columns:max-content minmax(0,1fr) max-content}.dialog-search-count{grid-column:2/3}.dialog-search-navigation{grid-column:3/4}.editor-dialog{max-height:calc(100vh - 20px);padding:14px}.editor-surface .ProseMirror{min-height:320px;padding:16px}}
