
body {
	margin: 0;
	background-color: #000;
	background-image: radial-gradient(ellipse at top, #335476 0.0%, #31506e 11.1%, #304b67 22.2%, #2f4760 33.3%, #2d4359 44.4%, #2c3f51 55.6%, #2a3a4a 66.7%, #293643 77.8%, #28323d 88.9%, #262e36 100.0%);
	height: 100%;
	overflow: hidden;

	font-family: monospace;
	font-weight: bold;
	letter-spacing: 0.06em;
	color: rgba(255, 255, 255, 0.75);
}

#c {
	display: block;
	touch-action: none;
	transform: translateZ(0);
}


/*/////////////////////
//        HUD        //
/////////////////////*/


.hud__score,
.pause-btn {
	position: fixed;
	font-size: calc(14px + 2vw + 1vh);
}

.hud__score {
	top: 0.65em;
	left: 0.65em;
	pointer-events: none;
	user-select: none;
	line-height: 1.6;
}

.cube-count-lbl {
	font-size: 0.46em;
}

.best {
	font-size: 0.46em;
}

.pause-btn {
	position: fixed;
	top: 66px;
	right: 0;
	padding: 0.8em 0.65em;
}

.pause-btn > div {
	position: relative;
	width: 0.8em;
	height: 0.8em;
	opacity: 0.75;
}

.pause-btn > div::before,
.pause-btn > div::after {
	content: '';
	display: block;
	width: 34%;
	height: 100%;
	position: absolute;
	background-color: #fff;
}

.pause-btn > div::after {
	right: 0;
}

.slowmo {
	position: fixed;
	bottom: 0;
	width: 100%;
	pointer-events: none;
	opacity: 0;
	transition: opacity 0.4s;
	will-change: opacity;
}

.slowmo::before {
	content: 'SLOW-MO';
	display: block;
	font-size: calc(8px + 1vw + 0.5vh);
	margin-left: 0.5em;
	margin-bottom: 8px;
}

.slowmo::after {
	content: '';
	display: block;
	position: fixed;
	bottom: 0;
	width: 100%;
	height: 1.5vh;
	background-color: rgba(0, 0, 0, 0.25);
	z-index: -1;
}

.slowmo__bar {
	height: 1.5vh;
	background-color: rgba(255, 255, 255, 0.75);
	transform-origin: 0 0;
}



/*/////////////////////
//       MENUS       //
/////////////////////*/

.menus::before {
	content: '';
	pointer-events: none;
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	left: 0;
	background-color: #000;
	opacity: 0;
	transition: opacity 0.2s;
	transition-timing-function: ease-in;
}

.menus.has-active::before {
	opacity: 0.08;
	transition-duration: 0.4s;
	transition-timing-function: ease-out;
}

.menus.interactive-mode::before {
	opacity: 0.02;
}



/* Menu containers */
.menu {
	pointer-events: none;
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	left: 0;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	user-select: none;
	text-align: center;
	color: rgba(255, 255, 255, 0.9);
	opacity: 0;
	visibility: hidden;
	transform: translateY(30px);
	transition-property: opacity, visibility, transform;
	transition-duration: 0.2s;
	transition-timing-function: ease-in;
}

.menu.active {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
	transition-duration: 0.4s;
	transition-timing-function: ease-out;
}

.menus.interactive-mode .menu.active {
	opacity: 0.6;
}

.menus:not(.interactive-mode) .menu.active > * {
	pointer-events: auto;
}


/* Common menu elements */

h1 {
	font-family: 'Courier New', monospace;
	font-weight: bold;
	font-size: 5rem;
	/* letter-spacing: 0.1em; */
	text-transform: uppercase;
	color: #f0f0f0;;
	margin: 0.5em 0;
	position: relative;
	text-shadow: 
		3px 3px 0 #b0b0b0, /* Medium grey shadow */
		6px 6px 0 #808080;  /* Darker grey for depth */
	transform: skew(-5deg);
}

h1::before {
	content: attr(data-text);
	position: absolute;
	top: 4px;
	left: 4px;
	color: #808080;
	z-index: -1;
}

h1::after {
	content: "";
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	/* background: repeating-linear-gradient(
		45deg,
		rgba(0, 0, 0, 0.1),
		rgba(0, 0, 0, 0.1) 5px,
		transparent 5px,
		transparent 10px
	); */
	z-index: 1;
	pointer-events: none;
}


h2 {
	font-size: 1.2rem;
	line-height: 1;
	text-align: center;
	font-weight: bold;
	margin: -1em 0.65em 1em;
}

.final-score-lbl {
	font-size: 5rem;
	margin: -0.2em 0 0;
}

.high-score-lbl {
	font-size: 1.2rem;
	margin: 0 0 2.5em;
}

button {
	/* display: block; */
	display: flex;              /* ✅ use flexbox */
	align-items: center;        /* ✅ vertical center */
	justify-content: center;    /* ✅ horizontal center */
	position: relative;
	width: 200px;
	padding: 12px 20px;
	background: transparent;
	border: none;
	outline: none;
	user-select: none;
	font-family: monospace;
	font-weight: bold;
	font-size: 1.4rem;
	color: #fff;
	opacity: 0.75;
	transition: opacity 0.3s;
}

button::before {
	content: '';
	position: absolute;
	top: 0;
	right: 0;
	bottom: 0;
	left: 0;
	background-color: rgba(255, 255, 255, 0.15);
	transform: scale(0, 0);
	opacity: 0;
	transition: opacity 0.3s, transform 0.3s;
}

/* No `:focus` styles because this is a mouse/touch game! */
button:active {
	opacity: 1;
}

button:active::before {
	transform: scale(1, 1);
	opacity: 1;
}

.play-normal-btn img {
  width: 25px;
  height: 25px;
  margin-right: 10px;  /* ✅ space between logo and PLAY GAME */
  vertical-align: middle; /* keeps it aligned with text */
}

.credits {
	position: fixed;
	width: 100%;
	left: 0;
	bottom: 20px;
}

a {
	color: white;
}

/* User Profile Dropdown - Blue Theme */
.user-profile {
	position: fixed;
	top: 10px;
	right: 70px;
	cursor: pointer;
	z-index: 9999;
}

.profile-toggle {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 8px 15px;
	border-radius: 6px;
	transition: all 0.3s ease;
	background: linear-gradient(145deg, #1b4a6a, #2e5d7b);
	border: 1px solid #3f8fb6;
	box-shadow: 0 0 12px rgba(34, 119, 139, 0.4), inset 0 0 6px rgba(0, 60, 90, 0.6);
}

.profile-toggle:hover {
	background: linear-gradient(145deg, #245c81, #376b93);
	box-shadow: 0 0 18px rgba(50, 155, 205, 0.6), inset 0 0 10px rgba(0, 80, 120, 0.6);
}

.profile-pic {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	object-fit: cover;
	border: 2px solid #4cafd0;
}

.username {
	display: none;
	font-weight: 600;
	font-size: 16px;
	color: #e6f4f7;
	text-shadow: 0 0 6px rgba(34, 119, 139, 0.7);
	font-family: 'Uncial Antiqua', serif;
}

.user-profile i {
	font-size: 14px;
	transition: transform 0.3s ease;
	color: #65add3;
}

.profile-dropdown {
	position: absolute;
	top: 100%;
	right: 0;
	background: linear-gradient(145deg, #143454, #1e3a6e);
	border-radius: 6px;
	padding: 10px 0;
	width: 200px;
	border: 1px solid #3f8fb6;
	box-shadow: 0 5px 20px rgba(0, 70, 120, 0.5);
	opacity: 0;
	visibility: hidden;
	transform: translateY(10px);
	transition: all 0.3s ease;
	z-index: 1000;
}

.user-profile.active .profile-dropdown {
	opacity: 1;
	visibility: visible;
	transform: translateY(0);
}

.user-profile.active .profile-toggle i {
	transform: rotate(180deg);
}

.profile-dropdown li {
	list-style: none;
}

.profile-dropdown a {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 10px 20px;
	color: #cae9ff;
	text-decoration: none;
	transition: all 0.3s ease;
	font-family: 'Uncial Antiqua', serif;
}

.profile-dropdown a:hover {
	background: rgba(34, 119, 179, 0.2);
	color: #f0f9ff;
	text-shadow: 0 0 8px rgba(144, 198, 238, 0.8);
}

.profile-dropdown a i {
	font-size: 16px;
	color: #90c8ee;
}

.profile-dropdown li:not(:last-child) {
	border-bottom: 1px solid rgba(144, 198, 238, 0.2);
}

/* ---- Landscape Lock Overlay ---- */
.landscape-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.95);
  color: white;
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  font-family: Roboto, Arial, sans-serif;
  text-align: center;
  z-index: 99999;
  font-size: 24px;
  padding: 40px;
}

.landscape-overlay.active {
  display: flex;
}

.landscape-icon {
  font-size: 80px;
  margin-bottom: 30px;
  opacity: 0.8;
}

.landscape-text {
  margin-bottom: 40px;
  line-height: 1.4;
}

/* Only enable hover state on large screens */
@media (min-width: 1025px) {
	button:hover {
		opacity: 1;
	}

	button:hover::before {
		transform: scale(1, 1);
		opacity: 1;
	}
	.username {
		display: block;
	}
}
