/* ==========================================================================
 * Jeu du jour : l'icone du bandeau (pastille, aura) et la page image_du_jour.php.
 * Aide : l'icone du bandeau, juste a droite de celle du jeu (page aide.php).
 *
 * Feuille a part, chargee par include/inc_entete.php sur toutes les pages (pour
 * les icones) : monmixtcg.css n'est pas touche.
 * ========================================================================== */

/* ---------- Les icones du bandeau : le jeu, puis l'aide, avant l'avatar ---- */

.bandeau-jeu,
.bandeau-aide {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	flex: 0 0 auto;
	margin-right: 6px;
	border-radius: 50%;
	color: #fff;
	background: rgba(255, 255, 255, .16);
	box-shadow: 0 0 0 2px rgba(255, 255, 255, .55);
	text-decoration: none;
	transition: box-shadow .15s ease, background .15s ease;
}

.bandeau-jeu:hover,
.bandeau-jeu:focus-visible,
.bandeau-jeu-actif,
.bandeau-aide:hover,
.bandeau-aide:focus-visible,
.bandeau-aide-actif {
	background: rgba(255, 255, 255, .3);
	box-shadow: 0 0 0 3px #fff;
}

.bandeau-jeu svg,
.bandeau-aide svg {
	display: block;
	width: 22px;
	height: 22px;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

/* Pastille : la regle commune (menu-bas.css) la place par rapport a un parent
 * relatif ; ici le parent est le rond de 36 px. */
.bandeau-jeu .pastille-notif {
	top: -6px;
	right: -6px;
}

/* L'aura : un halo dore qui respire, tant que le jeu du jour n'est pas joue. */
.bandeau-jeu-aura {
	box-shadow: 0 0 0 2px rgba(255, 255, 255, .7),
		0 0 8px 3px rgba(253, 224, 71, .6),
		0 0 18px 8px rgba(167, 139, 250, .45);
	animation: jeu-aura 2.4s ease-in-out infinite;
}

@keyframes jeu-aura {
	0%, 100% {
		box-shadow: 0 0 0 2px rgba(255, 255, 255, .7),
			0 0 6px 2px rgba(253, 224, 71, .45),
			0 0 12px 4px rgba(167, 139, 250, .3);
	}
	50% {
		box-shadow: 0 0 0 2px rgba(255, 255, 255, .9),
			0 0 12px 5px rgba(253, 224, 71, .8),
			0 0 24px 11px rgba(167, 139, 250, .6);
	}
}

@media (prefers-reduced-motion: reduce) {
	.bandeau-jeu-aura {
		animation: none;
	}
}

/* TELEPHONE ETROIT : LE TITRE ET QUATRE ICONES (jeu, aide, avatar, deconnexion)
 *
 * Ils ne tiennent pas sur une ligne de 360 px avec les dimensions du grand ecran :
 * le bandeau debordait a droite. On resserre l'ensemble — ronds de 32 px au lieu de
 * 36, marges et ecarts reduits, titre un peu plus petit. */
@media (max-width: 480px) {
	.bandeau {
		gap: 10px;
		padding-left: 18px;
		padding-right: 18px;
	}

	.bandeau h1 {
		font-size: 22px;
	}

	.bandeau-droite {
		gap: 8px;
	}

	.bandeau-jeu,
	.bandeau-aide {
		width: 32px;
		height: 32px;
		margin-right: 0;
	}

	.bandeau-jeu svg,
	.bandeau-aide svg {
		width: 20px;
		height: 20px;
	}

	.bandeau-avatar {
		width: 32px;
		height: 32px;
	}
}

/* Les tout petits ecrans (320 px) : un cran de plus. */
@media (max-width: 340px) {
	.bandeau {
		padding-left: 14px;
		padding-right: 14px;
	}

	.bandeau h1 {
		font-size: 19px;
	}
}

/* ---------- La page ------------------------------------------------------- */

.jeu {
	max-width: 520px;
	margin: 0 auto;
}

.jeu-consigne {
	text-align: center;
}

.jeu-image {
	margin: 12px auto;
	padding: 6px;
	border-radius: 14px;
	background: #fff;
	border: 1px solid #e4e0f3;
	box-shadow: 0 6px 18px rgba(80, 50, 150, .15);
	text-align: center;
}

.jeu-image img {
	display: block;
	max-width: 100%;
	max-height: 360px;
	margin: 0 auto;
	border-radius: 10px;
}

.jeu-sans-image {
	padding: 40px 12px;
	color: #6b6880;
}

.jeu-choix {
	margin: 0 0 12px;
	padding: 0;
	border: 0;
}

.jeu-choix legend {
	margin-bottom: 8px;
	padding: 0;
	font-weight: 700;
}

.jeu-option {
	display: flex;
	align-items: center;
	gap: 10px;
	margin: 0 0 8px;
	padding: 12px 14px;
	border: 2px solid #e4e0f3;
	border-radius: 12px;
	background: #fff;
	cursor: pointer;
}

.jeu-option input {
	flex: 0 0 auto;
	width: 18px;
	height: 18px;
	margin: 0;
}

.jeu-option:hover {
	border-color: #c4b5fd;
}

.jeu-option:has(input:checked) {
	border-color: #6d28d9;
	background: #f3effd;
}

.jeu-option:focus-within {
	outline: 2px solid #6d28d9;
	outline-offset: 2px;
}

.jeu-resultat {
	margin: 12px 0;
	padding: 12px 14px;
	border-radius: 12px;
	text-align: center;
}

.jeu-gagne {
	background: #ecfdf5;
	border: 1px solid #86efac;
}

.jeu-perdu {
	background: #fff1f2;
	border: 1px solid #fda4af;
}
