:root{--tcc-shell-bg:#071018;--tcc-shell-panel:#0b1720;--tcc-shell-line:#263c4a;--tcc-shell-text:#edf6fa;--tcc-shell-muted:#91a6b2;--tcc-shell-green:#55f29a;--tcc-shell-yellow:#ffc857;--tcc-shell-red:#ff5268}
.tcc-shell{position:sticky;top:0;z-index:10000;display:grid;grid-template-columns:minmax(270px,max-content) minmax(0,1fr) minmax(170px,max-content);align-items:center;gap:10px;min-height:78px;padding:10px clamp(14px,2vw,30px);background:rgba(7,16,24,.98);border-bottom:1px solid var(--tcc-shell-line);box-shadow:0 12px 30px rgba(0,0,0,.3);backdrop-filter:blur(16px)}
.tcc-shell-home{display:flex;align-items:center;gap:11px;min-width:0;margin-right:12px;color:var(--tcc-shell-text);background:transparent;border:0;text-align:left;cursor:pointer;padding:0}.tcc-shell-home img{width:52px;height:52px;object-fit:contain;flex:0 0 auto}.tcc-shell-brand{min-width:0}.tcc-shell-brand strong{display:block;font-size:clamp(.82rem,1.1vw,1rem);letter-spacing:.09em;white-space:nowrap}.tcc-shell-brand strong span{color:var(--tcc-shell-green)}.tcc-shell-brand small{display:block;color:var(--tcc-shell-muted);margin-top:3px;letter-spacing:.04em}
.tcc-shell-nav{display:flex;align-items:center;justify-content:center;gap:7px;min-width:0}.tcc-menu{position:relative}.tcc-menu-toggle,.tcc-shell-account,.tcc-shell-pretrade{min-height:42px;padding:0 13px;border:1px solid transparent;border-radius:9px;background:transparent;color:var(--tcc-shell-text);font-weight:850;letter-spacing:.045em;cursor:pointer}.tcc-shell-pretrade{white-space:nowrap;color:var(--tcc-shell-green)!important;border-color:rgba(85,242,154,.34)!important;background:rgba(85,242,154,.08)!important;font-size:.78rem!important}.tcc-menu-toggle:hover,.tcc-menu-toggle:focus-visible,.tcc-menu.open>.tcc-menu-toggle,.tcc-shell-account:hover,.tcc-shell-account:focus-visible,.tcc-shell-pretrade:hover,.tcc-shell-pretrade:focus-visible{border-color:var(--tcc-shell-green)!important;background:rgba(85,242,154,.16)!important;outline:none}.tcc-menu-toggle::after{content:'▾';margin-left:8px;color:var(--tcc-shell-green)}
.tcc-menu-panel{display:none;position:absolute;top:calc(100% + 8px);left:50%;transform:translateX(-50%);min-width:280px;padding:8px;background:#08141d;border:1px solid var(--tcc-shell-line);border-radius:12px;box-shadow:0 18px 45px rgba(0,0,0,.48)}.tcc-menu.open>.tcc-menu-panel{display:grid}.tcc-menu-panel a,.tcc-menu-panel button{display:flex;align-items:center;width:100%;min-height:46px;padding:9px 11px;border:0;border-radius:8px;background:transparent;color:var(--tcc-shell-text);font:inherit;font-weight:750;text-decoration:none;text-align:left;cursor:pointer}.tcc-menu-panel a:hover,.tcc-menu-panel a:focus-visible,.tcc-menu-panel button:hover,.tcc-menu-panel button:focus-visible,.tcc-menu-panel [aria-current="page"]{background:rgba(85,242,154,.1);color:var(--tcc-shell-green);outline:none}.tcc-menu-panel small{display:block;color:var(--tcc-shell-muted);font-weight:500;margin-top:2px}
.tcc-shell-status{display:flex;justify-content:flex-end;align-items:center;gap:9px;color:var(--tcc-shell-muted);font-size:.75rem;text-align:right}.tcc-shell-status b{display:block;color:var(--tcc-shell-text);font-size:.82rem}.tcc-shell-dot{width:8px;height:8px;border-radius:50%;background:var(--tcc-shell-green);box-shadow:0 0 12px var(--tcc-shell-green)}
.tcc-admin-qa-launch{display:none;position:fixed;right:14px;bottom:14px;z-index:11000;min-height:44px;border:1px solid var(--tcc-shell-yellow);border-radius:999px;padding:0 16px;background:#121b20;color:var(--tcc-shell-yellow);font-weight:900;cursor:pointer}.tcc-admin-qa-launch[data-authorized="true"]{display:block}
#tccGlobalQaLauncher{display:none!important}body:not(.tcc-admin-authorized) #qaInspector,body:not(.tcc-admin-authorized) .tccsj-card:has(#tccsjRunQa){display:none!important}
.tcc-command-center{padding:clamp(18px,3vw,36px);max-width:1400px;margin:0 auto}.tcc-command-welcome{border:1px solid var(--tcc-shell-line);border-radius:16px;padding:clamp(20px,4vw,42px);background:linear-gradient(135deg,rgba(85,242,154,.1),rgba(10,15,24,.94) 55%);margin-bottom:18px}.tcc-command-welcome small{color:var(--tcc-shell-green);font-weight:900;letter-spacing:.13em}.tcc-command-welcome h1{font-size:clamp(2rem,5vw,4rem);margin:.25em 0 .15em}.tcc-command-welcome p{color:var(--tcc-shell-muted);max-width:720px}.tcc-command-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}.tcc-command-card{display:block;border:1px solid var(--tcc-shell-line);border-radius:14px;padding:20px;background:var(--tcc-shell-panel);color:var(--tcc-shell-text);text-decoration:none;transition:.16s}.tcc-command-card:hover,.tcc-command-card:focus-visible{border-color:var(--tcc-shell-green);transform:translateY(-2px);outline:none}.tcc-command-card b{display:block;font-size:1.08rem}.tcc-command-card span{display:block;color:var(--tcc-shell-muted);margin-top:8px;line-height:1.45}
body.tcc-shell-ready>.app>header.topbar,body.tcc-shell-ready>header.topbar,body.tcc-shell-ready .app>header.topbar{display:none!important}body.tcc-shell-ready .tcc-banner-wrap{display:none!important}
@media(max-width:1180px){.tcc-shell{grid-template-columns:1fr auto}.tcc-shell-status{display:none}.tcc-shell-nav{justify-content:flex-end}.tcc-shell-home{margin-right:0}.tcc-shell-brand strong{white-space:normal}.tcc-command-grid{grid-template-columns:1fr}}
@media(max-width:720px){.tcc-shell{position:relative;grid-template-columns:1fr;padding:10px}.tcc-shell-home{justify-content:center}.tcc-shell-nav{display:grid;grid-template-columns:repeat(2,1fr);width:100%}.tcc-menu,.tcc-shell-account,.tcc-shell-pretrade{width:100%}.tcc-menu-toggle,.tcc-shell-account,.tcc-shell-pretrade{width:100%}.tcc-menu-panel{position:fixed;left:10px;right:10px;top:142px;transform:none;min-width:0}.tcc-command-welcome{text-align:center}}
.tcc-command-overview{display:grid;grid-template-columns:1.4fr 1fr 1fr;gap:14px;margin-top:14px}.tcc-command-panel{border:1px solid var(--tcc-shell-line);border-radius:14px;padding:18px;background:var(--tcc-shell-panel)}.tcc-command-panel h2{font-size:.8rem;letter-spacing:.1em;margin:0 0 12px}.tcc-command-panel strong{font-size:1.1rem}.tcc-command-panel p,.tcc-command-panel small{color:var(--tcc-shell-muted);line-height:1.5}.tcc-command-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px}.tcc-command-actions a{border:1px solid var(--tcc-shell-line);border-radius:8px;padding:8px 10px;color:var(--tcc-shell-text);text-decoration:none}.tcc-command-actions a:hover{border-color:var(--tcc-shell-green);color:var(--tcc-shell-green)}
@media(max-width:1050px){.tcc-command-overview{grid-template-columns:1fr}}
.tcc-shell-companion{min-height:42px;padding:0 13px;border:1px solid rgba(91,204,216,.36);border-radius:9px;background:rgba(91,204,216,.08);color:#c8f3ec;font-size:.74rem;font-weight:850;letter-spacing:.045em;white-space:nowrap;cursor:pointer}.tcc-shell-companion:hover,.tcc-shell-companion:focus-visible{border-color:var(--tcc-shell-green);background:rgba(85,242,154,.16);outline:none}@media(max-width:720px){.tcc-shell-companion{width:100%}}
/* Header alignment guard: brand, navigation, and workspace status each retain their own column. */
@media(min-width:1181px){.tcc-shell{grid-template-columns:minmax(350px,1fr) max-content minmax(200px,1fr);gap:clamp(14px,2vw,30px);padding-inline:clamp(20px,2.8vw,40px)}.tcc-shell-home{min-width:350px;margin-right:0}.tcc-shell-nav{gap:9px;white-space:nowrap}.tcc-shell-status{min-width:200px}}
@media(min-width:721px) and (max-width:1180px){.tcc-shell{grid-template-columns:minmax(310px,1fr) max-content;gap:18px;padding-inline:20px}.tcc-shell-nav{gap:8px;white-space:nowrap}.tcc-shell-brand strong{white-space:nowrap}}

/* RC layout repair (desktop/tablet only; the <=720px mobile layout above is intentionally untouched).
   The header used a rigid 3-column grid with a no-wrap navigation, so on pages with extra buttons it grew wider
   than the window and pushed the account/status chip off-screen. It now wraps onto a second row instead. */
@media(min-width:721px){
  .tcc-shell{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px clamp(10px,1.6vw,24px);box-sizing:border-box;width:100%;max-width:100%}
  .tcc-shell-home{flex:0 1 auto;min-width:0;margin-right:0}
  .tcc-shell-nav{flex:1 1 auto;min-width:0;flex-wrap:wrap;justify-content:center;white-space:normal;row-gap:6px}
  .tcc-shell-status{flex:0 1 auto;min-width:0;max-width:100%;flex-wrap:wrap}
}
@media(min-width:721px) and (max-width:1180px){
  .tcc-shell-status{display:none}
  .tcc-shell-nav{justify-content:flex-end}
}

/* RC layout repair (Prop Firm Drawdown Guard at tablet width): let form grids shrink and let the FX status badge wrap,
   so nothing pushes the page wider than the window. Selectors only exist on that page. */
@media(max-width:900px){#riskDesk .workspace,#riskDesk .stack,#riskDesk .card,#riskDesk .grid>*,#riskDesk .field{min-width:0}#riskDesk .field input,#riskDesk .field select,#riskDesk .field textarea{min-width:0;max-width:100%}}
#riskDesk #fxRateStatus{white-space:normal;overflow-wrap:anywhere;max-width:100%}

/* Drawdown Guard: state shown until the trader's real account numbers are in (never a clearance). */
.verdict[data-status="AWAITING_DATA"]{border-color:var(--tcc-shell-yellow,#ffc857)}
.verdict[data-status="AWAITING_DATA"] strong{color:var(--tcc-shell-yellow,#ffc857)}
#tccConfirmAccount{margin-top:10px;min-height:38px;padding:0 12px;border:1px solid #ffc857;border-radius:8px;background:rgba(255,200,87,.1);color:#ffe3a3;font:inherit;font-weight:800;letter-spacing:.04em;cursor:pointer}
#tccConfirmAccount:hover,#tccConfirmAccount:focus-visible{background:rgba(255,200,87,.2);outline:none}
#tccConfirmAccount[hidden]{display:none}

/* ===== TDC navigation: Commander Jade link + operating-cycle row (CALCULATE -> CONTROL -> CONQUER -> RECORD -> REVIEW) ===== */
.tdc-shell-jade{display:inline-flex;align-items:center;min-height:42px;padding:0 13px;border:1px solid rgba(186,140,255,.38);border-radius:9px;background:rgba(186,140,255,.08);color:#e5d6ff;font-size:.74rem;font-weight:850;letter-spacing:.045em;white-space:nowrap;text-decoration:none}
.tdc-shell-jade:hover,.tdc-shell-jade:focus-visible,.tdc-shell-jade[aria-current="page"]{border-color:#c9a5ff;background:rgba(186,140,255,.18);outline:none}
.tdc-cycle{grid-column:1/-1;flex:1 0 100%;box-sizing:border-box;width:100%;max-width:100%;display:flex;align-items:center;justify-content:center;gap:4px;margin:2px 0 0;padding:6px 8px;border:1px solid var(--tcc-shell-line);border-radius:11px;background:rgba(4,10,15,.55)}
.tdc-cycle .tcc-menu-toggle,.tdc-cycle-home{min-height:36px;padding:0 12px;font-size:.76rem;letter-spacing:.11em}
.tdc-cycle-home{display:inline-flex;align-items:center;border:1px solid transparent;border-radius:9px;color:var(--tcc-shell-text);font-weight:850;text-decoration:none;margin-right:6px}
.tdc-cycle-home:hover,.tdc-cycle-home:focus-visible,.tdc-cycle-home[aria-current="page"]{border-color:var(--tcc-shell-line);color:var(--tcc-shell-green);outline:none}
.tdc-cycle .tdc-step+.tdc-step::before{content:'›';position:absolute;left:-6px;top:50%;transform:translateY(-50%);color:var(--tcc-shell-green);opacity:.6;font-weight:900;pointer-events:none}
.tdc-cycle .tdc-step{margin-left:4px}
.tdc-cycle .tdc-more{margin-left:10px}
.tdc-cycle .tdc-more .tcc-menu-panel{left:auto;right:0;transform:none}
.tdc-cycle .tcc-menu-panel button[data-tdc-click]{text-align:left}
@media(max-width:1180px){.tdc-cycle{flex-wrap:wrap;row-gap:4px}.tdc-cycle .tdc-step{margin-left:2px}}
@media(max-width:720px){
  .tdc-cycle{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;margin:4px 0 0;padding:8px;overflow:visible}
  .tdc-cycle-home{grid-column:1/-1;justify-content:center;margin:0;border-color:var(--tcc-shell-line)}
  .tdc-cycle .tcc-menu,.tdc-cycle .tcc-menu-toggle{width:100%;margin:0}
  .tdc-cycle .tdc-step+.tdc-step::before{display:none}
  .tdc-shell-jade{width:100%;justify-content:center}
  .tdc-cycle .tcc-menu-panel{position:fixed;top:auto;left:10px;right:10px;transform:none;max-height:70vh;overflow:auto}
}
html[data-tcc-theme-resolved="light"] .tdc-cycle{background:rgba(226,233,238,.9)}
html[data-tcc-theme-resolved="light"] .tdc-shell-jade{color:#4b2a86;background:rgba(130,80,210,.08);border-color:rgba(110,60,190,.35)}
