.sort-tool-section{--sort-primary:var(--tool-accent);--sort-primary-dark:var(--tool-accent-strong);--sort-primary-soft:var(--tool-accent-soft);--sort-success:var(--tool-success);--sort-ink:var(--tool-ink);--sort-muted:var(--tool-muted);--sort-line:var(--tool-line);--sort-line-soft:var(--tool-line);--sort-surface:var(--tool-surface);--sort-gutter:calc(clamp(1rem, 2vw, 1.5rem));--sort-radius-sm:var(--tool-radius-sm);--sort-radius-md:var(--tool-radius-sm);background:#fff;border:1px solid var(--sort-line);border-radius:var(--tool-radius);color:var(--sort-ink);overflow:hidden;overflow-wrap:anywhere}.sort-options-card{background:var(--sort-surface);border-block-end:1px solid var(--sort-line);padding:14px var(--sort-gutter)}.sort-options-layout{align-items:start;display:grid;gap:12px calc(clamp(16px, 2vw, 28px));grid-template-columns:calc(clamp(14rem, 22vw, 17rem)) minmax(0,max-content) minmax(0,max-content)}.sort-cleanup-field,.sort-order-field{min-width:0}.sort-order-field .select-input.form-control[readonly]:not([disabled]){background-color:#fff}.sort-cleanup-field{border-inline-start:1px solid var(--sort-line);padding-inline-start:calc(clamp(16px, 2vw, 24px))}.sort-field-label{align-items:center;color:#5e6c80;display:flex;font-weight:700;gap:8px;line-height:1.45;margin-bottom:10px}.sort-field-label .svg-inline--fa,.sort-field-label svg{color:var(--sort-primary);flex:0 0 auto;width:16px}.sort-field-label span{min-width:0;overflow-wrap:normal;hyphens:auto}.sort-cleanup-heading{align-items:center;display:flex;justify-content:space-between}.cleanup-toggle{align-items:center;background:transparent;border:0;display:none;font-weight:700;gap:8px;min-height:44px;padding:6px 0 6px 12px}.cleanup-count,.cleanup-toggle{color:var(--sort-primary-dark);font-size:.9rem}.cleanup-count{background:#fff;border:1px solid #cbd9f2;border-radius:999px;padding:3px 8px}.cleanup-toggle .svg-inline--fa,.cleanup-toggle svg{transition:transform .18s ease}.cleanup-toggle[aria-expanded=true] .svg-inline--fa,.cleanup-toggle[aria-expanded=true] svg{transform:rotate(180deg)}.cleanup-options{display:grid;grid-template-columns:repeat(3,minmax(0,max-content));column-gap:10px}.cleanup-option{align-items:center;border-radius:8px;color:#39465a;cursor:pointer;display:flex;gap:8px;line-height:1.4;min-height:32px;min-width:0;padding:5px 8px 5px 4px;transition:background-color .16s ease,color .16s ease}.cleanup-option:hover{background:#fff;color:var(--sort-primary-dark)}.cleanup-option .form-check-input{cursor:pointer;flex:0 0 auto;margin:0}.cleanup-option span{overflow-wrap:anywhere}.auto-detect-note{align-items:flex-start;color:var(--sort-muted);display:flex;gap:6px;margin-top:8px}.auto-detect-note .svg-inline--fa,.auto-detect-note svg{color:var(--sort-primary);flex:none;margin-block-start:.25em}.sort-editor-controls{display:flex;align-items:center;align-self:center;flex-wrap:wrap;gap:10px}.editor-tabs{background:#fff;border:1px solid var(--sort-line);display:none;flex:1 1 12rem;min-width:0}.editor-tab,.editor-tabs{border-radius:var(--sort-radius-sm)}.editor-tab{background:transparent;border:0;color:var(--sort-muted);flex:1 1 50%;font-weight:700;min-height:40px;padding:8px 12px}.editor-tab.is-active{background:var(--sort-primary-soft);color:var(--sort-primary-dark)}.sort-workspace{display:grid;gap:12px;grid-template-columns:repeat(2,minmax(0,1fr));padding:var(--sort-gutter) var(--sort-gutter) 0;width:100%}.editor-pane{min-width:0}.editor-wrapper{background:#fff;border:1px solid var(--sort-line);border-radius:var(--sort-radius-md);box-shadow:none;display:flex;flex-direction:column;height:100%;overflow:hidden}.editor-wrapper:focus-within{border-color:#8db0ec;box-shadow:0 0 0 3px rgba(53,111,211,.1)}.editor-toolbar{background:var(--sort-surface);border-bottom:1px solid var(--sort-line-soft);flex-wrap:wrap;gap:6px 12px;justify-content:space-between;min-height:56px;padding:9px 12px 9px 16px}.editor-title,.editor-toolbar{align-items:center;display:flex}.editor-title{font-weight:750;gap:8px;min-width:0}.editor-title .svg-inline--fa,.editor-title svg{color:var(--sort-primary);flex:0 0 auto}.editor-title--result .svg-inline--fa,.editor-title--result svg{color:var(--sort-success)}.editor-actions{align-items:center;display:flex;flex-wrap:wrap;gap:6px}.sort-tool .tool-action--danger:hover{--tool-btn-bg:#fff3f2;--tool-btn-bd:#f4c7c3;color:#b42318}.sort-tool .editor-container{background:#fff;display:flex;margin:0}.sort-tool .editor-container--result,.sort-tool .editor-container--result textarea{background:#fbfcfe}.sort-tool .editor-container .line-numbers,.sort-tool .editor-container textarea{font-family:Consolas,Monaco,Courier New,monospace;font-size:.95rem;height:30rem;line-height:1.6;padding:12px}.sort-tool .line-numbers{background:#f7f9fc;border-right:1px solid var(--sort-line-soft);color:#8c98a8;margin:0;min-width:44px;overflow:hidden;text-align:right;user-select:none}.sort-tool .editor-container textarea{border:0;border-radius:0;flex:1 1 auto;min-width:0;outline:none;overflow:auto;resize:none;white-space:pre}.sort-tool .editor-container textarea:focus{box-shadow:none}.sort-tool .editor-container textarea:placeholder-shown{white-space:pre-wrap}.sort-tool .editor-meta-bar{align-items:center;background:var(--sort-surface);border-top:1px solid var(--sort-line-soft);color:var(--sort-muted);display:flex;flex-wrap:wrap;font-size:.9rem;gap:8px 16px;justify-content:space-between;line-height:1.45;min-height:37px;padding:8px 14px}.editor-meta-total{color:var(--sort-primary);flex:0 0 auto;font-weight:750}.editor-meta-total--result{color:var(--sort-success)}.editor-meta-detail{text-align:right}.sort-tool .editor-footer-bar{align-items:flex-start;background:#fff;border-top:1px solid var(--sort-line-soft);color:var(--sort-muted);display:flex;flex:1;gap:7px;line-height:1.5;min-height:40px;padding:9px 14px}.editor-footer-bar .svg-inline--fa,.editor-footer-bar svg{color:var(--sort-muted);flex:0 0 auto;margin-block-start:.25em}.editor-footer-bar--result .svg-inline--fa,.editor-footer-bar--result svg{color:var(--sort-success)}.sort-primary-action{min-height:44px}.sort-info-grid{display:grid;gap:1.25rem 2rem;grid-template-columns:repeat(2,minmax(0,1fr));margin-top:var(--sort-gutter);padding:var(--sort-gutter);border-top:1px solid var(--sort-line)}.sort-tool .tip-title{margin:0 0 .5rem;color:var(--sort-ink);font-size:1rem;font-weight:700;line-height:1.5}.sort-tool .tip-body{color:var(--sort-muted);line-height:1.7;margin:0;padding-left:1.2rem}.sort-tool .tip-body code{padding:.1em .35em;border-radius:4px;background:var(--sort-surface);color:#b4235a;font-size:.9rem}.sort-tool .tip-body li+li{margin-top:4px}.sort-tool button:focus-visible,.sort-tool input:focus-visible,.sort-tool select:focus-visible,.sort-tool textarea:focus-visible{outline:3px solid rgba(53,111,211,.24);outline-offset:2px}@media screen and (max-width:1199.98px){.sort-tool .sort-workspace{grid-template-columns:minmax(0,1fr)}.sort-tool .editor-container .line-numbers,.sort-tool .editor-container textarea{height:22rem}}@media screen and (max-width:991.98px){.sort-options-layout{grid-template-columns:minmax(0,1fr)}.sort-cleanup-field{border-inline-start:0;padding-inline-start:0}.sort-cleanup-field,.sort-editor-controls{border-block-start:1px solid var(--sort-line);padding-block-start:12px}.sort-info-grid{grid-template-columns:minmax(0,1fr)}}@media screen and (max-width:767.98px){.sort-cleanup-field{padding-block-start:4px}.sort-cleanup-heading .sort-field-label{margin-bottom:0;min-width:0}.cleanup-toggle{flex:0 0 auto;display:inline-flex;padding-left:8px}.cleanup-toggle>span:first-child{display:none}.cleanup-count{white-space:nowrap}.cleanup-options{display:none;grid-template-columns:repeat(2,minmax(0,1fr));margin-top:10px}.cleanup-options.is-open{display:grid}.cleanup-option{min-height:46px;padding:8px}.editor-tabs{display:flex}.editor-pane{display:none}.editor-pane.is-active{display:block}.editor-toolbar{min-height:54px;padding:8px 8px 8px 12px}.editor-actions{gap:2px}.sort-tool .tool-action{min-height:44px;padding-inline:.7rem}.action-label-full{display:none}.sort-tool .editor-container .line-numbers,.sort-tool .editor-container textarea{height:19rem}.sort-tool .editor-meta-bar{align-items:flex-start;flex-direction:column;gap:3px;min-height:52px;padding:8px 12px}.editor-meta-detail{text-align:left}.sort-tool .editor-footer-bar{min-height:38px;padding:8px 12px}}@media screen and (max-width:419.98px){.cleanup-options{grid-template-columns:minmax(0,1fr)}.cleanup-option{padding-left:10px}.sort-tool .tool-action{min-width:40px}}@media screen and (min-width:1600px){.sort-tool .editor-container .line-numbers,.sort-tool .editor-container textarea{height:38rem}}@media screen and (min-width:1900px){.sort-tool .editor-container .line-numbers,.sort-tool .editor-container textarea{height:46rem}}@media (prefers-reduced-motion:reduce){.sort-tool *,.sort-tool :after,.sort-tool :before{scroll-behavior:auto!important;transition-duration:.01ms!important}}