/* Stock and priority page (#/stock). Tokens from tokens.css, rows from app.css; only what those lack is here. */

/* the count on the right of a "can make" row: short, so it stays on the right on a phone too */
.line > .stk-n { grid-column: 2; grid-row: 1 / span 2; justify-self: end; font-weight: 500; white-space: nowrap; }

/* an order: its place in the queue and the client, then what can be made of it */
.stk-who { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-1) var(--s-2); min-width: 0; }
.stk-rank { color: var(--grey); font-weight: 400; min-width: 1.5rem; }
.stk-state { display: inline-flex; align-items: center; min-height: 32px; font-weight: 400; }
.line > .stk-res { grid-column: 2; grid-row: 1 / span 2; justify-self: end; max-width: 16rem; text-align: right; font-size: var(--t-sm); font-weight: 500; }
.stk-res.stk-is-none, .stk-res.stk-is-no_recipe { color: var(--grey); font-weight: 400; }

/* the parts that are missing, one under the other */
.stk-parts { display: grid; gap: 2px; }

/* a warning: a mark and words, never colour alone */
.stk-warn { display: flex; align-items: flex-start; gap: var(--s-2); font-size: var(--t-sm); line-height: 1.5; }
.stk-warn .mk { margin-top: 3px; }
.line > .stk-warn { grid-column: 1 / -1; }

/* which column is which: two across on a wide screen, one on a phone */
.stk-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); gap: var(--s-4); }
.stk-cols select { width: 100%; }
.stk-cols .help { overflow-wrap: anywhere; }
#stk-day { max-width: 14rem; }

@media (max-width: 40rem) {
  .line > .stk-res { grid-column: 1 / -1; grid-row: auto; justify-self: start; max-width: none; text-align: left; }
}
