/* UNDER LAYERS — 配給所(shop.html)。kb.css の .box / .band / .btn・ops.css の .x-row(個体の行)を使う。docs/api.md §29 */

.sh-main {
	max-width: 960px;
}

/* 配給所ビジュアル班がアイコンを入れる(空なら幅を取らない) */
.sh-icon:empty,
.sh-cur-icon:empty {
	display: none;
}

.sh-lead {
	margin: 4px 0 0;
	font-size: var(--fs-s);
}

/* 配給所ビジュアル班が場面(背景・店員・台詞)を入れる。空なら高さを取らない */
.sh-scene:empty {
	display: none;
}

.sh-scene {
	margin: 0 0 12px;
}

.sh-app {
	display: grid;
	gap: 12px;
}

.sh-box {
	margin: 0;
}

/* ---------------------------------------------------------------- 通貨 */

.sh-wallet {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 8px;
}

.sh-cur {
	display: grid;
	gap: 2px;
	padding: 8px 10px;
	background: var(--bg-1);
	border: 1px solid var(--line-hi);
	font-size: var(--fs-s);
}

.sh-cur.is-yakin { border-left: 3px solid var(--fg); }
.sh-cur.is-fusa { border-left: 3px solid var(--warn); }
.sh-cur.is-shizumi { border-left: 3px solid var(--cyan); }

.sh-cur-n b { color: var(--fg-hi); }
.sh-cur-p { font-size: var(--fs-xs); }

.sh-cur-v b {
	color: var(--fg-hi);
	font-size: var(--fs-l);
}

.sh-cur-e {
	display: flex;
	align-items: center;
	gap: 4px;
	font-size: var(--fs-xs);
}

.sh-cur-e b { color: var(--fg); }

.sh-cur-t {
	font-size: var(--fs-xs);
	line-height: 1.4;
}

.sh-meter {
	display: inline-block;
	flex: 1 1 auto;
	min-width: 30px;
	max-width: 90px;
	height: 5px;
	background: var(--bg-deep);
	border: 1px solid var(--line);
}

.sh-meter > span {
	display: block;
	height: 100%;
	background: var(--fg);
}

/* ---------------------------------------------------------------- 一時強化・切り替え */

.sh-reset {
	margin: 0 0 8px;
	font-size: var(--fs-s);
}

.sh-left {
	color: var(--fg-hi);
	font-weight: bold;
}

.sh-boost {
	margin: 0 0 8px;
	padding: 6px 8px;
	border: 1px dashed var(--line-hi);
	font-size: var(--fs-s);
	line-height: 1.5;
}

.sh-boost:not(.is-none) {
	border-color: var(--cyan);
}

.sh-boost-k {
	padding: 0 4px;
	color: var(--bg);
	background: var(--cyan);
	font-size: var(--fs-xs);
}

.sh-boost-left { color: var(--cyan); }

.sh-note {
	margin: 0 0 8px;
	font-size: var(--fs-s);
	line-height: 1.5;
}

.sh-h3 {
	margin: 10px 0 4px;
	color: var(--fg-hi);
	font-size: var(--fs-m);
}

/* ---------------------------------------------------------------- 品 */

.sh-list {
	display: grid;
	gap: 0;
	margin: 0;
	padding: 0;
	list-style: none;
}

.sh-list.is-molds {
	grid-template-columns: repeat(2, minmax(0, 1fr));
	column-gap: 14px;
}

.sh-item {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 8px 0;
	border-bottom: 1px dotted var(--line);
}

.sh-item.is-off .sh-item-n { color: var(--sub); }
.sh-item.is-sealed { opacity: .7; }

.sh-item-main {
	display: grid;
	flex: 1 1 auto;
	gap: 2px;
	min-width: 0;
}

.sh-item-n { color: var(--fg-hi); }

.sh-item-t {
	font-size: var(--fs-xs);
	line-height: 1.45;
}

.sh-tag {
	justify-self: start;
	padding: 0 4px;
	color: var(--cyan);
	border: 1px solid currentColor;
	font-size: var(--fs-xs);
}

.sh-why {
	color: var(--warn);
	font-size: var(--fs-xs);
}

.sh-have { font-size: var(--fs-xs); }
.sh-have.is-zero { color: var(--warn); }

/* 照準符の残り(打ち直しの道具とは別。作戦記録の封鎖照会で使う) */
.sh-aim { margin: 0 0 6px; font-size: var(--fs-s); }
.sh-aim b { color: var(--fg-hi); }

.sh-item-side {
	display: grid;
	flex: none;
	justify-items: end;
	gap: 3px;
	min-width: 8.5em;
	text-align: right;
}

.sh-price b {
	color: var(--fg-hi);
	font-size: var(--fs-l);
}

.sh-cur-icon.is-sm {
	display: inline-block;
	vertical-align: middle;
	margin-right: 3px;
}

.sh-limit { font-size: var(--fs-xs); }
.sh-limit.is-out { color: var(--warn); }

.sh-buy {
	min-width: 7em;
	min-height: 34px;
}

.sh-buy.is-armed {
	color: var(--bg);
	background: var(--warn);
	border-color: var(--warn);
}

.sh-item.is-inst .x-row {
	padding: 0;
	border: 0;
	background: none;
}

.sh-aids,
.sh-log {
	margin: 0 0 6px;
	padding-left: 1.2em;
	font-size: var(--fs-s);
}

.sh-log { font-size: var(--fs-xs); }

@media (max-width: 720px) {
	.sh-wallet {
		grid-template-columns: 1fr;
	}

	.sh-list.is-molds {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 520px) {
	.sh-item {
		flex-direction: column;
		align-items: stretch;
	}

	.sh-item-side {
		grid-template-columns: auto auto 1fr;
		align-items: center;
		justify-items: start;
		min-width: 0;
		text-align: left;
	}

	.sh-buy {
		justify-self: end;
	}
}


/* ---- 常設の棚(shop.js shelfBox。時刻では戻らない売り場。docs/totsu-design.md §7) ---- */
.sh-item-ic { width: 16px; height: 16px; margin-right: 4px; vertical-align: -3px; image-rendering: pixelated; }
html.kb-arts-off .sh-item-ic { display: none; }
