/* Player page shell. Loaded after the engine's gui.css, whose page-level rules (body, main,
   header, button) were written for wasm-wine's own demo page and are reset here. */
:root {
	--bar: 40px;
	--ink: #101316;
	--ink-2: #1b2025;
	--line: #2c343b;
	--text: #e9ecee;
	--muted: #98a2ab;
	--accent: #ffb0c4;
	--mono: ui-monospace, "SFMono-Regular", "JetBrains Mono", Menlo, Consolas, "Liberation Mono", monospace;
}
html, body { height: 100%; }
body.binsrc-player {
	margin: 0; display: flex; flex-direction: column; overflow: hidden;
	background: var(--ink); color: var(--text); font: 14px/1.4 system-ui, sans-serif;
}

.binsrc-bar {
	flex: 0 0 var(--bar); display: flex; align-items: center; gap: 8px; margin: 0; padding: 0 10px;
	background: var(--ink-2); border-bottom: 1px solid var(--line); min-width: 0;
}
.binsrc-bar__brand {
	font: 600 13px/1 var(--mono); color: var(--text); text-decoration: none; white-space: nowrap;
	overflow: hidden; text-overflow: ellipsis; min-width: 0;
}
.binsrc-bar__brand span { color: var(--accent); }
.binsrc-bar__status {
	flex: 1 1 0; min-width: 0; font-size: 12px; color: var(--muted);
	white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.binsrc-bar button, .binsrc-bar a:not(.binsrc-bar__brand) {
	flex: none; font: 500 12px/1 system-ui, sans-serif; padding: 7px 10px; border-radius: 4px;
	border: 1px solid var(--line); background: transparent; color: var(--text); cursor: pointer; text-decoration: none;
}
.binsrc-bar button:hover:not(:disabled), .binsrc-bar a:not(.binsrc-bar__brand):hover { border-color: var(--muted); }
.binsrc-bar button:disabled { opacity: .45; cursor: default; }
.binsrc-bar :focus-visible, .binsrc-veil button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
[hidden] { display: none !important; }

.binsrc-stage {
	position: relative; flex: 1 1 0; min-height: 0; padding: 0;
	display: flex; align-items: center; justify-content: center;
}
.binsrc-stage .desk-scroll { flex: none; overflow: hidden; max-width: none; }
/* The guest's windows carry their own z-order; keep it inside the desktop so the veil can cover them. */
.binsrc-stage .html-desktop { border: 0; isolation: isolate; }
.binsrc-stage #screen:focus-visible { outline: none; }

.binsrc-veil {
	position: absolute; inset: 0; z-index: 10; display: flex; align-items: center; justify-content: center;
	padding: 24px; background: var(--ink); text-align: center;
}
.binsrc-veil__box { max-width: 46ch; }
.binsrc-veil p { margin: 0 0 16px; color: var(--text); overflow-wrap: anywhere; }
.binsrc-veil button {
	font: 600 14px/1 system-ui, sans-serif; padding: 11px 18px; border: 0; border-radius: 4px;
	background: var(--accent); color: #151214; cursor: pointer;
}
.binsrc-veil__spin {
	width: 28px; height: 28px; margin: 0 auto 16px; border-radius: 50%;
	border: 3px solid var(--line); border-top-color: var(--accent); animation: binsrc-spin .9s linear infinite;
}
@keyframes binsrc-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .binsrc-veil__spin { animation-duration: 3s; } }

/* The engine's print view (Print in a program) must not carry the shell along. */
@media print { .binsrc-bar, .binsrc-veil { display: none !important; } body.binsrc-player { display: block; overflow: visible; background: #fff; } }
