.trader-pnl-cell{min-width:0;}
.trader-pnl-cell .trader-pos-pnl{min-width:0;max-width:100%;overflow-wrap:anywhere;}
.trader-pnl-heading{display:flex;align-items:center;gap:6px;min-width:0;max-width:100%;}
.trader-pnl-heading>span{min-width:0;overflow-wrap:anywhere;}
.trader-pnl-cell .trader-pos-pnl small{white-space:normal;overflow-wrap:anywhere;}
.trader-pos-table.trader-history-table{table-layout:auto;}
.trader-pos-table.trader-history-table col[class]{width:auto;}
.trader-pos-table.trader-history-table td{padding:7px 8px;vertical-align:middle;}
.trader-pos-table.trader-history-table th{padding-right:8px;padding-left:8px;}
.trader-history-table .trader-pnl-cell{width:max-content;max-width:240px;}
.trader-history-table .trader-pos-pair-btn{max-width:180px;}
.trader-pos-table.trader-history-table .trader-history-cell{max-width:180px;overflow-wrap:anywhere;}
.trader-history-table th:nth-child(11){text-align:center;}
.trader-pnl-share{flex:0 0 24px;width:24px;height:18px;display:inline-flex;align-items:center;justify-content:center;padding:0;border:0;border-radius:4px;background:transparent;cursor:pointer;opacity:.65;}
.trader-pnl-share:hover,.trader-pnl-share:focus-visible{opacity:1;background:#ffffff1a;}
.trader-pnl-share img{display:block;width:18px;height:18px;opacity:.7;}
.trader-night .trader-pnl-share img{filter:invert(1);}
.trader-pnl-share svg,.pnl-share-dialog button svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0;}
.trader-history-action{flex-wrap:wrap;gap:6px;}
:is(.mob-trader-host, html.tablet-boot #trader-root) .trader-pos-table { min-width: 1200px; }
:is(.mob-trader-host, html.tablet-boot #trader-root) .trader-pos-table:not(.trader-history-table) col.trader-col-pnl { width: 220px; }
:is(.mob-trader-host, html.tablet-boot #trader-root) .trader-history-table .trader-pnl-cell { max-width: 220px; }
:is(.mob-trader-host, html.tablet-boot #trader-root) .trader-pos-pnl { min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
:is(.mob-trader-host, html.tablet-boot #trader-root) .trader-pnl-share { flex: 0 0 32px; width: 32px; height: 32px; opacity: .8; border: 0; border-radius: 4px; }
:is(.mob-trader-host, html.tablet-boot #trader-root) .trader-pnl-share img { opacity: 1; }
.trader-api-loader{position:fixed;inset:0;width:100vw;height:100dvh;max-width:none;max-height:none;margin:0;padding:0;border:0;background:rgba(8,8,8,.2);color:#eee;font:16px Arial,sans-serif;overflow:auto;text-shadow:0 2px 6px #000;}
.trader-api-loader::backdrop{background:#0003;backdrop-filter:blur(6px);}
.trader-api-loader-root>div{position:fixed;inset:0;display:flex;align-items:center;justify-content:center;}
.trader-api-loader-root>div>div:first-child{position:relative;z-index:1;width:min(520px,calc(100vw - 48px));height:320px;overflow:hidden;mask-image:linear-gradient(to bottom,transparent,#000 22%,#000 74%,transparent);}
.trader-api-loader-root>div>div:first-child>div{position:relative;display:flex;flex-direction:column;margin:140px auto 0;max-width:520px;}
.trader-api-loader-root>div>div:first-child>div>div{display:flex;align-items:center;justify-content:center;gap:12px;height:40px;flex-shrink:0;margin:0;text-align:left;color:#ccc;}
.trader-api-loader-root>div>div:first-child>div>div>div{display:flex;width:24px;height:24px;flex-shrink:0;align-items:center;justify-content:center;}
.trader-api-loader-root svg{display:block;width:24px;height:24px;}
.trader-api-loader-root .api-loader-current{color:#b4e536!important;}
.trader-api-loader-root .api-loader-done{color:#eee!important;}
.trader-api-loader-root .api-loader-error{color:#ff7180!important;}
.api-loader-ring{display:block;box-sizing:border-box;width:22px;height:22px;border:2px solid currentColor;border-radius:50%;}
.api-loader-spinner{border-right-color:transparent;animation:trader-api-spin .8s linear infinite;}
.trader-api-loader-root>div>div:last-child{display:none;}
.trader-api-loader.is-finished{cursor:pointer;}
.trader-api-loader:focus{outline:none;}
@keyframes trader-api-spin{to{transform:rotate(360deg);}}
@media(prefers-reduced-motion:reduce){.api-loader-spinner{animation:none;}.trader-api-loader-root>div>div:first-child>div>div{transform:none!important;}}
.pnl-share-dialog{position:fixed;inset:0;margin:0;width:100vw;height:100dvh;max-width:none;max-height:none;padding:24px 0 max(16px,env(safe-area-inset-bottom));border:0;border-radius:0;background:transparent;color:#f4f5ef;box-shadow:none;font:14px Arial,sans-serif;overflow:auto;overscroll-behavior:contain;}
.pnl-share-dialog[open]{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;gap:12px;}
.pnl-share-dialog::backdrop{background:rgba(0,0,0,.78);backdrop-filter:blur(8px);}
.pnl-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap;}
.pnl-share-dialog button{font:600 13px Arial,sans-serif;color:inherit;cursor:pointer;}
.pnl-share-dialog button:disabled{opacity:.4;cursor:wait;}
.pnl-share-dialog button:focus-visible,.pnl-share-dialog input:focus-visible+span{outline:2px solid #dcff00;outline-offset:4px;}
.pnl-share-close{position:fixed;top:max(12px,env(safe-area-inset-top));right:16px;z-index:5;display:grid;place-items:center;width:36px;height:36px;padding:8px;background:#252b28;border:1px solid #49514b;border-radius:8px;}
.pnl-share-stage{flex-shrink:0;width:100%;padding:12px 24px 4px;}
.pnl-share-surface{position:relative;aspect-ratio:10/11;margin:auto;width:min(480px,100%);}
html.mobile-boot .pnl-share-stage { margin-top: auto; }
html.mobile-boot .pnl-controls-row { margin-bottom: auto; }
.pnl-notch[hidden]{display:none;}
.pnl-controls-row{display:grid;grid-template-columns:minmax(0,280px) 272px;align-items:end;justify-content:center;gap:28px;flex-shrink:0;width:min(640px,calc(100vw - 32px));padding-top:32px;margin-bottom:40px;}
.pnl-notch-host{position:relative;z-index:3;min-width:0;height:64px;}
.pnl-notch-host>div{position:absolute!important;inset:auto 0 8px!important;display:flex;justify-content:center;padding:0!important;pointer-events:none;}
.pnl-original-notch{display:flex;flex-direction:column;width:fit-content;max-width:calc(100vw - 32px);overflow:hidden;border:1px solid #303030;border-radius:12px;background:rgba(10,10,10,.95);box-shadow:0 12px 40px -8px #0009;backdrop-filter:blur(24px);pointer-events:auto;}
.pnl-original-notch>div:not(.pnl-original-notch-panel){display:flex;align-items:center;gap:4px;padding:4px;}
.pnl-original-notch-trigger{display:flex;align-items:center;gap:8px;padding:8px 12px;border:0;border-radius:24px;background:transparent;color:#d4d4d4;white-space:nowrap;}
.pnl-original-notch-trigger:hover{background:#ffffff0f;color:#fff;}
.pnl-original-notch>div>span[aria-hidden]{width:1px;height:20px;flex-shrink:0;margin:0 2px;align-self:center;}
.pnl-original-notch-panel{width:fit-content;max-width:100%;}
.pnl-original-notch-panel>div{display:flex;flex-direction:column;gap:6px;padding:8px;}
.pnl-original-notch-panel button{display:flex;width:100%;align-items:center;justify-content:space-between;gap:24px;padding:8px 12px;border:0;border-radius:6px;background:transparent;color:#d4d4d4;text-align:left;white-space:nowrap;}
.pnl-original-notch-panel button:hover{background:#ffffff0d;color:#fff;}
.pnl-original-notch-panel button>span:first-child{display:flex;align-items:center;gap:10px;}
.pnl-original-notch-panel button>span:last-child:not(:first-child){width:6px;height:6px;border-radius:50%;flex-shrink:0;}
.pnl-share-surface canvas{display:block;width:100%;height:100%;border-radius:16px;}
.pnl-comet-host{position:absolute;inset:0;}
.pnl-comet-host>.perspective-distant{perspective:1200px;width:100%;height:100%;}
.pnl-comet-host>.transform-3d{transform-style:preserve-3d;}
.pnl-comet-host>.perspective-distant>.relative{position:relative;width:100%;height:100%;border-radius:16px;}
.pnl-comet-content{width:100%;height:100%;}
.pnl-comet-host .pointer-events-none{position:absolute;inset:0;z-index:50;width:100%;height:100%;border-radius:16px;mix-blend-mode:overlay;pointer-events:none;}
.pnl-share-status{max-width:360px;padding:0 16px;font-size:12px;line-height:1.5;color:#d0d7d2;text-align:center;}
.pnl-share-status:empty{display:none;}
.pnl-floating{position:relative;flex-shrink:0;width:100%;height:64px;margin:0;}
.pnl-share-bubbles{position:absolute;z-index:5;left:0;top:0;width:0;height:0;visibility:hidden;pointer-events:none;}
.pnl-share-bubbles.is-open{visibility:visible;pointer-events:auto;}
.pnl-floating .pnl-share-bubbles button{position:absolute;left:-24px;top:-24px;display:grid;place-items:center;width:48px;height:48px;padding:0;border:1px solid #555;border-radius:50%;background:#262626;color:#f5f5f5;box-shadow:0 6px 20px #0009;opacity:0;transform:translate(0,0) scale(.4);transition:transform .25s cubic-bezier(.2,.8,.2,1.2),opacity .15s;}
.pnl-floating .pnl-share-bubbles.is-open button{opacity:1;}
.pnl-floating .pnl-share-bubbles button:focus-visible{outline:2px solid #ddd;outline-offset:3px;}
.pnl-share-bubbles.is-open button:nth-child(1){transform:translate(-92px,-64px) scale(var(--bubble-scale,1));}
.pnl-share-bubbles.is-open button:nth-child(2){transform:translate(-38px,-112px) scale(var(--bubble-scale,1));transition-delay:35ms;}
.pnl-share-bubbles.is-open button:nth-child(3){transform:translate(28px,-88px) scale(var(--bubble-scale,1));transition-delay:70ms;}
@media(hover:hover) and (pointer:fine){.pnl-share-bubbles.is-open button:hover{--bubble-scale:1.15;}}
.pnl-share-bubbles img{width:24px;height:24px;filter:invert(1);}
.pnl-share-bubbles button span{position:absolute;top:calc(100% + 5px);left:50%;transform:translateX(-50%);padding:3px 5px;border-radius:4px;background:#171717;color:#eee;font-size:10px;white-space:nowrap;pointer-events:none;}
@media(prefers-reduced-motion:reduce){.pnl-share-bubbles button{transition:none;}}
@media(max-width:767px){.pnl-share-bubbles.is-open button:nth-child(1){transform:translate(-92px,-58px) scale(var(--bubble-scale,1));}.pnl-share-bubbles.is-open button:nth-child(2){transform:translate(-62px,-120px) scale(var(--bubble-scale,1));}.pnl-share-bubbles.is-open button:nth-child(3){transform:translate(-8px,-174px) scale(var(--bubble-scale,1));}}
.pnl-floating-host{display:flex;justify-content:center;align-items:flex-end;width:100%;height:100%;}
.pnl-floating button{padding:0;border:0;background:transparent;color:#d4d4d4;}
.pnl-floating-desktop{box-sizing:border-box;display:flex;align-items:flex-end;gap:16px;height:64px;margin:0 auto;padding:0 16px 12px;border:0;border-radius:16px;background:#171717;}
.pnl-floating-desktop>button{flex-shrink:0;}
.pnl-floating-desktop>button>.relative{position:relative;display:flex;align-items:center;justify-content:center;aspect-ratio:1;border-radius:50%;background:#262626;}
.pnl-floating-desktop>button>.relative>div:not(.absolute){display:flex;align-items:center;justify-content:center;}
.pnl-floating-desktop .absolute{position:absolute;top:calc(100% + 16px);left:50%;width:max-content;max-width:190px;padding:5px 8px;border:1px solid #171717;border-radius:6px;background:#262626;color:#f5f5f5;font-size:11px;white-space:pre;pointer-events:none;}
.pnl-floating-icon{display:flex;width:100%;height:100%;align-items:center;justify-content:center;}
.pnl-floating .pnl-floating-icon svg{width:100%;height:100%;}
.pnl-floating-mobile{display:none;position:relative;}
.pnl-floating-mobile>.absolute{position:absolute;inset-inline:0;bottom:100%;margin-bottom:8px;display:flex;flex-direction:column;gap:8px;}
.pnl-floating-mobile button{display:flex;align-items:center;justify-content:center;width:40px;height:40px;border-radius:50%;background:#262626;}
.pnl-floating-mobile button>div{width:20px;height:20px;}
.pnl-floating-mobile>button>span{display:flex;width:20px;height:20px;}
@media(max-width:767px){
  .pnl-controls-row{grid-template-columns:minmax(0,1fr);gap:12px;align-items:center;justify-items:center;padding-top:8px;margin-bottom:24px;}
  .pnl-notch-host{width:100%;height:52px;}
  .pnl-notch-host>div{bottom:0!important;}
  .pnl-original-notch>div:not(.pnl-original-notch-panel){flex-wrap:nowrap;justify-content:center;}
  .pnl-original-notch-trigger{font-size:13px!important;min-height:44px;padding:10px 14px;}
  .pnl-original-notch-panel button{min-height:44px;}
  .pnl-floating{width:272px;height:64px;}
  .pnl-floating-desktop{display:flex;gap:16px;align-items:center;padding:10px 16px;height:64px;border-radius:8px;}
  .pnl-floating-desktop>button>.relative{width:44px!important;height:44px!important;}
  .pnl-floating-desktop>button>.relative>div:not(.absolute){width:22px!important;height:22px!important;}
  .pnl-floating-mobile{display:none;}
}
@media(prefers-reduced-motion:reduce){.pnl-floating-desktop>button>.relative{width:40px!important;height:40px!important;}.pnl-floating-desktop>button>.relative>div:not(.absolute){width:20px!important;height:20px!important;}}
.pnl-dock{display:flex;align-items:center;justify-content:center;gap:16px;flex-shrink:0;min-height:66px;margin:4px 16px 0;padding:10px 18px;border:1px solid #4a514c;border-radius:20px;background:rgba(34,40,36,.94);box-shadow:0 12px 32px #0005;backdrop-filter:blur(16px);}
.pnl-dock button{position:relative;display:grid;place-items:center;flex:0 0 42px;width:42px;height:42px;padding:10px;border:0;border-radius:12px;background:#3c4540;transform:scale(var(--dock-scale,1));transform-origin:center bottom;transition:transform .15s ease-out,background .15s;}
.pnl-dock button svg{width:22px;height:22px;}
.pnl-dock button[data-pnl-download]{background:#dcff00;color:#111714;}
.pnl-dock button[aria-pressed="true"]{background:#ebefea;color:#111714;}
.pnl-dock-tooltip{position:absolute;bottom:calc(100% + 14px);left:50%;transform:translateX(-50%) translateY(4px);width:max-content;max-width:180px;padding:7px 10px;border:1px solid #4a514c;border-radius:6px;background:#151b17;color:#f4f5ef;font-size:11px;line-height:1.3;opacity:0;visibility:hidden;pointer-events:none;transition:opacity .15s,transform .15s;}
.pnl-dock button:focus-visible .pnl-dock-tooltip{opacity:1;visibility:visible;transform:translateX(-50%);}
.pnl-notch{position:relative;z-index:3;flex-shrink:0;max-width:calc(100vw - 32px);}
.pnl-notch-trigger{display:flex;align-items:center;justify-content:center;gap:12px;min-height:36px;max-width:min(340px,calc(100vw - 32px));padding:8px 18px;border:1px solid #424a44;border-radius:18px;background:#111714;box-shadow:0 4px 12px #0004;}
.pnl-notch-trigger span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.pnl-notch-trigger svg{width:14px!important;height:14px!important;transition:transform .2s;}
.pnl-notch-trigger[aria-expanded="true"] svg{transform:rotate(180deg);}
.pnl-notch-panel{position:absolute;bottom:calc(100% + 10px);left:50%;transform:translateX(-50%);width:min(340px,calc(100vw - 32px));max-height:50dvh;overflow-y:auto;overscroll-behavior:contain;padding:16px;border:1px solid #424a44;border-radius:16px;background:#151b17;box-shadow:0 12px 40px #0009;animation:pnl-notch-open .2s ease-out;}
.pnl-notch-panel[hidden]{display:none;}
.pnl-notch-panel fieldset{min-width:0;margin:0 0 14px;padding:0;border:0;}
.pnl-notch-panel fieldset:last-child{margin-bottom:0;}
.pnl-notch-panel legend{margin-bottom:10px;color:#afb9b1;font-size:12px;}
.pnl-notch-segments{display:flex;gap:6px;}
.pnl-notch-segments label{position:relative;flex:1;min-width:0;cursor:pointer;}
.pnl-notch-segments input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer;}
.pnl-notch-segments span{display:flex;align-items:center;justify-content:center;min-height:36px;padding:6px;border:1px solid #424a44;border-radius:7px;background:#262e28;font-size:12px;text-align:center;}
.pnl-notch-segments input:checked+span{background:#dcff00;border-color:#dcff00;color:#111714;}
@keyframes pnl-notch-open{from{opacity:0;transform:translateX(-50%) translateY(8px) scale(.96);}to{opacity:1;transform:translateX(-50%) translateY(0) scale(1);}}
@media(hover:hover) and (pointer:fine){.pnl-dock button:not(:disabled):hover .pnl-dock-tooltip{opacity:1;visibility:visible;transform:translateX(-50%);}.pnl-dock button:not(:disabled):hover{background:#536056;}.pnl-dock button[data-pnl-download]:not(:disabled):hover{background:#e9ff60;}}
@media(prefers-reduced-motion:reduce){.pnl-comet-host>.perspective-distant>.relative{transform:none!important;}.pnl-comet-host .pointer-events-none{display:none;}.pnl-dock button{transition:none;transform:none!important;}.pnl-notch-panel{animation:none;}.pnl-notch-trigger svg{transition:none;}}
@media(max-width:480px){.pnl-share-dialog{padding-top:44px;}.pnl-share-stage{padding:0 16px;}.pnl-share-surface{width:100%;}.pnl-dock{gap:18px;}.pnl-dock button{width:44px;height:44px;flex-basis:44px;}}
