/* Trade Ladder view (web/static/js/trade_ladder.js): order-row pill and the perspective ladder modal. */
.tl-pill {
    display: inline-flex; align-items: center; justify-content: center;
    font: 600 12px/1 "Inter", "Segoe UI", ui-sans-serif, system-ui, Roboto, sans-serif;
    letter-spacing: .02em; color: #cfe3ff; background: #1e3a5c;
    border: 1px solid #3d6a99; border-radius: 999px; padding: 4px 11px; min-height: 24px;
    cursor: pointer; white-space: nowrap; vertical-align: middle;
}
.tl-pill:hover { background: #27507d; color: #ffffff; }
.tl-pill:focus-visible { outline: 2px solid #6cb6ff; outline-offset: 2px; }

.tl-overlay {
    position: fixed; inset: 0; z-index: 100000; display: none;
    align-items: flex-start; justify-content: center; overflow-y: auto;
    background: rgba(3, 7, 12, .78); padding: 3vh 12px; box-sizing: border-box;
    -webkit-overflow-scrolling: touch;
}
.tl-overlay.tl-open { display: flex; }
.tl-modal {
    position: relative; width: 100%; max-width: 760px; box-sizing: border-box;
    background: radial-gradient(ellipse at 50% 30%, #14263a 0%, #0b1119 72%);
    border: 1px solid rgba(108, 182, 255, .18); border-radius: 18px;
    box-shadow: 0 24px 70px rgba(0, 0, 0, .6);
    padding: 18px 20px 14px; color: #e8eef4;
    font-family: "Inter", "Segoe UI", ui-sans-serif, system-ui, Roboto, sans-serif;
}
.tl-modal * { box-sizing: border-box; }
.tl-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.tl-ttl { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-size: 14px; font-weight: 600; color: #b8c6d4; letter-spacing: .02em; min-width: 0; }
.tl-kind { font-weight: 700; font-size: 12px; letter-spacing: .08em; padding: 3px 9px; border: 1px solid; border-radius: 999px; }
.tl-kind:empty { display: none; }
.tl-contract { color: #eef3f8; font-weight: 700; font-variant-numeric: tabular-nums; }
.tl-strat { color: #b8c6d4; }
.tl-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.tl-btn {
    background: #1e3a5c; color: #ffffff; border: 1px solid #3d6a99; border-radius: 999px;
    padding: 8px 22px; font-family: inherit; font-size: 13px; font-weight: 700; line-height: 1; letter-spacing: .06em; cursor: pointer; min-width: 92px;
}
.tl-btn:hover { background: #27507d; }
.tl-x {
    width: 34px; height: 34px; border-radius: 999px; border: 1px solid #2c4258; background: #0f1b28;
    color: #c9d4de; font-size: 22px; line-height: 1; cursor: pointer; padding: 0;
}
.tl-x:hover { background: #1b2d40; color: #ffffff; }
.tl-btn:focus-visible, .tl-x:focus-visible, .tl-scrub:focus-visible { outline: 2px solid #6cb6ff; outline-offset: 2px; }
.tl-bar2 { align-items: flex-end; }
.tl-note { font-size: 13px; color: #a7b4c1; margin: 2px 0 4px; }
.tl-pxwrap { display: flex; align-items: baseline; gap: 8px; }
.tl-idx { font-size: 13px; font-weight: 700; color: #93a3b3; letter-spacing: .08em; }
.tl-px { font-size: 30px; font-weight: 700; font-variant-numeric: tabular-nums; color: #ffffff; letter-spacing: .01em; }
.tl-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.tl-fill { font-size: 13px; font-weight: 600; color: #b8c6d4; font-variant-numeric: tabular-nums; }
.tl-clk { font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; color: #b8c6d4; }
.tl-stage { position: relative; }
.tl-svg { width: 100%; height: auto; display: block; }
.tl-msg { font-size: 15px; font-weight: 500; color: #f5d38a; padding: 34px 6px; line-height: 1.5; text-align: center; }
.tl-scrub { width: 100%; margin: 6px 0 2px; accent-color: #6cb6ff; height: 22px; cursor: pointer; }
.tl-log { font-size: 14px; color: #c9b27a; min-height: 64px; margin-top: 4px; line-height: 1.5; font-weight: 500; }
.tl-log div { padding: 1px 0; }
.tl-log b { font-variant-numeric: tabular-nums; font-weight: 700; }
.tl-log .tl-now { color: #f5d38a; }
.tl-log .tl-linked { color: #cfe3ff; }
.tl-log .tl-now.tl-linked { color: #e6f1ff; }
.tl-legend { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 13px; color: #c9d4de; margin-top: 8px; font-weight: 500; }
.tl-legend i { display: inline-block; width: 22px; height: 8px; border-radius: 999px; margin-right: 7px; vertical-align: middle; }
.tl-dia { display: inline-block; width: 9px; height: 9px; transform: rotate(45deg); border-radius: 2px; margin-right: 7px; vertical-align: middle; }

@media (max-width: 560px) {
    .tl-overlay { padding: 8px 6px; }
    .tl-modal { padding: 12px 10px 12px; border-radius: 14px; }
    .tl-ttl { font-size: 13px; }
    .tl-btn { padding: 8px 14px; min-width: 76px; }
    .tl-px { font-size: 26px; }
    .tl-log { font-size: 14px; }
    .tl-legend { gap: 6px 14px; }
}
