@import url('https://fonts.googleapis.com/css?family=Consolas');

body {
	font-family: 'Consolas', monospace;
	margin: 0;
	padding: 0;
}

.theme-dark {
	background-color: rgb(43, 43, 43);
	color: #fff;
}

.theme-light {
	background-color: rgb(207, 207, 207);
	color: #000;
}

.skills {
	margin-bottom: 2px;
	display: inline-block;
}

#terminal {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	width: 90%;
	max-width: 60vw;
	height: 70%;
	max-height: 60vh;
	border-radius: 10px;
	overflow: hidden;
}

.barrel-roll {
	animation: barrelRoll 1s ease-in-out;
}

@keyframes barrelRoll {
	from {
		transform: translate(-50%, -50%) rotate(0);
	}
	to {
		transform: translate(-50%, -50%) rotate(360deg);
	}
}

.terminal-body {
	font-size: 16px;
}

.theme-dark #terminal {
	background-color: black;
	box-shadow: 0px 0px 30px rgba(0, 0, 0, 0.5);
	color: white;
}

.theme-light #terminal {
	background-color: rgb(240, 240, 240);
	box-shadow: 0px 0px 30px rgba(145, 145, 145, 0.5);
	color: black;
}

.terminal-header {
	height: 30px;
	background-color: #fff;
	color: #000;
	display: flex;
	align-items: center;
	padding: 0 10px;
}

.terminal-header span {
	flex: 1;
	text-align: center;
	font-weight: bolder;
}

.button {
	height: 10px;
	width: 10px;
	border-radius: 50%;
	margin-right: 5px;
}

/*light-theme*/
.theme-light ::-webkit-scrollbar {
	width: 10px;
	background-color: rgb(240, 240, 240);
}

.theme-light ::-webkit-scrollbar-thumb {
	background-color: rgb(209, 209, 209);
	border-radius: 5px;
}

/*dark-theme*/
.theme-dark ::-webkit-scrollbar {
	width: 10px;
	background-color: #000000;
}

.theme-dark ::-webkit-scrollbar-thumb {
	background-color: rgb(24, 24, 24);
	border-radius: 5px;
}

.close {
	background-color: #ff3b3b;
}

.minimize {
	background-color: #ffc200;
}

.expand {
	background-color: #00ca00;
}

.terminal-body {
	height: calc(100% - 30px);
	padding: 10px;
	overflow-y: auto;

}

/*dark-theme*/
.theme-dark a {
	color: white;
	text-decoration: none;
}

.theme-dark a:visited {
	color: white;
	font-weight: bold;
}

.theme-dark a:hover {
	font-style: italic;
	color: white;
}

.theme-dark a:visited:hover {
	font-style: italic;
	color: white;
	text-decoration: none;
}

/*light-theme*/
.theme-light a {
	color: black;
	text-decoration: none;
}

.theme-light a:visited {
	color: black;
	font-weight: bold;
	text-decoration: none;
}

.theme-light a:hover {
	font-style: italic;
	color: black;
}

.theme-light a:visited:hover {
	font-style: italic;
	color: black;
	font-weight: bold;
	text-decoration: none;
}

.terminal-body p {
	margin: 0;
	line-height: 1.5;
}

.label-text {
	display: inline-block;
	width: 150px;
	font-family: 'Consolas', monospace;
	text-align: right;
	padding-right: 10px;
	white-space: nowrap;
}

#userInput {
	font-family: 'Consolas', monospace;
	background-color: transparent;
	border: none;
	outline: none;
	padding: 8px;
	font-size: 16px;
	width: calc(100% - 200px);
}

.theme-dark #userInput {
	color: #fff;
}

.theme-light #userInput {
	color: black;
}

/*hacker-theme*/
.theme-hacker {
	background-color: #000;
	color: #00ff41;
}

.theme-hacker #terminal {
	background-color: #000;
	box-shadow: 0 0 30px rgba(0, 255, 65, 0.4);
	color: #00ff41;
}

.theme-hacker #userInput {
	color: #00ff41;
}

.theme-hacker a,
.theme-hacker a:visited,
.theme-hacker a:hover,
.theme-hacker a:visited:hover {
	color: #39ff14;
	text-decoration: none;
}

.theme-hacker ::-webkit-scrollbar {
	width: 10px;
	background-color: #000;
}

.theme-hacker ::-webkit-scrollbar-thumb {
	background-color: #0a3d0a;
	border-radius: 5px;
}

.theme-portal {
	background-color: #102b3b;
	color: #ffad42;
}

.theme-portal #terminal {
	background-color: #071923;
	box-shadow: 0 0 30px rgba(0, 168, 224, 0.45), 0 0 8px rgba(255, 153, 0, 0.3);
	color: #ffad42;
}

.theme-portal .terminal-header {
	background-color: #123b52;
	color: #ffad42;
}

.theme-portal #userInput {
	color: #ffad42;
	caret-color: #00b9e8;
}

.theme-portal a,
.theme-portal a:visited,
.theme-portal a:hover,
.theme-portal a:visited:hover {
	color: #00b9e8;
	text-decoration: none;
}

.theme-portal ::-webkit-scrollbar {
	width: 10px;
	background-color: #071923;
}

.theme-portal ::-webkit-scrollbar-thumb {
	background-color: #e88716;
	border-radius: 5px;
}

/*rainbow theme (tous les succès débloqués)*/
.theme-rainbow {
	background-color: #0a0a0a;
	color: #fff;
}

.theme-rainbow #terminal {
	background-color: #0a0a0a;
	color: #fff;
	border: 3px solid transparent;
	box-shadow: 0 0 45px 8px rgba(255, 0, 128, 0.5);
	animation: rainbowHue 5s linear infinite;
}

.theme-rainbow .terminal-header {
	background: linear-gradient(90deg, #ff005c, #ff9900, #fff700, #22ff00, #00e5ff, #7000ff, #ff005c);
	background-size: 400% 100%;
	color: #000;
	animation: rainbowSlide 4s linear infinite;
}

.theme-rainbow #userInput {
	color: #fff;
}

.theme-rainbow a,
.theme-rainbow a:visited,
.theme-rainbow a:hover,
.theme-rainbow a:visited:hover {
	color: #00e5ff;
	text-decoration: none;
}

.theme-rainbow ::-webkit-scrollbar {
	width: 10px;
	background-color: #0a0a0a;
}

.theme-rainbow ::-webkit-scrollbar-thumb {
	background: linear-gradient(180deg, #ff005c, #00e5ff);
	border-radius: 5px;
}

@keyframes rainbowHue {
	from {
		filter: hue-rotate(0deg);
	}
	to {
		filter: hue-rotate(360deg);
	}
}

@keyframes rainbowSlide {
	from {
		background-position: 0% 0;
	}
	to {
		background-position: 400% 0;
	}
}

/*achievement (konami code)*/
.achievement {
	position: fixed;
	top: 20px;
	left: 50%;
	transform: translateX(-50%);
	z-index: 100000;
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 12px 16px;
	border: 1px solid #00ff41;
	border-radius: 6px;
	background-color: rgba(0, 0, 0, 0.85);
	color: #00ff41;
	font-weight: bold;
	box-shadow: 0 0 20px rgba(0, 255, 65, 0.35);
	animation: achievementIn 0.5s ease-out both, achievementPulse 1.2s ease-in-out infinite alternate;
}

.achievement-icon {
	font-size: 1.5em;
	animation: achievementSpin 0.8s ease-out both;
}

.achievement-hide {
	animation: achievementOut 0.6s ease-in forwards;
}

@keyframes achievementIn {
	from {
		opacity: 0;
		transform: translateX(-50%) translateY(-15px) scale(0.9);
	}
	to {
		opacity: 1;
		transform: translateX(-50%) translateY(0) scale(1);
	}
}

@keyframes achievementOut {
	to {
		opacity: 0;
		transform: translateX(-50%) translateY(-15px) scale(0.9);
	}
}

@keyframes achievementPulse {
	from {
		box-shadow: 0 0 12px rgba(0, 255, 65, 0.25);
	}
	to {
		box-shadow: 0 0 26px rgba(0, 255, 65, 0.6);
	}
}

@keyframes achievementSpin {
	from {
		transform: rotate(-360deg) scale(0);
	}
	to {
		transform: rotate(0) scale(1);
	}
}

.achievement-grand {
	border: none;
	background: linear-gradient(90deg, #ff005c, #ff9900, #fff700, #22ff00, #00e5ff, #7000ff, #ff005c);
	background-size: 300% 100%;
	color: #000;
	font-size: 1.1em;
	padding: 16px 22px;
	animation: rainbowSlide 3s linear infinite, achievementIn 0.5s ease-out both;
}

#output {
	margin-top: 10px;
}

#videoBackground {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	z-index: -1;
	object-fit: cover;
}

#videoOverlay {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(0, 0, 0, 0.68);
	pointer-events: none;
	z-index: -1;
}

#curtain {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100vh;
	background-color: black;
	z-index: 9999;
	transition: transform 1s ease-in-out;
}

#content {
	position: relative;
	z-index: 10000;
	text-align: center;
	padding-top: 40vh;
	color: white;
}

#content h1 {
	font-size: clamp(2rem, 6vw, 4rem);
	font-weight: 700;
	letter-spacing: 3px;
	text-transform: uppercase;
	margin: 0 auto 0.5rem;
	background: linear-gradient(90deg, #00c6ff, #7d5fff, #00ffa3);
	background-size: 200% auto;
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: transparent;
	animation: titleFadeIn 1.2s ease-out both, titleGradient 6s linear infinite, titleGlow 3s ease-in-out infinite alternate;
}

#content .subtitle {
	font-size: clamp(1rem, 2.5vw, 1.5rem);
	font-weight: 400;
	letter-spacing: 6px;
	margin: 0 auto 2.5rem;
	color: rgba(255, 255, 255, 0.75);
	text-transform: uppercase;
	animation: titleFadeIn 1.2s ease-out 0.3s both;
}

@keyframes titleFadeIn {
	from {
		opacity: 0;
		transform: translateY(-25px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@keyframes titleGradient {
	to {
		background-position: 200% center;
	}
}

@keyframes titleGlow {
	from {
		filter: drop-shadow(0 0 6px rgba(0, 198, 255, 0.35));
	}
	to {
		filter: drop-shadow(0 0 20px rgba(125, 95, 255, 0.7));
	}
}

h1 {
	font-size: 36px;
}

div {
	z-index: 1;
}

/*easter egg*/
#easter-egg {
	display: none;
	position: fixed;
	inset: 0;
	width: 100vw;
	height: 100vh;
	overflow: hidden;
	background: #000;
	z-index: 10000;
}

#easter-egg>img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

#returnToTerminal {
	position: fixed;
	top: 16px;
	right: 16px;
	z-index: 10001;
	padding: 8px 12px;
	border: 1px solid rgba(255, 255, 255, 0.45);
	border-radius: 4px;
	background: rgba(0, 0, 0, 0.65);
	color: #fff;
	font: inherit;
	font-size: 14px;
	backdrop-filter: blur(6px);
}

#returnToTerminal:hover {
	background: rgba(0, 0, 0, 0.85);
	border-color: #fff;
}

#naviCursor {
	position: fixed;
	left: 0;
	top: 0;
	width: 68px;
	height: 68px;
	object-fit: contain;
	pointer-events: none;
	user-select: none;
	z-index: 100001;
	will-change: left, top, transform;
}

#naviCursor[hidden] {
	display: none;
}

/*motherlode easter egg*/
.money-rain {
	position: fixed;
	inset: 0;
	overflow: hidden;
	pointer-events: none;
	z-index: 100002;
}

.money-symbol {
	position: absolute;
	top: -10%;
	color: #2ecc71;
	font-weight: bold;
	text-shadow: 0 0 6px rgba(46, 204, 113, 0.8);
	animation-name: moneyFall;
	animation-timing-function: linear;
	animation-fill-mode: forwards;
}

@keyframes moneyFall {
	from {
		transform: translateY(-10vh) rotate(0deg);
		opacity: 0;
	}
	10% {
		opacity: 1;
	}
	to {
		transform: translateY(110vh) rotate(360deg);
		opacity: 0.9;
	}
}

/*snake game*/
#snakeGame {
	display: none;
	justify-content: center;
	align-items: center;
}

.buttonGame {
	display: none;
	color: rgb(105, 105, 105);
	padding: 5px;
}

.buttonGame:hover {
	color: rgb(255, 255, 255);
}

canvas {
	padding: 2px;
	border: 1px solid #313131;
}

button {
	position: relative;
	border: none;
	background: transparent;
	padding: 0;
	cursor: pointer;
	outline-offset: 4px;
	transition: filter 250ms;
	user-select: none;
	touch-action: manipulation;
}

.shadow {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	border-radius: 12px;
	background: hsla(0, 0%, 0%, 0.25);
	will-change: transform;
	transform: translateY(2px);
	transition: transform 600ms cubic-bezier(.3, .7, .4, 1);
}

.edge {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	border-radius: 12px;
	background: linear-gradient(to left, hsl(190deg 100% 16%) 0%, hsl(190deg 100% 30%) 8%, hsl(190deg 100% 30%) 92%, hsl(190deg 100% 16%) 100%);
}

.front {
	display: block;
	position: relative;
	padding: 12px 30px;
	border-radius: 12px;
	font-size: 1.1rem;
	font-weight: 700;
	letter-spacing: 2px;
	text-transform: uppercase;
	color: #042630;
	background: hsl(187deg 92% 50%);
	box-shadow: 0 0 18px rgba(0, 224, 255, 0.5);
	will-change: transform;
	transform: translateY(-4px);
	transition: transform 600ms cubic-bezier(.3, .7, .4, 1), box-shadow 250ms ease;
}

button:hover {
	filter: brightness(110%);
}

button:hover .front {
	transform: translateY(-6px);
	box-shadow: 0 0 28px rgba(0, 224, 255, 0.8);
	transition: transform 250ms cubic-bezier(.3, .7, .4, 1.5), box-shadow 250ms ease;
}

button:active .front {
	transform: translateY(-2px);
	transition: transform 34ms;
}

button:hover .shadow {
	transform: translateY(4px);
	transition: transform 250ms cubic-bezier(.3, .7, .4, 1.5);
}

button:active .shadow {
	transform: translateY(1px);
	transition: transform 34ms;
}

button:focus:not(:focus-visible) {
	outline: none;
}


@media screen and (max-width: 600px) {
	h1 {
		font-size: 24px;
		margin: 2rem;
	}

	.terminal-header>span {
		font-size: 14px;
	}

	#content {
		padding-top: 30vh;
	}

	#terminal {
		width: 95%;
		height: 95%;
		max-width: 100vw;
		max-height: 2000px;
	}

	#userInput {
		font-size: 14px;
	}

	.terminal-body {
		font-size: 14px;
	}

	.label-text {
		width: auto;
		padding-right: 5px;
	}

	#easter-egg>img {
		width: 100%;
	}
}

@media screen and (max-height: 600px) {

	label {
		font-size: 14px;
	}

	.terminal-header>span {
		font-size: 14px;
	}

	#content {
		padding-top: 20vh;
	}

	#terminal {
		width: 95%;
		height: 95%;
		max-width: 100vw;
		max-height: 2000px;
	}

	#userInput {
		font-size: 14px;
	}

	.terminal-body {
		font-size: 14px;
	}

	.label-text {
		width: auto;
		padding-right: 5px;
	}

	#easter-egg>img {
		width: 100%;
	}
}