/* Who Am I Section */
#WhoAmI {
	background-color: white;
	position: fixed;
	left: calc(50% - 300px);
	top: calc(50% - 300px);
	border-radius: 30px;
	width: 600px;
	height: auto;
	z-index: 10;
	font-size: 20px;
	color: black;
}

#background {
	background-color: rgba(0, 0, 0, 0.5);
	position: fixed;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	z-index: 9;
}

/* Header and sub-headers */
#header,
#header-white {
	z-index: 500;
	flex: 3;
	display: flex;
	flex-direction: row;
	height: fit-content;
	justify-content: space-around;
	align-items: center;
	width: 100%;
	/*padding: 0 30px;*/
}

#header-white {
	color: white;
	text-decoration: none;
}

/* Underline the gallery button when active */
#gallery-btn.active {
	text-decoration: underline;
}

/* Styling for the gallery links when visible */
#gallery-links a {
	display: block;
	padding: 5px 0;
}

/* Main content container */
.main {
	width: 96%;
	padding: 10px 2%;
	display: flex;
	flex-direction: column;
}

.box {
	background: var(--main-color);
	border-radius: 8px;
	margin: 30px;
}

.case {
	border: 1px solid #eaeaea;
	border-radius: 3px;
	background-color: #d1d8e1;
}

/* Responsive adjustments for screen sizes below 1200px */
@media screen and (max-width: 1200px) {
	#header > *,
	#header-white > * {
		padding: 10px;
	}
	#WhoAmI {
		left: calc(50% - 125px);
		top: calc(50% - 300px);
		border-radius: 15px;
		width: 250px;
		height: auto;
		font-size: 17px;
	}
}

/* Sub-menu styles */
.sub-menu {
	float: left;
	overflow: hidden;
}

.sub-menu .btn {
	font-size: 16px;
	outline: none;
	color: white;
	padding: 14px 16px;
	background-color: inherit;
	font-family: inherit;
	margin: 0;
	border: none;
}

.navbar a:hover,
.sub-menu:hover,
.btn {
	background-color: black;
	color: white;
}

.content {
	display: none;
	position: absolute;
	background-color: #f9f9f9;
	min-width: 160px;
	box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
	z-index: 1;
}

.content a {
	float: none;
	color: black;
	padding: 12px 16px;
	text-decoration: none;
	display: block;
	text-align: left;
}

.content a:hover {
	background-color: #eee;
	color: black;
}

.sub-menu:hover .content {
	display: block;
}

/* Mobile menu*/
#mobile-title {
	display: none;
	cursor: pointer;
}

/* Mobile menu button styles */
#menu-btn {
	display: none;
	font-size: 30px;
	cursor: pointer;
}

/* Overlay for mobile menu */
.overlay {
	display: none;
	background-color: rgba(0, 0, 0, 0.5);
	position: fixed;
	left: 0;
	top: 0;
	width: 100%;
	height: 100%;
	z-index: 5;
}

/* Mobile menu */
#mobile-menu {
	display: none;
	position: fixed;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%);
	height: auto; /* Adjust this if needed */
	border-radius: 15px;
	width: 250px;
	background-color: white;
	box-shadow: -3px 0 5px rgba(0, 0, 0, 0.5);
	z-index: 6;
	flex-direction: column;
}

.menu-content {
	display: flex;
	flex-direction: column;
	padding: 20px;
}

.menu-content a {
	padding: 10px 0;
	text-decoration: none;
	color: black;
	font-size: 18px;
}

.menu-content a.title {
	font-size: 22px;
	padding-bottom: 15px;
	padding-top: 5px;
}

.gallery-links {
	display: block;
	border-top: 1px solid #b0b0b0; /* Small top border with custom color */
	border-bottom: 1px solid #b0b0b0; /* Small bottom border with custom color */
}

.menu-content div.gallery-links a {
	font-size: 0.9em; /* Smaller font size for the gallery links */
	margin-left: 10px; /* Indent slightly from the main menu */
	padding-top: 5px; /* Optional: space between the border and links */
	padding-bottom: 5px;
}

#close-btn {
	font-size: 25px;
	margin-bottom: 20px;
	cursor: pointer;
}

.grid-item img {
	width: 100%; /* Ensures the image doesn't exceed 300px */
	max-width: 300px; /* Ensures the image doesn't exceed 300px */
	height: auto;
}

.grid {
	width: 90%;
	margin: 0 auto;
	background: #ddd;
}

/* Clearfix pour .grid */
.grid:after {
	content: '';
	display: block;
	clear: both;
}

/* Styles de base pour .grid-sizer et .grid-item */
.grid-sizer,
.grid-item {
	width: 33.333%; /* Par défaut, 3 colonnes */
}

.grid-item {
	float: left;
	margin-bottom: 10px;
}

.grid-item img {
	display: block;
	max-width: 100%;
}

/* ---- Ajustements Responsives ---- */

/* Pour les très petits écrans (max-width: 400px) - Appareils très petits */
/* Small devices (Phones) - 2 columns */
@media (max-width: 900px) {
	.grid-sizer,
	.grid-item {
		width: calc((100% - 10px) / 2); /* 2 columns */
	}
}

/* Medium devices (Small tablets) - 3 columns */
@media (min-width: 901px) and (max-width: 1400px) {
	.grid-sizer,
	.grid-item {
		width: calc((100% - 20px) / 3); /* 3 columns */
	}
}

/* Tablets and small laptops - 4 columns */
@media (min-width: 1401px) and (max-width: 2000px) {
	.grid-sizer,
	.grid-item {
		width: calc((100% - 30px) / 4); /* 4 columns */
	}
}

/* Large desktops (5 columns) */
@media (min-width: 2001px) {
	.grid-sizer,
	.grid-item {
		width: calc((100% - 40px) / 5); /* 5 columns */
	}
}

/* Styles for mobile sizes */
@media screen and (max-width: 900px) {
	.computer {
		display: none;
	}
	#header,
	#header-white {
		flex-direction: column;
		flex: 1;
	}
	#menu-btn,
	#mobile-title {
		display: block;
	}
	#header,
	#header-white {
		padding: 0;
	}
}
