.mcard .mto { display: block; }
.mtohead { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.mtohead .nu b { font-size: 18px; }
.mtohead i.dim { font-style: normal; font-size: 12px; }
.mq { display: flex; gap: 4px; flex-wrap: wrap; }
.ghost.sm.on { border-color: var(--accent-tint-line); background: var(--accent-tint); color: var(--accent-dark); }
.ghost.sm:disabled { opacity: .4; cursor: default; }

.mtl { max-height: 184px; overflow-y: auto; border: 1px solid var(--line); border-radius: 8px; }
.mtr { display: grid; grid-template-columns: 18px 26px minmax(150px, 1.4fr) minmax(0, 1.2fr) minmax(0, max-content); gap: 8px; align-items: center;
  padding: 4px 10px; border-top: 1px solid var(--paper-line); font-size: 12.5px; cursor: pointer; }
.mtr:first-child { border-top: 0; }
.mtr:hover { background: var(--hover); }
.mtr.on { background: var(--chip); }
.mtr.no { cursor: default; color: var(--subtle); }
.mtr.no .mtw { opacity: .55; }
.mtr.sent { grid-template-columns: minmax(150px, 1.4fr) minmax(0, 1.2fr) minmax(0, max-content); cursor: default; }
.mtr input { margin: 0; accent-color: var(--accent); }
.mtn { color: var(--subtle); font-variant-numeric: tabular-nums; text-align: right; }
.mte { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mtw2 { display: flex; gap: 4px; flex-wrap: wrap; justify-content: flex-end; }
.mno { color: var(--err); font-size: 12px; }

.mta { width: 100%; box-sizing: border-box; border: 1px solid var(--line-strong); border-radius: 8px; padding: 8px 10px;
  font: inherit; font-size: 13px; line-height: 1.8; resize: vertical; outline: 0; }
.mta:focus { border-color: var(--accent); }
.mslots { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; margin-top: 6px; }
.mslots .dim { font-size: 12px; margin-right: 4px; }
.slot { border: 1px dashed var(--accent-tint-line); background: var(--warm); color: var(--accent-dark); border-radius: 6px; padding: 0 7px; font-size: 12px; line-height: 1.8; }
.slot:hover { background: var(--accent-tint); }

.mcols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 18px; align-items: stretch; }
.mleft { align-content: start; }
.mright { min-height: 100%; }
.mright .mta { flex: 1; min-height: 320px; }
.mright .mprev { flex: 1; }
.mright .mprev .mbody { height: auto; min-height: 260px; flex: 1; }
.mright .mwait { flex: 1; min-height: 320px; }
.mleft .mtl { max-height: 300px; }
.mleft .mtr { grid-template-columns: 18px 22px minmax(120px, 1fr) minmax(0, 1fr) minmax(0, max-content); }
@media (max-width: 900px) { .mcols { grid-template-columns: 1fr; } .mright .mta, .mright .mwait { min-height: 220px; } }

.mbox { display: flex; flex-direction: column; gap: 6px; }
.mtabs { display: flex; align-items: center; gap: 2px; border-bottom: 1px solid var(--line); }
.mtabs button { border: 0; background: none; padding: 4px 12px; font-size: 13px; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.mtabs button.on { color: var(--accent-dark); border-bottom-color: var(--accent); font-weight: 600; }
.mtabs button:hover { color: var(--heading); }

.mwait { min-height: 190px; border: 1px dashed var(--line-strong); border-radius: 8px; padding: 10px 12px; color: var(--muted); font-size: 13px;
  background: linear-gradient(90deg, var(--chip), var(--hover), var(--chip)); background-size: 200% 100%; animation: mwait 1.6s linear infinite; }
.mwait.sub { min-height: 0; padding: 5px 10px; }
@keyframes mwait { from { background-position: 100% 0; } to { background-position: -100% 0; } }

.mprev { border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; display: flex; flex-direction: column; gap: 6px; }

.mprev .mbody { height: 150px; min-height: 80px; overflow-y: auto; resize: vertical; padding: 8px 12px; }
.mph { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.mpn { font-size: 12px; color: var(--muted); }
.mpn i { font-style: normal; margin-left: 2px; }
.mpto { margin-left: 4px; }
.mpto .dim { font-size: 12px; }
.mpsub { font-size: 13px; color: var(--heading); font-weight: 600; }
.mpo { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12px; }
.mwarn { color: var(--warn); background: var(--v-partial-bg); border-radius: 8px; padding: 5px 10px; font-size: 12.5px; }
[data-mlive] { display: flex; flex-direction: column; gap: 8px; }
.mcard .primary.arm { background: var(--err); }

.msig1 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 12.5px; padding-top: 3px; }
.msig1 label { display: inline-flex; align-items: center; gap: 4px; }
.msig1 input { accent-color: var(--accent); margin: 0; }
.msig1 .dim { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 60%; }
.msigf { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 12px; margin-bottom: 6px; }
.msigf label { display: grid; grid-template-columns: 52px minmax(0, 1fr); align-items: center; gap: 6px; font-size: 12px; color: var(--muted); }
.msigf input { border: 1px solid var(--line-strong); border-radius: 8px; padding: 4px 8px; font-size: 13px; outline: 0; min-width: 0; }
.msigf input:focus { border-color: var(--accent); }
.mprev .mbody.msig { height: auto; resize: none; color: var(--muted); font-size: 12px; }
@media (max-width: 640px) { .msigf { grid-template-columns: 1fr; } }

.msum { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.msum .nu b { font-size: 22px; }
.msum > span:not(.nu) { font-size: 13px; }

@media (max-width: 640px) {
  .mtr { grid-template-columns: 18px minmax(0, 1fr); }
  .mtr .mtn { display: none; }
  .mtr .mte, .mtr .mtw2 { grid-column: 2; justify-content: flex-start; }
}
