:root{color-scheme:light;font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,sans-serif;color:#1f2933;background:#eef2f5}*{box-sizing:border-box}body{margin:0;overflow:hidden}.app-error{min-height:100vh;display:grid;place-items:center;padding:24px;color:#7f1d1d;background:#f8fafc;font-size:18px;font-weight:600;text-align:center}button,input,select,textarea{font:inherit}button{border:1px solid #ccd4dd;background:#fff;color:#1f2933;border-radius:7px;min-height:38px;padding:0 12px;display:inline-flex;align-items:center;justify-content:center;gap:8px;cursor:pointer;transition:background .14s ease,border-color .14s ease,color .14s ease,box-shadow .14s ease}button:hover{border-color:#8ba0b4;box-shadow:0 1px 2px #0f172a14}button.active{background:#14213d;color:#fff;border-color:#14213d}button.primary{background:#1864ab;border-color:#1864ab;color:#fff}button.success{background:#2b8a3e;border-color:#2b8a3e;color:#fff}button.danger{background:#c92a2a;border-color:#c92a2a;color:#fff}button:disabled{cursor:not-allowed;opacity:.55}input,select,textarea{width:100%;border:1px solid #ccd4dd;border-radius:7px;background:#fff;min-height:38px;padding:8px 10px;color:#1f2933}input:focus,select:focus,textarea:focus{outline:none;border-color:#6b8fb3;box-shadow:0 0 0 3px #1864ab1f}textarea{min-height:88px;resize:vertical}a{color:#1864ab;display:inline-flex;gap:6px;align-items:center}.login-page{min-height:100vh;display:grid;place-items:center;padding:24px;background:#e8edf2}.login-panel{width:min(420px,100%);background:#fff;border:1px solid #d8e0e8;border-radius:8px;padding:28px;display:grid;gap:18px;box-shadow:0 20px 60px #1f29331f}.login-panel h1,.modal h2,.panel h2,.feed-column h2{margin:0}.eyebrow{margin:0 0 6px;color:#64748b;font-size:13px;text-transform:uppercase;letter-spacing:0}.form-error{margin:0;color:#c92a2a}.app-shell{height:100vh;display:grid;grid-template-rows:auto 1fr;overflow:hidden}.topbar{height:60px;border-bottom:1px solid #d8e0e8;background:#fff;display:flex;align-items:center;justify-content:space-between;padding:0 20px;gap:16px;box-shadow:0 1px #0f172a05}.topbar>div{display:grid;gap:2px}.topbar span{color:#64748b;font-size:13px}.topbar nav{display:flex;gap:6px;align-items:center;flex-wrap:wrap;justify-content:flex-end}.topbar nav button{min-height:34px;padding:0 10px;border-color:transparent;background:transparent}.topbar nav button:hover{background:#f4f7fa;border-color:#d8e0e8;box-shadow:none}.topbar nav button.active{background:#14213d;border-color:#14213d;color:#fff;box-shadow:0 1px 2px #0f172a29}.topbar nav button.active svg{color:#fff}.workspace{height:calc(100vh - 60px);padding:14px 16px 16px;display:grid;grid-template-rows:auto minmax(0,1fr);gap:16px;min-height:0;overflow:hidden}.toolbar{display:flex;justify-content:space-between;gap:12px;align-items:center}.toolbar-group{display:grid;grid-template-columns:minmax(260px,520px) 170px 180px;gap:10px;align-items:center;min-width:0}.searchbox{display:flex;align-items:center;gap:10px;background:#fff;border:1px solid #ccd4dd;border-radius:7px;min-height:42px;padding:0 12px;transition:border-color .12s ease,box-shadow .12s ease}.searchbox:focus-within{border-color:#6b8fb3;box-shadow:0 0 0 3px #1864ab1f}.searchbox input{border:0;box-shadow:none;min-height:40px;padding:8px 0;caret-color:#1864ab;cursor:text}.searchbox input:focus{border:0;box-shadow:none}.searchbox input::selection{background:transparent}.datebox{position:relative;display:grid;grid-template-columns:minmax(0,1fr);align-items:center;gap:4px;background:#fff;border:1px solid #ccd4dd;border-radius:7px;min-height:42px;padding:0;transition:border-color .12s ease,box-shadow .12s ease}.datebox.has-date{grid-template-columns:minmax(0,1fr) 30px;padding-right:5px}.datebox:focus-within{border-color:#6b8fb3;box-shadow:0 0 0 3px #1864ab1f}.date-trigger{min-width:0;min-height:40px;width:100%;display:flex;align-items:center;justify-content:flex-start;gap:8px;padding:0 12px;border:0;border-radius:6px;background:transparent;color:#64748b;cursor:pointer}.date-trigger:hover{background:#f8fafc;border-color:transparent;box-shadow:none}.datebox.has-date .date-trigger{color:#1f2933}.date-trigger span{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.date-native-input{position:absolute;left:12px;bottom:2px;width:1px;height:1px;opacity:0;pointer-events:none;border:0;box-shadow:none;min-height:0;padding:0}.date-native-input:focus{border:0;box-shadow:none}.clear-date-button{width:30px;min-height:28px;height:30px;padding:0;border:1px solid transparent;background:#eef2f5;color:#4a5a6a;border-radius:6px}.clear-date-button:hover{background:#e2e8f0;border-color:#cbd5e1}.refresh-button{min-width:118px}.refresh-panel{display:flex;align-items:center;justify-content:flex-end;gap:10px;min-width:0}.collection-status{min-width:0;max-width:300px;display:grid;gap:2px;text-align:right;color:#64748b;font-size:12px;line-height:1.25}.collection-status span,.collection-status strong{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.collection-status strong{color:#2b6f3e;font-size:13px}.collection-status.has-errors strong{color:#a61e1e}.spin{animation:spin .8s linear infinite}@keyframes spin{to{transform:rotate(360deg)}}.snackbar{position:fixed;left:50%;bottom:24px;transform:translate(-50%);z-index:20;min-width:min(420px,calc(100vw - 32px));max-width:calc(100vw - 32px);background:#17212b;color:#fff;border-radius:8px;padding:12px 16px;box-shadow:0 12px 36px #0f172a42;font-size:14px;text-align:center;animation:snackbar-in .16s ease-out}@keyframes snackbar-in{0%{opacity:0;transform:translate(-50%,8px)}to{opacity:1;transform:translate(-50%)}}.segmented{display:inline-grid;grid-auto-flow:column;background:#eef2f5;border:1px solid #ccd4dd;border-radius:8px;padding:2px;overflow:hidden}.segmented button{border:0;border-radius:6px;background:transparent;min-width:104px}.segmented button.active{background:#fff;color:#14213d;box-shadow:0 1px 2px #0f172a1a}.tab-badge{min-width:20px;height:20px;border-radius:999px;padding:0 6px;display:inline-flex;align-items:center;justify-content:center;background:#fff4e6;color:#ad5f00;font-size:12px;font-weight:700;font-variant-numeric:tabular-nums}.segmented button.active .tab-badge{background:#ffe8cc}.segmented.compact button{min-width:116px;min-height:34px}.board{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px;min-height:0;height:100%}.feed-column{min-width:0;background:#fff;border:1px solid #d8e0e8;border-radius:8px;height:100%;min-height:0;display:grid;grid-template-rows:auto minmax(0,1fr) auto;overflow:visible;box-shadow:0 1px 2px #0f172a0a}.feed-column>header{min-height:58px;padding:0 12px 0 14px;border-bottom:1px solid #e6ebf0;display:flex;align-items:center;justify-content:space-between;gap:12px}.feed-title{display:flex;align-items:baseline;gap:10px;min-width:0}.feed-title h2{font-size:17px;line-height:1.2}.feed-title span{color:#5b6b7c;background:#eef2f5;border-radius:999px;padding:2px 8px;font-size:12px;font-weight:600}.post-list{min-width:0;padding:12px;display:flex;flex-direction:column;gap:10px;overflow:auto;min-height:0;scrollbar-gutter:stable;background:#fbfcfd}.feed-pagination{min-height:48px;padding:6px 12px;border-top:1px solid #e6ebf0;display:grid;grid-template-columns:38px minmax(0,1fr) 38px;align-items:center;gap:8px;color:#64748b;font-size:13px}.feed-pagination span{min-width:0;text-align:center;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.post-card{width:100%;min-width:0;max-width:100%;height:auto;min-height:0;flex:0 0 auto;overflow:visible;padding:12px 13px;display:flex;flex-direction:column;gap:9px;text-align:left;align-items:stretch;background:#fff;border:1px solid #dfe6ed;border-radius:7px;border-color:#dfe6ed;color:#1f2933;cursor:pointer;box-shadow:0 1px 1px #0f172a08;transition:background .14s ease,border-color .14s ease,box-shadow .14s ease}.post-card:hover{border-color:#b6c5d4;box-shadow:0 2px 6px #0f172a14}.post-card:focus-visible{outline:2px solid #1864ab;outline-offset:2px}.post-card.hot-card{background:#fff8f6;border-color:#ffd0c7}.post-card.processed{opacity:1;background:#fff}.post-card h3{width:100%;min-width:0;margin:0;font-size:15px;line-height:1.25;color:#17212b;overflow-wrap:anywhere;display:block}.post-card p{width:100%;min-width:0;margin:0;color:#465666;line-height:1.35;overflow-wrap:anywhere;display:block}.post-meta{width:100%;min-width:0;max-width:100%;display:grid;grid-template-columns:auto minmax(56px,1fr) minmax(126px,auto);align-items:center;gap:7px;color:#64748b;font-size:12px;line-height:1.25}.post-meta time,.missing-date{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;text-align:right;justify-self:end;color:#5b6b7c;font-variant-numeric:tabular-nums}.missing-date{color:#8a5a12;font-variant-numeric:normal}.source-name{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.source-badge{max-width:58px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;border-radius:5px;padding:2px 5px;font-size:10px;font-weight:700;line-height:1.2;letter-spacing:0}.source-badge.telegram{background:#e7f5ff;color:#0b5f8a}.source-badge.max{background:#e6fcf5;color:#087f5b}.source-badge.web{background:#f1f3f5;color:#495057}.source-badge.manual{background:#fff4e6;color:#ad5f00}.snippet{border-left:3px solid #f76707;padding-left:9px;background:linear-gradient(90deg,rgba(255,244,230,.9),transparent);word-break:break-word}.keyword-highlight{background:#fff4d6;color:#2f3742;border-radius:4px;padding:0 2px;font-weight:650;box-shadow:inset 0 -1px #e6b450}.chips{width:100%;min-width:0;display:flex;flex-wrap:wrap;gap:6px;overflow:visible}.chips span{max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;background:#fff8d6;border:1px solid #ffec99;border-radius:999px;padding:2px 8px;font-size:12px}.empty-state{min-height:180px;border:1px dashed #cad5df;border-radius:8px;display:grid;place-items:center;align-content:center;gap:6px;color:#64748b;background:#fff;text-align:center;padding:20px}.empty-state span{color:#344454;font-weight:700}.empty-state p{margin:0}.processed-result{min-width:0;max-width:100%;display:flex;align-items:flex-start;gap:6px;border-radius:7px;padding:8px 9px;font-size:13px;line-height:1.3}.processed-result span{min-width:0;overflow-wrap:anywhere;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}.processed-result.rejected{background:#fff5f5;color:#a61e1e;border:1px solid #ffc9c9}.processed-result.sent{background:#ebfbee;color:#2b6f3e;border:1px solid #b2f2bb}.modal-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;background:#0f172a6b;display:grid;place-items:center;padding:20px;z-index:10}.modal{width:min(760px,100%);max-height:calc(100vh - 40px);background:#fff;border-radius:8px;display:grid;grid-template-rows:auto minmax(0,1fr) auto;overflow:hidden;box-shadow:0 22px 80px #0f172a3d}.modal>header{padding:18px;display:flex;justify-content:space-between;gap:16px;border-bottom:1px solid #e6ebf0}.icon-only{width:38px;padding:0}.modal-body{padding:18px;overflow:auto;display:grid;gap:14px;line-height:1.55}.modal-body p{margin:0;white-space:pre-wrap}.modal footer{padding:16px 18px;border-top:1px solid #e6ebf0}.actions{display:flex;gap:10px;justify-content:flex-end;flex-wrap:wrap}.action-form{display:grid;gap:12px}.admin-grid,.analytics{height:calc(100vh - 60px);padding:16px;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;overflow:auto;align-content:start}.panel-wide{grid-column:1 / -1}.panel{background:#fff;border:1px solid #d8e0e8;border-radius:8px;padding:16px;display:grid;gap:14px;align-content:start}.panel form{display:grid;gap:10px}.simple-list{list-style:none;margin:0;padding:0;display:grid;gap:8px}.simple-list li{border:1px solid #e6ebf0;border-radius:7px;padding:10px;background:#f9fbfc}.metric-grid{grid-column:1 / -1;display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}.metric{background:#fff;border:1px solid #d8e0e8;border-radius:8px;padding:14px;display:grid;gap:8px}.metric span{color:#64748b;font-size:13px}.metric strong{font-size:28px}.metric p,.panel-note{margin:0;color:#64748b;font-size:13px;line-height:1.35}.recommendations{margin:0;padding:0;list-style:none;display:grid;gap:8px}.recommendations li{border:1px solid #cfe2ff;background:#f0f7ff;color:#17456f;border-radius:7px;padding:10px 12px}.reason-list{list-style:none;margin:0;padding:0;display:grid;gap:8px}.reason-list li{display:flex;justify-content:space-between;gap:12px;align-items:center;background:#fff8f6;border:1px solid #ffd0c7;border-radius:7px;padding:9px 10px}.analytics-table{display:grid;border:1px solid #e0e7ef;border-radius:8px;overflow:hidden}.analytics-row{display:grid;grid-template-columns:minmax(0,1fr) 90px 170px;gap:10px;align-items:center;padding:10px 12px;background:#fff;border-top:1px solid #e8edf2}.analytics-row:first-child{border-top:0}.analytics-head{background:#f5f8fb;color:#64748b;font-size:12px;font-weight:700}.source-table .analytics-row{grid-template-columns:minmax(180px,1fr) repeat(5,86px) 100px}.keyword-status{width:fit-content;border-radius:999px;padding:4px 8px;font-size:12px;font-weight:700}.keyword-status.new{background:#fff4e6;color:#ad5f00}.keyword-status.known{background:#ebfbee;color:#2b6f3e}.analytics-post-list{display:grid;gap:8px}.analytics-post{display:grid;gap:6px;color:inherit;text-decoration:none;border:1px solid #e0e7ef;border-radius:8px;padding:10px 11px;background:#fff}.analytics-post:hover{border-color:#b6c5d4;box-shadow:0 1px 3px #0f172a14}.analytics-post>div{display:flex;gap:8px;align-items:center;color:#64748b;font-size:12px}.analytics-post strong{color:#17212b;line-height:1.25}.analytics-post p{margin:0;color:#4a5a6a;line-height:1.35}.empty-inline{border:1px dashed #cad5df;border-radius:8px;padding:14px;color:#64748b;background:#fbfcfd}@media (max-width: 980px){body{overflow:auto}.board,.admin-grid,.analytics,.metric-grid{grid-template-columns:1fr}.app-shell{min-height:100vh;height:auto;overflow:visible}.workspace,.admin-grid,.analytics{height:auto;min-height:calc(100vh - 64px);overflow:visible}.toolbar{align-items:stretch;flex-direction:column}.refresh-panel{justify-content:space-between}.collection-status{text-align:left}.toolbar-group{grid-template-columns:1fr}.board{height:auto}.feed-column{min-height:520px}.panel-wide{grid-column:auto}.analytics-row,.source-table .analytics-row{grid-template-columns:1fr}.topbar{height:auto;min-height:64px;align-items:flex-start;padding:12px;flex-direction:column}.topbar nav{justify-content:flex-start}}
