/* BidDesk Quant for all (12 Oct 2026): the paper trading desk. The account's value first; the ticket beside it at desk
   width and under it on a phone; every money lane fixed, right-aligned and tabular. Gold for the member's own money. */
.pt-line { margin: 0 0 22px; padding: 10px 14px; border: 1px solid var(--line-2); border-left: 2px solid var(--gold); border-radius: var(--r-1); background: var(--surface); color: var(--ink-2); font-size: 13.5px; }
.pt-grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 28px; align-items: start; }
.pt-side { position: sticky; top: calc(var(--q-top, 64px) + 16px); }
.pt-main, .pt-side, .pt-sec, .pt-tw { min-width: 0; }
.pt-sum { container: ptsum / inline-size; padding: 22px 24px 18px; border: 1px solid var(--line); border-radius: var(--r-3); background: linear-gradient(180deg, var(--surface-2), var(--surface)); }
.pt-stamp { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 0 0 16px; }
.pt-paper { color: var(--gold); border-color: rgba(217, 164, 65, .45); }
.pt-k { margin: 0; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.pt-big { margin: 4px 0 2px; font: 300 46px/1.05 var(--serif); letter-spacing: -.02em; color: var(--ink); }
.pt-chg { margin: 0; font-size: 15px; color: var(--ink-2); }
.pt-chg span { margin-left: 6px; } .pt-chg em { font-style: normal; color: var(--ink-3); margin-left: 6px; font-size: 13px; }
.up { color: var(--go) !important; } .down { color: var(--kill) !important; }
.pt-figs { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 0; margin: 20px 0 0; border-top: 1px solid var(--line); }
.pt-figs > div { padding: 12px 12px 0 0; min-width: 0; }
.pt-figs > div + div { padding-left: 14px; border-left: 1px solid var(--line); }
.pt-figs dt { font-size: 12px; color: var(--ink-3); margin: 0 0 3px; }
.pt-figs dd { margin: 0; font-size: 15px; font-weight: 500; white-space: nowrap; }   /* a figure is never cut: the grid reflows instead (below) */
.pt-figs small, .pt-t small { display: block; font-size: 11.5px; font-weight: 400; color: var(--ink-3); white-space: nowrap; }
.pt-mkt { margin: 16px 0 0; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.pt-sec { margin-top: 28px; }
.pt-h { margin: 0 0 10px; font: 500 15px/1.3 var(--sans); color: var(--ink); display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.pt-h .faint { font-weight: 400; }
.pt-empty { margin: 0; padding: 18px; border: 1px dashed var(--line-2); border-radius: var(--r-2); }
.pt-tw { container: pttw / inline-size; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-2); }
.pt-t { width: 100%; border-collapse: collapse; font-size: 13.5px; table-layout: auto; }
.pt-t th, .pt-t td { padding: 10px 12px; text-align: right; border-bottom: 1px solid var(--line); vertical-align: top; white-space: nowrap; }
.pt-t thead th { font-size: 11.5px; font-weight: 500; letter-spacing: .04em; color: var(--ink-3); background: var(--bg-2); position: sticky; top: 0; }
.pt-t tbody tr:last-child > * { border-bottom: 0; }
.pt-t th[scope="row"], .pt-t thead th:first-child { text-align: left; }
/* Every lane an explicit width, sized to what it holds at 1440 (Qty 1000, ₹3,055.57, "target ₹3,357.15"); the layout is auto, so a
   figure wider than its lane widens the lane instead of being cut to "1…" or "₹3,05…", and never overlaps the next. */
.pt-pos th:nth-child(1) { width: 17%; } .pt-pos th:nth-child(2) { width: 8%; } .pt-pos th:nth-child(3), .pt-pos th:nth-child(4) { width: 12%; } .pt-pos th:nth-child(5) { width: 12%; }
.pt-pos th:nth-child(6) { width: 12%; } .pt-pos th:nth-child(7) { width: 16%; } .pt-pos th:nth-child(8) { width: 11%; }   /* 17% for the stock: a ten-letter NSE symbol whole at 1440 */
.pt-pos td.pt-ex { white-space: nowrap; }   /* "stop ₹2,899.35" and "target ₹3,357.15" each whole on its line */ .pt-figs small { white-space: normal; }
/* A table never narrower than these; a box under 640 px shows cards instead (end of file), so nothing is cut or scrolled away. */
.pt-pos { min-width: 600px; } .pt-ord { min-width: 440px; } .pt-led { min-width: 640px; }
.pt-sym { font-weight: 600; text-decoration: none; color: var(--ink); }
.pt-sym:hover { text-decoration: underline; text-underline-offset: 3px; }
.pt-ex { font-size: 12px; color: var(--ink-2); } .pt-ex small { white-space: normal; }
.pt-act .btn { height: 28px; }
.pt-side-t { font-size: 12px; font-weight: 600; } .pt-side-t.buy { color: var(--go); } .pt-side-t.sell { color: var(--kill); }
.pt-log summary { list-style: none; cursor: pointer; display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: baseline; }
.pt-log summary::-webkit-details-marker { display: none; }
.pt-log summary .pt-h { margin: 0; } .pt-log[open] summary { margin-bottom: 10px; }
.pt-chk { font-size: 12.5px; color: var(--go); } .pt-chk.bad { color: var(--kill); }
.pt-led th, .pt-led td { padding: 9px 8px; }
.pt-led th:nth-child(1) { width: 4%; } .pt-led th:nth-child(2) { width: 10%; } .pt-led th:nth-child(3) { width: 20%; } .pt-led th:nth-child(4) { width: 13%; }
.pt-led th:nth-child(5) { width: 6%; } .pt-led th:nth-child(6) { width: 12%; } .pt-led th:nth-child(7) { width: 9%; } .pt-led th:nth-child(8) { width: 15%; } .pt-led th:nth-child(9) { width: 11%; }
.pt-led td:nth-child(3), .pt-led td:nth-child(4), .pt-led th:nth-child(3), .pt-led th:nth-child(4) { text-align: left; white-space: normal; }
.pt-led td:nth-child(3) small { white-space: normal; } .pt-led td:nth-child(2) { white-space: normal; }   /* "12 Oct, 11:00" (a past session) wraps after its comma */
.pt-hash { font: 12px ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--ink-3); }
.pt-ticket { padding: 18px 18px 16px; border: 1px solid var(--line-2); border-radius: var(--r-3); background: var(--surface); display: grid; gap: 12px; }
.pt-ticket .pt-h { margin: 0; }
.pt-seg { display: grid; grid-template-columns: 1fr 1fr; padding: 3px; gap: 3px; border-radius: 999px; background: var(--bg-2); border: 1px solid var(--line); }
.pt-seg button { height: 34px; border: 0; border-radius: 999px; background: transparent; color: var(--ink-2); cursor: pointer; font-weight: 500; }
.pt-seg button[aria-pressed="true"] { background: var(--raise); color: var(--ink); box-shadow: 0 1px 0 rgba(241, 233, 216, .06) inset; }
.pt-seg button[data-side="buy"][aria-pressed="true"] { color: var(--go); } .pt-seg button[data-side="sell"][aria-pressed="true"] { color: var(--kill); }
.pt-f { display: grid; gap: 5px; min-width: 0; } .pt-f > span { font-size: 12px; color: var(--ink-3); }
.pt-f[hidden], .pt-exits[hidden] { display: none; }   /* a grid never outranks [hidden]: no limit price under Market, no exits on a sell */
.pt-two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pt-quote { margin: -4px 0 0; min-height: 18px; font-size: 12.5px; color: var(--ink-2); }
.pt-quote b { color: var(--ink); font-weight: 600; }
.pt-exits summary { cursor: pointer; font-size: 13px; color: var(--ink-2); } .pt-exits[open] summary { margin-bottom: 10px; }
.pt-rb { margin: 0; min-height: 40px; padding: 10px 12px; border-radius: var(--r-1); background: var(--bg-2); font-size: 13.5px; color: var(--ink-3); }
.pt-rb[data-ok="1"] { color: var(--ink); }
.pt-sme { margin: -6px 0 0; padding: 8px 12px; border-left: 2px solid var(--gold); border-radius: var(--r-1); background: var(--gold-soft); font-size: 12.5px; line-height: 1.45; color: var(--ink-2); }
.pt-sme[hidden] { display: none; }
.pt-go { width: 100%; height: 44px; font-size: 15px; }
.pt-foot { margin: 0; font-size: 12px; }
.pt-reset { margin: 32px 0 0; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.pt-legal { margin: 14px 0 0; max-width: 90ch; }
.pt-err { color: var(--kill); }
/* The ticket 300 px wide up to 1300 (not 1100): at 1280 the positions' eight lanes then fit their box (646 px) without scrolling. */
@media (max-width: 1300px) { .pt-grid { grid-template-columns: minmax(0, 1fr) 300px; gap: 20px; } }
/* A tight box (1280, 1366): lanes keep 8 px a side, so the positions fit without scrolling. */
@container pttw (max-width: 719px) { .pt-pos th, .pt-pos td, .pt-ord th, .pt-ord td { padding-left: 8px; padding-right: 8px; } }
/* 13 Oct 2026: tighter still (1280-1330, three positions with exits): 13 px figures and 6 px lanes, so the Close buttons and
   the ledger stay inside the box, never scrolled. */
@container pttw (max-width: 679px) { .pt-pos, .pt-led { font-size: 13px; } .pt-pos th, .pt-pos td, .pt-led th, .pt-led td { padding-left: 6px; padding-right: 6px; } }
/* The account figures by the summary's own width: five across only when a 13-character figure ("−₹1,23,456.78", 108 px)
   fits each; else three, else two. Measured in Chrome at 15 px. */
@container ptsum (max-width: 679px) { .pt-figs { grid-template-columns: repeat(3, minmax(0, 1fr)); } .pt-figs > div:nth-child(4) { border-left: 0; padding-left: 0; } }
@container ptsum (max-width: 409px) { .pt-figs { grid-template-columns: repeat(2, minmax(0, 1fr)); } .pt-figs > div:nth-child(odd) { border-left: 0; padding-left: 0; }
  .pt-figs > div:nth-child(4) { border-left: 1px solid var(--line); padding-left: 14px; } }
/* The ticket goes under the account whenever the desk itself is under 720 px: a phone, and 761-1000 px windows where the
   Quant rail takes 232 px (iPad portrait, 768-834), so the account's column is never under 400 px beside the ticket and
   its value, figures and cards are never cut, overlapped or hidden under the ticket. By the desk's width, not the window's. */
.pt { container: ptdesk / inline-size; }
@container ptdesk (max-width: 719px) {
  .pt-grid { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  /* 13 Oct 2026: the account's value first, then what he holds and has open, the ticket, then the ledger; the account's
     "New paper order" jumps to the ticket. */
  .pt-main { display: contents; } .pt-sum { order: 0; } .pt-side { position: static; order: 2; } .pt-since, .pt-main > .pt-err { order: 0; } .pt-main > .pt-sec { order: 1; } #pt-logbox { order: 3; }
  .pt-sum .pt-newb { display: inline-flex; }
  .pt-main > .pt-sec { margin-top: 10px; }
}
@media (max-width: 760px) {
  .pt-sum { padding: 18px 16px 14px; } .pt-big { font-size: 38px; }
  .pt-figs { grid-template-columns: 1fr 1fr; } .pt-figs > div { padding: 10px 0 0 !important; border-left: 0 !important; }
  .pt-tw { border-radius: var(--r-2); }
}
/* Cards, not tables, whenever the box is narrower than the tables' lanes need (a phone; 761-920 px, stacked beside the rail;
   1001-1320 px, where the ticket shares the screen): every figure and the Close and Cancel buttons in view, nothing behind a
   sideways scroll. */
@container pttw (max-width: 639px) {
  .pt-pos thead { display: none; } .pt-pos, .pt-pos tbody { display: block; }
  .pt-pos tr { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
  .pt-pos tr > * { padding: 0; border: 0; text-align: left; }
  .pt-pos tr { grid-template-columns: minmax(0, 1fr) minmax(0, auto); } .pt-pos td small { white-space: normal; } .pt-pos td:nth-child(6) > small::after { content: " · after charges"; } .pt-pos td:nth-child(3) > small[title]::after { content: " charges"; } .pt-pos .pt-day::after { content: " today"; }   /* the day's change wraps under the clock, never past the card */
  .pt-pos td:nth-child(2)::before { content: "Qty "; color: var(--ink-3); } .pt-pos td:nth-child(3)::before { content: "Avg "; color: var(--ink-3); }
  .pt-pos td:nth-child(5)::before { content: "Value "; color: var(--ink-3); } .pt-pos td.pt-ex::before { content: "Exits "; color: var(--ink-3); }
  .pt-pos td:nth-child(even) { text-align: right; } .pt-pos td.pt-act { grid-column: 1 / -1; text-align: left; }
  .pt-pos th, .pt-pos td, .pt-ord th, .pt-ord td { width: auto !important; }
  .pt-ord thead { display: none; } .pt-ord, .pt-ord tbody { display: block; } .pt-pos, .pt-ord { min-width: 0; }
  /* The stock and its limit whole (max-content); a past session's "Placed 12 Oct, 11:00" wraps in the middle lane instead,
     which is never under its widest word (min-content), so "Buy" and "Placed" never run into Qty or under Cancel. */
  .pt-ord tr { display: grid; grid-template-columns: max-content minmax(min-content, 1fr) auto; gap: 2px 12px; padding: 10px 14px; border-bottom: 1px solid var(--line); align-items: center; }
  .pt-ord tr > * { padding: 0; border: 0; text-align: left; }
  .pt-ord td:nth-child(3)::before { content: "Qty "; color: var(--ink-3); } .pt-ord td:nth-child(4)::before { content: "Limit "; color: var(--ink-3); }
  .pt-ord td:nth-child(5)::before { content: "Placed "; color: var(--ink-3); } .pt-ord td:nth-child(5) { white-space: normal; }
  .pt-led th:nth-child(7), .pt-led td:nth-child(7), .pt-led th:nth-child(9), .pt-led td:nth-child(9) { display: none; }
  /* The ledger as cards, as positions and orders are: number, time and stock; what happened in full; qty, price, cash after. */
  .pt-led thead { display: none; } .pt-led, .pt-led tbody { display: block; min-width: 0; }
  /* The middle lane never under its figure (min-content); in a tight card (a 320-360 px phone) qty, price and cash put their
     label over the figure instead of running into the next one. */
  .pt-led tr { display: grid; grid-template-columns: auto minmax(min-content, 1fr) auto; gap: 3px 12px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
  .pt-led td:nth-child(5), .pt-led td:nth-child(6), .pt-led td:nth-child(8) { white-space: normal; }
  .pt-led tr > * { padding: 0; border: 0; width: auto !important; text-align: left; }
  .pt-led td:nth-child(1) { color: var(--ink-3); } .pt-led td:nth-child(1)::before { content: "#"; }
  .pt-led td:nth-child(3) { grid-row: 2; grid-column: 1 / -1; } .pt-led td:nth-child(4) { grid-row: 1; grid-column: 3; text-align: right; font-weight: 600; }
  .pt-led td:nth-child(5):not(:empty)::before { content: "Qty "; color: var(--ink-3); } .pt-led td:nth-child(6)::before { content: "Price "; color: var(--ink-3); }
  .pt-led td:nth-child(8) { text-align: right; } .pt-led td:nth-child(8)::before { content: "Cash "; color: var(--ink-3); }
}

/* 13 Oct 2026: the returning member's first line, the ticket's product and rule lines, a moved figure's flash. */
.pt-newb { display: none; margin-top: 12px; }
.pt-since { margin: 0 0 18px; padding: 14px 16px; border: 1px solid var(--line-2); border-left: 2px solid var(--gold); border-radius: var(--r-2); background: var(--surface); }
.pt-since .pt-h { margin: 0 0 8px; } .pt-since ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.pt-since li { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 10px; font-size: 13.5px; } .pt-since b { white-space: nowrap; }   /* a loss's sign stays with its amount */ .pt-since small { color: var(--ink-3); margin-left: 6px; }
.pt-prod { margin: -6px 0 0; font-size: 12.5px; } .pt-from { margin: 0; padding: 8px 12px; border-left: 2px solid var(--gold); border-radius: var(--r-1); background: var(--gold-soft); font-size: 12.5px; line-height: 1.45; color: var(--ink-2); }
.pt-from[hidden] { display: none; } .pt-how { margin-top: 6px; } .pt-how > summary { cursor: pointer; color: var(--ink-2); }
.pt-qchg { font-size: 12.5px; margin-left: 4px; } .pt-prov, .pt-prov small { color: var(--ink-3) !important; }
@keyframes ptUp { from { background: color-mix(in srgb, var(--go) 22%, transparent); } to { background: transparent; } }
@keyframes ptDn { from { background: color-mix(in srgb, var(--kill) 22%, transparent); } to { background: transparent; } }
.pt-up { animation: ptUp .9s ease-out; border-radius: 4px; } .pt-dn { animation: ptDn .9s ease-out; border-radius: 4px; }
@media (prefers-reduced-motion: reduce) { .pt-up, .pt-dn { animation: none; } }
.pt-rules ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; } .pt-rules li { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--r-1); font-size: 13.5px; }
.pt-pos th small { display: block; font-size: 10.5px; font-weight: 400; color: var(--ink-3); text-transform: none; letter-spacing: 0; }
.pt-pos td small, .pt-pos th small { white-space: normal; }   /* a tight lane wraps its note rather than scroll the table (13 Oct 2026) */
.pt-t [data-age], .pt-pos td[data-ltp] > small:first-of-type { white-space: nowrap; }   /* "11:00 · 12 s" whole on its line */
.pt-csv { margin: 0 0 10px; }
.pt-legal > summary { cursor: pointer; } .pt-legal p { margin: 6px 0 0; }
/* 21 Oct 2026: intraday and futures (tradefno.js, tradefnoparts.js). The product switch in three; a hidden grid stays
   hidden; the positions' lanes as the delivery table's, cards in a narrow box with each figure's label before it. */
.pt-prods { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pt-two[hidden], .pt-seg[hidden] { display: none; }
.pt-ticket select.input { width: 100%; min-width: 0; }
.pt-fno { min-width: 560px; } .pt-fno td small { white-space: normal; }
.pt-ftoday { margin: 18px 0 -8px; font-size: 13px; } .pt-ftoday b { white-space: nowrap; font-weight: 600; }
@container pttw (max-width: 639px) {
  .pt-fno thead { display: none; } .pt-fno, .pt-fno tbody { display: block; min-width: 0; }
  .pt-fno tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, auto); gap: 2px 12px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
  .pt-fno tr > * { padding: 0; border: 0; text-align: left; width: auto !important; }
  .pt-fno td:nth-child(even) { text-align: right; } .pt-fno td.pt-act { grid-column: 1 / -1; text-align: left; }
  .pt-fno td[data-l]::before { content: attr(data-l) " "; color: var(--ink-3); }
}
