/* ButtonBox.css */

.lh-box {
	position: fixed;
	top: 12px;
	right: 12px;
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
	justify-content: flex-end;
	left: 12px;
	box-sizing: border-box;
	max-width: none;
	width: calc(100vw - 24px);
	padding: 6px 8px;
	border-radius: 10px;
	background: rgba(247, 247, 247, 0.72);
	border: 1px solid rgba(208, 208, 208, 0.72);
	font: 14px/1 system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
	z-index: 9999;
	user-select: none;
}

.lh-box button {
	height: 28px;
	min-width: 28px;
	border: 1px solid #bbb;
	border-radius: 6px;
	background: rgba(255, 255, 255, 0.82);
	cursor: pointer;
	font-size: 16px;
	line-height: 1;
	white-space: nowrap;
}

.lh-box button#layoutSave,
.lh-box button#layoutLoad,
.lh-box button#layoutReset {
	padding: 0 10px;
	font-size: 13px;
	width: auto;
}

.lh-box span#lhValue {
	display: inline-block;
	min-width: 4ch;
	text-align: center;
	font-variant-numeric: tabular-nums;
	color: #000;
	font-weight: 600;
}

.lh-box select#gamepad-slot,
.lh-box select#gamepad-config {
	height: 28px;
	max-width: 260px;
	border: 1px solid #bbb;
	border-radius: 6px;
	background: rgba(255, 255, 255, 0.82);
	color: #000;
	padding: 0 8px;
	font: 13px/1 system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

.lh-box .gamepad-status.config-error {
	color: #800;
	font-weight: 700;
}

#gamepad-config-notice {
	position: fixed;
	left: 50%;
	top: 16px;
	transform: translateX(-50%);
	z-index: 2147483647;
	box-sizing: border-box;
	max-width: min(92vw, 720px);
	padding: 10px 14px;
	border: 2px solid #8fcf8f;
	border-radius: 6px;
	background: rgba(0, 32, 0, .92);
	color: #fff;
	font: 14px Consolas, "Courier New", monospace;
	text-align: center;
	white-space: normal;
	box-shadow: 0 4px 18px rgba(0,0,0,.8);
	opacity: 0;
	pointer-events: none;
	transition: opacity .16s ease-out;
}

#gamepad-config-notice.active {
	opacity: 1;
}

#gamepad-config-notice.error {
	border-color: #ff9a9a;
	background: rgba(64, 0, 0, .94);
}
