/* Bringing in a broker's activity statement (src/dashboard/statement-import.js): the journal's Import tab. Colours and sizes come from app.css's variables, so dark mode follows. */
.stm { display: grid; gap: var(--s4); min-width: 0; }
.stm > .card { margin: 0; }
.stm-drop { display: grid; justify-items: center; gap: var(--s2); text-align: center; padding: var(--s5) var(--s4); border: 1.5px dashed var(--line-2); border-radius: var(--radius); background: var(--panel-2); }
.stm-drop.over { border-color: var(--accent); background: var(--accent-bg); }
.stm-drop:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.stm-pick { justify-content: center; }
.stm-pick .btn { min-height: var(--tap); }
.stm-actions { flex-wrap: wrap; gap: var(--s2); }
.stm-actions .btn { min-height: var(--tap); }
/* The checks: a mark, what was compared, and for one that did not match what it means and the two figures. */
.stm-checks-wrap { display: grid; gap: var(--s3); }
.stm-checks { list-style: none; margin: var(--s2) 0 0; padding: 0; display: grid; gap: var(--s3); }
.stm-check { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: var(--s3); align-items: start; }
.stm-check-body { display: grid; gap: 2px; min-width: 0; overflow-wrap: anywhere; }
.stm-check-label { display: flex; flex-wrap: wrap; gap: 4px var(--s2); align-items: center; }
.stm-mark { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; font-size: 12px; font-weight: 700; line-height: 1; }
.stm-mark.ok { background: var(--pos-bg); color: var(--pos); }
.stm-mark.bad { background: var(--neg-bg); color: var(--neg); }
.stm-check.bad { padding: var(--s3); border: 1px solid var(--neg); border-radius: var(--radius-sm); background: var(--neg-bg); }
.stm-assume { margin: var(--s2) 0 0; }
.stm-list li { padding: var(--s3) 0; border-top: 1px solid var(--line); }
.stm-list li:first-child { border-top: 0; }
.stm-chips { display: flex; flex-wrap: wrap; gap: var(--s2); margin-top: 6px; }
.stm .btn.sm { min-height: var(--tap); }
@media (max-width: 480px) {
  .stm-drop { padding: var(--s4) var(--s3); }
  .stm-list .row.between { flex-wrap: wrap; gap: var(--s2); }
}
/* "Where do I get it?": one line until it is opened (a button, so Enter and Space open it), then the steps in a panel set off by an accent edge. The same markup is on the Year page's empty state. */
.stm-guide { display: grid; gap: var(--s2); justify-items: start; min-width: 0; }
.stm-guide-toggle { all: unset; box-sizing: border-box; display: inline-flex; align-items: center; gap: 6px; min-height: var(--tap); cursor: pointer; color: var(--accent); line-height: 1.35; }
.stm-guide-toggle:hover { text-decoration: underline dotted; text-underline-offset: 3px; }
.stm-guide-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.stm-chev { flex: none; width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; transition: transform 0.15s; }
.stm-guide-toggle[aria-expanded="true"] .stm-chev { transform: rotate(180deg); }
.stm-guide-body[hidden] { display: none; }
.stm-guide-body { display: grid; gap: var(--s2); width: 100%; box-sizing: border-box; padding: var(--s3) var(--s4); border-inline-start: 3px solid var(--accent); border-radius: var(--radius-sm); background: var(--panel-2); text-align: start; overflow-wrap: anywhere; }
.stm-guide-body h4 { margin: var(--s2) 0 0; font-size: var(--fs-body); }
.stm-guide-body h4:first-child { margin-top: 0; }
.stm-guide-body p { margin: 0; }
.stm-steps { margin: 0; padding-inline-start: 22px; display: grid; gap: var(--s1); }
/* What is counted, the way the broker counts: the executions first and large, then the grouping, then what a "trade" is on the page. */
.exec-counts { display: grid; gap: var(--s1); margin: var(--s3) 0 0; min-width: 0; overflow-wrap: anywhere; }
.exec-counts p { margin: 0; }
.exec-main { font-size: 17px; font-weight: 650; line-height: 1.3; }
.exec-help { margin-top: var(--s1) !important; padding-top: var(--s2); border-top: 1px solid var(--line); }
.stm-note { margin: var(--s3) 0 0; }
/* The Journal's realized figures (docs/realized-pnl.md): the headline card, the reconciliation under it, the figures about closed round trips, and the "by symbol" table. */
.rp-card .kv .v, .rp-closed .kv .v { min-width: 0; overflow-wrap: anywhere; }
.rp-sub { display: block; margin-top: 2px; font-weight: 400; }
.rp-open-note { margin: var(--s2) 0 var(--s3); }
.rp-h3 { margin: var(--s4) 0 var(--s2); font-size: var(--fs-body); }
.rp-reconcile { display: grid; gap: var(--s3); margin-top: var(--s2); padding-top: var(--s3); border-top: 1px solid var(--line); min-width: 0; }
.rp-rec { display: grid; gap: var(--s1); min-width: 0; padding-inline-start: var(--s3); border-inline-start: 3px solid var(--line-2); overflow-wrap: anywhere; }
.rp-rec.ok { border-inline-start-color: var(--pos); }
.rp-rec.differs { border-inline-start-color: var(--watch); }
.rp-rec p { margin: 0; }
.rp-rec-head { font-weight: 600; }
.rp-table td, .rp-table th { white-space: nowrap; }
.rp-table td.text { white-space: normal; }
.rp-sym { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 2px 6px; min-width: 0; }
.rp-sym a { white-space: nowrap; overflow-wrap: normal; word-break: normal; }
.rp-row { cursor: pointer; }
.rp-toggle { all: unset; box-sizing: border-box; flex: none; display: inline-grid; place-items: center; width: 26px; height: 26px; margin-inline-start: -6px; cursor: pointer; color: var(--muted); border-radius: 6px; }
.rp-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.rp-toggle .stm-chev { width: 16px; height: 16px; transition: transform 0.15s; }
.rp-toggle[aria-expanded="true"] .stm-chev { transform: rotate(180deg); }
.rp-open-chip { font-size: 11px; flex: none; }
.rp-detail td { padding-top: 0; white-space: normal; }
.rp-lines { display: grid; gap: var(--s1); margin: 0; padding-inline-start: var(--s3); }
.rp-lines li { overflow-wrap: anywhere; }
.rp-total { font-weight: 650; }
.rp-sort { margin-inline-start: auto; }
.rp-more { margin: var(--s2) var(--s3) var(--s3); min-height: var(--tap); }
.rp-open-cell { margin-top: 2px; }
.rp-open-mark { white-space: normal; font-size: 11px; line-height: 1.25; }
.rp-symbols .card-head { flex-wrap: wrap; gap: var(--s2); }
.rp-rec-symbols { margin-top: var(--s2); }
@media (max-width: 480px) {
  .rp-table th, .rp-table td { padding-inline: 6px; }
  .rp-open-mark { display: inline-block; max-width: 11em; }
}
