:root{font-family:system-ui,Avenir,Helvetica,Arial,sans-serif;line-height:1.5;font-weight:400;color:#ffffffde;background-color:#242424;font-synthesis:none;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}a{font-weight:500;color:#646cff;text-decoration:inherit}a:hover{color:#535bf2}body{margin:0;min-width:320px;min-height:100vh}#root{width:100%}h1{font-size:3.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:#1a1a1a;cursor:pointer;transition:border-color .25s}button:hover{border-color:#646cff}button:focus,button:focus-visible{outline:none}[data-theme=light]{color:#213547;background-color:#fff}[data-theme=light] a:hover{color:#747bff}[data-theme=light] button{background-color:#f0f0f0;color:#213547}.app{max-width:1200px;margin:0 auto;padding:1.5rem}.app--with-sidebar{max-width:1440px}h1{text-align:center;font-size:1.8em}.app-body{display:flex}.app-content{flex:1;min-width:0}.sidebar{width:220px;flex-shrink:0;background:#1a1a1a;border-right:1px solid #333;padding:.75rem 0;align-self:stretch;min-height:calc(100vh - 120px);transition:width .2s ease}.sidebar.collapsed{width:52px}.sidebar-collapse-btn{display:block;width:100%;background:none;border:none;border-bottom:1px solid #333;color:#888;padding:.5em 0;font-size:.85em;cursor:pointer;margin-bottom:.4rem;transition:color .15s}.sidebar-collapse-btn:hover{color:#4361ee}.sidebar-menu-item{display:block;width:100%;text-align:left;background:none;border:none;border-left:3px solid transparent;color:#aaa;padding:.7em 1em;font-size:.9em;cursor:pointer;font-family:inherit;transition:background .15s,color .15s}.sidebar-menu-item:hover{background:#4361ee14;color:#ddd}.sidebar-menu-item.active{background:#4361ee21;border-left:3px solid #4361ee;color:#4361ee;font-weight:600}.sidebar.collapsed .sidebar-menu-item{text-align:center;padding:.7em .3em;font-size:.95em;border-left-width:2px;overflow:hidden;white-space:nowrap}.sidebar-toggle{display:none;background:transparent;border:1px solid #444;color:#aaa;font-size:1.2em;padding:.2em .5em;border-radius:6px;cursor:pointer;line-height:1}.sidebar-toggle:hover{border-color:#646cff;color:#646cff}.sidebar-overlay{display:none}.page-placeholder{display:flex;align-items:center;justify-content:center;min-height:400px;color:#888;font-size:1.2em}.groups-input{display:grid;grid-template-columns:repeat(4,1fr);gap:1rem;margin-bottom:1.5rem}.group-input-card{border:1px solid #333;border-radius:8px;padding:.75rem;background:#1e1e1e}.group-input-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:.5rem}.group-name-input{background:transparent;border:1px solid transparent;color:inherit;font-weight:600;font-size:.9em;padding:.15em .35em;border-radius:4px;width:90px;font-family:inherit}.group-name-input:hover{border-color:#555}.group-name-input:focus{outline:none;border-color:#646cff;background:#2a2a2a}.group-menu-wrap{position:relative}.group-menu-btn{background:transparent;border:1px solid #444;color:#aaa;font-size:1em;padding:.1em .45em;border-radius:4px;cursor:pointer;line-height:1}.group-menu-btn:hover{border-color:#646cff;color:#646cff}.group-dropdown{position:absolute;right:0;top:100%;margin-top:4px;min-width:170px;background:#2a2a2a;border:1px solid #444;border-radius:8px;padding:.35rem 0;z-index:100;box-shadow:0 4px 16px #0006}.dropdown-item{display:block;width:100%;text-align:left;background:none;border:none;color:#ddd;padding:.45em .85em;font-size:.85em;cursor:pointer;border-radius:0}.dropdown-item:hover:not(:disabled){background:#646cff26}.dropdown-item:disabled{color:#555;cursor:default}.dropdown-divider{height:1px;background:#444;margin:.25rem 0}.dropdown-empty{padding:.45em .85em;font-size:.8em;color:#666}.saved-lists-bar{margin-bottom:1.5rem}.manage-lists-btn{background:transparent;border:1px solid #444;color:#aaa;padding:.4em 1em;font-size:.85em;border-radius:6px;cursor:pointer}.manage-lists-btn:hover{border-color:#646cff;color:#646cff}.saved-lists-grid{display:flex;flex-wrap:wrap;gap:.5rem;margin-top:.75rem}.saved-list-chip{display:flex;align-items:center;gap:.4em;background:#2a2a2a;border:1px solid #444;border-radius:6px;padding:.35em .6em;font-size:.82em}.chip-name{color:#ddd}.chip-count{color:#888;font-size:.9em}.chip-delete{background:none;border:none;color:#666;cursor:pointer;padding:0 .2em;font-size:.9em;line-height:1}.chip-delete:hover{color:#ff6b6b}.modal-overlay{position:fixed;inset:0;background:#0009;display:flex;align-items:center;justify-content:center;z-index:200}.modal{background:#2a2a2a;border:1px solid #444;border-radius:12px;padding:1.5rem;min-width:320px;max-width:90vw}.modal h3{margin:0 0 .5rem;font-size:1.1em}.modal-desc{color:#888;font-size:.85em;margin:0 0 1rem}.modal-input{width:100%;box-sizing:border-box;padding:.55em .75em;border-radius:6px;border:1px solid #555;background:#1a1a1a;color:inherit;font-size:.95em;font-family:inherit;margin-bottom:1rem}.modal-input:focus{outline:none;border-color:#646cff}.modal-actions{display:flex;justify-content:flex-end;gap:.5rem}.modal-cancel,.modal-confirm{padding:.45em 1.2em;font-size:.9em;border-radius:6px;border:none;cursor:pointer;font-weight:500}.modal-cancel{background:#444;color:#ccc}.modal-cancel:hover{background:#555}.modal-confirm{background:#4361ee;color:#fff}.modal-confirm:hover:not(:disabled){background:#3a56d4}.modal-confirm:disabled{opacity:.4;cursor:default}.group-input-card textarea{width:100%;box-sizing:border-box;padding:.5em;border-radius:6px;border:1px solid #444;background:#2a2a2a;color:inherit;font-family:inherit;font-size:.85em;resize:vertical;line-height:1.5}.group-input-card textarea:focus{outline:none;border-color:#646cff}.main-layout{display:grid;grid-template-columns:1fr 340px;gap:1.5rem;align-items:start}.rules-panel{border:1px solid #333;border-radius:10px;padding:1.25rem;background:#1a1a1a}.rules-header{display:flex;justify-content:space-between;align-items:center;flex-wrap:wrap;gap:.75rem;margin-bottom:1rem}.rules-header h2{font-size:1.1em;margin:0}.rules-header-actions{display:flex;gap:.5rem}.select-all-btn,.deselect-all-btn{padding:.45em 1em;font-size:.85em;font-weight:600;border-radius:6px;border:none;cursor:pointer}.select-all-btn{background:#4361ee;color:#fff}.select-all-btn:hover{background:#3a56d4}.deselect-all-btn{background:#e9ecef;color:#333}.deselect-all-btn:hover{background:#ddd}.btn-icon{margin-right:.25em}.rules-section{border:2px dashed #3a3a3a;border-radius:8px;padding:.75rem;margin-bottom:.75rem}.rules-section:last-child{margin-bottom:0}.rules-grid{display:grid;grid-template-columns:repeat(5,1fr);gap:.25rem .5rem}.rule-item{display:flex;align-items:center;gap:.4em;padding:.3em .2em;font-size:.88em;cursor:pointer;white-space:nowrap;border-radius:4px}.rule-item:hover{background:#646cff14}.rule-item input[type=checkbox]{accent-color:#888;width:15px;height:15px;cursor:pointer}.results-panel{border:1px solid #333;border-radius:10px;padding:1.25rem;background:#1a1a1a;position:sticky;top:1rem}.results-title-row{display:flex;justify-content:space-between;align-items:center;margin-bottom:.75rem}.results-title-row h2{font-size:1.1em;margin:0}.clear-btn{padding:.3em .8em;font-size:.8em;border-radius:6px;border:1px solid #555;background:transparent;color:#aaa;cursor:pointer}.clear-btn:hover:not(:disabled){border-color:#ff6b6b;color:#ff6b6b;background:#ff6b6b1a}.clear-btn:disabled{opacity:.4;cursor:default}.space-toggle{display:flex;align-items:center;gap:.5em;font-size:.9em;cursor:pointer;margin-bottom:.75rem}.space-toggle input[type=checkbox]{accent-color:#646cff;width:15px;height:15px;cursor:pointer}.results-box{border:1px solid #333;border-radius:6px;background:#222;min-height:200px;max-height:350px;overflow-y:auto;padding:.75rem;margin-bottom:.75rem}.results-placeholder{color:#666;font-size:.9em;margin:0}.result-line{font-size:.85em;padding:.15em 0;font-family:Courier New,Courier,monospace;word-break:break-all}.results-info{font-size:.85em;color:#888;text-align:right;margin:0 0 1rem}.results-info strong{color:inherit}.combine-btn,.download-btn{width:100%;padding:.75em;font-size:1em;font-weight:600;border:none;border-radius:8px;cursor:pointer;margin-bottom:.5rem}.combine-btn{background:#4361ee;color:#fff}.combine-btn:hover{background:#3a56d4}.download-btn{background:#2ec4b6;color:#fff;margin-bottom:0}.download-btn:hover{background:#26a89c}.app-header{display:flex;align-items:center;margin-bottom:1.5rem}.header-center{flex:1;display:flex;align-items:center;justify-content:center;gap:.4em;min-width:0}.header-logo{height:1.2em;object-fit:contain}.app-header h1{margin:0;text-align:center}.header-actions{display:flex;gap:.4rem;align-items:center;flex-shrink:0}.theme-toggle,.manager-toggle{background:#2a2a2a;border:1px solid #444;color:#ddd;padding:.35em .7em;font-size:1.1em;border-radius:8px;cursor:pointer;line-height:1;transition:background .2s,border-color .2s}.theme-toggle:hover,.manager-toggle:hover{border-color:#646cff;background:#333}.manager-toggle{font-weight:700;font-size:.95em;padding:.4em .65em}.manager-toggle.active{background:#4361ee;border-color:#4361ee;color:#fff}.manager-bar{display:flex;align-items:center;gap:.75rem;flex-wrap:wrap;padding:.6rem 1rem;border:1px solid #4361ee44;border-radius:8px;background:#4361ee11;margin-bottom:1rem}.manager-badge{font-weight:700;font-size:.8em;color:#4361ee;background:#4361ee22;padding:.25em .6em;border-radius:4px}.mgr-action-btn{padding:.35em .8em;font-size:.8em;background:transparent;border:1px solid #555;color:#aaa;border-radius:6px;cursor:pointer}.mgr-action-btn:hover{border-color:#ff6b6b;color:#ff6b6b}.mgr-limit{display:flex;align-items:center;gap:.4em;margin-left:auto;font-size:.82em;color:#aaa}.mgr-limit input{width:80px;padding:.3em .5em;border:1px solid #444;border-radius:4px;background:#2a2a2a;color:inherit;font-size:1em;font-family:inherit}.mgr-limit input:focus{outline:none;border-color:#646cff}.group-csv-btn{background:transparent;border:1px solid #444;color:#aaa;font-size:.72em;padding:.15em .45em;border-radius:4px;cursor:pointer;font-weight:600;line-height:1}.group-csv-btn:hover{border-color:#2ec4b6;color:#2ec4b6}.preset-save-btn{padding:.45em .8em;font-size:.8em;font-weight:600;border-radius:6px;border:1px solid #4361ee;background:transparent;color:#4361ee;cursor:pointer}.preset-save-btn:hover:not(:disabled){background:#4361ee22;border-color:#4361ee}.preset-save-btn:disabled{opacity:.4;cursor:default}.presets-bar{display:flex;flex-wrap:wrap;gap:.4rem;margin-bottom:.75rem}.preset-chip{display:flex;align-items:center;border:1px solid #444;border-radius:6px;overflow:hidden}.preset-load{background:transparent;border:none;color:#ddd;padding:.3em .6em;font-size:.8em;cursor:pointer;border-radius:0}.preset-load:hover{background:#4361ee22}.preset-delete{background:transparent;border:none;border-left:1px solid #444;color:#666;padding:.3em .45em;font-size:.75em;cursor:pointer;border-radius:0}.preset-delete:hover{color:#ff6b6b;background:#ff6b6b1a}.preset-keyword-btn{padding:.45em .8em;font-size:.8em;font-weight:600;border-radius:6px;border:1px solid #2ec4b6;background:transparent;color:#2ec4b6;cursor:pointer}.preset-keyword-btn:hover{background:#2ec4b622;border-color:#2ec4b6}.pk-manager-modal{min-width:400px;max-height:80vh;overflow-y:auto}.pk-manager-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:1rem}.pk-manager-header h3{margin:0}.pk-close-btn{background:transparent;border:1px solid #555;color:#aaa;padding:.3em .7em;font-size:.82em;border-radius:6px;cursor:pointer}.pk-close-btn:hover{border-color:#646cff;color:#646cff}.pk-group-item{border:1px solid #444;border-radius:8px;padding:.75rem;margin-bottom:.6rem}.pk-group-header{display:flex;align-items:center;gap:.5em}.pk-group-name{font-weight:600;font-size:.95em;cursor:pointer;color:#ddd}.pk-group-name:hover{color:#4361ee}.pk-group-count{font-size:.82em;color:#888}.pk-group-actions{margin-left:auto;display:flex;gap:.3em}.pk-edit-btn,.pk-delete-btn{background:none;border:1px solid transparent;color:#888;cursor:pointer;padding:.15em .35em;font-size:.9em;border-radius:4px;line-height:1}.pk-edit-btn:hover{color:#4361ee;border-color:#4361ee44}.pk-delete-btn:hover{color:#ff6b6b;border-color:#ff6b6b44}.pk-rename-input{font-weight:600;font-size:.95em;padding:.2em .4em;border:1px solid #646cff;border-radius:4px;background:#1a1a1a;color:inherit;font-family:inherit;width:160px}.pk-rename-input:focus{outline:none}.pk-edit-area{margin-top:.5rem}.pk-edit-area textarea{width:100%;box-sizing:border-box;padding:.5em;border-radius:6px;border:1px solid #555;background:#1a1a1a;color:inherit;font-family:inherit;font-size:.85em;resize:vertical;line-height:1.5;margin-bottom:.5rem}.pk-edit-area textarea:focus{outline:none;border-color:#646cff}.pk-edit-actions{display:flex;justify-content:flex-end;gap:.5rem}.pk-empty{color:#666;font-size:.85em;text-align:center;padding:1rem 0;margin:0}.pk-add-btn{display:block;width:100%;padding:.6em;font-size:.88em;font-weight:600;border:2px dashed #444;border-radius:8px;background:transparent;color:#888;cursor:pointer;margin-top:.4rem}.pk-add-btn:hover{border-color:#4361ee;color:#4361ee}.pk-add-form{border:2px dashed #4361ee44;border-radius:8px;padding:.75rem;margin-top:.4rem}.pk-add-textarea{width:100%;box-sizing:border-box;padding:.5em;border-radius:6px;border:1px solid #555;background:#1a1a1a;color:inherit;font-family:inherit;font-size:.85em;resize:vertical;line-height:1.5;margin-bottom:.5rem}.pk-add-textarea:focus{outline:none;border-color:#646cff}.dropdown-section-title{padding:.35em .85em;font-size:.72em;color:#888;font-weight:600}.filter-input{width:100%;box-sizing:border-box;padding:.45em .7em;border:1px solid #444;border-radius:6px;background:#2a2a2a;color:inherit;font-size:.85em;font-family:inherit;margin-bottom:.5rem}.filter-input:focus{outline:none;border-color:#646cff}.csv-export-btn{width:100%;padding:.75em;font-size:1em;font-weight:600;border:none;border-radius:8px;cursor:pointer;margin-top:.5rem;background:#e67e22;color:#fff}.csv-export-btn:hover:not(:disabled){background:#cf6d17}.csv-export-btn:disabled{opacity:.4;cursor:default}.history-section{margin-top:1rem;border-top:1px solid #333;padding-top:.75rem}.history-toggle-btn{background:transparent;border:1px solid #444;color:#aaa;padding:.4em .8em;font-size:.82em;border-radius:6px;cursor:pointer;width:100%}.history-toggle-btn:hover{border-color:#646cff;color:#646cff}.history-list{margin-top:.5rem;max-height:250px;overflow-y:auto}.history-empty{font-size:.82em;color:#666;text-align:center;padding:.5em}.history-clear{display:block;width:100%;background:transparent;border:none;color:#ff6b6b;font-size:.78em;padding:.3em;cursor:pointer;text-align:right;border-radius:0;margin-bottom:.3rem}.history-clear:hover{text-decoration:underline}.history-item{border:1px solid #333;border-radius:6px;padding:.5em .6em;margin-bottom:.4rem;font-size:.8em}.history-meta{display:flex;justify-content:space-between;margin-bottom:.25em}.history-time{color:#888;font-size:.9em}.history-count{color:#4361ee;font-weight:600}.history-preview{color:#999;font-size:.9em;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-bottom:.3em}.history-restore{background:transparent;border:1px solid #444;color:#aaa;padding:.2em .6em;font-size:.85em;border-radius:4px;cursor:pointer}.history-restore:hover{border-color:#4361ee;color:#4361ee}.ia-page{max-width:900px;margin:0 auto}.ia-form-panel{background:#1a1a1a;border:1px solid #333;border-radius:10px;padding:1.25rem;margin-bottom:1rem}.ia-form-panel h2{font-size:1.1em;margin:0 0 1rem}.ia-form-grid{display:grid;grid-template-columns:1fr 1fr;gap:.75rem;margin-bottom:1rem}.ia-field{display:flex;flex-direction:column;gap:.3em}.ia-field label{font-size:.82em;color:#aaa;font-weight:600}.ia-field input{padding:.5em .7em;border:1px solid #444;border-radius:6px;background:#2a2a2a;color:inherit;font-family:inherit;font-size:.9em}.ia-field input:focus{outline:none;border-color:#646cff}.ia-generate-btn{width:100%;padding:.75em;font-size:1em;font-weight:600;border:none;border-radius:8px;cursor:pointer;background:#4361ee;color:#fff}.ia-generate-btn:hover:not(:disabled){background:#3a56d4}.ia-generate-btn:disabled{opacity:.6;cursor:default}.ia-chat-panel{background:#1a1a1a;border:1px solid #333;border-radius:10px;padding:1.25rem}.ia-chat-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:.75rem}.ia-chat-header h2{font-size:1.1em;margin:0}.ia-chat-reset{background:transparent;border:1px solid #555;color:#aaa;padding:.3em .7em;font-size:.82em;border-radius:6px;cursor:pointer}.ia-chat-reset:hover{border-color:#ff6b6b;color:#ff6b6b}.ia-messages{max-height:500px;overflow-y:auto;margin-bottom:1rem;display:flex;flex-direction:column;gap:.75rem}.ia-msg{border-radius:10px;padding:.75rem 1rem;position:relative}.ia-msg--user{background:#4361ee22;border:1px solid #4361ee44}.ia-msg--assistant{background:#2a2a2a;border:1px solid #333}.ia-msg-label{font-size:.72em;font-weight:700;text-transform:uppercase;margin-bottom:.4em;color:#888}.ia-msg--user .ia-msg-label{color:#4361ee}.ia-msg-content{font-size:.92em;line-height:1.7}.ia-md-h3{font-size:1.1em;font-weight:700;margin:.8em 0 .4em;color:#e0e0e0}.ia-md-h4{font-size:1em;font-weight:600;margin:.6em 0 .3em;color:#ccc}.ia-md-p{margin:.3em 0;line-height:1.7}.ia-msg--system{background:#333a;border:1px dashed #555;text-align:center}.ia-system-text{margin:0;font-size:.85em;color:#999}.ia-loading-text{margin:0 0 .4em;font-size:.88em;color:#aaa}.ia-loading-dots{display:flex;gap:.3em;padding:.3em 0}.ia-loading-dots span{width:8px;height:8px;border-radius:50%;background:#888;animation:ia-dot-bounce 1.4s infinite ease-in-out both}.ia-loading-dots span:nth-child(1){animation-delay:-.32s}.ia-loading-dots span:nth-child(2){animation-delay:-.16s}@keyframes ia-dot-bounce{0%,80%,to{transform:scale(0);opacity:.5}40%{transform:scale(1);opacity:1}}.ia-chat-input-wrap{display:flex;gap:.5rem;align-items:flex-end}.ia-chat-input{flex:1;padding:.6em .75em;border:1px solid #444;border-radius:8px;background:#2a2a2a;color:inherit;font-family:inherit;font-size:.9em;resize:none;line-height:1.5}.ia-chat-input:focus{outline:none;border-color:#646cff}.ia-send-btn{padding:.6em 1.2em;background:#4361ee;color:#fff;border:none;border-radius:8px;font-size:.9em;font-weight:600;cursor:pointer;white-space:nowrap}.ia-send-btn:hover:not(:disabled){background:#3a56d4}.ia-send-btn:disabled{opacity:.4;cursor:default}.ia-msg-copy{position:absolute;top:.5rem;right:.5rem;background:#333;border:1px solid #555;color:#aaa;padding:.2em .5em;font-size:.72em;border-radius:4px;cursor:pointer;opacity:0;transition:opacity .15s}.ia-msg:hover .ia-msg-copy{opacity:1}.ia-msg-copy:hover{border-color:#4361ee;color:#4361ee}.profile-selector{flex-shrink:0;margin:0 .5rem}.profile-selector select{padding:.35em .7em;border:1px solid #444;border-radius:6px;background:#2a2a2a;color:#ddd;font-size:.82em;font-family:inherit;cursor:pointer;max-width:200px}.profile-selector select:focus{outline:none;border-color:#4361ee}.profile-banner{padding:.5rem 1rem;border-radius:8px;font-size:.85em;margin-bottom:1rem;background:#4361ee11;border:1px solid #4361ee33;color:#aab}.profile-banner strong{color:#4361ee}.profile-banner--warning{background:#ff6b6b11;border-color:#ff6b6b33;color:#cc8;display:flex;align-items:center;gap:.5em}.profile-banner--warning button{background:transparent;border:1px solid #ff6b6b66;color:#ff6b6b;padding:.2em .6em;font-size:.9em;border-radius:4px;cursor:pointer;font-family:inherit}.profile-banner--warning button:hover{background:#ff6b6b22}.pf-page{max-width:900px;margin:0 auto}.pf-header{display:flex;justify-content:space-between;align-items:center;margin-bottom:1rem}.pf-header h2{font-size:1.2em;margin:0}.pf-add-btn{padding:.5em 1em;font-size:.88em;font-weight:600;border:none;border-radius:8px;background:#4361ee;color:#fff;cursor:pointer}.pf-add-btn:hover{background:#3a56d4}.pf-error{background:#ff6b6b22;border:1px solid #ff6b6b44;color:#ff6b6b;padding:.5rem 1rem;border-radius:8px;font-size:.85em;margin-bottom:1rem}.pf-loading{text-align:center;color:#888;padding:2rem;font-size:.95em}.pf-empty{text-align:center;color:#666;padding:3rem 1rem;font-size:.95em;border:2px dashed #333;border-radius:10px}.pf-form-panel{background:#1a1a1a;border:1px solid #333;border-radius:10px;padding:1.25rem;margin-bottom:1rem}.pf-form-panel h3{font-size:1.05em;margin:0 0 1rem}.pf-form-grid{display:grid;grid-template-columns:1fr 1fr;gap:.75rem;margin-bottom:1rem}.pf-field{display:flex;flex-direction:column;gap:.3em}.pf-field label{font-size:.82em;color:#aaa;font-weight:600}.pf-field input,.pf-field select{padding:.5em .7em;border:1px solid #444;border-radius:6px;background:#2a2a2a;color:inherit;font-family:inherit;font-size:.9em}.pf-field input:focus,.pf-field select:focus{outline:none;border-color:#646cff}.pf-form-actions{display:flex;justify-content:flex-end;gap:.5rem}.pf-list{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:.75rem}.pf-card{background:#1a1a1a;border:2px solid #333;border-radius:10px;padding:1rem;cursor:pointer;transition:border-color .15s,background .15s;position:relative}.pf-card:hover{border-color:#4361ee66;background:#1e1e2a}.pf-card--selected{border-color:#4361ee;background:#4361ee11}.pf-card-header{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:.5rem}.pf-card-title{display:flex;flex-direction:column;gap:.2em}.pf-card-title strong{font-size:1em}.pf-card-category{font-size:.82em;color:#888}.pf-card-actions{display:flex;gap:.3em}.pf-edit-btn,.pf-delete-btn{background:none;border:1px solid transparent;color:#888;cursor:pointer;padding:.15em .35em;font-size:.9em;border-radius:4px;line-height:1}.pf-edit-btn:hover{color:#4361ee;border-color:#4361ee44}.pf-delete-btn:hover{color:#ff6b6b;border-color:#ff6b6b44}.pf-card-body{display:flex;flex-wrap:wrap;gap:.4em;margin-bottom:.4em}.pf-card-tag{font-size:.75em;padding:.2em .5em;background:#333;border-radius:4px;color:#aaa}.pf-card-keywords{font-size:.8em;color:#777;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.pf-card-selected-badge{position:absolute;top:.5rem;right:.5rem;background:#4361ee;color:#fff;font-size:.68em;font-weight:700;padding:.2em .5em;border-radius:4px}[data-theme=light] .sidebar{background:#f5f5f5;border-right-color:#ddd}[data-theme=light] .sidebar-menu-item{color:#666}[data-theme=light] .sidebar-menu-item:hover{background:#4361ee0f;color:#333}[data-theme=light] .sidebar-menu-item.active{background:#4361ee1a;border-left-color:#4361ee;color:#4361ee}[data-theme=light] .sidebar-toggle{border-color:#ccc;color:#888}[data-theme=light] .sidebar-toggle:hover{border-color:#646cff;color:#646cff}[data-theme=light] .sidebar-collapse-btn{color:#999;border-bottom-color:#ddd}[data-theme=light] .sidebar-collapse-btn:hover{color:#4361ee}[data-theme=light] .page-placeholder{color:#999}[data-theme=light] .group-input-card{background:#f5f5f5;border-color:#ddd}[data-theme=light] .group-input-card textarea{background:#fff;border-color:#ccc}[data-theme=light] .group-menu-btn{border-color:#ccc;color:#888}[data-theme=light] .rules-panel,[data-theme=light] .results-panel{background:#fff;border-color:#ddd}[data-theme=light] .rules-section{border-color:#ccc}[data-theme=light] .results-box{background:#fafafa;border-color:#ddd}[data-theme=light] .deselect-all-btn{background:#e9ecef;color:#333}[data-theme=light] .group-dropdown{background:#fff;border-color:#ddd;box-shadow:0 4px 16px #0000001f}[data-theme=light] .dropdown-item{color:#333}[data-theme=light] .dropdown-divider{background:#eee}[data-theme=light] .saved-list-chip{background:#f0f0f0;border-color:#ddd}[data-theme=light] .chip-name{color:#333}[data-theme=light] .modal{background:#fff;border-color:#ddd}[data-theme=light] .modal-input{background:#f9f9f9;border-color:#ccc}[data-theme=light] .modal-cancel{background:#e9ecef;color:#333}[data-theme=light] .clear-btn,[data-theme=light] .manage-lists-btn{border-color:#ccc;color:#888}[data-theme=light] .theme-toggle,[data-theme=light] .manager-toggle{background:#f0f0f0;border-color:#ccc;color:#333}[data-theme=light] .theme-toggle:hover,[data-theme=light] .manager-toggle:hover{background:#e0e0e0;border-color:#646cff}[data-theme=light] .manager-toggle.active{background:#4361ee;border-color:#4361ee;color:#fff}[data-theme=light] .manager-bar{border-color:#4361ee44;background:#4361ee08}[data-theme=light] .mgr-action-btn{border-color:#ccc;color:#666}[data-theme=light] .mgr-limit{color:#666}[data-theme=light] .mgr-limit input{background:#fff;border-color:#ccc;color:#333}[data-theme=light] .group-csv-btn{border-color:#ccc;color:#888}[data-theme=light] .preset-load{color:#333}[data-theme=light] .preset-chip,[data-theme=light] .preset-delete{border-color:#ddd}[data-theme=light] .filter-input{background:#fff;border-color:#ccc;color:#333}[data-theme=light] .history-section{border-color:#ddd}[data-theme=light] .history-toggle-btn{border-color:#ccc;color:#888}[data-theme=light] .history-item{border-color:#ddd}[data-theme=light] .history-restore{border-color:#ccc;color:#888}[data-theme=light] .rule-item input[type=checkbox]{accent-color:#4361ee}[data-theme=light] .space-toggle{color:#333}[data-theme=light] .results-placeholder{color:#999}[data-theme=light] .results-info,[data-theme=light] .chip-count{color:#666}[data-theme=light] .chip-delete,[data-theme=light] .dropdown-empty{color:#999}[data-theme=light] .dropdown-item:disabled{color:#bbb}[data-theme=light] .rules-header h2,[data-theme=light] .results-title-row h2{color:#213547}[data-theme=light] .rule-item span{color:#333}[data-theme=light] .result-line{color:#213547}[data-theme=light] .clear-btn:hover:not(:disabled){border-color:#ff6b6b;color:#ff6b6b}[data-theme=light] .manage-lists-btn:hover,[data-theme=light] .group-menu-btn:hover{border-color:#646cff;color:#646cff}[data-theme=light] .group-name-input{color:#213547}[data-theme=light] .group-name-input:hover{border-color:#ccc}[data-theme=light] .group-name-input:focus{border-color:#646cff;background:#f9f9f9}[data-theme=light] .pk-manager-modal{background:#fff;border-color:#ddd}[data-theme=light] .pk-close-btn{border-color:#ccc;color:#888}[data-theme=light] .pk-group-item{border-color:#ddd}[data-theme=light] .pk-group-name{color:#333}[data-theme=light] .pk-rename-input{background:#f9f9f9;border-color:#646cff;color:#333}[data-theme=light] .pk-edit-area textarea{background:#f9f9f9;border-color:#ccc;color:#333}[data-theme=light] .pk-add-btn{border-color:#ccc;color:#999}[data-theme=light] .pk-add-form{border-color:#4361ee44}[data-theme=light] .pk-add-textarea{background:#f9f9f9;border-color:#ccc;color:#333}[data-theme=light] .dropdown-section-title{color:#999}[data-theme=light] .profile-selector select{background:#f0f0f0;border-color:#ccc;color:#333}[data-theme=light] .profile-banner{background:#4361ee08;border-color:#4361ee22;color:#555}[data-theme=light] .profile-banner--warning{background:#ff6b6b08;border-color:#ff6b6b22;color:#886}[data-theme=light] .pf-form-panel{background:#fff;border-color:#ddd}[data-theme=light] .pf-field input,[data-theme=light] .pf-field select{background:#f9f9f9;border-color:#ccc;color:#333}[data-theme=light] .pf-card{background:#fff;border-color:#ddd}[data-theme=light] .pf-card:hover{border-color:#4361ee44;background:#f8f9ff}[data-theme=light] .pf-card--selected{border-color:#4361ee;background:#4361ee08}[data-theme=light] .pf-card-category{color:#666}[data-theme=light] .pf-card-tag{background:#eee;color:#666}[data-theme=light] .pf-card-keywords{color:#888}[data-theme=light] .pf-empty{border-color:#ddd;color:#999}[data-theme=light] .pf-error{background:#ff6b6b11;border-color:#ff6b6b33}[data-theme=light] .ia-form-panel{background:#fff;border-color:#ddd}[data-theme=light] .ia-form-panel h2{color:#213547}[data-theme=light] .ia-field label{color:#666}[data-theme=light] .ia-field input{background:#f9f9f9;border-color:#ccc;color:#333}[data-theme=light] .ia-chat-panel{background:#fff;border-color:#ddd}[data-theme=light] .ia-chat-header h2{color:#213547}[data-theme=light] .ia-chat-reset{border-color:#ccc;color:#888}[data-theme=light] .ia-msg--user{background:#4361ee11;border-color:#4361ee33}[data-theme=light] .ia-msg--assistant{background:#f5f5f5;border-color:#ddd}[data-theme=light] .ia-msg--system{background:#f0f0f0;border-color:#ccc}[data-theme=light] .ia-system-text{color:#888}[data-theme=light] .ia-loading-text{color:#666}[data-theme=light] .ia-md-h3{color:#213547}[data-theme=light] .ia-md-h4,[data-theme=light] .ia-msg-content{color:#333}[data-theme=light] .ia-chat-input{background:#f9f9f9;border-color:#ccc;color:#333}[data-theme=light] .ia-msg-copy{background:#f0f0f0;border-color:#ccc;color:#888}@media(max-width:900px){.groups-input{grid-template-columns:repeat(2,1fr)}.main-layout{grid-template-columns:1fr}.rules-grid{grid-template-columns:repeat(3,1fr)}}@media(max-width:600px){.app{padding:1rem .75rem}.sidebar-toggle{display:block;flex-shrink:0}.sidebar{position:fixed;left:0;top:0;width:220px;height:100vh;z-index:300;transform:translate(-100%);transition:transform .25s ease;min-height:unset}.sidebar.collapsed{width:220px}.sidebar-collapse-btn{display:none}.sidebar.collapsed .sidebar-menu-item{text-align:left;padding:.7em 1em;font-size:.9em;border-left-width:3px}.sidebar.open{transform:translate(0)}.sidebar-overlay{display:block;position:fixed;inset:0;background:#00000080;z-index:299}.header-logo{height:1em}.app-header h1{font-size:1.2em}.theme-toggle,.manager-toggle{font-size:.9em;padding:.3em .5em}.rules-header{flex-direction:column;align-items:stretch}.rules-header h2{text-align:center}.rules-header-actions{flex-wrap:wrap;justify-content:center}.rules-header-actions button{white-space:nowrap;font-size:.78em;padding:.4em .7em}.rules-grid{grid-template-columns:repeat(2,1fr)}.rules-panel,.results-panel{padding:.75rem}.manager-bar{flex-direction:column;align-items:stretch;gap:.5rem;padding:.5rem .75rem}.mgr-limit{margin-left:0}.pk-manager-modal{min-width:unset;width:92vw}.profile-selector{margin:0 .3rem}.profile-selector select{max-width:140px;font-size:.78em}.pf-form-grid,.pf-list{grid-template-columns:1fr}.profile-banner{font-size:.8em;flex-wrap:wrap}.ia-form-grid{grid-template-columns:1fr}.ia-chat-input-wrap{flex-direction:column}.ia-send-btn{width:100%}.ia-messages{max-height:350px}}@media(max-width:500px){.groups-input{grid-template-columns:1fr}.rule-item{font-size:.8em}}
