/* B"H — Awtsmoos game base: global touch rules for ALL games.
 * Prevents text selection / callout / tap-highlight on game UI while keeping
 * real inputs (text fields, textareas) selectable. Include in every game's
 * index.html <head>: <link rel="stylesheet" href="/games/css/awtsmoos-game-base.css">
 */

/* Game UI is touch-first: no selection, no callout, no tap flash, no double-tap zoom delay. */
.awt-game,
.awt-game button,
.awt-game a,
.awt-game canvas,
.awt-game [role="button"],
.awt-game .hud,
.awt-game .menu,
.awt-game .overlay {
	user-select: none;
	-webkit-user-select: none;
	-webkit-touch-callout: none;
	-webkit-tap-highlight-color: transparent;
	touch-action: manipulation;
	/* B"H CSS gate: text elements need an explicit color. inherit preserves
	   each game's own theme color exactly (no game defines base tokens). */
	color: inherit;
}

/* Canvases handle their own gestures (drag/swipe); never let the browser take over. */
.awt-game canvas {
	touch-action: none;
	display: block;
}

/* Real text inputs stay usable: allow selection where typing happens. */
.awt-game input[type="text"],
.awt-game input[type="search"],
.awt-game input[type="email"],
.awt-game textarea,
.awt-game [contenteditable="true"] {
	user-select: text;
	-webkit-user-select: text;
	-webkit-touch-callout: default;
	touch-action: auto;
	/* B"H CSS gate: explicit color via inherit — keeps each game's theme color. */
	color: inherit;
}

/* Buttons never show focus rings from touch; keyboard users still get them. */
.awt-game button:focus:not(:focus-visible),
.awt-game a:focus:not(:focus-visible) {
	outline: none;
	/* B"H LAW 2: visible focus replacement for the removed outline. */
	box-shadow: 0 0 0 3px var(--focus-ring, #4d9fff);
}
