/* The sub-pages' shared layout (Boo Remix, and Boo Band with boo-band.css), after base.css. */
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }

a:focus-visible, audio:focus-visible, button:focus-visible, input:focus-visible {
	outline: 2px solid var(--ink);
	outline-offset: 3px;
}

.studio {
	width: min(820px, calc(100% - 40px));
	margin: 0 auto;
	padding: 76px 0 48px;
}

/* The page menu and theme button sit in the page's top corners (nav.css). */

/* The artwork file stays black on white; dark mode shows it as a negative. */
:root[data-theme='dark'] .artwork { filter: invert(1); }

.artwork-sync { width: min(260px, 70%); margin-top: 40px; will-change: transform; }

.artwork {
	display: block;
	width: 100%;
	height: auto;
	image-rendering: pixelated;
}

.eyebrow {
	margin: 28px 0 0;
	font-size: 0.78rem;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

h1 {
	margin: 6px 0 12px;
	font-size: clamp(2.2rem, 8vw, 4rem);
	font-weight: 650;
	letter-spacing: -0.055em;
	line-height: 1;
}

.intro { max-width: 620px; margin: 0; font-size: 1.08rem; line-height: 1.6; }

.panel { margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--line); }

.panel-heading { display: flex; flex-wrap: wrap; gap: 12px; align-items: baseline; justify-content: space-between; }

h2 { margin: 0; font-size: 1.3rem; font-weight: 600; letter-spacing: -0.02em; }

.player-slot audio { display: block; width: 100%; margin-top: 18px; }

.status { min-height: 1.5em; margin: 10px 0 0; font-size: 0.92rem; color: var(--muted); }

.controls {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
	gap: 20px 32px;
	margin: 20px 0 24px;
}

.control {
	display: grid;
	grid-template-columns: 1fr auto;
	gap: 6px 12px;
	align-items: baseline;
}

.control label { font-weight: 550; }

.control output { font-variant-numeric: tabular-nums; color: var(--muted); }

.control input { grid-column: 1 / -1; width: 100%; margin: 0; }

.switch { display: inline-flex; gap: 8px; align-items: center; line-height: 1.4; cursor: pointer; }

.switch input { width: 18px; height: 18px; margin: 0; flex: none; }

.source-choice, .original-tracks { display: grid; gap: 10px; min-width: 0; margin: 18px 0 0; padding: 0; border: 0; }

.source-choice legend, .original-tracks legend { margin-bottom: 10px; padding: 0; font-weight: 550; }

.source-choice .switch { align-items: baseline; flex-wrap: wrap; min-height: 32px; }

.source-choice .hint { margin: 0; font-size: 0.9rem; }

.original-tracks[hidden] { display: none; }

.track-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px 24px; }

.track-list .switch { min-height: 32px; }

.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }

.actions button {
	min-height: 44px;
	padding: 0 18px;
	border: 1px solid var(--ink);
	color: var(--ink);
	background: var(--paper);
	cursor: pointer;
	transition: color 140ms ease, background-color 140ms ease;
}

.actions button:hover, .actions button[aria-pressed='true'] { color: var(--paper); background: var(--ink); }

.actions button:disabled { color: var(--muted); border-color: var(--line); background: var(--paper); cursor: default; }

.layers { display: grid; gap: 16px; margin: 20px 0 0; padding: 0; list-style: none; }

.layers:empty { display: none; }

.layer { padding: 16px; border: 1px solid var(--line); }

.layer .controls { margin: 16px 0 0; }

.layer-heading { display: flex; gap: 12px; align-items: center; justify-content: space-between; }

h3 { margin: 0; font-size: 1rem; font-weight: 600; }

/* A section heading's switch and Reset button sit together on the right. */
.panel-tools { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; }

.remove-layer,
.section-reset {
	min-height: 36px;
	padding: 0 12px;
	border: 1px solid var(--line);
	font: inherit;
	font-size: 0.9rem;
	color: var(--ink);
	background: var(--paper);
	cursor: pointer;
}

.remove-layer:hover,
.section-reset:hover { border-color: var(--ink); }

.remove-layer:focus-visible,
.section-reset:focus-visible {
	outline: 2px solid var(--ink);
	outline-offset: 3px;
}

.downloads { margin: 14px 0 0; font-size: 0.88rem; }

.hint { max-width: 620px; margin: 8px 0 0; color: var(--muted); line-height: 1.5; }

.control .hint { grid-column: 1 / -1; margin: 0; font-size: 0.85rem; }

.masthead .hint { margin-top: 4px; font-size: 0.9rem; }

.field { display: grid; gap: 6px; align-content: start; }

.field label { font-weight: 550; }

select {
	min-height: 40px;
	width: 100%;
	padding: 0 10px;
	border: 1px solid var(--ink);
	border-radius: 0;
	font: inherit;
	color: var(--ink);
	background: var(--paper);
}

select:disabled { color: var(--muted); border-color: var(--line); }

select:focus-visible {
	outline: 2px solid var(--ink);
	outline-offset: 3px;
}

/* The share link reads as one line to select or copy. */
.share-field { margin-top: 16px; }

.share-field input {
	min-height: 40px;
	width: 100%;
	padding: 0 10px;
	border: 1px solid var(--line);
	border-radius: 0;
	font-size: 0.85rem;
	color: var(--ink);
	background: var(--paper);
}

/* "Tell the ghost": the words and Ask on one line, then example words to try. */
.ask-form { margin-top: 16px; }

.ask-row { display: flex; gap: 8px; }

.ask-row input {
	flex: 1;
	min-width: 0;
	min-height: 44px;
	padding: 0 12px;
	border: 1px solid var(--ink);
	border-radius: 0;
	font: inherit;
	color: var(--ink);
	background: var(--paper);
}

.ask-row button,
.ask-examples button {
	min-height: 44px;
	padding: 0 18px;
	border: 1px solid var(--ink);
	font: inherit;
	color: var(--ink);
	background: var(--paper);
	cursor: pointer;
}

.ask-row button:hover { color: var(--paper); background: var(--ink); }

.ask-row button:disabled { color: var(--muted); border-color: var(--line); background: var(--paper); cursor: default; }

.ask-examples { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

.ask-examples button { min-height: 36px; padding: 0 12px; border-color: var(--line); font-size: 0.9rem; }

.ask-examples button:hover { border-color: var(--ink); }

.ask-row button:focus-visible,
.ask-examples button:focus-visible {
	outline: 2px solid var(--ink);
	outline-offset: 3px;
}

.ask-check:empty { display: none; }

.ask-check { margin-top: 12px; }

.ask-status { color: var(--ink); line-height: 1.5; }

.ask-form .actions { margin-top: 8px; }

.ask-form .actions:has(> [hidden]:only-child) { display: none; }

.shared-mix { margin-top: 24px; padding: 16px; border: 2px solid var(--ink); }

.shared-mix[hidden] { display: none; }

.shared-mix p { margin: 0; font-weight: 550; }

.shared-mix .actions { margin-top: 12px; }

footer { margin-top: 36px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 0.85rem; color: var(--muted); }

@media (max-width: 520px) {
	.studio { width: min(100% - 32px, 820px); padding-top: 72px; }
	.artwork-sync { margin-top: 28px; }
}

@media (prefers-reduced-motion: reduce) {
	.actions button { transition: none; }
}
