/* TradeDesk X Pro Scanner */
#proRoot{--pro-up:var(--green,#24d18f);--pro-dn:var(--red,#ff6174);--pro-blue:var(--blue,#45a4ff);--pro-amber:var(--amber,#f7b955);--pro-card:#0a1626;--pro-card2:#0c1b2f;--pro-line:#1d3149;--pro-mono:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;display:grid;gap:10px;min-width:0}
#proRoot *{box-sizing:border-box}
#proRoot .hidden{display:none!important}
#proRoot button{font:inherit;color:inherit;cursor:pointer}
#proRoot kbd{font:600 9px var(--pro-mono);padding:1px 4px;border:1px solid #2b4560;border-radius:4px;color:#7f9ab5;background:#081322}
#proRoot .up{color:var(--pro-up)}#proRoot .dn{color:var(--pro-dn)}
#proRoot .pro-muted{color:var(--muted,#8fa4bd)}
#proRoot .right{margin-left:auto}
#proRoot .bad{color:var(--pro-dn)}

/* ---- top bar */
.pro-sim{padding:8px 12px;border:1px solid #6b4a12;background:#2a1e07;color:#ffd48a;border-radius:10px;font-size:12px;font-weight:700;letter-spacing:.02em}
.pro-bar{display:grid;gap:8px;padding:10px 12px;border:1px solid var(--pro-line);border-radius:14px;background:linear-gradient(180deg,#0b1a2d,#08131f);position:relative}
.pro-bar-row{display:flex;align-items:center;gap:10px;min-width:0}
.pro-bar-row.wrap{flex-wrap:wrap}
.pro-bar-right{display:flex;gap:8px;margin-left:auto;flex:none}
.pro-tabs{display:flex;gap:4px;overflow-x:auto;scrollbar-width:none;min-width:0;padding:1px}
.pro-tabs::-webkit-scrollbar{display:none}
.pro-tab{display:inline-flex;align-items:center;gap:6px;white-space:nowrap;padding:7px 11px;border:1px solid transparent;border-radius:9px;background:transparent;color:#9db3cb;font-size:12.5px;font-weight:700;min-height:34px}
.pro-tab small{font:600 10px var(--pro-mono);color:#5f7893}
.pro-tab:hover{background:#0f2238;color:#dcebfb}
.pro-tab.active{background:#12304f;border-color:#2c6aa8;color:#fff;box-shadow:inset 0 -2px 0 var(--pro-blue)}
.pro-pip{min-width:18px;height:18px;padding:0 5px;border-radius:9px;background:var(--pro-up);color:#03150e;font:800 10px/18px var(--pro-mono);text-align:center;animation:proPulse 2.2s ease-in-out infinite}
@keyframes proPulse{50%{box-shadow:0 0 0 4px rgba(36,209,143,.18)}}
.pro-tab kbd{opacity:.6}
.pro-btn{padding:8px 14px;border-radius:9px;border:1px solid #2a4562;background:#0f2238;font-weight:800;font-size:12px;letter-spacing:.02em;min-height:36px;transition:filter .15s,background .15s}
.pro-btn:hover{filter:brightness(1.15)}
.pro-btn:focus-visible,.pro-tab:focus-visible,.pro-row:focus-visible,.pro-chip:focus-visible,#proRoot input:focus-visible,#proRoot select:focus-visible{outline:2px solid var(--pro-blue);outline-offset:1px}
.pro-btn.primary{background:linear-gradient(180deg,#2b8cf0,#1f6fcd);border-color:#4aa3ff;color:#fff}
.pro-btn.primary.danger,.pro-btn.danger{background:linear-gradient(180deg,#d8475a,#a8323f);border-color:#ff7d8d;color:#fff}
.pro-btn.ghost{background:#0a1a2c}
.pro-btn:disabled{opacity:.4;cursor:not-allowed;filter:none}
.pro-seg{display:inline-flex;border:1px solid #234060;border-radius:10px;overflow:hidden;background:#081423}
.pro-seg button{padding:7px 12px;background:transparent;border:0;border-right:1px solid #1b3350;font-size:12px;font-weight:800;color:#93aac4;min-height:34px;display:inline-flex;align-items:baseline;gap:5px}
.pro-seg button:last-child{border-right:0}
.pro-seg button small{font:600 9px var(--pro-mono);opacity:.65}
.pro-seg button.active{background:#16436f;color:#fff}
.pro-seg.small button{padding:6px 10px;font-size:11px;min-height:30px}
.pro-inline{display:inline-flex;align-items:center;gap:6px;font-size:11.5px;font-weight:700;color:#9db3cb;cursor:pointer}
.pro-inline input{accent-color:var(--pro-blue);width:15px;height:15px}
.pro-select,#proRoot input[type=number],.pro-search{background:#081423;border:1px solid #234060;border-radius:8px;color:#e6f1ff;padding:6px 8px;font:600 12px var(--pro-mono);min-height:32px}
.pro-icon{width:34px;height:32px;border:1px solid #234060;background:#081423;border-radius:8px;font-size:14px}
.pro-status{font:800 10.5px var(--pro-mono);letter-spacing:.06em;padding:6px 9px;border-radius:7px;background:#0a1a2c;border:1px solid #234060;color:#8fa4bd}
.pro-status.ok{color:var(--pro-up);border-color:#1c6b4f}.pro-status.busy{color:var(--pro-amber);border-color:#7a5a1d}.pro-status.bad{color:var(--pro-dn);border-color:#7a2c37}
.pro-env{font:800 10.5px var(--pro-mono);letter-spacing:.06em;padding:6px 9px;border-radius:7px;border:1px solid #234060;margin-left:auto}
.pro-env.paper{color:#8fe3c0;border-color:#1c6b4f;background:#0a2219}.pro-env.demo{color:#ffd48a;border-color:#7a5a1d;background:#241a07}.pro-env.live{color:#fff;border-color:#ff7d8d;background:#6a1e29}
.pro-progress{height:3px;border-radius:2px;background:#0f2238;overflow:hidden;margin:0 -2px}
.pro-progress i{display:block;height:100%;width:0;background:linear-gradient(90deg,#2b8cf0,#24d18f);transition:width .35s ease}
.pro-progress.on i{animation:proGlow 1.4s ease-in-out infinite}
@keyframes proGlow{50%{filter:brightness(1.5)}}
.pro-universe{border:1px solid #234060;border-radius:12px;padding:12px;background:#08131f;display:grid;gap:8px}
.pro-uni-title{font-weight:800;font-size:12px}.pro-uni-title span{color:#6b86a3;font-weight:600;margin-left:6px}
.pro-uni-chips{display:flex;flex-wrap:wrap;gap:6px}
.pro-uni-chips button{padding:6px 10px;border-radius:999px;border:1px solid #234060;background:#0a1a2c;font-size:12px;font-weight:700;color:#8fa4bd}
.pro-uni-chips button.on{background:#12304f;border-color:#2c6aa8;color:#fff}
.pro-uni-chips small{font:600 10px var(--pro-mono);opacity:.7}
.pro-uni-note{font-size:11px;color:#6b86a3}.pro-uni-note code{font-family:var(--pro-mono);color:#9db3cb}
.pro-uni-actions{display:flex;gap:8px;justify-content:flex-end}

/* ---- movers */
.pro-movers{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
.pro-mover{border:1px solid var(--pro-line);border-radius:12px;background:var(--pro-card);padding:8px 10px;display:grid;gap:1px;align-content:start;min-width:0}
.pro-mover h4{margin:0 0 3px;font:800 10px var(--pro-mono);letter-spacing:.08em;text-transform:uppercase;color:#6f89a6}
.pro-mover button{display:flex;justify-content:space-between;gap:8px;padding:3px 4px;background:transparent;border:0;border-radius:6px;font-size:12px;text-align:left}
.pro-mover button:hover{background:#12263d}
.pro-mover button span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#d3e3f6}
.pro-mover b{font:700 11.5px var(--pro-mono)}
.pro-mover em{color:#4f6882;font-size:12px}

/* ---- main grid */
.pro-left{display:grid;gap:10px;min-width:0;align-content:start}
.pro-main{display:grid;grid-template-columns:minmax(0,1fr) 410px;gap:12px;align-items:start}
.pro-list{border:1px solid var(--pro-line);border-radius:14px;background:var(--pro-card);min-width:0;overflow:hidden}
.pro-filters{display:flex;align-items:center;flex-wrap:wrap;gap:8px;padding:10px 12px;border-bottom:1px solid var(--pro-line);background:#0a1829}
.pro-chip{padding:5px 10px;border-radius:999px;border:1px solid #234060;background:#081423;font:800 10.5px var(--pro-mono);letter-spacing:.05em;color:#6f89a6}
.pro-chip small{opacity:.8;margin-left:3px}
.pro-chip.on.st-execute{background:#0c3a2a;border-color:#1f9d70;color:#6af0b6}
.pro-chip.on.st-armed{background:#10304f;border-color:#2c6aa8;color:#8cc6ff}
.pro-chip.on.st-watch{background:#3a2b0c;border-color:#8a6a22;color:#ffd48a}
.pro-chip.on.st-avoid{background:#3a1219;border-color:#8a2c3a;color:#ff9aa8}
.pro-sep{width:1px;height:20px;background:#1f3550}
.pro-range{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:700;color:#8fa4bd}
.pro-range b{font:700 11px var(--pro-mono);color:#dbe9fa;min-width:18px}
.pro-range input{width:90px;accent-color:var(--pro-blue)}
.pro-search{margin-left:auto;width:150px}
.pro-grid-head,.pro-row{display:grid;align-items:center;column-gap:8px;padding:0 12px;min-width:900px}
.pro-grid-head{height:30px;font:800 9.5px var(--pro-mono);letter-spacing:.07em;text-transform:uppercase;color:#5f7893;border-bottom:1px solid var(--pro-line);background:#08121f;position:sticky;top:0;z-index:2}
.pro-grid-head.sig,.pro-row:not(.board){grid-template-columns:minmax(128px,1.2fr) 50px 80px 38px 112px minmax(160px,1.6fr) 44px 74px 58px 44px 52px}
.pro-grid-head.board,.pro-row.board{grid-template-columns:minmax(150px,1.5fr) 100px 90px 72px 72px 72px 56px 60px 64px 90px}
.pro-grid-head [data-sort]{cursor:pointer}.pro-grid-head .sorted{color:#8cc6ff}
.pro-list{overflow-x:auto}
.pro-rows{display:block;max-height:calc(100vh - 290px);min-height:240px;overflow-y:auto;overflow-x:visible;min-width:900px}
.pro-row{min-height:50px;border-bottom:1px solid #12233a;font-size:12.5px;cursor:pointer;position:relative;border-left:3px solid transparent;font-variant-numeric:tabular-nums}
.pro-row:hover{background:#0e2036}
.pro-row.sel{background:#112a47;border-left-color:var(--pro-blue)}
.pro-row.st-execute{border-left-color:var(--pro-up)}
.pro-row.st-avoid{opacity:.62}
.pro-row.new{animation:proNew 2.4s ease-out}
@keyframes proNew{0%{background:#14553d}100%{background:transparent}}
.c-inst{display:grid;line-height:1.25;min-width:0}.c-inst strong{font-size:13px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.c-inst span{font-size:10.5px;color:#6f89a6;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.c-dir{font:800 11px var(--pro-mono)}.c-dir.long{color:var(--pro-up)}.c-dir.short{color:var(--pro-dn)}
.c-state{display:flex;flex-direction:column;align-items:flex-start;gap:2px}
.pro-badge{display:inline-block;padding:3px 7px;border-radius:6px;font:800 10px var(--pro-mono);letter-spacing:.06em;border:1px solid transparent}
.pro-badge.st-execute{background:var(--pro-up);color:#03150e}
.pro-badge.st-armed{background:#10304f;border-color:#2c6aa8;color:#8cc6ff}
.pro-badge.st-watch{background:#2d230c;border-color:#7a5f22;color:#ffd48a}
.pro-badge.st-avoid,.pro-badge.st-no_data{background:#2a1218;border-color:#6d2a35;color:#ff9aa8}
.pro-stale{font:800 8.5px var(--pro-mono);color:#ffb86b;letter-spacing:.06em;font-style:normal}
.pro-grade{display:inline-grid;place-items:center;min-width:28px;height:22px;padding:0 5px;border-radius:6px;font:800 11px var(--pro-mono)}
.g-ap{background:linear-gradient(135deg,#ffd76a,#f0a12a);color:#2a1a00}.g-a{background:#145a42;color:#8ff5c8}.g-b{background:#143f68;color:#9bd0ff}.g-c{background:#2a3647;color:#a9bbcf}.g-d,.g-x{background:#1a222d;color:#6b7c90}
.c-conf{display:grid;gap:3px}
.c-conf .pro-bar-meter{grid-row:1}.c-conf b{position:absolute;margin-left:0;display:none}
.pro-bar-meter{height:6px;border-radius:3px;background:#0f2238;overflow:hidden}
.pro-bar-meter i{display:block;height:100%;border-radius:3px}
.m-hi{background:linear-gradient(90deg,#17a06f,#24d18f)}.m-mid{background:linear-gradient(90deg,#2b72c4,#45a4ff)}.m-lo{background:#46607c}
.pro-bar-meter.sm{width:70px}
.c-conf{grid-template-columns:1fr auto;align-items:center;column-gap:6px}
.c-conf b{display:block;position:static;font:800 12px var(--pro-mono);color:#e6f1ff;grid-column:2;grid-row:1}
.pro-dots{grid-column:1/-1;display:flex;gap:2px}
.pro-dots i{width:7px;height:5px;border-radius:1px;background:#1b2b3f}.pro-dots i.p{background:var(--pro-up)}.pro-dots i.f{background:#7d2b37}.pro-dots i.n{background:#2a3a4f}
.c-plan{display:grid;line-height:1.3;min-width:0}.c-plan span{font:600 12px var(--pro-mono);white-space:nowrap}.c-plan b{font-size:9.5px;letter-spacing:.06em;color:#8cc6ff;margin-right:3px}.c-plan small{font:500 10px var(--pro-mono);color:#6f89a6;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.c-rr{font:700 12px var(--pro-mono)}
.c-htf{display:flex;gap:3px}
.c-htf i,.pro-trend i{font:800 9.5px var(--pro-mono);font-style:normal;padding:2px 5px;border-radius:4px;border:1px solid transparent}
.b-bullish{background:#0e3a2a;color:#6af0b6;border-color:#1c6b4f}.b-bearish{background:#3a1219;color:#ff9aa8;border-color:#7a2c37}.b-neutral{background:#1a2736;color:#8fa4bd;border-color:#2a3d54}
.c-d1,.c-rv{font:600 12px var(--pro-mono)}
.pro-route{font:800 9px var(--pro-mono);letter-spacing:.06em;padding:3px 6px;border-radius:5px;border:1px solid #1c6b4f;color:#6af0b6;background:#0a2219}
.pro-route.proxy{border-color:#7a5a1d;color:#ffd48a;background:#241a07}.pro-route.off{border-color:#2a3d54;color:#6f89a6;background:#0d1a2a}
.pro-tr{font-style:normal;font:800 9.5px var(--pro-mono)}.t-up{color:var(--pro-up)}.t-down{color:var(--pro-dn)}.t-mixed{color:#8fa4bd}
.pro-empty{padding:34px 20px;text-align:center;color:#8fa4bd;line-height:1.7;font-size:13px}
.pro-empty span{font-size:11px;color:#5f7893}.pro-empty.small{padding:14px}
.pro-foot{display:flex;justify-content:space-between;gap:10px;padding:8px 12px;border-top:1px solid var(--pro-line);font:600 10.5px var(--pro-mono);color:#5f7893;min-width:900px;flex-wrap:wrap}

/* ---- detail */
.pro-detail{position:sticky;top:8px;max-height:calc(100vh - 20px);overflow-y:auto;border:1px solid var(--pro-line);border-radius:14px;background:var(--pro-card);display:grid;gap:10px;padding:12px;align-content:start;scrollbar-width:thin}
.pro-d-head{display:flex;align-items:flex-start;gap:10px}
.pro-d-head h3{margin:0;font-size:17px}.pro-d-head h3 small{font:600 11px var(--pro-mono);color:#6f89a6;margin-left:4px}
.pro-d-price{margin-left:auto;text-align:right;display:grid}.pro-d-price b{font:800 17px var(--pro-mono)}.pro-d-price span{font:700 11px var(--pro-mono)}
.pro-close{display:none;width:34px;height:34px;border-radius:9px;border:1px solid #234060;background:#0a1a2c;font-size:16px}
.pro-d-state{display:flex;flex-wrap:wrap;align-items:center;gap:7px;font-size:12px}
.pro-dir{font:800 11px var(--pro-mono);padding:3px 7px;border-radius:6px}.pro-dir.long{background:#0e3a2a;color:#6af0b6}.pro-dir.short{background:#3a1219;color:#ff9aa8}.pro-dir.none{background:#1a2736;color:#8fa4bd}
.pro-score b{font:800 16px var(--pro-mono)}.pro-score{color:#6f89a6;font:600 11px var(--pro-mono)}
.pro-blockers{display:flex;flex-wrap:wrap;gap:6px}.pro-blockers span{font-size:11px;font-weight:700;color:#ffb3bd;background:#2a1218;border:1px solid #6d2a35;padding:4px 8px;border-radius:7px}
.pro-chart-wrap{position:relative;border:1px solid #17304a;border-radius:10px;background:#07111d;height:215px;overflow:hidden}
.pro-chart-wrap canvas{width:100%;height:100%;display:block}
.pro-chart-load{position:absolute;inset:0;display:grid;place-items:center;color:#6f89a6;font-size:12px;background:rgba(7,17,29,.7)}
.pro-plan{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}
.pro-plan>div:nth-child(1){grid-column:span 2}.pro-plan>div:nth-child(6){grid-column:1/-1}
.pro-plan>div{padding:7px 9px;border:1px solid #1a3250;border-radius:9px;background:#08131f;display:grid;gap:1px;min-width:0}
.pro-plan label,.pro-trend label,.pro-t-calc label,.pro-c-grid label,.pro-t-inputs label{font:700 9.5px var(--pro-mono);letter-spacing:.06em;text-transform:uppercase;color:#5f7893}
.pro-plan b{font:700 12.5px var(--pro-mono);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.pro-plan small{color:#6f89a6}
.pro-plan .sl b{color:var(--pro-dn)}.pro-plan .tp b{color:var(--pro-up)}
.pro-trend{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}
.pro-trend>div{padding:7px 9px;border:1px solid #1a3250;border-radius:9px;background:#08131f;display:grid;gap:3px;justify-items:start}
.pro-trend small{font:600 10px var(--pro-mono);color:#6f89a6}
.pro-factors{display:grid;grid-template-columns:1fr 1fr;gap:8px 12px}
.pro-fg h5{margin:0 0 3px;font:800 9.5px var(--pro-mono);letter-spacing:.09em;text-transform:uppercase;color:#5f7893}
.pro-f{display:grid;grid-template-columns:16px 1fr;column-gap:6px;padding:3px 0;font-size:11.5px;border-bottom:1px dashed #14263c}
.pro-f i{font-style:normal;font-weight:900;grid-row:span 2;align-self:start}
.pro-f.p i{color:var(--pro-up)}.pro-f.f i{color:var(--pro-dn)}.pro-f.n i{color:#4f6882}
.pro-f.n span{color:#6f89a6}
.pro-f em{font-style:normal;font-size:10.5px;color:#6f89a6;grid-column:2}

/* ---- ticket */
.pro-ticket{border:1px solid #234060;border-radius:12px;padding:10px;background:#08131f;display:grid;gap:8px}
.pro-ticket.live{border-color:#a73a49;background:#150a0e}.pro-ticket.demo{border-color:#7a5a1d}
.pro-t-head{display:flex;justify-content:space-between;align-items:center;font-size:13px}
.pro-t-route{font-size:12px;color:#9db3cb}.pro-t-route b{font-family:var(--pro-mono);color:#e6f1ff}
.pro-t-inputs{display:grid;grid-template-columns:repeat(auto-fit,minmax(90px,1fr));gap:8px}
.pro-t-inputs label{display:grid;gap:3px}.pro-t-inputs input{width:100%}
.pro-t-inputs label small{text-transform:none;letter-spacing:0;font-weight:500}
.pro-t-calc{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}.pro-t-calc>div{display:grid;gap:1px}.pro-t-calc b{font:800 13.5px var(--pro-mono)}
.pro-btn.exec{width:100%;min-height:44px;font-size:13px;letter-spacing:.04em}
.pro-btn.exec.long{background:linear-gradient(180deg,#1fbf86,#15915f);border-color:#3fe0a6;color:#03150e}
.pro-btn.exec.short{background:linear-gradient(180deg,#e0505f,#b23542);border-color:#ff8794;color:#fff}
.pro-t-note{margin:0;font-size:10.5px;color:#6f89a6;line-height:1.5}

/* ---- dialog */
.pro-dialog{border:1px solid #2c4a6a;border-radius:14px;background:#08131f;color:#eaf4ff;padding:0;width:min(560px,calc(100vw - 24px))}
.pro-dialog::backdrop{background:rgba(2,8,16,.72);backdrop-filter:blur(3px)}
.pro-confirm{padding:16px;display:grid;gap:12px}.pro-confirm h3{margin:0;font-size:18px}.pro-confirm h3 small{font:600 11px var(--pro-mono);color:#6f89a6}
.pro-c-env{font:800 11px var(--pro-mono);letter-spacing:.06em;padding:6px 9px;border-radius:7px;border:1px solid #1c6b4f;color:#8fe3c0;background:#0a2219;justify-self:start}
.pro-c-env.demo{border-color:#7a5a1d;color:#ffd48a;background:#241a07}.pro-c-env.live{border-color:#ff7d8d;color:#fff;background:#6a1e29}
.pro-c-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px}.pro-c-grid>div{padding:7px 9px;border:1px solid #1a3250;border-radius:9px;display:grid;gap:1px}.pro-c-grid b{font:700 12.5px var(--pro-mono)}
.pro-c-check{display:flex;gap:8px;align-items:flex-start;font-size:12px;color:#ffd48a;line-height:1.5}.pro-c-check input{margin-top:3px;accent-color:var(--pro-amber)}
.pro-c-warn{padding:8px 10px;border-radius:8px;background:#2a1e07;border:1px solid #6b4a12;color:#ffd48a;font-size:12px;font-weight:700}.pro-c-warn.live{background:#3a0f17;border-color:#a73a49;color:#ffb3bd}
.pro-c-error{color:#ff9aa8;font-size:12px;font-weight:700;min-height:0;line-height:1.5}
.pro-c-actions{display:flex;gap:8px;justify-content:flex-end}.pro-c-actions .pro-btn.exec{width:auto;min-width:170px}

/* ---- toasts */
.pro-toasts{position:fixed;right:14px;bottom:calc(14px + env(safe-area-inset-bottom));display:grid;gap:8px;z-index:90;max-width:min(420px,calc(100vw - 28px))}
.pro-toast{display:flex;align-items:center;gap:10px;padding:10px 12px;border-radius:11px;border:1px solid #2a4562;background:#0c1b2f;box-shadow:0 10px 30px rgba(0,0,0,.45);font-size:12.5px;animation:proIn .25s ease-out}
@keyframes proIn{from{transform:translateY(10px);opacity:0}}
.pro-toast.exec{border-color:#1f9d70;background:#0b2a20}.pro-toast.good{border-color:#1f9d70}.pro-toast.bad{border-color:#a73a49;background:#2a1018}
.pro-toast span{flex:1}.pro-toast button{padding:5px 10px;border-radius:7px;border:1px solid #3fe0a6;background:transparent;font-weight:800;font-size:11px;color:#6af0b6}
.pro-toast i{font-style:normal;cursor:pointer;opacity:.6;padding:0 3px}

/* ---- responsive */
@media(max-width:1180px){
  .pro-main{grid-template-columns:minmax(0,1fr)}
  .pro-detail{position:fixed;inset:0;z-index:80;max-height:none;border-radius:0;transform:translateY(105%);transition:transform .28s ease;padding-bottom:calc(16px + env(safe-area-inset-bottom));background:#08131f;visibility:hidden}
  .pro-detail.open{transform:none;visibility:visible}
  .pro-close{display:grid;place-items:center;flex:none}
  .pro-rows{max-height:none}
  .pro-movers{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media(max-width:760px){
  #proRoot .pro-btn,#proRoot .pro-seg button,#proRoot .pro-select,#proRoot .pro-tab,#proRoot .pro-chip,#proRoot .pro-icon,#proRoot .pro-inline{font-size:11.5px!important}
  #proRoot .pro-btn,#proRoot .pro-seg button,#proRoot .pro-select,#proRoot .pro-icon{min-height:32px!important;padding-top:4px;padding-bottom:4px}
  #proRoot .pro-bar{padding:8px;gap:6px}.pro-bar-row{gap:6px}
  #proRoot .pro-status,#proRoot .pro-env{font-size:9.5px}
  .pro-movers{display:none}
  .pro-tab kbd{display:none}
  .pro-bar-row:first-child{flex-wrap:wrap}.pro-bar-right{width:100%}.pro-bar-right .pro-btn{flex:1}
  .pro-env{margin-left:0}
  .pro-list{overflow:visible;border:0;background:transparent}
  .pro-filters{border:1px solid var(--pro-line);border-radius:12px;margin-bottom:8px}
  .pro-search{width:100%;margin-left:0}
  .pro-grid-head,.pro-foot{display:none}
  .pro-foot{display:flex;min-width:0}
  .pro-rows{min-width:0;overflow:visible}
  .pro-row:not(.board){grid-template-columns:1fr auto auto auto;grid-template-areas:"inst dir state grade" "conf conf conf conf" "plan plan plan rr" "htf htf d1 route";row-gap:6px;padding:10px 12px;min-width:0;border:1px solid var(--pro-line);border-left-width:3px;border-radius:12px;margin-bottom:8px;background:var(--pro-card)}
  .pro-row .c-dir{grid-area:dir}.pro-row .c-inst{grid-area:inst}.pro-row .c-state{grid-area:state;flex-direction:row;align-items:center}.pro-row .c-grade{grid-area:grade}
  .pro-row .c-conf{grid-area:conf}.pro-row .c-plan{grid-area:plan}.pro-row .c-rr{grid-area:rr}.pro-row .c-htf{grid-area:htf}.pro-row .c-d1{grid-area:d1}.pro-row .c-route{grid-area:route;justify-self:end}
  .pro-row .c-rv{display:none}
  .pro-row.board{grid-template-columns:1fr auto auto auto;min-width:0;gap:6px;border:1px solid var(--pro-line);border-radius:10px;margin-bottom:6px;padding:8px 10px;background:var(--pro-card)}
  .pro-row.board>div:nth-child(2),.pro-row.board>div:nth-child(6),.pro-row.board>div:nth-child(7),.pro-row.board>div:nth-child(8),.pro-row.board>div:nth-child(9),.pro-row.board>div:nth-child(10){display:none}
  .pro-factors{grid-template-columns:1fr}
  .pro-plan,.pro-trend{grid-template-columns:repeat(2,1fr)}
  .pro-movers{grid-template-columns:1fr 1fr}
  .pro-chart-wrap{height:220px}
  .pro-c-grid{grid-template-columns:1fr}
}
@media(prefers-reduced-motion:reduce){.pro-pip,.pro-progress.on i,.pro-row.new,.pro-toast{animation:none}.pro-detail{transition:none}}

body.pro-sheet-open .back-to-top{display:none!important}

/* The bottom nav gained a tab; keep it inside the viewport and let it scroll sideways instead of widening the page. */
@media(max-width:760px){
  #nav{width:100%;max-width:100vw;box-sizing:border-box;display:flex;flex-wrap:nowrap;justify-content:flex-start}
  #nav button{flex:0 0 auto}
}

/* Classic scanner: the visually-hidden AUTO SCAN checkbox was absolutely positioned against the page, creating horizontal scroll. */
.auto-switch{position:relative}.auto-switch input{left:0;top:0}

/* ---- EARLY tier + entry timing */
.pro-chip.on.st-early{background:#241f4a;border-color:#4d4396;color:#c3baff}
.pro-badge.st-early{background:#241f4a;border-color:#6a5fd0;color:#c3baff}
.pro-row.st-early{border-left-color:#8b7bff}
.pro-timing{display:block;font:800 8.5px var(--pro-mono);font-style:normal;letter-spacing:.05em;white-space:nowrap}
.pro-timing.conf{color:#6af0b6}.pro-timing.early{color:#c3baff}.pro-timing.wait{color:#6f89a6;font-weight:600}
.pro-toast.early{border-color:#6a5fd0;background:#16133a}
.pro-timing-card{border:1px solid #2a2860;background:#12112e;border-radius:10px;padding:9px 11px;display:grid;gap:6px}
.pro-timing-card.conf{border-color:#1f6b52;background:#0a2219}.pro-timing-card.wait{border-color:#1d3149;background:#0a1626}
.pro-tc-head{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.pro-tc-head b{font:800 10px var(--pro-mono);letter-spacing:.09em;text-transform:uppercase;color:#6f89a6}.pro-tc-head small{font:600 10.5px var(--pro-mono);color:#6f89a6}
.pro-badge.tm-conf{background:var(--pro-up);color:#03150e}.pro-badge.tm-early{background:#241f4a;border-color:#6a5fd0;color:#c3baff}.pro-badge.tm-wait{background:#1a2736;border-color:#2a3d54;color:#8fa4bd}
.pro-trig{display:grid;grid-template-columns:16px auto 1fr;gap:6px;align-items:baseline;font-size:11.5px}.pro-trig i{font-style:normal;color:#c3baff}.pro-trig em{font-style:normal;font-size:10.5px;color:#6f89a6}
.pro-tc-need{font-size:11px;color:#8fa4bd;line-height:1.5}
.pro-btn.sm-open{padding:5px 10px;min-height:30px;font-size:11px;margin-left:auto}
.pro-d-head .pro-d-price{margin-left:8px}

/* ---- direction-aware state labels: EXECUTE long/short share one look, EARLY keeps its violet with a small green/red accent */
.pro-badge.st-execute-long{background:var(--pro-up);color:#03150e}
.pro-badge.st-execute-short{background:var(--pro-dn);color:#2a0710}
.pro-badge.st-early-long{background:#1b1f45;border-color:#2fbf86;color:#a9f5d3;box-shadow:inset 3px 0 0 #24d18f}
.pro-badge.st-early-short{background:#26194a;border-color:#d4505f;color:#ffc2cb;box-shadow:inset 3px 0 0 #ff6174}
.pro-grid-head.sig,.pro-row:not(.board){grid-template-columns:minmax(128px,1.2fr) 50px 112px 38px 112px minmax(160px,1.6fr) 44px 74px 58px 44px 52px}
.pro-levels{border:1px solid #1d3149;background:#0a1626;border-radius:10px;padding:9px 11px;display:grid;gap:6px}
.pro-lvgrid{display:flex;flex-wrap:wrap;gap:5px}
.pro-lv{font:600 10.5px var(--pro-mono);padding:3px 7px;border-radius:6px;border:1px solid #234060;background:#081423;color:#b9c9dc;white-space:nowrap}
.pro-lv b{font-weight:800;color:#e6f1ff}.pro-lv i{font-style:normal;color:#6f89a6}.pro-lv.up{border-color:#5a3a22}.pro-lv.dn{border-color:#1d4a63}.pro-lv.orb{border-color:#2c6aa8;color:#8cc6ff}

/* instruments that already hold their maximum open trades: greyed out, not executable */
.pro-row.is-full{opacity:.42;filter:grayscale(.9)}.pro-row.is-full:hover{opacity:.7}
.pro-badge.slot-full{background:#1b2431;border:1px dashed #4a5d75;color:#9fb1c7;letter-spacing:.04em}
