/* AIseek css/app — restored from 8864c52 baseline */
body, body * { -webkit-user-select: text !important; user-select: text !important; }
        button, .btn, [role="button"], .status-pill, .drag-handle { -webkit-user-select: none !important; user-select: none !important; }
        :root {
            --bg: #161823;
            --surface: #1a1f2e;
            --text: #f0f4f8;
            --muted: rgba(240,244,248,0.65);
            --muted2: rgba(240,244,248,0.45);
            --stroke: rgba(255,255,255,0.10);
            --primary: #00d4aa;
            --primary-hover: #00e6b8;
            --r-sm: 8px;
            --r-md: 12px;
            --s-1: 8px;
            --s-2: 14px;
            --s-3: 20px;
            --dur: 160ms;
            --good: #4ade80;
            --warn: #fbbf24;
            --bad: #f87171;
        }
        body[data-theme="light"] {
            --bg: #f0f2f5;
            --surface: #ffffff;
            --text: #0f172a;
            --muted: rgba(15,23,42,0.65);
            --muted2: rgba(15,23,42,0.45);
            --stroke: rgba(15,23,42,0.12);
            --primary: #0d9488;
            --primary-hover: #0f766e;
        }
        * { box-sizing: border-box; }
        body { margin: 0; font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,sans-serif; background: var(--bg); color: var(--text); }
        a { color: inherit; text-decoration: none; }
        .topbar { height: 52px; display: flex; align-items: center; justify-content: space-between; padding: 0 20px; background: var(--bg); border-bottom: 1px solid var(--stroke); position: sticky; top: 0; z-index: 20; }
        .topbar .row { flex-wrap: nowrap; gap: 8px; align-items: center; }
        .brand { display: flex; align-items: center; gap: 8px; font-weight: 800; font-size: 14px; }
        .brand .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--primary); }
        .pill { display: inline-flex; align-items: center; gap: var(--s-1); padding: 6px 12px; border-radius: var(--r-sm); background: var(--bg); border: 1px solid var(--stroke); font-size: 13px; transition: all var(--dur) ease; }
        .pill:hover { border-color: var(--primary); color: var(--primary); }
        .btn { display: inline-flex; align-items: center; gap: var(--s-1); border: 1px solid var(--stroke); cursor: pointer; border-radius: var(--r-sm); height: 36px; padding: 0 14px; background: var(--bg); color: var(--text); font-size: 14px; font-weight: 600; transition: all var(--dur) ease; }
        .btn:hover { border-color: var(--primary); color: var(--primary); }
        .btn-primary { background: var(--primary); border-color: var(--primary); color: #0a0e14; }
        .btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); }
        .btn-danger { border-color: rgba(248,113,113,0.5); color: var(--bad); }
        .btn-small { height: 32px; padding: 0 12px; font-size: 13px; }
        .layout { padding: var(--s-2); min-height: calc(100vh - 54px); }
        .workspace-board { display: flex; flex-wrap: wrap; gap: var(--s-2); align-items: flex-start; align-content: flex-start; }
        .ws-module { width: 620px; min-width: 560px; max-width: 760px; background: var(--surface); border: 1px solid var(--stroke); border-radius: var(--r-md); overflow: hidden; display: flex; flex-direction: column; min-height: 380px; cursor: move; transition: box-shadow var(--dur) ease; }
        .ws-module:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.2); }
        .ws-module.dragging { opacity: 0.7; cursor: grabbing; }
        .ws-module .module-h { padding: 0 16px; height: 44px; display: flex; align-items: center; justify-content: space-between; background: var(--bg); border-bottom: 1px solid var(--stroke); cursor: grab; }
        .ws-module .module-h:active { cursor: grabbing; }
        .ws-module .module-h .title { font-size: 15px; font-weight: 700; color: var(--text); }
        .ws-module .module-b { padding: var(--s-2); overflow: visible; flex: 1; min-height: 0; }
        .ws-module .module-b::-webkit-scrollbar { width: 6px; }
        .ws-module .module-b::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.15); border-radius: 3px; }
        .field { margin-bottom: var(--s-2); }
        .field label { display: block; font-size: 12px; font-weight: 600; color: var(--muted); margin-bottom: 4px; }
        .input, .select, .textarea { width: 100%; background: var(--bg); border: 1px solid var(--stroke); color: var(--text); border-radius: var(--r-sm); padding: 11px 14px; font-size: 14px; outline: none; transition: border-color var(--dur) ease; }
        .input:focus, .select:focus, .textarea:focus { border-color: var(--primary); }
        .input::placeholder, .textarea::placeholder { color: var(--muted2); }
        .select { cursor: pointer; }
        .textarea { min-height: 120px; resize: vertical; }
        .row { display: flex; gap: var(--s-1); align-items: center; flex-wrap: wrap; }
        .grow { flex: 1; min-width: 0; }
        .form-grid-two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
        .form-grid-three { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; }
        .inline-ctl { display: flex; align-items: center; gap: 8px; }
        .inline-ctl .name { font-size: 12px; color: var(--muted); min-width: 56px; }
        .inline-ctl .select { flex: 1; min-width: 0; }
        .section-label { font-size: 12px; font-weight: 700; color: var(--primary); margin: var(--s-2) 0 var(--s-1); padding-bottom: 6px; border-bottom: 1px solid var(--stroke); }
        .section-toggle { display: flex; align-items: center; gap: 8px; cursor: pointer; padding: 8px 0; font-size: 13px; color: var(--muted); }
        .section-toggle:hover { color: var(--text); }
        .section-toggle i { transition: transform var(--dur) ease; }
        .section-toggle.collapsed i { transform: rotate(-90deg); }
        .section-optional { margin-top: var(--s-1); }
        .section-optional.collapsed { display: none; }
        .badge { font-size: 11px; padding: 3px 8px; border-radius: 999px; border: 1px solid var(--stroke); color: var(--muted); }
        .badge.good { color: var(--good); }
        .badge.warn { color: var(--warn); }
        .badge.bad { color: var(--bad); }
        .status-pill { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); border: 1px solid var(--stroke); border-radius: 999px; height: 24px; padding: 0 10px; }
        .status-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
        .status-pill.good { color: var(--good); }
        .status-pill.warn { color: var(--warn); }
        .status-pill.bad { color: var(--bad); }
        .tabs { display: flex; gap: 4px; }
        .tab { cursor: pointer; padding: 7px 12px; border-radius: var(--r-sm); border: 1px solid var(--stroke); color: var(--muted); font-size: 13px; transition: all var(--dur) ease; }
        .tab:hover { color: var(--text); }
        .tab.active { background: var(--primary); border-color: var(--primary); color: #0a0e14; }
        body[data-theme="light"] .tab.active { color: #fff; }
        .list { display: flex; flex-direction: column; gap: 10px; }
        .card { padding: var(--s-2); border-radius: var(--r-sm); border: 1px solid transparent; cursor: pointer; transition: border-color var(--dur) ease; }
        .card.active { border: 1px solid var(--primary); }
        .kv { display: grid; grid-template-columns: 80px 1fr; gap: 6px 10px; font-size: 12px; }
        .kv .k { color: var(--muted2); }
        .kv .v { color: var(--text); word-break: break-all; }
        .msg { padding: 10px; border-radius: var(--r-sm); border: 1px solid var(--stroke); margin-bottom: 8px; }
        .msg.user { border-color: rgba(0,212,170,0.3); }
        .msg .r { font-size: 11px; color: var(--muted2); margin-bottom: 4px; }
        .msg .c { font-size: 14px; line-height: 1.6; white-space: pre-wrap; }
        .chat-log { max-height: 320px; overflow-y: auto; margin-bottom: 10px; }
        .chat-input { display: flex; gap: 10px; }
        .chat-input textarea { flex: 1; min-height: 80px; resize: vertical; }
        #mod-works .module-b { max-height: 480px; overflow-y: auto; }
        #mod-works .module-b.has-more { overflow-y: scroll; }
        .video { width: 100%; aspect-ratio: 16/9; border-radius: var(--r-sm); background: #000; object-fit: contain; }
        .toast { position: fixed; right: 16px; bottom: 16px; background: rgba(0,0,0,0.8); color: #fff; border-radius: var(--r-sm); padding: 10px 14px; max-width: 360px; display: none; z-index: 99; }
        .toast.show { display: block; }
        #mod-create { min-height: 420px; }
        #btnLoadMorePosts { display: none !important; }
