/* Hearthmist module styles: market — the Trade tab. Everything else it shows is built from the shared primitives. */

/* Carts: icon, track, figures, as the goal's progress rows. */
.market-carts { margin-top: var(--s3); }
.market-carts .ic { color: var(--gold); }
.market-carts + .stat { margin-top: var(--s2); }

/* The deal: what to give, what to take, how much. */
.market-deal { display: grid; gap: 6px; margin-top: var(--s4); }

.btn.market-pick {
  display: flex;
  justify-content: flex-start;
  gap: var(--s2);
  width: 100%;
  min-height: 38px;
  padding: 5px 10px;
  font-weight: 400;
  text-align: left;
}
.btn.market-pick[aria-expanded="true"] { border-color: var(--gold); }
.market-k { flex: none; width: 34px; color: var(--muted); font-size: var(--fs-small); font-weight: 500; }
.market-v {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  font-family: var(--serif);
  font-size: var(--fs-name);
  line-height: 1.2;
}
.market-v b { font-weight: 400; }
.market-v .ic { width: 18px; height: 18px; }
.market-v.none { font-family: var(--sans); font-size: var(--fs-text); color: var(--muted); }
.market-n { margin-left: auto; color: var(--muted); font-size: var(--fs-small); white-space: nowrap; }

.market-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 6px; padding-bottom: var(--s1); }
.btn.market-res {
  justify-content: flex-start;
  gap: 6px;
  min-width: 0;
  min-height: 32px;
  padding: 3px 8px;
  font-size: var(--fs-text);
  font-weight: 500;
}
.btn.market-res .ic { width: 16px; height: 16px; }
.btn.market-res span { overflow: hidden; text-overflow: ellipsis; }
.btn.market-res:disabled .ic { opacity: 0.45; }
.market-note { margin-top: 0; }

.market-ask { margin-top: var(--s2); color: var(--muted); font-size: var(--fs-small); }
.market-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.btn.market-step { min-width: 0; padding: 4px 4px; font-size: var(--fs-text); font-weight: 500; }

/* Chosen, not actionable: gold, as a selection is on the map. */
.btn.market-res.on, .btn.market-step.on { background: var(--panel-3); border-color: var(--gold); color: var(--gold); }

/* Prices: a ruled list, name on the left, figures lined up on the right. */
.market-prices li {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr) auto 52px;
  align-items: baseline;
  gap: var(--s2);
  padding: 7px 0;
  border-top: 1px solid var(--line);
}
.market-prices li:first-child { border-top: 0; }
.market-prices .ic { width: 17px; height: 17px; align-self: center; }
.market-prices b { font-family: var(--serif); font-size: var(--fs-body); font-weight: 400; }
.market-w { color: var(--muted); font-size: var(--fs-small); text-align: right; white-space: nowrap; }
.market-p { font-weight: 700; text-align: right; }

@media (max-width: 820px) {
  .btn.market-res { min-height: 38px; }
  .btn.market-step { min-height: 38px; }
}
