/* /play: the shelf, the stage and its tools. Tokens, the shell and the shared
   pieces are site.css; only what is this page's own is here. */

.shelf-box {
	display: grid;
	gap: 12px;
}
.shelf-tools {
	display: grid;
	gap: 8px;
	grid-template-columns: minmax(0, 1fr) auto;
	align-items: center;
}
.shelf-tools input[type="search"] {
	width: 100%;
	max-width: 320px;
	padding: 8px 12px;
	border-radius: 10px;
	border: 1px solid var(--line);
	background: var(--void);
	color: var(--bone);
}
.shelf-tools .status {
	margin: 0;
	justify-self: end;
}

/* A flex wrap, not a grid. A grid sizes its rows from what each item says it
   wants before the column width is settled, and a <button> item answers with
   one line of text however tall its content is, so every card came out 37px
   with its art clipped to a strip. */
.shelf {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	max-height: 340px;
	overflow-y: auto;
	padding-right: 4px;
	align-content: flex-start;
}
.shelf > * {
	flex: 0 0 118px;
}
.shelf-skel {
	height: 140px;
	border-radius: 12px;
}
.shelf-card {
	display: block;
	padding: 0;
	border: 1px solid var(--line);
	border-radius: 12px;
	background: var(--card);
	overflow: hidden;
	text-align: left;
	cursor: pointer;
}
.shelf-card .card-in {
	display: grid;
	gap: 4px;
}
.shelf-card:hover {
	border-color: var(--line-hi);
}
.shelf-card[aria-current="true"] {
	border-color: var(--gold);
	background: rgba(var(--gold-rgb), 0.1);
}
/* The art is a fixed height, not a square worked out from the width. A grid
   asks each card how tall it wants to be before the column width is settled,
   and both aspect-ratio and padding-top resolve to nothing at that moment, so
   every card reported one line of text and the art was clipped to a strip. */
.shelf-card .art {
	display: block;
	height: 104px;
	background: var(--void);
}
.shelf-card .art img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}
.shelf-card .nm {
	padding: 0 8px;
	font-weight: 600;
	font-size: 13px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}
.shelf-card .sub {
	padding: 0 8px 8px;
	font-size: 11px;
	color: var(--dim);
	display: flex;
	gap: 6px;
	align-items: center;
}
.shelf-card .yours {
	color: var(--gold);
}

.stage-box {
	margin-block: 20px;
}
.stage {
	position: relative;
	border-radius: 14px;
	overflow: hidden;
	background: var(--card);
	aspect-ratio: 4 / 3;
	max-height: 72vh;
	width: 100%;
}
.stage canvas {
	display: block;
	width: 100%;
	height: 100%;
	touch-action: pan-y;
}
.stage .stage-say {
	position: absolute;
	inset: 0;
	display: grid;
	place-items: center;
	margin: 0;
	color: var(--soft);
	text-align: center;
	padding: 16px;
	pointer-events: none;
}
.stage .stage-who {
	position: absolute;
	left: 12px;
	bottom: 10px;
	display: flex;
	gap: 8px;
	align-items: baseline;
	font-size: 13px;
	color: var(--bone);
	background: rgba(var(--void-rgb), 0.55);
	padding: 4px 10px;
	border-radius: 99px;
	pointer-events: none;
	backdrop-filter: blur(6px);
}
.stage .stage-who b {
	font-family: var(--serif);
	font-size: 15px;
}
.stage .stage-who span {
	color: var(--dim);
	font-size: 11px;
}

/* the safe frame: what the photograph will keep, over the live view */
.stage .safe {
	position: absolute;
	inset: 0;
	display: grid;
	place-items: center;
	pointer-events: none;
}
.stage .safe-in {
	outline: 1px solid rgba(var(--bone-rgb), 0.5);
	box-shadow: 0 0 0 4000px rgba(0, 0, 0, 0.45);
}

.tools {
	display: grid;
	gap: 12px;
}
.tools .row {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
}
.tools .row > .label {
	margin: 0;
}
.chips {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
}
.chips button {
	font: inherit;
	font-size: 13px;
	padding: 5px 11px;
	border-radius: 99px;
	border: 1px solid var(--line);
	background: var(--card);
	color: var(--soft);
	cursor: pointer;
}
.chips button:hover {
	color: var(--bone);
	border-color: var(--line-hi);
}
.chips button[aria-pressed="true"] {
	background: var(--gold);
	border-color: var(--gold);
	color: var(--void);
	font-weight: 600;
}
.chips button:disabled {
	opacity: 0.4;
	cursor: default;
}

.play-row input[type="range"] {
	flex: 1 1 180px;
	min-width: 120px;
	accent-color: var(--gold);
}
.play-row .mono {
	font-size: 12px;
	min-width: 96px;
	text-align: right;
}

.photo {
	display: grid;
	gap: 12px;
	margin-block: 20px;
}
.look-row {
	display: flex;
	flex-wrap: wrap;
	gap: 14px;
	align-items: center;
}
.look-row label {
	display: flex;
	gap: 8px;
	align-items: center;
	font-size: 13px;
	color: var(--soft);
}
.look-row input[type="range"] {
	width: 108px;
	accent-color: var(--gold);
}
.look-row .mark {
	gap: 6px;
}
.photo .foot-note {
	margin: 0;
	flex-basis: 100%;
}

.soon {
	margin-block: 20px;
}

@media (max-width: 640px) {
	.shelf {
		max-height: 272px;
	}
	.shelf > * {
		flex: 1 0 96px;
	}
	.shelf-card .art {
		height: 88px;
	}
	.shelf-tools {
		grid-template-columns: minmax(0, 1fr);
	}
	.shelf-tools .status {
		justify-self: start;
	}
	.stage {
		aspect-ratio: 3 / 4;
		max-height: 64vh;
	}
	.play-row .mono {
		min-width: 0;
	}
}
