@keyframes gradient {
	0% {
		background-position: 0% 50%;
	}
	50% {
		background-position: 100% 50%;
	}
	100% {
		background-position: 0% 50%;
	}
}
@keyframes rotation {
	0% {
		transform: rotate(0deg);
	}
	100% {
		transform: rotate(360deg);
	}
}
@keyframes changement {
	0% {
		transform: rotate3d(1,0,0,0deg);
	}
	50% {
		transform: rotate3d(1,0,0,180deg);
	}
	100% {
		transform: rotate3d(1,0,0,180deg);
	}
}
@keyframes chronoPortableAnim {
	from {
		width: 0%;
		background: #00a300;
	}
	49% {
		background: #00a300;
	}
	50% {
		background: #cc6600;
	}
	79% {
		background: #cc6600;
	}
	80% {
		background: #cc0000;
	}
	to {
		width: 100%;
		background: #cc0000;
	}
}

:root {
	--actuelGradient: #ffc107;
	--palierGradient: #1456ff;
	--passeGradient : #000;

	--select: #fd7e14;
	--correct: #5cb85c;
}

* {
	padding: 0;
	margin: 0;
	box-sizing: border-box;
}

/*
1 - 2 = 1456ff
3 - 7 = 0032b3
8 - 12 = 00113D
*/

body {
	text-align: center;
	height: 100dvh;
	overflow: hidden;
	color: #1456ff;
	background-color: currentColor;
	transition: color 1.5s;
	/* background: linear-gradient(#0b0033, #2D00A3); */
}
body.wrong {
	transition: color 0.5s;
}

@supports (background-blend-mode: overlay) {
    body {
        background-image: radial-gradient(white, black);
        background-size: 300% 300%;
        animation: gradient 10s ease infinite;
        background-blend-mode: overlay;
    }
}

/* DÉBUT */

#menu {
	width: 100vw;
	height: 100%;
	display: flex;
	align-items: center;
	justify-content: space-evenly;
	background: linear-gradient(-45deg, #02849b, #03224c);
	background-size: 400% 400%;
	animation: gradient 7s ease infinite;
	overflow: hidden;
	position: relative;
}

#statsJeu {
	width: 95%;
	height: 100%;
	margin: 0 auto;
	display: none;
	flex-direction: column;
    justify-content: space-evenly;
}
#statsJeu > * {
	text-align: center;
	clip-path: polygon(5% 0, 95% 0, 100% 50%, 95% 100%, 5% 100%, 0 50%);
	background: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, 1) 10% 90%, transparent 100%);
	color: white;
	padding: 5px 0;
}
#statsJeu p {
	font-weight: 600;
	font-size: 1.5rem;
}

#valQuestion {
	background: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, 1) 10% 90%, transparent 100%);
}
#valJoueur {
	background: linear-gradient(90deg, transparent 0%, var(--actuelGradient) 10% 90%, transparent 100%);
}
#valJoueur p {
	color: black;	
}

#illustration, #illustrationJeu {
	position: relative;
	width: 25%;
	height: 100%;
	transition: width 1.5s;
	transition-timing-function: ease-in-out;
}

.symbols {
	transform-origin: center;
	animation: rotation 30s linear infinite;
}
.rayons {
	transform-origin: center;
	animation: rotation 30s linear infinite;
	animation-direction: reverse;
}

.expressImg {
	position: absolute;
	width: 50%;
	top: 53.5%;
}

#menu article {
	width: 30%;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
}

#menu .pdf {
	width: 100%;
	margin-bottom: 20px;
}

#menu #settings {
	position: absolute;
	width: 30%;
	height: 232px;
	background: white;
	display: flex;
	flex-direction: column;
	justify-content: space-evenly;
}

#menu #settings > div {
	display: flex;
	flex-direction: column;
	justify-content: space-evenly;
}

#settings i {
	cursor: pointer;
}

#menu #sonDiv, #menu #expressDiv {
	width: 30%;
	margin: 0 auto;
	display: flex;
	justify-content: space-between;
	font-family: LexendM;
	font-size: 1.5rem;
}

#menu #express {
	transform: scale(1.5);
}

#menu button {
	width: 100%;
	font-size: 1.2rem;
	font-family: "CopperplateG";
	border: 3px solid white;
	background: black;
	color: white;
	transition: color 0.5s, background 0.5s, border-color 0.5s;
	padding: 10px 0;
	cursor: pointer;
}

#start a button {
	background: #03224c;
	border-color: white;
}

#menu button:not(button:last-child) {
	margin-bottom: 20px;
}

#menu #settings button {
	width: 30%;
	margin: 0 auto;
}


#bouton-sound {
	display: flex;
	align-items: center;
	gap: 10px;
}

/* Container du switch */
.switch {
    position: relative;
    display: inline-block;
    width: 3.2em;
    height: 1.8em;
	margin: 0;
}

/* Masquer l'input */
.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0;
    right: 0; bottom: 0;
    background-color: #cc0000;
    transition: 0.25s;
    border-radius: 2em;
}

/* Bouton circulaire à l'intérieur */
.slider:before {
    position: absolute;
    content: "";
    height: 1.4em;
    width: 1.4em;
    left: 0.2em;
    bottom: 0.2em;
    background-color: white;
    transition: 0.25s;
    border-radius: 50%;
	transform: translateX(1.4em);
}

/* État ON */
input:checked + .slider {
    background-color: #5cb85c;
}

/* Déplacement du bouton quand ON */
input:checked + .slider:before {
    transform: translateX(0);
}

#start {
	width: 100%;
	display: flex;
	justify-content: center;
	margin-bottom: 20px;
}

#start a {
	width: 100%;
	margin-right: 50px;
}

.aspiration {
	transform: scale(5);
	opacity: 0;
	border-radius: 50%;
	transition: all 4.5s;
}

.aspiration > article:last-child {
	display: none;
}

.cache {
	display: none;
}

/* PIVOT */

#pivot {
	height: 100%;
	transform-style: preserve-3d;
	display: flex;
	justify-content: center;
	align-items: center;
}

#pivot * {
	backface-visibility: hidden;
}

.rotation {
	transition: transform 1s;
	transform: rotate3d(0, 1, 0, 180deg);
}

#resultatSection {
	position: absolute;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100%;
	transform: rotate3d(0, 1, 0, 180deg);
	background-image: radial-gradient(#1456ff, #0032b3 30%, #00113d 70%);
	background-repeat: no-repeat;
}
#resultatSection::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image: radial-gradient(circle at center, rgb(0, 0, 0), transparent 75%), url("../img/background.svg");
	background-repeat: no-repeat;
	background-position: center center;
	background-size: 100%;
	opacity: 0.3;
	z-index: -1;
}

#resultatSection img {
	height: clamp(30px,4.5vw,76px);
	margin-left: clamp(5px,2vw,15px);
}

/* QUIZ */

#left {
	width: 100%;
	height: 100%;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	align-items: center;
	overflow-y: hidden;
}

#illustration svg, #illustrationJeu svg {
	max-height: 100%;
	max-width: 100%;
}

section {
	width: 90%;
	height: 85%;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

#qcm {
	width: 100%;
}

#question {
	/* height: 150px; */
	width: 95%;
	/* background-color: black; */
	background: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, 1) 10% 90%, transparent 100%);
	color: white;
	margin: 1vh auto;
	font-family: LexendM;
	display: flex;
	justify-content: center;
	align-items: center;
	text-align: center;
	border-radius: 25px;
	padding: 20px 5%;
	clip-path: polygon(5% 0, 95% 0, 100% 50%, 95% 100%, 5% 100%, 0 50%);
}

article h1 {
	font-size: clamp(1rem,2vw,2rem);
}

#answer {
	width: 95%;
	display: flex;
	justify-content: space-between;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
	margin: auto;
}

article div[id*="rep"] {
	position: relative;
	width: 49%;
	background: linear-gradient(90deg, transparent 0%, #000000 10% 90%, transparent 100%);
	display: flex;
	justify-content: flex-start;
	align-items: center;
	padding: 10px 0 10px 2.5%;
	cursor: default;
	clip-path: polygon(5% 0, 95% 0, 100% 50%, 95% 100%, 5% 100%, 0 50%);
}



/*clamp(1.5rem,3vw,2.5rem)*/
article div[id*="rep"] > p:last-child {
	font-size: clamp(0.5rem,1.5vw,2rem);
	text-align: left;
	display: flex;
	align-items: center;
	transform-origin: left;
	max-width: 630px;
}

article div[id*="rep"] > p {
	font-family: LexendR;
}

article p, article button {
	color: white;
	font-family: "CopperplateG", "Helvetica";
	font-size: clamp(1.25rem,2vw,1.7rem);
}

.lettre {
	color: #fd7e14;
	font-size: clamp(1rem,1.5vw,2rem);
	margin-right: 5px;
}

article#quiz {
	width: 100%;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	align-self: flex-end;
}

#joker {
	width: 95%;
	display: flex;
	justify-content: space-evenly;
	align-items: center;
}

#joker > button {
	border-radius: 50%;
	border: 2px solid skyblue;
	background: black;
	width: clamp(98px,8vw,150px);
	height: clamp(43px,6vh,50px);
	display: flex;
	justify-content: center;
	align-items: center;
	padding: 0 10px;
}

	/* chrono ordi */

#chrono {
	border-radius: 100%;
	color: white;
	width: 250px;
	height: 250px;
	position: relative;
	overflow: hidden;
}

#chrono > #chronoBackground {
	background: radial-gradient(#555,#000);
	width: 100%;
	height: 100%;
/*	transform: rotateY(180deg);*/
/*	animation: chronoDesktopAnim 15s linear;*/
}

#chrono p {
	font-family: "CopperplateG";
	font-size: 5rem;
	text-shadow: 0 0 10px black;
	z-index: 1;
}

#chrono > #chronoBackground div {
	background-color: black;
	position: relative;
	width: 90%;
	height: 90%;
	border-radius: 100%;
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%,-50%);
	display: flex;
	justify-content: center;
	align-items: center;
}
#chrono > #chronoBackground div::before {
	content: "";
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	background-image: url("../img/background_chrono.svg");
	background-size: 115%;
	background-position: center;
	background-repeat: no-repeat;
	animation: rotation	30s linear infinite;
	opacity: 0.75;
}

/* chrono portable */

#chronoPortable {
	color: white;
	position: relative;
	width: 95%;
	height: clamp(28px,2vw,42px);
	border: 2px solid black;
	border-radius: 25px;
	margin: 0 auto;
	font-size: clamp(1.2rem,5vw,2.5rem);
	font-family: "CopperplateG";
	background: black;
}

#chronoProgress {
	height: 100%;
	position: relative;
	background: red;
	border-radius: 25px;
	mix-blend-mode: exclusion !important;
}

#chronoPortable > p {
	height: auto;
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%,-50%);
}

#pyramideGains {
	display: flex;
	height: 100%;
}

#pyramide {
	margin: auto;
	display: flex;
	flex-direction: column;
	gap: 5px;
	padding: 5px;
	border: 3px solid skyblue;
	border-radius: 5px;
	background: black;
	width: 300px;
	height: 100%;
	max-width: clamp(246px,35vw,300px);
}

#pyramide > div {
	display: flex;
	justify-content: center;
	align-items: center;
	padding: 0 10px;
	height: calc(100% / 12);
	clip-path: polygon(5% 0, 95% 0, 100% 50%, 95% 100%, 5% 100%, 0 50%);
}

#pyramide p {
	color: #ffc107;
}

#pyramide p {
	font-size: clamp(1.2rem,3vw,1.6rem);
	font-weight: 600;
	font-family: "CopperplateG", "Helvetica";
	display: inline;
}

#pyramide .blocArgent {
	transition: width 0.5s, background 0.5s, transform 0.5s, filter 0.5s;
	position: relative;
}

#pyramide .blocArgent.fin {
	background: linear-gradient(90deg, transparent 0%, var(--finGradient) 10% 90%, transparent 100%);
}
#pyramide .blocArgent.fin p {
	color: black;
}

#pyramide .blocArgent:not(#pyramide .actuel, #pyramide .passe) {
	transform: scale(0.9);
}

#pyramide .actuel {
	background: linear-gradient(90deg, transparent 0%, var(--actuelGradient) 10% 90%, transparent 100%) !important;
}
#pyramide .actuel p {
	color: black !important;
}

#pyramide .passe {
	background: linear-gradient(90deg, transparent 0%, var(--passeGradient) 10% 90%, transparent 100%);
	filter: contrast(0.2);
	width: 80%;
    margin: 0 auto;
}
#pyramide .passe p {
	color: var(--actuelGradient);
}

#pyramide .palier {
	background: linear-gradient(90deg, transparent 0%, var(--palierGradient) 10% 90%, transparent 100%);
}
#pyramide .palier p {
	color: white;
}

.sousPyra {
	display: flex;
	align-items: center;
}

.sousPyra img {
	height: clamp(18px,3vw,25px);
	margin: 0 0 0 5px;
}

p.numQuestion {
	display: flex;
	align-items: center;
}

.fa-check {
	font-size: 1rem;
	margin-left: 7px;
}

.score {
	background: #ffc107;
	padding: 1px 5px;
}

.score::before, .passe::before {
	content: "";
	width: 100%;
	height: 100%;
	position: absolute;
	top: 0;
	left: 0;
}

#pyramide .score p {
	color: black !important;
}

.score .cls-1 {
	fill: #ffc107;
}

#answer > div {
	backface-visibility: hidden;
	/* box-shadow: inset 0px 10px 27px -8px #141414; */
	/*inset 3px 3px 10px black, inset -3px -3px 10px black*/
}

#answer > div.select {
	transition: all 0.2s;
	background: linear-gradient(90deg, transparent 0%, var(--select) 10% 90%, transparent 100%);
}

#joker > .select {
	background: var(--select);
}

#answer > div.select p, div.select span, #joker > .select {
	transition: all 0.2s;
	color: black;
}

@keyframes fadeGradient {
	0%, 33.3%, 66.7%, 100% {
		opacity: 1;
	}
	16.7%, 50%, 83.3% {
		opacity: 0;
	}
}

@keyframes colorCorrect {
	0%, 33.3%, 66.7%, 100% {
		color: black;
	}
	16.7%, 50%, 83.3% {
		color: white;
	}
}
@keyframes colorLetterCorrect {
	0%, 33.3%, 66.7%, 100% {
		color: black;
	}
	16.7%, 50%, 83.3% {
		color: var(--select);
	}
}

#answer > div.correct {
	transition: all 0.2s;
	color: black;
}

#answer > div.correct::before {
	content: "";
	position: absolute;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	background: linear-gradient(90deg, transparent 0%, var(--correct) 5% 95%, transparent 100%);
	animation: fadeGradient 1.5s ease-in-out forwards;
}
#answer > div.correct * {
	z-index: 1000;
}

#answer > div.correct p {
	transition: all 0.2s;
	color: black;
}

#answer > div.correct p:not(#answer > div.select p) {
	animation: colorCorrect 1.5s ease-in-out forwards;
}
#answer > div.correct .lettre:not(#answer > div.select .lettre) {
	animation: colorLetterCorrect 1.5s ease-in-out forwards;
}


#joker > button.abandon {
	width: clamp(98px,8vw,150px);
	height: clamp(43px,6vh,50px);
	font-size: clamp(0.8rem,1.8vw,1rem);
	background: #fdf1b8;
	color: black;
	border-color: black;
}

	/* Aside Abandon */

#abandonAside {
	display: none;
	position: absolute;
	top: 0;
	left: 0;
	width: 100vw;
	height: 100vh;
	background: rgba(0, 0, 0, 0.5);
}

#abandonAside > article {
	width: 50%;
	height: 50%;
	background: #fdf1b8;
	color: black;
	display: flex;
	flex-direction: column;
	justify-content: space-around;
	align-items: center;
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%,-50%);
	border-radius: 20px;
}

#abandonAside h1, #abandonAside span, #abandonAside p {
	font-family: "CopperplateG", "Helvetica";
	font-size: clamp(1.5rem,3vw,2.3rem);
}

#abandonAside #sommeBrut {
	width: 75%;
	background: skyblue;
	border: 5px solid black;
	border-radius: 10px;
}

#abandonAside p {
	margin-right: 5px;
}

#abandonAside span, #abandonAside p {
	font-size: clamp(2.3rem,3vw,3rem);
	padding: 10px 0;
	color: black;
}

#abandonAside img {
	height: clamp(32px,3vw,45px);
	margin-left: 7px;
}

#abandonAside div {
	width: 100%;
	display: flex;
	align-items: center;
	justify-content: center;
}

#abandonAside div:last-child {
	justify-content: space-evenly;
}

#abandonAside button {
    font-size: clamp(1rem, 3vw, 2rem);
    padding: 5px;
    border: 2px solid;
    width: 150px;
}

#abandonAside button:first-child {
	background: black;
	border-color: black;
	transition: all 0.5s;
}

#abandonAside button:last-child {
	background: #4d0085;
	border-color: #4d0085;
	transition: all 0.5s;
}

	/* Page Résultat */

article#resultat {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%,-50%);
	width: 100%;
}

article#resultat h1 {
	font-family: "CopperplateG";
	color: white;
}

#pointsNet {
	transform: scale(0.7);
}

article#resultat #sommeNet, #pointsNet {
	width: 75%;
	background: black;
	border-radius: 10px;
	margin: auto;
	padding: 10px 0;
	background: linear-gradient(90deg, transparent 0%, rgba(0, 0, 0, 1) 10% 90%, transparent 100%);
    clip-path: polygon(5% 0, 95% 0, 100% 50%, 95% 100%, 5% 100%, 0 50%);
}

article#resultat p {
	font-size: clamp(2.5rem,6vw,6rem);
	font-family: "CopperplateG", "Helvetica";
	background: -webkit-linear-gradient(#b88b33 19.5%, #e8d3a4 45%, #b88b33 72.3%, #e8d3a4 92.7%, #b88b33);
	-webkit-background-clip: text;
	-webkit-text-fill-color: transparent;
}

#buttonMenu {
	position: absolute;
	bottom: 0;
	left: 50%;
	transform: translateX(-50%);
	margin-bottom: 1vh;
}

#buttonMenu button {
	cursor: pointer;
	font-family: "CopperplateG";
	padding: 10px;
    color: white;
	background: black;
	font-size: clamp(1rem,3vw,2rem);
	border: 2px solid skyblue;
	border-radius: 50%;
}
#buttonMenu .retourMenu {
	max-width: 205px;
}

.fleche {
	transition: margin-right 0.5s;
}

	/* Tableau des Scores */

.btn-classement {
	margin-right: 30px;
}

#tabScoreAside {
	position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0, 0.5);
/*    display: flex;*/
    justify-content: center;
    align-items: center;
    z-index: 1;
    transition: none;
}
#tabScoreAside.cache {
	display: none;
}
#tabScoreAside .fa-times {
	position: absolute;
    padding: 2vh 2vw;
    right: 0;
    top: 0;
    cursor: pointer;
    font-size: 50px;
    color: white;
    transition: transform 0.5s;
}
#tabScoreAside > #tabScore {
	background: white;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
/*    width: 95vw;*/
/*    border-radius: clamp(50px,3vw,0px);*/
}
#tabScore > li {
	width: 100%;
    justify-content: space-between;
    padding: 0 1vw;
    font-size: clamp(25px,3vw,1000000px);
/*    border-radius: clamp(50px,3vw,0px);*/
    margin: auto;
    display: flex;
    align-items: center;
    font-family: LexendM;
}
#tabScoreAside > #itemLeft > p {
	overflow-wrap: break-word;
}

.affichageScore > .itemLeft {
	display: flex;
}

.rang {
	display: flex;
	align-items: center;
	width: clamp(50px,5.5vw,100px);
	margin-right: clamp(20px,2vw,25px);
}

.pseudo {
	margin-right: clamp(20px,6vw,100px);
}

li.premier{
	color: #C29B0C;
}
li.second {
	color: #a0a0a0;
}
li.troiz {
	color: #C49C48;
}

	/* Classe jQuery */

#joker > .used, #joker > .used:hover {
	background: red;
	color: black;
}

.stop {
	pointer-events: none;
}

#menu button:disabled, #menu button:disabled:hover {
	background-color: #ccc;
  	color: #666;
	border-color: #999;
	cursor: not-allowed;
}

@media all and (max-width: 1200px) {
	#buttonMenu {
		display: flex;
		flex-direction: column;
	}
	.btn-classement {
		margin-right: 0;
		margin-bottom: 32px;
	}
}

@media all and (max-width: 1157px) {
	#menu article {
		width: 50%;
	}
}

@media all and (max-width: 950px) {
	#chrono {
		transform: scale(0.7);
	}
	#abandonAside > article {
		width: 80%;
		height: 80%;
	}
}

@media all and (min-width: 769px) {
	article div[id*="rep"]:hover, #joker > button:hover {
		background: #ffff9e;
		color: black;
	}

	article div[id*="rep"]:hover {
		background: linear-gradient(90deg, transparent, #ffff9e 10% 90%, transparent);
	}

	#menu button:hover {
		color: black;
		background: white;
		border-color: black;
	}

	#start a button:hover {
		color: #03224c;
		background: white;
		border-color: #03224c;
	}

	article div[id*="rep"]:hover > p {
		color: black;
	}

	#joker > button.abandon:hover {
		background: black;
		color: #fdf1b8;
		border-color: #fdf1b8;
	}

	#abandonAside button:first-child:hover {
		background: white;
		color: black;
	}

	#abandonAside button:last-child:hover {
		background: white;
		color: #4d0085;
	}

	#buttonMenu button:hover {
		background: #ffff9e;
		color: black;
	}

	button:hover .fleche {
		margin-right: 30px;
	}
}

@media all and (max-width: 768px) {
	section > * {
		flex-shrink: 0;
	}

	section {
		height: 100%;
		width: 98%;
	}

	#menu {
		flex-direction: column;
	}

	#pyramideGains {
		display: none;
		height: 98%;
	    margin: 0 auto;
	}

	#statsJeu {
		display: flex;
	}
	#illustrationJeu {
		display: none;
	}

	#menu #start {
		flex-direction: column-reverse;
	}

	#menu div > :last-child:not(.switch), #bouton-sound {
		margin-bottom: 20px;
	}
}

@media all and (max-width: 756px) {
	#left {
		padding: 10px 0;
	}

	#question {
		min-height: 94px;
	}

	#question > h1 {
		font-size: 1.2rem;
	}

	#answer {
		flex-direction: column;
	}

	#answer > div {
		width: 100%;
		margin: 0;
		max-height: 60px;
		border-radius: 12px;
	}

	article div[id*="rep"] {
		padding: 10px 0 10px 5%;
	}

	article div[id*="rep"] > p:last-child {
		font-size: 1rem;
	}

	#resultatSection::before {
		background-image: radial-gradient(circle at center, rgb(0, 0, 0), transparent 30%), url("../img/background.svg");
		background-size: 200%;
	}

	article#resultat #sommeNet, #pointsNet {
		width: 95%;
	}
}