/* markets view styles — owned by the markets feature; loaded after /styles.css. Prefix: mk- */
.mk-note { margin-bottom: 14px; border-style: dashed; background: var(--soft); }
.mk-search { margin-bottom: 14px; }
.mk-form { display: flex; gap: 8px; }
.mk-form input { flex: 1; min-width: 0; }
.mk-results { display: grid; gap: 6px; margin: 10px 0 8px; }
.mk-results:empty { display: none; }
.mk-result { font: inherit; color: var(--ink); background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; display: grid; grid-template-columns: 22px 1fr auto auto; gap: 10px; align-items: center; text-align: left; cursor: pointer; }
.mk-result:hover:not(:disabled) { border-color: var(--ink); }
.mk-result:disabled { opacity: .5; cursor: not-allowed; }
.mk-result-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-add { font-size: 12px; font-weight: 600; padding: 2px 9px; border-radius: 6px; background: var(--accent); color: var(--accent-ink); }

.mk-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); margin-bottom: 14px; }
.mk-loc { display: grid; gap: 10px; align-content: start; }
.mk-loc-head { display: grid; grid-template-columns: 30px 1fr auto; gap: 10px; align-items: center; }
.mk-loc-name { display: flex; flex-direction: column; min-width: 0; }
.mk-loc-name b { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-loc-name .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mk-flag { font-size: 22px; line-height: 1; text-align: center; }
.mk-cc { display: inline-block; font-family: var(--mono); font-size: 11px; padding: 3px 4px; border-radius: 5px; background: var(--soft); color: var(--muted); }
.mk-weight { display: grid; grid-template-columns: auto 1fr 44px; gap: 10px; align-items: center; }
.mk-weight input[type="range"] { padding: 0; border: 0; background: transparent; accent-color: var(--bar); min-width: 0; }
.mk-weight input[type="range"]:focus { outline-offset: 2px; }
.mk-share { text-align: right; }
.mk-plan { margin: 0; color: var(--muted); }
.mk-plan b { color: var(--ink); font-weight: 600; }
.mk-vis { display: grid; grid-template-columns: auto 1fr 44px; gap: 10px; align-items: center; padding-top: 10px; border-top: 1px solid var(--line); }
.mk-vis .mono { text-align: right; }
.mk-unmeasured { grid-column: 2 / 4; text-align: right; }

.mk-actions { margin-bottom: 14px; }
.mk-actions .card { display: flex; flex-direction: column; gap: 10px; }
.mk-actions .card > p { margin: 0; }
.mk-actions .btn.primary { align-self: flex-start; }
.mk-actions .field { margin-bottom: 0; }
.mk-actions textarea { min-height: 70px; }
.mk-check { display: flex; gap: 8px; align-items: center; }
.mk-check input { width: auto; }
.mk-summary .barrow { grid-template-columns: minmax(0, 180px) 1fr 56px; }

@media (max-width: 520px) {
  .mk-form { flex-direction: column; }
  .mk-result { grid-template-columns: 22px 1fr auto; }
  .mk-result > .muted { display: none; }
  .mk-summary .barrow { grid-template-columns: minmax(0, 110px) 1fr 48px; }
}
