/* One semantic table and one set of financial buttons. Small screens reshape
   the existing rows; no duplicated hidden wallets, event handlers or records. */
.record-id-full{display:none}
.instrument-row>span:first-child{min-width:0;overflow-wrap:anywhere}
@media(max-width:700px){
  .portfolio .table-wrap{max-height:560px;overflow-y:auto;overflow-x:hidden}
  .portfolio table{display:block;min-width:0;width:100%;white-space:normal}
  #record-head{position:absolute;clip-path:inset(50%);height:1px;width:1px;overflow:hidden}
  #records{display:grid;gap:12px;padding:12px;width:100%}
  #records tr{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;
    min-width:0;padding:14px;border:1px solid var(--line);border-radius:7px;background:#0a2034}
  #records td{display:block;min-width:0;max-width:100%;padding:0;border:0;white-space:normal;
    overflow-wrap:anywhere;word-break:break-word;font-size:13px;line-height:1.6}
  #records td::before{content:attr(data-label);display:block;color:var(--muted);
    font:11px/1.5 system-ui,"Microsoft YaHei",sans-serif;margin-bottom:3px}
  #records td:first-child,#records td:nth-child(2),#records .record-actions,#records .record-option-terms{grid-column:1/-1}
  #records td:first-child,#records td:nth-child(2){font-size:11px;color:#b6cedd}
  #records .record-id-short{display:none}
  #records .record-id-full{display:inline}
  #records .record-actions{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
  #records .record-actions::before{width:100%;margin:0}
  #records .record-actions:empty{display:none}
  #records td button{min-height:44px;min-width:88px;font-size:13px;padding:8px 12px}
  #records .record-option-terms{font-size:12px;color:#b6cedd}
}
